diff --git a/src/views/modules/communityService/measure/index.vue b/src/views/modules/communityService/measure/index.vue index f42f18f9..ce8cd0a6 100644 --- a/src/views/modules/communityService/measure/index.vue +++ b/src/views/modules/communityService/measure/index.vue @@ -1,39 +1,35 @@ @@ -617,7 +514,7 @@ import info from "./info"; export default { components: { info }, - data() { + data () { return { tableLoading: false, btnLoading: false, @@ -879,13 +776,13 @@ export default { }, computed: { ...mapGetters(["clientHeight", "iframeHeight"]), - tableHeight() { + tableHeight () { const h = this.clientHeight - this.searchH - 280 + this.iframeHeigh; const _h = this.clientHeight - 280 - this.searchH; return this.$store.state.inIframe ? h : _h; }, }, - async created() { + async created () { this.customerId = localStorage.getItem("customerId"); this.getTableData(); @@ -897,24 +794,24 @@ export default { }, 200); this.pageLoading = true; }, - mounted() { + mounted () { this.$nextTick(() => { this.searchH = this.$refs.searchCard.$el.offsetHeight; console.log("tableHeight", this.tableHeight); }); }, methods: { - handleSizeChange(val) { + handleSizeChange (val) { console.log(`每页 ${val} 条`); this.pageSize = val; this.getTableData(); }, - handleCurrentChange(val) { + handleCurrentChange (val) { console.log(`当前页: ${val}`); this.currentPage = val; this.getTableData(); }, - handleFilterSpan(row, item) { + handleFilterSpan (row, item) { let _val = ""; if (item.options && item.options.length > 0) { item.options.forEach((n) => { @@ -923,11 +820,11 @@ export default { } return _val || row[item.columnName]; }, - filterEdit(id) { + filterEdit (id) { const { user } = this.$store.state; return id === user.agencyId; }, - resetForm(formName) { + resetForm (formName) { this.searchForm.reportStartTime = ""; this.searchForm.reportEndTime = ""; this.searchForm.wantServiceStartTime = ""; @@ -939,12 +836,12 @@ export default { this.$refs[formName].resetFields(); this.handleSearch(); }, - handleCateCHange(val) { + handleCateCHange (val) { console.log("val", val); this.searchForm.categoryCode = val[1] || val[0]; this.searchForm.level = val.length; }, - handleCateSlect(val) { + handleCateSlect (val) { console.log("val", val); if (val.length === 1) { this.demandOptions.forEach((item) => { @@ -956,14 +853,14 @@ export default { this.form.categoryCode = val[1]; } }, - handleDemandChange(val) { + handleDemandChange (val) { console.log("val", val, this.selectDemandUser); this.selectDemandUser = val.label; this.form.demandUserName = val.demandUserName; this.form.demandUserMobile = val.demandUserMobile; this.form.demandUserId = val.demandUserId; }, - handleSearch(val) { + handleSearch (val) { console.log("searchhh--", val); this.currentPage = 1; if (Array.isArray(this.reportTime) && this.reportTime.length > 0) { @@ -976,27 +873,27 @@ export default { } this.getTableData(); }, - handelBlurServiceTime(val) { + handelBlurServiceTime (val) { console.log("val", val); if (val.length > 0) { this.form.serviceStartTime = val[0]; this.form.serviceEndTime = val[1]; } }, - handleServiceChange(type, val) { + handleServiceChange (type, val) { if (val === "social_org") { if (type === "add") this.getServiceuserList(val, "add_demand"); else this.getServiceuserList(val, "query_demand"); } else this.getServiceuserList(val, ""); }, - handleGridChange(val) { + handleGridChange (val) { this.getDemandUserList(); }, - handleAdd(addType) { + handleAdd (addType) { this.addType = addType; this.dialogVisible = true; }, - handlerCancle() { + handlerCancle () { // this.form.categoryCode = '' // this.form.parentCode = '' // this.form.demandUserName = '' @@ -1012,7 +909,7 @@ export default { // this.$refs.ruleForm.resetFields() this.dialogVisible = false; }, - async formatRowForm(row, addType, disabled) { + async formatRowForm (row, addType, disabled) { this.form = { ...row, categoryCode: [row.parentCode, row.categoryCode] }; this.addType = addType; @@ -1053,16 +950,16 @@ export default { this.dialogVisible = true; }, - async handleLook(row, type) { + async handleLook (row, type) { await this.formatRowForm(row, type, true); }, - async handleAppoint(row, type) { + async handleAppoint (row, type) { await this.formatRowForm(row, type, true); }, - async handleFinish(row, type) { + async handleFinish (row, type) { await this.formatRowForm(row, type, true); }, - async handleEdit(row, type) { + async handleEdit (row, type) { await this.formatRowForm(row, type, false); // this.form = { ...row, categoryCode: [row.parentCode, row.categoryCode] } // this.addType = addType @@ -1076,12 +973,12 @@ export default { // console.log('selectDemandUser', this.selectDemandUser) // this.dialogVisible = true }, - formatRowForm2(row, type) { + formatRowForm2 (row, type) { this.visitableInfo = true; this.currDemandId = row.demandRecId; this.infoAddType = type; }, - async addNew() { + async addNew () { const _form = { ...this.form, }; @@ -1100,7 +997,7 @@ export default { }); this.btnLoading = false; }, - async appointAjax() { + async appointAjax () { const _form = { demandRecId: this.form.demandRecId, serviceType: this.form.serviceType, @@ -1121,7 +1018,7 @@ export default { }); this.btnLoading = false; }, - async finishAjax() { + async finishAjax () { const { reportType, serviceShowFlag, serviceType } = this.form; const _form = { demandRecId: this.form.demandRecId, @@ -1147,7 +1044,7 @@ export default { }); this.btnLoading = false; }, - async editCate() { + async editCate () { const categoryCode = this.form.categoryCode; if (Array.isArray(categoryCode)) { if (categoryCode.length === 1) { @@ -1180,7 +1077,7 @@ export default { }); this.btnLoading = false; }, - handleSUbmit() { + handleSUbmit () { this.$refs.ruleForm.validate(async (valid) => { if (valid) { this.btnLoading = true; @@ -1194,7 +1091,7 @@ export default { } }); }, - handleDel(row) { + handleDel (row) { let params = { demandRecId: row.demandRecId, }; @@ -1216,7 +1113,7 @@ export default { return this.$message.error("网络错误"); }); }, - getTreeData(data) { + getTreeData (data) { if (!Array.isArray(data)) return []; let arr = data.map((item) => { let _item = {}; @@ -1231,7 +1128,7 @@ export default { }); return arr; }, - getFlagData(data, flag) { + getFlagData (data, flag) { if (!Array.isArray(data)) return []; let arr1 = data.filter((item) => item[flag]); let arr2 = arr1.map((item) => { @@ -1242,7 +1139,7 @@ export default { // console.log('arrr-oppp', arr2) return arr2; }, - async getGridList(type, agencyId) { + async getGridList (type, agencyId) { const { user } = await this.$store.state; console.log("user---ppp", user); // addorupdate query @@ -1265,7 +1162,7 @@ export default { return this.$message.error("网络错误"); }); }, - async getDemandUserList() { + async getDemandUserList () { const { user } = await this.$store.state; console.log("user---ppp", user); const params = { @@ -1289,7 +1186,7 @@ export default { }); }, - async getDemandOptions() { + async getDemandOptions () { this.$http .post("/heart/icresidemanddict/demandoption") .then(({ data: res }) => { @@ -1307,7 +1204,7 @@ export default { return this.$message.error("网络错误"); }); }, - async getServiceuserList(serviceType, query) { + async getServiceuserList (serviceType, query) { if (!serviceType) return false; const { demandUserId } = this.form; const params = { @@ -1330,7 +1227,7 @@ export default { return this.$message.error("网络错误"); }); }, - async getDictOptions() { + async getDictOptions () { this.$http .post("/sys/dict/data/dictlist", { dictType: "user_demand_status" }) .then(({ data: res }) => { @@ -1373,7 +1270,7 @@ export default { return this.$message.error("网络错误"); }); }, - async getTableData() { + async getTableData () { this.tableLoading = true; let params = { ...this.searchForm, diff --git a/src/views/modules/communityService/measure/info.vue b/src/views/modules/communityService/measure/info.vue index 680b5c0d..c4e8718b 100644 --- a/src/views/modules/communityService/measure/info.vue +++ b/src/views/modules/communityService/measure/info.vue @@ -5,7 +5,8 @@ :model="form" :rules="rules" ref="ruleForm"> - @@ -202,6 +203,7 @@