wxy 4 lat temu
rodzic
commit
e6f1a5fe90

BIN
src/assets/touxiang.png


+ 154 - 0
src/components/parts/textVideo.vue

@@ -0,0 +1,154 @@
+<template>
+  <div id="textVideo">
+    <el-row>
+      <el-col :span="24" class="textVideo">
+        <el-col class="list" v-for="(item, index) in list" :key="index">
+          <el-col :span="3" class="image">
+            <el-image :src="touxiang" style="width:30px;height:30px"></el-image>
+          </el-col>
+          <el-col :span="21" class="other">
+            <el-col :span="24" class="one">
+              <span>{{ item.type == '0' || item.type == '2' ? item.login_name : item.type == '1' ? item.market_username : '暂无' }}</span>
+              <span>[{{ getlundate(item.date) }}]</span>
+            </el-col>
+            <el-col :span="24" class="two">
+              <span v-if="item.type == '0'">
+                <p class="hywl">
+                  <span>欢迎</span>
+                  <span>{{ item.login_name }}</span>
+                  <span>位临现场</span>
+                  <el-image :src="hand" class="hand"></el-image>
+                  <el-image :src="hand" class="hand"></el-image>
+                  <el-image :src="hand" class="hand"></el-image>
+                  <el-image :src="hand" class="hand"></el-image>
+                  <el-image :src="hand" class="hand"></el-image>
+                  <el-image :src="hand" class="hand"></el-image>
+                </p>
+              </span>
+              <span v-else-if="item.type == '1'">
+                <p class="zh">
+                  <span>祝贺</span>
+                  <span>{{ item.market_username }}</span>
+                  <span>和</span>
+                  <span>{{ item.username }}</span>
+                  <span>{{ getstatus(item.status) }}</span>
+                  <el-image :src="hand" class="hand"></el-image>
+                  <el-image :src="hand" class="hand"></el-image>
+                  <el-image :src="hand" class="hand"></el-image>
+                  <el-image :src="hand" class="hand"></el-image>
+                  <el-image :src="hand" class="hand"></el-image>
+                  <el-image :src="hand" class="hand"></el-image>
+                </p>
+              </span>
+              <span v-else-if="item.type == '2'">
+                <p class="remark">{{ item.remark }}</p>
+              </span>
+            </el-col>
+          </el-col>
+        </el-col>
+      </el-col>
+    </el-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+import moment from 'moment';
+export default {
+  name: 'textVideo',
+  props: {
+    list: { type: Array },
+  },
+  components: {},
+  data: function() {
+    return {
+      touxiang: require('@/assets/touxiang.png'),
+    };
+  },
+  created() {},
+  methods: {
+    // 过滤轮播时间
+    getlundate(data) {
+      let newdata = moment(data).format('hh:mm');
+      if (newdata) return newdata;
+    },
+    // 过滤轮播交易状态
+    getstatus(status) {
+      if (status == '0') return '正在洽谈';
+      else if (status == '1') return '达成意向';
+      else if (status == '2') return '交易完成';
+      else if (status == '3') return '取消交易';
+      else if (status == '4') return '交易待确定';
+      else return '暂无';
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+    pageTitle() {
+      return `${this.$route.meta.title}`;
+    },
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+};
+</script>
+
+<style lang="less" scoped>
+.textVideo {
+  height: 315px;
+  overflow-y: auto;
+  .list {
+    padding: 10px 0;
+    border-bottom: 1px dashed #ff0000;
+    .image {
+      text-align: center;
+    }
+    .other {
+      .one {
+        span:nth-child(1) {
+          color: #000;
+          font-size: 16px;
+          font-weight: bold;
+        }
+        span:nth-child(2) {
+          display: inline-block;
+          margin: 0 0 0 15px;
+          color: #ccc;
+        }
+      }
+      .two {
+        margin: 5px 0 0 0;
+        color: #000;
+        .zh {
+          min-height: 20px;
+          font-size: 15px;
+          padding: 5px;
+          border-radius: 5px;
+          background: #ea4235;
+        }
+        .hywl {
+          min-height: 20px;
+          font-size: 15px;
+          padding: 5px;
+          border-radius: 5px;
+          background: #245efe5f;
+          .hand {
+            width: 30px;
+            top: 6px;
+            left: 5px;
+            margin: 0px 0 0 10px;
+          }
+        }
+        .remark {
+          min-height: 20px;
+          font-size: 15px;
+          padding: 5px;
+          border-radius: 5px;
+          background: #cccccc5f;
+        }
+      }
+    }
+  }
+}
+</style>

+ 18 - 0
src/router/index.js

@@ -137,6 +137,24 @@ const routes = [
     meta: { title: '审核管理', isleftarrow: true },
     component: () => import('../views/adminCenter/enterpriseProduct/index.vue'),
   },
+  {
+    path: '/adminCenter/enterpriseProduct/detail',
+    name: 'adminCenter_enterpriseProduct',
+    meta: { title: '产品信息管理', isleftarrow: true },
+    component: () => import('../views/adminCenter/enterpriseProduct/detail.vue'),
+  },
+  {
+    path: '/adminCenter/transaction/index',
+    name: 'adminCenter_transaction',
+    meta: { title: '交易审核管理', isleftarrow: true },
+    component: () => import('../views/adminCenter/transaction/index.vue'),
+  },
+  {
+    path: '/adminCenter/transaction/detail',
+    name: 'adminCenter_transaction',
+    meta: { title: '交易信息管理', isleftarrow: true },
+    component: () => import('../views/adminCenter/transaction/detail.vue'),
+  },
   // 登录
   {
     path: '/login',

+ 8 - 0
src/store/index.js

@@ -11,6 +11,10 @@ import login from './user/login';
 // 个人中心
 import marketuser from './market/user';
 import markettype from './market/markettype';
+// 交易审核
+import transaction from './market/transaction';
+// 交易记录
+import productpact from './market/productpact';
 // 公共
 import * as ustate from '@/store/common/state';
 import * as umutations from '@/store/common/mutations';
@@ -35,5 +39,9 @@ export default new Vuex.Store({
     // 个人中心
     marketuser,
     markettype,
+    // 交易审核
+    transaction,
+    // 交易记录
+    productpact,
   },
 });

+ 14 - 0
src/store/market/product.js

@@ -5,6 +5,7 @@ Vue.use(Vuex);
 const api = {
   newsInfo: `/api/market/product`,
   indexqueryinfo: `/api/market/product/indexquery`,
+  exportexcelInfo: `/api/market/product/exportexcel`,
 };
 const state = () => ({});
 const mutations = {};
@@ -28,6 +29,15 @@ const actions = {
     });
     return res;
   },
+  // 管理员查询注册用户所发布的产品
+  async comquery({ commit }, { skip = 0, limit, ...info } = {}) {
+    const res = await this.$axios.$get(`${api.newsInfo}/allquery`, {
+      skip,
+      limit,
+      ...info,
+    });
+    return res;
+  },
   async newquery({ commit }, { skip = 0, limit, ...info } = {}) {
     const res = await this.$axios.$get(`${api.newsInfo}/newquery`, {
       skip,
@@ -44,6 +54,10 @@ const actions = {
     });
     return res;
   },
+  async exportexcel({ commit }, payload) {
+    const res = await this.$axios.$post(`${api.exportexcelInfo}`, payload);
+    return res;
+  },
   async create({ commit }, payload) {
     const res = await this.$axios.$post(`${api.newsInfo}`, payload);
     return res;

+ 49 - 0
src/store/market/productpact.js

@@ -0,0 +1,49 @@
+import Vue from 'vue';
+import Vuex from 'vuex';
+import _ from 'lodash';
+Vue.use(Vuex);
+const api = {
+  productpactInfo: `/api/market/productpact`,
+  findpactInfo: `/api/market/productpact/findpact`,
+};
+const state = () => ({});
+const mutations = {};
+
+const actions = {
+  async query({ commit }, { skip = 0, limit, ...info } = {}) {
+    const res = await this.$axios.$get(api.productpactInfo, {
+      skip,
+      limit,
+      ...info,
+    });
+    return res;
+  },
+  async create({ commit }, payload) {
+    const res = await this.$axios.$post(`${api.productpactInfo}`, payload);
+    return res;
+  },
+  async fetch({ commit }, payload) {
+    const res = await this.$axios.$get(`${api.productpactInfo}/${payload}`);
+    return res;
+  },
+
+  async findpact({ commit }, payload) {
+    const res = await this.$axios.$get(`${api.findpactInfo}/${payload}`);
+    return res;
+  },
+
+  async update({ commit }, { id, ...data }) {
+    const res = await this.$axios.$post(`${api.productpactInfo}/update/${id}`, data);
+    return res;
+  },
+  async delete({ commit }, payload) {
+    const res = await this.$axios.$delete(`${api.productpactInfo}/${payload}`);
+    return res;
+  },
+};
+export default {
+  namespaced: true,
+  state,
+  mutations,
+  actions,
+};

+ 42 - 0
src/store/market/transaction.js

@@ -0,0 +1,42 @@
+import Vue from 'vue';
+import Vuex from 'vuex';
+import _ from 'lodash';
+Vue.use(Vuex);
+const api = {
+  transactionInfo: `/api/market/transaction`,
+};
+const state = () => ({});
+const mutations = {};
+
+const actions = {
+  async query({ commit }, { skip = 0, limit, ...info } = {}) {
+    const res = await this.$axios.$get(`${api.transactionInfo}`, { skip, limit, ...info });
+    return res;
+  },
+  async productquery({ commit }, payload) {
+    const res = await this.$axios.$post(`${api.transactionInfo}/findTransactionList`, payload);
+    return res;
+  },
+  async create({ commit }, payload) {
+    const res = await this.$axios.$post(`${api.transactionInfo}`, payload);
+    return res;
+  },
+  async fetch({ commit }, payload) {
+    const res = await this.$axios.$get(`${api.transactionInfo}/${payload}`);
+    return res;
+  },
+  async update({ commit }, { id, ...data }) {
+    const res = await this.$axios.$post(`${api.transactionInfo}/update/${id}`, data);
+    return res;
+  },
+  async delete({ commit }, payload) {
+    const res = await this.$axios.$delete(`${api.transactionInfo}/${payload}`);
+    return res;
+  },
+};
+export default {
+  namespaced: true,
+  state,
+  mutations,
+  actions,
+};

+ 15 - 1
src/store/market/user.js

@@ -5,13 +5,19 @@ Vue.use(Vuex);
 const api = {
   interface: `/api/market/user`,
   userinterface: `/api/market/user/hwsxg`,
+  operaInfo: `/api/market/operationlog`,
 };
 const state = () => ({});
 const mutations = {};
 
 const actions = {
   async query({ commit }, { skip = 0, limit = undefined, isdel = '0', ...info } = {}) {
-    const res = await this.$axios.$get(api.interface, { skip, limit, isdel, ...info });
+    const res = await this.$axios.$get(api.interface, {
+      skip,
+      limit,
+      isdel,
+      ...info,
+    });
     return res;
   },
   async userquery({ commit }, { skip = 0, limit = undefined, isdel = '0', ...info } = {}) {
@@ -39,6 +45,14 @@ const actions = {
     const res = await this.$axios.$delete(`${api.interface}/${payload}`);
     return res;
   },
+  async operaFetch({ commit }, { skip = 0, limit, ...info } = {}) {
+    const res = await this.$axios.$get(`${api.operaInfo}`, {
+      skip,
+      limit,
+      ...info,
+    });
+    return res;
+  },
 };
 
 export default {

+ 205 - 0
src/views/adminCenter/enterpriseProduct/detail.vue

@@ -0,0 +1,205 @@
+<template>
+  <div id="index">
+    <el-row>
+      <el-col :span="24" class="style">
+        <el-col :span="24" class="top">
+          <NavBar v-show="navShow" :title="title" :isleftarrow="isleftarrow"> </NavBar>
+        </el-col>
+        <el-col :span="24" class="main">
+          <span v-if="form.type == '0'">
+            <van-form>
+              <van-field v-model="form.name" name="名称" label="名称" placeholder="名称" readonly />
+              <van-field v-model="form.contacts" name="联系人" label="联系人" placeholder="联系人" readonly />
+              <van-field v-model="form.phone" name="联系电话" label="联系电话" placeholder="联系电话" readonly />
+              <van-field v-model="form.qqwx" name="QQ/微信" label="QQ/微信" placeholder="QQ/微信" readonly />
+              <van-field v-model="form.email" name="电子邮箱" label="电子邮箱" placeholder="电子邮箱" readonly />
+              <van-field v-model="form.field" name="所属领域" label="所属领域" placeholder="所属领域" readonly />
+              <van-field v-model="form.cooperation" name="合作方式" label="合作方式" placeholder="合作方式" readonly />
+              <van-field v-model="form.company" name="企业名称" label="企业名称" placeholder="企业名称" readonly />
+              <van-field v-model="form.companybrief" rows="1" autosize label="企业简介" type="textarea" placeholder="企业简介" readonly />
+              <van-field v-model="form.companyweb" name="企业网站" label="企业网站" placeholder="企业网站" readonly />
+              <van-field v-model="form.condition" name="合作条件及要求" label="合作条件及要求" placeholder="合作条件及要求" readonly />
+              <!-- <van-field v-model="form.image" name="产品图片" label="产品图片" placeholder="产品图片" readonly /> -->
+              <van-field v-model="form.budget" name="投资预算" label="投资预算" placeholder="投资预算" readonly />
+              <van-field v-model="form.companytype" name="投资预算" label="投资预算" placeholder="投资预算" readonly />
+              <van-field v-model="form.zzjgdm" name="信用代码" label="信用代码" placeholder="信用代码" readonly />
+              <van-field v-model="form.companydate" name="注册时间" label="注册时间" placeholder="注册时间" readonly />
+              <van-field v-model="form.companycapital" name="注册资金" label="注册资金" placeholder="注册资金" readonly />
+              <van-field v-model="form.companyperson" name="企业法人" label="企业法人" placeholder="企业法人" readonly />
+              <van-field v-model="form.sndqyzsr" name="企业总收入" label="企业总收入" placeholder="企业总收入" readonly />
+              <van-field v-model="form.sndyffy" name="研发费用" label="研发费用" placeholder="研发费用" readonly />
+              <van-field v-model="form.companytotal" name="总人数" label="总人数" placeholder="总人数" readonly />
+              <van-field v-model="form.zjzyfrs" name="研发人数" label="研发人数" placeholder="研发人数" readonly />
+              <van-field v-model="form.degreeurgency" name="需求紧急程度" label="需求紧急程度" placeholder="需求紧急程度" readonly />
+              <van-field v-model="form.requirementdesc" rows="1" autosize label="技术难题" type="textarea" placeholder="技术难题" readonly />
+              <van-field v-model="form.expect" rows="1" autosize label="预期目标" type="textarea" placeholder="预期目标" readonly />
+              <van-field v-model="form.present" rows="1" autosize label="需求现状" type="textarea" placeholder="需求现状" readonly />
+              <van-field v-model="form.mainproduct" rows="1" autosize label="主要产品" type="textarea" placeholder="主要产品" readonly />
+              <van-field v-model="form.qualifications" rows="1" autosize label="资质/荣誉" type="textarea" placeholder="资质/荣誉" readonly />
+              <van-field name="radio" label="状态" v-if="form.status == '0'">
+                <template #input>
+                  <van-radio-group v-model="form.status" direction="horizontal">
+                    <van-radio name="0">待审核</van-radio>
+                    <van-radio name="1">通过</van-radio>
+                    <van-radio name="2">拒绝</van-radio>
+                  </van-radio-group>
+                </template>
+              </van-field>
+              <div style="margin: 16px;" v-if="form.status == '0'">
+                <van-button round block type="info" @click="onSubmit">
+                  提交
+                </van-button>
+              </div>
+            </van-form>
+          </span>
+          <span v-if="form.type == '1'">
+            <van-form>
+              <van-field v-model="form.name" name="名称" label="名称" placeholder="名称" readonly />
+              <van-field v-model="form.contacts" name="联系人" label="联系人" placeholder="联系人" readonly />
+              <van-field v-model="form.phone" name="联系电话" label="联系电话" placeholder="联系电话" readonly />
+              <van-field v-model="form.qqwx" name="QQ/微信" label="QQ/微信" placeholder="QQ/微信" readonly />
+              <van-field v-model="form.email" name="电子邮箱" label="电子邮箱" placeholder="电子邮箱" readonly />
+              <van-field v-model="form.field" name="所属领域" label="所属领域" placeholder="所属领域" readonly />
+              <van-field v-model="form.cooperation" name="合作方式" label="合作方式" placeholder="合作方式" readonly />
+              <van-field v-model="form.company" name="企业名称" label="企业名称" placeholder="企业名称" readonly />
+              <van-field v-model="form.companybrief" rows="1" autosize label="企业简介" type="textarea" placeholder="企业简介" readonly />
+              <van-field v-model="form.companyweb" name="企业网站" label="企业网站" placeholder="企业网站" readonly />
+              <van-field v-model="form.condition" name="合作条件及要求" label="合作条件及要求" placeholder="合作条件及要求" readonly />
+              <van-field v-model="form.achievestatus" name="成果状态" label="成果状态" placeholder="成果状态" readonly />
+              <van-field v-model="form.achieveown" name="成果权属" label="成果权属" placeholder="成果权属" readonly />
+              <van-field v-model="form.degreeurgency" name="成果来源" label="成果来源" placeholder="成果来源" readonly />
+              <van-field v-model="form.roadshow" name="项目路演" label="项目路演" placeholder="项目路演" readonly />
+              <van-field v-model="form.intentionprice" name="意向价格" label="意向价格" placeholder="意向价格" readonly />
+              <van-field v-model="form.achievebrief" rows="1" autosize label="成果简介" type="textarea" placeholder="成果简介" readonly />
+              <van-field v-model="form.maxRows" rows="1" autosize label="技术特点" type="textarea" placeholder="技术特点" readonly />
+              <van-field v-model="form.team" rows="1" autosize label="技术团队" type="textarea" placeholder="技术团队" readonly />
+              <van-field v-model="form.expectations" rows="1" autosize label="商业预期" type="textarea" placeholder="商业预期" readonly />
+              <van-field name="radio" label="状态" v-if="form.status == '0'">
+                <template #input>
+                  <van-radio-group v-model="form.status" direction="horizontal">
+                    <van-radio name="0">待审核</van-radio>
+                    <van-radio name="1">通过</van-radio>
+                    <van-radio name="2">拒绝</van-radio>
+                  </van-radio-group>
+                </template>
+              </van-field>
+              <div style="margin: 16px;" v-if="form.status == '0'">
+                <van-button round block type="info" @click="onSubmit">
+                  提交
+                </van-button>
+              </div>
+            </van-form>
+          </span>
+          <span v-if="form.type == '2'">
+            <van-form>
+              <van-field v-model="form.name" name="名称" label="名称" placeholder="名称" readonly />
+              <van-field v-model="form.contacts" name="联系人" label="联系人" placeholder="联系人" readonly />
+              <van-field v-model="form.phone" name="联系电话" label="联系电话" placeholder="联系电话" readonly />
+              <van-field v-model="form.qqwx" name="QQ/微信" label="QQ/微信" placeholder="QQ/微信" readonly />
+              <van-field v-model="form.email" name="电子邮箱" label="电子邮箱" placeholder="电子邮箱" readonly />
+              <van-field v-model="form.messattribute" name="信息属性" label="信息属性" placeholder="信息属性" readonly />
+              <van-field v-model="form.demand" name="需求程度" label="需求程度" placeholder="需求程度" readonly />
+              <van-field v-model="form.informationdesc" rows="1" autosize label="信息描述" type="textarea" placeholder="信息描述" readonly />
+              <van-field v-model="form.coreelements" rows="1" autosize label="核心要素" type="textarea" placeholder="核心要素" readonly />
+              <van-field v-model="form.priceinfo" rows="1" autosize label="价格信息" type="textarea" placeholder="价格信息" readonly />
+              <van-field v-model="form.businessexpect" rows="1" autosize label="商业预期" type="textarea" placeholder="商业预期" readonly />
+              <van-field name="radio" label="状态" v-if="form.status == '0'">
+                <template #input>
+                  <van-radio-group v-model="form.status" direction="horizontal">
+                    <van-radio name="0">待审核</van-radio>
+                    <van-radio name="1">通过</van-radio>
+                    <van-radio name="2">拒绝</van-radio>
+                  </van-radio-group>
+                </template>
+              </van-field>
+              <div style="margin: 16px;" v-if="form.status == '0'">
+                <van-button round block type="info" @click="onSubmit">
+                  提交
+                </van-button>
+              </div>
+            </van-form>
+          </span>
+        </el-col>
+      </el-col>
+    </el-row>
+  </div>
+</template>
+
+<script>
+import NavBar from '@/layout/common/topInfo.vue';
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: product } = createNamespacedHelpers('product');
+export default {
+  name: 'index',
+  props: {},
+  components: {
+    NavBar,
+  },
+  data: function() {
+    return {
+      // 头部标题
+      title: '',
+      // meta为true
+      isleftarrow: '',
+      // 返回
+      navShow: true,
+      form: {},
+    };
+  },
+  async created() {
+    if (this.id) {
+      await this.search();
+    }
+  },
+  methods: {
+    ...product(['query', 'comquery', 'delete', 'fetch', 'update']),
+    async search() {
+      let res = await this.fetch(this.id);
+      if (this.$checkRes(res)) {
+        this.$set(this, `form`, res.data);
+      }
+    },
+    // 提交
+    async onSubmit() {
+      let data = this.form;
+      const res = await this.update(data);
+      if (this.$checkRes(res)) {
+        this.$notify({
+          message: '审核成功',
+          type: 'success',
+        });
+        this.$router.push({ path: '/adminCenter/enterpriseProduct/index' });
+      }
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+    id() {
+      return this.$route.query.id;
+    },
+  },
+  mounted() {
+    this.title = this.$route.meta.title;
+    this.isleftarrow = this.$route.meta.isleftarrow;
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+};
+</script>
+
+<style lang="less" scoped>
+.style {
+  width: 100%;
+  min-height: 667px;
+  position: relative;
+  background-color: #f9fafc;
+}
+.top {
+  height: 46px;
+  overflow: hidden;
+}
+.main {
+  min-height: 570px;
+}
+</style>

+ 49 - 5
src/views/adminCenter/enterpriseProduct/index.vue

@@ -8,13 +8,13 @@
         <el-col :span="24" class="main">
           <van-tabs v-model="active">
             <van-tab title="待审核">
-              <list></list>
+              <list :list="oneList" status="0" @query="search" @check="check" @deleteBtn="deleteBtn"></list>
             </van-tab>
             <van-tab title="审核成功">
-              <list></list>
+              <list :list="twoList" status="1" @query="search" @check="check" @deleteBtn="deleteBtn"></list>
             </van-tab>
             <van-tab title="审核拒绝">
-              <list></list>
+              <list :list="threeList" status="2" @query="search" @check="check" @deleteBtn="deleteBtn"></list>
             </van-tab>
           </van-tabs>
         </el-col>
@@ -27,6 +27,7 @@
 import list from './parts/list.vue';
 import NavBar from '@/layout/common/topInfo.vue';
 import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: product } = createNamespacedHelpers('product');
 export default {
   name: 'index',
   props: {},
@@ -43,10 +44,53 @@ export default {
       // 返回
       navShow: true,
       active: '1',
+      // 待审核
+      oneList: [],
+      // 审核成功
+      twoList: [],
+      // 审核拒绝
+      threeList: [],
     };
   },
-  created() {},
-  methods: {},
+  async created() {
+    await this.search({ status: '0' });
+    await this.search({ status: '1' });
+    await this.search({ status: '2' });
+  },
+  methods: {
+    ...product(['query', 'comquery', 'delete', 'fetch', 'update']),
+    async search({ skip = 0, status, ...info } = {}) {
+      let code = this.user.code;
+      let pid = this.user.uid;
+      let res = await this.comquery({ status, code, pid, ...info });
+      if (res.errcode === 0) {
+        if (status == '0') {
+          this.$set(this, `oneList`, res.data);
+        } else if (status == '1') {
+          this.$set(this, `twoList`, res.data);
+        } else if (status == '2') {
+          this.$set(this, `threeList`, res.data);
+        }
+      }
+    },
+    // 审核/查看
+    check(data) {
+      this.$router.push({ path: '/adminCenter/enterpriseProduct/detail', query: { id: data.id } });
+    },
+    // 删除
+    async deleteBtn(data) {
+      const res = await this.delete(data.id);
+      if (this.$checkRes(res)) {
+        this.$notify({
+          message: '删除成功',
+          type: 'success',
+        });
+        this.search({ status: '0' });
+        this.search({ status: '1' });
+        this.search({ status: '2' });
+      }
+    },
+  },
   computed: {
     ...mapState(['user']),
   },

+ 55 - 4
src/views/adminCenter/enterpriseProduct/parts/list.vue

@@ -1,6 +1,20 @@
 <template>
   <div id="list">
-    <p>list</p>
+    <el-row>
+      <el-col :span="24" class="product">
+        <el-col :span="24" class="list" v-for="(item, index) in list" :key="index">
+          <p class="textOver">{{ item.name }}</p>
+          <p>
+            <span>产品类型:{{ item.type == '0' ? '技术' : item.type == '1' ? '产品' : '商务' }}</span>
+            <span>产品状态:{{ item.status == '0' ? '待审核' : item.status == '1' ? '审核通过' : '审核拒绝' }}</span>
+          </p>
+          <p>
+            <el-button type="primary" size="mini" @click="check(item)">{{ item.status == '0' ? '审核' : '查看' }}</el-button>
+            <el-button type="danger" size="mini" @click="deleteBtn(item)">删除</el-button>
+          </p>
+        </el-col>
+      </el-col>
+    </el-row>
   </div>
 </template>
 
@@ -8,13 +22,24 @@
 import { mapState, createNamespacedHelpers } from 'vuex';
 export default {
   name: 'list',
-  props: {},
+  props: {
+    list: { type: Array },
+  },
   components: {},
   data: function() {
     return {};
   },
   created() {},
-  methods: {},
+  methods: {
+    // 审核/查看
+    check(data) {
+      this.$emit('check', data);
+    },
+    // 删除
+    deleteBtn(data) {
+      this.$emit('deleteBtn', data);
+    },
+  },
   computed: {
     ...mapState(['user']),
     pageTitle() {
@@ -27,4 +52,30 @@ export default {
 };
 </script>
 
-<style lang="less" scoped></style>
+<style lang="less" scoped>
+.product {
+  padding: 0 10px;
+  .list {
+    padding: 10px 0;
+    border-bottom: 1px dashed #ccc;
+    p {
+      font-size: 16px;
+      color: #000;
+      padding: 0 0 10px 0;
+    }
+    p:nth-child(1) {
+      font-size: 18px;
+      font-weight: bold;
+    }
+    p:nth-child(2) {
+      span {
+        display: inline-block;
+        width: 50%;
+      }
+    }
+    p:nth-child(3) {
+      text-align: center;
+    }
+  }
+}
+</style>

+ 51 - 38
src/views/adminCenter/transaction/detail.vue

@@ -1,12 +1,30 @@
 <template>
-  <div id="index">
+  <div id="detail">
     <el-row>
       <el-col :span="24" class="style">
         <el-col :span="24" class="top">
           <NavBar v-show="navShow" :title="title" :isleftarrow="isleftarrow"> </NavBar>
         </el-col>
         <el-col :span="24" class="main">
-          <detaliinfo :form="form" @onSubmit="onSubmit"></detaliinfo>
+          <van-form>
+            <van-field v-model="form.product_name" name="产品名称" label="产品名称" placeholder="产品名称" readonly />
+            <van-field v-model="form.market_username" name="营销人名称" label="营销人名称" placeholder="营销人名称" readonly />
+            <van-field v-model="form.username" name="购买人名称" label="购买人名称" placeholder="购买人名称" readonly />
+            <van-field v-model="form.description" rows="1" autosize label="描述" type="textarea" placeholder="描述" />
+            <van-field name="radio" label="状态">
+              <template #input>
+                <van-radio-group v-model="form.status" direction="horizontal">
+                  <van-radio name="0">待审核</van-radio>
+                  <van-radio name="1">通过</van-radio>
+                </van-radio-group>
+              </template>
+            </van-field>
+            <div style="margin: 16px;" v-if="form.status == '0'">
+              <van-button round block type="info" @click="onSubmit">
+                提交
+              </van-button>
+            </div>
+          </van-form>
         </el-col>
       </el-col>
     </el-row>
@@ -15,49 +33,41 @@
 
 <script>
 import NavBar from '@/layout/common/topInfo.vue';
-import detaliinfo from '@/layout/transaction/detaliinfo.vue';
 import { mapState, createNamespacedHelpers } from 'vuex';
 const { mapActions: transaction } = createNamespacedHelpers('transaction');
 const { mapActions: productpact } = createNamespacedHelpers('productpact');
 export default {
-  name: 'index',
+  name: 'detail',
   props: {},
   components: {
     NavBar,
-    detaliinfo, //个人信息维护
   },
-  data: () => ({
-    // 头部标题
-    title: '',
-    // meta为true
-    isleftarrow: '',
-    // 返回
-    navShow: true,
-    // 个人信息
-    form: {},
-  }),
-  created() {
-    this.searchInfo();
+  data: function() {
+    return {
+      // 头部标题
+      title: '',
+      // meta为true
+      isleftarrow: '',
+      // 返回
+      navShow: true,
+      form: {},
+    };
   },
-  computed: {
-    ...mapState(['user']),
-    id() {
-      return this.$route.query.id;
-    },
-    role() {
-      return this.$route.query.role;
-    },
+  async created() {
+    await this.search();
   },
   methods: {
-    ...transaction({ transactionsfetch: 'fetch', transactionslist: 'query', transactionupdate: 'update' }),
+    ...transaction({ transactionfetch: 'fetch', transactionlist: 'query', transactiondetele: 'detele', transactionupdate: 'update' }),
     ...productpact({ transactionQuery: 'query', productpactFetch: 'findpact', productpactUpdate: 'update' }),
-    async searchInfo() {
-      const res = await this.productpactFetch(this.id);
+    async search() {
+      let res = await this.productpactFetch(this.id);
       if (this.$checkRes(res)) {
-        this.$set(this, `form`, res.data);
+        this.$set(this, 'form', res.data);
       }
     },
-    async onSubmit({ data }) {
+    // 提交审核
+    async onSubmit() {
+      let data = this.form;
       const res = await this.productpactUpdate(data);
       if (this.$checkRes(res)) {
         data.status = '2';
@@ -65,18 +75,27 @@ export default {
         const arr = await this.transactionupdate(data);
         if (this.$checkRes(arr)) {
           this.$notify({
-            message: '确定成功',
+            message: '审核成功',
             type: 'success',
           });
+          this.$router.push({ path: '/adminCenter/transaction/index' });
         }
       }
-      this.$router.push({ path: './index' });
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+    id() {
+      return this.$route.query.id;
     },
   },
   mounted() {
     this.title = this.$route.meta.title;
     this.isleftarrow = this.$route.meta.isleftarrow;
   },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
 };
 </script>
 
@@ -90,14 +109,8 @@ export default {
 .top {
   height: 46px;
   overflow: hidden;
-  position: relative;
-  z-index: 999;
 }
 .main {
   min-height: 570px;
 }
-.foot {
-  position: absolute;
-  bottom: 0;
-}
 </style>

+ 45 - 47
src/views/adminCenter/transaction/index.vue

@@ -6,7 +6,11 @@
           <NavBar v-show="navShow" :title="title" :isleftarrow="isleftarrow"> </NavBar>
         </el-col>
         <el-col :span="24" class="main">
-          <list></list>
+          <list :list="oneList" @check="check"></list>
+          <!-- <van-tabs v-model="active">
+            <van-tab title="待审核">
+            </van-tab>
+          </van-tabs> -->
         </el-col>
       </el-col>
     </el-row>
@@ -14,32 +18,54 @@
 </template>
 
 <script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-import NavBar from '@/layout/common/topInfo.vue';
 import list from './parts/list.vue';
+import NavBar from '@/layout/common/topInfo.vue';
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: transaction } = createNamespacedHelpers('transaction');
 export default {
   name: 'index',
   props: {},
-  components: { NavBar, list },
-  data: () => ({
-    // 头部标题
-    title: '',
-    // meta为true
-    isleftarrow: '',
-    // 返回
-    navShow: true,
-    img_path: require('@/assets/logo.png'),
-    active: 0,
-    show: false,
-    newform: {},
-  }),
-  created() {},
-  computed: {},
-  methods: {},
+  components: {
+    NavBar,
+    list,
+  },
+  data: function() {
+    return {
+      // 头部标题
+      title: '',
+      // meta为true
+      isleftarrow: '',
+      // 返回
+      navShow: true,
+      active: '1',
+      oneList: [],
+    };
+  },
+  async created() {
+    await this.search();
+  },
+  methods: {
+    ...transaction({ transactionsfetch: 'fetch', transactionslist: 'query', transactiondetele: 'detele' }),
+    async search() {
+      let res = await this.transactionslist();
+      if (this.$checkRes(res)) {
+        this.$set(this, 'oneList', res.data);
+      }
+    },
+    check(data) {
+      this.$router.push({ path: '/adminCenter/transaction/detail', query: { id: data.id } });
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
   mounted() {
     this.title = this.$route.meta.title;
     this.isleftarrow = this.$route.meta.isleftarrow;
   },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
 };
 </script>
 
@@ -53,36 +79,8 @@ export default {
 .top {
   height: 46px;
   overflow: hidden;
-  position: relative;
-  z-index: 999;
 }
 .main {
   min-height: 570px;
-  .two {
-    position: fixed;
-    top: 80%;
-
-    left: 10px;
-    z-index: 999;
-  }
-}
-/deep/.van-tab {
-  text-align: center;
-}
-/deep/.van-tabs--line .van-tabs__wrap {
-  height: 70px;
-  margin: 0 0 10px 0;
-}
-/deep/.van-tab--active {
-  color: red;
-}
-.van-icon {
-  font-size: 20px;
-}
-/deep/.van-popup--bottom {
-  bottom: 0;
-  left: 0;
-  width: 100%;
-  height: 300px;
 }
 </style>

+ 41 - 89
src/views/adminCenter/transaction/parts/list.vue

@@ -1,35 +1,31 @@
 <template>
-  <div id="auditList">
+  <div id="list">
     <el-row>
-      <el-col :span="24" class="info">
+      <el-col :span="24" class="train">
         <el-col :span="24" class="list" v-for="(item, index) in list" :key="index">
-          <p class="textOver">
-            <span @click="$router.push({ path: '/userCenter/matter/detailinfo', query: { id: item.id } })">{{ item.product_name }}</span>
-            <span style="float:right"><van-button v-if="item.status == '4'" type="primary" size="small" @click="submit(item)">备案</van-button> </span>
-          </p>
+          <p class="textOver">{{ item.product_name }}</p>
           <p>
-            <span class="ptwo"><span>购买人名称:</span>{{ item.username || '暂无' }}</span>
+            <span class="textOver">营销人:{{ item.market_username }}</span>
+            <span class="textOver">购买人:{{ item.username }}</span>
           </p>
-
           <p>
-            <span class="ptwo"><span>营销人名称:</span>{{ item.market_username || '暂无' }}</span>
-            <span>状态:</span>
-            {{
-              `${item.status}` === `0`
+            交易状态:{{
+              item.status == '0'
                 ? '未交易'
-                : `${item.status}` === `1`
+                : item.status == '1'
                 ? '交易中'
-                : `${item.status}` === `2`
-                ? '交易成'
-                : `${item.status}` === `3`
+                : item.status == '2'
+                ? '交易成'
+                : item.status == '3'
                 ? '交易失败'
-                : `${item.status}` === `4`
-                ? '合同待审核'
-                : '未识别'
+                : item.status == '4'
+                ? '待确定'
+                : '暂无'
             }}
           </p>
-
-          <p class="textOver"><span>说明:</span>{{ item.description || '暂无' }}</p>
+          <p>
+            <el-button type="primary" size="mini" @click="check(item)">审核/查看</el-button>
+          </p>
         </el-col>
       </el-col>
     </el-row>
@@ -38,43 +34,19 @@
 
 <script>
 import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: transaction } = createNamespacedHelpers('transaction');
-
 export default {
-  name: 'auditList',
-  props: {},
+  name: 'list',
+  props: {
+    list: { type: Array },
+  },
   components: {},
   data: function() {
-    return {
-      list: [],
-    };
-  },
-  created() {
-    this.searchInfo();
+    return {};
   },
+  created() {},
   methods: {
-    ...transaction({ transactionList: 'query', transactiondtetle: 'delete', shenheupdate: 'update' }),
-    async searchInfo() {
-      if (this.user.role == '4') {
-        let create_userid = this.user.uid;
-        let res = await this.transactionList({ create_userid, status: '4' });
-        let arr = await this.transactionList({ create_userid, status: '2' });
-        if (this.$checkRes(res)) {
-          var newData = res.data.concat(arr.data);
-          this.$set(this, `list`, newData);
-        }
-      } else {
-        let userid = this.user.uid;
-        let res = await this.transactionList({ status: '4' });
-        let arr = await this.transactionList({ status: '2' });
-        if (this.$checkRes(res)) {
-          var newData = res.data.concat(arr.data);
-          this.$set(this, `list`, newData);
-        }
-      }
-    },
-    async submit(item) {
-      this.$router.push({ path: './detail', query: { id: item.id } });
+    check(data) {
+      this.$emit('check', data);
     },
   },
   computed: {
@@ -90,48 +62,28 @@ export default {
 </script>
 
 <style lang="less" scoped>
-.info {
-  border-top: 1px solid #f5f5f5;
+.train {
+  padding: 0 10px;
   .list {
-    background: #fff;
-    padding: 0 10px;
-    border-bottom: 1px solid #ccc;
+    padding: 10px;
+    border-bottom: 1px dashed #ccc;
     p {
-      font-size: 14px;
-      color: #000;
-      padding: 5px 0;
-    }
-    p:first-child {
       font-size: 16px;
+      color: #666;
+      padding: 0 0 5px 0;
+      span {
+        display: inline-block;
+        width: 50%;
+      }
     }
-    p:nth-child(2) .ptwo {
-      display: inline-block;
-      width: 75%;
-    }
-
-    p:nth-child(3) .ptwo {
-      display: inline-block;
-      width: 40%;
-    }
-
-    p:nth-child(3) .ptwo span:first-child {
-      color: #ccc;
-    }
-
-    p:nth-child(2) .ptwo span:first-child {
-      color: #ccc;
+    p:nth-child(1) {
+      font-size: 18px;
+      font-weight: bold;
+      color: #000;
     }
-    p:last-child span {
-      color: #ccc;
+    p:nth-child(4) {
+      text-align: center;
     }
   }
 }
-.content {
-  padding: 16px 16px 160px;
-  height: 160px;
-  background-color: aqua;
-}
-.newptwo {
-  color: #ccc !important;
-}
 </style>

+ 9 - 1
src/views/adminCenter/user/index.vue

@@ -71,7 +71,15 @@ export default {
           if (three) this.$set(this, `threeList`, three);
         }
       } else {
-        console.log('机构');
+        const res = await this.userquery({ code: this.user.code, ...info });
+        if (this.$checkRes(res)) {
+          let one = res.data.filter(i => i.status == '0' && i.isdel == '0');
+          if (one) this.$set(this, `oneList`, one);
+          let two = res.data.filter(i => i.status == '1' && i.isdel == '0');
+          if (two) this.$set(this, `twoList`, two);
+          let three = res.data.filter(i => i.status == '2' && i.isdel == '0');
+          if (three) this.$set(this, `threeList`, three);
+        }
       }
     },
     // 审核用户。查看用户

+ 0 - 1
src/views/live/index.vue

@@ -66,7 +66,6 @@ export default {
     };
   },
   async created() {
-    console.log(this.user);
     await this.searchPlace();
     await this.searchList({ status: '0' });
     await this.searchList({ status: '1' });

+ 38 - 9
src/views/live/parts/videoDetail.vue

@@ -11,7 +11,14 @@
           </div>
         </el-col>
         <el-col :span="24" class="chat">
-          <chat></chat>
+          <van-tabs v-model="active">
+            <van-tab title="图文直播">
+              <textVideo :list="lunboList"></textVideo>
+            </van-tab>
+            <van-tab title="公共聊天">
+              <chat></chat>
+            </van-tab>
+          </van-tabs>
         </el-col>
         <el-col :span="24" class="tab">
           <el-tabs v-model="activeName" stretch type="border-card">
@@ -57,15 +64,18 @@
 
 <script>
 import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: dock } = createNamespacedHelpers('dock');
 import chat from '@/components/parts/chat.vue';
+import textVideo from '@/components/parts/textVideo.vue';
+const { mapActions: dock } = createNamespacedHelpers('dock');
 const { mapActions: exportuser } = createNamespacedHelpers('exportuser');
-
+const { mapActions: marketuser } = createNamespacedHelpers('marketuser');
+import moment from 'moment';
 export default {
   name: 'videoDetail',
   props: {},
   components: {
     chat,
+    textVideo,
   },
   data: function() {
     return {
@@ -80,15 +90,21 @@ export default {
       // 展会详情
       dockInfo: {},
       times: 5,
+      // 聊天
+      active: '1',
+      // 图文直播
+      lunboList: [],
     };
   },
   async created() {
     await this.seachdock();
     await this.seachInfo();
+    await this.seachLunbo();
   },
   methods: {
     ...dock({ dockQuery: 'query', dockFetch: 'fetch' }),
     ...exportuser({ expertQuery: 'query' }),
+    ...marketuser({ operaFetch: 'operaFetch' }),
     async seachInfo({ skip = 0, limit = 5, ...info } = {}) {
       let res = await this.dockFetch(this.id);
       if (this.$checkRes(res)) {
@@ -104,7 +120,6 @@ export default {
         // 专家智库
         let exportdata = await this.expertQuery({ role: 6, limit: 6 });
         if (this.$checkRes(exportdata)) this.$set(this, `expertList`, exportdata.data);
-        console.log('ad');
       }
     },
     // 文字/视频倒计时
@@ -119,10 +134,23 @@ export default {
       }, 1000);
     },
     async seachdock() {
-      let res = await this.dockFetch(this.id);
+      if (this.id) {
+        let res = await this.dockFetch(this.id);
+        if (this.$checkRes(res)) {
+          // 对接会详情
+          this.$set(this, `dockInfo`, res.data);
+        }
+      }
+    },
+    // 查询图文直播
+    async seachLunbo() {
+      let res = await this.operaFetch({ dockid: this.id });
+      for (const val of res.data) {
+        var date = moment(val.meta.createdAt).format('YYYY-MM-DD hh:mm');
+        val.date = date;
+      }
       if (this.$checkRes(res)) {
-        // 对接会详情
-        this.$set(this, `dockInfo`, res.data);
+        this.$set(this, `lunboList`, res.data);
       }
     },
   },
@@ -141,11 +169,12 @@ export default {
   watch: {
     times: {
       handler(val) {
-        if (val == 5) {
+        if (val && val == 5) {
           this.daojishi();
         }
       },
       immediate: true,
+      deep: true,
     },
   },
 };
@@ -166,7 +195,7 @@ export default {
       padding: 0px 0 15px 0px;
     }
     .videointro {
-      background: url(/img/directBack.d8126f77.png);
+      background: url('~@/assets/directBack.png');
       background-size: 100% 100%;
       color: #fff;
       padding: 0 15px;

+ 3 - 17
src/views/user/parts/clickBtn.vue

@@ -14,10 +14,11 @@
             <van-cell is-link title="用户管理" @click="$router.push({ path: '/adminCenter/user/index' })" />
             <van-cell is-link title="展会管理" @click="$router.push({ path: '/adminCenter/duijiehui/index' })" />
             <van-cell is-link title="审核管理" @click="$router.push({ path: '/adminCenter/enterpriseProduct/index' })" />
-            <van-cell is-link title="交易审核" @click="$router.push({ path: '' })" />
+            <van-cell is-link title="交易审核" @click="$router.push({ path: '/adminCenter/transaction/index' })" />
           </span>
           <span v-else-if="user.role == '1'">
-            机构
+            <van-cell is-link title="用户管理" @click="$router.push({ path: '/adminCenter/user/index' })" />
+            <van-cell is-link title="审核管理" @click="$router.push({ path: '/adminCenter/enterpriseProduct/index' })" />
           </span>
           <span v-else-if="user.role == '3'">
             展会负责人
@@ -28,21 +29,6 @@
         </span>
         <van-cell is-link title="退出登录" @click="loginOut()" />
         <!-- <span v-else>
-          <span v-if="user.role == '0'">
-            <van-cell is-link title="用户管理" @click="$router.push({ path: '/adminCenter/user/index' })" />
-            <van-cell is-link title="对接会管理" @click="$router.push({ path: '/adminCenter/duijiehui/index' })" />
-            <van-cell is-link title="产品供求审核管理" @click="$router.push({ path: '/adminCenter/enterpriseProduct/index' })" />
-            <van-cell is-link title="产品供求交易状态审核管理" @click="$router.push({ path: '/adminCenter/transaction/index' })" />
-          </span>
-          <span v-else-if="user.role == '1'">
-            <van-cell is-link title="用户管理" v-if="oneName == '用户管理'" @click="$router.push({ path: '/adminCenter/user/index' })" />
-            <van-cell
-              is-link
-              title="产品供求审核管理"
-              v-if="threeName == '产品供求审核管理'"
-              @click="$router.push({ path: '/adminCenter/enterpriseProduct/index' })"
-            />
-          </span>
           <span v-else-if="user.role == '3'">
             <van-cell is-link title="展会管理" @click="$router.push({ path: '/dockCenter/dockInfo/index' })" />
             <van-cell is-link title="申请管理" @click="$router.push({ path: '/dockCenter/applyInfo/index' })" />