shixr hai 1 ano
pai
achega
07c27ffbff

+ 28 - 8
src/api/index.js

@@ -56,12 +56,18 @@ export function findCooperatorListByName(name) {
     return request.get('/cooperator/findCooperatorListByName?name=' + name);
 }
 
-export function findCooperatorFieldByNum(Num) {
-    return request.get('/cooperator/findCooperatorFieldByNum?Num=' + Num);
+export function findCooperatorFieldByNum(cooperatorNum){
+    return request({
+        url: '/cooperator/findCooperatorFieldByNum/'+ cooperatorNum ,
+        method: 'get',
+      })  
 }
 
-export function findCooperatorProductByNum(Num) {
-    return request.get('/cooperator/findCooperatorProductByNum?Num=' + Num);
+export function findCooperatorProductByNum(cooperatorNum){
+    return request({
+        url: '/cooperator/findCooperatorProductByNum/'+ cooperatorNum ,
+        method: 'get',
+      })  
 }
 
 export function fieldTemplateList() {
@@ -71,11 +77,26 @@ export function fieldTemplateList() {
 export function cooperatorProductList(){
     return request.get('/cooperator_product/cooperatorProductList');
 }
-
-export function findCooperatorProductFieldByNum(Num){
-    return request.get('/cooperator_product/findCooperatorProductFieldByNum?Num=' + Num);
+export function findCooperatorProductFieldByNum(productNum){
+    return request({
+        url: '/cooperator_product/findCooperatorProductFieldByNum/'+ productNum,
+        method: 'get',
+      })
+}
+export function updateProductFieldNo(productNum,fieldNo){
+    return request({
+        url: '/cooperator_product/updateProductFieldNo/'+ productNum +'/'+ fieldNo,
+        method: 'get',
+      })  
+}
+export function findCooperatorFieldsByName(cooperatorName){
+    return request({
+        url: '/cooperator_product/findCooperatorFieldsByName/'+ cooperatorName ,
+        method: 'get',
+    })
 }
 
+
 export function modelDefineList(){
     return request.get('/model_define/modelDefineList');
 }
@@ -182,7 +203,6 @@ export function cooperatorEdit(cooperator_id, cooperator_name, corp_certificate_
     });
 }
 
-
 export function login(username, password) {
     return request.post('/login', {
         username: username,

+ 18 - 0
src/router/index.js

@@ -299,6 +299,24 @@ var routes = [{
                     show: true
                 }
             },
+            {
+                path: '/cooperatorProductFieldInfo',
+                name: '合作方产品字段信息',
+                component: () => import('../views/system/cooperatorProductFieldInfo.vue'),
+                meta: {
+                    keepAlive: false,
+                    show: true
+                }
+            },
+            {
+                path: '/cooperatorProductFieldModify',
+                name: '合作方产品字段信息修改',
+                component: () => import('../views/system/cooperatorProductFieldModify.vue'),
+                meta: {
+                    keepAlive: false,
+                    show: true
+                }
+            },
             
         ]
     },

+ 10 - 17
src/views/system/cooperatorDetailed.vue

@@ -43,12 +43,12 @@
                         <span>{{cooperatorName}}</span>
                         </el-form-item>
                       </el-col>
-
                       <el-col span="10">
-                        <el-form-item label="字段数量" width="100px">
-                          <span>{{fieldCount}}</span>
+                        <el-form-item label="合作方编号" width="100px">
+                        <span>{{cooperatorId}}</span>
                         </el-form-item>
                       </el-col>
+
                     </el-row>
                   </el-form>
                 </el-col>
@@ -59,17 +59,8 @@
                   <el-form  label-position="labelPosition" class="model_add_button" label-width="120px">
 
                     <el-row>
-                      <el-col span="10">
-                        <el-form-item label="合作方编号" width="100px">
-                        <span>{{cooperatorNum}}</span>
-                        </el-form-item>
-                      </el-col>
+                      
 
-                      <el-col span="10">
-                        <el-form-item label="模型数量" width="100px">
-                          <span>{{modelCount}}</span>
-                        </el-form-item>
-                      </el-col>
                     </el-row>
                   </el-form>
                 </el-col>
@@ -209,14 +200,12 @@ export default {
       activeKey: 0,
       activeName: "second",
       activeKey: 1,
-      activeName: "third",
+      activeName2: "first",
       currentPage: 1,
       // cooperatorName : this.$route.query.cooperatorName,
       cooperatorId : this.$route.query.cooperatorId,
       cooperatorName : this.$route.query.cooperatorName,
       cooperatorNum : this.$route.query.cooperatorNum,
-      fieldCount : this.$route.query.fieldCount,
-      modelCount : this.$route.query.modelCount,
       createTime : this.$route.query.createTime,
       cooperatorData : [],
       selected1: true,
@@ -308,7 +297,10 @@ export default {
       this.$router.push({
         path: '/cooperatorEdit',
         query: {
-          'cooperatorId' : this.cooperatorId
+          'cooperatorId' : this.cooperatorId,
+          'cooperatorNum' : this.cooperatorNum,
+          'cooperatorName' : this.cooperatorName,
+          'createTime' : this.createTime
         }
       })
     },
@@ -319,6 +311,7 @@ export default {
           'cooperatorId' : this.cooperatorId,
           'cooperatorNum' : this.cooperatorNum,
           'cooperatorName' : this.cooperatorName,
+          'createTime' : this.createTime
 
         }
       })

+ 10 - 4
src/views/system/cooperatorEdit.vue

@@ -48,8 +48,8 @@
 
               </el-form>
              
-              <el-button class="model_add_button " type="primary" @click="submit()">完成</el-button>
-              <el-button class="model_add_button " type="primary" @click="return_page()">返回</el-button>
+              <el-button class="model_add_button " round type="primary" @click="submit()">完成</el-button>
+              <el-button class="model_add_button " round type="danger" @click="return_page()">返回</el-button>
 
             </div>
           </el-main>
@@ -90,6 +90,9 @@ export default {
       cooperatorProduct : [],
       productStatus : "",
       arr: [{ name: '统一社会信用代码' }, { name: '组织机构代码' }, ],
+      cooperatorName : this.$route.query.cooperatorName,
+      cooperatorNum : this.$route.query.cooperatorNum,
+      createTime : this.$route.query.createTime,
       cooperator_name : "",
       corp_certificate_num : "",
       corp_certificate_type_name : "",
@@ -171,8 +174,11 @@ export default {
       this.$router.push({
         path: '/cooperatorDetailed',
         query: {
-          
-        }
+          cooperatorId : this.cooperatorId,
+          cooperatorName: this.cooperatorName,
+          cooperatorNum : this.cooperatorNum,
+          createTime : this.createTime
+        }// 要传递的参数
       })
     },
     submit (){

+ 21 - 32
src/views/system/cooperatorInfo.vue

@@ -29,44 +29,27 @@
 
           <el-main>
             <div class = "filter-container">
-              <el-input v-model="input" placeholder="产品名称/产品编号" style="width: 30%" size="small" clearable/>
+              <el-input v-model="input" placeholder="合作方名称" style="width: 30%" size="small" clearable/>
               <el-button type="primary" icon="el-icon-search" size="small" style="margin-left: 10px" @click="filterTable">查询</el-button>
-              <el-button type="primary" round @click="onButtonClickAdd" size="small" style="margin-left: 350px"
-              >新增</el-button
-              >
+              <el-button type="primary" round @click="onButtonClickAdd" size="small" style="margin-left: 350px">新增</el-button>
             </div>
 
             
-
-
-
-        
             <el-table :data="cooperatorData" style="width: 100%;" @row-click="onButtonClick">
-              <el-table-column align="center" label="合作方编号" width="150">
+              <el-table-column align="center" label="合作方编号" width="250">
                 <template v-slot="{row}">
-                  <span>{{ row.Id}}</span>
+                  <span>{{ row.id}}</span>
                 </template>
               </el-table-column>
 
-              <el-table-column align="center" label="合作方名称" width="150">
+              <el-table-column align="center" label="合作方名称" width="250">
                 <template v-slot="{row}">
                   <span>{{ row.cooperatorName}}</span>
                 </template>
               </el-table-column>
 
-              <el-table-column align="center" label="字段数量" width="150">
-                <template v-slot="{row}">
-                  <span>{{ row.fieldCount}}</span>
-                </template>
-              </el-table-column>
-
-              <el-table-column align="center" label="模型数量" width="150">
-                <template v-slot="{row}">
-                  <span>{{ row.modelCount}}</span>
-                </template>
-              </el-table-column>
-
-              <el-table-column align="center" label="创建时间" width="150">
+    
+              <el-table-column align="center" label="创建时间" width="250">
                 <template v-slot="{row}">
                   <span>{{ row.createTime}}</span>
                 </template>
@@ -101,7 +84,7 @@ export default {
   data() {
     return {
       activeKey: 0,
-      activeName: "second",
+      activeName: "third",
       currentPage: 1,
       cooperatorData : [],
       selected1: true,
@@ -136,6 +119,14 @@ export default {
     handleClick() {},
     handleCurrentChange() {},
     handleSizeChange() {},
+    async getTableData(){
+      try {
+        const { data } = await cooperatorList();
+        this.cooperatorData = data.cooperator_List;
+      } catch (error) {
+        console.error(error);
+      }
+    },
     gotolink1()
     {
       this.$router.replace('/cooperatorInfo');
@@ -185,11 +176,9 @@ export default {
       this.$router.push({
         path: '/cooperatorDetailed',
         query: {
-          cooperatorId : row.cooperatorId,
+          cooperatorId : row.id,
           cooperatorName: row.cooperatorName,
           cooperatorNum : row.cooperatorNum,
-          fieldCount : row.fieldCount,
-          modelCount : row.modelCount,
           createTime : row.createTime
         }// 要传递的参数
       })
@@ -202,9 +191,7 @@ export default {
         }
       })
     },
-
-  },
-  filterTable(){
+    filterTable(){
       if (this.input.trim() === '') {
         // 如果输入框为空,显示所有数据
         this.cooperatorData = this.getTableData();
@@ -218,7 +205,9 @@ export default {
         });
       }
     },
-  fillter: {},
+
+  },
+  
 }
 </script>
 

+ 17 - 9
src/views/system/cooperatorProductApply.vue

@@ -42,8 +42,8 @@
                   <el-input v-model="cooperator_product_name" style="width:200px"></el-input>
                 </el-form-item>
               </el-form>
-              <el-button class="model_add_button " type="primary" @click="paneNext1()">下一步</el-button>
-              <el-button class="model_add_button " type="primary" @click="paneClose1()">关闭</el-button>
+              <el-button class="model_add_button " round type="primary"  @click="paneNext1()">下一步</el-button>
+              <el-button class="model_add_button " round type="danger" style="margin-left: 50px" @click="paneClose1()">关闭</el-button>
             </div>
             </el-tab-pane>
 
@@ -75,8 +75,8 @@
 
             </el-table>
 
-              <el-button class="model_add_button " type="primary" @click="paneNext2()">下一步</el-button>
-              <el-button class="model_add_button " type="primary" @click="paneClose1()">关闭</el-button>
+              <el-button class="model_add_button " round type="primary" @click="paneNext2()">下一步</el-button>
+              <el-button class="model_add_button " round type="danger" style="margin-left: 50px" @click="paneClose1()">关闭</el-button>
 
             </el-tab-pane>
             <el-tab-pane label="合作方产品模型信息" name="third">
@@ -90,8 +90,8 @@
                   </select>
                 </el-form-item>
               </el-form>
-              <el-button class="model_add_button " type="primary" @click="submit()">完成</el-button>
-              <el-button class="model_add_button " type="primary" @click="paneClose1()">关闭</el-button>
+              <el-button class="model_add_button " round type="primary" @click="submit()">完成</el-button>
+              <el-button class="model_add_button " round type="danger" style="margin-left: 50px" @click="paneClose1()">关闭</el-button>
             
             </el-tab-pane>
             
@@ -133,6 +133,7 @@ export default {
       cooperatorName : this.$route.query.cooperatorName,
       cooperatorNum : this.$route.query.cooperatorNum,
       cooperatorId : this.$route.query.cooperatorId,
+      createTime : this.$route.query.createTime,
       cooperator_product_no : "",
       cooperator_product_name : "",
       cooperatorData : [],
@@ -238,7 +239,11 @@ export default {
       this.$router.push({
         path: '/cooperatorDetailed',
         query: {
-        }
+          cooperatorId : this.cooperatorId,
+          cooperatorName: this.cooperatorName,
+          cooperatorNum : this.cooperatorNum,
+          createTime : this.createTime
+        }// 要传递的参数
       })
     },
     submit()
@@ -249,8 +254,11 @@ export default {
             this.$router.push({
               path: '/cooperatorDetailed',
               query: {
-                
-              }
+                cooperatorId : this.cooperatorId,
+                cooperatorName: this.cooperatorName,
+                cooperatorNum : this.cooperatorNum,
+                createTime : this.createTime
+              }// 要传递的参数
             })
           },
         )

+ 275 - 0
src/views/system/cooperatorProductFieldInfo.vue

@@ -0,0 +1,275 @@
+<template>
+    <div class="container" style="min-height: 100%; padding-bottom: 100px;">
+  
+        <el-tabs v-model="activeName" @tab-click="handleClick"  stretch>
+            <el-tab-pane label="首页" name="first"  >首页</el-tab-pane>
+            <el-tab-pane label="业务" name="second">业务</el-tab-pane>
+            <el-tab-pane label="合作方" name="third">合作方</el-tab-pane>
+            <el-tab-pane label="字段列表" name="fourth">字段列表</el-tab-pane>
+            <el-tab-pane label="模型列表" name="fifth">模型列表</el-tab-pane>
+            <el-tab-pane label="管理" name="sixth">管理</el-tab-pane>
+    
+        </el-tabs>
+        <van-sidebar v-model="activeKey">
+            <van-sidebar-item title="标签名称"></van-sidebar-item>
+            <van-sidebar-item title="标签名称"></van-sidebar-item>
+            <van-sidebar-item title="标签名称"></van-sidebar-item>
+    
+        </van-sidebar>
+    
+        <el-container>
+            <el-aside width="250px">
+
+            <button @click="gotolink1" v-bind:class="{ button: selected1, buttonselected: selected2 }">待办任务</button>
+            <button @click="gotolink2" v-bind:class="{ button: selected3, buttonselected: selected4 }">合作方</button>
+            <button @click="gotolink3" v-bind:class="{ button: selected5, buttonselected: selected6 }">合作产品</button>
+
+            </el-aside>
+            <div class="line" />
+
+            <el-main>
+                <div class = "top-bar" >
+                    <el-tabs ref= "tabs" v-model="activeName2" @tab-click="handleClick2" >
+                    <el-tab-pane label="产品基础信息" name="first"  ></el-tab-pane>
+                    <el-tab-pane label="产品字段信息" name="second" ></el-tab-pane>
+                    </el-tabs>
+                    <el-button round ref="btn" type="primary" size="small" style="margin-left: 550px" @click="gotolink3" >返回</el-button>
+                </div>
+
+
+            
+                <el-table :data="cooperatorProductFieldData" style="width: 100%;">
+                    <el-table-column align="center" label="字段类型" width="160">
+                    <template v-slot="{row}">
+                        <span>{{ row.type}}</span>
+                    </template>
+                    </el-table-column>
+
+                    <el-table-column align="center" label="字段编号" width="160">
+                    <template v-slot="{row}">
+                        <span>{{ row.fieldNo}}</span>
+                    </template>
+                    </el-table-column>
+
+                    <el-table-column align="center" label="字段名称(中文)" width="160">
+                    <template v-slot="{row}">
+                        <span>{{ row.name}}</span>
+                    </template>
+                    </el-table-column>
+
+                    <el-table-column align="center" label="字段名称(英文)" width="160">
+                    <template v-slot="{row}">
+                        <span>{{ row.nameZH}}</span>
+                    </template>
+                    </el-table-column>
+
+                    <el-table-column align="center" label="加入日期" width="160">
+                    <template v-slot="{row}">
+                        <span>{{ row.createTime}}</span>
+                    </template>
+                    </el-table-column>
+                
+                
+                </el-table>
+                <div class = "bottom-bar" style="margin-top: 20px" >
+                    <el-button round type="primary" size="small"  @click="gotolink6" >修改</el-button>
+                    <el-button round type="danger" size="small"  style="margin-left: 50px" @click="gotolink3" >关闭</el-button>
+                </div>
+            </el-main>
+        </el-container>
+    </div>
+  </template>
+  
+  <script>
+  
+  import {
+    getList,
+    userInfo, partnerList, roleDel
+  } from '@/api/index.js'
+  import store from "@/store";
+  import request from '@/utils/request.js'
+  import { fieldInfo, modelInfo } from '../../api';
+  import {
+    findCooperatorProductFieldByNum
+  } from '@/api/index.js'
+  import { Row } from 'element-ui';
+  export default {
+  
+    name: "cooperatorProductFieldInfo",
+    props: [],
+    components: {},
+    data() {
+      return {
+        activeKey: 0,
+        activeName: "second",
+        activeName2: "second",
+        currentPage: 1,
+        cooperatorProductFieldData : [],
+        selected1: true,
+        selected2: false,
+        selected3: true,
+        selected4: false,
+        selected5: false,
+        selected6: true,
+        buttondisabled1: 'true',
+        buttondisabled2: 'false',
+      }
+    },
+    watch: {},
+    computed: {
+    },
+    beforeCreate() {},
+    created() {},
+    beforeMount() {},
+    mounted() 
+    {
+      this.getTableData();
+      const scrollBar = this.$refs.tabs.$el.querySelector('.el-tabs__nav-scroll');
+      scrollBar.appendChild(this.$refs.btn.$el);
+
+    },
+    beforeUpdate() {},
+    updated() {},
+    destroyed() {},
+    methods: {
+      async getTableData(){
+        try {
+          const { data } = await findCooperatorProductFieldByNum(this.$route.query.productNum);
+          this.cooperatorProductFieldData = data.cooperator_product_field;
+        } catch (error) {
+          console.error(error);
+        }
+      },
+      request() {},
+      handleClick1() {},
+      handleClick2(tab, event) {
+        if(tab.name=='first'){
+          this.gotolink4();
+        }
+        if(tab.name=='second'){
+          this.gotolink5();
+        }
+      },
+      handleCurrentChange() {},
+      handleSizeChange() {},
+      gotolink1()
+      {
+        this.$router.replace('/cooperatorProductInfo');
+        this.selected1 = false;
+        this.selected2 = true;
+        this.selected3 = true;
+        this.selected4 = false;
+        this.selected5 = true;
+        this.selected6 = false;
+      },
+      gotolink2()
+      {
+        //指定跳转地址
+        this.$router.push('/cooperatorInfo');
+        this.selected1 = true;
+        this.selected2 = false;
+        this.selected3 = false;
+        this.selected4 = true;
+        this.selected5 = true;
+        this.selected6 = false;
+      },
+      gotolink3()
+      {
+        //指定跳转地址
+        this.$router.replace('/cooperatorProductInfo');
+        this.selected1 = true;
+        this.selected2 = false;
+        this.selected3 = true;
+        this.selected4 = false;
+        this.selected5 = false;
+        this.selected6 = true;
+      },
+      gotolink4()
+      {
+        //指定跳转地址
+        this.$router.push({path:'/cooperatorProductInfoBase',query:{productNum:this.$route.query.productNum,productName:this.$route.query.productName,modelId:this.$route.query.modelId,cooperatorName:this.$route.query.cooperatorName}});
+        this.selected1 = true;
+        this.selected2 = false;
+        this.selected3 = true;
+        this.selected4 = false;
+        this.selected5 = false;
+        this.selected6 = true;
+      },
+      gotolink5()
+      {
+        //指定跳转地址
+        this.$router.push({path:'/cooperatorProductFieldInfo',query:{productNum:this.$route.query.productNum,productName:this.$route.query.productName,modelId:this.$route.query.modelId,cooperatorName:this.$route.query.cooperatorName}});
+        this.selected1 = true;
+        this.selected2 = false;
+        this.selected3 = true;
+        this.selected4 = false;
+        this.selected5 = false;
+        this.selected6 = true;
+      },
+      gotolink6(){
+        this.$router.push({path:'/cooperatorProductFieldModify',query:{productNum:this.$route.query.productNum,productName:this.$route.query.productName,modelId:this.$route.query.modelId,cooperatorName:this.$route.query.cooperatorName}});
+        this.selected1 = true;
+        this.selected2 = false;
+        this.selected3 = true;
+        this.selected4 = false;
+        this.selected5 = false;
+        this.selected6 = true;
+
+      }
+  
+    },
+
+  
+  }
+  </script>
+  
+  <style scoped>
+  /* 竖线 */
+  .line{
+    float: left;
+    width: 0.1em;
+    height: 19.5em;
+    margin-right: 1em;
+    margin-left: 0em;
+    background:#000000;
+  }
+  
+  .button {
+      background-color: white; 
+      border: none;
+      color: black;
+      padding: 15px 32px;
+      text-align: center;
+      text-decoration: none;
+      display: inline-block;
+      font-size: 16px;
+      width:180px;
+      height:50px;
+      font-weight: normal
+  }
+  
+  .buttonselected {
+      background-color: white; 
+      border: none;
+      color: black;
+      padding: 15px 32px;
+      text-align: center;
+      text-decoration: none;
+      display: inline-block;
+      font-size: 18px;
+      width:180px;
+      height:50px;
+      font-weight: 900
+  }
+  .bottom-bar{
+    display:flex;
+    align-items: center ;
+    justify-content: center;
+  }
+  .el-tabs__nav-scroll {
+  display: flex;
+  justify-content: space-between;
+}
+  /* .container {  } */
+</style>
+  

+ 292 - 0
src/views/system/cooperatorProductFieldModify.vue

@@ -0,0 +1,292 @@
+<template>
+    <div class="container" style="min-height: 100%; padding-bottom: 100px;">
+  
+        <el-tabs v-model="activeName" @tab-click="handleClick"  stretch>
+            <el-tab-pane label="首页" name="first"  >首页</el-tab-pane>
+            <el-tab-pane label="业务" name="second">业务</el-tab-pane>
+            <el-tab-pane label="合作方" name="third">合作方</el-tab-pane>
+            <el-tab-pane label="字段列表" name="fourth">字段列表</el-tab-pane>
+            <el-tab-pane label="模型列表" name="fifth">模型列表</el-tab-pane>
+            <el-tab-pane label="管理" name="sixth">管理</el-tab-pane>
+    
+        </el-tabs>
+        <van-sidebar v-model="activeKey">
+            <van-sidebar-item title="标签名称"></van-sidebar-item>
+            <van-sidebar-item title="标签名称"></van-sidebar-item>
+            <van-sidebar-item title="标签名称"></van-sidebar-item>
+    
+        </van-sidebar>
+    
+        <el-container>
+            <el-aside width="250px">
+
+            <button @click="gotolink1" v-bind:class="{ button: selected1, buttonselected: selected2 }">待办任务</button>
+            <button @click="gotolink2" v-bind:class="{ button: selected3, buttonselected: selected4 }">合作方</button>
+            <button @click="gotolink3" v-bind:class="{ button: selected5, buttonselected: selected6 }">合作产品</button>
+
+            </el-aside>
+            <div class="line" />
+
+            <el-main>
+                <div class = "top-bar" >
+                    <el-tabs ref= "tabs" v-model="activeName2" @tab-click="handleClick2" >
+                    <el-tab-pane label="产品基础信息" name="first"  ></el-tab-pane>
+                    <el-tab-pane label="产品字段信息" name="second" ></el-tab-pane>
+                    </el-tabs>
+                </div>
+
+
+            
+                <el-table :data="cooperatorFields" style="width: 100%;" ref="cooperatorFields" @row-click="singleElection" highlight-current-row>
+                    <el-table-column label="" width="65">
+                        <template slot-scope="scope">
+                            <el-radio class="radio" v-model="templateSelection" :label="scope.$index">&nbsp;</el-radio>
+                        </template>
+                    </el-table-column>
+
+                    <el-table-column align="center" label="字段类型" width="160">
+                    <template v-slot="{row}">
+                        <span>{{ row.type}}</span>
+                    </template>
+                    </el-table-column>
+
+                    <el-table-column align="center" label="字段编号" width="160">
+                    <template v-slot="{row}">
+                        <span>{{ row.fieldNo}}</span>
+                    </template>
+                    </el-table-column>
+
+                    <el-table-column align="center" label="字段名称(中文)" width="160">
+                    <template v-slot="{row}">
+                        <span>{{ row.name}}</span>
+                    </template>
+                    </el-table-column>
+
+                    <el-table-column align="center" label="字段名称(英文)" width="160">
+                    <template v-slot="{row}">
+                        <span>{{ row.nameZH}}</span>
+                    </template>
+                    </el-table-column>
+                
+                
+                </el-table>
+                <div class = "bottom-bar" style="margin-top: 20px" >
+                    <el-button round type="primary" size="small"  @click="gotolink6" >完成</el-button>
+                    <el-button round type="danger" size="small"  style="margin-left: 50px" @click="gotolink3" >关闭</el-button>
+                </div>
+            </el-main>
+        </el-container>
+    </div>
+  </template>
+  
+  <script>
+  
+  import {
+    getList,
+    userInfo, partnerList, roleDel
+  } from '@/api/index.js'
+  import store from "@/store";
+  import request from '@/utils/request.js'
+  import { fieldInfo, modelInfo } from '../../api';
+  import {
+    updateProductFieldNo,
+    findCooperatorFieldsByName
+  } from '@/api/index.js'
+  import { Row } from 'element-ui';
+  export default {
+  
+    name: "cooperatorProductFieldModify",
+    props: [],
+    components: {},
+    data() {
+      return {
+        activeKey: 0,
+        activeName: "second",
+        activeName2: "second",
+        currentPage: 1,
+        cooperatorFields : [
+            // {
+            //     type:'1',
+            //     fieldNo:'01',
+            //     name:'xxxx',
+            //     nameZH:'XXXX',
+            // },
+            // {
+            //     type:'2',
+            //     fieldNo:'02',
+            //     name:'xxxy',
+            //     nameZH:'XXXY',
+            // }
+        ],
+        selected1: true,
+        selected2: false,
+        selected3: true,
+        selected4: false,
+        selected5: false,
+        selected6: true,
+        buttondisabled1: 'true',
+        buttondisabled2: 'false',
+        templateSelection: '',
+        templateRadio: null,
+      }
+    },
+    watch: {},
+    computed: {
+    },
+    beforeCreate() {},
+    created() {},
+    beforeMount() {},
+    mounted() 
+    {
+        this.getTableData();
+    },
+    beforeUpdate() {},
+    updated() {},
+    destroyed() {},
+    methods: {
+      async getTableData(){
+        try {
+          const { data } = await findCooperatorFieldsByName(this.$route.query.cooperatorName);
+          this.cooperatorFields = data.cooperator_fields_by_name;
+        } catch (error) {
+          console.error(error);
+        }
+      },
+      singleElection(row) {
+        this.templateSelection = this.cooperatorFields.indexOf(row);
+        this.templateRadio = row.fieldNo;
+      },
+      request() {},
+      handleClick1() {},
+      handleClick2(tab, event) {
+        if(tab.name=='first'){
+          this.gotolink4();
+        }
+        if(tab.name=='second'){
+          this.gotolink5();
+        }
+      },
+      handleCurrentChange() {},
+      handleSizeChange() {},
+      gotolink1()
+      {
+        this.$router.replace('/cooperatorProductInfo');
+        this.selected1 = false;
+        this.selected2 = true;
+        this.selected3 = true;
+        this.selected4 = false;
+        this.selected5 = true;
+        this.selected6 = false;
+      },
+      gotolink2()
+      {
+        //指定跳转地址
+        this.$router.push('/partnerInfo');
+        this.selected1 = true;
+        this.selected2 = false;
+        this.selected3 = false;
+        this.selected4 = true;
+        this.selected5 = true;
+        this.selected6 = false;
+      },
+      gotolink3()
+      {
+        //指定跳转地址
+        this.$router.replace('/cooperatorProductInfo');
+        this.selected1 = true;
+        this.selected2 = false;
+        this.selected3 = true;
+        this.selected4 = false;
+        this.selected5 = false;
+        this.selected6 = true;
+      },
+      gotolink4()
+      {
+        //指定跳转地址
+        this.$router.push({path:'/cooperatorProductInfoBase',query:{productNum:this.$route.query.productNum,productName:this.$route.query.productName,modelId:this.$route.query.modelId,cooperatorName:this.$route.query.cooperatorName}});
+        this.selected1 = true;
+        this.selected2 = false;
+        this.selected3 = true;
+        this.selected4 = false;
+        this.selected5 = false;
+        this.selected6 = true;
+      },
+      gotolink5()
+      {
+        //指定跳转地址
+        this.$router.push({path:'/cooperatorProductFieldInfo',query:{productNum:this.$route.query.productNum,productName:this.$route.query.productName,modelId:this.$route.query.modelId,cooperatorName:this.$route.query.cooperatorName}});
+        this.selected1 = true;
+        this.selected2 = false;
+        this.selected3 = true;
+        this.selected4 = false;
+        this.selected5 = false;
+        this.selected6 = true;
+      },
+      async gotolink6(){
+        const { data } = await updateProductFieldNo(this.$route.query.productNum,this.templateRadio);
+        this.$router.push({path:'/cooperatorProductInfoBase',query:{productNum:this.$route.query.productNum,productName:this.$route.query.productName,modelId:this.$route.query.modelId,fieldNo:this.templateRadio}});
+        this.selected1 = true;
+        this.selected2 = false;
+        this.selected3 = true;
+        this.selected4 = false;
+        this.selected5 = false;
+        this.selected6 = true;
+
+      }
+  
+    },
+
+  
+  }
+  </script>
+  
+  <style scoped>
+  /* 竖线 */
+  .line{
+    float: left;
+    width: 0.1em;
+    height: 19.5em;
+    margin-right: 1em;
+    margin-left: 0em;
+    background:#000000;
+  }
+  
+  .button {
+      background-color: white; 
+      border: none;
+      color: black;
+      padding: 15px 32px;
+      text-align: center;
+      text-decoration: none;
+      display: inline-block;
+      font-size: 16px;
+      width:180px;
+      height:50px;
+      font-weight: normal
+  }
+  
+  .buttonselected {
+      background-color: white; 
+      border: none;
+      color: black;
+      padding: 15px 32px;
+      text-align: center;
+      text-decoration: none;
+      display: inline-block;
+      font-size: 18px;
+      width:180px;
+      height:50px;
+      font-weight: 900
+  }
+  .bottom-bar{
+    display:flex;
+    align-items: center ;
+    justify-content: center;
+  }
+  .el-tabs__nav-scroll {
+  display: flex;
+  justify-content: space-between;
+}
+  /* .container {  } */
+</style>
+  

+ 224 - 240
src/views/system/cooperatorProductInfo.vue

@@ -1,200 +1,189 @@
 <template>
-    <div class="container" style="min-height: 100%; padding-bottom: 100px;">
-  
-      <el-tabs v-model="activeName" @tab-click="handleClick"  stretch>
-        <el-tab-pane label="首页" name="first"  >首页</el-tab-pane>
-        <el-tab-pane label="业务" name="second">业务</el-tab-pane>
-        <el-tab-pane label="合作方" name="third">合作方</el-tab-pane>
-        <el-tab-pane label="字段列表" name="fourth">字段列表</el-tab-pane>
-        <el-tab-pane label="模型列表" name="fifth">模型列表</el-tab-pane>
-        <el-tab-pane label="管理" name="sixth">管理</el-tab-pane>
-  
-      </el-tabs>
-      <van-sidebar v-model="activeKey">
-        <van-sidebar-item title="标签名称"></van-sidebar-item>
-        <van-sidebar-item title="标签名称"></van-sidebar-item>
-        <van-sidebar-item title="标签名称"></van-sidebar-item>
-  
-      </van-sidebar>
-  
-          <el-container>
-            <el-aside width="250px">
-  
-              <button @click="gotolink1" v-bind:class="{ button: selected1, buttonselected: selected2 }">待办任务</button>
-              <button @click="gotolink2" v-bind:class="{ button: selected3, buttonselected: selected4 }">合作方</button>
-              <button @click="gotolink3" v-bind:class="{ button: selected5, buttonselected: selected6 }">合作产品</button>
-  
-            </el-aside>
-            <div class="line" />
-  
-            <el-main>
-              <div class = "filter-container">
-              <el-input v-model="input" placeholder="产品名称/产品编号" style="width: 30%" size="small" clearable/>
+  <div class="container" style="min-height: 100%; padding-bottom: 100px;">
+
+    <el-tabs v-model="activeName" @tab-click="handleClick"  stretch>
+      <el-tab-pane label="首页" name="first"  >首页</el-tab-pane>
+      <el-tab-pane label="业务" name="second">业务</el-tab-pane>
+      <el-tab-pane label="合作方" name="third">合作方</el-tab-pane>
+      <el-tab-pane label="字段列表" name="fourth">字段列表</el-tab-pane>
+      <el-tab-pane label="模型列表" name="fifth">模型列表</el-tab-pane>
+      <el-tab-pane label="管理" name="sixth">管理</el-tab-pane>
+
+    </el-tabs>
+    <van-sidebar v-model="activeKey">
+      <van-sidebar-item title="标签名称"></van-sidebar-item>
+      <van-sidebar-item title="标签名称"></van-sidebar-item>
+      <van-sidebar-item title="标签名称"></van-sidebar-item>
+
+    </van-sidebar>
+
+        <el-container>
+          <el-aside width="250px">
+
+            <button @click="gotolink1" v-bind:class="{ button: selected1, buttonselected: selected2 }">待办任务</button>
+            <button @click="gotolink2" v-bind:class="{ button: selected3, buttonselected: selected4 }">合作方</button>
+            <button @click="gotolink3" v-bind:class="{ button: selected5, buttonselected: selected6 }">合作产品</button>
+
+          </el-aside>
+          <div class="line" />
+
+          <el-main>
+            <div class = "filter-container">
+              <el-input v-model="input" placeholder="产品编号/产品名称/合作方名称" style="width: 30%" size="small" clearable/>
               <el-button type="primary" icon="el-icon-search" size="small" style="margin-left: 10px" @click="filterTable">查询</el-button>
             </div>
 
-  
-          
-              <el-table :data="cooperatorProductData" style="width: 100%;" @row-click="gotolink4">
-                <el-table-column align="center" label="产品编号" width="160">
-                  <template v-slot="{row}">
-                    <span>{{ row.productNum}}</span>
-                  </template>
-                </el-table-column>
-  
-                <el-table-column align="center" label="产品名称" width="160">
-                  <template v-slot="{row}">
-                    <span>{{ row.productName}}</span>
-                  </template>
-                </el-table-column>
-  
-                <el-table-column align="center" label="产品状态" width="80">
-                  <template v-slot="{row}">
-                    <span>{{ row.productStatus}}</span>
-                  </template>
-                </el-table-column>
-  
-                <el-table-column align="center" label="合作方名称" width="160">
-                  <template v-slot="{row}">
-                    <span>{{ row.cooperatorName}}</span>
-                  </template>
-                </el-table-column>
-  
-                <el-table-column align="center" label="对应模型" width="80">
-                  <template v-slot="{row}">
-                    <span>{{ row.modelName}}</span>
-                  </template>
-                </el-table-column>
-  
-                <el-table-column align="center" label="创建日期" width="160">
-                  <template v-slot="{row}">
-                    <span>{{ row.createTime}}</span>
-                  </template>
-                </el-table-column>
-              
-              
-              </el-table>
-  
-              
-            </el-main>
-          </el-container>
-    </div>
-  </template>
-  
-  <script>
-  
-  import {
-    getList,
-    userInfo, partnerList, roleDel
-  } from '@/api/index.js'
-  import store from "@/store";
-  import request from '@/utils/request.js'
-  import { fieldInfo, modelInfo } from '../../api';
-  import {
-    cooperatorProductList
-  } from '@/api/index.js'
+        
+            <el-table :data="cooperatorProductData" style="width: 100%;" @row-click="gotolink4">
+              <el-table-column align="center" label="产品编号" width="160">
+                <template v-slot="{row}">
+                  <span>{{ row.productNum}}</span>
+                </template>
+              </el-table-column>
+
+              <el-table-column align="center" label="产品名称" width="160">
+                <template v-slot="{row}">
+                  <span>{{ row.productName}}</span>
+                </template>
+              </el-table-column>
+
+              <el-table-column align="center" label="产品状态" width="80">
+                <template v-slot="{row}">
+                  <span>{{ row.productStatus}}</span>
+                </template>
+              </el-table-column>
+
+              <el-table-column align="center" label="合作方名称" width="160">
+                <template v-slot="{row}">
+                  <span>{{ row.cooperatorName}}</span>
+                </template>
+              </el-table-column>
+
+              <el-table-column align="center" label="对应模型" width="80">
+                <template v-slot="{row}">
+                  <span>{{ row.modelName}}</span>
+                </template>
+              </el-table-column>
+
+              <el-table-column align="center" label="创建日期" width="160">
+                <template v-slot="{row}">
+                  <span>{{ row.createTime}}</span>
+                </template>
+              </el-table-column>
+            
+            
+            </el-table>
+
+            
+          </el-main>
+        </el-container>
+  </div>
+</template>
+
+<script>
+
+import {
+  getList,
+  userInfo, partnerList, roleDel
+} from '@/api/index.js'
+import store from "@/store";
+import request from '@/utils/request.js'
+import { fieldInfo, modelInfo } from '../../api';
+import {
+  cooperatorProductList
+} from '@/api/index.js'
 import { Row } from 'element-ui';
-  export default {
-  
-    name: "cooperatorProductInfo",
-    props: [],
-    components: {},
-    data() {
-      return {
-        activeKey: 0,
-        activeName: "second",
-        currentPage: 1,
-        cooperatorProductData : [],
-        selected1: true,
-        selected2: false,
-        selected3: true,
-        selected4: false,
-        selected5: false,
-        selected6: true,
-        input:'',
+export default {
+
+  name: "cooperatorProductInfo",
+  props: [],
+  components: {},
+  data() {
+    return {
+      activeKey: 0,
+      activeName: "third",
+      currentPage: 1,
+      cooperatorProductData : [],
+      selected1: true,
+      selected2: false,
+      selected3: true,
+      selected4: false,
+      selected5: false,
+      selected6: true,
+      input:'',
+    }
+  },
+  watch: {},
+  computed: {
+  },
+  beforeCreate() {},
+  created() {},
+  beforeMount() {},
+  mounted() 
+  {
+    this.getTableData();
+  },
+  beforeUpdate() {},
+  updated() {},
+  destroyed() {},
+  methods: {
+    async getTableData(){
+      try {
+        const { data } = await cooperatorProductList();
+        this.cooperatorProductData = data.cooperator_Product_List;
+      } catch (error) {
+        console.error(error);
       }
     },
-    watch: {},
-    computed: {},
-    beforeCreate() {},
-    created() {},
-    beforeMount() {},
-    mounted() 
+    request() {},
+    handleClick() {},
+    handleCurrentChange() {},
+    handleSizeChange() {},
+    gotolink1()
+    {
+      this.$router.replace('/cooperatorProductInfo');
+      this.selected1 = false;
+      this.selected2 = true;
+      this.selected3 = true;
+      this.selected4 = false;
+      this.selected5 = true;
+      this.selected6 = false;
+    },
+    gotolink2()
+    {
+      //指定跳转地址
+      this.$router.push('/cooperatorInfo');
+      this.selected1 = true;
+      this.selected2 = false;
+      this.selected3 = false;
+      this.selected4 = true;
+      this.selected5 = true;
+      this.selected6 = false;
+    },
+    gotolink3()
+    {
+      //指定跳转地址
+      this.$router.replace('/cooperatorProductInfo');
+      this.selected1 = true;
+      this.selected2 = false;
+      this.selected3 = true;
+      this.selected4 = false;
+      this.selected5 = false;
+      this.selected6 = true;
+    },
+    gotolink4(row)
     {
-      cooperatorProductList().then(
-          res=>
-          {
-            this.cooperatorProductData=res.data.cooperator_Product_List;
-            // console.log(this.fieldData)
-          }
-      )
+      //指定跳转地址
+      this.$router.push({path:'/cooperatorProductInfoBase',query:{productNum:row.productNum,productName:row.productName,modelName:row.modelName,cooperatorName:row.cooperatorName}});
+      this.selected1 = true;
+      this.selected2 = false;
+      this.selected3 = false;
+      this.selected4 = true;
+      this.selected5 = true;
+      this.selected6 = false;
     },
-    beforeUpdate() {},
-    updated() {},
-    destroyed() {},
-    methods: {
-      request() {},
-      handleClick() {},
-      handleCurrentChange() {},
-      handleSizeChange() {},
-      gotolink1()
-      {
-        this.$router.replace('/cooperatorProductInfo');
-        this.selected1 = false;
-        this.selected2 = true;
-        this.selected3 = true;
-        this.selected4 = false;
-        this.selected5 = true;
-        this.selected6 = false;
-      },
-      gotolink2()
-      {
-        //指定跳转地址
-        this.$router.push('/cooperatorInfo');
-        this.selected1 = true;
-        this.selected2 = false;
-        this.selected3 = false;
-        this.selected4 = true;
-        this.selected5 = true;
-        this.selected6 = false;
-      },
-      gotolink3()
-      {
-        //指定跳转地址
-        this.$router.replace('/cooperatorProductInfo');
-        this.selected1 = true;
-        this.selected2 = false;
-        this.selected3 = true;
-        this.selected4 = false;
-        this.selected5 = false;
-        this.selected6 = true;
-      },
-      gotolink4(row)
-      {
-        //指定跳转地址
-        this.$router.push({path:'/cooperatorProductInfoBase',query:{productNum:row.productNum,productName:row.productName,modelName:row.modelName}});
-        this.selected1 = true;
-        this.selected2 = false;
-        this.selected3 = false;
-        this.selected4 = true;
-        this.selected5 = true;
-        this.selected6 = false;
-      },
-      tables:function () { //在你的数据表格中定义tabels
-        const input = this.input
-        if (input) {
-          // console.log("input输入的搜索内容:" + this.input)
-          return this.cooperatorProductData.filter(data => {
-            console.log("object:" + Object.keys(data))
-            return Object.keys(data).some(key => {
-              return String(data[key]).indexOf(input) > -1
-            })
-          })
-        }
-        return this.cooperatorProductData
-      },
-      filterTable(){
-      if (this.input.trim() == "") {
+    filterTable(){
+      if (this.input.trim() === '') {
         // 如果输入框为空,显示所有数据
         this.cooperatorProductData = this.getTableData();
       } else {
@@ -207,55 +196,50 @@ import { Row } from 'element-ui';
         });
       }
     },
-  
-    },
-    tableFilter(){
-        
-    },
-    fillter: {},
-  }
-  </script>
-  
-  <style scoped>
-  /* 竖线 */
-  .line{
-    float: left;
-    width: 0.1em;
-    height: 19.5em;
-    margin-right: 1em;
-    margin-left: 0em;
-    background:#000000;
-  }
-  
-  .button {
-      background-color: white; 
-      border: none;
-      color: black;
-      padding: 15px 32px;
-      text-align: center;
-      text-decoration: none;
-      display: inline-block;
-      font-size: 16px;
-      width:180px;
-      height:50px;
-      font-weight: normal
-  }
-  
-  .buttonselected {
-      background-color: white; 
-      border: none;
-      color: black;
-      padding: 15px 32px;
-      text-align: center;
-      text-decoration: none;
-      display: inline-block;
-      font-size: 18px;
-      width:180px;
-      height:50px;
-      font-weight: 900
-  }
-  
-  
-  .container {  }
-  </style>
-  
+  },
+
+}
+</script>
+
+<style scoped>
+/* 竖线 */
+.line{
+  float: left;
+  width: 0.1em;
+  height: 19.5em;
+  margin-right: 1em;
+  margin-left: 0em;
+  background:#000000;
+}
+
+.button {
+    background-color: white; 
+    border: none;
+    color: black;
+    padding: 15px 32px;
+    text-align: center;
+    text-decoration: none;
+    display: inline-block;
+    font-size: 16px;
+    width:180px;
+    height:50px;
+    font-weight: normal
+}
+
+.buttonselected {
+    background-color: white; 
+    border: none;
+    color: black;
+    padding: 15px 32px;
+    text-align: center;
+    text-decoration: none;
+    display: inline-block;
+    font-size: 18px;
+    width:180px;
+    height:50px;
+    font-weight: 900
+}
+
+
+.container {  }
+</style>

+ 27 - 12
src/views/system/cooperatorProductInfoBase.vue

@@ -1,7 +1,7 @@
 <template>
     <div class="container" style="min-height: 100%; padding-bottom: 100px;">
   
-      <el-tabs v-model="activeName" @tab-click="handleClick"  stretch>
+      <el-tabs v-model="activeName1" @tab-click="handleClick1"  stretch>
         <el-tab-pane label="首页" name="first"  >首页</el-tab-pane>
         <el-tab-pane label="业务" name="second">业务</el-tab-pane>
         <el-tab-pane label="合作方" name="third">合作方</el-tab-pane>
@@ -29,9 +29,11 @@
   
             <el-main>
                 <div class = "top-bar" >
-                    <el-button round type="primary" size="small" style="margin-left: 10px" @click="gotolink4" >产品基础信息</el-button>
-                    <el-button round type="primary" size="small" style="margin-left: 20px" @click="gotolink5" >产品字段信息</el-button>
-                    <el-button round type="primary" size="small" style="margin-left: 500px" @click="gotolink3" >返回</el-button>
+                  <el-tabs ref= "tabs" v-model="activeName2" @tab-click="handleClick2" >
+                    <el-tab-pane label="产品基础信息" name="first"  ></el-tab-pane>
+                    <el-tab-pane label="产品字段信息" name="second" ></el-tab-pane>
+                  </el-tabs>
+                  <el-button round ref="btn" type="primary" size="small" style="margin-left: 550px" @click="gotolink3" >返回</el-button>
                 </div>
                 
                 <el-descriptions style="margin-top: 20px" direction="vertical" :column="1" border>
@@ -53,7 +55,7 @@
                     
                 </el-descriptions>
                 <div class = "bottom-bar" style="margin-top: 20px" >
-                    <el-button round type="success" size="small" style="margin-left:auto" @click="gotolink3" >完成</el-button>
+                    <el-button round type="success" size="small" style="margin-left:auto" @click="gotolink2" >完成</el-button>
                 </div>
               
             </el-main>
@@ -82,7 +84,8 @@ import { Row } from 'element-ui';
     data() {
       return {
         activeKey: 0,
-        activeName: "second",
+        activeName1: "second",
+        activeName2: "first",
         currentPage: 1,
         selected1: true,
         selected2: false,
@@ -102,14 +105,23 @@ import { Row } from 'element-ui';
     beforeMount() {},
     mounted() 
     {
-
+      const scrollBar = this.$refs.tabs.$el.querySelector('.el-tabs__nav-scroll')
+      scrollBar.appendChild(this.$refs.btn.$el)
     },
     beforeUpdate() {},
     updated() {},
     destroyed() {},
     methods: {
       request() {},
-      handleClick() {},
+      handleClick1() {},
+      handleClick2(tab, event) {
+        if(tab.name=='first'){
+          this.gotolink4();
+        }
+        if(tab.name=='second'){
+          this.gotolink5();
+        }
+      },
       handleCurrentChange() {},
       handleSizeChange() {},
       gotolink1()
@@ -125,7 +137,7 @@ import { Row } from 'element-ui';
       gotolink2()
       {
         //指定跳转地址
-        this.$router.push('/cooperatorInfo');
+        this.$router.push('/cooperatorProductInfo');
         this.selected1 = true;
         this.selected2 = false;
         this.selected3 = false;
@@ -147,7 +159,7 @@ import { Row } from 'element-ui';
       gotolink4()
       {
         //指定跳转地址
-        this.$router.push({path:'/cooperatorProductInfoBase',query:{productNum:this.$route.query.productNum,productName:this.$route.query.productName,modelId:this.$route.query.modelId}});
+        this.$router.push({path:'/cooperatorProductInfoBase',query:{productNum:this.$route.query.productNum,productName:this.$route.query.productName,modelName:this.$route.query.modelName,cooperatorName:this.$route.query.cooperatorName}});
         this.selected1 = true;
         this.selected2 = false;
         this.selected3 = true;
@@ -158,7 +170,7 @@ import { Row } from 'element-ui';
       gotolink5()
       {
         //指定跳转地址
-        this.$router.push({path:'/cooperatorProductInfoBase',query:{productNum:this.$route.query.productNum,productName:this.$route.query.productName,modelId:this.$route.query.modelId}});
+        this.$router.push({path:'/cooperatorProductFieldInfo',query:{productNum:this.$route.query.productNum,productName:this.$route.query.productName,modelName:this.$route.query.modelName,cooperatorName:this.$route.query.cooperatorName}});
         this.selected1 = true;
         this.selected2 = false;
         this.selected3 = true;
@@ -224,7 +236,10 @@ import { Row } from 'element-ui';
       font-weight: 900
   }
   
-  
+  .el-tabs__nav-scroll {
+  display: flex;
+  justify-content: space-between;
+}
   .container {  }
   </style>