fan 2 лет назад
Родитель
Сommit
ee6a7eaa84

+ 22 - 18
src/pages/main/incomeExcel/home.vue

@@ -1,23 +1,14 @@
 <template>
     <div class="inner-container">
-        <el-col :span="3">
-            <el-tabs
-                tab-position="left"
-                v-model="activeName"
-                @tab-click="handleClick">
-                <el-tab-pane
-                    v-for="(item, index) in routerList"
-                    :key="index"
-                    :name="item.path"
-                    :label="item.label">
+        <div class="tabBox">
+            <el-tabs tab-position="left" v-model="activeName" @tab-click="handleClick">
+                <el-tab-pane v-for="(item, index) in routerList" :key="index" :name="item.path" :label="item.label">
                 </el-tab-pane>
             </el-tabs>
-        </el-col>
-        <el-col :span="21" style="background: #f4f4f4;">
-            <div style="height: 100%">
-                <router-view/>
-            </div>
-        </el-col>
+        </div>
+        <div class="infoBox">
+            <router-view />
+        </div>
     </div>
 </template>
 <script>
@@ -30,12 +21,12 @@ export default {
                 {label: "收入模板管理", path: "/incomeExcelTemplate", name: "incomeExcelTemplate"},
                 {label: "收入信息收集", path: "/incomeExcelIssued", name: "incomeExcelIssued"},
                 {label: "收入信息发布", path: "/incomeExcelView", name: "incomeExcelView"},
-                {label: "收入附件收集", path: "/incomeExcelAppendix", name: "incomeExcelAppendix"},
+                {label: "收入附件收集", path: "/incomeExcelAppendix", name: "incomeExcelAppendix"}
             ],
         };
     },
     computed: {
-        menuList: function () {
+        menuList: function() {
             let arr = [];
             this.routerList.map((item) => {
                 this.showList.map((row) => {
@@ -50,6 +41,7 @@ export default {
     methods: {
         handleClick(val) {
             if (this.$route.path != this.activeName) {
+                console.log(this.activeName);
                 this.$router.push(this.activeName);
             }
         },
@@ -73,4 +65,16 @@ export default {
 .el-tabs__content {
     display: none;
 }
+.inner-container{
+    display: flex;
+    justify-content: space-between;
+}
+.tabBox{
+    width: 135px;
+}
+.infoBox{
+    background: #f4f4f4!important;
+    height: 100%;
+    width: calc(100% - 135px)
+}
 </style>

+ 1 - 0
src/pages/main/incomeExcel/incomeExcelAppendix.vue

@@ -464,6 +464,7 @@ export default {
                         type: 'success'
                     });
                     this.addDialogStatus = false;
+                    this.appendixUserDialog = false;
                     this.getList({}, 1);
                 }
             });

+ 22 - 8
src/pages/main/incomeExcel/incomeExcelInfo.vue

@@ -225,7 +225,13 @@ export default {
                         message: '处理成功',
                         type: 'success'
                     });
+                    //没找到关闭标签页之前的临时处理措施
+                    const newUrl = '#' + this.$route.path + '?type=4&id=' + this.getUrlKey("id");
+                    console.log(newUrl);
+                    window.history.replaceState('', '', newUrl);
+                    document.getElementById('excelIframe').contentWindow.location.reload();
                     //关闭这个窗口,得找找怎么关闭
+                    //this.$router.go(-1);
                 }
             });
 
@@ -301,6 +307,8 @@ export default {
                         this.type = '2';
                         document.getElementById('excelIframe').contentWindow.location.reload();
                     }
+                    //this.$store.dispatch('tagsView/delView',this.$route)
+                    //this.$router.go(-1);
                 }
             });
         },
@@ -352,16 +360,22 @@ export default {
         addNewLimitAuth() {
             var _this = this;
             if (this.authType == '2') {
-                var lastLimitUserList = _this.limitList[_this.limitList.length - 1].userIds;
-                if (lastLimitUserList == null) {
-                    _this.$message({
-                        message: '请先选择上一条记录的负责人',
-                        type: 'error'
-                    });
-                } else {
+                if (_this.limitList.length == 0) {
                     _this.limitList.push({
                         index: 1
                     });
+                } else {
+                    var lastLimitUserList = _this.limitList[_this.limitList.length - 1].userIds;
+                    if (lastLimitUserList == null) {
+                        _this.$message({
+                            message: '请先选择上一条记录的负责人',
+                            type: 'error'
+                        });
+                    } else {
+                        _this.limitList.push({
+                            index: 1
+                        });
+                    }
                 }
             } else {
                 _this.$message({
@@ -437,7 +451,7 @@ export default {
                     var i = -1;
                     var nowStart = '';
                     var nowEnd = '';
-                    this.limitList = [{}];
+                    this.limitList = [];
                     this.noLimitUsers = [];
                     this.noLimitUserName = '';
                     authUsers.map((o) => {

+ 76 - 10
src/pages/main/incomeExcel/incomeExcelIssued.vue

@@ -21,9 +21,11 @@
                     <el-table-column label="接收人" align="center">
                         <template slot-scope="scope">
                             <span v-if="scope.row.userList == null"
-                                  style="color: #0b82ff;cursor: pointer">{{ scope.row.userName }}</span>
+                                  style="color: #0b82ff;cursor: pointer"
+                                  @click="processIssuedLog(scope.row.id)">{{ scope.row.userName }}</span>
                             <div v-else v-for="item in scope.row.userList">
-                                <span style="color: #0b82ff;cursor: pointer">{{ item.userName }}&nbsp;</span>
+                                <span style="color: #0b82ff;cursor: pointer"
+                                      @click="processIssuedLog(item.id)">{{ item.userName }}&nbsp;</span>
                             </div>
                         </template>
                     </el-table-column>
@@ -108,6 +110,32 @@
                     </div>
                 </div>
             </el-dialog>
+
+            <el-dialog title="回复详情" :visible.sync="issuedLogStatus" width="70%" :close-on-press-escape="false"
+                       :show-close="true" :before-close="closeIssuedLog" :destroy-on-close="true"
+                       :modal-append-to-body="false"
+                       :close-on-click-modal="false" :fullscreen="true">
+                <div class="tabbox" style="height: 500px">
+                    <el-table height="calc(100% - 50px)" class="com-table" ref="multipleTable"
+                              :data="issuedLogData"
+                              tooltip-effect="dark" size="small" border style="width: 100%" v-loading="loading">
+                        <el-table-column prop="beforeUserName" label="接收人">
+                        </el-table-column>
+                        <el-table-column prop="beforeUserDept" label="部门">
+                        </el-table-column>
+                        <el-table-column prop="opTime" label="回复时间">
+                        </el-table-column>
+                        <el-table-column prop="remark" label="审批记录">
+                        </el-table-column>
+                        <el-table-column prop="status" label="审批意见">
+                        </el-table-column>
+                    </el-table>
+                    <el-pagination class="pageBox" @current-change="issuedLogChange"
+                                   layout="prev, pager, next" background
+                                   :total="issuedLogTotal">
+                    </el-pagination>
+                </div>
+            </el-dialog>
         </div>
     </fullscreen>
 </template>
@@ -170,7 +198,7 @@ export default {
                     }
                 ]
             },],
-            nowUserId:'',
+            nowUserId: '',
             auditBoxList: [{}],
             authDialog: false,
             auditForm: {},
@@ -182,18 +210,56 @@ export default {
             treeListonly: {},
             excelData: {},
             fullscreen: false,
-            defaultList:[],
-            addInfoList:[],
-            closeList:[],
-            depttype:'',
+            defaultList: [],
+            addInfoList: [],
+            closeList: [],
+            depttype: '',
+            issuedLogStatus: false,
+            issuedLogData: [],
+            issuedLogPageSize: 1,
+            issuedLogParams: {},
+            issuedLogTotal: 0,
         }
     },
     methods: {
+        processIssuedLog(row) {
+            this.issuedLogParams = {
+                issuedUserId: row
+            };
+            console.log(this.issuedLogParams);
+            this.getIssuedLog(this.issuedLogParams, this.issuedLogPageSize);
+            this.issuedLogStatus = true;
+        },
+        getIssuedLog(v, n) {
+            this.issuedLogPageSize = n;
+            this.loading = true;
+            this.issuedLogData = [];
+            this.$http({
+                url: "/market/cIncomeExcelIssued/getIssuedLog",
+                method: "post",
+                headers: {
+                    "Content-Type": "application/json",
+                    "page": '{"pageNo":"' + n + '","pageSize":"10"}'
+                },
+                data: v,
+            }).then((res) => {
+                this.issuedLogData = res.data.data;
+                this.issuedLogTotal = res.data.totalRecord;
+                this.loading = false;
+            });
+        },
+        issuedLogChange(v) {
+            this.issuedLogPageSize = v;
+            this.getIssuedLog(this.issuedLogParams, this.issuedLogPageSize);
+        },
+        closeIssuedLog() {
+            this.issuedLogStatus = false;
+        },
         //搜索数据
         searchInfo(v) {
             this.params = {};
             v[0] ? this.params.templateName = v[0] : '';
-            v[1] ? this.params.endTime = this.$formatDate(v[1] , "YYYY-MM-DD")  : '';
+            v[1] ? this.params.endTime = this.$formatDate(v[1], "YYYY-MM-DD") : '';
             v[2] ? this.params.state = v[2] : '';
             this.getList(this.params, this.pageSize);
         },
@@ -290,10 +356,10 @@ export default {
                     "Content-Type": "application/json",
                 },
                 data: {
-                    issuedUserId:this.nowUserId,
+                    issuedUserId: this.nowUserId,
                     type: this.auditForm.authType,
                     nextUserId: this.auditUserId,
-                    auditRemark:this.auditForm.auditRemark
+                    auditRemark: this.auditForm.auditRemark
                 },
             }).then((res) => {
                 this.loading = false;

+ 42 - 14
src/pages/main/incomeExcel/incomeExcelTemplate.vue

@@ -36,7 +36,7 @@
                             <el-button size="mini" type="primary" @click="addNewIssued(scope.row)">下发</el-button>
                             <el-button size="mini" @click="toEdit(scope.row)">编辑</el-button>
                             <el-button size="mini" @click="toView(scope.row)">查看</el-button>
-                            <el-button size="mini">删除</el-button>
+                            <el-button size="mini" @click="checkDelete(scope.row)">删除</el-button>
                         </template>
                     </el-table-column>
                 </el-table>
@@ -74,22 +74,22 @@
                 </div>
             </el-dialog>
         </div>
-        <myMessage :deleteTag='deleteTag' @closeMessage="processDelete" :centerDialogVisible="centerDialogVisible"
-                   v-if="centerDialogVisible"></myMessage>
+        <myMessageNew :messTit='deleteTag' @closeMessage="processDelete" :centerDialogVisible="centerDialogVisible"
+                      v-if="centerDialogVisible" yes-btn-name="是" no-btn-name="否"></myMessageNew>
     </fullscreen>
 </template>
 <script>
 import mySearch from "../../../components/search.vue";
 import myUpload from "../../../components/upload";
 import toolList from "../../../components/toolList";
-import myMessage from "../../../components/myMessage.vue"
+import myMessageNew from "../../../components/myMessageNew.vue"
 
 export default {
     components: {
         myUpload,
         mySearch,
         toolList,
-        myMessage
+        myMessageNew
     },
     data() {
         return {
@@ -101,8 +101,8 @@ export default {
             loading: false,
             issuedAddStatus: false,
             issuedParam: {},
-            pickerOptions:{
-                disabledDate(time){
+            pickerOptions: {
+                disabledDate(time) {
                     return time.getTime() < Date.now();
                 }
             },
@@ -118,9 +118,43 @@ export default {
                 value: '',
                 width: '48%',
             },],
+            delTemplateId: '',
+            fullscreen: false
         }
     },
     methods: {
+        checkDelete(row) {
+            this.deleteTag = '确认删除吗?';
+            this.centerDialogVisible = true;
+            this.delTemplateId = row.id;
+        },
+        processDelete(v) {
+            this.centerDialogVisible = false;
+            var _this = this;
+            if (v === 1) {
+                this.$http({
+                    url: "/market/cIncomeExcelTemplate/deleteTemplate",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                    },
+                    data: {excelId: this.delTemplateId},
+                }).then((res) => {
+                    if (res.data.result === 1) {
+                        _this.$message({
+                            message: '删除失败',
+                            type: 'error'
+                        });
+                    } else {
+                        _this.$message({
+                            message: '删除成功',
+                            type: 'success'
+                        });
+                        _this.getList({}, _this.pageSize);
+                    }
+                });
+            }
+        },
         //搜索数据
         searchInfo(v) {
             this.params = {};
@@ -161,12 +195,6 @@ export default {
                 this.loading = false;
             });
         },
-        processDelete(v) {
-            this.centerDialogVisible = false;
-            if (v === 1) {
-                console.log("删除")
-            }
-        },
         addNew() {
             var _this = this;
             _this.jumpinfop('/incomeExcelInfo', 1, '新增模板', "")
@@ -181,7 +209,7 @@ export default {
         },
         addNewIssued(row) {
             this.issuedParam = {
-                templateId:row.id,
+                templateId: row.id,
             };
             this.issuedAddStatus = true;
         },