Ver Fonte

项目更新

guhongwei há 3 anos atrás
pai
commit
c36b5329ae
100 ficheiros alterados com 4018 adições e 3109 exclusões
  1. 64 73
      src/layout/analysis/form-1.vue
  2. 18 6
      src/layout/analysis/list-1.vue
  3. 0 109
      src/layout/analysis/list-2.vue
  4. 5 5
      src/layout/apply/check-2.vue
  5. 4 4
      src/layout/apply/check-3.vue
  6. 0 76
      src/layout/apply/agent-1.vue
  7. 1 1
      src/layout/apply/check-1.vue
  8. 92 95
      src/layout/apply/form-1.vue
  9. 337 0
      src/layout/apply/form-2.vue
  10. 16 14
      src/layout/apply/info-1.vue
  11. 71 24
      src/layout/apply/list-1.vue
  12. 0 122
      src/layout/apply/list-2.vue
  13. 0 133
      src/layout/apply/list-3.vue
  14. 135 0
      src/layout/apply/mech-1.vue
  15. 146 21
      src/layout/assessment/form-1.vue
  16. 9 6
      src/layout/assessment/info-1.vue
  17. 20 6
      src/layout/assessment/list-1.vue
  18. 0 120
      src/layout/assessment/list-2.vue
  19. 1 0
      src/layout/assessment/search-1.vue
  20. 1 1
      src/layout/chatCommon/chat.vue
  21. 7 30
      src/layout/login/login-1.vue
  22. 1 1
      src/layout/login/login-2.vue
  23. 61 0
      src/layout/login/login-3.vue
  24. 61 0
      src/layout/login/login-4.vue
  25. 21 24
      src/layout/login/register-1.vue
  26. 0 91
      src/layout/patent/info-1.vue
  27. 0 98
      src/layout/patent/list-2.vue
  28. 0 103
      src/layout/patent/trans-1.vue
  29. 529 0
      src/layout/patentInfo/form-1.vue
  30. 97 0
      src/layout/patentInfo/info-1.vue
  31. 19 6
      src/layout/patent/list-1.vue
  32. 148 0
      src/layout/patentInfo/search-1.vue
  33. 209 0
      src/layout/patentInfo/trans-1.vue
  34. 84 0
      src/layout/question/assign-1.vue
  35. 105 0
      src/layout/question/form-1.vue
  36. 89 0
      src/layout/question/info-1.vue
  37. 98 0
      src/layout/question/list-1.vue
  38. 113 0
      src/layout/question/list-2.vue
  39. 104 0
      src/layout/question/upload-1.vue
  40. 3 3
      src/layout/trans/contract-1.vue
  41. 0 1
      src/layout/trans/endtrans-1.vue
  42. 72 0
      src/layout/trans/examine-1.vue
  43. 9 11
      src/layout/trans/form-1.vue
  44. 37 15
      src/layout/trans/info-1.vue
  45. 48 17
      src/layout/trans/list-1.vue
  46. 4 17
      src/layout/trans/list-2.vue
  47. 0 115
      src/layout/trans/list-3.vue
  48. 56 0
      src/layout/trans/result-1.vue
  49. 88 59
      src/router/index.js
  50. 11 0
      src/store/index.js
  51. 0 93
      src/views/account/adminCenter/users/detail.vue
  52. 0 128
      src/views/account/adminCenter/users/index.vue
  53. 0 77
      src/views/account/adminCenter/users/parts/company-detail.vue
  54. 86 0
      src/views/account/agentmech/detail.vue
  55. 69 0
      src/views/account/agentmech/index.vue
  56. 65 0
      src/views/account/agentmech/parts/form-1.vue
  57. 8 12
      src/views/account/userCenter/parts/user-1.vue
  58. 19 24
      src/views/patent/admin/patent/info_create.vue
  59. 69 0
      src/views/account/answertea/index.vue
  60. 74 0
      src/views/account/answertea/parts/form-1.vue
  61. 16 14
      src/views/account/adminCenter/users/parts/personal-1.vue
  62. 51 0
      src/views/account/basic/index.vue
  63. 68 0
      src/views/account/basic/parts/info-1.vue
  64. 87 0
      src/views/account/basic/parts/info-3.vue
  65. 68 0
      src/views/account/basic/parts/info-4.vue
  66. 83 0
      src/views/account/basic/parts/info-5.vue
  67. 25 39
      src/views/account/index.vue
  68. 0 108
      src/views/account/mechCenter/users/detail.vue
  69. 0 110
      src/views/account/mechCenter/users/index.vue
  70. 0 88
      src/views/account/mechCenter/users/parts/company-1.vue
  71. 0 77
      src/views/account/mechCenter/users/parts/company-detail.vue
  72. 0 84
      src/views/account/mechCenter/users/parts/personal-detail.vue
  73. 2 2
      src/views/account/adminCenter/mechanism/detail.vue
  74. 10 10
      src/views/account/adminCenter/mechanism/index.vue
  75. 0 0
      src/views/account/mechanism/parts/detail_1.vue
  76. 13 4
      src/views/account/adminCenter/mechanism/parts/list_1.vue
  77. 0 48
      src/views/account/parts/role-1.vue
  78. 0 47
      src/views/account/parts/role-2.vue
  79. 0 43
      src/views/account/parts/role-3.vue
  80. 9 2
      src/views/account/userCenter/password/index.vue
  81. 11 8
      src/views/account/mechCenter/patent/index.vue
  82. 0 0
      src/views/account/patent/parts/info-1.vue
  83. 0 0
      src/views/account/patent/parts/list-1.vue
  84. 0 105
      src/views/account/userCenter/basic/index.vue
  85. 0 72
      src/views/account/userCenter/parts/basic-1.vue
  86. 0 104
      src/views/account/userCenter/parts/company-1.vue
  87. 19 13
      src/views/market/patentInfo/detail.vue
  88. 1 1
      src/views/account/adminCenter/users/import_user.vue
  89. 94 0
      src/views/account/users/index.vue
  90. 0 0
      src/views/account/users/parts/importForm-1.vue
  91. 6 10
      src/views/account/mechCenter/users/parts/personal-1.vue
  92. 19 9
      src/views/account/adminCenter/users/parts/personal-detail.vue
  93. 10 0
      src/views/login.vue
  94. 14 27
      src/views/market/patentInfo/index.vue
  95. 0 81
      src/views/market/patentInfo/parts/info-1.vue
  96. 0 82
      src/views/market/patentInfo/parts/list-1.vue
  97. 0 107
      src/views/market/patentInfo/parts/search-1.vue
  98. 0 63
      src/views/market/transfer/detail.vue
  99. 28 10
      src/views/market/transfer/index.vue
  100. 0 0
      src/views/market/transfer/parts/info-1.vue

+ 64 - 73
src/layout/analysis/form-1.vue

@@ -2,59 +2,35 @@
   <div id="form-1">
     <van-row>
       <van-col span="24" class="main">
-        <van-form @submit="onSubmit">
-          <van-field v-model="form.name" name="name" label="发明名称" placeholder="发明名称" :rules="[{ required: true, message: '发明名称' }]" />
-          <van-field v-model="form.apply_name" name="apply_name" label="申请人" placeholder="申请人" :rules="[{ required: true, message: '申请人' }]" />
-          <van-field
-            readonly
-            clickable
-            name="type"
-            :value="form.type"
-            label="选择类型"
-            placeholder="点击选择"
-            @click="typePicker = true"
-            :rules="[{ required: true, message: '专利类型' }]"
-          />
-          <van-popup v-model="typePicker" position="bottom">
-            <van-picker show-toolbar :columns="typeList" @confirm="typeCon" @cancel="typePicker = false" />
-          </van-popup>
-          <van-field v-model="form.inventor" name="inventor" label="发明人" placeholder="发明人" :rules="[{ required: true, message: '发明人' }]" />
-          <van-field v-model="form.contact" name="contact" label="技术联系人" placeholder="技术联系人" :rules="[{ required: true, message: '技术联系人' }]" />
-          <van-field v-model="form.phone" name="phone" label="联系人电话" placeholder="联系人电话" :rules="[{ required: true, message: '联系人电话' }]" />
-          <van-field v-model="form.email" name="email" label="联系人邮箱" placeholder="联系人邮箱" :rules="[{ required: true, message: '联系人邮箱' }]" />
-          <van-field v-model="form.questions.q8" type="textarea" rows="1" autosize name="特殊情况说明" label="特殊情况说明" placeholder="特殊情况说明" />
-          <van-field v-model="form.questions.q1" type="textarea" rows="1" autosize label="本发明的技术领域" placeholder="本发明的技术领域" />
-          <van-field v-model="form.questions.q2" type="textarea" rows="1" autosize label="与本发明相关的背景技术" placeholder="与本发明相关的背景技术" />
-          <van-field
-            v-model="form.questions.q3"
-            type="textarea"
-            rows="1"
-            autosize
-            label="现有技术的缺点及本发明所要解决的技术问题"
-            placeholder="现有技术的缺点及本发明所要解决的技术问题"
-          />
-          <van-field v-model="form.questions.q4" type="textarea" rows="1" autosize label="本发明技术方案的详细阐述" placeholder="本发明技术方案的详细阐述" />
-          <van-field v-model="form.questions.q5" type="textarea" rows="1" autosize label="本申请的关键点和欲保护点" placeholder="本申请的关键点和欲保护点" />
-          <van-field
-            v-model="form.questions.q6"
-            type="textarea"
-            rows="1"
-            autosize
-            label="与本发明最相似,相近的实现技术,方案相比,本发明有何优点"
-            placeholder="与本发明最相似,相近的实现技术,方案相比,本发明有何优点"
-          />
-          <van-field
-            v-model="form.questions.q7"
-            type="textarea"
-            rows="1"
-            autosize
-            label="针对本发明技术方案,是否还有别的替代方案"
-            placeholder="针对本发明技术方案,是否还有别的替代方案"
-          />
-          <div style="margin: 16px">
-            <van-button round block type="info" native-type="submit">提交</van-button>
-          </div>
-        </van-form>
+        <van-col span="24" class="one">
+          <van-form @submit="onSubmit">
+            <van-field v-model="form.name" name="name" label="发明名称" placeholder="发明名称" :rules="[{ required: true, message: '发明名称' }]" />
+            <van-field v-model="form.apply_name" name="apply_name" label="申请人" placeholder="申请人" :rules="[{ required: true, message: '申请人' }]" />
+            <van-field name="type" label="专利类型" :rules="[{ required: true, message: '请填写专利类型' }]">
+              <template #input>
+                <van-radio-group v-model="form.type" direction="horizontal">
+                  <van-radio name="发明申请">发明申请</van-radio>
+                  <van-radio name="实用新型">实用新型</van-radio>
+                </van-radio-group>
+              </template>
+            </van-field>
+            <van-field v-model="form.inventor" name="inventor" label="发明人" placeholder="发明人" :rules="[{ required: true, message: '发明人' }]" />
+            <van-field v-model="form.contact" name="contact" label="技术联系人" placeholder="技术联系人" :rules="[{ required: true, message: '技术联系人' }]" />
+            <van-field v-model="form.phone" name="phone" label="联系人电话" placeholder="联系人电话" :rules="[{ required: true, message: '联系人电话' }]" />
+            <van-field v-model="form.email" name="email" label="联系人邮箱" placeholder="联系人邮箱" :rules="[{ required: true, message: '联系人邮箱' }]" />
+            <van-field v-model="form.questions.q1" type="textarea" autosize name="特殊情况说明" label="特殊情况说明" placeholder="特殊情况说明" />
+            <van-field v-model="form.questions.q2" type="textarea" autosize label="本发明的技术领域" placeholder="本发明的技术领域" />
+            <van-field v-model="form.questions.q3" type="textarea" autosize label="与本发明相关的背景技术" placeholder="与本发明相关的背景技术" />
+            <van-field v-model="form.questions.q4" type="textarea" autosize label="现有技术的缺点及本发明所要解决的技术问题" />
+            <van-field v-model="form.questions.q5" type="textarea" autosize label="本发明技术方案的详细阐述" />
+            <van-field v-model="form.questions.q6" type="textarea" autosize label="本申请的关键点和欲保护点" />
+            <van-field v-model="form.questions.q7" type="textarea" autosize label="与本发明最相似,相近的实现技术,方案相比,本发明有何优点" />
+            <van-field v-model="form.questions.q8" type="textarea" autosize label="针对本发明技术方案,是否还有别的替代方案" />
+            <van-col span="24" style="text-align: center; margin: 10px 0">
+              <van-button type="info" size="small" native-type="submit">提交申请</van-button>
+            </van-col>
+          </van-form>
+        </van-col>
       </van-col>
     </van-row>
   </div>
@@ -63,40 +39,55 @@
 <script>
 import { mapState, createNamespacedHelpers } from 'vuex';
 const { mapActions: adminLogin } = createNamespacedHelpers('adminLogin');
+const { mapActions: patentanalysis } = createNamespacedHelpers('patentanalysis');
 export default {
   name: 'form-1',
-  props: {
-    form: { type: Object },
-  },
+  props: {},
   components: {},
   data: function () {
     return {
       // 管理员信息
       adminInfo: {},
-      // 申请类型
-      typePicker: false,
-      typeList: ['发明', '实用新型', '其他'],
+      form: { questions: {} },
     };
   },
   created() {
-    this.search();
+    this.searchOther();
   },
   methods: {
-    ...adminLogin(['query']),
-    async search() {
-      let res = await this.query({ code: 'JLKJQY' });
-      if (this.$checkRes(res)) {
-        this.$set(this, `adminInfo`, res.data[0]);
-        this.$set(this.form, `admin_id`, this.adminInfo._id);
+    ...adminLogin({ adminQuery: 'query' }),
+    ...patentanalysis(['query', 'fetch', 'create', 'update']),
+    async onSubmit(values) {
+      if (values) {
+        let data = this.form;
+        if (data.id) {
+          console.log(data);
+        } else {
+          let res = await this.create(data);
+          if (this.$checkRes(res)) {
+            this.$toast({ type: `success`, message: `操作成功` });
+            this.searchOther();
+          }
+        }
       }
     },
-    onSubmit(value) {
-      if (value) this.$emit('onSubmit', { data: this.form });
-    },
-    // 选择类型
-    typeCon(value) {
-      this.$set(this.form, `type`, value);
-      this.typePicker = false;
+    async searchOther() {
+      let res = await this.adminQuery({ code: 'JLKQadmin' });
+      if (this.$checkRes(res)) this.$set(this, `adminInfo`, res.data[0]);
+      let data = {
+        user_id: this.user._id,
+        user_name: this.user.name,
+        admin_id: this.adminInfo.id,
+        admin_name: this.adminInfo.name,
+        apply_name: this.user.name,
+        inventor: this.user.name,
+        contact: this.user.name,
+        phone: this.user.phone,
+        email: this.user.email,
+        questions: {},
+        status: '0',
+      };
+      this.$set(this, `form`, data);
     },
   },
   computed: {

+ 18 - 6
src/layout/analysis/list-1.vue

@@ -8,18 +8,22 @@
           </van-col>
           <van-col span="24" class="other">
             <van-col span="24" class="otherInfo">
-              申请类型:<span>{{ item.type || '暂无' }}</span>
+              专利类型:<span>{{ item.type || '暂无' }}</span>
             </van-col>
             <van-col span="24" class="otherInfo">
               申请状态:<span>{{ getStu(item.status) }}</span>
             </van-col>
           </van-col>
           <van-col span="24" class="btn">
-            <van-button size="small" type="info" @click="toView(item)">查看信息</van-button>
-            <van-button size="small" type="info" @click="toResult(item)">审核结果</van-button>
-            <van-button size="small" type="info" @click="download(item.file)" v-if="item.status == '2'">报告文件</van-button>
-            <!-- <van-button size="small" type="info" @click="result(item)">查看审核结果</van-button> -->
-            <!-- <van-button size="small" type="info" @click="downFile(item.file)" v-if="item.status == '2'">报告文件</van-button> -->
+            <van-button size="small" type="info" @click="toView(item)">详细信息</van-button>
+            <template v-if="user.role == '1'">
+              <van-button size="small" type="info" @click="toCheck(item)" v-if="item.status == '0'">申请审核</van-button>
+              <van-button size="small" type="info" @click="toFile(item)" v-if="item.status == '1'">报告文件</van-button>
+            </template>
+            <template v-else-if="user.role == '3'">
+              <van-button size="small" type="info" @click="toResult(item)">审核结果</van-button>
+              <van-button size="small" type="info" @click="download(item.file)" v-if="item.status == '2'">报告文件</van-button>
+            </template>
           </van-col>
         </van-col>
       </van-col>
@@ -48,6 +52,14 @@ export default {
     toResult(data) {
       this.$emit('toResult', data);
     },
+    // 申请审核
+    toCheck(data) {
+      this.$emit('toCheck', data);
+    },
+    // 报告文件
+    toFile(data) {
+      this.$emit('toFile', data);
+    },
     // 下载文件
     download(data) {
       if (data.length > 0) {

+ 0 - 109
src/layout/analysis/list-2.vue

@@ -1,109 +0,0 @@
-<template>
-  <div id="list-2">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-col span="24" class="list" v-for="(item, index) in list" :key="index">
-          <van-col span="24" class="title textOver">
-            {{ item.name }}
-          </van-col>
-          <van-col span="24" class="other">
-            <van-col span="24" class="otherInfo">
-              申请类型:<span>{{ item.type || '暂无' }}</span>
-            </van-col>
-            <van-col span="24" class="otherInfo">
-              申请状态:<span>{{ getStu(item.status) }}</span>
-            </van-col>
-          </van-col>
-          <van-col span="24" class="btn">
-            <van-button size="small" type="info" @click="toView(item)">查看信息</van-button>
-            <van-button size="small" type="info" @click="toCheck(item)" v-if="item.status == '0'">申请审核</van-button>
-            <van-button size="small" type="info" @click="toFile(item)" v-if="item.status == '1'">报告文件</van-button>
-          </van-col>
-        </van-col>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'list-2',
-  props: {
-    list: { type: Array },
-  },
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    // 查看信息
-    toView(data) {
-      this.$emit('toView', data);
-    },
-    // 申请审核
-    toCheck(data) {
-      this.$emit('toCheck', data);
-    },
-    // 报告文件
-    toFile(data) {
-      this.$emit('toFile', data);
-    },
-    // 整理状态
-    getStu(status) {
-      if (status == '0') return '待审中';
-      else if (status == '1') return '审核通过,待发报告文件';
-      else if (status == '-1') return '审核未通过!';
-      else if (status == '2') return '文件已发放';
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  padding: 8px 8px 0 8px;
-  .list {
-    background-color: #fff;
-    margin: 0 0 8px 0;
-    padding: 8px;
-    border-radius: 5px;
-    .title {
-      font-size: 16px;
-      font-weight: bold;
-      margin: 0 0 5px 0;
-    }
-    .other {
-      margin: 0 0 5px 0;
-      .otherInfo {
-        font-size: 14px;
-        color: #666;
-        margin: 0 0 5px 0;
-        span {
-          color: #000;
-        }
-      }
-    }
-    .btn {
-      text-align: center;
-      .van-button {
-        margin: 0 5px;
-      }
-    }
-  }
-}
-</style>

+ 5 - 5
src/layout/apply/check-2.vue

@@ -1,16 +1,16 @@
 <template>
-  <div id="check-2">
+  <div id="check-1">
     <van-row>
       <van-col span="24" class="main">
         <van-col span="24" class="one">
           <van-form @submit="onSubmit">
             <van-field v-model="form.id" name="id" label="数据id" readonly style="display: none" />
-            <van-field v-model="form.name" name="name" label="发明名称" readonly />
+            <van-field v-model="form.name" name="name" label="专利名称" readonly />
             <van-field name="status" label="审核状态">
               <template #input>
                 <van-radio-group v-model="form.status" direction="horizontal">
-                  <van-radio name="2">通过</van-radio>
-                  <van-radio name="-2">拒绝</van-radio>
+                  <van-radio name="6">通过</van-radio>
+                  <van-radio name="-6">拒绝</van-radio>
                 </van-radio-group>
               </template>
             </van-field>
@@ -39,7 +39,7 @@
 <script>
 import { mapState, createNamespacedHelpers } from 'vuex';
 export default {
-  name: 'check-2',
+  name: 'check-1',
   props: {
     form: { type: Object },
   },

+ 4 - 4
src/layout/apply/check-3.vue

@@ -1,16 +1,16 @@
 <template>
-  <div id="check-3">
+  <div id="check-1">
     <van-row>
       <van-col span="24" class="main">
         <van-col span="24" class="one">
           <van-form @submit="onSubmit">
             <van-field v-model="form.id" name="id" label="数据id" readonly style="display: none" />
-            <van-field v-model="form.name" name="name" label="发明名称" readonly />
+            <van-field v-model="form.name" name="name" label="专利名称" readonly />
             <van-field name="status" label="审核状态">
               <template #input>
                 <van-radio-group v-model="form.status" direction="horizontal">
                   <van-radio name="4">通过</van-radio>
-                  <van-radio name="-3">拒绝</van-radio>
+                  <van-radio name="-4">拒绝</van-radio>
                 </van-radio-group>
               </template>
             </van-field>
@@ -39,7 +39,7 @@
 <script>
 import { mapState, createNamespacedHelpers } from 'vuex';
 export default {
-  name: 'check-3',
+  name: 'check-1',
   props: {
     form: { type: Object },
   },

+ 0 - 76
src/layout/apply/agent-1.vue

@@ -1,76 +0,0 @@
-<template>
-  <div id="agent-1">
-    <el-row>
-      <el-col :span="24" class="main">
-        <van-col span="24" class="one">
-          <van-form @submit="onSubmit">
-            <van-field v-model="form.status" name="status" label="数据状态" readonly style="display: none" />
-            <van-field v-model="form.id" name="id" label="数据id" readonly style="display: none" />
-            <van-field name="agent_url" label="文件" :rules="[{ required: true, message: '上传文件' }]">
-              <template #input>
-                <van-uploader
-                  :fileList="form.agent_url"
-                  :max-count="1"
-                  :after-read="(file) => toUpload(file, 'agent_url')"
-                  @delete="(file) => toDelete(file, 'agent_url')"
-                  accept="file"
-                />
-              </template>
-            </van-field>
-            <div style="margin: 16px">
-              <van-button round block type="info" native-type="submit">提交</van-button>
-            </div>
-          </van-form>
-        </van-col>
-      </el-col>
-    </el-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: upload } = createNamespacedHelpers('upload');
-export default {
-  name: 'agent-1',
-  props: {
-    form: { type: Object },
-  },
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    ...upload(['upload']),
-    onSubmit(value) {
-      this.$emit('onSubmit', value);
-    },
-    async toUpload({ file }, model) {
-      // 上传,赋值
-      const res = await this.upload({ file, dir: 'apply' });
-      if (this.$checkRes(res)) {
-        this.$set(this.form, model, [{ name: res.name, url: res.uri }]);
-      }
-    },
-    toDelete(file, model) {
-      const index = this.form[model].findIndex((f) => _.isEqual(f, file));
-      this.form[model].splice(index, 1);
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 1 - 1
src/layout/apply/check-1.vue

@@ -5,7 +5,7 @@
         <van-col span="24" class="one">
           <van-form @submit="onSubmit">
             <van-field v-model="form.id" name="id" label="数据id" readonly style="display: none" />
-            <van-field v-model="form.name" name="name" label="发明名称" readonly />
+            <van-field v-model="form.name" name="name" label="专利名称" readonly />
             <van-field name="status" label="审核状态">
               <template #input>
                 <van-radio-group v-model="form.status" direction="horizontal">

+ 92 - 95
src/layout/apply/form-1.vue

@@ -2,38 +2,29 @@
   <div id="form-1">
     <van-row>
       <van-col span="24" class="main">
-        <van-col :span="24" class="one">
-          <van-form @submit="onSubmit">
-            <van-col :span="24" class="remark">申请专利时如需所在学校机构进行审核,请选择是;如不需要请选择否;</van-col>
-            <van-field name="is_mech" label="是否需要机构" :rules="[{ required: true, message: '请选择' }]">
-              <template #input>
-                <van-radio-group v-model="form.is_mech" direction="horizontal">
-                  <van-radio name="1">是</van-radio>
-                  <van-radio name="0">否</van-radio>
-                </van-radio-group>
-              </template>
-            </van-field>
+        <van-col span="24" class="one">
+          <van-form @submit="onSubmit" label-width="5em">
+            <van-field v-model="form.mech_id" name="mech_id" label="机构id" style="display: none" />
             <van-field
-              v-if="form.is_mech == '1'"
               readonly
               clickable
-              name="mechanism_name"
-              :value="form.mechanism_name"
+              :value="form.mech_name"
+              name="mech_name"
               label="选择机构"
               placeholder="点击选择"
               @click="oneShow = true"
+              :rules="[{ required: true, message: '请选择' }]"
             />
             <van-popup v-model="oneShow" position="bottom">
-              <van-picker show-toolbar :columns="mechanismList" value-key="deptname" @confirm="oneCom" @cancel="oneShow = false" />
+              <van-picker show-toolbar :columns="mechList" value-key="name" @confirm="oneCom" @cancel="oneShow = false" />
             </van-popup>
-            <van-field v-model="form.name" name="name" label="专利名称" placeholder="专利名称" :rules="[{ required: true, message: '专利名称' }]" />
-            <van-field v-model="form.apply_name" name="apply_name" label="申请人" placeholder="申请人" :rules="[{ required: true, message: '申请人' }]" />
-            <van-field name="type" label="专利类型" :rules="[{ required: true, message: '专利类型' }]">
+            <van-field v-model="form.name" name="name" label="专利名称" placeholder="专利名称" :rules="[{ required: true, message: '请填写专利名称' }]" />
+            <van-field v-model="form.apply_name" name="apply_name" label="申请人" placeholder="申请人" :rules="[{ required: true, message: '请填写申请人' }]" />
+            <van-field name="type" label="专利类型" :rules="[{ required: true, message: '请填写专利类型' }]">
               <template #input>
                 <van-radio-group v-model="form.type" direction="horizontal">
-                  <van-radio name="发明">发明</van-radio>
+                  <van-radio name="发明申请">发明申请</van-radio>
                   <van-radio name="实用新型">实用新型</van-radio>
-                  <van-radio name="其他">其他</van-radio>
                 </van-radio-group>
               </template>
             </van-field>
@@ -63,38 +54,9 @@
                 </van-col>
               </van-col>
             </van-col>
-            <van-field v-model="form.phone" name="phone" label="联系人电话" placeholder="联系人电话" :rules="[{ required: true, message: '联系人电话' }]" />
-            <van-field v-model="form.email" name="email" label="联系人邮箱" placeholder="联系人邮箱" :rules="[{ required: true, message: '联系人邮箱' }]" />
-            <van-field v-model="form.questions.q8" type="textarea" rows="1" autosize name="特殊情况说明" label="特殊情况说明" placeholder="特殊情况说明" />
-            <van-field v-model="form.questions.q1" type="textarea" rows="1" autosize label="本发明的技术领域" placeholder="本发明的技术领域" />
-            <van-field v-model="form.questions.q2" type="textarea" rows="1" autosize label="与本发明相关的背景技术" placeholder="与本发明相关的背景技术" />
-            <van-field
-              v-model="form.questions.q3"
-              type="textarea"
-              rows="1"
-              autosize
-              label="现有技术的缺点及本发明所要解决的技术问题"
-              placeholder="现有技术的缺点及本发明所要解决的技术问题"
-            />
-            <van-field v-model="form.questions.q4" type="textarea" rows="1" autosize label="本发明技术方案的详细阐述" placeholder="本发明技术方案的详细阐述" />
-            <van-field v-model="form.questions.q5" type="textarea" rows="1" autosize label="本申请的关键点和欲保护点" placeholder="本申请的关键点和欲保护点" />
-            <van-field
-              v-model="form.questions.q6"
-              type="textarea"
-              rows="1"
-              autosize
-              label="与本发明最相似,相近的实现技术,方案相比,本发明有何优点"
-              placeholder="与本发明最相似,相近的实现技术,方案相比,本发明有何优点"
-            />
-            <van-field
-              v-model="form.questions.q7"
-              type="textarea"
-              rows="1"
-              autosize
-              label="针对本发明技术方案,是否还有别的替代方案"
-              placeholder="针对本发明技术方案,是否还有别的替代方案"
-            />
-            <van-field name="check_url" label="审查文件" :rules="[{ required: false, message: '审查文件' }]">
+            <van-field v-model="form.phone" name="phone" label="联系电话" placeholder="联系电话" :rules="[{ required: true, message: '请填写联系电话' }]" />
+            <van-field v-model="form.email" name="email" label="电子邮箱" placeholder="电子邮箱" :rules="[{ required: true, message: '请填写电子邮箱' }]" />
+            <van-field name="check_url" label="审查文件" :rules="[{ required: true, message: '审查文件' }]">
               <template #input>
                 <van-uploader
                   :fileList="form.check_url"
@@ -105,8 +67,16 @@
                 />
               </template>
             </van-field>
-            <van-col span="24">
-              <van-button round block type="info" native-type="submit">提交</van-button>
+            <van-field v-model="form.questions.q1" type="textarea" autosize label="特殊情况说明" />
+            <van-field v-model="form.questions.q2" type="textarea" autosize label="本发明的技术领域" />
+            <van-field v-model="form.questions.q3" type="textarea" autosize label="与本发明相关的背景技术" />
+            <van-field v-model="form.questions.q4" type="textarea" autosize label="现有技术的缺点及本发明所要解决的技术问题" />
+            <van-field v-model="form.questions.q5" type="textarea" autosize label="本发明技术方案的详细阐述" />
+            <van-field v-model="form.questions.q6" type="textarea" autosize label="本申请的关键点和欲保护点" />
+            <van-field v-model="form.questions.q7" type="textarea" autosize label="与本发明最相似,相近的实现技术,方案相比,本发明有何优点" />
+            <van-field v-model="form.questions.q8" type="textarea" autosize label="针对本发明技术方案,是否还有别的替代方案" />
+            <van-col span="24" style="text-align: center; margin: 10px 0">
+              <van-button type="info" size="small" native-type="submit">提交申请</van-button>
             </van-col>
           </van-form>
         </van-col>
@@ -156,20 +126,22 @@ import { mapState, createNamespacedHelpers } from 'vuex';
 const { mapActions: adminLogin } = createNamespacedHelpers('adminLogin');
 const { mapActions: personal } = createNamespacedHelpers('personal');
 const { mapActions: upload } = createNamespacedHelpers('upload');
+const { mapActions: patentapply } = createNamespacedHelpers('patentapply');
 
 export default {
   name: 'form-1',
   props: {
-    form: { type: Object },
+    apply_id: { type: String },
   },
   components: {},
   data: function () {
     return {
       // 管理员信息
       adminInfo: {},
+      form: { questions: {} },
       // 机构
-      mechanismList: [],
       oneShow: false,
+      mechList: [],
       // 发明人&技术联系人
       dialog: { show: false, titla: '查询用户', type: '1' },
       type: '',
@@ -182,28 +154,41 @@ export default {
       addForm: {},
     };
   },
+
   async created() {
-    await this.search();
+    await this.searchOther();
     await this.searchUser();
   },
   methods: {
-    ...upload(['upload']),
     ...adminLogin({ adminQuery: 'query' }),
     ...personal({ personalQuery: 'query' }),
-    // 查询信息
-    async search() {
-      let res = await this.adminQuery({ role: '2' });
-      if (this.$checkRes(res)) {
-        let admin = res.data.filter((i) => i.code == 'JLKJQYCGD' || i.code == 'JLKJQYGC');
-        if (admin) this.$set(this, `mechanismList`, admin);
-      }
-      // 查询管理员信息
-      res = await this.adminQuery({ code: 'JLKJQY' });
-      if (this.$checkRes(res)) {
-        this.$set(this, `adminInfo`, res.data[0]);
-        this.$set(this.form, `admin_id`, this.adminInfo._id);
+    ...upload(['upload']),
+    ...patentapply(['fetch', 'create', 'update']),
+    async onSubmit(values) {
+      if (values) {
+        let data = this.form;
+        if (data.id) {
+          if (data.status == '-1') data.status = '0';
+          let res = await this.update(data);
+          if (this.$checkRes(res)) {
+            this.$toast({ type: `success`, message: `操作完成` });
+            this.searchOther();
+          }
+        } else {
+          let res = await this.create(data);
+          if (this.$checkRes(res)) {
+            this.$toast({ type: `success`, message: `操作完成` });
+            this.searchOther();
+          }
+        }
       }
     },
+    // 确认选择机构
+    oneCom(values) {
+      this.$set(this.form, `mech_id`, values.id);
+      this.$set(this.form, `mech_name`, values.name);
+      this.oneShow = false;
+    },
     // 查询用户
     async searchUser({ skip = 0, limit = this.limit, ...info } = {}) {
       if (this.searchName) info.phone = this.searchName;
@@ -213,15 +198,6 @@ export default {
         this.$set(this, `total`, res.total);
       }
     },
-    onSubmit(value) {
-      if (value) this.$emit('onSubmit', { data: this.form });
-    },
-    // 确认选择机构
-    oneCom(value) {
-      this.$set(this.form, `mechanism_name`, value.name);
-      this.$set(this.form, `mechanism_id`, value._id);
-      this.oneShow = false;
-    },
     // 发明人,技术联系人
     toSelect(type) {
       this.$set(this, `type`, type);
@@ -233,26 +209,52 @@ export default {
       let user = { user_id: data.id, name: data.name };
       if (this.type == 'inventor') this.form.inventor.push(user);
       else if (this.type == 'contact') this.form.contact.push(user);
-      let dialog = { show: false, title: '查询用户', type: '1' };
-      this.$set(this, `dialog`, dialog);
+      this.dialog = { show: false, title: '查询用户', type: '1' };
     },
     // 添加发明人&技术联系人
     toAdd(type) {
       this.$set(this, `type`, type);
-      let dialog = { show: true, title: '添加用户', type: '2' };
-      this.$set(this, `dialog`, dialog);
+      this.dialog = { show: true, title: '添加用户', type: '2' };
     },
     // 确认添加
     userSubmit(value) {
       if (this.type == 'inventor') this.form.inventor.push(value);
       else if (this.type == 'contact') this.form.contact.push(value);
-      let dialog = { show: false, title: '添加用户', type: '2' };
-      this.$set(this, `dialog`, dialog);
+      this.dialog = { show: false, title: '添加用户', type: '2' };
     },
     // 删除发明人&技术联系人
     delInv(data, type) {
       this.form[type].splice(this.form[type].indexOf(data), 1);
     },
+    // 查询其他信息
+    async searchOther() {
+      // 查询管理员信息
+      let res = await this.adminQuery({ code: 'JLKQadmin' });
+      if (this.$checkRes(res)) this.$set(this, `adminInfo`, res.data[0]);
+      // 查询机构
+      res = await this.adminQuery({ role: '2', pid: this.adminInfo.id });
+      if (this.$checkRes(res)) this.$set(this, `mechList`, res.data);
+      // 查詢用戶
+      let data = {
+        user_id: this.user.id,
+        user_name: this.user.name,
+        apply_name: this.user.name,
+        inventor: [{ user_id: this.user._id, name: this.user.name }],
+        contact: [{ user_id: this.user._id, name: this.user.name }],
+        phone: this.user.phone,
+        email: this.user.email,
+        questions: {},
+      };
+      this.$set(this, `form`, data);
+    },
+    // 用户重申
+    async searchInfo() {
+      let res = await this.fetch(this.apply_id);
+      if (this.$checkRes(res)) {
+        if (res.data.questions == undefined) res.data.questions = {};
+        this.$set(this, `form`, res.data);
+      }
+    },
     async toUpload({ file }, model) {
       // 上传,赋值
       const res = await this.upload({ file, dir: 'file' });
@@ -272,10 +274,12 @@ export default {
     return { title: this.$route.meta.title };
   },
   watch: {
-    test: {
+    apply_id: {
       deep: true,
       immediate: true,
-      handler(val) {},
+      handler(val) {
+        if (val) this.searchInfo();
+      },
     },
   },
 };
@@ -284,13 +288,6 @@ export default {
 <style lang="less" scoped>
 .main {
   .one {
-    .remark {
-      text-align: center;
-      color: #ff0000;
-      padding: 5px 0;
-      font-weight: bold;
-      background-color: #ffffff;
-    }
     .inventor {
       background-color: #ffffff;
       .txt {
@@ -321,7 +318,7 @@ export default {
 }
 .dialog {
   /deep/.van-dialog__content {
-    max-height: 365px;
+    max-height: 350px;
     overflow-y: auto;
   }
   .one {

+ 337 - 0
src/layout/apply/form-2.vue

@@ -0,0 +1,337 @@
+<template>
+  <div id="form-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-col span="24" class="one">
+          <van-form @submit="onSubmit" label-width="5em">
+            <van-field v-model="form.name" name="name" label="专利名称" placeholder="专利名称" :rules="[{ required: true, message: '请填写专利名称' }]" />
+            <van-field v-model="form.apply_name" name="apply_name" label="申请人" placeholder="申请人" :rules="[{ required: true, message: '请填写申请人' }]" />
+            <van-field name="type" label="专利类型" :rules="[{ required: true, message: '请填写专利类型' }]">
+              <template #input>
+                <van-radio-group v-model="form.type" direction="horizontal">
+                  <van-radio name="发明申请">发明申请</van-radio>
+                  <van-radio name="实用新型">实用新型</van-radio>
+                </van-radio-group>
+              </template>
+            </van-field>
+            <van-col span="24" class="inventor">
+              <van-col span="24" class="txt">发明人</van-col>
+              <van-col span="24" class="btn">
+                <van-button type="info" size="small" @click.prevent="toSelect('inventor')">选择发明人</van-button>
+                <van-button type="info" size="small" @click.prevent="toAdd('inventor')">添加发明人</van-button>
+              </van-col>
+              <van-col span="24" class="list">
+                <van-col span="12" class="list_1" v-for="(item, index) in form.inventor" :key="index">
+                  <p class="textOver">{{ index + 1 }}-{{ item.name }}</p>
+                  <van-button type="danger" size="mini" @click.prevent="delInv(item, 'inventor')">删除</van-button>
+                </van-col>
+              </van-col>
+            </van-col>
+            <van-col span="24" class="inventor">
+              <van-col span="24" class="txt">技术联系人</van-col>
+              <van-col span="24" class="btn">
+                <van-button type="info" size="small" @click.prevent="toSelect('contact')">选择技术联系人</van-button>
+                <van-button type="info" size="small" @click.prevent="toAdd('contact')">添加技术联系人</van-button>
+              </van-col>
+              <van-col span="24" class="list">
+                <van-col span="12" class="list_1" v-for="(item, index) in form.contact" :key="index">
+                  <p class="textOver">{{ index + 1 }}-{{ item.name }}</p>
+                  <van-button type="danger" size="mini" @click.prevent="delInv(item, 'contact')">删除</van-button>
+                </van-col>
+              </van-col>
+            </van-col>
+            <van-field v-model="form.phone" name="phone" label="联系电话" placeholder="联系电话" :rules="[{ required: true, message: '请填写联系电话' }]" />
+            <van-field v-model="form.email" name="email" label="电子邮箱" placeholder="电子邮箱" :rules="[{ required: true, message: '请填写电子邮箱' }]" />
+            <van-field name="agent_url" label="申请文件" :rules="[{ required: true, message: '申请文件' }]">
+              <template #input>
+                <van-uploader
+                  :fileList="form.agent_url"
+                  :max-count="1"
+                  :after-read="(file) => toUpload(file, 'agent_url')"
+                  @delete="(file) => toDelete(file, 'agent_url')"
+                  accept="file"
+                />
+              </template>
+            </van-field>
+            <van-field v-model="form.questions.q1" type="textarea" autosize label="特殊情况说明" />
+            <van-field v-model="form.questions.q2" type="textarea" autosize label="本发明的技术领域" />
+            <van-field v-model="form.questions.q3" type="textarea" autosize label="与本发明相关的背景技术" />
+            <van-field v-model="form.questions.q4" type="textarea" autosize label="现有技术的缺点及本发明所要解决的技术问题" />
+            <van-field v-model="form.questions.q5" type="textarea" autosize label="本发明技术方案的详细阐述" />
+            <van-field v-model="form.questions.q6" type="textarea" autosize label="本申请的关键点和欲保护点" />
+            <van-field v-model="form.questions.q7" type="textarea" autosize label="与本发明最相似,相近的实现技术,方案相比,本发明有何优点" />
+            <van-field v-model="form.questions.q8" type="textarea" autosize label="针对本发明技术方案,是否还有别的替代方案" />
+            <van-col span="24" style="text-align: center; margin: 10px 0">
+              <van-button type="info" size="small" native-type="submit">提交申请</van-button>
+            </van-col>
+          </van-form>
+        </van-col>
+      </van-col>
+    </van-row>
+    <van-dialog class="dialog" v-model="dialog.show" :title="dialog.title" :show-confirm-button="false" show-cancel-button>
+      <van-col span="24" class="one" v-if="dialog.type == '1'">
+        <van-col span="24" class="one_1">
+          <van-search v-model="searchName" show-action placeholder="请输入联系电话" @search="searchUser">
+            <template #action>
+              <div @click="searchUser">搜索</div>
+            </template>
+          </van-search>
+        </van-col>
+        <van-col span="24" class="one_2">
+          <van-col span="24" class="list" v-for="(item, index) in list" :key="index">
+            <van-col span="24" class="name"> {{ item.name }} </van-col>
+            <van-col span="24" class="other">
+              <van-col span="24" class="otherInfo">
+                联系电话:<span>{{ item.phone }}</span>
+              </van-col>
+            </van-col>
+            <van-col span="24" class="btn">
+              <van-button type="info" size="mini" @click="conFirm(item)">确认选择</van-button>
+            </van-col>
+          </van-col>
+          <van-col span="24" class="page">
+            <page @search="searchUser" :limit="limit" :total="total"></page>
+          </van-col>
+        </van-col>
+      </van-col>
+      <van-col span="24" class="two" v-else-if="dialog.type == '2'">
+        <van-form @submit="userSubmit">
+          <van-field v-model="addForm.name" name="name" label="姓名" placeholder="姓名" :rules="[{ required: true, message: '姓名' }]" />
+          <van-field v-model="addForm.phone" name="phone" label="联系电话" placeholder="联系电话" :rules="[{ required: true, message: '联系电话' }]" />
+          <van-col span="24" class="btn">
+            <van-button size="small" type="info" native-type="submit">确认添加</van-button>
+          </van-col>
+        </van-form>
+      </van-col>
+    </van-dialog>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: adminLogin } = createNamespacedHelpers('adminLogin');
+const { mapActions: personal } = createNamespacedHelpers('personal');
+const { mapActions: upload } = createNamespacedHelpers('upload');
+const { mapActions: patentapply } = createNamespacedHelpers('patentapply');
+export default {
+  name: 'form-1',
+  props: {
+    apply_id: { type: String },
+  },
+  components: {},
+  data: function () {
+    return {
+      // 管理员信息
+      adminInfo: {},
+      form: { questions: {} },
+      // 发明人&技术联系人
+      dialog: { show: false, titla: '查询用户', type: '1' },
+      type: '',
+      // 查询
+      searchName: '',
+      list: [],
+      limit: 3,
+      total: 0,
+      // 添加发明人&技术联系人
+      addForm: {},
+    };
+  },
+
+  async created() {
+    await this.searchOther();
+    await this.searchUser();
+  },
+  methods: {
+    ...adminLogin({ adminQuery: 'query' }),
+    ...personal({ personalQuery: 'query' }),
+    ...upload(['upload']),
+    ...patentapply(['fetch', 'create', 'update']),
+    async onSubmit(values) {
+      if (values) {
+        let data = this.form;
+        if (data.id) {
+          if (data.status == '-6') data.status = '5';
+          let res = await this.update(data);
+          if (this.$checkRes(res)) {
+            this.$toast({ type: `success`, message: `操作完成` });
+            this.searchOther();
+          }
+        } else {
+          data.status = '5';
+          console.log(data);
+          let res = await this.create(data);
+          if (this.$checkRes(res)) {
+            this.$toast({ type: `success`, message: `操作完成` });
+            this.searchOther();
+          }
+        }
+      }
+    },
+
+    // 查询用户
+    async searchUser({ skip = 0, limit = this.limit, ...info } = {}) {
+      if (this.searchName) info.phone = this.searchName;
+      let res = await this.personalQuery({ skip, limit, code: this.user.code, ...info });
+      if (this.$checkRes(res)) {
+        this.$set(this, `list`, res.data);
+        this.$set(this, `total`, res.total);
+      }
+    },
+    // 发明人,技术联系人
+    toSelect(type) {
+      this.$set(this, `type`, type);
+      let dialog = { show: true, title: '查询用户', type: '1' };
+      this.$set(this, `dialog`, dialog);
+    },
+    // 确认选择
+    conFirm(data) {
+      let user = { user_id: data.id, name: data.name };
+      if (this.type == 'inventor') this.form.inventor.push(user);
+      else if (this.type == 'contact') this.form.contact.push(user);
+      this.dialog = { show: false, title: '查询用户', type: '1' };
+    },
+    // 添加发明人&技术联系人
+    toAdd(type) {
+      this.$set(this, `type`, type);
+      this.dialog = { show: true, title: '添加用户', type: '2' };
+    },
+    // 确认添加
+    userSubmit(value) {
+      if (this.type == 'inventor') this.form.inventor.push(value);
+      else if (this.type == 'contact') this.form.contact.push(value);
+      this.dialog = { show: false, title: '添加用户', type: '2' };
+    },
+    // 删除发明人&技术联系人
+    delInv(data, type) {
+      this.form[type].splice(this.form[type].indexOf(data), 1);
+    },
+    // 查询其他信息
+    async searchOther() {
+      // 查询管理员信息
+      let res = await this.adminQuery({ code: 'JLKQadmin' });
+      if (this.$checkRes(res)) this.$set(this, `adminInfo`, res.data[0]);
+      // 查詢用戶
+      let data = {
+        user_id: this.user.id,
+        user_name: this.user.name,
+        admin_id: this.adminInfo.id,
+        admin_name: this.adminInfo.name,
+        agentmech_id: this.user.id,
+        agentmech_name: this.user.name,
+        apply_name: this.user.name,
+        inventor: [{ user_id: this.user._id, name: this.user.name }],
+        contact: [{ user_id: this.user._id, name: this.user.name }],
+        phone: this.user.phone,
+        email: this.user.email,
+        questions: {},
+      };
+      this.$set(this, `form`, data);
+    },
+    // 用户重申
+    async searchInfo() {
+      let res = await this.fetch(this.apply_id);
+      if (this.$checkRes(res)) {
+        if (res.data.questions == undefined) res.data.questions = {};
+        this.$set(this, `form`, res.data);
+      }
+    },
+    async toUpload({ file }, model) {
+      // 上传,赋值
+      const res = await this.upload({ file, dir: 'file' });
+      if (this.$checkRes(res)) {
+        this.$set(this.form, model, [{ name: res.name, url: res.uri }]);
+      }
+    },
+    toDelete(file, model) {
+      const index = this.form[model].findIndex((f) => _.isEqual(f, file));
+      this.form[model].splice(index, 1);
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    apply_id: {
+      deep: true,
+      immediate: true,
+      handler(val) {
+        if (val) this.searchInfo();
+      },
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped>
+.main {
+  .one {
+    .inventor {
+      background-color: #ffffff;
+      .txt {
+        padding: 5px 0px 0 18px;
+        font-size: 14px;
+        color: #666;
+      }
+      .btn {
+        text-align: center;
+        .van-button {
+          margin: 8px;
+        }
+      }
+      .list {
+        padding: 0px 18px;
+        .list_1 {
+          border: 1px dashed #409eff;
+          margin: 0 0 8px 0;
+          text-align: center;
+          padding: 5px;
+          p {
+            font-size: 14px;
+          }
+        }
+      }
+    }
+  }
+}
+.dialog {
+  /deep/.van-dialog__content {
+    max-height: 350px;
+    overflow-y: auto;
+  }
+  .one {
+    .one_2 {
+      .list {
+        border-bottom: 1px dashed #ccc;
+        margin: 0 0 8px 0;
+        padding: 0 8px 5px 8px;
+        .name {
+          font-size: 16px;
+          margin: 0 0 5px 0;
+        }
+        .other {
+          margin: 0 0 5px 0;
+          .otherInfo {
+            font-size: 14px;
+            color: #666;
+            span {
+              color: #000;
+            }
+          }
+        }
+        .btn {
+          text-align: center;
+        }
+      }
+    }
+  }
+  .two {
+    .btn {
+      margin: 8px 0;
+      text-align: center;
+    }
+  }
+}
+</style>

+ 16 - 14
src/layout/apply/info-1.vue

@@ -4,23 +4,23 @@
       <van-col span="24" class="main">
         <van-col span="24" class="one">
           <van-form>
-            <van-field v-model="info.is_mech" name="is_mech" label="是否需要机构" readonly />
-            <van-field v-model="info.mechanism_name" name="mechanism_name" label="机构" readonly />
+            <van-field v-model="info.mech_name" name="mech_name" label="机构名称" readonly />
+            <van-field v-model="info.create_number" name="create_number" label="申请号" readonly />
+            <van-field v-model="info.name" name="name" label="专利名称" readonly />
             <van-field v-model="info.apply_name" name="apply_name" label="申请人" readonly />
             <van-field v-model="info.type" name="type" label="专利类型" readonly />
             <van-field v-model="info.inventor" name="inventor" label="发明人" readonly />
             <van-field v-model="info.contact" name="contact" label="技术联系人" readonly />
-            <van-field v-model="info.phone" name="phone" label="联系人电话" readonly />
-            <van-field v-model="info.email" name="email" label="联系人邮箱" readonly />
-            <van-field v-model="info.name" name="name" label="专利名称" readonly />
-            <van-field v-model="info.questions.q8" type="textarea" rows="1" autosize label="特殊情况说明" readonly />
-            <van-field v-model="info.questions.q1" type="textarea" rows="1" autosize label="本发明的技术领域" readonly />
-            <van-field v-model="info.questions.q2" type="textarea" rows="1" autosize label="与本发明相关的背景技术" readonly />
-            <van-field v-model="info.questions.q3" type="textarea" rows="1" autosize label="现有技术的缺点及本发明所要解决的技术问题" readonly />
-            <van-field v-model="info.questions.q4" type="textarea" rows="1" autosize label="本发明技术方案的详细阐述" readonly />
-            <van-field v-model="info.questions.q5" type="textarea" rows="1" autosize label="本申请的关键点和欲保护点" readonly />
-            <van-field v-model="info.questions.q6" type="textarea" rows="1" autosize label="与本发明最相似,相近的实现技术,方案相比,本发明有何优点" readonly />
-            <van-field v-model="info.questions.q7" type="textarea" rows="1" autosize label="针对本发明技术方案,是否还有别的替代方案" readonly />
+            <van-field v-model="info.phone" name="phone" label="联系电话" readonly />
+            <van-field v-model="info.email" name="email" label="电子邮箱" readonly />
+            <van-field v-model="info.questions.q1" type="textarea" rows="1" autosize label="特殊情况说明" readonly />
+            <van-field v-model="info.questions.q2" type="textarea" rows="1" autosize label="本发明的技术领域" readonly />
+            <van-field v-model="info.questions.q3" type="textarea" rows="1" autosize label="与本发明相关的背景技术" readonly />
+            <van-field v-model="info.questions.q4" type="textarea" rows="1" autosize label="现有技术的缺点及本发明所要解决的技术问题" readonly />
+            <van-field v-model="info.questions.q5" type="textarea" rows="1" autosize label="本发明技术方案的详细阐述" readonly />
+            <van-field v-model="info.questions.q6" type="textarea" rows="1" autosize label="本申请的关键点和欲保护点" readonly />
+            <van-field v-model="info.questions.q7" type="textarea" rows="1" autosize label="与本发明最相似,相近的实现技术,方案相比,本发明有何优点" readonly />
+            <van-field v-model="info.questions.q8" type="textarea" rows="1" autosize label="针对本发明技术方案,是否还有别的替代方案" readonly />
           </van-form>
         </van-col>
       </van-col>
@@ -33,7 +33,9 @@ import { mapState, createNamespacedHelpers } from 'vuex';
 export default {
   name: 'info-1',
   props: {
-    info: { type: Object },
+    info: {
+      type: Object,
+    },
   },
   components: {},
   data: function () {

+ 71 - 24
src/layout/apply/list-1.vue

@@ -7,9 +7,6 @@
             {{ item.name }}
           </van-col>
           <van-col span="24" class="other">
-            <!-- <van-col span="24" class="otherInfo">
-              专利用户码:<span>{{ item.water_number || '暂无' }}</span>
-            </van-col> -->
             <van-col span="24" class="otherInfo">
               申请类型:<span>{{ item.type || '暂无' }}</span>
             </van-col>
@@ -18,11 +15,34 @@
             </van-col>
           </van-col>
           <van-col span="24" class="btn">
-            <van-button size="small" type="info" @click="toView(item)">查看信息</van-button>
-            <van-button size="small" type="info" @click="toResult(item)">审核结果</van-button>
-            <van-button size="small" type="info" @click="toAgain(item)" v-if="item.status == '-1' || item.status == '-2'">重申</van-button>
-            <van-button size="small" type="info" @click="toAgent(item)" v-if="item.status == '2' || item.status == '-3'">申请文件</van-button>
-            <van-button size="small" type="info" @click="toGzj(item)">国知局反馈信息</van-button>
+            <van-button type="info" size="small" @click="toView(item)">详细信息</van-button>
+            <template v-if="user.role == '1'">
+              <van-button type="info" size="small" @click="download(item.agent_url)">申请文件</van-button>
+              <van-button type="info" size="small" @click="toAccept(item)" v-if="item.status == '2' || item.status == '5'">受理</van-button>
+              <van-button type="info" size="small" @click="gzjSubmit(item)" v-if="item.status == '6'">确认上传</van-button>
+            </template>
+            <template v-else-if="user.role == '2'">
+              <van-button type="info" size="small" @click="download(item.check_url)">审查文件</van-button>
+              <van-button type="info" size="small" @click="fileCheck(item)" v-if="item.status == '0'">文件审批</van-button>
+              <van-button size="small" type="info" v-if="item.status == '7'" @click="toGzj(item)">国知局反馈信息</van-button>
+            </template>
+            <template v-else-if="user.role == '3'">
+              <van-button size="small" type="info" v-if="item.status == '7'" @click="toGzj(item)">国知局反馈信息</van-button>
+              <van-button type="info" size="small" @click="toResult(item)">审核结果</van-button>
+              <van-button type="info" size="small" @click="toHeavy(item)" v-if="item.status == '-1'">重申</van-button>
+              <van-button type="info" size="small" @click="selectMech(item)" v-if="item.status == '1' || item.status == '-4' || item.status == '-6'"
+                >选择代理机构</van-button
+              >
+            </template>
+            <template v-else-if="user.role == '4'">
+              <van-button size="small" type="info" v-if="item.status == '7'" @click="toGzj(item)">国知局反馈信息</van-button>
+              <!-- <van-button type="info" size="small" @click="toResult(item)">审核结果</van-button> -->
+              <van-button type="info" size="small" @click="download(item.agent_url)">申请文件</van-button>
+              <van-button type="info" size="small" @click="toAccept(item)" v-if="item.status == '3'">受理</van-button>
+              <van-button type="info" size="small" @click="toOneself(item, '-5')" v-if="item.status == '4'">自行上报</van-button>
+              <van-button type="info" size="small" @click="toOneself(item, '5')" v-if="item.status == '4'">科企上报</van-button>
+              <van-button type="info" size="small" @click="toHeavy(item)" v-if="item.status == '-6'">重申</van-button>
+            </template>
           </van-col>
         </van-col>
       </van-col>
@@ -43,37 +63,64 @@ export default {
   },
   created() {},
   methods: {
-    // 查看信息
+    // 详细信息
     toView(data) {
       this.$emit('toView', data);
     },
-    // 审核结果
+    // 科企受理
+    toAccept(data) {
+      this.$emit('toAccept', data);
+    },
+    // 机构文件审批
+    fileCheck(data) {
+      this.$emit('fileCheck', data);
+    },
+    // 用户查看审核结果
     toResult(data) {
       this.$emit('toResult', data);
     },
-    // 重审
-    toAgain(data) {
-      this.$emit('toAgain', data);
+    // 用户重申
+    toHeavy(data) {
+      this.$emit('toHeavy', data);
+    },
+    // 用户选择代理机构
+    selectMech(data) {
+      this.$emit('selectMech', data);
     },
-    // 申请文件
-    toAgent(data) {
-      this.$emit('toAgent', data);
+    // 确认上传国知局
+    gzjSubmit(data) {
+      this.$emit('gzjSubmit', data);
+    },
+    // 代理机构自行上报
+    toOneself(data, status) {
+      this.$emit('toOneself', { data, status });
     },
     // 国知局反馈信息
     toGzj(data) {
       this.$emit('toGzj', data);
     },
+    // 审查文件下载
+    download(data) {
+      if (data.length > 0) {
+        let url = data.map((i) => i.url);
+        window.location.href = `${process.env.VUE_APP_HOST}${url[0]}`;
+      } else {
+        this.$toast({ type: `fail`, message: `未上传文件` });
+      }
+    },
     // 整理状态
     getStu(status) {
       if (status == '0') return '待审中';
-      else if (status == '1') return '机构审批通过,待管理员受理';
-      else if (status == '-1') return '机构审核未通过';
-      else if (status == '2') return '已通过管理员受理,请及时上传申请文件';
-      else if (status == '-2') return '未通过管理员受理';
-      else if (status == '3') return '文件已上传,待形式审查';
-      else if (status == '-3') return '未通过管理员形式审查';
-      else if (status == '4') return '通过管理员形式审查,待上传国知局';
-      else if (status == '5') return '已上传到国知局';
+      else if (status == '1') return '机构审批通过';
+      else if (status == '-1') return '机构审批未通过';
+      else if (status == '2' || status == '3') return '已选机构,待受理';
+      else if (status == '4') return '代理机构已受理';
+      else if (status == '-4') return '代理机构拒绝受理';
+      else if (status == '5') return '代理机构推送科企机构,待科企机构受理';
+      else if (status == '-5') return '代理机构自行上报';
+      else if (status == '6') return '机构已受理,待上报国知局';
+      else if (status == '-6') return '机构未受理,请重新选择机构';
+      else if (status == '7') return '已上报国知局';
     },
   },
   computed: {

+ 0 - 122
src/layout/apply/list-2.vue

@@ -1,122 +0,0 @@
-<template>
-  <div id="list-2">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-col span="24" class="list" v-for="(item, index) in list" :key="index">
-          <van-col span="24" class="title textOver">
-            {{ item.name }}
-          </van-col>
-          <van-col span="24" class="other">
-            <!-- <van-col span="24" class="otherInfo">
-              专利用户码:<span>{{ item.water_number || '暂无' }}</span>
-            </van-col> -->
-            <van-col span="24" class="otherInfo">
-              申请类型:<span>{{ item.type || '暂无' }}</span>
-            </van-col>
-            <van-col span="24" class="otherInfo">
-              申请状态:<span>{{ getStu(item.status) }}</span>
-            </van-col>
-          </van-col>
-          <van-col span="24" class="btn">
-            <van-button size="small" type="info" @click="toView(item)">查看信息</van-button>
-            <van-button size="small" type="info" @click="download(item.check_url)">审查文件</van-button>
-            <van-button size="small" type="info" @click="toCheck(item)" v-if="item.status == '0'">申请审批</van-button>
-          </van-col>
-        </van-col>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'list-2',
-  props: {
-    list: { type: Array },
-  },
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    // 查看信息
-    toView(data) {
-      this.$emit('toView', data);
-    },
-    // 申請審核
-    toCheck(data) {
-      this.$emit('toCheck', data);
-    },
-    // 整理状态
-    getStu(status) {
-      if (status == '0') return '待审中';
-      else if (status == '1') return '待受理';
-      else if (status == '-1') return '机构审核未通过';
-      else if (status == '2') return '待上传申请文件';
-      else if (status == '-2') return '未通过受理';
-      else if (status == '3') return '文件已上传,待形式审查';
-      else if (status == '-3') return '未通过形式审查';
-      else if (status == '4') return '通过形式审查,待上传国知局';
-      else if (status == '5') return '已上传到国知局';
-    },
-    // 审查文件下载
-    download(data) {
-      if (data.length > 0) {
-        let url = data.map((i) => i.url);
-        window.location.href = `${process.env.VUE_APP_HOST}${url[0]}`;
-      } else {
-        this.$toast({ type: `fail`, message: `未上传文件` });
-      }
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  padding: 8px 8px 0 8px;
-  .list {
-    background-color: #fff;
-    margin: 0 0 8px 0;
-    padding: 8px;
-    border-radius: 5px;
-    .title {
-      font-size: 16px;
-      font-weight: bold;
-      margin: 0 0 5px 0;
-    }
-    .other {
-      margin: 0 0 5px 0;
-      .otherInfo {
-        font-size: 14px;
-        color: #666;
-        margin: 0 0 5px 0;
-        span {
-          color: #000;
-        }
-      }
-    }
-    .btn {
-      text-align: center;
-      .van-button {
-        margin: 0 5px;
-      }
-    }
-  }
-}
-</style>

+ 0 - 133
src/layout/apply/list-3.vue

@@ -1,133 +0,0 @@
-<template>
-  <div id="list-3">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-col span="24" class="list" v-for="(item, index) in list" :key="index">
-          <van-col span="24" class="title textOver">
-            {{ item.name }}
-          </van-col>
-          <van-col span="24" class="other">
-            <!-- <van-col span="24" class="otherInfo">
-              专利用户码:<span>{{ item.water_number || '暂无' }}</span>
-            </van-col> -->
-            <van-col span="24" class="otherInfo">
-              申请类型:<span>{{ item.type || '暂无' }}</span>
-            </van-col>
-            <van-col span="24" class="otherInfo">
-              申请状态:<span>{{ getStu(item.status) }}</span>
-            </van-col>
-          </van-col>
-          <van-col span="24" class="btn">
-            <van-button size="small" type="info" @click="toView(item)">查看信息</van-button>
-            <!-- <van-button size="small" type="info" @click="download(item.check_url)">审查文件</van-button> -->
-            <van-button size="small" type="info" @click="toCheck(item)" v-if="item.status == '1'">受理</van-button>
-            <van-button size="small" type="info" @click="download(item.agent_url)" v-if="item.status == '3'">申请文件</van-button>
-            <van-button size="small" type="info" @click="formCheck(item)" v-if="item.status == '3'">形式审查</van-button>
-            <van-button size="small" type="info" @click="gzjSubmit(item)" v-if="item.status == '4'">确认上传</van-button>
-          </van-col>
-        </van-col>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'list-3',
-  props: {
-    list: { type: Array },
-  },
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    // 查看信息
-    toView(data) {
-      this.$emit('toView', data);
-    },
-    // 申請審核
-    toCheck(data) {
-      this.$emit('toCheck', data);
-    },
-    // 形式审查
-    formCheck(data) {
-      this.$emit('formCheck', data);
-    },
-    // 确认上传
-    gzjSubmit(data) {
-      this.$emit('gzjSubmit', data);
-    },
-    // 整理状态
-    getStu(status) {
-      if (status == '0') return '待审中';
-      else if (status == '1') return '待受理';
-      else if (status == '-1') return '机构审核未通过';
-      else if (status == '2') return '待上传申请文件';
-      else if (status == '-2') return '未通过受理';
-      else if (status == '3') return '文件已上传,待形式审查';
-      else if (status == '-3') return '未通过形式审查';
-      else if (status == '4') return '通过形式审查,待上传国知局';
-      else if (status == '5') return '已上传到国知局';
-    },
-    // 审查文件下载
-    download(data) {
-      if (data.length > 0) {
-        let url = data.map((i) => i.url);
-        window.location.href = `${process.env.VUE_APP_HOST}${url[0]}`;
-      } else {
-        this.$toast({ type: `fail`, message: `未上传文件` });
-      }
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  padding: 8px 8px 0 8px;
-  .list {
-    background-color: #fff;
-    margin: 0 0 8px 0;
-    padding: 8px;
-    border-radius: 5px;
-    .title {
-      font-size: 16px;
-      font-weight: bold;
-      margin: 0 0 5px 0;
-    }
-    .other {
-      margin: 0 0 5px 0;
-      .otherInfo {
-        font-size: 14px;
-        color: #666;
-        margin: 0 0 5px 0;
-        span {
-          color: #000;
-        }
-      }
-    }
-    .btn {
-      text-align: center;
-      .van-button {
-        margin: 0 5px;
-      }
-    }
-  }
-}
-</style>

+ 135 - 0
src/layout/apply/mech-1.vue

@@ -0,0 +1,135 @@
+<template>
+  <div id="mech-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-col span="24" class="one">
+          <van-form @submit="onSubmit" label-width="5em">
+            <van-field v-model="form.id" name="id" label="数据id" readonly style="display: none" />
+            <van-field name="status" label="机构类型" :rules="[{ required: true, message: '机构类型' }]">
+              <template #input>
+                <van-radio-group v-model="form.status" direction="horizontal" @change="changeStatus">
+                  <van-radio name="2">系统机构</van-radio>
+                  <van-radio name="3">代理机构</van-radio>
+                </van-radio-group>
+              </template>
+            </van-field>
+            <van-field v-if="form.status == '2'" v-model="form.admin_id" name="admin_id" label="科企机构id" readonly style="display: none" />
+            <van-field
+              v-if="form.status == '2'"
+              :value="form.admin_name"
+              name="admin_name"
+              label="科企机构"
+              placeholder="点击选择"
+              @click="oneShow = true"
+              :rules="[{ required: true, message: '科企机构' }]"
+            />
+            <van-field v-if="form.status == '3'" v-model="form.agentmech_id" name="agentmech_id" label="代理机构id" readonly style="display: none" />
+            <van-field
+              v-if="form.status == '3'"
+              :value="form.agentmech_name"
+              name="agentmech_name"
+              label="代理机构"
+              placeholder="点击选择"
+              @click="oneShow = true"
+              :rules="[{ required: true, message: '代理机构' }]"
+            />
+            <van-popup v-model="oneShow" position="bottom">
+              <van-picker show-toolbar :columns="agentmechList" value-key="name" @confirm="oneCom" @cancel="oneShow = false" />
+            </van-popup>
+            <van-field name="agent_url" label="申请文件" :rules="[{ required: true, message: '申请文件' }]">
+              <template #input>
+                <van-uploader
+                  :fileList="form.agent_url"
+                  :max-count="1"
+                  :after-read="(file) => toUpload(file, 'agent_url')"
+                  @delete="(file) => toDelete(file, 'agent_url')"
+                  accept="file"
+                />
+              </template>
+            </van-field>
+            <div style="margin: 16px">
+              <van-button round block type="info" native-type="submit">提交</van-button>
+            </div>
+          </van-form>
+        </van-col>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: adminLogin } = createNamespacedHelpers('adminLogin');
+const { mapActions: agent_mech } = createNamespacedHelpers('agent_mech');
+const { mapActions: upload } = createNamespacedHelpers('upload');
+export default {
+  name: 'mech-1',
+  props: {
+    form: { type: Object },
+  },
+  components: {},
+  data: function () {
+    return {
+      // 代理机构
+      oneShow: false,
+      agentmechList: [],
+    };
+  },
+  created() {},
+  methods: {
+    ...adminLogin({ adminQuery: 'query' }),
+    ...agent_mech({ agentmechQuery: 'query' }),
+    ...upload(['upload']),
+    onSubmit(value) {
+      this.$emit('onSubmit', value);
+    },
+    // 查询机构
+    async changeStatus(type) {
+      if (type == '2') {
+        let res = await this.adminQuery({ code: 'JLKQadmin' });
+        if (this.$checkRes(res)) this.$set(this, `agentmechList`, res.data);
+      } else if (type == '3') {
+        let res = await this.agentmechQuery();
+        if (this.$checkRes(res)) this.$set(this, `agentmechList`, res.data);
+      }
+    },
+    // 确认选择
+    oneCom(values) {
+      if (this.form.status == '2') {
+        this.$set(this.form, `admin_id`, values.id);
+        this.$set(this.form, `admin_name`, values.name);
+      } else if (this.form.status == '3') {
+        this.$set(this.form, `agentmech_id`, values.id);
+        this.$set(this.form, `agentmech_name`, values.name);
+      }
+      this.oneShow = false;
+    },
+    async toUpload({ file }, model) {
+      // 上传,赋值
+      const res = await this.upload({ file, dir: 'file' });
+      if (this.$checkRes(res)) {
+        this.$set(this.form, model, [{ name: res.name, url: res.uri }]);
+      }
+    },
+    toDelete(file, model) {
+      const index = this.form[model].findIndex((f) => _.isEqual(f, file));
+      this.form[model].splice(index, 1);
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 146 - 21
src/layout/assessment/form-1.vue

@@ -3,46 +3,150 @@
     <van-row>
       <van-col span="24" class="main">
         <van-col span="24" class="one">
+          <van-button type="info" size="small" @click="toSearch()">查询专利</van-button>
+        </van-col>
+        <van-col span="24" class="two">
           <van-form @submit="onSubmit">
-            <van-field v-model="form.admin_id" name="admin_id" label="管理员id" style="display: none" />
             <van-field v-model="form.user_id" name="user_id" label="用户id" style="display: none" />
+            <van-field v-model="form.user_name" name="user_name" label="用户姓名" style="display: none" />
+            <van-field v-model="form.admin_id" name="admin_id" label="管理员id" style="display: none" />
+            <van-field v-model="form.admin_name" name="admin_name" label="管理员姓名" style="display: none" />
             <van-field v-model="form.patent_id" name="patent_id" label="专利id" style="display: none" />
             <van-field v-model="form.create_number" name="create_number" label="申请号" readonly />
             <van-field v-model="form.patent_name" name="patent_name" label="专利名称" readonly />
-            <van-field v-model="form.inventors" name="inventors" label="发明人" readonly />
+            <van-field v-model="form.inventors" name="inventor" label="发明人" readonly />
             <van-field v-model="form.type" name="type" label="专利类型" readonly />
-            <van-field v-model="form.contact" name="contact" label="联系人" placeholder="联系人" :rules="[{ required: true, message: '联系人' }]" />
-            <van-field v-model="form.phone" name="phone" label="联系人电话" placeholder="联系人电话" :rules="[{ required: true, message: '联系人电话' }]" />
-            <van-field v-model="form.email" name="email" label="联系人邮箱" placeholder="联系人邮箱" :rules="[{ required: true, message: '联系人邮箱' }]" />
-            <van-field v-model="form.abstract" name="abstract" label="摘要" placeholder="摘要" type="textarea" rows="1" autosize />
-            <van-field v-model="form.field" name="field" label="应用领域" placeholder="应用领域" type="textarea" rows="1" autosize />
-            <van-field v-model="form.explain" name="explain" label="技术说明" placeholder="技术说明" type="textarea" rows="1" autosize />
-            <div style="margin: 16px">
-              <van-button round block type="info" native-type="submit">提交</van-button>
-            </div>
+            <van-field v-model="form.contact" name="contact" label="联系人" placeholder="请输入联系人" :rules="[{ required: true, message: '请输入联系人' }]" />
+            <van-field
+              v-model="form.phone"
+              name="phone"
+              label="联系电话"
+              placeholder="请输入联系电话"
+              :rules="[{ required: true, message: '请输入联系电话' }]"
+            />
+            <van-field
+              v-model="form.email"
+              name="email"
+              label="电子邮箱"
+              placeholder="请输入电子邮箱"
+              :rules="[{ required: true, message: '请输入电子邮箱' }]"
+            />
+            <van-field v-model="form.abstract" name="abstract" label="摘要" type="textarea" autosize readonly />
+            <van-field
+              v-model="form.field"
+              name="field"
+              label="应用领域"
+              placeholder="请输入应用领域"
+              type="textarea"
+              autosize
+              :rules="[{ required: true, message: '请输入应用领域' }]"
+            />
+            <van-field
+              v-model="form.explain"
+              name="explain"
+              label="技术说明"
+              placeholder="请输入技术说明"
+              type="textarea"
+              autosize
+              :rules="[{ required: true, message: '请输入技术说明' }]"
+            />
+            <van-field v-model="form.shared_value" name="shared_value" label="合享价值度" type="textarea" autosize readonly />
+            <van-field v-model="form.techol_stable" name="techol_stable" label="技术稳定性" type="textarea" autosize readonly />
+            <van-field v-model="form.techol_advanced" name="techol_advanced" label="技术先进性" type="textarea" autosize readonly />
+            <van-col span="24" class="btn">
+              <van-button type="info" size="small" native-type="submit">提交申请</van-button>
+            </van-col>
           </van-form>
         </van-col>
       </van-col>
     </van-row>
+    <van-dialog class="dialog" v-model="dialog.show" :title="dialog.title" :show-confirm-button="false" show-cancel-button>
+      <search-1 v-if="dialog.type == '1'" @conPatent="conPatent"></search-1>
+    </van-dialog>
   </div>
 </template>
 
 <script>
+import search1 from '@/layout/assessment/search-1.vue';
 import { mapState, createNamespacedHelpers } from 'vuex';
-
+const { mapActions: patentassess } = createNamespacedHelpers('patentassess');
+const { mapActions: patentinfo } = createNamespacedHelpers('patentinfo');
+const { mapActions: adminLogin } = createNamespacedHelpers('adminLogin');
 export default {
   name: 'form-1',
   props: {
-    form: { type: Object },
+    patent_id: { type: String },
   },
-  components: {},
+  components: { search1 },
   data: function () {
-    return {};
+    return {
+      adminInfo: {},
+      form: {
+        inventor: [],
+      },
+      // 弹框
+      dialog: { show: false, title: '查询专利', type: '1' },
+    };
+  },
+  created() {
+    this.searchOther();
   },
-  created() {},
   methods: {
-    onSubmit(value) {
-      if (value) this.$emit('onSubmit', { data: this.form });
+    ...adminLogin({ adminQuery: 'query' }),
+    ...patentinfo({ patentQuery: 'query', patentFetch: 'fetch' }),
+    ...patentassess(['fetch', 'create', 'update']),
+    // 提交
+    async onSubmit(values) {
+      if (values) {
+        let data = this.form;
+        if (data.id) {
+        } else {
+          let res = await this.create(data);
+          if (this.$checkRes(res)) {
+            this.$toast({ type: `success`, message: `操作完成` });
+            this.form = { inventor: [] };
+          }
+        }
+      }
+    },
+    // 查询专利
+    toSearch() {
+      this.dialog = { show: true, title: '查询专利', type: '1' };
+    },
+    // 确认选择专利
+    conPatent(value) {
+      let data = {
+        admin_id: this.adminInfo.id,
+        admin_name: this.adminInfo.name,
+        user_id: this.user.id,
+        user_name: this.user.name,
+        patent_id: value.id,
+        create_number: value.create_number,
+        patent_name: value.name,
+        inventors: JSON.stringify(value.inventor.map((i) => i.name)),
+        inventor: value.inventor,
+        type: value.type,
+        contact: this.user.name,
+        phone: this.user.phone,
+        email: this.user.email,
+        abstract: value.abstract,
+        shared_value: value.shared_value,
+        techol_stable: value.techol_stable,
+        techol_advanced: value.techol_advanced,
+      };
+      this.$set(this, `form`, data);
+      this.dialog = { show: false, title: '查询专利', type: '1' };
+    },
+    // 查询其他信息
+    async searchOther() {
+      // 查询管理员信息
+      let res = await this.adminQuery({ code: 'JLKQadmin' });
+      if (this.$checkRes(res)) this.$set(this, `adminInfo`, res.data[0]);
+    },
+    // 查询专利信息
+    async searchPatent() {
+      let res = await this.patentFetch(this.patent_id);
+      if (this.$checkRes(res)) this.conPatent(res.data);
     },
   },
   computed: {
@@ -52,13 +156,34 @@ export default {
     return { title: this.$route.meta.title };
   },
   watch: {
-    test: {
+    patent_id: {
       deep: true,
       immediate: true,
-      handler(val) {},
+      handler(val) {
+        this.searchPatent();
+      },
     },
   },
 };
 </script>
 
-<style lang="less" scoped></style>
+<style lang="less" scoped>
+.main {
+  .one {
+    text-align: center;
+    padding: 5px 0;
+  }
+  .two {
+    .btn {
+      text-align: center;
+      margin: 10px 0;
+    }
+  }
+}
+.dialog {
+  /deep/.van-dialog__content {
+    max-height: 350px;
+    overflow-y: auto;
+  }
+}
+</style>

+ 9 - 6
src/layout/assessment/info-1.vue

@@ -7,12 +7,15 @@
           <van-field v-model="info.patent_name" name="patent_name" label="专利名称" readonly />
           <van-field v-model="info.inventor" name="inventor" label="发明人" readonly />
           <van-field v-model="info.type" name="type" label="专利类型" readonly />
-          <van-field v-model="info.contact" name="contact" label="联系人" readonly />
-          <van-field v-model="info.phone" name="phone" label="联系人电话" readonly />
-          <van-field v-model="info.email" name="email" label="联系人邮箱" readonly />
-          <van-field v-model="info.abstract" name="abstract" label="摘要" type="textarea" rows="1" autosize readonly />
-          <van-field v-model="info.field" name="field" label="应用领域" type="textarea" rows="1" autosize readonly />
-          <van-field v-model="info.explain" name="explain" label="技术说明" type="textarea" rows="1" autosize readonly />
+          <van-field v-model="info.contact" name="contact" label="联系人" placeholder="请输入联系人" readonly />
+          <van-field v-model="info.phone" name="phone" label="联系电话" placeholder="请输入联系电话" readonly />
+          <van-field v-model="info.email" name="email" label="电子邮箱" placeholder="请输入电子邮箱" readonly />
+          <van-field v-model="info.abstract" name="abstract" label="摘要" type="textarea" autosize readonly />
+          <van-field v-model="info.field" name="field" label="应用领域" placeholder="请输入应用领域" type="textarea" autosize readonly />
+          <van-field v-model="info.explain" name="explain" label="技术说明" placeholder="请输入技术说明" type="textarea" autosize readonly />
+          <van-field v-model="info.shared_value" name="shared_value" label="合享价值度" type="textarea" autosize readonly />
+          <van-field v-model="info.techol_stable" name="techol_stable" label="技术稳定性" type="textarea" autosize readonly />
+          <van-field v-model="info.techol_advanced" name="techol_advanced" label="技术先进性" type="textarea" autosize readonly />
         </van-col>
       </el-col>
     </el-row>

+ 20 - 6
src/layout/assessment/list-1.vue

@@ -19,8 +19,14 @@
           </van-col>
           <van-col span="24" class="btn">
             <van-button size="small" type="info" @click="toView(item)">查看信息</van-button>
-            <van-button size="small" type="info" @click="toResult(item)">审核结果</van-button>
-            <van-button size="small" type="info" @click="download(item.report)" v-if="item.status == '2'">报告文件</van-button>
+            <template v-if="user.role == '1'">
+              <van-button size="small" type="info" @click="toCheck(item)" v-if="item.status == '0'">审核申请</van-button>
+              <van-button size="small" type="info" @click="toFile(item)" v-if="item.status == '1'">报告文件</van-button>
+            </template>
+            <template v-else-if="user.role == '3'">
+              <van-button size="small" type="info" @click="toResult(item)">审核结果</van-button>
+              <van-button size="small" type="info" @click="download(item.report)" v-if="item.status == '2'">报告文件</van-button>
+            </template>
           </van-col>
         </van-col>
       </van-col>
@@ -46,6 +52,14 @@ export default {
     toView(data) {
       this.$emit('toView', data);
     },
+    // 审核申请
+    toCheck(data) {
+      this.$emit('toCheck', data);
+    },
+    // 报告文件
+    toFile(data) {
+      this.$emit('toFile', data);
+    },
     // 审核结果
     toResult(data) {
       this.$emit('toResult', data);
@@ -59,16 +73,16 @@ export default {
         this.$toast({ type: `fail`, message: `非正常文件,无法下载` });
       }
     },
-    getDate(data) {
-      let newDate = moment(data.createdAt).format('YYYY-MM-DD hh:mm:ss');
-      if (newDate) return newDate;
-    },
     getStu(status) {
       if (status == '0') return '待审中';
       else if (status == '1') return '审核通过,待发报告文件';
       else if (status == '-1') return '审核拒绝';
       else if (status == '2') return '报告文件已发,请及时下载查看';
     },
+    getDate(data) {
+      let newDate = moment(data.createdAt).format('YYYY-MM-DD hh:mm:ss');
+      if (newDate) return newDate;
+    },
   },
   computed: {
     ...mapState(['user']),

+ 0 - 120
src/layout/assessment/list-2.vue

@@ -1,120 +0,0 @@
-<template>
-  <div id="list-2">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-col span="24" class="list" v-for="(item, index) in list" :key="index">
-          <van-col span="24" class="title textOver">
-            {{ item.patent_name }}
-          </van-col>
-          <van-col span="24" class="other">
-            <van-col span="24" class="otherInfo">
-              申请号:<span>{{ item.create_number }}</span>
-            </van-col>
-            <van-col span="24" class="otherInfo">
-              是否缴费:<span>{{ item.is_money ? '已缴费' : '未缴费' }}</span>
-            </van-col>
-            <van-col span="24" class="otherInfo">
-              申请时间:<span>{{ getDate(item.meta) }}</span>
-            </van-col>
-            <van-col span="24" class="otherInfo">
-              申请状态:<span>{{ getStu(item.status) }}</span>
-            </van-col>
-          </van-col>
-          <van-col span="24" class="btn">
-            <van-button size="small" type="info" @click="toView(item)">查看信息</van-button>
-            <van-button size="small" type="info" @click="toCheck(item)" v-if="item.status == '0'">审核申请</van-button>
-            <van-button size="small" type="info" @click="toFile(item)" v-if="item.status == '1'">报告文件</van-button>
-          </van-col>
-        </van-col>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-var moment = require('moment');
-export default {
-  name: 'list-2',
-  props: {
-    list: { type: Array },
-  },
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    // 查看信息
-    toView(data) {
-      this.$emit('toView', data);
-    },
-    // 审核申请
-    toCheck(data) {
-      this.$emit('toCheck', data);
-    },
-    // 报告文件
-    // 下载文件
-    toFile(data) {
-      this.$emit('toFile', data);
-    },
-    getDate(data) {
-      let newDate = moment(data.createdAt).format('YYYY-MM-DD hh:mm:ss');
-      if (newDate) return newDate;
-    },
-    getStu(status) {
-      if (status == '0') return '待审中';
-      else if (status == '1') return '审核通过,请及时发放报告文件';
-      else if (status == '-1') return '审核拒绝';
-      else if (status == '2') return '报告文件已发';
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  padding: 8px 8px 0 8px;
-  .list {
-    background-color: #fff;
-    margin: 0 0 8px 0;
-    padding: 8px;
-    border-radius: 5px;
-    .title {
-      font-size: 16px;
-      font-weight: bold;
-      margin: 0 0 5px 0;
-    }
-    .other {
-      margin: 0 0 5px 0;
-      .otherInfo {
-        font-size: 14px;
-        color: #666;
-        margin: 0 0 5px 0;
-        span {
-          color: #000;
-        }
-      }
-    }
-    .btn {
-      text-align: center;
-      .van-button {
-        margin: 0 5px;
-      }
-    }
-  }
-}
-</style>

+ 1 - 0
src/layout/assessment/search-1.vue

@@ -56,6 +56,7 @@ export default {
     ...patentinfo(['query']),
     async search({ skip = 0, limit = this.limit, ...info } = {}) {
       info.user_id = this.user._id;
+      if (this.searchName) info.name = this.searchName;
       let res = await this.query({ skip, limit, ...info });
       if (this.$checkRes(res)) {
         this.$set(this, `list`, res.data);

+ 1 - 1
src/layout/chatCommon/chat.vue

@@ -181,7 +181,7 @@ export default {
     },
     // 查询管理员
     async searchAdmin() {
-      let res = await this.adminQuery({ code: 'JLKJQY' });
+      let res = await this.adminQuery({ code: 'JLKQadmin' });
       if (this.$checkRes(res)) {
         this.$set(this, `adminInfo`, res.data[0]);
       }

+ 7 - 30
src/layout/login/login-1.vue

@@ -2,17 +2,9 @@
   <div id="login-1">
     <van-row>
       <van-col span="24" class="main">
-        <van-form @submit="onSubmit">
+        <van-form @submit="onSubmit" label-width="4em">
           <van-field v-model="form.phone" name="phone" label="账号" placeholder="账号" :rules="[{ required: true, message: '账号' }]" />
           <van-field v-model="form.password" type="password" name="password" label="密码" placeholder="密码" :rules="[{ required: true, message: '密码' }]" />
-          <van-field name="role" label="用户类别">
-            <template #input>
-              <van-radio-group v-model="form.role" direction="horizontal">
-                <van-radio name="4">个人用户</van-radio>
-                <!-- <van-radio name="5">企业用户</van-radio> -->
-              </van-radio-group>
-            </template>
-          </van-field>
           <div style="margin: 16px">
             <van-button round block type="info" native-type="submit">登录</van-button>
           </div>
@@ -28,7 +20,6 @@
 
 <script>
 import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: organization } = createNamespacedHelpers('organization');
 const { mapActions: personal } = createNamespacedHelpers('personal');
 export default {
   name: 'login-1',
@@ -42,27 +33,13 @@ export default {
   created() {},
   methods: {
     ...personal(['perLogin']),
-    ...organization(['orgLogin', 'wxLogin']),
     async onSubmit(values) {
-      if (values.role == '4') {
-        // 个人用户
-        let res = await this.perLogin({ user: values });
-        if (this.$checkRes(res)) {
-          if (this.path) this.$router.push({ path: this.path });
-          else this.$router.push({ path: '/account/index' });
-        } else {
-          this.$toast({ type: 'fail', message: res.errmsg });
-        }
-      } else if (values.role == '5') {
-        // 企业用户
-        values.institution_code = values.phone;
-        let res = await this.orgLogin({ user: values });
-        if (this.$checkRes(res)) {
-          if (this.path) this.$router.push({ path: this.path });
-          else this.$router.push({ path: '/account/index' });
-        } else {
-          this.$toast({ type: 'fail', message: res.errmsg });
-        }
+      let res = await this.perLogin({ user: values });
+      if (this.$checkRes(res)) {
+        if (this.path) this.$router.push({ path: this.path });
+        else this.$router.push({ path: '/account/index' });
+      } else {
+        this.$toast({ type: 'fail', message: res.errmsg });
       }
     },
     // 注册

+ 1 - 1
src/layout/login/login-2.vue

@@ -2,7 +2,7 @@
   <div id="login-2">
     <van-row>
       <van-col span="24" class="main">
-        <van-form @submit="onSubmit">
+        <van-form @submit="onSubmit" label-width="4em">
           <van-field v-model="form.code_phone" name="code_phone" label="账号" placeholder="账号" :rules="[{ required: true, message: '账号' }]" />
           <van-field v-model="form.passwd" type="password" name="passwd" label="密码" placeholder="密码" :rules="[{ required: true, message: '密码' }]" />
           <div style="margin: 16px">

+ 61 - 0
src/layout/login/login-3.vue

@@ -0,0 +1,61 @@
+<template>
+  <div id="login-3">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-form @submit="onSubmit" label-width="4em">
+          <van-field v-model="form.phone" name="phone" label="账号" placeholder="账号" :rules="[{ required: true, message: '账号' }]" />
+          <van-field v-model="form.password" type="password" name="password" label="密码" placeholder="密码" :rules="[{ required: true, message: '密码' }]" />
+          <div style="margin: 16px">
+            <van-button round block type="info" native-type="submit">登录</van-button>
+          </div>
+        </van-form>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: agent_mech } = createNamespacedHelpers('agent_mech');
+export default {
+  name: 'login-3',
+  props: {},
+  components: {},
+  data: function () {
+    return {
+      form: {},
+    };
+  },
+  created() {},
+  methods: {
+    ...agent_mech(['login']),
+    async onSubmit(values) {
+      let res = await this.login({ user: values });
+      if (this.$checkRes(res)) {
+        if (this.path) this.$router.push({ path: this.path });
+        else this.$router.push({ path: '/account/index' });
+      } else {
+        this.$toast({ type: 'fail', message: res.errmsg });
+      }
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+    path() {
+      return this.$route.query.path;
+    },
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 61 - 0
src/layout/login/login-4.vue

@@ -0,0 +1,61 @@
+<template>
+  <div id="login-4">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-form @submit="onSubmit" label-width="4em">
+          <van-field v-model="form.phone" name="phone" label="账号" placeholder="账号" :rules="[{ required: true, message: '账号' }]" />
+          <van-field v-model="form.password" type="password" name="password" label="密码" placeholder="密码" :rules="[{ required: true, message: '密码' }]" />
+          <div style="margin: 16px">
+            <van-button round block type="info" native-type="submit">登录</van-button>
+          </div>
+        </van-form>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: answer_tea } = createNamespacedHelpers('answer_tea');
+export default {
+  name: 'login-4',
+  props: {},
+  components: {},
+  data: function () {
+    return {
+      form: {},
+    };
+  },
+  created() {},
+  methods: {
+    ...answer_tea(['login']),
+    async onSubmit(values) {
+      let res = await this.login({ user: values });
+      if (this.$checkRes(res)) {
+        if (this.path) this.$router.push({ path: this.path });
+        else this.$router.push({ path: '/account/index' });
+      } else {
+        this.$toast({ type: 'fail', message: res.errmsg });
+      }
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+    path() {
+      return this.$route.query.path;
+    },
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 21 - 24
src/layout/login/register-1.vue

@@ -2,36 +2,33 @@
   <div id="register-1">
     <van-row>
       <van-col span="24" class="main">
-        <van-form @submit="onSubmit" label-width="6em">
-          <van-field v-model="form.name" name="name" label="用户名" :rules="[{ required: true, message: '用户名' }]" />
-          <van-field v-model="form.phone" name="phone" label="手机号" :rules="[{ required: true, message: '手机号' }]" />
+        <van-form @submit="onSubmit" label-width="4em">
+          <van-field v-model="form.name" name="name" label="姓名" placeholder="请填写姓名" :rules="[{ required: true, message: '姓名' }]" />
+          <van-field v-model="form.phone" name="phone" label="手机号" placeholder="请填写手机号" :rules="[{ required: true, message: '手机号' }]" />
           <van-col span="24" class="tip"> 手机号作为登录平台唯一凭证,请谨慎填写! </van-col>
-          <van-field v-model="form.password" type="password" name="password" label="登录密码" :rules="[{ required: true, message: '登录密码' }]" />
+          <van-field
+            v-model="form.password"
+            type="password"
+            name="password"
+            label="登录密码"
+            placeholder="请填写登录密码"
+            :rules="[{ required: true, message: '登录密码' }]"
+          />
           <van-field v-model="form.code" name="code" label="邀请码" placeholder="请填写邀请码" :rules="[{ required: true, message: '邀请码' }]" />
-          <van-field name="type" label="用户类别" :rules="[{ required: true, message: '用户类别' }]">
-            <template #input>
-              <van-radio-group v-model="form.type" direction="horizontal">
-                <van-radio name="4">个人用户</van-radio>
-                <!-- <van-radio name="5">企业用户</van-radio> -->
-              </van-radio-group>
-            </template>
-          </van-field>
-          <van-field v-model="form.email" name="email" label="电子邮箱" placeholder="电子邮箱" />
-          <van-field v-model="form.addr" name="addr" label="联系地址" placeholder="联系地址" />
-          <van-field v-model="form.office_phone" name="office_phone" label="办公电话" placeholder="办公电话" />
+          <van-field v-model="form.card" name="card" label="身份证号" placeholder="请填写身份证号" />
+          <van-field v-model="form.email" name="email" label="电子邮箱" placeholder="请填写电子邮箱" />
+          <van-field v-model="form.addr" name="addr" label="联系地址" placeholder="请填写联系地址" />
+          <van-field v-model="form.zwzc" name="zwzc" label="职务职称" placeholder="请填写职务职称" />
+          <van-field v-model="form.school" name="school" label="院校" placeholder="请填写院校" />
+          <van-field v-model="form.major" name="major" label="专业" placeholder="请填写专业" />
+          <van-field v-model="form.office_phone" name="office_phone" label="办公电话" placeholder="请填写办公电话" />
           <van-field readonly clickable name="juris" :value="form.juris" label="所属辖区" placeholder="点击选择" @click="showPicker = true" />
-          <van-field v-model="form.school" name="school" label="院校" placeholder="院校" />
-          <van-field v-model="form.major" name="major" label="专业" placeholder="专业" />
-          <van-field v-model="form.card" name="card" label="身份证号" placeholder="身份证号" :rules="[{ required: true, message: '身份证号' }]" />
-          <van-field v-model="form.zwzc" name="zwzc" label="职务职称" placeholder="职务职称" />
           <van-popup v-model="showPicker" position="bottom">
             <van-picker show-toolbar :columns="jurisList" @confirm="confirm" @cancel="showPicker = false" />
           </van-popup>
-
           <div class="btn">
-            <van-button round type="danger" size="normal" @click="reseat">取消注册</van-button>
-            <van-button round type="primary" size="normal" native-type="submit" v-if="form.type == '4'">提交注册</van-button>
-            <van-button round type="info" size="normal" @click="next" v-if="form.type == '5'">下一步</van-button>
+            <van-button type="danger" size="small" @click="reseat">取消注册</van-button>
+            <van-button type="primary" size="small" native-type="submit">提交注册</van-button>
           </div>
         </van-form>
       </van-col>
@@ -93,7 +90,7 @@ export default {
 <style lang="less" scoped>
 .main {
   .btn {
-    margin: 16px;
+    margin: 10px;
     text-align: center;
     .van-button {
       margin: 0 10px;

+ 0 - 91
src/layout/patent/info-1.vue

@@ -1,91 +0,0 @@
-<template>
-  <div id="info-1">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-col span="24" class="one">
-          <van-image :src="img_url"></van-image>
-        </van-col>
-        <van-col span="24" class="two">
-          <van-form>
-            <van-field v-model="info.term" name="term" label="专利有效性" readonly />
-            <van-field v-model="info.name" name="name" label="名称" readonly />
-            <van-field v-model="info.create_number" name="create_number" label="申请号" readonly />
-            <van-field v-model="info.create_date" name="create_date" label="申请日" readonly />
-            <van-field v-model="info.success_number" name="success_number" label="公开(公告)号" readonly />
-            <van-field v-model="info.success_date" name="success_date" label="公开(公告)日" readonly />
-            <van-field v-model="info.type" name="type" label="专利类型" readonly />
-            <van-field v-model="info.inventor" name="inventor" label="发明人" readonly />
-            <van-field v-model="info.address" name="address" label="发明人地址" readonly />
-            <van-field v-model="info.apply_personal" name="apply_personal" label="申请人" readonly />
-            <van-field v-model="info.agent_personal" name="agent_personal" label="代理人" readonly />
-            <van-field v-model="info.agent" name="agent" label="代理机构" readonly />
-            <van-field v-model="info.abstract" name="abstract" label="摘要" rows="1" autosize type="textarea" readonly />
-            <van-field name="trans_status" label="是否交易" readonly>
-              <template #input>
-                <van-radio-group v-model="info.trans_status" direction="horizontal">
-                  <van-radio name="0" label-disabled>未交易</van-radio>
-                  <van-radio name="1" label-disabled>已交易</van-radio>
-                </van-radio-group>
-              </template>
-            </van-field>
-          </van-form>
-        </van-col>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'info-1',
-  props: { info: { type: Object } },
-  components: {},
-  data: function () {
-    return {
-      img_url: '',
-    };
-  },
-  created() {},
-  methods: {
-    searchImg(data) {
-      if (data.img_url && data.img_url.length > 0) {
-        var url = data.img_url.map((item) => item.url)[0];
-        this.$set(this, `img_url`, url);
-      } else {
-        var url = require('@/assets/fmzl.jpg');
-        this.$set(this, `img_url`, url);
-      }
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    info: {
-      deep: true,
-      immediate: true,
-      handler(val) {
-        this.searchImg(val);
-      },
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  padding: 0 8px;
-  .one {
-    height: 220px;
-    border-bottom: 1px solid #f1f1f1;
-    .van-image {
-      width: 100%;
-      height: 219px;
-    }
-  }
-}
-</style>

+ 0 - 98
src/layout/patent/list-2.vue

@@ -1,98 +0,0 @@
-<template>
-  <div id="list-2">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-col span="24" class="list" v-for="(item, index) in list" :key="index">
-          <van-col span="24" class="title textOver">
-            {{ item.name }}
-          </van-col>
-          <van-col span="24" class="other">
-            <van-col span="24" class="otherInfo">
-              专利有效性:<span>{{ item.term || '暂无' }}</span>
-            </van-col>
-            <van-col span="24" class="otherInfo">
-              申请时间:<span>{{ item.create_date || '暂无' }}</span>
-            </van-col>
-          </van-col>
-          <van-col span="24" class="btn">
-            <van-button type="info" size="small" @click="toView(item)">查看信息</van-button>
-          </van-col>
-        </van-col>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-const moment = require('moment');
-export default {
-  name: 'list-2',
-  props: { list: { type: Array } },
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    // 专利信息
-    toView(data) {
-      this.$emit('toView', data);
-    },
-
-    // 过滤时间
-    getDate(val) {
-      let newDate = moment(val).format('YYYY-MM-DD');
-      if (newDate) return newDate;
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  margin: 8px 0 0 0;
-  .list {
-    background-color: #fff;
-    margin: 0 0 10px 0;
-    box-shadow: 0 0 5px #f1f1f1;
-    padding: 8px;
-    .title {
-      font-size: 16px;
-      font-weight: bold;
-      margin: 0 0 5px 0;
-    }
-    .other {
-      margin: 0 0 5px 0;
-      .otherInfo {
-        font-size: 14px;
-        color: #666;
-        margin: 0 0 5px 0;
-        span {
-          color: #000;
-        }
-      }
-    }
-    .btn {
-      text-align: center;
-
-      .van-button {
-        margin: 0 10px 5px 10px;
-      }
-    }
-  }
-}
-</style>

+ 0 - 103
src/layout/patent/trans-1.vue

@@ -1,103 +0,0 @@
-<template>
-  <div id="trans-1">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-form @submit="onSubmit">
-          <van-field v-model="form.user_id" name="user_id" label="用户id" readonly style="display: none" />
-          <van-field v-model="form.patent_id" name="patent_id" label="专利id" readonly style="display: none" />
-          <van-field v-model="form.admin_id" name="admin_id" label="管理员id" readonly style="display: none" />
-          <van-field v-model="form.create_number" name="create_number" label="申请号" readonly />
-          <van-field v-model="form.patent_name" name="patent_name" label="专利名称" readonly />
-          <van-field v-model="form.on_obligee" name="on_obligee" label="当前权利人" readonly />
-          <van-field v-model="form.contact" name="contact" label="联系人" :rules="[{ required: true, message: '联系人' }]" />
-          <van-field v-model="form.phone" name="phone" label="联系电话" :rules="[{ required: true, message: '联系电话' }]" />
-          <van-field v-model="form.email" name="email" label="电子邮箱" :rules="[{ required: true, message: '电子邮箱' }]" />
-          <van-field v-model="form.budget" name="budget" type="digit" label="投资预算(万元)" :rules="[{ required: true, message: '投资预算' }]" />
-          <van-field name="type" label="交易类型" :rules="[{ required: true, message: '交易类型' }]">
-            <template #input>
-              <van-radio-group v-model="form.type" direction="horizontal">
-                <van-radio name="转让">转让</van-radio>
-                <van-radio name="许可">许可</van-radio>
-                <van-radio name="招商">招商</van-radio>
-                <van-radio name="质押">质押</van-radio>
-              </van-radio-group>
-            </template>
-          </van-field>
-          <van-field name="is_report" label="评估报告">
-            <template #input>
-              <van-radio-group v-model="form.is_report" direction="horizontal">
-                <van-radio :name="true">有</van-radio>
-                <van-radio :name="false">无</van-radio>
-              </van-radio-group>
-            </template>
-          </van-field>
-          <van-field name="report" label="评估报告">
-            <template #input>
-              <van-uploader
-                :fileList="form.report"
-                :max-count="1"
-                :after-read="(file) => toUpload(file, 'report')"
-                @delete="(file) => toDelete(file, 'report')"
-              />
-            </template>
-          </van-field>
-          <van-field v-model="form.requirementdesc" name="requirementdesc" label="技术说明" rows="2" autosize type="textarea" />
-          <van-field v-model="form.expect" name="expect" label="商业预期" rows="2" autosize type="textarea" />
-          <van-field v-model="form.condition" name="condition" label="合作条件及要求" rows="2" autosize type="textarea" />
-          <div style="margin: 16px">
-            <van-button round block type="info" native-type="submit">提交</van-button>
-          </div>
-        </van-form>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: upload } = createNamespacedHelpers('upload');
-export default {
-  name: 'trans-1',
-  props: {
-    form: { type: Object },
-  },
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    ...upload(['upload']),
-    onSubmit(values) {
-      values.status = '0';
-      this.$emit('onSubmit', values);
-    },
-    async toUpload({ file }, model) {
-      // 上传,赋值
-      const res = await this.upload({ file, dir: 'file' });
-      if (this.$checkRes(res)) {
-        this.$set(this.form, model, [{ name: res.name, url: res.uri }]);
-      }
-    },
-    toDelete(file, model) {
-      const index = this.form[model].findIndex((f) => _.isEqual(f, file));
-      this.form[model].splice(index, 1);
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 529 - 0
src/layout/patentInfo/form-1.vue

@@ -0,0 +1,529 @@
+<template>
+  <div id="form-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-col span="24" class="one">
+          <van-form @submit="onSubmit" label-width="6em">
+            <van-field
+              v-model="form.create_number"
+              name="create_number"
+              label="申请号"
+              placeholder="请输入申请号"
+              :rules="[{ required: true, message: '申请号' }]"
+            />
+            <van-field
+              :value="form.create_date"
+              name="create_date"
+              label="申请日"
+              placeholder="点击选择"
+              @click="selectDate('create_date')"
+              :rules="[{ required: true, message: '申请日' }]"
+            />
+            <van-field
+              v-model="form.success_number"
+              name="success_number"
+              label="公开(公告)号"
+              placeholder="请输入公开(公告)号"
+              :rules="[{ required: true, message: '公开(公告)号' }]"
+            />
+            <van-field
+              :value="form.success_date"
+              name="success_date"
+              label="公开(公告)日"
+              placeholder="点击选择"
+              @click="selectDate('success_date')"
+              :rules="[{ required: true, message: '公开(公告)日' }]"
+            />
+            <van-col span="24" class="inventor">
+              <van-col span="24" class="txt">发明人</van-col>
+              <van-col span="24" class="btn">
+                <van-button type="info" size="small" @click.prevent="toSelect('inventor')">选择发明人</van-button>
+              </van-col>
+              <van-col span="24" class="list">
+                <van-col span="12" class="list_1" v-for="(item, index) in form.inventor" :key="index">
+                  <p class="textOver">{{ index + 1 }}-{{ item.name }}</p>
+                  <van-button type="danger" size="mini" @click.prevent="delInv(item, 'inventor')">删除</van-button>
+                </van-col>
+              </van-col>
+            </van-col>
+            <van-field
+              v-model="form.agent"
+              name="agent"
+              label="代理机构"
+              placeholder="请输入代理机构"
+              :rules="[{ required: false, message: '请输入代理机构' }]"
+            />
+            <van-field
+              v-model="form.agent_personal"
+              name="agent_personal"
+              label="代理人"
+              placeholder="请输入代理人"
+              :rules="[{ required: false, message: '请输入代理人' }]"
+            />
+            <van-field
+              v-model="form.abstract"
+              name="abstract"
+              label="摘要"
+              placeholder="请输入摘要"
+              type="textarea"
+              autosize
+              maxlength="300"
+              show-word-limit
+              :rules="[{ required: true, message: '请输入摘要' }]"
+            />
+            <van-field
+              v-model="form.address"
+              name="address"
+              label="发明人地址"
+              placeholder="请输入发明人地址"
+              :rules="[{ required: false, message: '请输入发明人地址' }]"
+            />
+            <van-field v-model="form.name" name="name" label="专利名称" placeholder="请输入专利名称" :rules="[{ required: true, message: '请输入专利名称' }]" />
+            <van-field
+              v-model="form.apply_personal"
+              name="apply_personal"
+              label="申请人"
+              placeholder="请输入申请人"
+              :rules="[{ required: true, message: '请输入申请人' }]"
+            />
+            <van-field name="term" label="专利有效性" :rules="[{ required: true, message: '请选择专利有效性' }]">
+              <template #input>
+                <van-radio-group v-model="form.term" direction="horizontal">
+                  <van-radio name="有效">有效</van-radio>
+                  <van-radio name="审中">审中</van-radio>
+                  <van-radio name="失效">失效</van-radio>
+                </van-radio-group>
+              </template>
+            </van-field>
+            <van-field name="type" label="专利类型" :rules="[{ required: true, message: '请选择专利类型' }]">
+              <template #input>
+                <van-radio-group v-model="form.type" direction="horizontal">
+                  <van-radio name="发明申请">发明申请</van-radio>
+                  <van-radio name="发明授权">发明授权</van-radio>
+                  <van-radio name="实用新型">实用新型</van-radio>
+                  <van-radio name="外观设计">外观设计</van-radio>
+                  <van-radio name="PCT国际申请号">PCT国际申请号</van-radio>
+                  <van-radio name="PCT国际公布号">PCT国际公布号</van-radio>
+                </van-radio-group>
+              </template>
+            </van-field>
+            <van-field name="img_url" label="首页附图" :rules="[{ required: false, message: '首页附图' }]">
+              <template #input>
+                <van-uploader
+                  :fileList="form.img_url"
+                  :max-count="1"
+                  :after-read="(file) => toUpload(file, 'img_url')"
+                  @delete="(file) => toDelete(file, 'img_url')"
+                />
+              </template>
+            </van-field>
+            <van-field
+              v-model="form.nationality"
+              name="nationality"
+              label="公开国别"
+              placeholder="请输入公开国别"
+              :rules="[{ required: false, message: '请输入公开国别' }]"
+            />
+            <van-field
+              v-model="form.ipc_type"
+              name="ipc_type"
+              label="IPC主分类"
+              placeholder="请输入IPC主分类"
+              :rules="[{ required: false, message: '请输入IPC主分类' }]"
+            />
+            <van-field
+              v-model="form.onlegal_status"
+              name="onlegal_status"
+              label="当前法律状态"
+              placeholder="请输入当前法律状态"
+              :rules="[{ required: false, message: '请输入当前法律状态' }]"
+            />
+            <van-field
+              v-model="form.legal_status"
+              name="legal_status"
+              label="法律状态"
+              placeholder="请输入法律状态"
+              :rules="[{ required: false, message: '请输入法律状态' }]"
+            />
+            <van-field
+              :value="form.law_date"
+              name="law_date"
+              label="法律文书日期"
+              placeholder="点击选择"
+              @click="selectDate('law_date')"
+              :rules="[{ required: false, message: '法律文书日期' }]"
+            />
+            <van-field
+              v-model="form.on_obligee"
+              name="on_obligee"
+              label="当前权利人"
+              placeholder="请输入当前权利人"
+              :rules="[{ required: true, message: '请输入当前权利人' }]"
+            />
+            <van-field
+              v-model="form.apply_address"
+              name="apply_address"
+              label="申请人地址(其他)"
+              placeholder="请输入申请人地址(其他)"
+              :rules="[{ required: false, message: '请输入申请人地址(其他)' }]"
+            />
+            <van-field
+              v-model="form.apply_other"
+              name="apply_other"
+              label="申请人(其他)"
+              placeholder="请输入申请人(其他)"
+              :rules="[{ required: false, message: '请输入申请人(其他)' }]"
+            />
+            <van-field
+              v-model="form.law_num"
+              name="law_num"
+              label="法律文书编号"
+              placeholder="请输入法律文书编号"
+              :rules="[{ required: false, message: '请输入法律文书编号' }]"
+            />
+            <van-field
+              :value="form.first_opendate"
+              name="first_opendate"
+              label="首次公开日"
+              placeholder="点击选择"
+              @click="selectDate('first_opendate')"
+              :rules="[{ required: false, message: '首次公开日' }]"
+            />
+            <van-field
+              :value="form.empower_date"
+              name="empower_date"
+              label="授权公告日"
+              placeholder="点击选择"
+              @click="selectDate('empower_date')"
+              :rules="[{ required: false, message: '授权公告日' }]"
+            />
+            <van-field
+              :value="form.lose_date"
+              name="lose_date"
+              label="失效日"
+              placeholder="点击选择"
+              @click="selectDate('lose_date')"
+              :rules="[{ required: false, message: '失效日' }]"
+            />
+            <van-field
+              :value="form.examine_date"
+              name="examine_date"
+              label="实质审查生效日"
+              placeholder="点击选择"
+              @click="selectDate('examine_date')"
+              :rules="[{ required: false, message: '实质审查生效日' }]"
+            />
+            <van-field
+              v-model="form.invention_design"
+              name="invention_design"
+              label="发明(设计)人(其他)"
+              placeholder="请输入发明(设计)人(其他)"
+              :rules="[{ required: false, message: '请输入发明(设计)人(其他)' }]"
+            />
+            <van-field
+              v-model="form.incopat_link"
+              name="incopat_link"
+              label="链接到incoPat"
+              placeholder="请输入链接到incoPat"
+              :rules="[{ required: false, message: '请输入链接到incoPat' }]"
+            />
+            <van-field
+              v-model="form.first_ask"
+              name="first_ask"
+              label="首项权利要求"
+              placeholder="请输入首项权利要求"
+              type="textarea"
+              autosize
+              :rules="[{ required: false, message: '请输入首项权利要求' }]"
+            />
+            <van-field
+              v-model="form.first_apply"
+              name="first_apply"
+              label="第一申请人"
+              placeholder="请输入第一申请人"
+              :rules="[{ required: false, message: '请输入第一申请人' }]"
+            />
+            <van-field
+              v-model="form.apply_city"
+              name="apply_city"
+              label="中国申请人地市"
+              placeholder="请输入中国申请人地市"
+              :rules="[{ required: false, message: '请输入中国申请人地市' }]"
+            />
+            <van-field
+              v-model="form.business_code"
+              name="business_code"
+              label="工商统一社会信用代码"
+              placeholder="请输入工商统一社会信用代码"
+              :rules="[{ required: false, message: '请输入工商统一社会信用代码' }]"
+            />
+            <van-field
+              v-model="form.business_address"
+              name="business_address"
+              label="工商注册地址"
+              placeholder="请输入工商注册地址"
+              type="textarea"
+              autosize
+              :rules="[{ required: false, message: '请输入工商注册地址' }]"
+            />
+            <van-field
+              v-model="form.first_inventor"
+              name="first_inventor"
+              label="第一发明人"
+              placeholder="请输入第一发明人"
+              :rules="[{ required: false, message: '请输入第一发明人' }]"
+            />
+            <van-field
+              v-model="form.shared_value"
+              name="shared_value"
+              label="合享价值度"
+              placeholder="请输入合享价值度"
+              type="textarea"
+              autosize
+              :rules="[{ required: false, message: '请输入合享价值度' }]"
+            />
+            <van-field
+              v-model="form.techol_stable"
+              name="techol_stable"
+              label="技术稳定性"
+              placeholder="请输入技术稳定性"
+              type="textarea"
+              autosize
+              :rules="[{ required: false, message: '请输入技术稳定性' }]"
+            />
+            <van-field
+              v-model="form.techol_advanced"
+              name="techol_advanced"
+              label="技术先进性"
+              placeholder="请输入技术先进性"
+              type="textarea"
+              autosize
+              :rules="[{ required: false, message: '请输入技术先进性' }]"
+            />
+            <van-field
+              v-model="form.pct_apply"
+              name="pct_apply"
+              label="PCT国际申请号"
+              placeholder="请输入PCT国际申请号"
+              :rules="[{ required: false, message: '请输入PCT国际申请号' }]"
+            />
+            <van-field
+              v-model="form.pct_publish"
+              name="pct_publish"
+              label="PCT国际公布号"
+              placeholder="请输入PCT国际公布号"
+              :rules="[{ required: false, message: '请输入PCT国际公布号' }]"
+            />
+            <!-- 选择日期公用弹框 -->
+            <van-calendar v-model="calendarShow" @confirm="calendarCon" :min-date="minDate" :max-date="maxDate" />
+            <van-col span="24" class="btn">
+              <van-button type="info" size="small" native-type="submit">提交信息</van-button>
+            </van-col>
+          </van-form>
+        </van-col>
+      </van-col>
+    </van-row>
+    <van-dialog class="dialog" v-model="dialog.show" :title="dialog.title" :show-confirm-button="false" show-cancel-button>
+      <van-col span="24" class="one" v-if="dialog.type == '1'">
+        <van-col span="24" class="one_1">
+          <van-search v-model="searchName" show-action placeholder="请输入联系电话" @search="searchUser">
+            <template #action>
+              <div @click="searchUser">搜索</div>
+            </template>
+          </van-search>
+        </van-col>
+        <van-col span="24" class="one_2">
+          <van-col span="24" class="list" v-for="(item, index) in list" :key="index">
+            <van-col span="24" class="name"> {{ item.name }} </van-col>
+            <van-col span="24" class="other">
+              <van-col span="24" class="otherInfo">
+                联系电话:<span>{{ item.phone }}</span>
+              </van-col>
+            </van-col>
+            <van-col span="24" class="btn">
+              <van-button type="info" size="mini" @click.prevent="conFirm(item)">确认选择</van-button>
+            </van-col>
+          </van-col>
+          <van-col span="24" class="page">
+            <page @search="searchUser" :limit="limit" :total="total"></page>
+          </van-col>
+        </van-col>
+      </van-col>
+    </van-dialog>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: personal } = createNamespacedHelpers('personal');
+const { mapActions: upload } = createNamespacedHelpers('upload');
+var moment = require('moment');
+export default {
+  name: 'form-1',
+  props: {
+    form: { type: Object },
+  },
+  components: {},
+  data: function () {
+    return {
+      minDate: new Date(2000, 10, 1),
+      maxDate: new Date(2050, 10, 1),
+      calendarShow: false,
+      calendar_type: '',
+      // 发明人
+      dialog: { show: false, titla: '查询用户', type: '1' },
+      type: '',
+      // 查询
+      searchName: '',
+      list: [],
+      limit: 3,
+      total: 0,
+      // 添加发明人
+      addForm: {},
+    };
+  },
+  async created() {
+    await this.searchUser();
+  },
+  methods: {
+    ...personal({ personalQuery: 'query' }),
+    ...upload(['upload']),
+    onSubmit(value) {
+      if (value) this.$emit('onSubmit', { data: this.form });
+    },
+    // 查询用户
+    async searchUser({ skip = 0, limit = this.limit, ...info } = {}) {
+      if (this.searchName) info.phone = this.searchName;
+      let res = await this.personalQuery({ skip, limit, ...info });
+      if (this.$checkRes(res)) {
+        this.$set(this, `list`, res.data);
+        this.$set(this, `total`, res.total);
+      }
+    },
+    // 发明人,技术联系人
+    toSelect(type) {
+      this.$set(this, `type`, type);
+      this.dialog = { show: true, title: '查询用户', type: '1' };
+    },
+    // 确认选择
+    conFirm(data) {
+      let user = { user_id: data.id, name: data.name };
+      if (this.type == 'inventor') this.form[this.type].push(user);
+      this.dialog = { show: false, title: '查询用户', type: '1' };
+    },
+    // 删除发明人&技术联系人
+    delInv(data, type) {
+      this.form[type].splice(this.form[type].indexOf(data), 1);
+    },
+    // 打开选择日期弹框
+    selectDate(type) {
+      this.$set(this, `calendar_type`, type);
+      this.calendarShow = true;
+    },
+    // 选中日期
+    calendarCon(date) {
+      this.$set(this.form, this.calendar_type, moment(date).format('YYYY-MM-DD'));
+      this.calendarShow = false;
+    },
+    async toUpload({ file }, model) {
+      // 上传,赋值
+      const res = await this.upload({ file, dir: 'file' });
+      if (this.$checkRes(res)) {
+        this.$set(this.form, model, [{ name: res.name, url: res.uri }]);
+      }
+    },
+    toDelete(file, model) {
+      const index = this.form[model].findIndex((f) => _.isEqual(f, file));
+      this.form[model].splice(index, 1);
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped>
+.main {
+  .one {
+    .btn {
+      text-align: center;
+      margin: 10px 0;
+    }
+    .inventor {
+      background-color: #ffffff;
+      .txt {
+        padding: 5px 0px 0 18px;
+        font-size: 14px;
+        color: #666;
+      }
+      .btn {
+        text-align: center;
+        .van-button {
+          margin: 8px;
+        }
+      }
+      .list {
+        padding: 0px 18px;
+        .list_1 {
+          border: 1px dashed #409eff;
+          margin: 0 0 8px 0;
+          text-align: center;
+          padding: 5px;
+          p {
+            font-size: 14px;
+          }
+        }
+      }
+    }
+  }
+}
+.dialog {
+  /deep/.van-dialog__content {
+    max-height: 350px;
+    overflow-y: auto;
+  }
+  .one {
+    .one_2 {
+      .list {
+        border-bottom: 1px dashed #ccc;
+        margin: 0 0 8px 0;
+        padding: 0 8px 5px 8px;
+        .name {
+          font-size: 16px;
+          margin: 0 0 5px 0;
+        }
+        .other {
+          margin: 0 0 5px 0;
+          .otherInfo {
+            font-size: 14px;
+            color: #666;
+            span {
+              color: #000;
+            }
+          }
+        }
+        .btn {
+          text-align: center;
+        }
+      }
+    }
+  }
+  .two {
+    .btn {
+      margin: 8px 0;
+      text-align: center;
+    }
+  }
+}
+</style>

+ 97 - 0
src/layout/patentInfo/info-1.vue

@@ -0,0 +1,97 @@
+<template>
+  <div id="info-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-col span="24" class="one">
+          <van-image :src="img_url"></van-image>
+        </van-col>
+        <van-col span="24" class="two">
+          <van-form label-width="6em">
+            <van-field v-model="info.create_number" label="申请号" readonly />
+            <van-field v-model="info.create_date" label="申请日" readonly />
+            <van-field v-model="info.success_number" label="公开(公告)号" readonly />
+            <van-field v-model="info.success_date" label="公开(公告)日" readonly />
+            <van-field v-model="info.inventor" label="发明人" readonly />
+            <van-field v-model="info.agent" label="代理机构" readonly />
+            <van-field v-model="info.agent_personal" label="代理人" readonly />
+            <van-field v-model="info.abstract" label="摘要" type="textarea" autosize readonly />
+            <van-field v-model="info.address" label="发明人地址" readonly />
+            <van-field v-model="info.name" label="专利名称" readonly />
+            <van-field v-model="info.apply_personal" label="申请人" readonly />
+            <van-field v-model="info.term" label="专利有效性" readonly />
+            <van-field v-model="info.type" label="专利类型" readonly />
+            <van-field v-model="info.nationality" label="公开国别" readonly />
+            <van-field v-model="info.ipc_type" label="IPC主分类" readonly />
+            <van-field v-model="info.onlegal_status" label="当前法律状态" readonly />
+            <van-field v-model="info.legal_status" label="法律状态" readonly />
+            <van-field v-model="info.law_date" label="法律文书日期" readonly />
+            <van-field v-model="info.on_obligee" label="当前权利人" readonly />
+            <van-field v-model="info.apply_address" label="申请人地址(其他)" readonly />
+            <van-field v-model="info.apply_other" label="申请人(其他)" readonly />
+            <van-field v-model="info.law_num" label="法律文书编号" readonly />
+            <van-field v-model="info.first_opendate" label="首次公开日" readonly />
+            <van-field v-model="info.empower_date" label="授权公告日" readonly />
+            <van-field v-model="info.lose_date" label="失效日" readonly />
+            <van-field v-model="info.examine_date" label="实质审查生效日" readonly />
+            <van-field v-model="info.invention_design" label="发明(设计)人(其他)" readonly />
+            <van-field v-model="info.incopat_link" label="链接到incoPat" readonly />
+            <van-field v-model="info.first_ask" label="首项权利要求" type="textarea" autosize readonly />
+            <van-field v-model="info.first_apply" label="第一申请人" readonly />
+            <van-field v-model="info.apply_city" label="中国申请人地市" readonly />
+            <van-field v-model="info.business_code" label="工商统一社会信用代码" readonly />
+            <van-field v-model="info.business_address" label="工商注册地址" type="textarea" autosize readonly />
+            <van-field v-model="info.first_inventor" label="第一发明人" readonly />
+            <van-field v-model="info.shared_value" label="合享价值度" type="textarea" autosize readonly />
+            <van-field v-model="info.techol_stable" label="技术稳定性" type="textarea" autosize readonly />
+            <van-field v-model="info.techol_advanced" label="技术先进性" type="textarea" autosize readonly />
+            <van-field v-model="info.pct_apply" label="PCT国际申请号" readonly />
+            <van-field v-model="info.pct_publish" label="PCT国际公布号" readonly />
+          </van-form>
+        </van-col>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+export default {
+  name: 'info-1',
+  props: {
+    info: { type: Object },
+  },
+  components: {},
+  data: function () {
+    return { img_url: '' };
+  },
+  created() {},
+  methods: {
+    searchImg(data) {
+      if (data && data.length > 0) {
+        var url = data.map((item) => item.url)[0];
+        this.$set(this, `img_url`, url);
+      } else {
+        var url = require('@/assets/fmzl.jpg');
+        this.$set(this, `img_url`, url);
+      }
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    info: {
+      deep: true,
+      immediate: true,
+      handler(val) {
+        this.searchImg(val.img_url);
+      },
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 19 - 6
src/layout/patent/list-1.vue

@@ -15,17 +15,22 @@
             </van-col>
           </van-col>
           <van-col span="24" class="btn">
-            <van-button type="info" size="small" @click="toView(item)">查看信息</van-button>
-            <van-button type="info" size="small" @click="toAssess(item)" v-if="item.term != '失效'">价值评估</van-button>
-            <van-button type="info" size="small" @click="toTrans(item)" v-if="item.trans_status == '0' && item.term != '失效'">专利交易</van-button>
-            <van-button type="info" size="small" @click="toGzj(item)">反馈信息</van-button>
+            <van-button type="info" size="small" @click="toView(item)">详细信息</van-button>
+            <template v-if="user.role == '1'">
+              <van-button type="info" size="small" @click="toEdit(item)">修改信息</van-button>
+              <van-button type="danger" size="small" @click="toDel(item)">刪除信息</van-button>
+            </template>
+            <template v-else-if="user.role == '3'">
+              <van-button type="info" size="small" @click="toAssess(item)" v-if="item.term != '失效'">价值评估</van-button>
+              <van-button type="info" size="small" @click="toTrans(item)" v-if="item.trans_status == '0' && item.term != '失效'">专利交易</van-button>
+              <van-button type="info" size="small" @click="toGzj(item)">反馈信息</van-button>
+            </template>
           </van-col>
         </van-col>
       </van-col>
     </van-row>
   </div>
 </template>
-
 <script>
 import { mapState, createNamespacedHelpers } from 'vuex';
 const moment = require('moment');
@@ -38,10 +43,18 @@ export default {
   },
   created() {},
   methods: {
-    // 专利信息
+    // 详细信息
     toView(data) {
       this.$emit('toView', data);
     },
+    // 修改信息
+    toEdit(data) {
+      this.$emit('toEdit', data);
+    },
+    // 刪除信息
+    toDel(data) {
+      this.$emit('toDel', data);
+    },
     // 国知局反馈信息
     toGzj(data) {
       this.$router.push({ path: '/patent/user/apply/apply/gzjDetail', query: { name: data.name, create_number: data.create_number } });

+ 148 - 0
src/layout/patentInfo/search-1.vue

@@ -0,0 +1,148 @@
+<template>
+  <div id="search-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-col :span="24" class="one">
+          <van-form label-width="6em">
+            <van-field v-model="searchForm.apply_personal" name="apply_personal" label="申请人" placeholder="请输入申请人" />
+            <van-field v-model="searchForm.first_apply" name="first_apply" label="第一申请人" placeholder="请输入第一申请人" />
+            <van-field v-model="searchForm.on_obligee" name="on_obligee" label="当前权利人" placeholder="请输入当前权利人" />
+            <van-field name="term" label="专利有效性">
+              <template #input>
+                <van-radio-group v-model="searchForm.term" direction="horizontal">
+                  <van-radio name="有效">有效</van-radio>
+                  <van-radio name="审中">审中</van-radio>
+                  <van-radio name="失效">失效</van-radio>
+                </van-radio-group>
+              </template>
+            </van-field>
+            <van-field v-model="searchForm.key_word" name="key_word" label="标题或关键词" placeholder="请输入标题或关键词" />
+            <van-field name="type" label="专利类型">
+              <template #input>
+                <van-radio-group v-model="searchForm.type" direction="horizontal">
+                  <van-radio name="发明申请">发明申请</van-radio>
+                  <van-radio name="发明授权">发明授权</van-radio>
+                  <van-radio name="实用新型">实用新型</van-radio>
+                  <van-radio name="外观设计">外观设计</van-radio>
+                  <van-radio name="PCT国际申请号">PCT国际申请号</van-radio>
+                  <van-radio name="PCT国际公布号">PCT国际公布号</van-radio>
+                </van-radio-group>
+              </template>
+            </van-field>
+            <van-field v-model="searchForm.single_inventor" name="single_inventor" label="发明人" placeholder="请输入发明人" />
+            <van-field v-model="searchForm.first_inventor" name="first_inventor" label="第一发明人" placeholder="请输入第一发明人" />
+            <van-field v-model="searchForm.apply_city" name="apply_city" label="申请人地市" placeholder="请输入申请人地市" />
+            <van-field
+              readonly
+              clickable
+              name="calendar"
+              :value="searchForm['create_date@start']"
+              label="申请日(开始)"
+              placeholder="点击选择"
+              @click="changeCreate('create_date@start')"
+            />
+            <van-field
+              readonly
+              clickable
+              name="calendar"
+              :value="searchForm['create_date@end']"
+              label="申请日(结束)"
+              placeholder="点击选择"
+              @click="changeCreate('create_date@end')"
+            />
+            <van-field
+              readonly
+              clickable
+              name="calendar"
+              :value="searchForm['empower_date@start']"
+              label="授权公告日(开始)"
+              placeholder="点击选择"
+              @click="changeCreate('empower_date@start')"
+            />
+            <van-field
+              readonly
+              clickable
+              name="calendar"
+              :value="searchForm['empower_date@end']"
+              label="授权公告日(结束)"
+              placeholder="点击选择"
+              @click="changeCreate('empower_date@end')"
+            />
+            <van-field v-model="searchForm.create_number" name="create_number" label="申请号" placeholder="请输入申请号" />
+            <van-calendar v-model="oneShow" @confirm="oneChange" position="right" :min-date="minDate" :max-date="maxDate" />
+            <div class="btn">
+              <van-button type="info" size="small" @click="reseat">重置条件</van-button>
+              <van-button type="primary" size="small" @click="onSubmit">提交查询</van-button>
+            </div>
+          </van-form>
+        </van-col>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+const moment = require('moment');
+export default {
+  name: 'search-1',
+  props: {
+    searchForm: { type: Object },
+  },
+  components: {},
+  data: function () {
+    return {
+      // 选择申请日
+      oneShow: false,
+      minDate: new Date(1900, 1, 1),
+      maxDate: new Date(2050, 1, 1),
+      type: '',
+    };
+  },
+  created() {},
+  methods: {
+    reseat() {
+      this.$emit('reseat');
+    },
+    onSubmit() {
+      this.$emit('onSubmit', { data: this.searchForm });
+    },
+    changeCreate(type) {
+      this.$set(this, `type`, type);
+      this.oneShow = true;
+    },
+    // 选择申请日
+    oneChange(value) {
+      this.$set(this.searchForm, this.type, moment(value).format('YYYY-MM-DD'));
+      this.oneShow = false;
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped>
+.main {
+  .one {
+    .btn {
+      text-align: center;
+      margin: 10px 0;
+      .van-button {
+        margin: 0 5px;
+      }
+    }
+  }
+}
+</style>

+ 209 - 0
src/layout/patentInfo/trans-1.vue

@@ -0,0 +1,209 @@
+<template>
+  <div id="trans-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-col span="24" class="one">
+          <van-form @submit="onSubmit" label-width="5em">
+            <van-field v-model="form.user_id" name="user_id" label="用户id" style="display: none" />
+            <van-field v-model="form.user_name" name="user_name" label="用户姓名" style="display: none" />
+            <van-field v-model="form.mech_id" name="mech_id" label="机构id" style="display: none" />
+            <van-field v-model="form.mech_name" name="mech_name" label="机构姓名" style="display: none" />
+            <van-field v-model="form.patent_id" name="patent_id" label="专利id" style="display: none" />
+            <van-field v-model="form.patent_name" name="patent_name" label="专利名称" readonly />
+            <van-field v-model="form.create_number" name="create_number" label="专利号" readonly />
+            <van-field v-model="form.on_obligee" name="on_obligee" label="当前权利人" readonly />
+            <van-field v-model="form.contact" name="contact" label="联系人" placeholder="请输入联系人" :rules="[{ required: true, message: '请输入联系人' }]" />
+            <van-field
+              v-model="form.phone"
+              name="phone"
+              label="联系电话"
+              placeholder="请输入联系电话"
+              :rules="[{ required: true, message: '请输入联系电话' }]"
+            />
+            <van-field
+              v-model="form.email"
+              name="email"
+              label="电子邮箱"
+              placeholder="请输入电子邮箱"
+              :rules="[{ required: true, message: '请输入电子邮箱' }]"
+            />
+            <van-field
+              v-model="form.budget"
+              name="budget"
+              type="digit"
+              label="投资预算(万元)"
+              placeholder="请输入投资预算"
+              :rules="[{ required: true, message: '请输入投资预算' }]"
+            />
+            <van-field name="type" label="交易类型" :rules="[{ required: true, message: '交易类型' }]">
+              <template #input>
+                <van-radio-group v-model="form.type" direction="horizontal">
+                  <van-radio name="转让">转让</van-radio>
+                  <van-radio name="许可">许可</van-radio>
+                  <van-radio name="免费许可">免费许可</van-radio>
+                  <van-radio name="招商">招商</van-radio>
+                  <van-radio name="质押">质押</van-radio>
+                </van-radio-group>
+              </template>
+            </van-field>
+            <van-col span="24" class="typeThr" v-if="form.type == '免费许可'">
+              <van-col span="24" class="title"> 免费许可承诺书 </van-col>
+              <van-col span="24" class="info">
+                公开声明:【{{ form.patent_name }}】专利权人许可本专利在【
+                <span @click.prevent="typeSelect('province')">{{ form.promise_file.province }}</span>
+                】【
+                <span @click.prevent="typeSelect('city')">{{ form.promise_file.city }}</span>
+                】范围内免费使用,期限至【
+                <span @click.prevent="typeSelect('end_date')">{{ form.promise_file.end_date }}</span>
+                】止,被许可人需与许可人签订许可合同后方可使用。
+              </van-col>
+              <van-popup v-model="oneShow" position="bottom">
+                <van-picker show-toolbar :columns="provinceList" @confirm="oneFirm" @cancel="oneShow = false" />
+              </van-popup>
+              <van-popup v-model="twoShow" position="bottom">
+                <van-picker show-toolbar :columns="cityList" @confirm="twoFirm" @cancel="twoShow = false" />
+              </van-popup>
+              <van-calendar v-model="thrShow" @confirm="thrFirm" :min-date="minDate" :max-date="maxDate" />
+            </van-col>
+            <van-field name="is_report" label="评估报告">
+              <template #input>
+                <van-radio-group v-model="form.is_report" direction="horizontal">
+                  <van-radio :name="true">有</van-radio>
+                  <van-radio :name="false">无</van-radio>
+                </van-radio-group>
+              </template>
+            </van-field>
+            <van-field name="report" label="报告文件">
+              <template #input>
+                <van-uploader
+                  :fileList="form.report"
+                  :max-count="1"
+                  :after-read="(file) => toUpload(file, 'report')"
+                  @delete="(file) => toDelete(file, 'report')"
+                />
+              </template>
+            </van-field>
+            <van-field v-model="form.requirementdesc" name="requirementdesc" label="技术说明" placeholder="请输入技术说明" type="textarea" autosize />
+            <van-field v-model="form.expect" name="expect" label="商业预期" placeholder="请输入商业预期" type="textarea" autosize />
+            <van-field v-model="form.condition" name="condition" label="合作条件及要求" placeholder="请输入合作条件及要求" type="textarea" autosize />
+            <van-col span="24" class="btn">
+              <van-button type="info" size="small" native-type="submit">提交交易</van-button>
+            </van-col>
+          </van-form>
+        </van-col>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: upload } = createNamespacedHelpers('upload');
+const moment = require('moment');
+export default {
+  name: 'trans-1',
+  props: {
+    form: { type: Object },
+  },
+  components: {},
+  data: function () {
+    return {
+      type: '',
+      // 省份
+      oneShow: false,
+      provinceList: ['吉林省'],
+      // 城市
+      twoShow: false,
+      cityList: ['长春市', '吉林市', '四平市', '辽源市', '通化市', '白山市', '白城市', '延边州', '松原市', '长白山管委会'],
+      // 截止日期
+      thrShow: false,
+      minDate: new Date(1900, 1, 1),
+      maxDate: new Date(2050, 1, 1),
+    };
+  },
+  created() {},
+  methods: {
+    ...upload(['upload']),
+    onSubmit(value) {
+      if (value) this.$emit('onSubmit', { data: this.form });
+    },
+    // 承诺书信息
+    typeSelect(type) {
+      this.$set(this, `type`, type);
+      if (type == 'province') this.oneShow = true;
+      else if (type == 'city') this.twoShow = true;
+      else if (type == 'end_date') this.thrShow = true;
+    },
+    // 确认选择省份
+    oneFirm(value) {
+      this.$set(this.form.promise_file, `${this.type}`, value);
+      this.oneShow = false;
+    },
+    // 确认选择城市
+    twoFirm(value) {
+      this.$set(this.form.promise_file, `${this.type}`, value);
+      this.twoShow = false;
+    },
+    // 确认选择日历
+    thrFirm(value) {
+      this.$set(this.form.promise_file, `${this.type}`, moment(value).format('YYYY-MM-DD'));
+      this.thrShow = false;
+    },
+    async toUpload({ file }, model) {
+      // 上传,赋值
+      const res = await this.upload({ file, dir: 'file' });
+      if (this.$checkRes(res)) {
+        this.$set(this.form, model, [{ name: res.name, url: res.uri }]);
+      }
+    },
+    toDelete(file, model) {
+      const index = this.form[model].findIndex((f) => _.isEqual(f, file));
+      this.form[model].splice(index, 1);
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped>
+.main {
+  .one {
+    .btn {
+      text-align: center;
+      margin: 10px 0;
+    }
+    .typeThr {
+      padding: 10px;
+      background-color: #fff;
+      .title {
+        text-align: center;
+        font-weight: bold;
+        margin: 0 0 15px 0;
+      }
+      .info {
+        padding: 0 0 15px 0;
+        line-height: 25px;
+        border-bottom: 1px solid #ebedf0;
+        span {
+          color: #409eff;
+        }
+        span:hover {
+          cursor: pointer;
+        }
+      }
+    }
+  }
+}
+</style>

+ 84 - 0
src/layout/question/assign-1.vue

@@ -0,0 +1,84 @@
+<template>
+  <div id="assign-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-col span="24" class="one">
+          <van-form @submit="onSubmit">
+            <van-field v-model="form.answer_id" name="answer_id" label="答题人id" style="display: none" />
+            <van-field
+              readonly
+              clickable
+              name="answer_name"
+              :value="form.answer_name"
+              label="答题人"
+              placeholder="点击选择"
+              @click="showPicker = true"
+              :rules="[{ required: true, message: '答题人' }]"
+            />
+            <van-popup v-model="showPicker" position="bottom">
+              <van-picker show-toolbar :columns="answernameList" value-key="name" @confirm="answerCon" @cancel="showPicker = false" />
+            </van-popup>
+            <div style="margin: 16px">
+              <van-button round block type="info" native-type="submit">提交</van-button>
+            </div>
+          </van-form>
+        </van-col>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: answer_tea } = createNamespacedHelpers('answer_tea');
+
+export default {
+  name: 'assign-1',
+  props: {
+    form: { type: Object },
+  },
+  components: {},
+  data: function () {
+    return {
+      answernameList: [],
+      showPicker: false,
+    };
+  },
+  created() {
+    this.search();
+  },
+  methods: {
+    ...answer_tea(['query']),
+    async search() {
+      let res = await this.query();
+      if (this.$checkRes(res)) {
+        this.$set(this, `answernameList`, res.data);
+      }
+    },
+    answerCon(values) {
+      this.$set(this.form, `answer_id`, values.id);
+      this.$set(this.form, `answer_name`, values.name);
+      this.showPicker = false;
+    },
+    // 提交
+    onSubmit(values) {
+      if (values) this.$emit('onSubmit', { data: this.form });
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 105 - 0
src/layout/question/form-1.vue

@@ -0,0 +1,105 @@
+<template>
+  <div id="form-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-form @submit="onSubmit">
+          <van-field v-model="form.ask_id" name="ask_id" label="发问人id" style="display: none" />
+          <van-field v-model="form.ask_name" name="ask_name" label="发问人" :rules="[{ required: true, message: '发问人' }]" />
+          <van-field v-model="form.name" name="name" label="问题名称" placeholder="请填写问题名称" :rules="[{ required: true, message: '问题名称' }]" />
+          <van-field
+            readonly
+            clickable
+            name="calendar"
+            :value="form.ask_date"
+            label="发问时间"
+            placeholder="点击选择日期"
+            @click="showCalendar = true"
+            :rules="[{ required: true, message: '发问时间' }]"
+          />
+          <van-calendar v-model="showCalendar" @confirm="onConfirm" />
+          <van-field
+            v-model="form.ask_explain"
+            name="ask_explain"
+            label="问题说明"
+            placeholder="请填写问题说明"
+            autosize
+            type="textarea"
+            :rules="[{ required: true, message: '问题说明' }]"
+          />
+          <van-field name="ask_file" label="问题文件" :rules="[{ required: true, message: '问题文件' }]">
+            <template #input>
+              <van-uploader
+                :fileList="form.ask_file"
+                :max-count="1"
+                :after-read="(file) => toUpload(file, 'ask_file')"
+                @delete="(file) => toDelete(file, 'ask_file')"
+                accept="file"
+              />
+            </template>
+          </van-field>
+          <div style="margin: 16px">
+            <van-button round block type="info" native-type="submit">提交</van-button>
+          </div>
+        </van-form>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: upload } = createNamespacedHelpers('upload');
+
+const moment = require('moment');
+export default {
+  name: 'form-1',
+  props: {
+    form: { type: Object },
+  },
+  components: {},
+  data: function () {
+    return {
+      // 发问时间
+      showCalendar: false,
+    };
+  },
+  created() {},
+  methods: {
+    ...upload(['upload']),
+    onSubmit(values) {
+      if (values) this.$emit('onSubmit', { data: this.form });
+    },
+    // 确认选择时间
+    onConfirm(values) {
+      this.$set(this.form, 'ask_date', moment(values).format('YYYY-MM-DD'));
+      this.showCalendar = false;
+    },
+    async toUpload({ file }, model) {
+      // 上传,赋值
+      const res = await this.upload({ file, dir: 'file' });
+      if (this.$checkRes(res)) {
+        this.$set(this.form, model, [{ name: res.name, url: res.uri }]);
+      }
+    },
+    toDelete(file, model) {
+      const index = this.form[model].findIndex((f) => _.isEqual(f, file));
+      this.form[model].splice(index, 1);
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 89 - 0
src/layout/question/info-1.vue

@@ -0,0 +1,89 @@
+<template>
+  <div id="info-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-col span="24" class="one">
+          <van-form>
+            <van-field v-model="info.name" name="name" label="问题名称" readonly />
+            <van-field v-model="info.ask_name" name="ask_name" label="发问人" readonly />
+            <van-field v-model="info.ask_date" name="ask_date" label="发问时间" readonly />
+            <van-field v-model="info.ask_explain" name="ask_explain" label="问题说明" autosize type="textarea" readonly />
+            <van-field v-model="info.answer_name" name="answer_name" label="答题人" readonly />
+            <van-field v-model="info.answer_date" name="answer_date" label="答题时间" readonly />
+            <van-field v-model="info.answer_explain" name="ask_explain" label="答题说明" autosize type="textarea" readonly />
+            <van-col span="24" class="btn">
+              <van-button type="info" size="small" @click="download(info.ask_file)" v-if="info.ask_id != user.id">问题文件下载</van-button>
+              <van-button type="info" size="small" @click="download(info.answer_file)" v-if="info.status == '3' || info.status == '4'">答案文件下载</van-button>
+              <van-button type="info" size="small" @click="onSubmit()" v-if="info.status == '3' && info.ask_id == user.id">信息已读</van-button>
+            </van-col>
+          </van-form>
+        </van-col>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+export default {
+  name: 'info-1',
+  props: {
+    info: { type: Object },
+  },
+  components: {},
+  data: function () {
+    return {};
+  },
+  created() {},
+  methods: {
+    onSubmit() {
+      this.$emit('onSubmit', { data: this.info });
+    },
+    // 问题文件下载
+    askDownload(data) {
+      if (data && data.length > 0) {
+        let url = data.map((i) => i.url);
+        window.location.href = `${process.env.VUE_APP_HOST}${url[0]}`;
+      } else {
+        this.$toast({ type: `fail`, message: `非正常文件,无法下载` });
+      }
+    },
+    // 下载文件
+    download(data) {
+      if (data && data.length > 0) {
+        let url = data.map((i) => i.url);
+        window.location.href = `${process.env.VUE_APP_HOST}${url[0]}`;
+      } else {
+        this.$toast({ type: `fail`, message: `非正常文件,无法下载` });
+      }
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped>
+.main {
+  .one {
+    .btn {
+      text-align: center;
+      margin: 10px 0;
+      .van-button {
+        margin: 0 10px;
+      }
+    }
+  }
+}
+</style>

+ 98 - 0
src/layout/question/list-1.vue

@@ -0,0 +1,98 @@
+<template>
+  <div id="list-1">
+    <van-col span="24" class="main">
+      <van-col span="24" class="list" v-for="(item, index) in list" :key="index">
+        <van-col span="24" class="title">
+          {{ item.name }}
+        </van-col>
+        <van-col span="24" class="other">
+          <van-col span="24" class="otherInfo">
+            发问时间:<span>{{ item.ask_date || '暂无' }}</span>
+          </van-col>
+          <van-col span="24" class="otherInfo">
+            答题时间:<span>{{ item.answer_date || '暂无' }}</span>
+          </van-col>
+          <van-col span="24" class="otherInfo">
+            问题状态:<span>{{ getStu(item.status) }}</span>
+          </van-col>
+        </van-col>
+        <van-col span="24" class="btn">
+          <van-button type="info" size="small" @click="toView(item)">查看信息</van-button>
+        </van-col>
+      </van-col>
+    </van-col>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+export default {
+  name: 'list-1',
+  props: {
+    list: { type: Array },
+  },
+  components: {},
+  data: function () {
+    return {};
+  },
+  created() {},
+  methods: {
+    toView(data) {
+      this.$emit('toView', data);
+    },
+    // 整理状态
+    getStu(data) {
+      if (data == '0') return '待受理';
+      else if (data == '1') return '已分配,待作答';
+      else if (data == '2') return '已作答,待下发';
+      else if (data == '3') return '已下发,待阅读';
+      else if (data == '4') return '已阅读';
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped>
+.main {
+  .list {
+    background-color: #fff;
+    margin: 0 0 8px 0;
+    padding: 8px;
+    border-radius: 5px;
+    .title {
+      font-size: 16px;
+      font-weight: bold;
+      margin: 0 0 5px 0;
+    }
+    .other {
+      .otherInfo {
+        font-size: 14px;
+        color: #666;
+        margin: 0 0 5px 0;
+        span {
+          color: #000;
+        }
+      }
+    }
+    .btn {
+      text-align: center;
+      .van-button {
+        margin: 0 10px;
+      }
+    }
+  }
+}
+</style>

+ 113 - 0
src/layout/question/list-2.vue

@@ -0,0 +1,113 @@
+<template>
+  <div id="list-2">
+    <van-col span="24" class="main">
+      <van-col span="24" class="list" v-for="(item, index) in list" :key="index">
+        <van-col span="24" class="title">
+          {{ item.name }}
+        </van-col>
+        <van-col span="24" class="other">
+          <van-col span="24" class="otherInfo">
+            发问时间:<span>{{ item.ask_date || '暂无' }}</span>
+          </van-col>
+          <van-col span="24" class="otherInfo">
+            答题时间:<span>{{ item.answer_date || '暂无' }}</span>
+          </van-col>
+          <van-col span="24" class="otherInfo">
+            问题状态:<span>{{ getStu(item.status) }}</span>
+          </van-col>
+        </van-col>
+        <van-col span="24" class="btn">
+          <van-button type="info" size="small" @click="toView(item)">查看信息</van-button>
+          <van-button type="info" size="small" @click="toAssign(item)" v-if="item.status == '0'">工作分派</van-button>
+          <van-button type="info" size="small" @click="toUpload(item)" v-if="item.status == '1' && item.answer_id == user.id">答案上传</van-button>
+          <van-button type="info" size="small" @click="toIssue(item)" v-if="item.status == '2' && item.answer_id != user.id">答案下发</van-button>
+        </van-col>
+      </van-col>
+    </van-col>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+export default {
+  name: 'list-2',
+  props: {
+    list: { type: Array },
+  },
+  components: {},
+  data: function () {
+    return {};
+  },
+  created() {},
+  methods: {
+    toView(data) {
+      this.$emit('toView', data);
+    },
+    // 工作分派
+    toAssign(data) {
+      this.$emit('toAssign', data);
+    },
+    //答案上传
+    toUpload(data) {
+      this.$emit('toUpload', data);
+    },
+    // 答案下发
+    toIssue(data) {
+      this.$emit('toIssue', data);
+    },
+    // 整理状态
+    getStu(data) {
+      if (data == '0') return '待受理';
+      else if (data == '1') return '已分配,待作答';
+      else if (data == '2') return '已作答,待下发';
+      else if (data == '3') return '已下发,待阅读';
+      else if (data == '4') return '已阅读';
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped>
+.main {
+  .list {
+    background-color: #fff;
+    margin: 0 0 8px 0;
+    padding: 8px;
+    border-radius: 5px;
+    .title {
+      font-size: 16px;
+      font-weight: bold;
+      margin: 0 0 5px 0;
+    }
+    .other {
+      .otherInfo {
+        font-size: 14px;
+        color: #666;
+        margin: 0 0 5px 0;
+        span {
+          color: #000;
+        }
+      }
+    }
+    .btn {
+      text-align: center;
+      .van-button {
+        margin: 0 10px;
+      }
+    }
+  }
+}
+</style>

+ 104 - 0
src/layout/question/upload-1.vue

@@ -0,0 +1,104 @@
+<template>
+  <div id="upload-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-col span="24" class="one">
+          <van-form @submit="onSubmit">
+            <van-field v-model="form.id" name="id" label="数据id" style="display: none" />
+            <van-field
+              readonly
+              clickable
+              name="calendar"
+              :value="form.answer_date"
+              label="答题时间"
+              placeholder="点击选择日期"
+              @click="showCalendar = true"
+              :rules="[{ required: true, message: '答题时间' }]"
+            />
+            <van-calendar v-model="showCalendar" @confirm="onConfirm" />
+            <van-field
+              v-model="form.answer_explain"
+              name="answer_explain"
+              label="答题说明"
+              autosize
+              type="textarea"
+              :rules="[{ required: true, message: '答题说明' }]"
+            />
+            <van-field name="answer_file" label="答题文件" :rules="[{ required: true, message: '答题文件' }]">
+              <template #input>
+                <van-uploader
+                  :fileList="form.answer_file"
+                  :max-count="1"
+                  :after-read="(file) => toUpload(file, 'answer_file')"
+                  @delete="(file) => toDelete(file, 'answer_file')"
+                  accept="file"
+                />
+              </template>
+            </van-field>
+            <div style="margin: 16px">
+              <van-button round block type="info" native-type="submit">提交</van-button>
+            </div>
+          </van-form>
+        </van-col>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: upload } = createNamespacedHelpers('upload');
+const moment = require('moment');
+export default {
+  name: 'upload-1',
+  props: {
+    form: { type: Object },
+  },
+  components: {},
+  data: function () {
+    return {
+      // 答题时间
+      showCalendar: false,
+    };
+  },
+  created() {},
+  methods: {
+    ...upload(['upload']),
+    // 提交
+    onSubmit(values) {
+      if (values) this.$emit('onSubmit', { data: this.form });
+    },
+    // 确认选择时间
+    onConfirm(values) {
+      this.$set(this.form, 'answer_date', moment(values).format('YYYY-MM-DD'));
+      this.showCalendar = false;
+    },
+    async toUpload({ file }, model) {
+      // 上传,赋值
+      const res = await this.upload({ file, dir: 'file' });
+      if (this.$checkRes(res)) {
+        this.$set(this.form, model, [{ name: res.name, url: res.uri }]);
+      }
+    },
+    toDelete(file, model) {
+      const index = this.form[model].findIndex((f) => _.isEqual(f, file));
+      this.form[model].splice(index, 1);
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 3 - 3
src/layout/trans/contract-1.vue

@@ -51,8 +51,8 @@
               <span>第八条 本合同一式三份,双方各执一份,备案一份。</span>
             </van-col>
             <van-col span="24" class="btn">
-              <van-button type="info" size="small" @click="onSubmit('2')">合同通过</van-button>
-              <van-button type="danger" size="small" @click="onSubmit('-1')">合同拒绝</van-button>
+              <van-button type="info" size="small" @click="onSubmit('3')">合同通过</van-button>
+              <van-button type="danger" size="small" @click="onSubmit('-3')">合同拒绝</van-button>
             </van-col>
           </van-form>
         </van-col>
@@ -75,7 +75,7 @@ export default {
   created() {},
   methods: {
     onSubmit(status) {
-      this.$emit('onSubmit', status);
+      this.$emit('onSubmit', { data: this.form, status: status });
     },
   },
 

+ 0 - 1
src/layout/trans/endtrans-1.vue

@@ -5,7 +5,6 @@
         <van-col span="24" class="one">
           <van-form @submit="onSubmit">
             <van-field v-model="form.id" name="id" label="数据id" readonly style="display: none" />
-            <van-field v-model="form.patent_id" name="patent_id" label="专利id" readonly style="display: none" />
             <van-field v-model="form.patent_name" name="patent_name" label="专利名称" autosize rows="1" type="textarea" readonly />
             <van-field v-model="form.on_obligee" name="on_obligee" label="当前权利人" readonly />
             <van-field v-model="form.on_afterobligee" name="on_afterobligee" label="变更后权利人" :rules="[{ required: true, message: '变更后权利人' }]" />

+ 72 - 0
src/layout/trans/examine-1.vue

@@ -0,0 +1,72 @@
+<template>
+  <div id="examine-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-col span="24" class="one">
+          <van-form @submit="onSubmit">
+            <van-field v-model="form.id" name="id" label="数据id" readonly style="display: none" />
+            <van-field v-model="form.patent_name" name="patent_name" label="专利名称" readonly />
+            <van-field name="status" label="审核状态">
+              <template #input>
+                <van-radio-group v-model="form.status" direction="horizontal">
+                  <van-radio name="1">通过</van-radio>
+                  <van-radio name="-1">拒绝</van-radio>
+                </van-radio-group>
+              </template>
+            </van-field>
+            <van-field
+              v-model="form.remark"
+              name="remark"
+              rows="1"
+              autosize
+              label="审核意见"
+              type="textarea"
+              maxlength="100"
+              placeholder="审核意见"
+              show-word-limit
+              :rules="[{ required: true, message: '审核意见' }]"
+            />
+            <div style="margin: 16px">
+              <van-button round block type="info" native-type="submit">提交</van-button>
+            </div>
+          </van-form>
+        </van-col>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+export default {
+  name: 'examine-1',
+  props: {
+    form: { type: Object },
+  },
+  components: {},
+  data: function () {
+    return {};
+  },
+  created() {},
+  methods: {
+    onSubmit(value) {
+      this.$emit('onSubmit', value);
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 9 - 11
src/layout/trans/form-1.vue

@@ -4,34 +4,32 @@
       <van-col span="24" class="main">
         <van-col span="24" class="one">
           <van-form @submit="onSubmit">
-            <van-field v-model="form.patent_id" name="patent_id" label="专利id" style="display: none" />
-            <van-field v-model="form.transfer_id" name="transfer_id" label="机构id" style="display: none" />
             <van-col span="24" class="one_1"> 专利转让合同 </van-col>
             <van-col span="24" class="one_2">
               <span>甲方(转让方):</span>
-              <van-field v-model="form.transfer" name="transfer" />
+              <van-field v-model="form.contract.transfer" name="transfer" />
             </van-col>
             <van-col span="24" class="one_2">
               <span>乙方(受让方):</span>
-              <van-field v-model="form.transferee" name="transferee" />
+              <van-field v-model="form.contract.transferee" name="transferee" />
             </van-col>
             <van-col span="24" class="one_3"> 甲、乙方经过平等协商,自愿订立专利权转让合同,并共同遵照执行: </van-col>
             <van-col span="24" class="one_4">
               <span>第一条 甲方将其享有的</span>
-              <van-field v-model="form.patent_name" name="patent_name" />
+              <van-field v-model="form.contract.patent_name" name="patent_name" />
               <span>专利权有偿转让给乙方,专利号为:</span>
-              <van-field v-model="form.create_number" name="create_number" />
+              <van-field v-model="form.contract.create_number" name="create_number" />
             </van-col>
             <van-col span="24" class="one_5">
               <span>第二条 甲方向乙方转让</span>
-              <van-field v-model="form.patent_right" name="patent_right" />
+              <van-field v-model="form.contract.patent_right" name="patent_right" />
               <span>专利权;</span>
             </van-col>
             <van-col span="24" class="one_6">
               <span>第三条 乙方为此向甲方支付专利权转让费用</span>
-              <van-field v-model="form.money" name="money" />
+              <van-field v-model="form.contract.money" name="money" />
               <span>元,于本合同生效后</span>
-              <van-field v-model="form.days" name="days" />
+              <van-field v-model="form.contract.days" name="days" />
               <span>天内一次付清。</span>
             </van-col>
             <van-col span="24" class="one_7">第四条 如任何一方违反本合同约定给对方造成损失,守约方可以要求对方承担违约责任;</van-col>
@@ -39,7 +37,7 @@
             <van-col span="24" class="one_7">第六条 本合同于各方签字盖章后生效,未经各方同意,任何一方均无权修改或变更本合同约定;</van-col>
             <van-col span="24" class="one_8">
               <span>第七条 任何因本合同的履行而产生的争议,均应当友好协商解决,如无法协商解决,各方同意交由</span>
-              <van-field v-model="form.arbirate" name="arbirate" />
+              <van-field v-model="form.contract.arbirate" name="arbirate" />
               <span>仲裁委员会按照该会现时有效的仲裁规则予以仲裁;</span>
             </van-col>
             <van-col span="24" class="one_7"> 第八条 本合同一式三份,双方各执一份,备案一份。 </van-col>
@@ -67,7 +65,7 @@ export default {
   created() {},
   methods: {
     onSubmit(values) {
-      this.$emit('onSubmit', values);
+      this.$emit('onSubmit', { data: this.form });
     },
   },
   computed: {

+ 37 - 15
src/layout/trans/info-1.vue

@@ -3,29 +3,36 @@
     <van-row>
       <van-col span="24" class="main">
         <van-col span="24" class="one">
-          <van-form label-width="7em">
-            <van-field v-model="info.create_number" name="create_number" label="申请号" readonly />
+          <van-form label-width="5em">
             <van-field v-model="info.patent_name" name="patent_name" label="专利名称" readonly />
+            <van-field v-model="info.create_number" name="create_number" label="专利号" readonly />
+            <van-field v-model="info.on_obligee" name="on_obligee" label="当前权利人" readonly />
             <van-field v-model="info.contact" name="contact" label="联系人" readonly />
             <van-field v-model="info.phone" name="phone" label="联系电话" readonly />
             <van-field v-model="info.email" name="email" label="电子邮箱" readonly />
-            <van-field v-model="info.budget" name="budget" type="digit" label="投资预算" readonly />
+            <van-field v-model="info.budget" name="budget" type="digit" label="投资预算(万元)" readonly />
             <van-field v-model="info.type" name="type" label="交易类型" readonly />
-            <van-field v-model="info.on_obligee" name=" on_obligee" label="变更前权利人" readonly />
-            <van-field v-model="info.on_afterobligee" name=" on_afterobligee" label="变更后权利人" readonly />
-            <van-field v-model="info.transfer_date" name=" transfer_date" label="专利权转移日期" readonly />
-            <van-field name="is_report" label="评估报告">
+            <van-col span="24" class="typeThr" v-if="info.type == '免费许可'">
+              <van-col span="24" class="title"> 免费许可承诺书 </van-col>
+              <van-col span="24" class="info">
+                公开声明:【{{ info.patent_name }}】专利权人许可本专利在【
+                <span>{{ info.promise_file.province }}</span>
+                】【
+                <span>{{ info.promise_file.city }}</span>
+                】范围内免费使用,期限至【
+                <span>{{ info.promise_file.end_date }}</span>
+                】止,被许可人需与许可人签订许可合同后方可使用。
+              </van-col>
+            </van-col>
+            <van-col span="24" style="text-align: center"> </van-col>
+            <van-field label="报告文件">
               <template #input>
-                <van-radio-group v-model="info.is_report" direction="horizontal" disabled>
-                  <van-radio :name="true">有</van-radio>
-                  <van-radio :name="false">无</van-radio>
-                </van-radio-group>
                 <van-button type="info" size="small" v-if="info.is_report == true" @click="download(info.report)">下载报告</van-button>
               </template>
             </van-field>
-            <van-field v-model="info.requirementdesc" name="requirementdesc" label="技术说明" rows="1" autosize type="textarea" readonly />
-            <van-field v-model="info.expect" name="expect" label="商业预期" rows="1" autosize type="textarea" readonly />
-            <van-field v-model="info.condition" name="condition" label="条件及要求" rows="1" autosize type="textarea" readonly />
+            <van-field v-model="info.requirementdesc" name="requirementdesc" label="技术说明" readonly />
+            <van-field v-model="info.expect" name="expect" label="商业预期" readonly />
+            <van-field v-model="info.condition" name="condition" label="合作条件及要求" readonly />
           </van-form>
         </van-col>
       </van-col>
@@ -72,4 +79,19 @@ export default {
 };
 </script>
 
-<style lang="less" scoped></style>
+<style lang="less" scoped>
+.typeThr {
+  padding: 10px;
+  background-color: #fff;
+  .title {
+    text-align: center;
+    font-weight: bold;
+    margin: 0 0 15px 0;
+  }
+  .info {
+    padding: 0 0 15px 0;
+    line-height: 25px;
+    border-bottom: 1px solid #ebedf0;
+  }
+}
+</style>

+ 48 - 17
src/layout/trans/list-1.vue

@@ -18,11 +18,21 @@
             </van-col>
           </van-col>
           <van-col span="24" class="btn">
-            <van-button type="info" size="small" @click="toView(item)">查看信息</van-button>
-            <van-button type="danger" size="small" @click="toRevoke(item)" v-if="item.status == '0'">撤回交易</van-button>
-            <van-button type="info" size="small" @click="toContract(item)" v-if="item.status == '0' || item.status == '-1'">填写合同</van-button>
-            <van-button type="info" size="small" @click="toConfirm(item)" v-if="item.status == '2'">用户确认</van-button>
-            <van-button type="info" size="small" @click="toEndtrans(item)" v-if="item.status == '0'">结束交易</van-button>
+            <van-button type="info" size="small" @click="toView(item)">详细信息</van-button>
+            <template v-if="user.role == '1'"> </template>
+            <template v-else-if="user.role == '2'">
+              <van-button type="info" size="small" @click="toExamine(item)" v-if="item.status == '0'">交易审核</van-button>
+              <van-button type="info" size="small" @click="toContact(item)" v-if="item.status == '2'">合同审核</van-button>
+              <van-button type="info" size="small" @click="toCheck(item)" v-if="item.status == '4'">交易归档</van-button>
+            </template>
+            <template v-else-if="user.role == '3'">
+              <van-button type="info" size="small" @click="toResult(item)" v-if="item.status == '-1'">审核结果</van-button>
+              <van-button type="info" size="small" @click="toHeavy(item)" v-if="item.status == '-1'">重申交易</van-button>
+              <van-button type="danger" size="small" @click="toRevoke(item)" v-if="item.status == '1'">撤回交易</van-button>
+              <van-button type="info" size="small" @click="toContract(item)" v-if="item.status == '1' || item.status == '-3'">填写合同</van-button>
+              <van-button type="info" size="small" @click="toEndtrans(item)" v-if="item.status == '1'">结束交易</van-button>
+              <van-button type="info" size="small" @click="toConfirm(item)" v-if="item.status == '3'">用户确认</van-button>
+            </template>
           </van-col>
         </van-col>
       </van-col>
@@ -43,10 +53,18 @@ export default {
   },
   created() {},
   methods: {
-    // 查看信息
+    // 详细信息
     toView(data) {
       this.$emit('toView', data);
     },
+    // 审核结果
+    toResult(data) {
+      this.$emit('toResult', data);
+    },
+    // 重申交易
+    toHeavy(data) {
+      this.$emit('toHeavy', data);
+    },
     // 撤回交易
     toRevoke(data) {
       this.$emit('toRevoke', data);
@@ -55,23 +73,36 @@ export default {
     toContract(data) {
       this.$emit('toContract', data);
     },
-    // 用户确认
-    toConfirm(data) {
-      this.$emit('toConfirm', data);
-    },
     // 结束交易
     toEndtrans(data) {
       this.$emit('toEndtrans', data);
     },
+    // 用户确定
+    toConfirm(data) {
+      this.$emit('toConfirm', data);
+    },
+    // 交易审核
+    toExamine(data) {
+      this.$emit('toExamine', data);
+    },
+    // 合同审核
+    toContact(data) {
+      this.$emit('toContact', data);
+    },
+    // 交易归档
+    toCheck(data) {
+      this.$emit('toCheck', data);
+    },
     // 整理状态
     getStu(data) {
-      if (data == '0') return '待交易';
-      else if (data == '1') return '填写完合同,等待机构审核';
-      else if (data == '-1') return '填写合同审核失败,重填';
-      else if (data == '2') return '合同审核通过,待用户确认';
-      else if (data == '3') return '用户确认成功,机构归档';
-      else if (data == '-3') return '归档失败';
-      else if (data == '4') return '归档成功';
+      if (data == '0') return '待审中';
+      else if (data == '1') return '审核通过';
+      else if (data == '-1') return '审核拒绝';
+      else if (data == '2') return '合同待审中';
+      else if (data == '3') return '交易合同审核通过,待用户确认';
+      else if (data == '-3') return '交易合同审核拒绝';
+      else if (data == '4') return '用户已确认';
+      else if (data == '5') return '交易完成';
     },
   },
   computed: {

+ 4 - 17
src/layout/trans/list-2.vue

@@ -7,18 +7,15 @@
             {{ item.patent_name }}
           </van-col>
           <van-col span="24" class="other">
-            <van-col span="12" class="otherInfo">
+            <van-col span="24" class="otherInfo">
               申请号:<span>{{ item.create_number || '暂无' }}</span>
             </van-col>
-            <van-col span="12" class="otherInfo">
-              交易类型:<span>{{ item.type || '暂无' }}</span>
-            </van-col>
             <van-col span="24" class="otherInfo">
-              状态:<span>{{ getStu(item.status) }}</span>
+              交易类型:<span>{{ item.type || '暂无' }}</span>
             </van-col>
           </van-col>
           <van-col span="24" class="btn">
-            <van-button type="info" size="small" @click="toView(item)">查看信息</van-button>
+            <van-button type="info" size="small" @click="toView(item)">详细信息</van-button>
           </van-col>
         </van-col>
       </van-col>
@@ -39,20 +36,10 @@ export default {
   },
   created() {},
   methods: {
-    // 查看信息
+    // 详细信息
     toView(data) {
       this.$emit('toView', data);
     },
-    // 整理状态
-    getStu(data) {
-      if (data == '0') return '待交易';
-      else if (data == '1') return '填写完合同,等待机构审核';
-      else if (data == '-1') return '填写合同审核失败,重填';
-      else if (data == '2') return '合同审核通过,待用户确认';
-      else if (data == '3') return '用户确认成功,机构归档';
-      else if (data == '-3') return '归档失败';
-      else if (data == '4') return '归档成功';
-    },
   },
   computed: {
     ...mapState(['user']),

+ 0 - 115
src/layout/trans/list-3.vue

@@ -1,115 +0,0 @@
-<template>
-  <div id="list-3">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-col span="24" class="list" v-for="(item, index) in list" :key="index">
-          <van-col span="24" class="title textOver">
-            {{ item.patent_name }}
-          </van-col>
-          <van-col span="24" class="other">
-            <van-col span="12" class="otherInfo">
-              申请号:<span>{{ item.create_number || '暂无' }}</span>
-            </van-col>
-            <van-col span="12" class="otherInfo">
-              交易类型:<span>{{ item.type || '暂无' }}</span>
-            </van-col>
-            <van-col span="24" class="otherInfo">
-              状态:<span>{{ getStu(item.status) }}</span>
-            </van-col>
-          </van-col>
-          <van-col span="24" class="btn">
-            <van-button type="info" size="small" @click="toView(item)">查看信息</van-button>
-            <van-button type="info" size="small" @click="toContact(item)" v-if="item.status == '1'">合同审核</van-button>
-            <van-button type="info" size="small" @click="toCheck(item)" v-if="item.status == '3'">归档确认</van-button>
-          </van-col>
-        </van-col>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'list-3',
-  props: {
-    list: { type: Array },
-  },
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    // 查看信息
-    toView(data) {
-      this.$emit('toView', data);
-    },
-    // 合同审核
-    toContact(data) {
-      this.$emit('toContact', data);
-    },
-    // 归档确认
-    toCheck(data) {
-      this.$emit('toCheck', data);
-    },
-    // 整理状态
-    getStu(data) {
-      if (data == '0') return '待交易';
-      else if (data == '1') return '合同待审核';
-      else if (data == '-1') return '合同审核拒绝';
-      else if (data == '2') return '合同审核通过,待用户确认';
-      else if (data == '3') return '待归档';
-      else if (data == '-3') return '归档失败';
-      else if (data == '4') return '交易完成';
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  padding: 8px 8px 0 8px;
-  .list {
-    background-color: #fff;
-    margin: 0 0 8px 0;
-    padding: 8px;
-    border-radius: 5px;
-    .title {
-      font-size: 16px;
-      font-weight: bold;
-      margin: 0 0 5px 0;
-    }
-    .other {
-      margin: 0 0 5px 0;
-      .otherInfo {
-        font-size: 14px;
-        color: #666;
-        margin: 0 0 5px 0;
-        span {
-          color: #000;
-        }
-      }
-    }
-    .btn {
-      text-align: center;
-      .van-button {
-        margin: 0 8px;
-      }
-    }
-  }
-}
-</style>

+ 56 - 0
src/layout/trans/result-1.vue

@@ -0,0 +1,56 @@
+<template>
+  <div id="result-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-col span="24" class="one">
+          <van-steps direction="vertical" :active="info.status">
+            <van-step v-for="(item, index) in info.record" :key="index">
+              <p>{{ item.word }}</p>
+              <p>审核时间:{{ item.time }}</p>
+              <p>审核意见:{{ item.remark || '暂无' }}</p>
+            </van-step>
+          </van-steps>
+        </van-col>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+export default {
+  name: 'result-1',
+  props: {
+    info: { type: Object },
+  },
+  components: {},
+  data: function () {
+    return {};
+  },
+  created() {},
+  methods: {},
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped>
+.main {
+  .one {
+    p {
+      margin: 0 0 8px 0;
+    }
+  }
+}
+</style>

+ 88 - 59
src/router/index.js

@@ -13,21 +13,11 @@ const market = [
     meta: { title: '专利超市-专利检索' },
     component: () => import('../views/market/patentInfo/index.vue'),
   },
-  {
-    path: '/market/patentInfo/detail',
-    meta: { title: '专利检索-详细信息' },
-    component: () => import('../views/market/patentInfo/detail.vue'),
-  },
   {
     path: '/market/transfer/index',
     meta: { title: '专利超市-专利转让' },
     component: () => import('../views/market/transfer/index.vue'),
   },
-  {
-    path: '/market/transfer/detail',
-    meta: { title: '专利转让-详细信息' },
-    component: () => import('../views/market/transfer/detail.vue'),
-  },
   {
     path: '/market/demand/index',
     meta: { title: '专利超市-专利需求' },
@@ -97,58 +87,65 @@ const account = [
     meta: { title: '管理中心' },
     component: () => import('../views/account/index.vue'),
   },
-  // 个人用户
   {
-    path: '/account/userCenter/basic/index',
-    meta: { title: '基本信息' },
-    component: () => import('../views/account/userCenter/basic/index.vue'),
+    path: '/account/mechanism/index',
+    meta: { title: '机构用户' },
+    component: () => import('../views/account/mechanism/index.vue'),
   },
   {
-    path: '/account/userCenter/password/index',
-    meta: { title: '修改密码' },
-    component: () => import('../views/account/userCenter/password/index.vue'),
+    path: '/account/mechanism/detail',
+    meta: { title: '机构用户-信息管理' },
+    component: () => import('../views/account/mechanism/detail.vue'),
   },
-  // 机构用户
   {
-    path: '/account/mechCenter/users/index',
+    path: '/account/users/index',
     meta: { title: '平台用户' },
-    component: () => import('../views/account/mechCenter/users/index.vue'),
+    component: () => import('../views/account/users/index.vue'),
   },
   {
-    path: '/account/mechCenter/users/detail',
-    meta: { title: '平台用户-信息维护' },
-    component: () => import('../views/account/mechCenter/users/detail.vue'),
+    path: '/account/users/detail',
+    meta: { title: '平台用户-信息管理' },
+    component: () => import('../views/account/users/detail.vue'),
   },
   {
-    path: '/account/mechCenter/patent/index',
+    path: '/account/patent/index',
     meta: { title: '平台用户-专利信息' },
-    component: () => import('../views/account/mechCenter/patent/index.vue'),
+    component: () => import('../views/account/patent/index.vue'),
   },
-  // 管理用户
   {
-    path: '/account/adminCenter/mechanism/index',
-    meta: { title: '机构用户' },
-    component: () => import('../views/account/adminCenter/mechanism/index.vue'),
+    path: '/account/users/import_user',
+    meta: { title: '平台用户-批量注册用户' },
+    component: () => import('../views/account/users/import_user.vue'),
   },
   {
-    path: '/account/adminCenter/mechanism/detail',
-    meta: { title: '机构用户-信息维护' },
-    component: () => import('../views/account/adminCenter/mechanism/detail.vue'),
+    path: '/account/agentmech/index',
+    meta: { title: '代理机构' },
+    component: () => import('../views/account/agentmech/index.vue'),
   },
   {
-    path: '/account/adminCenter/users/index',
-    meta: { title: '平台用户' },
-    component: () => import('../views/account/adminCenter/users/index.vue'),
+    path: '/account/agentmech/detail',
+    meta: { title: '代理机构-信息管理' },
+    component: () => import('../views/account/agentmech/detail.vue'),
   },
   {
-    path: '/account/adminCenter/users/detail',
-    meta: { title: '平台用户-信息维护' },
-    component: () => import('../views/account/adminCenter/users/detail.vue'),
+    path: '/account/answertea/index',
+    meta: { title: '答题师' },
+    component: () => import('../views/account/answertea/index.vue'),
   },
   {
-    path: '/account/adminCenter/users/import_user',
-    meta: { title: '平台用户-批量注册用户' },
-    component: () => import('../views/account/adminCenter/users/import_user.vue'),
+    path: '/account/answertea/detail',
+    meta: { title: '答题师-信息管理' },
+    component: () => import('../views/account/answertea/detail.vue'),
+  },
+  {
+    path: '/account/basic/index',
+    meta: { title: '基本信息' },
+    component: () => import('../views/account/basic/index.vue'),
+  },
+  {
+    path: '/account/password/index',
+    meta: { title: '修改密码' },
+    component: () => import('../views/account/password/index.vue'),
   },
 ];
 const patent = [
@@ -179,6 +176,11 @@ const patent = [
     meta: { title: '咨询服务' },
     component: () => import('../views/patent/user/chat/index.vue'),
   },
+  {
+    path: '/patent/user/chat/detail',
+    meta: { title: '咨询服务-问题编辑' },
+    component: () => import('../views/patent/user/chat/detail.vue'),
+  },
   // 专利运营-个人用户
   // 我的消息
   {
@@ -203,11 +205,6 @@ const patent = [
     meta: { title: '专利申请' },
     component: () => import('../views/patent/user/apply/apply/index.vue'),
   },
-  {
-    path: '/patent/user/apply/apply/detail',
-    meta: { title: '专利申请-审批单' },
-    component: () => import('../views/patent/user/apply/apply/detail.vue'),
-  },
   {
     path: '/patent/user/apply/apply/gzjDetail',
     meta: { title: '专利申请-国知局信息' },
@@ -283,6 +280,11 @@ const patent = [
     meta: { title: '专利审核' },
     component: () => import('../views/patent/mech/examine/patent.vue'),
   },
+  {
+    path: '/patent/mech/examine/trans_examine',
+    meta: { title: '交易审核' },
+    component: () => import('../views/patent/mech/examine/trans_examine.vue'),
+  },
   {
     path: '/patent/mech/examine/contract',
     meta: { title: '合同审核' },
@@ -290,7 +292,7 @@ const patent = [
   },
   {
     path: '/patent/mech/examine/trans',
-    meta: { title: '交易审核' },
+    meta: { title: '交易归档' },
     component: () => import('../views/patent/mech/examine/trans.vue'),
   },
   // 我的专利
@@ -322,6 +324,11 @@ const patent = [
   },
   // 管理用户
   // 我的消息
+  {
+    path: '/patent/admin/message/question',
+    meta: { title: '问题管理' },
+    component: () => import('../views/patent/admin/message/question.vue'),
+  },
   {
     path: '/patent/admin/message/service',
     meta: { title: '咨询服务' },
@@ -382,22 +389,17 @@ const patent = [
   {
     path: '/patent/admin/patent/info',
     meta: { title: '专利信息' },
-    component: () => import('../views/patent/admin/patent/info.vue'),
+    component: () => import('../views/patent/admin/patent/index.vue'),
   },
   {
-    path: '/patent/admin/patent/info_create',
-    meta: { title: '专利信息-添加专利' },
-    component: () => import('../views/patent/admin/patent/info_create.vue'),
+    path: '/patent/admin/patent/detail',
+    meta: { title: '专利信息-信息管理' },
+    component: () => import('../views/patent/admin/patent/detail.vue'),
   },
   {
-    path: '/patent/admin/patent/info_import',
-    meta: { title: '专利信息-导入专利' },
-    component: () => import('../views/patent/admin/patent/info_import.vue'),
-  },
-  {
-    path: '/patent/admin/patent/info_result',
-    meta: { title: '专利信息-导出结果' },
-    component: () => import('../views/patent/admin/patent/info_result.vue'),
+    path: '/patent/admin/patent/import',
+    meta: { title: '专利信息-专利导入' },
+    component: () => import('../views/patent/admin/patent/import.vue'),
   },
   {
     path: '/patent/admin/patent/assessment',
@@ -419,6 +421,33 @@ const patent = [
     meta: { title: '专利需求' },
     component: () => import('../views/patent/admin/techol/index.vue'),
   },
+  // 答题师
+  {
+    path: '/patent/answertea/message/question',
+    meta: { title: '问题管理' },
+    component: () => import('../views/patent/answertea/message/question.vue'),
+  },
+  // 代理机构
+  {
+    path: '/patent/agentmech/message/examine',
+    meta: { title: '审核通知' },
+    component: () => import('../views/patent/agentmech/message/examine.vue'),
+  },
+  {
+    path: '/patent/agentmech/examine/patent',
+    meta: { title: '专利审核' },
+    component: () => import('../views/patent/agentmech/examine/patent.vue'),
+  },
+  {
+    path: '/patent/agentmech/apply/apply',
+    meta: { title: '专利申请' },
+    component: () => import('../views/patent/agentmech/apply/apply/index.vue'),
+  },
+  {
+    path: '/patent/agentmech/apply/apply/gzjDetail',
+    meta: { title: '专利申请-国知局信息' },
+    component: () => import('../views/patent/agentmech/apply/apply/gzjDetail.vue'),
+  },
 ];
 const patentCommon = [
   {

+ 11 - 0
src/store/index.js

@@ -64,6 +64,14 @@ import patentsafeg from '@common/src/store/patent/patentsafeg';
 
 // 专利交易
 import patenttrans from '@common/src/store/patent/patenttrans';
+// 代理机构
+import agent_mech from '@common/src/store/patent/agent_mech';
+
+// 答题师
+import answer_tea from '@common/src/store/patent/answer_tea';
+// 问题咨询
+import problem_service from '@common/src/store/patent/problem_service';
+
 import mission from '@common/src/store/mission';
 const _ = require('lodash');
 
@@ -128,5 +136,8 @@ export default new Vuex.Store({
     mission,
     patenttechol,
     patentsafeg,
+    agent_mech,
+    answer_tea,
+    problem_service,
   },
 });

+ 0 - 93
src/views/account/adminCenter/users/detail.vue

@@ -1,93 +0,0 @@
-<template>
-  <div id="detail">
-    <admin-frame :usePage="false" topType="2" :rightArrow="false" @back="back" :useNav="false">
-      <template v-slot:info>
-        <personal-detail v-if="type == '1'" :form="form" @onSubmit="onSubmit"></personal-detail>
-        <company-detail v-if="type == '2'" :form="form" @onSubmit="onSubmit"></company-detail>
-      </template>
-    </admin-frame>
-  </div>
-</template>
-
-<script>
-import personalDetail from './parts/personal-detail.vue';
-import companyDetail from './parts/company-detail.vue';
-import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: personal } = createNamespacedHelpers('personal');
-const { mapActions: organization } = createNamespacedHelpers('organization');
-export default {
-  name: 'detail',
-  props: {},
-  components: {
-    adminFrame,
-    personalDetail,
-    companyDetail,
-  },
-  data: function () {
-    return {
-      form: {},
-    };
-  },
-  async created() {
-    if (this.id) await this.search();
-  },
-  methods: {
-    ...personal({ personalFetch: 'fetch', personalUpdate: 'update' }),
-    ...organization({ organizationFetch: 'fetch', organizationUpdate: 'update' }),
-    async search() {
-      if (this.type == '1') {
-        let res = await this.personalFetch(this.id);
-        if (this.$checkRes(res)) {
-          this.$set(this, `form`, res.data);
-        }
-      } else if (this.type == '2') {
-        let res = await this.organizationFetch(this.id);
-        if (this.$checkRes(res)) {
-          this.$set(this, `form`, res.data);
-        }
-      }
-    },
-    // 審核
-    async onSubmit(data) {
-      if (this.type == '1') {
-        let res = await this.personalUpdate(data);
-        if (this.$checkRes(res)) {
-          this.$toast({ type: `success`, message: `信息审核成功` });
-          this.back();
-        }
-      } else if (this.type == '2') {
-        let res = await this.organizationUpdate(data);
-        if (this.$checkRes(res)) {
-          this.$toast({ type: `success`, message: `信息审核成功` });
-          this.back();
-        }
-      }
-    },
-    back() {
-      this.$router.push({ path: `/account/adminCenter/users/index` });
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-    id() {
-      return this.$route.query.id;
-    },
-    type() {
-      return this.$route.query.type;
-    },
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 0 - 128
src/views/account/adminCenter/users/index.vue

@@ -1,128 +0,0 @@
-<template>
-  <div id="index">
-    <admin-frame @search="search" :limit="limit" :total="total" topType="2" @back="back" :rightArrow="false" :useNav="false">
-      <template v-slot:info>
-        <!-- <van-tabs v-model="active" @change="change">
-          <van-tab title="个人用户">
-            <personal-1 :list="personalList" @detail="perDetail"></personal-1>
-          </van-tab>
-          <van-tab title="企业用户">
-            <company-1 :list="companyList" @detail="orgDetail"></company-1>
-          </van-tab>
-        </van-tabs> -->
-        <van-col span="24" class="one">
-          <van-button type="info" size="small" @click="toImport()">批量注册用户</van-button>
-          <van-button type="info" size="small" @click="tpExport()">批量导出用户</van-button>
-        </van-col>
-        <van-col span="24" class="two">
-          <personal-1 :list="personalList" @detail="perDetail"></personal-1>
-        </van-col>
-      </template>
-    </admin-frame>
-  </div>
-</template>
-
-<script>
-import personal1 from './parts/personal-1.vue';
-import company1 from './parts/company-1.vue';
-import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: personal } = createNamespacedHelpers('personal');
-const { mapActions: organization } = createNamespacedHelpers('organization');
-export default {
-  name: 'index',
-  props: {},
-  components: {
-    adminFrame,
-    personal1,
-  },
-  data: function () {
-    return {
-      active: 0,
-      personalList: [],
-      companyList: [],
-      total: 0,
-      limit: 5,
-    };
-  },
-  async created() {
-    await this.search();
-  },
-  methods: {
-    ...personal(['query', 'export']),
-    ...organization({ orgQuery: 'query' }),
-    // 查询列表
-    async search({ skip = 0, limit = this.limit, ...info } = {}) {
-      let user = this.user;
-      if (this.active == '0') {
-        if (user.role != '0') info.code = this.user.code;
-        let res = await this.query({ skip, limit, ...info });
-        if (this.$checkRes(res)) {
-          this.$set(this, `personalList`, res.data);
-          this.$set(this, `total`, res.total);
-        }
-      } else if (this.active == '1') {
-        if (user.role != '0') info.code = user.code;
-        let res = await this.orgQuery({ skip, limit, ...info });
-        if (this.$checkRes(res)) {
-          this.$set(this, `companyList`, res.data);
-          this.$set(this, `total`, res.total);
-        }
-      }
-    },
-    // 个人详情
-    perDetail(data) {
-      this.$router.push({ path: `/account/adminCenter/users/detail`, query: { id: data.id, type: '1' } });
-    },
-    // 企业详情
-    orgDetail(data) {
-      this.$router.push({ path: `/account/adminCenter/users/detail`, query: { id: data.id, type: '2' } });
-    },
-    // 选择用户类别
-    change(type) {
-      this.$set(this, `active`, type);
-      this.search();
-    },
-    // 批量注册用户
-    toImport() {
-      this.$router.push({ path: `/account/adminCenter/users/import_user` });
-    },
-    // 导出用户
-    async tpExport() {
-      let res = await this.export();
-      if (this.$checkRes(res)) {
-        window.location.href = `${process.env.VUE_APP_HOST}/${res.data}`;
-      }
-    },
-
-    // 返回
-    back() {
-      this.$router.push({ path: `/account/index` });
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.one {
-  background-color: #ffffff;
-  text-align: center;
-  padding: 10px 0;
-  .van-button {
-    margin: 0 10px;
-  }
-}
-</style>

+ 0 - 77
src/views/account/adminCenter/users/parts/company-detail.vue

@@ -1,77 +0,0 @@
-<template>
-  <div id="company-detail">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-form @submit="onSubmit">
-          <van-field v-model="form.name" name="name" label="姓名" readonly />
-          <van-field v-model="form.phone" name="phone" label="手机号" readonly />
-          <van-field v-model="form.code" name="code" label="机构代码" readonly />
-          <van-field v-model="form.email" name="email" label="电子邮箱" readonly />
-          <van-field v-model="form.addr" name="addr" label="地址" readonly />
-          <van-field v-model="form.office_phone" name="office_phone" label="办公电话" readonly />
-          <van-field v-model="form.profession" name="profession" label="所属行业" readonly />
-          <van-field v-model="form.juris" name="juris" label="所属辖区" readonly />
-          <van-field v-model="form.institution_code" name="institution_code" label="统一社会信用代码" readonly />
-          <van-field v-model="form.companytype" name="companytype" label="注册类型" readonly />
-          <van-field v-model="form.companydate" name="companydate" label="注册时间" readonly />
-          <van-field v-model="form.companycapital" name="companycapital" label="注册资金" readonly />
-          <van-field v-model="form.companyperson" name="companyperson" label="企业法人" readonly />
-          <van-field v-model="form.sndqyzsr" name="sndqyzsr" label="上年度企业总收入" readonly />
-          <van-field v-model="form.sndyffy" name="sndyffy" label="上年度研发费用" readonly />
-          <van-field v-model="form.companytotal" name="companytotal" label="企业总人数" readonly />
-          <van-field v-model="form.zjzyfrs" name="zjzyfrs" label="专&兼职研发人数" readonly />
-          <van-field v-model="form.companybrief" name="companybrief" label="企业简介" rows="1" autosize type="textarea" readonly />
-          <van-field v-model="form.mainproduct" name="mainproduct" label="主要产品" rows="1" autosize type="textarea" readonly />
-          <van-field v-model="form.qualifications" name="qualifications" label="企业资质&荣誉" rows="1" autosize type="textarea" readonly />
-          <van-field name="status" 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 name="2">拒绝</van-radio>
-              </van-radio-group>
-            </template>
-          </van-field>
-          <div style="margin: 16px">
-            <van-button round block type="info" native-type="submit">提交</van-button>
-          </div>
-        </van-form>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'company-detail',
-  props: {
-    form: { type: Object },
-  },
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    onSubmit() {
-      this.$emit('onSubmit', this.form);
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 86 - 0
src/views/account/agentmech/detail.vue

@@ -0,0 +1,86 @@
+<template>
+  <div id="detail">
+    <admin-frame :usePage="false" topType="2" :rightArrow="false" @back="back" :useNav="false">
+      <template v-slot:info>
+        <form-1 :form="form" :pidList="pidList" @onSubmit="onSubmit"></form-1>
+      </template>
+    </admin-frame>
+  </div>
+</template>
+
+<script>
+import form1 from './parts/form-1.vue';
+import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: agent_mech } = createNamespacedHelpers('agent_mech');
+const { mapActions: adminLogin } = createNamespacedHelpers('adminLogin');
+export default {
+  name: 'detail',
+  props: {},
+  components: {
+    adminFrame,
+    form1,
+  },
+  data: function () {
+    return {
+      form: {},
+      pidList: [],
+    };
+  },
+  async created() {
+    await this.search();
+  },
+  methods: {
+    ...agent_mech(['fetch', 'create', 'update']),
+    ...adminLogin({ adminQuery: 'query' }),
+    async search() {
+      if (this.id) {
+        let res = await this.fetch(this.id);
+        if (this.$checkRes(res)) {
+          this.$set(this, `form`, res.data);
+        }
+      }
+      let res = await this.adminQuery({ role: '1', code: this.user.code });
+      if (this.$checkRes(res)) {
+        this.$set(this, `pidList`, res.data);
+      }
+    },
+    async onSubmit(data) {
+      if (this.id) {
+        let res = await this.update(data);
+        if (this.$checkRes(res)) {
+          this.$toast({ type: `success`, message: `操作成功` });
+          this.back();
+        }
+      } else {
+        let res = await this.create(data);
+        if (this.$checkRes(res)) {
+          this.$toast({ type: `success`, message: `操作成功` });
+          this.back();
+        }
+      }
+    },
+    back() {
+      this.$router.push({ path: `/account/agentmech/index` });
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+    id() {
+      return this.$route.query.id;
+    },
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 69 - 0
src/views/account/agentmech/index.vue

@@ -0,0 +1,69 @@
+<template>
+  <div id="index">
+    <admin-frame @search="search" :limit="limit" :total="total" topType="2" @back="back" @add="toAdd" :useNav="false">
+      <template v-slot:info>
+        <list-1 :list="list" @toEdit="toEdit"></list-1>
+      </template>
+    </admin-frame>
+  </div>
+</template>
+
+<script>
+import list1 from './parts/list-1.vue';
+import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: agent_mech } = createNamespacedHelpers('agent_mech');
+export default {
+  name: 'index',
+  props: {},
+  components: { adminFrame, list1 },
+  data: function () {
+    return {
+      list: [],
+      limit: 4,
+      total: 0,
+    };
+  },
+  created() {
+    this.search();
+  },
+  methods: {
+    ...agent_mech(['query']),
+    async search({ skip = 0, limit = this.limit, searchName, ...info } = {}) {
+      if (searchName) info.name = searchName;
+      let res = await this.query({ skip, limit, pid: this.user.id, ...info });
+      if (this.$checkRes(res)) {
+        this.$set(this, `list`, res.data);
+        this.$set(this, `total`, res.total);
+      }
+    },
+    // 添加
+    toAdd() {
+      this.$router.push({ path: `/account/agentmech/detail` });
+    },
+    // 编辑
+    toEdit(data) {
+      this.$router.push({ path: `/account/agentmech/detail`, query: { id: data.id } });
+    },
+    // 返回
+    back() {
+      this.$router.push({ path: `/account/index` });
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 65 - 0
src/views/account/agentmech/parts/form-1.vue

@@ -0,0 +1,65 @@
+<template>
+  <div id="form-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-form @submit="onSubmit">
+          <van-field v-model="form.pid" name="pid" label="管理员id" style="display: none" />
+          <van-field readonly clickable name="pid_name" :value="form.pid_name" label="管理员" placeholder="点击选择" @click="showPicker = true" />
+          <van-popup v-model="showPicker" position="bottom">
+            <van-picker show-toolbar :columns="pidList" value-key="name" @confirm="pidCon" @cancel="showPicker = false" />
+          </van-popup>
+          <van-field v-model="form.mech_name" name="mech_name" label="机构名称" :rules="[{ required: true, message: '机构名称' }]" />
+          <van-field v-model="form.name" name="name" label="姓名" :rules="[{ required: true, message: '姓名' }]" />
+          <van-field v-model="form.phone" name="phone" label="手机号" :rules="[{ required: true, message: '手机号' }]" />
+          <van-field v-model="form.password" name="password" label="密码" type="password" :rules="[{ required: true, message: '密码' }]" v-if="!form.id" />
+          <div style="margin: 16px">
+            <van-button round block type="info" native-type="submit">提交</van-button>
+          </div>
+        </van-form>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+export default {
+  name: 'form-1',
+  props: {
+    form: { type: Object },
+    pidList: { type: Array },
+  },
+  components: {},
+  data: function () {
+    return {
+      showPicker: false,
+    };
+  },
+  created() {},
+  methods: {
+    onSubmit() {
+      this.$emit('onSubmit', this.form);
+    },
+    pidCon(value) {
+      this.$set(this.form, `pid`, value.id);
+      this.$set(this.form, `pid_name`, value.name);
+      this.showPicker = false;
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 8 - 12
src/views/account/userCenter/parts/user-1.vue

@@ -7,15 +7,14 @@
         </van-col>
         <van-col span="24" class="other">
           <van-col span="24" class="otherInfo">
-            组织机构代码:<span>{{ item.institution_code || '暂无' }}</span>
+            机构名称:<span>{{ item.mech_name || '暂无' }}</span>
           </van-col>
           <van-col span="24" class="otherInfo">
-            所属辖区:<span>{{ item.juris || '暂无' }}</span>
+            联系电话:<span>{{ item.phone || '暂无' }}</span>
           </van-col>
         </van-col>
         <van-col span="24" class="btn">
-          <el-button type="primary" size="mini" @click="bind(item)" v-if="item.openid == null">绑定</el-button>
-          <el-button type="danger" size="mini" @click="removeBind(item)" v-if="item.openid">解绑</el-button>
+          <van-button type="info" size="small" @click="toEdit(item)">编辑信息</van-button>
         </van-col>
       </van-col>
     </van-col>
@@ -35,13 +34,8 @@ export default {
   },
   created() {},
   methods: {
-    // 绑定微信
-    bind(data) {
-      this.$emit('bind', data);
-    },
-    // 接触绑定
-    removeBind(data) {
-      this.$emit('removeBind', data);
+    toEdit(data) {
+      this.$emit('toEdit', data);
     },
   },
   computed: {
@@ -62,7 +56,6 @@ export default {
 
 <style lang="less" scoped>
 .main {
-  padding: 8px 8px 0 8px;
   .list {
     background-color: #fff;
     margin: 0 0 8px 0;
@@ -85,6 +78,9 @@ export default {
     }
     .btn {
       text-align: center;
+      .van-button {
+        margin: 0 10px;
+      }
     }
   }
 }

+ 19 - 24
src/views/patent/admin/patent/info_create.vue

@@ -1,65 +1,60 @@
 <template>
-  <div id="info_create">
-    <admin-frame topType="2" @back="back" :rightArrow="false" :usePage="false" :useNav="false">
+  <div id="detail">
+    <admin-frame :usePage="false" topType="2" :rightArrow="false" @back="back" :useNav="false">
       <template v-slot:info>
-        <detail-1 :form="form" @onSubmit="onSubmit"></detail-1>
+        <form-1 :form="form" @onSubmit="onSubmit"></form-1>
       </template>
     </admin-frame>
   </div>
 </template>
 
 <script>
-import detail1 from './info/detail-1.vue';
+import form1 from './parts/form-1.vue';
 import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
 import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: patentinfo } = createNamespacedHelpers('patentinfo');
+const { mapActions: answer_tea } = createNamespacedHelpers('answer_tea');
 export default {
-  name: 'info_create',
+  name: 'detail',
   props: {},
   components: {
     adminFrame,
-    detail1,
+    form1,
   },
   data: function () {
     return {
-      form: { inventor: [] },
+      form: {},
     };
   },
   async created() {
-    if (this.id) await this.search();
+    await this.search();
   },
   methods: {
-    ...patentinfo(['fetch', 'create', 'update']),
+    ...answer_tea(['fetch', 'create', 'update']),
     async search() {
-      let res = await this.fetch(this.id);
-      if (this.$checkRes(res)) {
-        this.$set(this, `form`, res.data);
+      if (this.id) {
+        let res = await this.fetch(this.id);
+        if (this.$checkRes(res)) {
+          this.$set(this, `form`, res.data);
+        }
       }
     },
-    async onSubmit() {
-      let data = this.form;
+    async onSubmit(data) {
       if (this.id) {
         let res = await this.update(data);
         if (this.$checkRes(res)) {
-          this.$toast({ type: `success`, message: `修改成功` });
+          this.$toast({ type: `success`, message: `操作成功` });
           this.back();
-        } else {
-          this.$toast({ type: `fail`, message: `${res.errmsg}` });
         }
       } else {
-        data.trans_status = '0';
         let res = await this.create(data);
         if (this.$checkRes(res)) {
-          this.$toast({ type: `success`, message: `添加成功` });
+          this.$toast({ type: `success`, message: `操作成功` });
           this.back();
-        } else {
-          this.$toast({ type: `fail`, message: `${res.errmsg}` });
         }
       }
     },
-    // 返回
     back() {
-      this.$router.push({ path: '/patent/admin/patent/info' });
+      this.$router.push({ path: `/account/answertea/index` });
     },
   },
   computed: {

+ 69 - 0
src/views/account/answertea/index.vue

@@ -0,0 +1,69 @@
+<template>
+  <div id="index">
+    <admin-frame @search="search" :limit="limit" :total="total" topType="2" @back="back" @add="toAdd" :useNav="false">
+      <template v-slot:info>
+        <list-1 :list="list" @toEdit="toEdit"></list-1>
+      </template>
+    </admin-frame>
+  </div>
+</template>
+
+<script>
+import list1 from './parts/list-1.vue';
+import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: answer_tea } = createNamespacedHelpers('answer_tea');
+export default {
+  name: 'index',
+  props: {},
+  components: { adminFrame, list1 },
+  data: function () {
+    return {
+      list: [],
+      limit: 4,
+      total: 0,
+    };
+  },
+  created() {
+    this.search();
+  },
+  methods: {
+    ...answer_tea(['query']),
+    async search({ skip = 0, limit = this.limit, searchName, ...info } = {}) {
+      if (searchName) info.name = searchName;
+      let res = await this.query({ skip, limit, ...info });
+      if (this.$checkRes(res)) {
+        this.$set(this, `list`, res.data);
+        this.$set(this, `total`, res.total);
+      }
+    },
+    // 添加
+    toAdd() {
+      this.$router.push({ path: `/account/answertea/detail` });
+    },
+    // 编辑
+    toEdit(data) {
+      this.$router.push({ path: `/account/answertea/detail`, query: { id: data.id } });
+    },
+    // 返回
+    back() {
+      this.$router.push({ path: `/account/index` });
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 74 - 0
src/views/account/answertea/parts/form-1.vue

@@ -0,0 +1,74 @@
+<template>
+  <div id="form-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-form @submit="onSubmit" label-width="4em">
+          <van-field name="radio" label="用户类型" :rules="[{ required: true, message: '用户类型' }]">
+            <template #input>
+              <van-radio-group v-model="form.type" direction="horizontal">
+                <van-radio name="1">咨询师</van-radio>
+                <van-radio name="2">代理师</van-radio>
+                <van-radio name="3">分析师</van-radio>
+              </van-radio-group>
+            </template>
+          </van-field>
+          <van-field v-model="form.name" name="name" label="姓名" :rules="[{ required: true, message: '机构名称' }]" />
+          <van-field v-model="form.phone" name="phone" label="手机号" :rules="[{ required: true, message: '机构名称' }]" />
+          <van-field
+            v-model="form.password"
+            name="password"
+            label="登录密码"
+            type="password"
+            :rules="[{ required: true, message: '登录密码' }]"
+            v-if="!form.id"
+          />
+          <van-field v-model="form.card" name="card" label="身份证号" :rules="[{ required: false, message: '机构名称' }]" />
+          <van-field v-model="form.email" name="email" label="电子邮箱" :rules="[{ required: false, message: '机构名称' }]" />
+          <van-field v-model="form.address" name="address" label="联系地址" :rules="[{ required: false, message: '机构名称' }]" />
+          <van-field v-model="form.zwzc" name="zwzc" label="职务职称" :rules="[{ required: false, message: '机构名称' }]" />
+          <van-field v-model="form.school" name="school" label="院校" :rules="[{ required: false, message: '机构名称' }]" />
+          <van-field v-model="form.major" name="major" label="专业" :rules="[{ required: false, message: '机构名称' }]" />
+          <van-field v-model="form.word_tel" name="word_tel" label="办公电话" :rules="[{ required: false, message: '机构名称' }]" />
+          <div style="margin: 16px">
+            <van-button round block type="info" native-type="submit">提交</van-button>
+          </div>
+        </van-form>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+export default {
+  name: 'form-1',
+  props: {
+    form: { type: Object },
+  },
+  components: {},
+  data: function () {
+    return {};
+  },
+  created() {},
+  methods: {
+    onSubmit() {
+      this.$emit('onSubmit', this.form);
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 16 - 14
src/views/account/adminCenter/users/parts/personal-1.vue

@@ -1,24 +1,21 @@
 <template>
-  <div id="personal-1">
+  <div id="list-1">
     <van-col span="24" class="main">
-      <van-col span="24" class="list" v-for="(item, index) in list" :key="index" @click.native="detail(item)">
+      <van-col span="24" class="list" v-for="(item, index) in list" :key="index">
         <van-col span="24" class="title">
           {{ item.name }}
         </van-col>
         <van-col span="24" class="other">
           <van-col span="24" class="otherInfo">
-            机构代码或邀请码:<span style="color: #ff0000">{{ item.code || '暂无' }}</span>
-          </van-col>
-          <van-col span="12" class="otherInfo">
-            联系电话:<span>{{ item.phone || '暂无' }}</span>
-          </van-col>
-          <van-col span="12" class="otherInfo">
-            所属辖区:<span>{{ item.juris || '暂无' }}</span>
+            用户类型:<span>{{ item.type == '1' ? '咨询师' : item.type == '2' ? '代理师' : '分析师' }}</span>
           </van-col>
           <van-col span="24" class="otherInfo">
-            审核状态:<span>{{ item.status == '0' ? '待审中' : item.status == '1' ? '审核通过' : '审核拒绝' }}</span>
+            联系电话:<span>{{ item.phone || '暂无' }}</span>
           </van-col>
         </van-col>
+        <van-col span="24" class="btn">
+          <van-button type="info" size="small" @click="toEdit(item)">编辑信息</van-button>
+        </van-col>
       </van-col>
     </van-col>
   </div>
@@ -27,7 +24,7 @@
 <script>
 import { mapState, createNamespacedHelpers } from 'vuex';
 export default {
-  name: 'personal-1',
+  name: 'list-1',
   props: {
     list: { type: Array },
   },
@@ -37,8 +34,8 @@ export default {
   },
   created() {},
   methods: {
-    detail(data) {
-      this.$emit('detail', data);
+    toEdit(data) {
+      this.$emit('toEdit', data);
     },
   },
   computed: {
@@ -59,7 +56,6 @@ export default {
 
 <style lang="less" scoped>
 .main {
-  padding: 8px 8px 0 8px;
   .list {
     background-color: #fff;
     margin: 0 0 8px 0;
@@ -80,6 +76,12 @@ export default {
         }
       }
     }
+    .btn {
+      text-align: center;
+      .van-button {
+        margin: 0 10px;
+      }
+    }
   }
 }
 </style>

+ 51 - 0
src/views/account/basic/index.vue

@@ -0,0 +1,51 @@
+<template>
+  <div id="index">
+    <admin-frame topType="2" @back="back" :usePage="false" :rightArrow="false" :useNav="false">
+      <template v-slot:info>
+        <info-1 v-if="user.role == '1' || user.role == '2'"></info-1>
+        <info-3 v-else-if="user.role == '3'"></info-3>
+        <info-4 v-else-if="user.role == '4'"></info-4>
+        <info-5 v-else-if="user.role == '5'"></info-5>
+      </template>
+    </admin-frame>
+  </div>
+</template>
+
+<script>
+import info1 from './parts/info-1.vue';
+import info3 from './parts/info-3.vue';
+import info4 from './parts/info-4.vue';
+import info5 from './parts/info-5.vue';
+import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
+import { mapState, createNamespacedHelpers } from 'vuex';
+export default {
+  name: 'index',
+  props: {},
+  components: { adminFrame, info1, info3, info4, info5 },
+  data: function () {
+    return {};
+  },
+  created() {},
+  methods: {
+    // 返回
+    back() {
+      this.$router.push({ path: `/account/index` });
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 68 - 0
src/views/account/basic/parts/info-1.vue

@@ -0,0 +1,68 @@
+<template>
+  <div id="info-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-form @submit="onSubmit">
+          <van-field v-model="form.id" name="id" label="数据id" style="display: none" />
+          <van-field v-model="form.deptname" name="deptname" label="机构名称" :rules="[{ required: true, message: '机构名称' }]" />
+          <van-field v-model="form.name" name="name" label="姓名" :rules="[{ required: true, message: '姓名' }]" />
+          <van-field v-model="form.phone" name="phone" label="手机号" :rules="[{ required: true, message: '手机号' }]" />
+          <div style="margin: 16px">
+            <van-button round block type="info" native-type="submit">提交</van-button>
+          </div>
+        </van-form>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: adminLogin } = createNamespacedHelpers('adminLogin');
+export default {
+  name: 'info-1',
+  props: {},
+  components: {},
+  data: function () {
+    return {
+      form: {},
+    };
+  },
+  created() {
+    this.search();
+  },
+  methods: {
+    ...adminLogin(['fetch', 'update']),
+    async search() {
+      if (this.user.id) {
+        let res = await this.fetch(this.user.id);
+        if (this.$checkRes(res)) {
+          this.$set(this, `form`, res.data);
+        }
+      }
+    },
+    async onSubmit(values) {
+      let res = await this.update(values);
+      if (this.$checkRes(res)) {
+        this.$toast({ type: `success`, message: `操作完成` });
+        this.search();
+      }
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 87 - 0
src/views/account/basic/parts/info-3.vue

@@ -0,0 +1,87 @@
+<template>
+  <div id="info-3">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-form @submit="onSubmit">
+          <van-field v-model="form.id" name="id" label="数据id" style="display: none" />
+          <van-field v-model="form.name" name="name" label="姓名" placeholder="请填写姓名" :rules="[{ required: true, message: '姓名' }]" />
+          <van-field v-model="form.phone" name="phone" label="手机号" placeholder="请填写手机号" :rules="[{ required: true, message: '手机号' }]" />
+          <van-field v-model="form.code" name="code" label="邀请码" placeholder="请填写邀请码" readonly />
+          <van-field v-model="form.card" name="card" label="身份证号" placeholder="请填写身份证号" />
+          <van-field v-model="form.email" name="email" label="电子邮箱" placeholder="请填写电子邮箱" />
+          <van-field v-model="form.addr" name="addr" label="联系地址" placeholder="请填写联系地址" />
+          <van-field v-model="form.zwzc" name="zwzc" label="职务职称" placeholder="请填写职务职称" />
+          <van-field v-model="form.school" name="school" label="院校" placeholder="请填写院校" />
+          <van-field v-model="form.major" name="major" label="专业" placeholder="请填写专业" />
+          <van-field v-model="form.office_phone" name="office_phone" label="办公电话" placeholder="请填写办公电话" />
+          <van-field readonly clickable name="juris" :value="form.juris" label="所属辖区" placeholder="点击选择" @click="showPicker = true" />
+          <van-popup v-model="showPicker" position="bottom">
+            <van-picker show-toolbar :columns="jurisList" @confirm="onConfirm" @cancel="showPicker = false" />
+          </van-popup>
+          <div style="margin: 16px">
+            <van-button round block type="info" native-type="submit">提交</van-button>
+          </div>
+        </van-form>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { juris } from '@common/dict/index';
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: personal } = createNamespacedHelpers('personal');
+export default {
+  name: 'info-3',
+  props: {},
+  components: {},
+  data: function () {
+    return {
+      form: {},
+      showPicker: false,
+      jurisList: juris,
+    };
+  },
+  created() {
+    this.search();
+  },
+  methods: {
+    ...personal(['fetch', 'update']),
+    async search() {
+      if (this.user.id) {
+        let res = await this.fetch(this.user.id);
+        if (this.$checkRes(res)) {
+          this.$set(this, `form`, res.data);
+        }
+      }
+    },
+    async onSubmit(values) {
+      let res = await this.update(values);
+      if (this.$checkRes(res)) {
+        this.$toast({ type: `success`, message: `操作完成` });
+        this.search();
+      }
+    },
+    // 选择辖区
+    onConfirm(value) {
+      this.$set(this.form, `juris`, value);
+      this.showPicker = false;
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 68 - 0
src/views/account/basic/parts/info-4.vue

@@ -0,0 +1,68 @@
+<template>
+  <div id="info-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-form @submit="onSubmit">
+          <van-field v-model="form.id" name="id" label="数据id" style="display: none" />
+          <van-field v-model="form.mech_name" name="mech_name" label="机构名称" :rules="[{ required: true, message: '机构名称' }]" />
+          <van-field v-model="form.name" name="name" label="姓名" :rules="[{ required: true, message: '姓名' }]" />
+          <van-field v-model="form.phone" name="phone" label="手机号" :rules="[{ required: true, message: '手机号' }]" />
+          <div style="margin: 16px">
+            <van-button round block type="info" native-type="submit">提交</van-button>
+          </div>
+        </van-form>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: agent_mech } = createNamespacedHelpers('agent_mech');
+export default {
+  name: 'info-1',
+  props: {},
+  components: {},
+  data: function () {
+    return {
+      form: {},
+    };
+  },
+  created() {
+    this.search();
+  },
+  methods: {
+    ...agent_mech(['fetch', 'update']),
+    async search() {
+      if (this.user.id) {
+        let res = await this.fetch(this.user.id);
+        if (this.$checkRes(res)) {
+          this.$set(this, `form`, res.data);
+        }
+      }
+    },
+    async onSubmit(values) {
+      let res = await this.update(values);
+      if (this.$checkRes(res)) {
+        this.$toast({ type: `success`, message: `操作完成` });
+        this.search();
+      }
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 83 - 0
src/views/account/basic/parts/info-5.vue

@@ -0,0 +1,83 @@
+<template>
+  <div id="info-1">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-form @submit="onSubmit" label-width="4em">
+          <van-field v-model="form.id" name="id" label="数据id" style="display: none" />
+          <van-field name="radio" label="用户类型" :rules="[{ required: true, message: '用户类型' }]">
+            <template #input>
+              <van-radio-group v-model="form.type" direction="horizontal">
+                <van-radio name="1">咨询师</van-radio>
+                <van-radio name="2">代理师</van-radio>
+                <van-radio name="3">分析师</van-radio>
+              </van-radio-group>
+            </template>
+          </van-field>
+          <van-field v-model="form.name" name="name" label="姓名" :rules="[{ required: true, message: '机构名称' }]" />
+          <van-field v-model="form.phone" name="phone" label="手机号" :rules="[{ required: true, message: '机构名称' }]" />
+          <van-field v-model="form.card" name="card" label="身份证号" :rules="[{ required: false, message: '机构名称' }]" />
+          <van-field v-model="form.email" name="email" label="电子邮箱" :rules="[{ required: false, message: '机构名称' }]" />
+          <van-field v-model="form.address" name="address" label="联系地址" :rules="[{ required: false, message: '机构名称' }]" />
+          <van-field v-model="form.zwzc" name="zwzc" label="职务职称" :rules="[{ required: false, message: '机构名称' }]" />
+          <van-field v-model="form.school" name="school" label="院校" :rules="[{ required: false, message: '机构名称' }]" />
+          <van-field v-model="form.major" name="major" label="专业" :rules="[{ required: false, message: '机构名称' }]" />
+          <van-field v-model="form.word_tel" name="word_tel" label="办公电话" :rules="[{ required: false, message: '机构名称' }]" />
+          <div style="margin: 16px">
+            <van-button round block type="info" native-type="submit">提交</van-button>
+          </div>
+        </van-form>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: answer_tea } = createNamespacedHelpers('answer_tea');
+export default {
+  name: 'info-1',
+  props: {},
+  components: {},
+  data: function () {
+    return {
+      form: {},
+    };
+  },
+  created() {
+    this.search();
+  },
+  methods: {
+    ...answer_tea(['fetch', 'update']),
+    async search() {
+      if (this.user.id) {
+        let res = await this.fetch(this.user.id);
+        if (this.$checkRes(res)) {
+          this.$set(this, `form`, res.data);
+        }
+      }
+    },
+    async onSubmit(values) {
+      let res = await this.update(values);
+      if (this.$checkRes(res)) {
+        this.$toast({ type: `success`, message: `操作完成` });
+        this.search();
+      }
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped></style>

+ 25 - 39
src/views/account/index.vue

@@ -3,23 +3,22 @@
     <admin-frame :useTop="false" :usePage="false" :useNav="false">
       <template v-slot:info>
         <van-col span="24" class="one">
-          <van-col span="24" class="image">
+          <van-col span="4" class="left">
             <van-image :src="icon"></van-image>
           </van-col>
-          <van-col span="24" class="other">
-            <van-col span="24" class="otherInfo">
-              {{ userInfo.name }}
-            </van-col>
-            <van-col span="24" class="otherInfo">
-              {{ userInfo.phone }}
-            </van-col>
+          <van-col span="20" class="right">
+            <van-col span="24" class="info">{{ userInfo.name }}</van-col>
+            <van-col span="24" class="info">联系电话:{{ userInfo.phone }}</van-col>
           </van-col>
         </van-col>
         <van-col span="24" class="two">
-          <role-1 v-if="userInfo.role == '1'"></role-1>
-          <role-2 v-else-if="userInfo.role == '2'"></role-2>
-          <role-3 v-else></role-3>
-          <van-cell title="专利运营" @click="patentBtn" is-link />
+          <van-cell title="基本信息" @click="to('basic')" is-link />
+          <van-cell title="机构用户" @click="to('mechanism')" is-link v-if="userInfo.role == '1'" />
+          <van-cell title="平台用户" @click="to('users')" is-link v-if="userInfo.role == '1' || userInfo.role == '2'" />
+          <van-cell title="代理机构" @click="to('agentmech')" is-link v-if="userInfo.role == '1'" />
+          <van-cell title="答题师" @click="to('answertea')" is-link v-if="userInfo.role == '1'" />
+          <van-cell title="专利运营" @click="toPatent('patent')" is-link />
+          <van-cell title="修改密码" @click="to('password')" is-link v-if="userInfo.role == '3'" />
           <van-cell title="退出登录" @click="logout" is-link />
         </van-col>
       </template>
@@ -28,9 +27,6 @@
 </template>
 
 <script>
-import role1 from './parts/role-1.vue';
-import role2 from './parts/role-2.vue';
-import role3 from './parts/role-3.vue';
 import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
 import { mapState, createNamespacedHelpers } from 'vuex';
 export default {
@@ -38,9 +34,6 @@ export default {
   props: {},
   components: {
     adminFrame,
-    role1,
-    role2,
-    role3,
   },
   data: function () {
     return {
@@ -61,9 +54,12 @@ export default {
         this.$router.push({ path: '/login', query: { path: '/account/index', type: '1' } });
       }
     },
+    to(type) {
+      this.$router.push({ path: `/account/${type}/index` });
+    },
     // 专利运营
-    patentBtn() {
-      this.$router.push({ path: '/patent/index' });
+    toPatent(type) {
+      this.$router.push({ path: `/${type}/index` });
     },
   },
   computed: {
@@ -84,27 +80,17 @@ export default {
 
 <style lang="less" scoped>
 .one {
-  background: url('~@/assets/userbj.jpg');
-  background-repeat: no-repeat;
-  background-size: 100% 100%;
-  .image {
+  background-color: #fff;
+  margin: 0 0 10px 0;
+  padding: 0 10px;
+  .left {
     text-align: center;
-    padding: 10px 0 10px 0;
-    .van-image {
-      width: 66px;
-      height: 66px;
-      /deep/.van-image__img {
-        border-radius: 90px;
-      }
-    }
+    padding: 20px 0;
   }
-  .other {
-    text-align: center;
-    .otherInfo {
-      font-size: 16px;
-      color: #000;
-      font-weight: bold;
-      margin: 0 0 5px 0;
+  .right {
+    padding: 20px 10px;
+    .info {
+      margin: 5px 0;
     }
   }
 }

+ 0 - 108
src/views/account/mechCenter/users/detail.vue

@@ -1,108 +0,0 @@
-<template>
-  <div id="detail">
-    <admin-frame :usePage="false" topType="2" :rightArrow="false" @back="back" :useNav="false">
-      <template v-slot:info>
-        <personal-detail v-if="type == '1'" :form="form" @onSubmit="onSubmit"></personal-detail>
-        <company-detail v-if="type == '2'" :form="form" @onSubmit="onSubmit"></company-detail>
-      </template>
-    </admin-frame>
-  </div>
-</template>
-
-<script>
-import personalDetail from './parts/personal-detail.vue';
-import companyDetail from './parts/company-detail.vue';
-import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: personal } = createNamespacedHelpers('personal');
-const { mapActions: organization } = createNamespacedHelpers('organization');
-export default {
-  name: 'detail',
-  props: {},
-  components: {
-    adminFrame,
-    personalDetail,
-    companyDetail,
-  },
-  data: function () {
-    return {
-      form: {},
-    };
-  },
-  async created() {
-    await this.search();
-  },
-  methods: {
-    ...personal({ personalFetch: 'fetch', personalUpdate: 'update', personalCreate: 'create' }),
-    ...organization({ organizationFetch: 'fetch', organizationUpdate: 'update' }),
-    async search() {
-      if (this.id) {
-        if (this.type == '1') {
-          let res = await this.personalFetch(this.id);
-          if (this.$checkRes(res)) {
-            this.$set(this, `form`, res.data);
-          }
-        } else if (this.type == '2') {
-          let res = await this.organizationFetch(this.id);
-          if (this.$checkRes(res)) {
-            this.$set(this, `form`, res.data);
-          }
-        }
-      } else {
-        let data = { code: this.user.code };
-        this.$set(this, `form`, data);
-      }
-    },
-    // 審核
-    async onSubmit(data) {
-      if (data.id) {
-        if (this.type == '1') {
-          let res = await this.personalUpdate(data);
-          if (this.$checkRes(res)) {
-            this.$toast({ type: `success`, message: `操作成功` });
-            this.back();
-          }
-        } else if (this.type == '2') {
-          let res = await this.organizationUpdate(data);
-          if (this.$checkRes(res)) {
-            this.$toast({ type: `success`, message: `操作成功` });
-            this.back();
-          }
-        }
-      } else {
-        if (this.type == '1') {
-          let res = await this.personalCreate(data);
-          if (this.$checkRes(res)) {
-            this.$toast({ type: `success`, message: `操作成功` });
-            this.back();
-          }
-        }
-      }
-    },
-    back() {
-      this.$router.push({ path: `/account/mechCenter/users/index` });
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-    id() {
-      return this.$route.query.id;
-    },
-    type() {
-      return this.$route.query.type;
-    },
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 0 - 110
src/views/account/mechCenter/users/index.vue

@@ -1,110 +0,0 @@
-<template>
-  <div id="index">
-    <admin-frame @search="search" :limit="limit" :total="total" topType="2" @back="back" :rightArrow="false" :useNav="false">
-      <template v-slot:info>
-        <!-- <van-tabs v-model="active" @change="change">
-          <van-tab title="个人用户">
-            <personal-1 :list="personalList" @detail="perDetail"></personal-1>
-          </van-tab>
-          <van-tab title="企业用户">
-            <company-1 :list="companyList" @detail="orgDetail"></company-1>
-          </van-tab>
-        </van-tabs> -->
-        <personal-1 :list="personalList" @detail="perDetail" @patent="toPatent"></personal-1>
-      </template>
-    </admin-frame>
-  </div>
-</template>
-
-<script>
-import personal1 from './parts/personal-1.vue';
-import company1 from './parts/company-1.vue';
-import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: personal } = createNamespacedHelpers('personal');
-const { mapActions: organization } = createNamespacedHelpers('organization');
-export default {
-  name: 'index',
-  props: {},
-  components: {
-    adminFrame,
-    personal1,
-    // company1,
-  },
-  data: function () {
-    return {
-      active: 0,
-      personalList: [],
-      companyList: [],
-      total: 0,
-      limit: 5,
-    };
-  },
-  async created() {
-    await this.search();
-  },
-  methods: {
-    ...personal(['query']),
-    ...organization({ orgQuery: 'query' }),
-    // 查询列表
-    async search({ skip = 0, limit = this.limit, ...info } = {}) {
-      let user = this.user;
-      if (this.active == '0') {
-        if (user.role != '0') info.code = user.code;
-        let res = await this.query({ skip, limit, ...info });
-        if (this.$checkRes(res)) {
-          this.$set(this, `personalList`, res.data);
-          this.$set(this, `total`, res.total);
-        }
-      } else if (this.active == '1') {
-        if (user.role != '0') info.code = user.code;
-        let res = await this.orgQuery({ skip, limit, ...info });
-        if (this.$checkRes(res)) {
-          this.$set(this, `companyList`, res.data);
-          this.$set(this, `total`, res.total);
-        }
-      }
-    },
-    // 添加
-    add() {
-      this.$router.push({ path: `/account/mechCenter/users/detail`, query: { type: '1' } });
-    },
-    // 个人详情
-    perDetail(data) {
-      this.$router.push({ path: `/account/mechCenter/users/detail`, query: { id: data.id, type: '1' } });
-    },
-    // 查询专利信息
-    toPatent(data) {
-      this.$router.push({ path: `/account/mechCenter/patent/index`, query: { id: data._id } });
-    },
-    // 企业详情
-    orgDetail(data) {
-      this.$router.push({ path: `/account/mechCenter/users/detail`, query: { id: data.id, type: '2' } });
-    },
-    // 选择用户类别
-    change(type) {
-      this.$set(this, `active`, type);
-      this.search();
-    },
-    // 返回
-    back() {
-      this.$router.push({ path: `/account/index` });
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 0 - 88
src/views/account/mechCenter/users/parts/company-1.vue

@@ -1,88 +0,0 @@
-<template>
-  <div id="company-1">
-    <van-col span="24" class="main">
-      <van-col span="24" class="list" v-for="(item, index) in list" :key="index" @click.native="detail(item)">
-        <van-col span="24" class="title">
-          {{ item.name }}
-        </van-col>
-        <van-col span="24" class="other">
-          <van-col span="24" class="otherInfo">
-            机构代码或邀请码:<span style="color: #ff0000">{{ item.code || '暂无' }}</span>
-          </van-col>
-          <van-col span="24" class="otherInfo">
-            社会统一信用代码:<span>{{ item.institution_code || '暂无' }}</span>
-          </van-col>
-          <van-col span="12" class="otherInfo">
-            联系电话:<span>{{ item.phone || '暂无' }}</span>
-          </van-col>
-          <van-col span="12" class="otherInfo">
-            所属辖区:<span>{{ item.juris || '暂无' }}</span>
-          </van-col>
-          <van-col span="24" class="otherInfo">
-            审核状态:<span>{{ item.status == '0' ? '待审中' : item.status == '1' ? '审核通过' : '审核拒绝' }}</span>
-          </van-col>
-        </van-col>
-      </van-col>
-    </van-col>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'company-1',
-  props: {
-    list: { type: Array },
-  },
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    detail(data) {
-      this.$emit('detail', data);
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  padding: 8px 8px 0 8px;
-  .list {
-    background-color: #fff;
-    margin: 0 0 8px 0;
-    padding: 8px;
-    border-radius: 5px;
-    .title {
-      font-size: 16px;
-      font-weight: bold;
-      margin: 0 0 5px 0;
-    }
-    .other {
-      .otherInfo {
-        font-size: 14px;
-        color: #666;
-        margin: 0 0 5px 0;
-        span {
-          color: #000;
-        }
-      }
-    }
-  }
-}
-</style>

+ 0 - 77
src/views/account/mechCenter/users/parts/company-detail.vue

@@ -1,77 +0,0 @@
-<template>
-  <div id="company-detail">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-form @submit="onSubmit">
-          <van-field v-model="form.name" name="name" label="姓名" readonly />
-          <van-field v-model="form.phone" name="phone" label="手机号" readonly />
-          <van-field v-model="form.code" name="code" label="机构代码" readonly />
-          <van-field v-model="form.email" name="email" label="电子邮箱" readonly />
-          <van-field v-model="form.addr" name="addr" label="地址" readonly />
-          <van-field v-model="form.office_phone" name="office_phone" label="办公电话" readonly />
-          <van-field v-model="form.profession" name="profession" label="所属行业" readonly />
-          <van-field v-model="form.juris" name="juris" label="所属辖区" readonly />
-          <van-field v-model="form.institution_code" name="institution_code" label="统一社会信用代码" readonly />
-          <van-field v-model="form.companytype" name="companytype" label="注册类型" readonly />
-          <van-field v-model="form.companydate" name="companydate" label="注册时间" readonly />
-          <van-field v-model="form.companycapital" name="companycapital" label="注册资金" readonly />
-          <van-field v-model="form.companyperson" name="companyperson" label="企业法人" readonly />
-          <van-field v-model="form.sndqyzsr" name="sndqyzsr" label="上年度企业总收入" readonly />
-          <van-field v-model="form.sndyffy" name="sndyffy" label="上年度研发费用" readonly />
-          <van-field v-model="form.companytotal" name="companytotal" label="企业总人数" readonly />
-          <van-field v-model="form.zjzyfrs" name="zjzyfrs" label="专&兼职研发人数" readonly />
-          <van-field v-model="form.companybrief" name="companybrief" label="企业简介" rows="1" autosize type="textarea" readonly />
-          <van-field v-model="form.mainproduct" name="mainproduct" label="主要产品" rows="1" autosize type="textarea" readonly />
-          <van-field v-model="form.qualifications" name="qualifications" label="企业资质&荣誉" rows="1" autosize type="textarea" readonly />
-          <van-field name="status" 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 name="2">拒绝</van-radio>
-              </van-radio-group>
-            </template>
-          </van-field>
-          <div style="margin: 16px">
-            <van-button round block type="info" native-type="submit">提交</van-button>
-          </div>
-        </van-form>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'company-detail',
-  props: {
-    form: { type: Object },
-  },
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    onSubmit() {
-      this.$emit('onSubmit', this.form);
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 0 - 84
src/views/account/mechCenter/users/parts/personal-detail.vue

@@ -1,84 +0,0 @@
-<template>
-  <div id="personal-detail">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-form @submit="onSubmit">
-          <van-field v-model="form.name" name="name" label="姓名" />
-          <van-field v-model="form.phone" name="phone" label="手机号" />
-          <van-field v-model="form.password" name="password" type="password" label="密码" v-if="id == null" />
-          <van-field v-model="form.code" name="code" label="机构代码" />
-          <van-field v-model="form.email" name="email" label="电子邮箱" />
-          <van-field v-model="form.addr" name="addr" label="地址" />
-          <van-field v-model="form.office_phone" name="office_phone" label="办公电话" />
-          <van-field v-model="form.profession" name="profession" label="所属行业" />
-          <van-field clickable name="juris" :value="form.juris" label="所属辖区" placeholder="点击选择" @click="showPicker = true" />
-          <van-field v-model="form.school" name="院校" label="院校" placeholder="院校" />
-          <van-field v-model="form.major" name="专业" label="专业" placeholder="专业" />
-          <van-field v-model="form.card" name="身份证号" label="身份证号" placeholder="身份证号" />
-          <van-field v-model="form.zwzc" name="职务职称" label="职务职称" placeholder="职务职称" />
-          <van-popup v-model="showPicker" position="bottom">
-            <van-picker show-toolbar :columns="jurisList" @confirm="onConfirm" @cancel="showPicker = false" />
-          </van-popup>
-          <van-field name="status" 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 name="2">拒绝</van-radio>
-              </van-radio-group>
-            </template>
-          </van-field>
-          <div style="margin: 16px">
-            <van-button round block type="info" native-type="submit">提交</van-button>
-          </div>
-        </van-form>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'personal-detail',
-  props: {
-    form: { type: Object },
-  },
-  components: {},
-  data: function () {
-    return {
-      showPicker: false,
-      jurisList: ['长春新区', '净月区', '汽开区', '经开区', '高新区', '南关区', '朝阳区', '宽城区', '二道区', '绿园区', '双阳区', '九台区'],
-    };
-  },
-  created() {},
-  methods: {
-    onSubmit() {
-      this.$emit('onSubmit', this.form);
-    },
-    // 选择辖区
-    onConfirm(value) {
-      this.$set(this.form, `juris`, value);
-      this.showPicker = false;
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-    id() {
-      return this.$route.query.id;
-    },
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 2 - 2
src/views/account/adminCenter/mechanism/detail.vue

@@ -32,7 +32,7 @@ export default {
   methods: {
     ...adminLogin(['query', 'fetch', 'update', 'delete', 'create']),
     async search() {
-      let res = await this.query({ role: '1' });
+      let res = await this.query({ role: '1', code: this.user.code });
       if (this.$checkRes(res)) {
         this.$set(this, `pidList`, res.data);
       }
@@ -62,7 +62,7 @@ export default {
       }
     },
     back() {
-      this.$router.push({ path: `/account/adminCenter/mechanism/index` });
+      this.$router.push({ path: `/account/mechanism/index` });
     },
   },
   computed: {

+ 10 - 10
src/views/account/adminCenter/mechanism/index.vue

@@ -2,12 +2,11 @@
   <div id="index">
     <admin-frame @search="search" :limit="limit" :total="total" topType="2" @add="add" @back="back" :useNav="false">
       <template v-slot:info>
-        <list-1 :list="list" @detail="detail"></list-1>
+        <list-1 :list="list" @toEdit="toEdit"></list-1>
       </template>
     </admin-frame>
   </div>
 </template>
-
 <script>
 import list1 from './parts/list_1.vue';
 import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
@@ -31,23 +30,24 @@ export default {
     await this.search();
   },
   methods: {
-    ...adminLogin(['query', 'fetch', 'update', 'delete']),
+    ...adminLogin(['query', 'delete']),
     async search({ skip = 0, limit = this.limit, searchName, ...info } = {}) {
-      if (this.user.role == '1' || this.user.role == '2') info.pid = this.user.id;
       if (searchName) info.name = this.searchName;
-      let res = await this.query({ skip, limit, role: '2', ...info });
+      let res = await this.query({ skip, limit, pid: this.user.id, role: '2', ...info });
       if (this.$checkRes(res)) {
         this.$set(this, `list`, res.data);
         this.$set(this, `total`, res.total);
       }
     },
-    // 查看详情
-    detail(data) {
-      this.$router.push({ path: `/account/adminCenter/mechanism/detail`, query: { id: data.id } });
-    },
+    // 添加
     add() {
-      this.$router.push({ path: `/account/adminCenter/mechanism/detail` });
+      this.$router.push({ path: `/account/mechanism/detail` });
     },
+    // 编辑
+    toEdit(data) {
+      this.$router.push({ path: `/account/mechanism/detail`, query: { id: data.id } });
+    },
+
     back() {
       this.$router.push({ path: `/account/index` });
     },

src/views/account/adminCenter/mechanism/parts/detail_1.vue → src/views/account/mechanism/parts/detail_1.vue


+ 13 - 4
src/views/account/adminCenter/mechanism/parts/list_1.vue

@@ -1,7 +1,7 @@
 <template>
   <div id="list_1">
     <van-col span="24" class="main">
-      <van-col span="24" class="list" v-for="(item, index) in list" :key="index" @click.native="detail(item)">
+      <van-col span="24" class="list" v-for="(item, index) in list" :key="index">
         <van-col span="24" class="title">
           {{ item.name }}
         </van-col>
@@ -16,6 +16,9 @@
             联系电话:<span>{{ item.phone || '暂无' }}</span>
           </van-col>
         </van-col>
+        <van-col span="24" class="btn">
+          <van-button type="info" size="small" @click="toEdit(item)">编辑信息</van-button>
+        </van-col>
       </van-col>
     </van-col>
   </div>
@@ -34,8 +37,8 @@ export default {
   },
   created() {},
   methods: {
-    detail(data) {
-      this.$emit('detail', data);
+    toEdit(data) {
+      this.$emit('toEdit', data);
     },
   },
   computed: {
@@ -56,7 +59,6 @@ export default {
 
 <style lang="less" scoped>
 .main {
-  padding: 8px 8px 0 8px;
   .list {
     background-color: #fff;
     margin: 0 0 8px 0;
@@ -68,6 +70,7 @@ export default {
       margin: 0 0 5px 0;
     }
     .other {
+      margin: 0 0 5px 0;
       .otherInfo {
         font-size: 14px;
         color: #666;
@@ -77,6 +80,12 @@ export default {
         }
       }
     }
+    .btn {
+      text-align: center;
+      .van-button {
+        margin: 0 10px;
+      }
+    }
   }
 }
 </style>

+ 0 - 48
src/views/account/parts/role-1.vue

@@ -1,48 +0,0 @@
-<template>
-  <div id="role-1">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-cell title="机构用户" @click="to('mechanism')" is-link />
-        <van-cell title="平台用户" @click="to('users')" is-link />
-        <!-- <van-cell title="我的消息" @click="to('message')" is-link />
-        <van-cell title="申请管理" @click="to('disclosure')" is-link />
-        <van-cell title="专利管理" @click="to('patent')" is-link />
-        <van-cell title="交易管理" @click="to('trade')" is-link /> 
-        <van-cell title="统计" is-link /> -->
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'role-1',
-  props: {},
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    to(type) {
-      this.$router.push({ path: `/account/adminCenter/${type}/index` });
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 0 - 47
src/views/account/parts/role-2.vue

@@ -1,47 +0,0 @@
-<template>
-  <div id="role-2">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-cell title="平台用户" @click="to('users')" is-link />
-        <!-- <van-cell title="我的消息" @click="to('message')" is-link />
-        <van-cell title="申请管理" @click="to('disclosure')" is-link />
-        <van-cell title="专利管理" @click="to('patent')" is-link />
-        <van-cell title="交易管理" @click="to('trade')" is-link />
-        <van-cell title="统计" is-link /> -->
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'role-2',
-  props: {},
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    to(type) {
-      this.$router.push({ path: `/account/mechCenter/${type}/index` });
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 0 - 43
src/views/account/parts/role-3.vue

@@ -1,43 +0,0 @@
-<template>
-  <div id="role-3">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-cell title="基本信息" @click="to('basic')" is-link />
-        <van-cell title="修改密码" @click="to('password')" is-link />
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'role-3',
-  props: {},
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    to(type) {
-      this.$router.push({ path: `/account/userCenter/${type}/index` });
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 9 - 2
src/views/account/userCenter/password/index.vue

@@ -2,8 +2,15 @@
   <div id="login">
     <admin-frame topType="2" @back="back" :rightArrow="false" :usePage="false" :useNav="false">
       <template v-slot:info>
-        <van-form @submit="onSubmit">
-          <van-field v-model="form.password" type="password" name="password" label="新密码" :rules="[{ required: true, message: '请填写密码' }]" />
+        <van-form @submit="onSubmit" label-width="4em">
+          <van-field
+            v-model="form.password"
+            type="password"
+            name="password"
+            label="新密码"
+            placeholder="请填写密码"
+            :rules="[{ required: true, message: '请填写密码' }]"
+          />
           <div style="margin: 16px">
             <van-button round block type="info" native-type="submit">提交修改</van-button>
           </div>

+ 11 - 8
src/views/account/mechCenter/patent/index.vue

@@ -1,12 +1,12 @@
 <template>
   <div id="index">
-    <admin-frame @search="search" :limit="limit" :total="total" topType="2" @back="back" :rightArrow="false" :useNav="false">
+    <admin-frame @search="search" :limit="limit" :total="total" topType="3" @back="back" :rightArrow="false" :useNav="false">
       <template v-slot:info>
         <list-1 :list="list" @detail="detail"></list-1>
       </template>
     </admin-frame>
-    <van-dialog class="dialog" v-model="show" title="详细信息" :show-confirm-button="false" show-cancel-button>
-      <info-1 :info="info"></info-1>
+    <van-dialog class="dialog" v-model="dialog.show" :title="dialog.title" :show-confirm-button="false" show-cancel-button>
+      <info-1 :info="info" v-if="dialog.type == '1'"></info-1>
     </van-dialog>
   </div>
 </template>
@@ -30,8 +30,10 @@ export default {
       limit: 5,
       total: 0,
       list: [],
+      // 弹框
+      dialog: { show: false, title: '详细信息', type: '1' },
+      // 详细信息
       info: {},
-      show: false,
     };
   },
   async created() {
@@ -39,8 +41,9 @@ export default {
   },
   methods: {
     ...patentinfo(['query']),
-    async search({ skip = 0, limit = this.limit, ...info } = {}) {
+    async search({ skip = 0, limit = this.limit, searchName, ...info } = {}) {
       info.user_id = this.id;
+      if (searchName) info.name = searchName;
       let res = await this.query({ skip, limit, ...info });
       if (this.$checkRes(res)) {
         this.$set(this, `list`, res.data);
@@ -51,11 +54,11 @@ export default {
     detail(data) {
       data.inventor = JSON.stringify(data.inventor.map((i) => i.name));
       this.$set(this, `info`, data);
-      this.show = true;
+      this.dialog = { show: true, title: '详细信息', type: '1' };
     },
     // 返回
     back() {
-      this.$router.push({ path: '/account/mechCenter/users/index' });
+      this.$router.push({ path: '/account/users/index' });
     },
   },
   computed: {
@@ -80,7 +83,7 @@ export default {
 <style lang="less" scoped>
 .dialog {
   /deep/.van-dialog__content {
-    height: 350px;
+    max-height: 350px;
     overflow-y: auto;
   }
 }

src/views/account/mechCenter/patent/parts/info-1.vue → src/views/account/patent/parts/info-1.vue


src/views/account/mechCenter/patent/parts/list-1.vue → src/views/account/patent/parts/list-1.vue


+ 0 - 105
src/views/account/userCenter/basic/index.vue

@@ -1,105 +0,0 @@
-<template>
-  <div id="index">
-    <admin-frame :usePage="false" topType="2" @back="back">
-      <template v-slot:info>
-        <van-tabs v-model="active">
-          <van-tab title="基本信息">
-            <basic-1 :userInfo="userInfo" @onSubmit="onSubmit"></basic-1>
-          </van-tab>
-          <van-tab title="详细信息" v-if="isCom(userInfo)">
-            <company-1 :userInfo="userInfo" @onSubmit="onSubmit"></company-1>
-          </van-tab>
-        </van-tabs>
-      </template>
-    </admin-frame>
-  </div>
-</template>
-
-<script>
-import basic1 from '../parts/basic-1.vue';
-import company1 from '../parts/company-1.vue';
-import adminFrame from '@/layout/common/admin-frame.vue';
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: organization } = createNamespacedHelpers('organization');
-const { mapActions: personal } = createNamespacedHelpers('personal');
-export default {
-  name: 'index',
-  props: {},
-  components: {
-    adminFrame,
-    basic1,
-    company1,
-  },
-  data: function () {
-    return {
-      active: 0,
-      userInfo: {},
-    };
-  },
-  async created() {
-    if (this.user) await this.search();
-  },
-  methods: {
-    ...organization(['fetch', 'update']),
-    ...personal({ personalFetch: 'fetch', personalUpdate: 'update' }),
-    async search() {
-      if (this.user.is_expert == undefined) {
-        let res = await this.fetch(this.user.id);
-        if (this.$checkRes(res)) {
-          this.$set(this, `userInfo`, res.data);
-        }
-      } else {
-        let res = await this.personalFetch(this.user.id);
-        if (this.$checkRes(res)) {
-          this.$set(this, `userInfo`, res.data);
-        }
-      }
-    },
-    // 保存基本信息
-    async onSubmit({ data }) {
-      if (this.user.is_expert == undefined) {
-        let res = await this.update(data);
-        if (this.$checkRes(res)) {
-          this.$notify({
-            message: '基本信息修改成功',
-            type: 'success',
-          });
-          this.search();
-        }
-      } else {
-        let res = await this.personalUpdate(data);
-        if (this.$checkRes(res)) {
-          this.$notify({
-            message: '基本信息修改成功',
-            type: 'success',
-          });
-          this.search();
-        }
-      }
-    },
-    back() {
-      this.$router.push({ path: '/account/index' });
-    },
-    // 判断是否是企业
-    isCom(data) {
-      if (data.is_expert == false || data.is_expert == true) return false;
-      else return true;
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 0 - 72
src/views/account/userCenter/parts/basic-1.vue

@@ -1,72 +0,0 @@
-<template>
-  <div id="basic-1">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-form>
-          <van-field v-model="userInfo.name" name="用户名称" label="用户名称" placeholder="用户名称" />
-          <van-field v-model="userInfo.phone" name="联系电话" label="联系电话" placeholder="联系电话" />
-          <van-field v-model="userInfo.code" name="所属机构" label="所属机构" placeholder="所属机构" readonly />
-          <van-field v-model="userInfo.email" name="电子邮箱" label="电子邮箱" placeholder="电子邮箱" />
-          <van-field v-model="userInfo.addr" name="联系地址" label="联系地址" placeholder="联系地址" />
-          <van-field v-model="userInfo.office_phone" name="办公电话" label="办公电话" placeholder="办公电话" />
-          <van-field v-model="userInfo.profession" name="所属行业" label="所属行业" placeholder="所属行业" />
-          <van-field readonly clickable name="picker" :value="userInfo.juris" label="所属辖区" placeholder="点击选择" @click="showPicker = true" />
-          <van-popup v-model="showPicker" position="bottom">
-            <van-picker show-toolbar :columns="jurisList" @confirm="onConfirm" @cancel="showPicker = false" />
-          </van-popup>
-          <van-field v-model="userInfo.school" name="院校" label="院校" placeholder="院校" />
-          <van-field v-model="userInfo.major" name="专业" label="专业" placeholder="专业" />
-          <van-field v-model="userInfo.card" name="身份证号" label="身份证号" placeholder="身份证号" />
-          <van-field v-model="userInfo.zwzc" name="职务职称" label="职务职称" placeholder="职务职称" />
-          <van-col span="24" class="btn">
-            <van-button round block type="info" @click="onSubmit">保存信息</van-button>
-            <!-- <van-button round block type="info" @click="upgradeBtn" v-if="userInfo.is_expert == false">升级用户</van-button> -->
-          </van-col>
-        </van-form>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { juris } from '@common/dict/index';
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'basic-1',
-  props: {
-    userInfo: { type: Object },
-  },
-  components: {},
-  data: function () {
-    return {
-      showPicker: false,
-      jurisList: juris,
-    };
-  },
-  created() {},
-  methods: {
-    onSubmit() {
-      this.$emit('onSubmit', { data: this.userInfo });
-    },
-    onConfirm(value) {
-      this.$set(this.userInfo, `juris`, value);
-      this.showPicker = false;
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 0 - 104
src/views/account/userCenter/parts/company-1.vue

@@ -1,104 +0,0 @@
-<template>
-  <div id="company-1">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-form>
-          <van-field v-model="userInfo.institution_code" name="信用代码" label="信用代码" placeholder="信用代码" disabled />
-          <van-field v-model="userInfo.companyperson" name="企业法人" label="企业法人" placeholder="企业法人" />
-          <van-field v-model="userInfo.companycapital" name="注册资金" label="注册资金" placeholder="注册资金" />
-          <van-field
-            readonly
-            clickable
-            name="calendar"
-            :value="userInfo.companydate"
-            label="注册时间"
-            placeholder="点击选择日期"
-            @click="showCalendar = true"
-          />
-          <van-calendar v-model="showCalendar" @confirm="onConfirm" />
-          <van-field v-model="userInfo.companytype" name="注册类型" label="注册类型" placeholder="注册类型" />
-          <van-field v-model="userInfo.companytotal" name="企业总人数" label="企业总人数" placeholder="企业总人数" />
-          <van-field v-model="userInfo.sndyffy" name="研发费用" label="研发费用" placeholder="研发费用" />
-          <van-field v-model="userInfo.sndqyzsr" name="企业总收入" label="企业总收入" placeholder="企业总收入" />
-          <van-field v-model="userInfo.zjzyfrs" name="研发人数" label="研发人数" placeholder="研发人数" />
-          <van-field
-            v-model="userInfo.companybrief"
-            name="企业简介"
-            label="企业简介"
-            placeholder="企业简介"
-            type="textarea"
-            rows="2"
-            autosize
-            maxlength="300"
-            show-word-limit
-          />
-          <van-field
-            v-model="userInfo.mainproduct"
-            name="主要产品"
-            label="主要产品"
-            placeholder="主要产品"
-            type="textarea"
-            rows="2"
-            autosize
-            maxlength="300"
-            show-word-limit
-          />
-          <van-field
-            v-model="userInfo.qualifications"
-            name="企业资质"
-            label="企业资质"
-            placeholder="企业资质"
-            type="textarea"
-            rows="2"
-            autosize
-            maxlength="300"
-            show-word-limit
-          />
-          <van-col span="24" class="btn">
-            <van-button round block type="info" @click="onSubmit">保存信息</van-button>
-          </van-col>
-        </van-form>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-var moment = require('moment');
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'company-1',
-  props: { userInfo: { type: Object } },
-  components: {},
-  data: function () {
-    return {
-      showCalendar: false,
-    };
-  },
-  created() {},
-  methods: {
-    onSubmit() {
-      this.$emit('onSubmit', { data: this.userInfo });
-    },
-    onConfirm(date) {
-      this.$set(this.userInfo, `companydate`, moment(date).format('YYYY-MM-DD'));
-      this.showCalendar = false;
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 19 - 13
src/views/market/patentInfo/detail.vue

@@ -1,45 +1,51 @@
 <template>
   <div id="detail">
-    <admin-frame topType="2" @back="back" :rightArrow="false" :usePage="false" :useNav="false">
+    <admin-frame :usePage="false" topType="2" :rightArrow="false" @back="back" :useNav="false">
       <template v-slot:info>
-        <info-1 :info="info"></info-1>
+        <personal-detail :form="form" @onSubmit="onSubmit"></personal-detail>
       </template>
     </admin-frame>
   </div>
 </template>
 
 <script>
-import info1 from './parts/info-1.vue';
+import personalDetail from './parts/personal-detail.vue';
 import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
 import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: patentinfo } = createNamespacedHelpers('patentinfo');
+const { mapActions: personal } = createNamespacedHelpers('personal');
 export default {
-  name: 'index',
+  name: 'detail',
   props: {},
   components: {
     adminFrame,
-    info1,
+    personalDetail,
   },
   data: function () {
     return {
-      info: {},
+      form: {},
     };
   },
   async created() {
-    if (this.id) await this.search();
+    await this.search();
   },
   methods: {
-    ...patentinfo(['fetch']),
+    ...personal(['fetch', 'update']),
     async search() {
       let res = await this.fetch(this.id);
       if (this.$checkRes(res)) {
-        res.data.inventor = JSON.stringify(res.data.inventor.map((i) => i.name));
-        this.$set(this, `info`, res.data);
+        this.$set(this, `form`, res.data);
+      }
+    },
+    // 審核
+    async onSubmit(data) {
+      let res = await this.update(data);
+      if (this.$checkRes(res)) {
+        this.$toast({ type: `success`, message: `操作成功` });
+        this.back();
       }
     },
-    // 返回
     back() {
-      this.$router.push({ path: '/market/patentInfo/index' });
+      this.$router.push({ path: `/account/users/index` });
     },
   },
   computed: {

+ 1 - 1
src/views/account/adminCenter/users/import_user.vue

@@ -57,7 +57,7 @@ export default {
     },
     // 返回
     back() {
-      this.$router.push({ path: `/account/adminCenter/users/index` });
+      this.$router.push({ path: `/account/users/index` });
     },
   },
   computed: {

+ 94 - 0
src/views/account/users/index.vue

@@ -0,0 +1,94 @@
+<template>
+  <div id="index">
+    <admin-frame @search="search" :limit="limit" :total="total" topType="3" @back="back" :rightArrow="false" :useNav="false">
+      <template v-slot:info>
+        <van-col span="24" v-if="user.role == '1'" class="one">
+          <van-button type="info" size="small" @click="toImport()">批量注册用户</van-button>
+          <van-button type="info" size="small" @click="tpExport()">批量导出用户</van-button>
+        </van-col>
+        <personal-1 :list="list" @toCheck="toCheck" @toPatent="toPatent"></personal-1>
+      </template>
+    </admin-frame>
+  </div>
+</template>
+
+<script>
+import personal1 from './parts/personal-1.vue';
+import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
+import { mapState, createNamespacedHelpers } from 'vuex';
+const { mapActions: personal } = createNamespacedHelpers('personal');
+export default {
+  name: 'index',
+  props: {},
+  components: { adminFrame, personal1 },
+  data: function () {
+    return {
+      list: [],
+      limit: 4,
+      total: 0,
+    };
+  },
+  created() {
+    this.search();
+  },
+  methods: {
+    ...personal(['query', 'export']),
+    async search({ skip = 0, limit = this.limit, searchName, ...info } = {}) {
+      if (searchName) info.name = searchName;
+      let res = await this.query({ skip, limit, code: this.user.code, ...info });
+      if (this.$checkRes(res)) {
+        this.$set(this, `list`, res.data);
+        this.$set(this, `total`, res.total);
+      }
+    },
+    // 查看信息
+    toCheck(data) {
+      this.$router.push({ path: `/account/users/detail`, query: { id: data.id } });
+    },
+    // 专利信息
+    toPatent(data) {
+      this.$router.push({ path: `/account/patent/index`, query: { id: data._id } });
+    },
+    // 批量注册用户
+    toImport() {
+      this.$router.push({ path: `/account/users/import_user` });
+    },
+    // 导出用户
+    async tpExport() {
+      let res = await this.export();
+      if (this.$checkRes(res)) {
+        window.location.href = `${process.env.VUE_APP_HOST}/${res.data}`;
+      }
+    },
+    // 返回
+    back() {
+      this.$router.push({ path: `/account/index` });
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped>
+.one {
+  background-color: #ffffff;
+  text-align: center;
+  padding: 10px 0;
+  margin: 0 0 10px 0;
+  .van-button {
+    margin: 0 10px;
+  }
+}
+</style>

src/views/account/adminCenter/users/parts/importForm-1.vue → src/views/account/users/parts/importForm-1.vue


+ 6 - 10
src/views/account/mechCenter/users/parts/personal-1.vue

@@ -13,15 +13,12 @@
             联系电话:<span>{{ item.phone || '暂无' }}</span>
           </van-col>
           <van-col span="12" class="otherInfo">
-            所属辖区:<span>{{ item.juris || '暂无' }}</span>
-          </van-col>
-          <van-col span="24" class="otherInfo">
             审核状态:<span>{{ item.status == '0' ? '待审中' : item.status == '1' ? '审核通过' : '审核拒绝' }}</span>
           </van-col>
         </van-col>
         <van-col span="24" class="btn">
-          <van-button type="info" size="small" @click="detail(item)">查看详情</van-button>
-          <van-button type="info" size="small" @click="patent(item)">查看专利</van-button>
+          <van-button type="info" size="small" @click="toCheck(item)">审核信息</van-button>
+          <van-button type="info" size="small" @click="toPatent(item)">查看专利</van-button>
         </van-col>
       </van-col>
     </van-col>
@@ -41,11 +38,11 @@ export default {
   },
   created() {},
   methods: {
-    detail(data) {
-      this.$emit('detail', data);
+    toCheck(data) {
+      this.$emit('toCheck', data);
     },
-    patent(data) {
-      this.$emit('patent', data);
+    toPatent(data) {
+      this.$emit('toPatent', data);
     },
   },
   computed: {
@@ -66,7 +63,6 @@ export default {
 
 <style lang="less" scoped>
 .main {
-  padding: 8px 8px 0 8px;
   .list {
     background-color: #fff;
     margin: 0 0 8px 0;

+ 19 - 9
src/views/account/adminCenter/users/parts/personal-detail.vue

@@ -2,19 +2,18 @@
   <div id="personal-detail">
     <van-row>
       <van-col span="24" class="main">
-        <van-form @submit="onSubmit">
+        <van-form @submit="onSubmit" label-width="4em">
           <van-field v-model="form.name" name="name" label="姓名" readonly />
           <van-field v-model="form.phone" name="phone" label="手机号" readonly />
-          <van-field v-model="form.code" name="code" label="机构代码" readonly />
+          <van-field v-model="form.code" name="code" label="邀请码" readonly />
+          <van-field v-model="form.card" name="card" label="身份证号" readonly />
           <van-field v-model="form.email" name="email" label="电子邮箱" readonly />
-          <van-field v-model="form.addr" name="addr" label="地址" readonly />
+          <van-field v-model="form.addr" name="addr" label="联系地址" readonly />
+          <van-field v-model="form.zwzc" name="zwzc" label="职务职称" readonly />
+          <van-field v-model="form.school" name="school" label="院校" readonly />
+          <van-field v-model="form.major" name="major" label="专业" readonly />
           <van-field v-model="form.office_phone" name="office_phone" label="办公电话" readonly />
-          <van-field v-model="form.profession" name="profession" label="所属行业" readonly />
           <van-field v-model="form.juris" name="juris" label="所属辖区" readonly />
-          <van-field v-model="form.school" name="院校" label="院校" placeholder="院校" />
-          <van-field v-model="form.major" name="专业" label="专业" placeholder="专业" />
-          <van-field v-model="form.card" name="身份证号" label="身份证号" placeholder="身份证号" />
-          <van-field v-model="form.zwzc" name="职务职称" label="职务职称" placeholder="职务职称" />
           <van-field name="status" label="状态">
             <template #input>
               <van-radio-group v-model="form.status" direction="horizontal">
@@ -42,16 +41,27 @@ export default {
   },
   components: {},
   data: function () {
-    return {};
+    return {
+      showPicker: false,
+      jurisList: ['长春新区', '净月区', '汽开区', '经开区', '高新区', '南关区', '朝阳区', '宽城区', '二道区', '绿园区', '双阳区', '九台区'],
+    };
   },
   created() {},
   methods: {
     onSubmit() {
       this.$emit('onSubmit', this.form);
     },
+    // 选择辖区
+    onConfirm(value) {
+      this.$set(this.form, `juris`, value);
+      this.showPicker = false;
+    },
   },
   computed: {
     ...mapState(['user']),
+    id() {
+      return this.$route.query.id;
+    },
   },
   metaInfo() {
     return { title: this.$route.meta.title };

+ 10 - 0
src/views/login.vue

@@ -8,6 +8,12 @@
             <van-tab title="平台用户">
               <login-1></login-1>
             </van-tab>
+            <van-tab title="代理机构">
+              <login-3></login-3>
+            </van-tab>
+            <van-tab title="答题师">
+              <login-4></login-4>
+            </van-tab>
             <van-tab title="管理用户">
               <login-2></login-2>
             </van-tab>
@@ -21,6 +27,8 @@
 <script>
 import login1 from '@/layout/login/login-1.vue';
 import login2 from '@/layout/login/login-2.vue';
+import login3 from '@/layout/login/login-3.vue';
+import login4 from '@/layout/login/login-4.vue';
 import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
 import { mapState, createNamespacedHelpers } from 'vuex';
 export default {
@@ -30,6 +38,8 @@ export default {
     adminFrame,
     login1,
     login2,
+    login3,
+    login4,
   },
   data: function () {
     return {

+ 14 - 27
src/views/market/patentInfo/index.vue

@@ -7,26 +7,24 @@
           <span class="total">({{ total }})</span>
         </van-col>
         <van-col :span="24" class="two">
-          <list-1 :list="list" @detail="detail"></list-1>
+          <list-1 :list="list" @toView="toView"></list-1>
         </van-col>
       </template>
     </admin-frame>
     <van-dialog class="dialog" v-model="dialog.show" :title="dialog.title" :show-confirm-button="false" show-cancel-button>
-      <search-1 v-if="dialog.type == '1'" :searchForm="searchForm" @reseat="reseat" @onSubmit="onSubmit" @changeCreate="changeCreate"></search-1>
+      <search-1 v-if="dialog.type == '1'" :searchForm="searchForm" @reseat="reseat" @onSubmit="onSubmit"></search-1>
       <info-1 v-else-if="dialog.type == '2'" :info="info"></info-1>
     </van-dialog>
-    <van-calendar v-model="oneShow" @confirm="oneChange" :min-date="minDate" :max-date="maxDate" />
   </div>
 </template>
 
 <script>
-import search1 from './parts/search-1.vue';
-import list1 from './parts/list-1.vue';
-import info1 from '@/layout/patent/info-1.vue';
+import search1 from '@/layout/patentInfo/search-1.vue';
+import list1 from '@/layout/patentInfo/list-1.vue';
+import info1 from '@/layout/patentInfo/info-1.vue';
 import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
 import { mapState, createNamespacedHelpers } from 'vuex';
 const { mapActions: patentinfo } = createNamespacedHelpers('patentinfo');
-const moment = require('moment');
 export default {
   name: 'index',
   props: {},
@@ -39,12 +37,8 @@ export default {
   data: function () {
     return {
       list: [],
-      limit: 5,
+      limit: 4,
       total: 0,
-      // 选择申请日
-      oneShow: false,
-      minDate: new Date(1900, 1, 1),
-      maxDate: new Date(2050, 1, 1),
       // 弹框
       dialog: { show: false, title: '查询条件', type: '1' },
       // 查询条件
@@ -57,7 +51,7 @@ export default {
     await this.search();
   },
   methods: {
-    ...patentinfo(['query']),
+    ...patentinfo(['query', 'fetch']),
     async search({ skip = 0, limit = this.limit, ...info } = {}) {
       let res = await this.query({ skip, limit, ...this.searchForm, ...info });
       if (this.$checkRes(res)) {
@@ -66,11 +60,13 @@ export default {
       }
     },
     // 详情
-    detail(data) {
-      data.inventor = JSON.stringify(data.inventor.map((i) => i.name));
-      this.$set(this, `info`, data);
-      let dialog = { show: true, title: '详细信息', type: '2' };
-      this.$set(this, `dialog`, dialog);
+    async toView(data) {
+      let res = await this.fetch(data.id);
+      if (this.$checkRes(res)) {
+        res.data.inventor = JSON.stringify(res.data.inventor.map((i) => i.name));
+        this.$set(this, `info`, res.data);
+        this.dialog = { show: true, title: '详细信息', type: '2' };
+      }
     },
     // 查询
     toSearch() {
@@ -88,15 +84,6 @@ export default {
       let dialog = { show: false, title: '查询条件', type: '1' };
       this.$set(this, `dialog`, dialog);
     },
-    changeCreate() {
-      this.oneShow = true;
-    },
-    // 选择申请日
-    oneChange(value) {
-      let date = moment(value).format('YYYY-MM-DD');
-      this.$set(this.searchForm, `create_date`, date);
-      this.oneShow = false;
-    },
   },
   computed: {
     ...mapState(['user']),

+ 0 - 81
src/views/market/patentInfo/parts/info-1.vue

@@ -1,81 +0,0 @@
-<template>
-  <div id="info-1">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-col :span="24" class="one">
-          <van-image :src="img_url"> </van-image>
-          <van-form>
-            <van-field v-model="info.term" label="专利有效性" readonly />
-            <van-field v-model="info.name" label="专利名称" type="textarea" autosize readonly />
-            <van-field v-model="info.create_number" label="申请号" readonly />
-            <van-field v-model="info.create_date" label="申请日" readonly />
-            <van-field v-model="info.success_number" label="公开(公告)号" readonly />
-            <van-field v-model="info.success_date" label="公开(公告)日" readonly />
-            <van-field v-model="info.type" label="专利类型" readonly />
-            <van-field v-model="info.inventor" label="发明人" type="textarea" autosize readonly />
-            <van-field v-model="info.address" label="发明人地址" readonly />
-            <van-field v-model="info.apply_personal" label="申请人" readonly />
-            <van-field v-model="info.agent_personal" label="代理人" readonly />
-            <van-field v-model="info.agent" label="代理机构" readonly />
-            <van-field v-model="info.abstract" label="摘要" type="textarea" autosize readonly />
-          </van-form>
-        </van-col>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'info-1',
-  props: {
-    info: { type: Object },
-  },
-  components: {},
-  data: function () {
-    return {
-      img_url: '',
-    };
-  },
-  created() {},
-  methods: {
-    searchImg(data) {
-      if (data && data.length > 0) {
-        var url = data.map((item) => item.url)[0];
-        this.$set(this, `img_url`, url);
-      } else {
-        var url = require('@/assets/fmzl.jpg');
-        this.$set(this, `img_url`, url);
-      }
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    info: {
-      deep: true,
-      immediate: true,
-      handler(val) {
-        this.searchImg(val.img_url);
-      },
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  .one {
-    .van-image {
-      width: 100%;
-      height: 220px;
-      overflow: hidden;
-    }
-  }
-}
-</style>

+ 0 - 82
src/views/market/patentInfo/parts/list-1.vue

@@ -1,82 +0,0 @@
-<template>
-  <div id="list-1">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-col span="24" class="list" v-for="(item, index) in list" :key="index" @click.native="detail(item)">
-          <van-col span="24" class="title textOver">
-            {{ item.name }}
-          </van-col>
-          <van-col span="24" class="other">
-            <van-col span="24" class="otherInfo">
-              专利有效性:<span>{{ item.term || '暂无' }}</span>
-            </van-col>
-            <van-col span="24" class="otherInfo">
-              申请时间:<span>{{ item.create_date || '暂无' }}</span>
-            </van-col>
-          </van-col>
-        </van-col>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'list-1',
-  props: {
-    list: { type: Array },
-  },
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    detail(data) {
-      this.$emit('detail', data);
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  padding: 8px 8px 0 8px;
-  .list {
-    background-color: #fff;
-    margin: 0 0 8px 0;
-    padding: 8px;
-    border-radius: 5px;
-    .title {
-      font-size: 16px;
-      font-weight: bold;
-      margin: 0 0 5px 0;
-    }
-    .other {
-      margin: 0 0 5px 0;
-      .otherInfo {
-        font-size: 14px;
-        color: #666;
-        margin: 0 0 5px 0;
-        span {
-          color: #000;
-        }
-      }
-    }
-  }
-}
-</style>

+ 0 - 107
src/views/market/patentInfo/parts/search-1.vue

@@ -1,107 +0,0 @@
-<template>
-  <div id="search-1">
-    <van-row>
-      <van-col span="24" class="main">
-        <van-col :span="24" class="one">
-          <van-form>
-            <van-field v-model="searchForm.create_number" name="create_number" label="申请号" placeholder="请输入申请号" />
-            <van-field readonly clickable name="calendar" :value="searchForm.create_date" label="申请日" placeholder="点击选择" @click="changeCreate" />
-            <!-- <van-calendar v-model="oneShow" @confirm="oneChange" /> -->
-            <van-field v-model="searchForm.name" name="name" label="专利名称" placeholder="请输入专利名称" />
-            <van-field name="term" label="专利状态">
-              <template #input>
-                <van-radio-group v-model="searchForm.term" direction="horizontal">
-                  <van-radio name="有效">有效</van-radio>
-                  <van-radio name="审中">审中</van-radio>
-                </van-radio-group>
-              </template>
-            </van-field>
-            <!-- <van-field name="apply_type" label="申请类型">
-              <template #input>
-                <van-radio-group v-model="searchForm.apply_type" direction="horizontal">
-                  <van-radio name="1">发明专利</van-radio>
-                  <van-radio name="2">实用新型</van-radio>
-                  <van-radio name="3">外观设计</van-radio>
-                  <van-radio name="8">PCT发明</van-radio>
-                  <van-radio name="9">PCT实用新型</van-radio>
-                </van-radio-group>
-              </template>
-            </van-field> -->
-            <van-field name="type" label="专利类型">
-              <template #input>
-                <van-radio-group v-model="searchForm.type" direction="horizontal">
-                  <van-radio name="发明申请">发明申请</van-radio>
-                  <van-radio name="发明授权">发明授权</van-radio>
-                  <van-radio name="实用新型">实用新型</van-radio>
-                  <van-radio name="外观设计">外观设计</van-radio>
-                  <van-radio name="PCT国际申请号">PCT国际申请号</van-radio>
-                  <van-radio name="PCT国际公布号">PCT国际公布号</van-radio>
-                </van-radio-group>
-              </template>
-            </van-field>
-            <van-field v-model="searchForm.on_obligee" name="on_obligee" label="当前权利人" placeholder="请输入当前权利人" />
-            <div class="btn">
-              <van-button type="info" size="small" @click="reseat">重置条件</van-button>
-              <van-button type="primary" size="small" @click="onSubmit">提交查询</van-button>
-            </div>
-          </van-form>
-        </van-col>
-      </van-col>
-    </van-row>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'search-1',
-  props: {
-    searchForm: { type: Object },
-    oneShow: { type: Boolean },
-  },
-  components: {},
-  data: function () {
-    return {};
-  },
-  created() {},
-  methods: {
-    reseat() {
-      this.$emit('reseat');
-    },
-    onSubmit() {
-      this.$emit('onSubmit', { data: this.searchForm });
-    },
-    // 选择申请日
-    changeCreate() {
-      this.$emit('changeCreate');
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped>
-.main {
-  .one {
-    .btn {
-      text-align: center;
-      margin: 10px 0;
-      .van-button {
-        margin: 0 5px;
-      }
-    }
-  }
-}
-</style>

+ 0 - 63
src/views/market/transfer/detail.vue

@@ -1,63 +0,0 @@
-<template>
-  <div id="detail">
-    <admin-frame topType="2" @back="back" :rightArrow="false" :usePage="false" :useNav="false">
-      <template v-slot:info>
-        <info-1 :info="info"></info-1>
-      </template>
-    </admin-frame>
-  </div>
-</template>
-
-<script>
-import info1 from './parts/info-1.vue';
-import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
-import { mapState, createNamespacedHelpers } from 'vuex';
-const { mapActions: patenttrans } = createNamespacedHelpers('patenttrans');
-export default {
-  name: 'index',
-  props: {},
-  components: {
-    adminFrame,
-    info1,
-  },
-  data: function () {
-    return {
-      info: {},
-    };
-  },
-  async created() {
-    if (this.id) await this.search();
-  },
-  methods: {
-    ...patenttrans(['fetch']),
-    async search() {
-      let res = await this.fetch(this.id);
-      if (this.$checkRes(res)) {
-        this.$set(this, `info`, res.data);
-      }
-    },
-    // 返回
-    back() {
-      this.$router.push({ path: '/market/transfer/index' });
-    },
-  },
-  computed: {
-    ...mapState(['user']),
-    id() {
-      return this.$route.query.id;
-    },
-  },
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-  watch: {
-    test: {
-      deep: true,
-      immediate: true,
-      handler(val) {},
-    },
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 28 - 10
src/views/market/transfer/index.vue

@@ -4,19 +4,24 @@
       <template v-slot:info>
         <van-tabs v-model="active" @change="changeActive">
           <van-tab title="成交专利">
-            <list-1 :list="list" @detail="detail"></list-1>
+            <list-1 :list="list"></list-1>
           </van-tab>
           <van-tab title="转让信息">
-            <list-1 :list="list" @detail="detail"></list-1>
+            <list-2 :list="list" @toView="toView"></list-2>
           </van-tab>
         </van-tabs>
       </template>
     </admin-frame>
+    <van-dialog class="dialog" v-model="dialog.show" :title="dialog.title" :show-confirm-button="false" show-cancel-button>
+      <info-1 :info="info" v-if="dialog.type == '1'"></info-1>
+    </van-dialog>
   </div>
 </template>
 
 <script>
 import list1 from './parts/list-1.vue';
+import list2 from '@/layout/trans/list-2.vue';
+import info1 from '@/layout/trans/info-1.vue';
 import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
 import { mapState, createNamespacedHelpers } from 'vuex';
 const { mapActions: patenttrans } = createNamespacedHelpers('patenttrans');
@@ -26,6 +31,8 @@ export default {
   components: {
     adminFrame,
     list1,
+    list2,
+    info1,
   },
   data: function () {
     return {
@@ -34,6 +41,10 @@ export default {
       total: 0,
       // 转让信息
       list: [],
+      // 弹框
+      dialog: { show: false, title: '详细信息', type: '1' },
+      // 详细信息
+      info: {},
     };
   },
   async created() {
@@ -44,24 +55,24 @@ export default {
     async search({ skip = 0, limit = this.limit, searchName, ...info } = {}) {
       if (searchName) info.patent_name = searchName;
       if (this.active == 0) {
-        let res = await this.query({ skip, limit, status: '4', ...info });
+        let res = await this.query({ skip, limit, status: '5', ...info });
         if (this.$checkRes(res)) {
           this.$set(this, `list`, res.data);
           this.$set(this, `total`, res.total);
         }
       } else if (this.active == 1) {
-        let res = await this.query({ skip, limit, status: '0', ...info });
+        let res = await this.query({ skip, limit, status: '1', ...info });
         if (this.$checkRes(res)) {
           this.$set(this, `list`, res.data);
           this.$set(this, `total`, res.total);
         }
       }
     },
-    // 详情
-    detail(data) {
-      if (this.active == '1') {
-        this.$router.push({ path: '/market/transfer/detail', query: { id: data.id } });
-      }
+    // 查看详情
+    toView(data) {
+      this.$set(this, `info`, data);
+      let dialog = { show: true, title: '详细信息', type: '1' };
+      this.$set(this, `dialog`, dialog);
     },
     // 选择类型
     changeActive(value) {
@@ -85,4 +96,11 @@ export default {
 };
 </script>
 
-<style lang="less" scoped></style>
+<style lang="less" scoped>
+.dialog {
+  /deep/.van-dialog__content {
+    max-height: 350px;
+    overflow-y: auto;
+  }
+}
+</style>

+ 0 - 0
src/views/market/transfer/parts/info-1.vue


Alguns ficheiros não foram mostrados porque muitos ficheiros mudaram neste diff