瀏覽代碼

Merge branch 'master' into test-dev

duy 2 月之前
父節點
當前提交
182da2ca24
共有 2 個文件被更改,包括 38 次插入8 次删除
  1. 3 3
      src/config/index.json
  2. 35 5
      src/views/digital/signer.vue

+ 3 - 3
src/config/index.json

@@ -1,9 +1,9 @@
 {
   "target22": "http://39.108.216.210:8090",
-  "target7": "http://192.168.0.109:8090",
-  "target2": "http://192.168.0.101:8090",
+  "target1": "http://192.168.0.109:8090",
+  "target": "http://219.151.181.73:8090",
   "target3": "http://183.247.216.148:28090",
-  "target": "http://192.168.0.109:8090",
+  "target2": "http://192.168.0.109:8090",
   "dev": {
     "port": 1888
   }

+ 35 - 5
src/views/digital/signer.vue

@@ -53,6 +53,7 @@
                         </div>
                         <div class="table-box">
                             <el-table
+                            height="600"
                                 v-loading="tableLoading"
                                 ref="multipleTable"
                                 :data="tableData"
@@ -127,7 +128,7 @@
         <el-dialog
         class="dialog-footer-center"
             append-to-body
-            title="新增电签配置信息"
+            :title="addDialogVisibleTitle"
             :visible.sync="addDialogVisible"
             width="80%"
             :before-close="handleAddClose">
@@ -393,6 +394,7 @@
                 total: 0,
 
                 addDialogVisible: false,
+                addDialogVisibleTitle: '新增电签配置信息',
                 saveBatchLoading: false,
                 checkedList: [],
                 tableData1: [{}],
@@ -503,6 +505,8 @@
             //获取岗位列表
             getRoleData() {
                 this.roleListLoading = true;
+                this.selectedItem = {};
+
                 getRoleList({
                     type: this.tabPosition,
                     roleName: this.postText
@@ -517,6 +521,7 @@
                         this.roleData = [];
                     }
                 })
+                  this.getTableData();
             },
             positionClick(event, item){
                 this.selectedItem = item; 
@@ -531,8 +536,9 @@
                 getListPage({
                     size: this.pageSize,
                     current: this.currentPage,
-                    keyword: this.postText,
-                    roleId: this.selectedItem.roleId||''
+                    keyword: '',
+                    roleId: this.selectedItem.roleId||'',
+                    type: this.tabPosition
                 }).then(res => {
                     this.tableLoading = false;
                     if (res.data.code == 200) {
@@ -554,11 +560,13 @@
             },
             addEleClick() {
                 this.addDialogVisible = true;
+                this.addDialogVisibleTitle = '新增电签配置信息';
                 this.tableData1=[{}]
             },
             editEleClick(row) {
                 
                 this.addDialogVisible = true;
+                this.addDialogVisibleTitle = '编辑电签配置信息';
                 this.tableData1 = [...this.checkedList]
                 console.log( this.tableData1,' this.tableData1');
                 this.isPosView=false
@@ -649,14 +657,35 @@
             },
             handleDelete(row,index) {
                 console.log('删除', row);
-                if(this.tableData1.length==1){
+                if(this.tableData1.length==1&&this.addDialogVisibleTitle=='新增电签配置信息'){
                     this.$message({
                         type: "warning",
                         message: "请至少保留一条数据",
                     });
                     return;
                 }
-                this.tableData1.splice(index, 1);
+                if(this.addDialogVisibleTitle=='新增电签配置信息'){
+                     this.tableData1.splice(index, 1);
+                }else{
+                    let _that = this;
+                    let ids = row.id;
+                    this.$confirm("删除后,项目级表单电签信息将同步删除,请确认是否删除", "提示", {
+                        confirmButtonText: "确定",
+                        cancelButtonText: "取消",
+                        type: "warning",
+                    })
+                        .then(() => {
+                        _that.remove({ ids });
+                         _that.tableData1.splice(index, 1);
+                        })
+                        .catch(() => {
+                        this.$message({
+                            type: "info",
+                            message: "已取消删除",
+                        });
+                        })
+                }
+              
                 // 删除操作的逻辑
             },
             rowDel() {
@@ -679,6 +708,7 @@
                 })
                     .then(() => {
                     _that.remove({ ids });
+                     
                     })
                     .catch(() => {
                     this.$message({