Browse Source

Merge branch 'master' of https://git.agilestar.cn/spfm-group/spfm-market-front

noob 3 years ago
parent
commit
f21cadaaa5

+ 2 - 1
public/index.html

@@ -27,7 +27,8 @@
   <script type="text/javascript">
     // window.staticHost = 'http://10.230.26.15:8000/spfm'; // 正式
     // window.staticHost = 'http://10.149.85.90:8000/spfm'; // 测试
-    window.staticHost = 'http://192.168.2.142:9600/';
+    window.staticHost = 'http://192.168.0.103:9600/';
+    // window.staticHost = 'http://192.168.2.142:9600/';
   </script>
 </body>
 

+ 2 - 2
public/static/views/ecClubWork.html

@@ -239,7 +239,7 @@
                             type: 'error'
                             })
                         }
-                        
+
                     });
                 })
                 // 导出
@@ -293,4 +293,4 @@
     </script>
 </body>
 
-</html>
+</html>

+ 19 - 0
public/static/views/excel.html

@@ -65,6 +65,14 @@
 		</div>
 	</div>
 	<script>
+		//2021.11.19
+		var managerLevel = JSON.parse(window.sessionStorage.userInfo).managerLevel
+		window.onload = function(){
+			if(managerLevel <= '1'){
+				$('#saves').hide()
+				$('#updates').hide()				
+			}
+		}		 
 		var date = new Date();
 		var month = date.getMonth()
 		if (month >= 1 && month <= 9) {
@@ -316,6 +324,8 @@
 						view: false, // 打印视图
 						zoom: false, // 缩放
 					},
+					// 2021.11.19
+					enableAddRow: managerLevel <= '1' ? false : true, //允许添加行(表格底部添加按钮)
 					showinfobar: true,
 					functionButton: '<button id="updates" class="btn btn-primary" style="padding:3px 6px;font-size: 12px;margin-right: 10px;">开启编辑</button> <button id="saves" class="btn btn-primary btn-danger" style=" padding:3px 6px; font-size: 12px; margin-right: 10px;display:none">保存</button>',
 					cellRightClickConfig: {
@@ -346,12 +356,20 @@
 					},
 					hook: {
 						cellMousedown: function (a, b, c) {
+							//2021.11.19
+							if(managerLevel <= '1' ){
+								window.top.$vm.$message({
+								message: '您没有编辑权限',
+								type: 'info'
+								})
+							}else
 							if (flag == false) {
 								window.top.$vm.$message({
 									message: '请先点击开启编辑按钮',
 									type: 'info'
 								})
 							}
+							
 						},//绑定鼠标事件
 					},
 				})
@@ -405,6 +423,7 @@
 				});
 			})
 		}
+		
 	</script>
 </body>
 

+ 4 - 0
public/static/views/text.html

@@ -46,6 +46,8 @@
     <div id="luckysheet" style="width:99%;height:100%">
     </div>
     <script>
+        // 2021.11.19
+        var managerLevel = JSON.parse(window.sessionStorage.userInfo).managerLevel
         var date = new Date();
         var month = date.getMonth()
         if (month >= 1 && month <= 9) {
@@ -107,6 +109,8 @@
                 showstatisticBar: false, // 底部计数
                 myFolderUrl: false,
                 showinfobar: true,
+                // 2021.11.19
+                enableAddRow: managerLevel <= '1' ? false : true, //允许添加行(表格底部添加按钮)
                 showstatisticBarConfig: {
                     count: false, // 计数栏
                     view: false, // 打印视图

+ 3 - 2
public/static/views/weeklyReport.html

@@ -99,7 +99,7 @@
 			}
 		</script>
 		<script>
-			//创建角色  配置菜单   
+			//创建角色  配置菜单
 			var id = '' //  模板id 查看/修改load时候用
 			var powerFlag = '0'; // 权限控制 0 开启 1关闭
 			var excelId = '';
@@ -136,7 +136,8 @@
 						$('#monthSelect').show()
 						$('#bmSelect').show()
 						lockFlag = 'bm'; //部门经理
-						util.ajaxJson("数据加载中", ctx + '/sysmgr/csysdept/queryChildListByLoginDept', {}, function(res) {
+                        var weekUrl="";
+						util.ajaxJson("数据加载中", ctx + '/market/weeklyReport/queryChildListByLoginDept', {}, function(res) {
 							document.getElementById("ksFlag").innerHTML = '';
 							document.getElementById("userFlag").innerHTML = '';
 							for (let i = 0; i < res.length; i++) {

+ 155 - 0
src/components/deptTreeUserNew.vue

@@ -0,0 +1,155 @@
+<template>
+    <div class="treebox" v-loading="loading">
+        <el-tree :highlight-current="true" :check-strictly="true" ref="tree" @check-change="handleCheckChange"
+            :data="treeList" node-key="id" :default-checked-keys="defaultListc" :default-expanded-keys="defaultListc"
+            @node-click="handleNodeClick">
+            <span class="custom-tree-node" slot-scope="{ node, data }" @click="cs(node)">
+                <em style="display: inline-block;width: 20px;" v-if="node.data.haveUserFlag == 'N'&& node.data.children.length == 0"></em>
+                <i class="el-icon-caret-right" v-if="node.data.haveUserFlag == 'Y' && node.data.children.length == 0"></i>
+                <el-checkbox style="margin-right: 10px" v-model="node.checked" v-if="node.data.type == 1"></el-checkbox>
+                <span>{{ node.label }}</span>
+            </span>
+        </el-tree>
+    </div>
+</template>
+
+<script>
+    export default {
+        props: ["defaultList", "type", "closeList","fillLists"],
+        data() {
+            return {
+                treeList: [],
+                opt: [],
+                defaultProps: {
+                    children: "children",
+                    label: "label",
+                },
+                defaultListc: [],
+                loading:false
+            };
+        },
+        methods: {
+            
+            cs(v){
+                // console.log(v)
+                
+            },
+            getTree(v) {
+                this.loading = true;
+                this.$http({
+                    url: "/sysmgr/csysdept/queryAllList",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                    },
+                    data: {
+                        parentorgid: v,
+                    },
+                }).then((res) => {
+                    this.treeList = res.data;
+                    this.loading = false;
+                });
+            },
+            handleCheckChange(v) {
+                let opt = [];
+                let list = this.$refs.tree.getCheckedNodes();
+                for (let i = 0; i < list.length; i++) {
+                    if (list[i].type == 1) {
+                        opt.push({
+                            receiveNo: list[i].loginNoStr,
+                            receiveName: list[i].label,
+                            deptName: list[i].displayname,
+                            deptCode: list[i].groupId,
+                            id: list[i].id,
+                            type: list[i].type,
+                            label: list[i].label
+                        });
+                    }
+                }
+                this.$emit("treeCheck", opt);
+            },
+           async handleNodeClick(v,node) {
+                let s = false;
+                if (v.children && v.children.length == 0) {
+                    s = true;
+                }
+                if (v.type) {
+                    return;
+                }
+                if (
+                    v.children &&
+                    v.children.length > 0 &&
+                    v.children[v.children.length - 1].type == 1
+                ) {
+                    return;
+                }
+                
+                await this.$http({
+                    url: "/sysmgr/sysuserinfo/queryList",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                    },
+                    data: {
+                        groupId: v.o,
+                    },
+                }).then((res) => {
+                    res.data.forEach((item) => {
+                       v.children.push({
+                            id: item.id,
+                            label: item.loginNameStr,
+                            type: 1,
+                            displayname: v.displayname,
+                            groupId: item.groupId,
+                            loginNoStr: item.loginNoStr,
+                        });
+                       
+                    });
+                
+                    
+                });
+                 
+                    node.childNodes.forEach(m=>{
+                         this.fillLists.forEach(n=>{
+                            if(m.data.loginNoStr == n.fillNo){
+                                m.checked = true
+                            }
+                         })
+                     })
+                     
+                for (let i = 0; i < this.$refs.tree.store._getAllNodes().length; i++) {
+                    if (s && v.o == this.$refs.tree.store._getAllNodes()[i].data.o) {
+                        this.$refs.tree.store._getAllNodes()[i].expanded = true;
+                        return;
+                    }
+                }
+            },
+        },
+        created() {
+            this.getTree();
+            this.defaultListc = this.defaultList;
+        },
+        watch: {
+            type() {
+                this.defaultListc = this.defaultList;
+                this.$forceUpdate();
+            },
+            defaultList() {
+                this.$forceUpdate();
+            },
+            closeList() {
+                this.$refs.tree.setCheckedNodes(this.closeList);
+            },
+        },
+    };
+</script>
+
+<style scoped lang="scss">
+    .el-icon-caret-right{
+        color: #ccc;
+        margin:0 5px;
+    }
+    .treebox {
+        border: 1px solid #ddd;
+    }
+</style>

+ 11 - 3
src/pages/main/achievements/achievementsMuban.vue

@@ -11,7 +11,7 @@
 			</div>
 			<div class="search">
 				<mySearch :searchList="searchList" @searchInfo="searchInfo"></mySearch>
-				<el-button size="small" @click="addExcel" type="primary">新增模板</el-button>
+				<el-button size="small" @click="addExcel" type="primary" v-if="isManageMuban">新增模板</el-button>
 			</div>
 			<div class="tabbox">
 				<el-table height="calc(100% - 40px)" v-loading="loading" class="com-table" ref="multipleTable"
@@ -33,7 +33,7 @@
 					<el-table-column align="center" prop="hotline" width="200" label="操作">
 						<template slot-scope="scope">
 							<el-button :disabled="scope.row.tempStsDesc == '作废'" size="mini" type="primary" plain
-								@click="issue(scope.row)">下发</el-button>
+								@click="issue(scope.row)" v-if="isManageMuban">下发</el-button>
 							<el-button size="mini" type="primary" plain @click="detailes(scope.row)">查看</el-button>
 							<!-- <el-button
                 size="mini"
@@ -43,7 +43,7 @@
                 >修改</el-button
               > -->
 							<el-button :disabled="scope.row.tempStsDesc == '作废'" size="mini" type="danger" plain
-								@click="deletes(scope.row)">作废</el-button>
+								@click="deletes(scope.row)" v-if="isManageMuban">作废</el-button>
 						</template>
 					</el-table-column>
 				</el-table>
@@ -167,6 +167,7 @@
 				loading: false,
 				tableCell: "",
 				tempType: "",
+				isManageMuban: false
 			};
 		},
 		methods: {
@@ -403,6 +404,13 @@
 		mounted() {
 			this.getOpations();
 			this.getList(this.params, this.pageSize);
+
+			let menus = JSON.parse(window.sessionStorage.childrenMenus);
+			menus.forEach(item=>{
+				if(item.systemflag == 1 && item.jspUrl == '/kpiMuban'){
+					this.isManageMuban = true
+				}
+			})
 		},
 		watch: {
 			$route() {

+ 1 - 1
src/pages/main/memberFamily/dataStatistics.vue

@@ -191,7 +191,7 @@
                     url="/market/cMemberWo/querySummaryByProvPage"
                 }else if(this.companyFlag == 1){
                     url="/market/cMemberWo/querySummaryByAreaPage"
-                    v.regionName = n.regionName
+                    v.regionName = this.userInfo.cityName
                 }
 				this.$http({
 					url: url,

+ 253 - 86
src/pages/main/memberFamily/empInfoFilling.vue

@@ -41,7 +41,7 @@
                 <el-table class="com-table" ref="multipleTable" :data="infodata" tooltip-effect="dark" size="small"
                     border style="width: 100%">
 
-                    <el-table-column prop="memberRelation" label="成员关系" width="200">
+                    <el-table-column prop="memberRelation" label="成员关系">
                         <template slot-scope="scope">
                             <el-select clearable v-model="scope.row.memberRelation" :disabled="disableStatus">
                                 <el-option v-for="items in relationopt" :key="items.dataCode" :label="items.dataName"
@@ -50,19 +50,19 @@
                             </el-select>
                         </template>
                     </el-table-column>
-                    <el-table-column prop="memberName" label="成员姓名" width="200">
+                    <el-table-column prop="memberName" label="成员姓名">
                         <template slot-scope="scope">
                             <el-input v-model="scope.row.memberName" :disabled="disableStatus"></el-input>
                         </template>
                     </el-table-column>
-                    <el-table-column prop="bornDate" label="成员出生日期" width="250">
+                    <!-- <el-table-column prop="bornDate" label="成员出生日期" width="250" >
                         <template slot-scope="scope">
                             <el-date-picker v-model="scope.row.bornDate" type="date"
-                                :disabled="disableStatus">
+                                disabled>
                                 </el-date-picker>
                         </template>
-                    </el-table-column>
-                    <el-table-column prop="memberSex" label="成员性别" width="200">
+                    </el-table-column> -->
+                    <el-table-column prop="memberSex" label="成员性别">
                         <template slot-scope="scope">
                             <el-select clearable v-model="scope.row.memberSex" :disabled="disableStatus">
                                 <el-option v-for="items in sexopt" :key="items.dataCode" :label="items.dataName"
@@ -71,14 +71,14 @@
                             </el-select>
                         </template>
                     </el-table-column>
-                    <el-table-column prop="idCard" label="成员身份证号" width="200">
+                    <el-table-column prop="idCard" label="成员身份证号">
                         <template slot-scope="scope">
                             <el-input v-model="scope.row.idCard" :disabled="disableStatus" @change="sfzyz(scope.row)"></el-input>
                         </template>
                     </el-table-column>
-                    <el-table-column prop="memberEdu" label="成员学历" width="200">eduBack
+                    <!-- <el-table-column prop="memberEdu" label="成员学历" width="200">eduBack
                         <template slot-scope="scope">
-                            <el-select clearable v-model="scope.row.memberEdu" :disabled="disableStatus">
+                            <el-select clearable v-model="scope.row.memberEdu" disabled>
                                 <el-option v-for="items in eduBackopt" :key="items.dataCode" :label="items.dataName"
                                     :value="items.dataCode">
                                 </el-option>
@@ -87,7 +87,7 @@
                     </el-table-column>
                     <el-table-column prop="partyGroup" label="成员政治面貌" width="200">
                         <template slot-scope="scope">
-                            <el-select clearable v-model="scope.row.partyGroup" :disabled="disableStatus">
+                            <el-select clearable v-model="scope.row.partyGroup" disabled>
                                 <el-option v-for="items in partyGroupopt" :key="items.dataCode" :label="items.dataName"
                                     :value="items.dataCode">
                                 </el-option>
@@ -96,7 +96,7 @@
                     </el-table-column>
                     <el-table-column prop="memberNation" label="成员民族信息" width="200">
                         <template slot-scope="scope">
-                            <el-select clearable v-model="scope.row.memberNation" :disabled="disableStatus">
+                            <el-select clearable v-model="scope.row.memberNation" disabled>
                                 <el-option v-for="items in nationopt" :key="items.dataCode" :label="items.dataName"
                                     :value="items.dataCode">
                                 </el-option>
@@ -105,42 +105,42 @@
                     </el-table-column>
                     <el-table-column prop="workUnit" label="成员工作单位" width="200">
                         <template slot-scope="scope">
-                            <el-input v-model="scope.row.workUnit" :disabled="disableStatus"></el-input>
+                            <el-input v-model="scope.row.workUnit" disabled></el-input>
                         </template>
                     </el-table-column>
                     <el-table-column prop="workDuty" label="成员职位职务" width="200">
                         <template slot-scope="scope">
-                            <el-input v-model="scope.row.workDuty" :disabled="disableStatus"></el-input>
+                            <el-input v-model="scope.row.workDuty" disabled></el-input>
                         </template>
                     </el-table-column>
                     <el-table-column prop="emerContact" label="是否为紧急联系人" width="200">
                         <template slot-scope="scope">
-                            <el-input v-model="scope.row.emerContact" :disabled="disableStatus"></el-input>
+                            <el-input v-model="scope.row.emerContact" disabled></el-input>
                         </template>
                     </el-table-column>
                     <el-table-column prop="memberTel" label="成员联系电话" width="200">
                         <template slot-scope="scope">
-                            <el-input v-model="scope.row.memberTel" :disabled="disableStatus"></el-input>
+                            <el-input v-model="scope.row.memberTel" disabled></el-input>
                         </template>
                     </el-table-column>
                     <el-table-column prop="interiorStaff" label="是否移动系统内工作" width="200">
                         <template slot-scope="scope">
-                            <el-input v-model="scope.row.interiorStaff" :disabled="disableStatus"></el-input>
+                            <el-input v-model="scope.row.interiorStaff" disabled></el-input>
                         </template>
                     </el-table-column>
                     <el-table-column prop="staffName" label="系统内员工职务" width="200">
                         <template slot-scope="scope">
-                            <el-input v-model="scope.row.staffName" :disabled="disableStatus"></el-input>
+                            <el-input v-model="scope.row.staffName" disabled></el-input>
                         </template>
                     </el-table-column>
                     <el-table-column prop="isMove" label="是否移居海外" width="200">
                         <template slot-scope="scope">
-                            <el-input v-model="scope.row.isMove" :disabled="disableStatus"></el-input>
+                            <el-input v-model="scope.row.isMove" disabled></el-input>
                         </template>
                     </el-table-column>
                     <el-table-column prop="immiType" label="移居类型" width="200">
                         <template slot-scope="scope">
-                            <el-select clearable v-model="scope.row.immiType" :disabled="disableStatus">
+                            <el-select clearable v-model="scope.row.immiType" disabled>
                                 <el-option v-for="items in immiTypeopt" :key="items.dataCode" :label="items.dataName"
                                     :value="items.dataCode">
                                 </el-option>
@@ -149,10 +149,10 @@
                     </el-table-column>
                     <el-table-column prop="memberAddress" label="成员联系地址" width="200">
                         <template slot-scope="scope">
-                            <el-input v-model="scope.row.memberAddress" :disabled="disableStatus"></el-input>
+                            <el-input v-model="scope.row.memberAddress" disabled></el-input>
                         </template>
-                    </el-table-column>
-                    <el-table-column label="操作" width="120px" align="center" v-if="!disableStatus" fixed="right">
+                    </el-table-column> -->
+                    <el-table-column label="操作" align="center" v-if="!disableStatus">
                         <template slot-scope="scope">
                             <el-button size="mini" type="primary" @click="choline(1,scope)" v-if="!scope.row.id">添加
                             </el-button>
@@ -250,9 +250,11 @@
             choline(v, n) {
                 let _this = this;
                 n.row.fillId = this.fillId;
+                // console.log(n.row);
                 let url = '';
                 if (v == 1) {
                     url = "/market/cMemberFillDetail/add"
+                    // _this.infodata.push({});
                 } else if (v == 3) {
                     url = "/market/cMemberFillDetail/update"
                 } else if (v == 2) {
@@ -273,13 +275,13 @@
                     });
                     return
                 }
-                if(!n.row.bornDate){
-                    this.$message({
-                        message: '请填写成员出生日期',
-                        type: 'error'
-                    });
-                    return
-                }
+                // if(!n.row.bornDate){
+                //     this.$message({
+                //         message: '请填写成员出生日期',
+                //         type: 'error'
+                //     });
+                //     return
+                // }
                 
                 if(!n.row.memberSex){
                     this.$message({
@@ -295,48 +297,48 @@
                     });
                     return
                 }
-                if(!n.row.partyGroup){
-                    this.$message({
-                        message: '请填写成员政治面貌',
-                        type: 'error'
-                    });
-                    return
-                }
-                if(!n.row.workUnit){
-                    this.$message({
-                        message: '请填写成员工作单位',
-                        type: 'error'
-                    });
-                    return
-                }
-                if(!n.row.memberTel){
-                    this.$message({
-                        message: '请填写成员联系电话',
-                        type: 'error'
-                    });
-                    return
-                }
-                if(!n.row.memberAddress){
-                    this.$message({
-                        message: '请填写成员联系地址',
-                        type: 'error'
-                    });
-                    return
-                }
-                if(!n.row.interiorStaff){
-                    this.$message({
-                        message: '请填写是否移动系统内工作',
-                        type: 'error'
-                    });
-                    return
-                }
-                if(!n.row.staffName){
-                    this.$message({
-                        message: '请填写系统内员工职务',
-                        type: 'error'
-                    });
-                    return
-                }
+                // if(!n.row.partyGroup){
+                //     this.$message({
+                //         message: '请填写成员政治面貌',
+                //         type: 'error'
+                //     });
+                //     return
+                // }
+                // if(!n.row.workUnit){
+                //     this.$message({
+                //         message: '请填写成员工作单位',
+                //         type: 'error'
+                //     });
+                //     return
+                // }
+                // if(!n.row.memberTel){
+                //     this.$message({
+                //         message: '请填写成员联系电话',
+                //         type: 'error'
+                //     });
+                //     return
+                // }
+                // if(!n.row.memberAddress){
+                //     this.$message({
+                //         message: '请填写成员联系地址',
+                //         type: 'error'
+                //     });
+                //     return
+                // }
+                // if(!n.row.interiorStaff){
+                //     this.$message({
+                //         message: '请填写是否移动系统内工作',
+                //         type: 'error'
+                //     });
+                //     return
+                // }
+                // if(!n.row.staffName){
+                //     this.$message({
+                //         message: '请填写系统内员工职务',
+                //         type: 'error'
+                //     });
+                //     return
+                // }
                 this.$http({
                     url: url,
                     method: "post",
@@ -459,7 +461,7 @@
                     },
                 }).then((res) => {
                     this.infodata = res.data.data;
-                    this.infodata.push({});
+                    this.infodata.push({fillId: this.fillId});
                 });
             },
             //添加
@@ -468,21 +470,186 @@
                     this.infolist = {};
                     this.dialogStatus = false;
                 }else{
-                    this.$http({
-                        url: "/market/cMemberFillDetail/saveFillDetailSummary",
-                        method: "post",
-                        headers: {
-                            "Content-Type": "application/json",
-                            "page": '{"pageNo":"' + 1 + '","pageSize":"100"}'
-                        },
-                        data: {
-                            fillId:this.fillId
-                        },
-                    }).then((res) => {
-                        this.infolist = {};
-                        this.dialogStatus = false;
-                    });
+
+                    let _this = this;
+                    let infodata1 = JSON.parse(JSON.stringify(this.infodata))
+                    let infodataLast = infodata1[infodata1.length-1]
+                    if(Object.keys(infodataLast).length >= 2){
+                        if(!infodataLast.memberRelation && !infodataLast.memberName && !infodataLast.memberSex && !infodataLast.idCard){
+                            this.loadinged = true;
+                        this.$http({
+                            url: "/market/cMemberFillDetail/saveFillDetailSummaryNew",
+                            method: "post",
+                            headers: {
+                                "Content-Type": "application/json",
+                                "page": '{"pageNo":"' + 1 + '","pageSize":"100"}'
+                            },
+                            data: infodata1,
+                        }).then((res) => {
+                            // this.infolist = {};
+                            // this.dialogStatus = false;
+                            this.loadinged = false;
+                            if (res.data.result === 1) {
+                                _this.$message({
+                                    message: res.data.desc,
+                                    type: 'error'
+                                });
+                            } else {
+                                _this.$message({
+                                    message: '成功',
+                                    type: 'success'
+                                });
+                                _this.infolist = {};
+                                _this.dialogStatus = false;
+                                _this.getList({}, _this.pageSize);
+                            }
+                        });
+                        }else if(!infodataLast.memberRelation || !infodataLast.memberName || !infodataLast.memberSex || !infodataLast.idCard){
+                            if(!infodataLast.memberRelation){
+                            this.$message({
+                                message: '请填写成员关系',
+                                type: 'error'
+                            });
+                            return false
+                        }
+                        
+                        if(!infodataLast.memberName){
+                            this.$message({
+                                message: '请填写成员姓名',
+                                type: 'error'
+                            });
+                            return false
+                        }
+                        
+                        if(!infodataLast.memberSex){
+                            this.$message({
+                                message: '请填写成员性别',
+                                type: 'error'
+                            });
+                            return false
+                        }
+                        if(!infodataLast.idCard){
+                            this.$message({
+                                message: '请填写成员身份证号',
+                                type: 'error'
+                            });
+                            return false
+                        }
+                        this.loadinged = true;
+                        this.$http({
+                            url: "/market/cMemberFillDetail/saveFillDetailSummaryNew",
+                            method: "post",
+                            headers: {
+                                "Content-Type": "application/json",
+                                "page": '{"pageNo":"' + 1 + '","pageSize":"100"}'
+                            },
+                            data: infodata1,
+                        }).then((res) => {
+                            // this.infolist = {};
+                            // this.dialogStatus = false;
+                            this.loadinged = false;
+                            if (res.data.result === 1) {
+                                _this.$message({
+                                    message: res.data.desc,
+                                    type: 'error'
+                                });
+                            } else {
+                                _this.$message({
+                                    message: '成功',
+                                    type: 'success'
+                                });
+                                _this.infolist = {};
+                                _this.dialogStatus = false;
+                                _this.getList({}, _this.pageSize);
+                            }
+                        });
+                        }
+                        
+                    }else if(Object.keys(infodataLast).length == 1){
+                        this.loadinged = true;
+                        this.$http({
+                            url: "/market/cMemberFillDetail/saveFillDetailSummaryNew",
+                            method: "post",
+                            headers: {
+                                "Content-Type": "application/json",
+                                "page": '{"pageNo":"' + 1 + '","pageSize":"100"}'
+                            },
+                            data: infodata1,
+                        }).then((res) => {
+                            // this.infolist = {};
+                            // this.dialogStatus = false;
+                            this.loadinged = false;
+                            if (res.data.result === 1) {
+                                _this.$message({
+                                    message: res.data.desc,
+                                    type: 'error'
+                                });
+                            } else {
+                                _this.$message({
+                                    message: '成功',
+                                    type: 'success'
+                                });
+                                _this.infolist = {};
+                                _this.dialogStatus = false;
+                                _this.getList({}, _this.pageSize);
+                            }
+                        });
+                    }
+
+
+                    // let isInfodataNull = infodataLast.filter((item)=>{
+                    //     console.log(item.length);
+                    //     return item.length
+                    // })
+                    // console.log(isInfodataNull);  
+                // this.infodata.forEach((item,index)=>{
+                    // if(!infodataLast.memberRelation){
+                    //     this.$message({
+                    //         message: '请填写成员关系',
+                    //         type: 'error'
+                    //     });
+                    //     return false
+                    // }
+                    
+                    // if(!infodataLast.memberName){
+                    //     this.$message({
+                    //         message: '请填写成员姓名',
+                    //         type: 'error'
+                    //     });
+                    //     return false
+                    // }
+                    
+                    // if(!infodataLast.memberSex){
+                    //     this.$message({
+                    //         message: '请填写成员性别',
+                    //         type: 'error'
+                    //     });
+                    //     return false
+                    // }
+                    // if(!infodataLast.idCard){
+                    //     this.$message({
+                    //         message: '请填写成员身份证号',
+                    //         type: 'error'
+                    //     });
+                    //     return false
+                    // }
+                // })
+                    // this.$http({
+                    //     url: "/market/cMemberFillDetail/saveFillDetailSummaryNew",
+                    //     method: "post",
+                    //     headers: {
+                    //         "Content-Type": "application/json",
+                    //         "page": '{"pageNo":"' + 1 + '","pageSize":"100"}'
+                    //     },
+                    //     data: infodata1,
+                    // }).then((res) => {
+                    //     this.infolist = {};
+                    //     this.dialogStatus = false;
+                    // });
+                    // console.log(infodata1)
+                
                 }
+                
             },
             submitInfo(u) {
                 let _this = this;

+ 8 - 7
src/pages/main/memberFamily/employeeInfo.vue

@@ -11,10 +11,10 @@
                     tooltip-effect="dark" size="small" border style="width: 100%" v-loading="loading" >
 				<!-- 	<el-table-column type="selection" width="55">
 					</el-table-column> -->
-                    <el-table-column prop="regionName" label="地市公司名称">
+                    <!-- <el-table-column prop="regionName" label="地市公司名称">
                     </el-table-column>
                     <el-table-column prop="areaName" label="区县名称">
-                    </el-table-column>
+                    </el-table-column> -->
 					<el-table-column prop="fillName" label="员工姓名">
                     </el-table-column>
 					<el-table-column prop="memberName" label="成员姓名">
@@ -24,8 +24,8 @@
                     </el-table-column>
 					<el-table-column prop="memberRelation" label="成员关系">
 					</el-table-column>
-					<el-table-column prop="bornDate" label="成员出生日期">
-                    </el-table-column>
+					<!-- <el-table-column prop="bornDate" label="成员出生日期">
+                    </el-table-column> -->
                     <el-table-column prop="memberSex" label="成员性别">
                     </el-table-column>
 					<el-table-column prop="idCard" label="成员身份证号">
@@ -33,7 +33,7 @@
                            {{$desensitization(scope.row.idCard,3)}}
                         </template>
                     </el-table-column>
-					<el-table-column prop="memberEdu" label="成员学历">
+					<!-- <el-table-column prop="memberEdu" label="成员学历">
                     </el-table-column>
 					<el-table-column prop="partyGroup" label="成员政治面貌">
 					</el-table-column>
@@ -59,7 +59,7 @@
 					<el-table-column prop="immiType" label="移居类型">
 					</el-table-column>
 					<el-table-column prop="memberAddress" label="成员联系地址">
-					</el-table-column>
+					</el-table-column> -->
                 </el-table>
                 <el-pagination class="pageBox" @current-change="currchange" layout="prev, pager, next" background
                     :total="total">
@@ -157,7 +157,7 @@
                 });
             },
 			handleSelectionChange(val) {
-				console.log(val)
+				// console.log(val)
 			},
 			jumpjd(){
 				this.$router.push({
@@ -199,6 +199,7 @@
                 this.loading = true;
                 this.tableData = [];
                 v.areaName = this.$route.query.regionName
+                v.isShow = 0
                 this.$http({
                     url: "/market/cMemberWo/queryMkMemberFillDetailSummaryPage",
                     method: "post",

+ 73 - 15
src/pages/main/memberFamily/haveInHand.vue

@@ -73,7 +73,7 @@
 
                 <el-form-item class="info-line online" v-if="!disableStatus">
                     <span>填报人</span>
-                    <deptTree :closeList="closeList" class="tree" @treeCheck="treeCheck">
+                    <deptTree :closeList="closeList" class="tree" @treeCheck="treeCheck" :defaultList="defaultList" :fillLists="fillLists">
                     </deptTree>
                     <div class="tree treeUser">
                         <p v-for="(item,index) in treeList" :key="index">{{item.receiveName}}
@@ -127,7 +127,7 @@
     import mySearch from "../../../components/search.vue";
     import myMessage from "../../../components/myMessage.vue"
     import toolList from '../../../components/toolList'
-    import deptTree from "../../../components/deptTreeUser.vue"
+    import deptTree from "../../../components/deptTreeUserNew.vue"
     import deptTreep from "../../../components/deptTreeP.vue"
 
     export default {
@@ -186,7 +186,8 @@
                 deptList: [],
                 companyFlag: '',
                 dialogStatusp: false,
-                choone: {}
+                choone: {},
+                fillLists:[]
             }
         },
         methods: {
@@ -219,9 +220,10 @@
                             fillName: this.treeList[i].label,
                         })
                     }
+
+                    JSON.parse(JSON.stringify(param.fillList))
                     // for (let i = 0; i < this.treeList.length; i++) {
                     //     for (let ii = 0; ii < this.treeListp.length; ii++) {
-                    //         console.log(this.treeList);
                     //         if (this.treeListp[i].loginNoStr == this.treeList[ii].receiveNo) {
                     //             this.$message({
                     //                 message: '负责人和填报人重复!',
@@ -231,6 +233,7 @@
                     //         }
                     //     }
                     // }
+                    var end_flag=false;
                     this.treeList.forEach(item=>{
                         this.treeListp.forEach(n=>{
                             if(n.loginNoStr == item.receiveNo){
@@ -238,11 +241,11 @@
                                     message: '负责人和填报人重复!',
                                     type: 'error'
                                 });
-                                return
+                                end_flag=true;
                             }
                         })
                     })
-
+                    if(end_flag)return;
                     let url = '';
                     if (this.companyFlag == 0) {
                         url = '/market/cMemberWo/saveMkMemberWoByProv';
@@ -274,16 +277,16 @@
                                 type: 'success'
                             });
                             _this.infolist = {};
-                            _this.treeList = [];
-                            _this.treeListp = [];
+                            // _this.treeList = [];
+                            // _this.treeListp = [];
                             _this.dialogStatus = false;
                             _this.getList({}, 1);
                         }
                     });
                 } else if (v === 2) {
                     this.infolist = {};
-                    this.treeList = [];
-                    this.treeListp = [];
+                    // this.treeList = [];
+                    // this.treeListp = [];
                     this.dialogStatus = false;
                 }
             },
@@ -359,7 +362,6 @@
                     this.treeListp.splice(x, 1)
                 } else {
                     this.treeListp.push(v);
-                    // console.log(this.treeListp)
                 }
             },
             jumpfw(v) {
@@ -372,7 +374,7 @@
                 this.setabList("填报进度跟踪", "/reportProgress?woNo=" + v.woNo);
             },
             jumpjd(v) {
-                console.log(v.receiverGroupName)
+                // console.log(v.receiverGroupName)
                 this.$router.push({
                     path: "/speedOfProgress",
                     query: {
@@ -443,7 +445,7 @@
                 this.getList(this.params, this.pageSize);
             },
             //申请
-            dialogCheck(v, n) {
+             dialogCheck(v, n) {
                 this.choone = n;
                 if (v === 1) {
                     this.titname = '查看';
@@ -453,6 +455,7 @@
                     this.disableStatus = false;
                 }
                 this.dialogStatus = true;
+                
                 this.$http({
                     url: "/market/cMemberWo/queryMemeberWoInfo",
                     method: "post",
@@ -467,11 +470,35 @@
                     this.infolist.time = [res.data.startTime, res.data.endTime];
                     this.infolist.opNo = this.userInfo.loginNo;
                     this.infolist.opName = this.userInfo.loginName;
-
+                    // this.defaultList = []
+                    // this.defaultList.push({
+                    //     deptCode: "00440089005200000000",
+                    //     deptName: "中国移动通信集团黑龙江有限公司\\哈尔滨分公司\\综合部",
+                    //     id: "694817329862230016",
+                    //     label: "郭有为",
+                    //     receiveName: "郭有为",
+                    //     receiveNo: "guoyouwei",
+                    //     type: 1,
+                    // })
+
+                    // this.treeList = this.defaultList
+                    this.fillLists = []
+                    this.infolist.fillList.forEach(item=>{
+                        this.fillLists.push({
+                            fillName: item.fillName,
+                            fillNo: item.fillNo,
+                            receiveNo: item.fillNo,
+                            receiveName:item.fillName,
+                            label: item.fillName
+                        })
+                        
+                    })
+                    this.treeList = this.fillLists
                     //地市范围
                     if (this.companyFlag == '0') {
                         this.$http({
                             url: "/sysmgr/csysdept/queryRegionDeptList",
+                            async:false,
                             method: "post",
                             headers: {
                                 "Content-Type": "application/json",
@@ -479,11 +506,21 @@
                             data: {},
                         }).then((res) => {
                             this.deptList = res.data[0].children;
+                            this.deptList.forEach(item=>{
+                                this.infolist.dutyList.forEach(m=>{
+                                    if(m.groupId == item.o){
+                                        
+                                        item = Object.assign(item,{loginNoStr: m.dutyNo, loginNameStr: m.dutyName})
+                                        this.treeListp.push(item);
+                                    }
+                                })
+                            })
                         });
                     } else {
-                        this.$http({
+                         this.$http({
                             url: "/sysmgr/csysdept/queryListByParent",
                             method: "post",
+                            async:false,
                             headers: {
                                 "Content-Type": "application/json",
                             },
@@ -492,8 +529,19 @@
                             },
                         }).then((res) => {
                             this.deptList = res.data;
+                            this.deptList.forEach(item=>{
+                                this.infolist.dutyList.forEach(m=>{
+                                    if(m.groupId == item.o){
+                                        item = Object.assign(item,{loginNoStr: m.dutyNo, loginNameStr: m.dutyName})
+                                        this.treeListp.push(item);
+                                    }
+                                })
+                            })
+
+                            
                         });
                     }
+                    
                     //区县进入查人
                     // if(this.companyFlag == '2'){
                     //     this.$http({
@@ -578,6 +626,16 @@
         },
         mounted() {
             this.getUser();
+            // this.defaultList.push({
+            //             deptCode: "",
+            //             deptName: "",
+            //             id: "",
+            //             label: "",
+            //             receiveName: "",
+            //             receiveNo: "",
+            //             type: 1,
+            //             checked:true
+            //         })
         },
         created() {
 

+ 18 - 3
src/pages/main/memberFamily/index.vue

@@ -3,12 +3,25 @@
 		<div class="container">
 			<div class="container-box">
 				<div class="adv-type">
-					<div v-for="item in typeList" :key="item.dataCode" @click="advmaterial(item)">
+					<!-- <div v-for="item in typeList" :key="item.dataCode" @click="advmaterial(item)" >
 						<div v-if="(roleStatus <= 1 && item.dataName=='信息汇总') || (roleStatus < 4 && item.dataName=='信息填报')">
 							<span><i class="el-icon-folder-opened"></i></span>
 							<span>{{item.dataName}}</span>
 						</div>
 
+					</div> -->
+					<div @click="advmaterial(typeList[0])" v-if="roleStatus < 4">
+						
+							<span><i class="el-icon-folder-opened"></i></span>
+							<span>信息填报</span>
+						
+
+					</div>
+					<div @click="advmaterial(typeList[1])" v-if="roleStatus <= 1">
+						
+							<span><i class="el-icon-folder-opened"></i></span>
+							<span>信息汇总</span>
+					
 					</div>
 				</div>
 				<div class="adv-box">
@@ -173,7 +186,7 @@
 						})
 					}
 					param.fillList = [];
-                    console.log(this.treeList)
+                    // console.log(this.treeList)
 					for (let i = 0; i < this.treeList.length; i++) {
 						param.fillList.push({
 							fillNo:this.treeList[i].receiveNo,
@@ -392,7 +405,7 @@
 
 			getUser() {
 				this.userInfo = JSON.parse(window.sessionStorage.userInfo);
-				console.log(this.userInfo);
+				// console.log(this.userInfo);
 				let newArr = [];
 				
 				if(this.userInfo.cityName == null && this.userInfo.countyName == null){
@@ -410,6 +423,7 @@
 							sts: 0
 						},
 					}).then((res) => {
+						// console.log(res.data.body);
 						res.data.body.forEach(item=>{
 							newArr.push(...item.dutyNo.split(","));
 						})
@@ -435,6 +449,7 @@
 							sts: 0
 						},
 					}).then((res) => {
+						
 						res.data.body.forEach(item=>{
 							newArr.push(...item.dutyNo.split(","));
 						})

+ 80 - 10
src/pages/main/organizaStructure/staffManage.vue

@@ -3,20 +3,55 @@
         <div class="container-box">
             <toolList @iconCli='iconCli' :tooltit='tooltit'></toolList>
             <div class="search">
-                <mySearch :searchList="searchList" @searchInfo="searchInfo" style="width: 60%"></mySearch>
-                <span>
+                <el-form :model="searchSection" ref="searchSection">
+                    <div class="search-box">
+                        <el-form-item>
+                            <el-select @change="getareatype" :popper-append-to-body="false" v-model="searchSection.cityCompName" placeholder="地市">
+                                <el-option v-for="item in typeopt" :key="item.id" :label="item.roleName"
+                                    :value="item.roleName">
+                                </el-option>
+                            </el-select>
+                        </el-form-item>
+                        <el-form-item>
+                            <el-select  @change="gettype" :popper-append-to-body="false" v-model="searchSection.areaCompName" placeholder="区县">
+                                <el-option v-for="item in kindopt" :key="item.id" :label="item.roleName"
+                                    :value="item.roleName">
+                                </el-option>
+                            </el-select>
+                        </el-form-item>
+                        <el-form-item>
+                            <el-input v-model="searchSection.roleName" placeholder="角色">
+                            </el-input>
+                        </el-form-item>
+                        <el-form-item>
+                            <el-input v-model="searchSection.userName" placeholder="姓名">
+                            </el-input>
+                        </el-form-item>
+                    </div>
+                </el-form>
+                <div>
+                    <el-button class="btn-check" size="medium" type="primary" plain icon="el-icon-search" @click="searchInfo">搜索</el-button>
+                    <el-button class="btn-check" size="medium" type="primary"  @click="resetSearch">重置</el-button>
+                </div>
+                
+                <!-- <mySearch :searchList="searchList" @searchInfo="searchInfo" style="width: 60%"></mySearch> -->
+                
+            </div>
+            <div class="clearfix" style="margin-top: 20px">
+                <span style="float: right">
                     <!-- <el-button type="primary" @click="dialogCheck(4)" size="medium">导入</el-button> -->
-                    <el-button type="primary" @click="downloadExcel(1)">导出</el-button>
-                    <el-button type="primary" @click="downloadExcel(2)">下载模板</el-button>
+                    
+                    <el-button type="primary" @click="downloadExcel(2)" class="downloadMuban">下载模板</el-button>
                     <myUpload style="display:inline-block;" :fileInfo="fileInfo"
                         :fileList="fileInfo.fileList" @uploadBack='uploadBack'></myUpload>
+                    <el-button type="primary" size="medium" @click="downloadExcel(1)">导出</el-button>
                     <el-button type="primary" @click="dialogCheck(3)" size="medium">添加</el-button>
                     <!-- <el-button type="primary" @click="dialogCheck(3)" size="medium">导入</el-button> -->
                     <!-- <el-button type="primary" @click="dialogCheck(3)" size="medium">导出</el-button> -->
                 </span>
             </div>
             <div class="tabbox">
-                <el-table height="calc(100% - 40px)" class="com-table" ref="multipleTable" :data="tableData"
+                <el-table height="calc(100% - 150px)" class="com-table" ref="multipleTable" :data="tableData"
                     tooltip-effect="dark" size="small" border style="width: 100%" v-loading="loading">
                     <el-table-column prop="oaNo" label="员工工号">
                     </el-table-column>
@@ -183,7 +218,7 @@
                     }],
                 },
                 searchList: [{
-                        type: 'input',
+                        type: 'sel',
                         tit: '地市',
                         value: '',
                         width: '24%'
@@ -207,6 +242,7 @@
                         width: '24%',
                     },
                 ],
+                searchSection: {},
                 tooltit: '人员管理',
                 fullscreen: false,
                 total: 0,
@@ -247,12 +283,21 @@
             //搜索数据
             searchInfo(v) {
                 this.params = {};
-                v[0] ? this.params.cityCompName = v[0] : '';
-                v[1] ? this.params.areaCompName = v[1] : '';
-                v[2] ? this.params.roleName = v[2] : '';
-                v[3] ? this.params.userName = v[3] : '';
+                this.searchSection.cityCompName ? this.params.cityCompName = this.searchSection.cityCompName : '';
+                this.searchSection.areaCompName ? this.params.areaCompName = this.searchSection.areaCompName : '';
+                this.searchSection.roleName ? this.params.roleName = this.searchSection.roleName : '';
+                this.searchSection.userName ? this.params.userName = this.searchSection.userName : '';
+                // v[0] ? this.params.cityCompName = v[0] : '';
+                // v[1] ? this.params.areaCompName = v[1] : '';
+                // v[2] ? this.params.roleName = v[2] : '';
+                // v[3] ? this.params.userName = v[3] : '';
                 this.getList(this.params, this.pageSize);
             },
+            resetSearch(){
+                this.searchSection = {};
+                this.params = {};
+                this.getList(this.params, 1);
+            },
             closedia() {
                 this.infolist = {
                     roleName:''
@@ -736,4 +781,29 @@
             }
         }
     }
+    .clearfix:after {
+    content: ".";
+    display: block;
+    height: 0;
+    clear: both;
+    visibility: hidden;
+    }
+
+    .clearfix {
+        *zoom: 1;
+    }
+    .downloadMuban{
+        background: none;
+        color: #107CFF;
+        border: none;
+        padding: 0;
+        vertical-align: bottom;
+    }
+    .search-box{
+        display: flex;
+        div{
+            margin-right: 10px;
+            margin-bottom: 0;
+        }
+    }
 </style>

+ 31 - 19
src/pages/main/terminal/advcheck.vue

@@ -27,7 +27,7 @@
                         <template slot-scope="scope">
                             <el-button size="mini" type="primary" @click="dialogCheck(scope.row,1)">查看</el-button>
                             <!--<el-button size="mini" type="danger" v-if="scope.row.sts==3"-->
-                            <el-button size="mini" type="danger" v-if="advstatus == 0 && scope.row.isBtnShow  && scope.row.sts=='0'"
+                            <el-button size="mini" type="danger" v-if="advstatus == 0 && scope.row.isBtnShow  && scope.row.sts=='0' && userInfo.loginNo == scope.row.assigneeNo"
                                 @click="dialogCheck(scope.row,2)">审核</el-button>
                             <el-button v-if="userInfo.loginName == scope.row.opName&&scope.row.sts=='3'" size="mini"
                                 type="primary" @click="advSure(scope.row)">归档
@@ -51,7 +51,7 @@
 
             <el-dialog title="定稿素材" :visible.sync="dialogStatusc" width="50%" :destroy-on-close="true"
                 :modal-append-to-body="false" :close-on-click-modal="false">
-                <el-form>
+                <!-- <el-form>
                     <el-form-item class="info-line online">
                         <span>素材类型</span>
                         <el-select :popper-append-to-body="false" v-model="advtype" placeholder="素材类型">
@@ -60,7 +60,7 @@
                             </el-option>
                         </el-select>
                     </el-form-item>
-                </el-form>
+                </el-form> -->
                 <div slot="footer" class="dialog-footer">
                     <el-button @click="dialogCli(1)" type="primary">确 定</el-button>
                     <el-button @click="dialogCli(2)">取 消</el-button>
@@ -116,6 +116,7 @@
                 singleTable: {},
                 shParam:{},
                 // isBtnShow: false,
+                isGDClick: false
             }
         },
         methods: {
@@ -141,6 +142,7 @@
                     let data = res.data.data;
                     this.total = res.data.totalRecord;
                     this.loading = false;
+                    this.isGDClick = false;
                     if(this.advstatus==0){
 						data.forEach(item => {
                             item.isBtnShow = false;
@@ -162,7 +164,14 @@
 				        woNo: v.id
 				    },
 				}).then((res) => {
+                    
                     this.shParam = res.data;
+                    //  this.dialogCli(1);
+                    // callback&&callback()
+                    if(this.isGDClick){
+                        this.dialogCli(1);
+                        return
+                    }
 				    if(res.data.taskName == '需求部门'){
                         v.sts = '3'
                         return
@@ -172,7 +181,8 @@
                         v.isBtnShow = true;
                         return
                     }
-            
+                   
+                    
 				});
 			},
             // 分页
@@ -199,22 +209,25 @@
                 this.componentInfo = params;
                 this.componentStatus = true;
             },
+            // 归档
             advSure(v) {
                 let _this = this;
-                this.dialogStatusc = true;
+                // this.dialogStatusc = true;
+                this.isGDClick = true;
                 this.dgid = v.id;
+                
                 this.getSts(v);
             },
             dialogCli(v) {
                 let _this = this;
 
                 if (v == 1) {
-                    let advTypeName = '';
-                    for (let i = 0; i < this.typeList.length; i++) {
-                        if (this.typeList[i].dataCode == this.advtype) {
-                            advTypeName = this.typeList[i].dataName;
-                        }
-                    }
+                    // let advTypeName = '';
+                    // for (let i = 0; i < this.typeList.length; i++) {
+                    //     if (this.typeList[i].dataCode == this.advtype) {
+                    //         advTypeName = this.typeList[i].dataName;
+                    //     }
+                    // }
                     // let param = {
                     //     woNo: this.dgid,
                     //     advTypeName: advTypeName,
@@ -222,14 +235,13 @@
                     // }
                     let gdParam = {
                         woNo: this.dgid,
-                        advTypeName: advTypeName,
-                        advType: this.advtype
+                        // advTypeName: advTypeName,
+                        // advType: this.advtype
                     }
-                    
+
                     this.shParam.params.terminalRes = JSON.stringify(Object.assign(JSON.parse(this.shParam.params.terminalRes) , gdParam))
-                    
-                    let param = this.shParam
 
+                    let param = this.shParam
                     this.$http({
                         // url: "/market/cadv/mkConfirmAdv",
                         url: "/bpm/api/submitTask",
@@ -237,7 +249,7 @@
                         headers: {
                             "Content-Type": "application/json",
                         },
-                        data: param,
+                        data: param, 
                     }).then((res) => {
                         if (res.data.result === 1) {
                             _this.$message({
@@ -253,8 +265,8 @@
                         }
                     });
                 }
-                this.dialogStatusc = false;
-                this.advtype = '';
+                // this.dialogStatusc = false;
+                // this.advtype = '';
                 return
             },
             closeEdio() {

+ 16 - 1
src/pages/main/terminal/advertincrease.vue

@@ -37,7 +37,7 @@
                         </el-form-item>
                         <el-form-item prop="overtime">
                             <span>完成时间</span>
-                            <el-date-picker v-model="infolist.overtime" type="date" placeholder="完成时间">
+                            <el-date-picker v-model="infolist.overtime" type="date" placeholder="完成时间" :pickerOptions = "pickerOptions">
                             </el-date-picker>
                         </el-form-item>
                         <el-form-item prop="urgent">
@@ -343,6 +343,21 @@
                 depttype: 0,
             }
         },
+        computed:{
+             pickerOptions:function(){
+                 return {
+                     disabledDate(time) {
+                        // if(time.getTime() < Date.now() - 8.64e7 || (time.getTime() > Date.now() && time.getTime() < Date.now() + 8.64e7*3) ){
+                        //     return true
+                        // }
+                        if(time.getTime() < Date.now() + 8.64e7*3){
+                            return true
+                        }
+                        
+                    }
+                 }
+             }
+        },
         methods: {
             deletes() {
             	this.treeListonly = {};

+ 2 - 1
src/pages/main/terminal/advertisement.vue

@@ -18,7 +18,8 @@
 
                     <div class="adv-tit" @click="jumpadv('2')">
                         <i class="el-icon-notebook-1"></i>
-                        <span>定稿 <em>{{info.designNum||0}}</em></span>
+                        <!-- <span>定稿 <em>{{info.designNum||0}}</em></span> -->
+                        <span>定稿 <em>{{info.finalNum||0}}</em></span>
                     </div>
                     <div class="adv-tit" @click="jumpinfo">
                         <span>广告设计费明细</span>

+ 171 - 28
src/pages/main/terminal/advertmaterial.vue

@@ -4,11 +4,31 @@
             <div class="container-box">
                 <h2>素材库</h2>
                 <div class="adv-type">
-                    <el-select v-model="infotype" @change="changeType">
+                    <div class="search-list-box">
+                    <el-select v-model="infotype" @change="changeType" class="search-box">
                         <el-option v-for="items in typeList" :key="items.dataCode" :label="items.dataName"
                             :value="items.dataCode">
                         </el-option>
                     </el-select>
+                    <el-input v-model="fileNameSearch" placeholder="文件名称" @input="searchInput" class="file-name-search search-box"></el-input>
+                    <el-select v-model="timeSort" @change="timeSortChange" class="search-box">
+                        <el-option v-for="item in sortList" :key="item.sortCode" :label="item.sortName"
+                            :value="item.sortCode">
+                        </el-option>
+                    </el-select>
+                    <div class="block search-box search-box1">
+                        <el-date-picker
+                        v-model="dateSearch"
+                        type="daterange"
+                        range-separator="至"
+                        start-placeholder="开始日期"
+                        end-placeholder="结束日期"
+                        @change="dateSearchChange"
+                        class="search-inner-box">
+                        </el-date-picker>
+                    </div>
+                    
+                    </div>
                     <span>
                         <myUpload style="float: left;" @uploadBack="uploadBack" :fileInfo="fileInfot"
                             :fileList="fileInfot.fileList"></myUpload>
@@ -22,12 +42,15 @@
 
                 <div class="img-box">
                     <div class="boximg">
-                        <div v-for="(item,index) in imgList" :key="item.id">
-                            <img :src="item.fileBase64" alt="" @click="checkimg(item,index)">
-                            <el-checkbox v-if="mstatus" v-model="item.checked" @change="checkAdd(item)"></el-checkbox>
+                        <div v-for="(item,index) in imgList" :key="item.id" class="img-list">
+                            <div class="img-content">
+                                <img :src="item.fileBase64" alt="" @click="checkimg(item,index)">                           
+                                <el-checkbox v-if="mstatus" v-model="item.checked" @change="checkAdd(item)"></el-checkbox>
+                            </div>
+                            <input type="text" class="file-name" v-model="item.fileName" :readonly="!item.isRename" @dblclick="renameFile(item)" :style="{'border':!item.isRename ? 'none' : '1px solid #ddd'}" @blur="submitFileName(item)">
                         </div>
                     </div>
-                    <el-pagination class="pageBox" @current-change="currchange" layout="prev, pager, next" background
+                    <el-pagination :page-size="20" class="pageBox" @current-change="currchange" layout="prev, pager, next" background
                         :total="total">
                     </el-pagination>
                 </div>
@@ -67,7 +90,27 @@
                 bigImgs: false,
                 checksrc: null,
                 mstatus: false,
-                checkList: []
+                checkList: [],
+                params:{},
+                fileNameSearch: '',
+                isRename: true,
+
+                //时间排序
+                sortList:[
+                    {
+                        sortCode: '1',
+                        sortName: '倒序'
+                    },
+                    {
+                        sortCode: '2',
+                        sortName: '正序'
+                    }
+                ],
+                timeSort:'倒序',
+                isDesc: "desc",
+                dateSearch:[],
+                createTimeFrom: '',
+                createTimeTo:''
             }
         },
         methods: {
@@ -76,10 +119,31 @@
                     if (this.typeList[i].dataCode == v) {
                         this.fileInfot.advType = v;
                         this.fileInfot.advTypeName = this.typeList[i].dataName;
+                        // this.infotype = v
                         this.getlist(this.pageSize);
                     }
                 }
             },
+            timeSortChange(v){
+                if(v==1){
+                    this.isDesc = 'desc'
+                    this.getlist(this.pageSize);
+                }else if(v==2){
+                    this.isDesc = ''
+                    this.getlist(this.pageSize);
+                }
+            },
+            dateSearchChange(v){
+                this.createTimeFrom = this.$formatDate(v[0],"YYYY-MM-DD")
+                this.createTimeTo = this.$formatDate(v[1],"YYYY-MM-DD")
+                this.getlist(this.pageSize);
+                
+
+            },
+            searchInput(v){
+                this.fileNameSearch = v
+                this.getlist(this.pageSize);
+            },
             uploadBack(v) {
                 this.getlist(this.pageSize);
             },
@@ -149,9 +213,45 @@
                     });
                 }
             },
+            renameFile(v){
+                this.$set(v,'isRename',true)
+            },
+            submitFileName(v){
+                v.isRename = false;
+                let params = {
+                    id: v.id,
+                    fileName: v.fileName
+                }
+                this.$http({
+                    url: "/market/cadvMaterial/updateMkAdvFileName",
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                    },
+                    data: params,
+                }).then((res) => {
+                    if (res.data.result === 1) {
+                            this.$message({
+                                message: res.data.desc,
+                                type: 'error'
+                            });
+                        } else {
+                            this.$message({
+                                message: '成功',
+                                type: 'success'
+                            });
+                            this.getlist(this.pageSize);
+                        }
+                });
+               
+            },
             getlist(v) {
                 let params = {
-                    advType: this.infotype
+                    advType: this.infotype,
+                    fileName: this.fileNameSearch,
+                    isDesc: this.isDesc,
+                    createTimeFrom: this.createTimeFrom,
+                    createTimeTo: this.createTimeTo,
                 };
                 if (this.infotype == '08') {
                     params.advType = ''
@@ -177,7 +277,7 @@
             // 分页
             currchange(v) {
                 this.pageSize = v;
-                this.getList(this.pageSize);
+                this.getlist(this.pageSize);
             },
             gettype() {
                 this.$http({
@@ -279,7 +379,10 @@
         .adv-type {
             display: flex;
             justify-content: space-between;
-
+            align-items: center;
+            .file-name-search{
+                width: 30%;
+            }
             span {
                 display: inline-block;
 
@@ -287,7 +390,7 @@
         }
 
         .img-box {
-            height: 100%;
+            height: 90%;
 
             .boximg {
                 height: calc(100% - 190px);
@@ -297,35 +400,57 @@
                 // justify-content: space-between;
                 margin-top: 20px;
 
-                div {
+                .img-list {
                     display: inline-block;
                     width: 18%;
                     margin-right: 2%;
                     margin-bottom: 20px;
                     overflow: hidden;
-                    border: 1px solid #ddd;
+                    // border: 1px solid #ddd;
                     border-radius: 3px;
                     background: #fff;
                     position: relative;
-                    height: 45%;
-
-                    img {
+                    height: 50%;
+                    
+                   
+                    .img-content{
+                        border: 1px solid #ddd;
+                        display: flex;
+                        align-items: center;
                         width: 100%;
-                        position: absolute;
-                        top: 0;
-                        bottom: 0;
-                        margin: auto;
-                        // height: 100%;
-                    }
+                        height: 80%;
+                        text-align: center;
+                        img {
+                        // width: 100%;
+                            display: block;
+                            max-width: 100%;
+                            max-height: 100%;
+                            // position: absolute;
+                            // top: 0;
+                            // bottom: 0;
+                            margin: auto;
+                            // height: 100%;
+                        }
 
-                    .el-checkbox {
-                        position: absolute;
-                        top: 0;
-                        right: 0;
-                        display: inline-block;
-                    }
+                        .el-checkbox {
+                            position: absolute;
+                            top: 0;
+                            right: 0;
+                            display: inline-block;
+                        }
 
-                    span {}
+                        span {}
+                    }
+                    .file-name{
+                        margin-top: 5px;
+                        border: none;
+                        outline: none;
+                        width: 100%;
+                        white-space: nowrap;
+                        text-overflow: ellipsis;
+                        overflow: hidden;
+                    }
+                    
                 }
             }
         }
@@ -367,4 +492,22 @@
             cursor: pointer;
         }
     }
+    .search-list-box{
+        display: flex;
+        flex-wrap: wrap;
+        max-width: 50%;
+        .search-box{
+            width: 30%;
+            margin-right: 10px;
+            margin-bottom: 10px;
+            .search-inner-box{
+                width: 100%
+            }
+        }
+        .search-box1{
+            width: 80%;
+        }
+
+    }
+    
 </style>

+ 1 - 1
vue.config.js

@@ -37,7 +37,7 @@ module.exports = {
                         // vuex: {
                         //     name: 'vuex',
                         //     test: /[\\/]node_modules[\\/]vuex[\\/]/,
-                        //     priority: -10
+                        //     priority: -10qa
                         // },
                         // 'vue-router': {
                         //     name: 'vue-router',