Merge branch 'dev' into vite
# Conflicts: # package.json # packages/bigscreen/designer/AppDesigner.vue # packages/bigscreen/designer/components/Add.vue # packages/bigscreen/designer/components/Layout.vue # packages/bigscreen/designer/components/RenderElement.vue # packages/bigscreen/viewer/AppGigscreenViewer.vue # project/dvui/layout/AiDvPanel/AiDvPanel.vue # project/dvui/layout/AiDvWrapper/AiDvWrapper.vue
This commit is contained in:
		
							
								
								
									
										117
									
								
								packages/2.0.5/AppGridMember/AppGridMember.vue
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										117
									
								
								packages/2.0.5/AppGridMember/AppGridMember.vue
									
									
									
									
										vendored
									
									
								
							| @@ -1,117 +0,0 @@ | ||||
| <template> | ||||
|   <ai-list class="AppGridMember" v-if="!isShowDetail"> | ||||
|     <template slot="title"> | ||||
|       <ai-title title="网格员管理" :isShowBottomBorder="false"></ai-title> | ||||
|     </template> | ||||
|     <template slot="tabs"> | ||||
|       <el-tabs v-model="currIndex"> | ||||
|         <el-tab-pane v-for="(tab,i) in tabs" :key="i" :label="tab.label"> | ||||
|           <component :ref="String(i)" v-if="currIndex == i" :is="tab.comp" @change="onChange" lazy :instance="instance" :dict="dict" :permissions="permissions"/> | ||||
|         </el-tab-pane> | ||||
|       </el-tabs> | ||||
|     </template> | ||||
|   </ai-list> | ||||
|   <Add v-else-if="component === 'Add'" :params="params" :instance="instance" :dict="dict" :permissions="permissions" @change="onChange"></Add> | ||||
|   <Family v-else-if="component === 'Family'" :params="params" :instance="instance" :dict="dict" :permissions="permissions" @change="onChange"></Family> | ||||
|   <ApplyDetail v-else-if="component === 'ApplyDetail'" :params="params" :instance="instance" :dict="dict" :permissions="permissions" @change="onChange"></ApplyDetail> | ||||
|   <ApplyAdd v-else-if="component === 'ApplyAdd'" :params="params" :instance="instance" :dict="dict" :permissions="permissions" @change="onChange"></ApplyAdd> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
|   import List from './components/list' | ||||
|   import ApplyList from './components/ApplyList' | ||||
|   import Add from './components/add' | ||||
|   import ApplyDetail from './components/ApplyDetail' | ||||
|   import ApplyAdd from './components/ApplyAdd' | ||||
|   import Family from './components/Family' | ||||
|  | ||||
|   export default { | ||||
|     name: "AppGridMember", | ||||
|     label: "网格管理员", | ||||
|  | ||||
|     props: { | ||||
|       instance: Function, | ||||
|       dict: Object, | ||||
|       permissions: Function | ||||
|     }, | ||||
|  | ||||
|     data() { | ||||
|       return { | ||||
|         component: "List", | ||||
|         params: {}, | ||||
|         include: [], | ||||
|         currIndex: '0', | ||||
|         isShowDetail: false | ||||
|       }; | ||||
|     }, | ||||
|  | ||||
|       computed: { | ||||
|         tabs () { | ||||
|           const tabList = [ | ||||
|             {label: '网格员信息', name: 'List', comp: List, permission: ''}, | ||||
|             {label: '申报信息', name: 'ApplyList', comp: ApplyList, permission: 'app_appgirdmemberapply_detail'} | ||||
|           ].filter(item => { | ||||
|             return item.name !== 'ApplyList' || this.permissions(item.permission) | ||||
|           }) | ||||
|  | ||||
|           return tabList | ||||
|         } | ||||
|       }, | ||||
|  | ||||
|     components: { | ||||
|       Add, | ||||
|       List, | ||||
|       Family, | ||||
|       ApplyList, | ||||
|       ApplyDetail, | ||||
|       ApplyAdd | ||||
|     }, | ||||
|  | ||||
|     mounted() {}, | ||||
|  | ||||
|     methods: { | ||||
|       onChange(data) { | ||||
|         if (data.type === "Add") { | ||||
|           this.component = "Add" | ||||
|           this.isShowDetail = true | ||||
|           this.params = data.params | ||||
|         } | ||||
|  | ||||
|         if (data.type === "Family") { | ||||
|           this.component = "Family" | ||||
|           this.isShowDetail = true | ||||
|           this.params = data.params | ||||
|         } | ||||
|         if (data.type === "ApplyDetail") { | ||||
|           this.component = "ApplyDetail" | ||||
|           this.isShowDetail = true | ||||
|           this.params = data.params | ||||
|         } | ||||
|  | ||||
|         if (data.type === "ApplyAdd") { | ||||
|           this.component = "ApplyAdd" | ||||
|           this.isShowDetail = true | ||||
|           this.params = data.params | ||||
|         } | ||||
|  | ||||
|         if (data.type === "list") { | ||||
|           this.component = "List" | ||||
|           this.isShowDetail = false | ||||
|           this.params = data.params | ||||
|         } | ||||
|  | ||||
|         if (data.type === "ApplyList") { | ||||
|           this.component = "ApplyList" | ||||
|           this.isShowDetail = false | ||||
|           this.params = data.params | ||||
|         } | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| </script> | ||||
|  | ||||
| <style lang="scss"> | ||||
|   .AppGridMember { | ||||
|     height: 100%; | ||||
|   } | ||||
| </style> | ||||
							
								
								
									
										197
									
								
								packages/2.0.5/AppGridMember/components/list.vue
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										197
									
								
								packages/2.0.5/AppGridMember/components/list.vue
									
									
									
									
										vendored
									
									
								
							| @@ -1,197 +0,0 @@ | ||||
| <template> | ||||
|   <ai-list class="list" isTabs> | ||||
|     <template slot="content"> | ||||
|       <ai-search-bar bottomBorder> | ||||
|         <template slot="left"> | ||||
|           <el-date-picker | ||||
|             v-model="searchObj.selectionDate" | ||||
|             type="date" | ||||
|             @change="(page.current = 1), getList()" | ||||
|             value-format="yyyy-MM-dd" | ||||
|             size="small" | ||||
|             placeholder="选用时间"> | ||||
|           </el-date-picker> | ||||
|         </template> | ||||
|         <template slot="right"> | ||||
|           <el-input | ||||
|             v-model="searchObj.name" | ||||
|             size="small" | ||||
|             placeholder="网格员/责任网格" | ||||
|             v-throttle="() => {page.current = 1, getList()}" | ||||
|             @keyup.enter.native="(page.current = 1), getList()" | ||||
|             clearable | ||||
|             @clear="(searchObj.name = '', page.current = 1), getList()" | ||||
|             suffix-icon="iconfont iconSearch" /> | ||||
|         </template> | ||||
|       </ai-search-bar> | ||||
|       <ai-search-bar style="padding: 16px 0 0"> | ||||
|         <template slot="left"> | ||||
|           <el-button | ||||
|             icon="iconfont iconAdd" | ||||
|             type="primary" | ||||
|             size="small" | ||||
|             @click="add('')" | ||||
|             >添加</el-button | ||||
|           > | ||||
|           <el-button | ||||
|             icon="iconfont iconDelete" | ||||
|             @click="deleteById(ids.join(','))" | ||||
|             :disabled="!Boolean(ids.length)" | ||||
|             >删除</el-button | ||||
|           > | ||||
|         </template> | ||||
|       </ai-search-bar> | ||||
|       <ai-table | ||||
|         :tableData="tableData" | ||||
|         :col-configs="colConfigs" | ||||
|         :total="page.total" | ||||
|         ref="aitableex" | ||||
|         :current.sync="page.current" | ||||
|         :size.sync="page.size" | ||||
|         @selection-change="(v) => (ids = v.map((e) => e.id))" | ||||
|         @getList="getList()"> | ||||
|         <el-table-column label="操作" slot="options" align="center" fixed="right" width="170"> | ||||
|           <template slot-scope="{ row }"> | ||||
|             <div class="table-options"> | ||||
|               <el-button type="text" @click="toFamily(row.id)">责任家庭</el-button> | ||||
|               <el-button type="text" @click="add(row.id)">详情</el-button> | ||||
|               <el-button type="text" @click="deleteById(row.id)">删除</el-button> | ||||
|             </div> | ||||
|           </template> | ||||
|         </el-table-column> | ||||
|       </ai-table> | ||||
|     </template> | ||||
|   </ai-list> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| export default { | ||||
|   name: "List", | ||||
|   label: "网格员管理", | ||||
|   props: { | ||||
|     instance: Function, | ||||
|     dict: Object, | ||||
|     permissions: Function, | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       searchObj: { | ||||
|         name: "", | ||||
|         selectionDate: "", | ||||
|       }, | ||||
|       page: { | ||||
|         current: 1, | ||||
|         size: 10, | ||||
|         total: 0, | ||||
|       }, | ||||
|       goAdd: false, | ||||
|       tableData: [], | ||||
|       fileList: [], | ||||
|       ids: [], | ||||
|       detail: {}, | ||||
|     }; | ||||
|   }, | ||||
|   created() { | ||||
|     this.dict.load("sex", "girdMemberType", "politicsStatus", "education"); | ||||
|     this.getList(); | ||||
|   }, | ||||
|   computed: { | ||||
|     colConfigs() { | ||||
|       let _ = this; | ||||
|       return [ | ||||
|         { | ||||
|           type: "selection", | ||||
|         }, | ||||
|         { | ||||
|           prop: "name", | ||||
|           label: "网格员姓名", | ||||
|         }, | ||||
|         { | ||||
|           prop: "girdInfoListStr", | ||||
|           align: "center", | ||||
|           label: "责任网格", | ||||
|         }, | ||||
|         { | ||||
|           prop: "phone", | ||||
|           align: "center", | ||||
|           label: "联系电话", | ||||
|         }, | ||||
|         { | ||||
|           prop: "selectionDate", | ||||
|           align: "center", | ||||
|           label: "选用时间", | ||||
|         }, | ||||
|       ]; | ||||
|     }, | ||||
|   }, | ||||
|   methods: { | ||||
|     getList() { | ||||
|       this.instance | ||||
|         .post("/app/appgirdmemberinfo/list", null, { | ||||
|           params: { | ||||
|             ...this.searchObj, | ||||
|             ...this.page, | ||||
|           }, | ||||
|         }) | ||||
|         .then((res) => { | ||||
|           if (res.code == 0) { | ||||
|             this.tableData = res.data.records; | ||||
|             this.page.total = res.data.total; | ||||
|           } | ||||
|         }); | ||||
|     }, | ||||
|     deleteById(ids) { | ||||
|       ids && | ||||
|         this.$confirm("是否要删除该网格员?", { | ||||
|           type: "error", | ||||
|         }) | ||||
|           .then(() => { | ||||
|             this.instance | ||||
|               .post("/app/appgirdmemberinfo/delete", null, { | ||||
|                 params: { ids }, | ||||
|               }) | ||||
|               .then((res) => { | ||||
|                 if (res?.code == 0) { | ||||
|                   this.$message.success("删除成功!"); | ||||
|                   this.getList(); | ||||
|                 } | ||||
|               }); | ||||
|           }) | ||||
|           .catch(() => {}); | ||||
|     }, | ||||
|     add(id) { | ||||
|       this.$emit('change', { | ||||
|         type: 'Add', | ||||
|         params: { | ||||
|           id: id || '' | ||||
|         } | ||||
|       }) | ||||
|     }, | ||||
|  | ||||
|     toFamily (id) { | ||||
|       this.$emit('change', { | ||||
|         type: 'Family', | ||||
|         params: { | ||||
|           id | ||||
|         } | ||||
|       }) | ||||
|     }, | ||||
|  | ||||
|     handleSelectionChange(val) { | ||||
|       this.ids = []; | ||||
|       val.map((e) => { | ||||
|         this.ids.push(e.id); | ||||
|       }); | ||||
|     }, | ||||
|     resetSearch() { | ||||
|       Object.keys(this.searchObj).map((e) => { | ||||
|         this.searchObj[e] = ""; | ||||
|       }); | ||||
|       this.getList(); | ||||
|     }, | ||||
|   }, | ||||
| }; | ||||
| </script> | ||||
|  | ||||
| <style lang="scss" scoped> | ||||
| </style> | ||||
							
								
								
									
										131
									
								
								packages/grid/AppGridMember/AppGridMember.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										131
									
								
								packages/grid/AppGridMember/AppGridMember.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,131 @@ | ||||
| <template> | ||||
|   <ai-list class="AppGridMember" v-if="!isShowDetail"> | ||||
|     <template slot="title"> | ||||
|       <ai-title title="网格员管理" :isShowBottomBorder="false"></ai-title> | ||||
|     </template> | ||||
|     <template slot="tabs"> | ||||
|       <el-tabs v-model="currIndex"> | ||||
|         <el-tab-pane v-for="(tab,i) in tabs" :key="i" :label="tab.label"> | ||||
|           <component :ref="String(i)" v-if="currIndex == i" :is="tab.comp" @change="onChange" lazy :instance="instance" | ||||
|                      :dict="dict" :permissions="permissions"/> | ||||
|         </el-tab-pane> | ||||
|       </el-tabs> | ||||
|     </template> | ||||
|   </ai-list> | ||||
|   <Add v-else-if="component === 'Add'" :params="params" :instance="instance" :dict="dict" :permissions="permissions" | ||||
|        @change="onChange"></Add> | ||||
|   <Family v-else-if="component === 'Family'" :params="params" :instance="instance" :dict="dict" | ||||
|           :permissions="permissions" @change="onChange"></Family> | ||||
|   <MonitorUser v-else-if="component === 'MonitorUser'" :params="params" :instance="instance" :dict="dict" | ||||
|                :permissions="permissions" @change="onChange"></MonitorUser> | ||||
|   <ApplyDetail v-else-if="component === 'ApplyDetail'" :params="params" :instance="instance" :dict="dict" | ||||
|                :permissions="permissions" @change="onChange"></ApplyDetail> | ||||
|   <ApplyAdd v-else-if="component === 'ApplyAdd'" :params="params" :instance="instance" :dict="dict" | ||||
|             :permissions="permissions" @change="onChange"></ApplyAdd> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import List from './components/list' | ||||
| import ApplyList from './components/ApplyList' | ||||
| import Add from './components/add' | ||||
| import ApplyDetail from './components/ApplyDetail' | ||||
| import ApplyAdd from './components/ApplyAdd' | ||||
| import Family from './components/Family' | ||||
| import MonitorUser from './components/MonitorUser' | ||||
|  | ||||
| export default { | ||||
|   name: "AppGridMember", | ||||
|   label: "网格管理员", | ||||
|  | ||||
|   props: { | ||||
|     instance: Function, | ||||
|     dict: Object, | ||||
|     permissions: Function | ||||
|   }, | ||||
|  | ||||
|   data() { | ||||
|     return { | ||||
|       component: "List", | ||||
|       params: {}, | ||||
|       include: [], | ||||
|       currIndex: '0', | ||||
|       isShowDetail: false | ||||
|     }; | ||||
|   }, | ||||
|  | ||||
|   computed: { | ||||
|     tabs() { | ||||
|       return [ | ||||
|         {label: '网格员信息', name: 'List', comp: List, permission: ''}, | ||||
|         {label: '申报信息', name: 'ApplyList', comp: ApplyList, permission: 'app_appgirdmemberapply_detail'} | ||||
|       ].filter(item => { | ||||
|         return item.name !== 'ApplyList' || this.permissions(item.permission) | ||||
|       }) | ||||
|     } | ||||
|   }, | ||||
|  | ||||
|   components: { | ||||
|     Add, | ||||
|     List, | ||||
|     Family, | ||||
|     ApplyList, | ||||
|     ApplyDetail, | ||||
|     MonitorUser, | ||||
|     ApplyAdd | ||||
|   }, | ||||
|  | ||||
|   mounted() { | ||||
|   }, | ||||
|  | ||||
|   methods: { | ||||
|     onChange(data) { | ||||
|       if (data.type === "Add") { | ||||
|         this.component = "Add" | ||||
|         this.isShowDetail = true | ||||
|         this.params = data.params | ||||
|       } | ||||
|  | ||||
|       if (data.type === "Family") { | ||||
|         this.component = "Family" | ||||
|         this.isShowDetail = true | ||||
|         this.params = data.params | ||||
|       } | ||||
|  | ||||
|       if (data.type === "MonitorUser") { | ||||
|         this.component = "MonitorUser" | ||||
|         this.isShowDetail = true | ||||
|         this.params = data.params | ||||
|       } | ||||
|       if (data.type === "ApplyDetail") { | ||||
|         this.component = "ApplyDetail" | ||||
|         this.isShowDetail = true | ||||
|         this.params = data.params | ||||
|       } | ||||
|  | ||||
|       if (data.type === "ApplyAdd") { | ||||
|         this.component = "ApplyAdd" | ||||
|         this.isShowDetail = true | ||||
|         this.params = data.params | ||||
|       } | ||||
|  | ||||
|       if (data.type === "list") { | ||||
|         this.component = "List" | ||||
|         this.isShowDetail = false | ||||
|         this.params = data.params | ||||
|       } | ||||
|  | ||||
|       if (data.type === "ApplyList") { | ||||
|         this.component = "ApplyList" | ||||
|         this.isShowDetail = false | ||||
|         this.params = data.params | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style lang="scss"> | ||||
| .AppGridMember { | ||||
|   height: 100%; | ||||
| } | ||||
| </style> | ||||
| @@ -44,7 +44,7 @@ | ||||
|         <el-table-column slot="options" width="100px" fixed="right" label="操作" align="center"> | ||||
|           <template slot-scope="{ row }"> | ||||
|             <div class="table-options"> | ||||
|               <el-button type="text" @click="remove(row.gmrId)">删除</el-button> | ||||
|               <el-button type="text" @click="remove(row.gmpId)">删除</el-button> | ||||
|             </div> | ||||
|           </template> | ||||
|         </el-table-column> | ||||
| @@ -286,9 +286,11 @@ export default { | ||||
|       }) | ||||
|     }, | ||||
| 
 | ||||
|     remove(id) { | ||||
|     remove(ids) { | ||||
|       this.$confirm('确定删除该数据?').then(() => { | ||||
|         this.instance.post(`/app/appgirdmemberresident/delete?ids=${id}`).then(res => { | ||||
|         this.instance.post(`/app/appgirdmemberpoverty/delete`, null, { | ||||
|           params: {ids} | ||||
|         }).then(res => { | ||||
|           if (res.code == 0) { | ||||
|             this.$message.success('删除成功!') | ||||
|             this.getList() | ||||
| @@ -53,7 +53,7 @@ | ||||
|           <template slot-scope="{ row }"> | ||||
|             <div class="table-options"> | ||||
|               <el-button type="text" @click="toFamily(row.id)">责任家庭</el-button> | ||||
|               <el-button type="text" @click="toMonitorUser(row.id)">监测对象</el-button> | ||||
|               <el-button type="text" @click="toMonitorUser(row.id)" v-if="permissions('girdmemberpovertyconfig')">监测对象</el-button> | ||||
|               <el-button type="text" @click="add(row.id)">详情</el-button> | ||||
|               <el-button type="text" @click="deleteById(row.id)">删除</el-button> | ||||
|             </div> | ||||
| @@ -203,4 +203,4 @@ export default { | ||||
| </script> | ||||
| 
 | ||||
| <style lang="scss" scoped> | ||||
| </style> | ||||
| </style> | ||||
| @@ -1,126 +0,0 @@ | ||||
| <template> | ||||
|   <ai-list class="AppGridMember" v-if="!isShowDetail"> | ||||
|     <template slot="title"> | ||||
|       <ai-title title="网格员管理" :isShowBottomBorder="false"></ai-title> | ||||
|     </template> | ||||
|     <template slot="tabs"> | ||||
|       <el-tabs v-model="currIndex"> | ||||
|         <el-tab-pane v-for="(tab,i) in tabs" :key="i" :label="tab.label"> | ||||
|           <component :ref="String(i)" v-if="currIndex == i" :is="tab.comp" @change="onChange" lazy :instance="instance" :dict="dict" :permissions="permissions"/> | ||||
|         </el-tab-pane> | ||||
|       </el-tabs> | ||||
|     </template> | ||||
|   </ai-list> | ||||
|   <Add v-else-if="component === 'Add'" :params="params" :instance="instance" :dict="dict" :permissions="permissions" @change="onChange"></Add> | ||||
|   <Family v-else-if="component === 'Family'" :params="params" :instance="instance" :dict="dict" :permissions="permissions" @change="onChange"></Family> | ||||
|   <MonitorUser v-else-if="component === 'MonitorUser'" :params="params" :instance="instance" :dict="dict" :permissions="permissions" @change="onChange"></MonitorUser> | ||||
|   <ApplyDetail v-else-if="component === 'ApplyDetail'" :params="params" :instance="instance" :dict="dict" :permissions="permissions" @change="onChange"></ApplyDetail> | ||||
|   <ApplyAdd v-else-if="component === 'ApplyAdd'" :params="params" :instance="instance" :dict="dict" :permissions="permissions" @change="onChange"></ApplyAdd> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
|   import List from './components/list' | ||||
|   import ApplyList from './components/ApplyList' | ||||
|   import Add from './components/add' | ||||
|   import ApplyDetail from './components/ApplyDetail' | ||||
|   import ApplyAdd from './components/ApplyAdd' | ||||
|   import Family from './components/Family' | ||||
|   import MonitorUser from './components/MonitorUser' | ||||
|  | ||||
|   export default { | ||||
|     name: "AppGridMemberJp", | ||||
|     label: "网格管理员(防返贫)", | ||||
|  | ||||
|     props: { | ||||
|       instance: Function, | ||||
|       dict: Object, | ||||
|       permissions: Function | ||||
|     }, | ||||
|  | ||||
|     data() { | ||||
|       return { | ||||
|         component: "List", | ||||
|         params: {}, | ||||
|         include: [], | ||||
|         currIndex: '0', | ||||
|         isShowDetail: false | ||||
|       }; | ||||
|     }, | ||||
|  | ||||
|       computed: { | ||||
|         tabs () { | ||||
|           const tabList = [ | ||||
|             {label: '网格员信息', name: 'List', comp: List, permission: ''}, | ||||
|             {label: '申报信息', name: 'ApplyList', comp: ApplyList, permission: 'app_appgirdmemberapply_detail'} | ||||
|           ].filter(item => { | ||||
|             return item.name !== 'ApplyList' || this.permissions(item.permission) | ||||
|           }) | ||||
|  | ||||
|           return tabList | ||||
|         } | ||||
|       }, | ||||
|  | ||||
|     components: { | ||||
|       Add, | ||||
|       List, | ||||
|       Family, | ||||
|       ApplyList, | ||||
|       ApplyDetail, | ||||
|       MonitorUser, | ||||
|       ApplyAdd | ||||
|     }, | ||||
|  | ||||
|     mounted() {}, | ||||
|  | ||||
|     methods: { | ||||
|       onChange(data) { | ||||
|         if (data.type === "Add") { | ||||
|           this.component = "Add" | ||||
|           this.isShowDetail = true | ||||
|           this.params = data.params | ||||
|         } | ||||
|  | ||||
|         if (data.type === "Family") { | ||||
|           this.component = "Family" | ||||
|           this.isShowDetail = true | ||||
|           this.params = data.params | ||||
|         } | ||||
|  | ||||
|         if (data.type === "MonitorUser") { | ||||
|           this.component = "MonitorUser" | ||||
|           this.isShowDetail = true | ||||
|           this.params = data.params | ||||
|         } | ||||
|         if (data.type === "ApplyDetail") { | ||||
|           this.component = "ApplyDetail" | ||||
|           this.isShowDetail = true | ||||
|           this.params = data.params | ||||
|         } | ||||
|  | ||||
|         if (data.type === "ApplyAdd") { | ||||
|           this.component = "ApplyAdd" | ||||
|           this.isShowDetail = true | ||||
|           this.params = data.params | ||||
|         } | ||||
|  | ||||
|         if (data.type === "list") { | ||||
|           this.component = "List" | ||||
|           this.isShowDetail = false | ||||
|           this.params = data.params | ||||
|         } | ||||
|  | ||||
|         if (data.type === "ApplyList") { | ||||
|           this.component = "ApplyList" | ||||
|           this.isShowDetail = false | ||||
|           this.params = data.params | ||||
|         } | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| </script> | ||||
|  | ||||
| <style lang="scss"> | ||||
|   .AppGridMember { | ||||
|     height: 100%; | ||||
|   } | ||||
| </style> | ||||
| @@ -1,107 +0,0 @@ | ||||
| <template> | ||||
|   <ai-detail class="content-add"> | ||||
|     <template slot="title"> | ||||
|       <ai-title :title="params.id ? '编辑' : '添加'" isShowBack isShowBottomBorder @onBackClick="cancel(false)"> | ||||
|       </ai-title> | ||||
|     </template> | ||||
|     <template slot="content"> | ||||
|       <ai-card title="基本信息"> | ||||
|         <template #content> | ||||
|           <el-form class="ai-form" :model="form" label-width="120px" ref="form"> | ||||
|             <el-form-item label="姓名" style="width: 100%;" prop="name" :rules="[{required: true, message: '请输入姓名', trigger: 'blur'}]"> | ||||
|               <el-input size="small" v-model="form.name" placeholder="请输入..." :maxlength="20"></el-input> | ||||
|             </el-form-item> | ||||
|             <el-form-item label="联系电话" style="width: 100%;" prop="phone" :rules="[{required: true, message: '请输入联系电话', trigger: 'blur'}]"> | ||||
|               <el-input size="small" v-model="form.phone" placeholder="请输入..." :maxlength="11"></el-input> | ||||
|             </el-form-item> | ||||
|             <el-form-item label="网格名称" style="width: 100%;" prop="girdName" :rules="[{required: true, message: '请输入网格名称', trigger: 'blur'}]"> | ||||
|               <el-input size="small" v-model="form.girdName" placeholder="请输入..." :maxlength="50"></el-input> | ||||
|             </el-form-item> | ||||
|           </el-form> | ||||
|         </template> | ||||
|       </ai-card> | ||||
|     </template> | ||||
|     <template #footer> | ||||
|       <el-button @click="cancel">取消</el-button> | ||||
|       <el-button type="primary" :loading="isLoading" @click="confirm">提交</el-button> | ||||
|     </template> | ||||
|   </ai-detail> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
|   export default { | ||||
|     name: 'ApplyAdd', | ||||
|  | ||||
|     props: { | ||||
|       instance: Function, | ||||
|       dict: Object, | ||||
|       params: Object | ||||
|     }, | ||||
|  | ||||
|     data () { | ||||
|       return { | ||||
|         form: { | ||||
|           name: '', | ||||
|           phone: '', | ||||
|           gridName: '' | ||||
|         }, | ||||
|         isLoading: false, | ||||
|         id: '' | ||||
|       } | ||||
|     }, | ||||
|  | ||||
|     created () { | ||||
|       if (this.params && this.params.id) { | ||||
|         this.id = this.params.id | ||||
|         this.getInfo(this.params.id) | ||||
|       } | ||||
|     }, | ||||
|  | ||||
|     methods: { | ||||
|       getInfo (id) { | ||||
|         this.instance.post(`/app/appcontentinfo/queryDetailById?id=${id}`).then(res => { | ||||
|           if (res.code === 0) { | ||||
|             this.form = res.data | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       onChange () { | ||||
|         this.form.files = [] | ||||
|       }, | ||||
|  | ||||
|       confirm () { | ||||
|         this.$refs.form.validate((valid) => { | ||||
|           if (valid) { | ||||
|             this.isLoading = true | ||||
|             this.instance.post(`/app/appgirdmemberapply/addOrUpdate`, { | ||||
|               ...this.form, | ||||
|               id: this.params.id || '' | ||||
|             }).then(res => { | ||||
|               if (res.code == 0) { | ||||
|                 this.$message.success('提交成功') | ||||
|                 setTimeout(() => { | ||||
|                   this.cancel(true) | ||||
|                 }, 600) | ||||
|               } else { | ||||
|                 this.isLoading = false | ||||
|               } | ||||
|             }).catch(() => { | ||||
|               this.isLoading = false | ||||
|             }) | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       cancel (isRefresh) { | ||||
|         this.$emit('change', { | ||||
|           type: 'list', | ||||
|           isRefresh: !!isRefresh | ||||
|         }) | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| </script> | ||||
|  | ||||
| <style scoped lang="scss"> | ||||
| </style> | ||||
| @@ -1,65 +0,0 @@ | ||||
| <template> | ||||
|   <ai-detail> | ||||
|     <template slot="title"> | ||||
|       <ai-title title="详情" isShowBack isShowBottomBorder @onBackClick="cancel(false)"> | ||||
|       </ai-title> | ||||
|     </template> | ||||
|     <template slot="content"> | ||||
|       <ai-card title="基本信息"> | ||||
|         <template #content> | ||||
|           <ai-wrapper> | ||||
|             <ai-info-item label="姓名" isLine :value="info.name"></ai-info-item> | ||||
|             <ai-info-item label="联系电话" isLine :value="info.phone"></ai-info-item> | ||||
|             <ai-info-item label="网格名称" isLine :value="info.girdName"></ai-info-item> | ||||
|           </ai-wrapper> | ||||
|         </template> | ||||
|       </ai-card> | ||||
|     </template> | ||||
|   </ai-detail> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
|   export default { | ||||
|     name: 'ApplyDetail', | ||||
|  | ||||
|     props: { | ||||
|       instance: Function, | ||||
|       dict: Object, | ||||
|       params: Object | ||||
|     }, | ||||
|  | ||||
|     data () { | ||||
|       return { | ||||
|         info: {}, | ||||
|         id: '' | ||||
|       } | ||||
|     }, | ||||
|  | ||||
|     created () { | ||||
|       if (this.params && this.params.id) { | ||||
|         this.id = this.params.id | ||||
|         this.getInfo(this.params.id) | ||||
|       } | ||||
|     }, | ||||
|  | ||||
|     methods: { | ||||
|       getInfo (id) { | ||||
|         this.instance.post(`/app/appgirdmemberapply/queryDetailById?id=${id}`).then(res => { | ||||
|           if (res.code === 0) { | ||||
|             this.info = res.data | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       cancel (isRefresh) { | ||||
|         this.$emit('change', { | ||||
|           type: 'ApplyList', | ||||
|           isRefresh: !!isRefresh | ||||
|         }) | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| </script> | ||||
|  | ||||
| <style scoped lang="scss"> | ||||
| </style> | ||||
| @@ -1,179 +0,0 @@ | ||||
| <template> | ||||
|   <ai-list class="list" isTabs> | ||||
|     <template slot="content"> | ||||
|       <ai-search-bar bottomBorder> | ||||
|         <template slot="left"> | ||||
|           <el-button | ||||
|             icon="iconfont iconAdd" | ||||
|             type="primary" | ||||
|             size="small" | ||||
|             @click="add('')">添加</el-button> | ||||
|           <el-button | ||||
|             icon="iconfont iconDelete" | ||||
|             @click="deleteById(ids.join(','))" | ||||
|             :disabled="!Boolean(ids.length)"> | ||||
|             删除 | ||||
|           </el-button> | ||||
|           <ai-import :instance="instance" :dict="dict" type="appgirdmemberapply" name="网格员申报" @success="getList()"> | ||||
|             <el-button icon="iconfont iconImport">导入</el-button> | ||||
|           </ai-import> | ||||
|         </template> | ||||
|         <template slot="right"> | ||||
|           <el-input | ||||
|             v-model="searchObj.name" | ||||
|             size="small" | ||||
|             placeholder="网格员/责任网格" | ||||
|             @keyup.enter.native="(page.current = 1), getList()" | ||||
|             clearable | ||||
|             @clear="(searchObj.name = '', page.current = 1), getList()" | ||||
|             suffix-icon="iconfont iconSearch" /> | ||||
|         </template> | ||||
|       </ai-search-bar> | ||||
|       <ai-table | ||||
|         :tableData="tableData" | ||||
|         :col-configs="colConfigs" | ||||
|         :total="page.total" | ||||
|         ref="aitableex" | ||||
|         :current.sync="page.current" | ||||
|         :size.sync="page.size" | ||||
|         @selection-change="(v) => (ids = v.map((e) => e.id))" | ||||
|         @getList="getList()"> | ||||
|         <el-table-column label="操作" slot="options" align="center" fixed="right" width="120"> | ||||
|           <template slot-scope="{ row }"> | ||||
|             <div class="table-options"> | ||||
|               <el-button type="text" @click="toDetail(row.id)">详情</el-button> | ||||
|               <el-button type="text" @click="deleteById(row.id)">删除</el-button> | ||||
|             </div> | ||||
|           </template> | ||||
|         </el-table-column> | ||||
|       </ai-table> | ||||
|     </template> | ||||
|   </ai-list> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
|   export default { | ||||
|     name: 'ApplyList', | ||||
|     label: '网格员管理', | ||||
|     props: { | ||||
|       instance: Function, | ||||
|       dict: Object, | ||||
|       permissions: Function, | ||||
|     }, | ||||
|     data() { | ||||
|       return { | ||||
|         searchObj: { | ||||
|           name: "", | ||||
|           selectionDate: "", | ||||
|         }, | ||||
|         page: { | ||||
|           current: 1, | ||||
|           size: 10, | ||||
|           total: 0, | ||||
|         }, | ||||
|         goAdd: false, | ||||
|         tableData: [], | ||||
|         fileList: [], | ||||
|         ids: [], | ||||
|         detail: {}, | ||||
|       }; | ||||
|     }, | ||||
|     created() { | ||||
|       this.dict.load("sex", "girdMemberType", "politicsStatus", "education"); | ||||
|       this.getList(); | ||||
|     }, | ||||
|     computed: { | ||||
|       colConfigs() { | ||||
|         let _ = this; | ||||
|         return [ | ||||
|           { | ||||
|             type: "selection", | ||||
|           }, | ||||
|           { | ||||
|             prop: "name", | ||||
|             label: "网格员姓名", | ||||
|           }, | ||||
|           { | ||||
|             prop: "girdName", | ||||
|             align: "left", | ||||
|             label: "责任网格", | ||||
|           }, | ||||
|           { | ||||
|             prop: "phone", | ||||
|             align: "center", | ||||
|             label: "联系电话", | ||||
|           } | ||||
|         ]; | ||||
|       }, | ||||
|     }, | ||||
|     methods: { | ||||
|       getList() { | ||||
|         this.instance | ||||
|           .post("/app/appgirdmemberapply/list", null, { | ||||
|             params: { | ||||
|               ...this.searchObj, | ||||
|               ...this.page, | ||||
|             }, | ||||
|           }) | ||||
|           .then((res) => { | ||||
|             if (res.code == 0) { | ||||
|               this.tableData = res.data.records; | ||||
|               this.page.total = res.data.total; | ||||
|             } | ||||
|           }); | ||||
|       }, | ||||
|       deleteById(ids) { | ||||
|         ids && | ||||
|           this.$confirm("是否要删除该网格员?", { | ||||
|             type: "error", | ||||
|           }) | ||||
|             .then(() => { | ||||
|               this.instance | ||||
|                 .post("/app/appgirdmemberapply/delete", null, { | ||||
|                   params: { ids }, | ||||
|                 }) | ||||
|                 .then((res) => { | ||||
|                   if (res?.code == 0) { | ||||
|                     this.$message.success("删除成功!"); | ||||
|                     this.getList(); | ||||
|                   } | ||||
|                 }); | ||||
|             }) | ||||
|             .catch(() => {}); | ||||
|       }, | ||||
|       add (id) { | ||||
|         this.$emit('change', { | ||||
|           type: 'ApplyAdd', | ||||
|           params: { | ||||
|             id: id || '' | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       toDetail (id) { | ||||
|         this.$emit('change', { | ||||
|           type: 'ApplyDetail', | ||||
|           params: { | ||||
|             id | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       handleSelectionChange(val) { | ||||
|         this.ids = []; | ||||
|         val.map((e) => { | ||||
|           this.ids.push(e.id); | ||||
|         }); | ||||
|       }, | ||||
|       resetSearch() { | ||||
|         Object.keys(this.searchObj).map((e) => { | ||||
|           this.searchObj[e] = ""; | ||||
|         }); | ||||
|         this.getList(); | ||||
|       }, | ||||
|     }, | ||||
|   } | ||||
| </script> | ||||
|  | ||||
| <style lang="scss" scoped> | ||||
| </style> | ||||
| @@ -1,499 +0,0 @@ | ||||
| <template> | ||||
|   <ai-list class="Family"> | ||||
|     <template slot="title"> | ||||
|       <ai-title title="责任家庭" isShowBack isShowBottomBorder @onBackClick="onBack"></ai-title> | ||||
|     </template> | ||||
|     <template slot="content"> | ||||
|       <ai-search-bar class="search-bar"> | ||||
|         <template #left> | ||||
|           <el-button size="small" type="primary" icon="iconfont iconAdd" @click="isShow = true">添加</el-button> | ||||
|           <el-button size="small" :disabled="!ids.length" icon="iconfont iconDelete" @click="removeAll">批量删除</el-button> | ||||
|           <el-select size="small" style="width: 200px;" v-model="search.girdId" placeholder="所属网格" clearable @change="getListInit()"> | ||||
|             <el-option | ||||
|               v-for="(item,i) in girdList" | ||||
|               :key="i" | ||||
|               :label="item.girdName" | ||||
|               :value="item.id" | ||||
|             > | ||||
|             </el-option> | ||||
|           </el-select> | ||||
|         </template> | ||||
|         <template #right> | ||||
|           <el-input | ||||
|             v-model="search.name" | ||||
|             class="search-input" | ||||
|             size="small" | ||||
|             v-throttle="() => {search.current = 1, getList()}" | ||||
|             placeholder="姓名/身份证/联系方式" | ||||
|             clearable | ||||
|             @clear="search.current = 1, search.name = '', getList()" | ||||
|             suffix-icon="iconfont iconSearch"> | ||||
|           </el-input> | ||||
|         </template> | ||||
|       </ai-search-bar> | ||||
|       <ai-table | ||||
|         :tableData="tableData" | ||||
|         :col-configs="colConfigs" | ||||
|         :total="total" | ||||
|         style="margin-top: 6px;" | ||||
|         :current.sync="search.current" | ||||
|         :size.sync="search.size" | ||||
|         @handleSelectionChange="handleSelectionChange" | ||||
|         @getList="getList"> | ||||
|         <el-table-column slot="options" width="100px" fixed="right" label="操作" align="center"> | ||||
|           <template slot-scope="{ row }"> | ||||
|             <div class="table-options"> | ||||
|               <el-button type="text" @click="remove(row.gmrId)">删除</el-button> | ||||
|             </div> | ||||
|           </template> | ||||
|         </el-table-column> | ||||
|       </ai-table> | ||||
|       <ai-dialog | ||||
|         :visible.sync="isShow" | ||||
|         width="890px" | ||||
|         @close="closeDialog" | ||||
|         title="添加户主" | ||||
|         @onConfirm="onConfirm"> | ||||
|         <ai-area-select clearable always-show :instance="instance"  v-model="areaId" :disabled-level="disabledLevel" @change="search.current = 1, getUserList()"></ai-area-select> | ||||
|         <span style="margin-top:16px;"><span style="color:#f46;margin-right:4px;">*</span>网格:</span> | ||||
|         <el-select size="small" style="width: 280px;margin-top:16px;" v-model="girdId" placeholder="请选择网格" clearable> | ||||
|           <el-option | ||||
|             v-for="(item,i) in girdList" | ||||
|             :key="i" | ||||
|             :label="item.girdName" | ||||
|             :value="item.id" | ||||
|           > | ||||
|           </el-option> | ||||
|         </el-select> | ||||
|         <div class="AiWechatSelecter-container"> | ||||
|           <div class="AiWechatSelecter-container__left" v-loading="isLoading"> | ||||
|             <div class="AiWechatSelecter-header"> | ||||
|               <div class="AiWechatSelecter-header__left"> | ||||
|                 <h2>户主信息列表</h2> | ||||
|               </div> | ||||
|               <el-input | ||||
|                 class="search-input" | ||||
|                 size="mini" | ||||
|                 placeholder="请输入姓名/身份证号" | ||||
|                 v-model="name" | ||||
|                 clearable | ||||
|                 @keyup.enter.native="getUserList()" | ||||
|                 @clear="name = '', getUserList()" | ||||
|                 suffix-icon="iconfont iconSearch"> | ||||
|               </el-input> | ||||
|             </div> | ||||
|             <el-scrollbar class="AiWechatSelecter-list"> | ||||
|               <el-checkbox-group v-model="chooseUser"> | ||||
|                 <el-checkbox | ||||
|                   :label="`${item.name}~${item.id}`" | ||||
|                   v-for="(item, index) in userList" | ||||
|                   :key="index"> | ||||
|                   {{ item.name }}-{{ item.idNumber }} | ||||
|                 </el-checkbox> | ||||
|               </el-checkbox-group> | ||||
|               <AiEmpty v-if="!this.userList.length"></AiEmpty> | ||||
|             </el-scrollbar> | ||||
|           </div> | ||||
|           <div class="AiWechatSelecter-container__right"> | ||||
|             <div class="AiWechatSelecter-header AiWechatSelecter-header__right"> | ||||
|               <h2>已选择</h2> | ||||
|               <el-button size="mini" icon="el-icon-delete" @click="clearAll">清空</el-button> | ||||
|             </div> | ||||
|             <el-scrollbar class="AiWechatSelecter-list"> | ||||
|               <div class="tags-wrapper"> | ||||
|                 <el-tag | ||||
|                   v-for="(item, index) in chooseUser" | ||||
|                   :key="index" | ||||
|                   closable | ||||
|                   @close="del(item)" | ||||
|                   size="small" | ||||
|                   type="info"> | ||||
|                   {{ item.split('~')[0] }} | ||||
|                 </el-tag> | ||||
|               </div> | ||||
|             </el-scrollbar> | ||||
|           </div> | ||||
|         </div> | ||||
|       </ai-dialog> | ||||
|     </template> | ||||
|   </ai-list> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
|   import { mapState } from 'vuex' | ||||
|   export default { | ||||
|     name: 'Family', | ||||
|  | ||||
|     props: { | ||||
|       instance: Function, | ||||
|       dict: Object, | ||||
|       params: Object | ||||
|     }, | ||||
|  | ||||
|     data() { | ||||
|       return { | ||||
|         search: { | ||||
|           current: 1, | ||||
|           size: 10, | ||||
|           name: '', | ||||
|           girdId: '' | ||||
|         }, | ||||
|         isLoading: false, | ||||
|         form: { | ||||
|  | ||||
|         }, | ||||
|         userList: [], | ||||
|         name: '', | ||||
|         chooseUser: [], | ||||
|         isShow: false, | ||||
|         total: 10, | ||||
|         colConfigs: [ | ||||
|           { type: 'selection', label: '' }, | ||||
|           { prop: 'name',  label: '户主姓名', align: 'left', width: '200px' }, | ||||
|           { prop: 'idNumber', label: '身份证号', align: 'center' }, | ||||
|           { prop: 'phone', label: '联系方式', align: 'center' }, | ||||
|           { prop: 'girdName', label: '所属网格', align: 'center' }, | ||||
|           { prop: 'createTime', label: '添加时间', align: 'center' }, | ||||
|           { slot: 'options', label: '操作', align: 'center' } | ||||
|         ], | ||||
|         tableData: [], | ||||
|         areaId: '', | ||||
|         ids: [], | ||||
|         disabledLevel: 0, | ||||
|         girdList: [], | ||||
|         girdId: '', | ||||
|       } | ||||
|     }, | ||||
|  | ||||
|     computed: { | ||||
|       ...mapState(['user']) | ||||
|     }, | ||||
|  | ||||
|     created() { | ||||
|       this.areaId = this.user.info.areaId | ||||
|       this.disabledLevel = this.user.info.areaList.length | ||||
|       this.dict.load('epidemicDangerousAreaLevel').then(() => { | ||||
|         this.getGirdList() | ||||
|         this.getList() | ||||
|         this.getUserList() | ||||
|       }) | ||||
|     }, | ||||
|  | ||||
|     methods: { | ||||
|       getGirdList() { | ||||
|         this.instance.post(`/app/appgirdmemberinfo/queryMyGirdListByLevel2?girdMemberId=${this.params.id}`).then(res => { | ||||
|           if (res.code == 0) { | ||||
|             this.girdList = res.data | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|       getListInit() { | ||||
|         this.search.current = 1 | ||||
|         this.getList() | ||||
|       }, | ||||
|       getList () { | ||||
|         this.instance.post(`/app/appgirdmemberresident/listByGirdMember`, null, { | ||||
|           params: { | ||||
|             ...this.search, | ||||
|             girdMemberId: this.params.id, | ||||
|             areaId: this.areaId | ||||
|           } | ||||
|         }).then(res => { | ||||
|           if (res.code == 0) { | ||||
|             this.tableData = res.data.records | ||||
|             this.total = res.data.total | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|     removeAll() { | ||||
|         if (!this.ids) { | ||||
|           return this.$message.error('请选择户主') | ||||
|         } | ||||
|         this.remove(this.ids.join(',')) | ||||
|       }, | ||||
|       handleSelectionChange(e) { | ||||
|         this.ids = e.map(v => v.gmrId) | ||||
|       }, | ||||
|  | ||||
|       clearAll () { | ||||
|         this.chooseUser = [] | ||||
|       }, | ||||
|  | ||||
|       onConfirm () { | ||||
|         if(!this.girdId) { | ||||
|           return this.$message.error('请选择网格') | ||||
|         } | ||||
|  | ||||
|         if (!this.chooseUser.length) { | ||||
|           return this.$message.error('请选择户主') | ||||
|         } | ||||
|  | ||||
|         const residentList = this.chooseUser.map(v => { | ||||
|           return { | ||||
|             girdMemberId: this.params.id, | ||||
|             name: v.split('~')[0], | ||||
|             residentId: v.split('~')[1], | ||||
|             girdId: this.girdId | ||||
|           } | ||||
|         }) | ||||
|         this.instance.post(`/app/appgirdmemberresident/add`, { | ||||
|           residentList | ||||
|         }).then(res => { | ||||
|           if (res.code == 0) { | ||||
|             this.current = 1 | ||||
|             this.getList() | ||||
|             this.$message.success('添加成功') | ||||
|             this.closeDialog() | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|       closeDialog() { | ||||
|         this.isShow = false | ||||
|         this.chooseUser = [] | ||||
|         this.girdId = '' | ||||
|         this.name = '' | ||||
|         this.areaId = this.user.info.areaId | ||||
|         this.getUserList() | ||||
|       }, | ||||
|  | ||||
|       del (e) { | ||||
|         this.chooseUser.splice(this.chooseUser.indexOf(e), 1) | ||||
|       }, | ||||
|  | ||||
|       getUserList () { | ||||
|         this.isLoading = true | ||||
|         this.instance.post(`/app/appresident/list`, null, { | ||||
|           params: { | ||||
|             current: 1, | ||||
|             size: 200, | ||||
|             con: this.name, | ||||
|             householdName: 1, | ||||
|             areaId: this.areaId, | ||||
|           } | ||||
|         }).then(res => { | ||||
|           if (res.code == 0) { | ||||
|             this.userList = res.data.records | ||||
|           } | ||||
|  | ||||
|           this.isLoading = false | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       onBack () { | ||||
|         this.$emit('change', { | ||||
|           type: 'list' | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       remove(id) { | ||||
|         this.$confirm('确定删除该数据?').then(() => { | ||||
|           this.instance.post(`/app/appgirdmemberresident/delete?ids=${id}`).then(res => { | ||||
|             if (res.code == 0) { | ||||
|               this.$message.success('删除成功!') | ||||
|               this.getList() | ||||
|             } | ||||
|           }) | ||||
|         }) | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| </script> | ||||
|  | ||||
| <style lang="scss" scoped> | ||||
|   .Family { | ||||
|     .AiWechatSelecter-container { | ||||
|       display: flex; | ||||
|       height: 380px; | ||||
|       margin-top: 20px; | ||||
|  | ||||
|       ::v-deep { | ||||
|         .el-icon-circle-close { | ||||
|           display: inline-block!important; | ||||
|         } | ||||
|       } | ||||
|  | ||||
|       .tree-container { | ||||
|         & > span { | ||||
|           display: block; | ||||
|           margin-bottom: 4px; | ||||
|         } | ||||
|  | ||||
|         .tree-user__item { | ||||
|           display: flex; | ||||
|           align-items: center; | ||||
|           margin-bottom: 10px; | ||||
|  | ||||
|           &:last-child { | ||||
|             margin-bottom: 0; | ||||
|           } | ||||
|         } | ||||
|         img { | ||||
|           width: 27px; | ||||
|           height: 27px; | ||||
|           margin-right: 10px; | ||||
|         } | ||||
|       } | ||||
|  | ||||
|       ::v-deep .el-tree { | ||||
|         background: transparent; | ||||
|  | ||||
|         .el-tree-node { | ||||
|           margin-bottom: 8px; | ||||
|  | ||||
|           &:last-child { | ||||
|             margin-bottom: 0; | ||||
|           } | ||||
|         } | ||||
|  | ||||
|         .el-tree-node__content { | ||||
|           height: auto; | ||||
|           margin-top: 2px; | ||||
|           // align-items: inherit; | ||||
|         } | ||||
|          | ||||
|         .el-tree-node__expand-icon { | ||||
|           height: 24px; | ||||
|         } | ||||
|       } | ||||
|  | ||||
|       .mask-btn__wrapper { | ||||
|         position: relative; | ||||
|       } | ||||
|  | ||||
|       .mask-btn { | ||||
|         position: absolute; | ||||
|         left: 0; | ||||
|         top: 0; | ||||
|         width: 100%; | ||||
|         height: 100%; | ||||
|         z-index: 1; | ||||
|       } | ||||
|  | ||||
|       .userlist-item { | ||||
|         display: flex; | ||||
|         align-items: center; | ||||
|         justify-content: space-between; | ||||
|         margin-bottom: 8px; | ||||
|         padding: 0 17px; | ||||
|         cursor: pointer; | ||||
|         user-select: none; | ||||
|  | ||||
|         ::v-deep .el-checkbox__label { | ||||
|           display: none; | ||||
|         } | ||||
|  | ||||
|         .userlist-item__left { | ||||
|           display: flex; | ||||
|           align-items: center; | ||||
|  | ||||
|           span { | ||||
|             color: #222222; | ||||
|             font-size: 14px; | ||||
|           } | ||||
|  | ||||
|           img { | ||||
|             width: 40px; | ||||
|             height: 40px; | ||||
|             margin-right: 8px; | ||||
|           } | ||||
|         } | ||||
|       } | ||||
|  | ||||
|       & > div { | ||||
|         width: 280px; | ||||
|         background: #FCFCFC; | ||||
|         border: 1px solid #D0D4DC; | ||||
|       } | ||||
|  | ||||
|       .AiWechatSelecter-list { | ||||
|         height: calc(100% - 40px); | ||||
|         padding: 8px 0; | ||||
|  | ||||
|         ::v-deep .el-scrollbar__wrap { | ||||
|           margin-bottom: 0!important; | ||||
|           overflow-x: hidden; | ||||
|         } | ||||
|  | ||||
|         ::v-deep .el-checkbox-group { | ||||
|           padding: 0 8px; | ||||
|  | ||||
|           .el-checkbox { | ||||
|             display: block; | ||||
|             margin-right: 0; | ||||
|           } | ||||
|         } | ||||
|       } | ||||
|  | ||||
|       .AiWechatSelecter-container__left { | ||||
|         flex: 1; | ||||
|       } | ||||
|  | ||||
|       .AiWechatSelecter-container__right { | ||||
|         flex: 1; | ||||
|         margin-left: 20px; | ||||
|  | ||||
|         .AiWechatSelecter-list { | ||||
|           .tags-wrapper { | ||||
|             padding: 0 8px; | ||||
|           } | ||||
|           .el-tag { | ||||
|             margin: 0 8px 8px 0px; | ||||
|             color: #222222; | ||||
|             font-size: 14px; | ||||
|           } | ||||
|         } | ||||
|       } | ||||
|  | ||||
|       .AiWechatSelecter-header { | ||||
|         display: flex; | ||||
|         align-items: center; | ||||
|         justify-content: space-between; | ||||
|         height: 40px; | ||||
|         padding: 0 8px 0 0; | ||||
|         border-bottom: 1px solid #D0D4DC; | ||||
|         background: #F5F7FA; | ||||
|  | ||||
|         .AiWechatSelecter-header__left { | ||||
|           display: flex; | ||||
|           align-items: center; | ||||
|           padding: 0 8px; | ||||
|  | ||||
|           h2 { | ||||
|             height: 100%; | ||||
|             line-height: 40px; | ||||
|             color: #222222; | ||||
|             font-size: 14px; | ||||
|             text-align: center; | ||||
|             cursor: pointer; | ||||
|             border-bottom: 2px solid transparent; | ||||
|  | ||||
|             &.active { | ||||
|               color: #2266FF; | ||||
|               border-color: #2266FF; | ||||
|             } | ||||
|           } | ||||
|         } | ||||
|  | ||||
|         .el-button { | ||||
|           height: 28px; | ||||
|           padding: 7px 5px; | ||||
|         } | ||||
|  | ||||
|         .el-input { | ||||
|           width: 160px; | ||||
|         } | ||||
|       } | ||||
|  | ||||
|       .AiWechatSelecter-header__right { | ||||
|         padding: 0 8px; | ||||
|  | ||||
|         h2 { | ||||
|           color: #222222; | ||||
|           font-size: 14px; | ||||
|           text-align: center; | ||||
|         } | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| </style> | ||||
| @@ -1,543 +0,0 @@ | ||||
| <template> | ||||
|   <section style="height: 100%"> | ||||
|     <ai-detail class="add"> | ||||
|       <template #title> | ||||
|         <ai-title :title="title" :isShowBack="true" :isShowBottomBorder="true" @onBackClick="cancel(false)"></ai-title> | ||||
|       </template> | ||||
|       <template #content> | ||||
|         <el-form | ||||
|           ref="rules" | ||||
|           :model="forms" | ||||
|           :rules="formRules" | ||||
|           size="small" | ||||
|           label-suffix=":" | ||||
|           label-width="136px"> | ||||
|           <ai-card title="基础信息" > | ||||
|             <template #right  v-if="title=='网格员详情'"> | ||||
|               <span style="color:#2266FF;cursor: pointer;font-size: 12px;" class="iconfont iconEdit" v-if="editOne==false" @click="editOne=true">修改</span> | ||||
|               <span style="color:#2266FF;margin-left: 16px;cursor: pointer;font-size: 12px;" v-if="editOne==true" @click="searchDetail(),editOne=false">取消</span> | ||||
|               <span style="color:#2266FF;margin-left: 16px;cursor: pointer;font-size: 12px;" v-if="editOne==true" @click="save()">保存</span> | ||||
|             </template> | ||||
|             <template slot="content"> | ||||
|               <div class="above" v-if="editOne==true"> | ||||
|                 <div class="left"> | ||||
|                   <el-form-item label="网格员姓名" prop="name" > | ||||
|                     <el-input v-model="forms.name" placeholder="请选择网格员" disabled> | ||||
|                       <template #append> | ||||
|                         <ai-wechat-selecter :isMultiple="false" refs="addTags" :instance="instance" v-model="users" @change="getSelectPerson"> | ||||
|                           <el-button size="small" type="primary"><span style="color: #fff">选择成员</span></el-button> | ||||
|                         </ai-wechat-selecter> | ||||
|                       </template> | ||||
|                     </el-input> | ||||
|                   </el-form-item> | ||||
|                   <el-form-item label="选用日期" prop="selectionDate" > | ||||
|                     <el-date-picker | ||||
|                       v-model="forms.selectionDate" | ||||
|                       type="date" | ||||
|                       style="width: 100%" | ||||
|                       value-format="yyyy-MM-dd" | ||||
|                       size="medium" | ||||
|                       placeholder="选择日期"> | ||||
|                     </el-date-picker> | ||||
|                   </el-form-item> | ||||
|                   <el-form-item label="身份证号" prop="idNumber" > | ||||
|                       <el-input v-model="forms.idNumber" placeholder="请输入…" maxlength="18" show-word-limit></el-input> | ||||
|                   </el-form-item> | ||||
|                 </div> | ||||
|                 <div class="right"> | ||||
|                   <el-form-item label="照片" prop="photo"> | ||||
|                     <!-- <ai-uploader :instance="instance" v-model="photoList" :limit="1" @change="photoChange"></ai-uploader> --> | ||||
|                     <ai-avatar :instance="instance"  v-model="forms.photo"/> | ||||
|                   </el-form-item> | ||||
|                 </div> | ||||
|               </div> | ||||
|               <div class="above" v-if="editOne==true"> | ||||
|                 <div class="left"> | ||||
|                   <el-form-item label="出生日期" prop="birthday" > | ||||
|                     <el-date-picker | ||||
|                         v-model="forms.birthday" | ||||
|                         type="date" | ||||
|                         style="width: 100%" | ||||
|                         value-format="yyyy-MM-dd" | ||||
|                         size="medium" | ||||
|                         placeholder="选择日期"> | ||||
|                     </el-date-picker> | ||||
|                   </el-form-item> | ||||
|                   <el-form-item label="联系电话" prop="phone" > | ||||
|                     <el-input v-model.number="forms.phone" placeholder="请输入…" maxlength="11" show-word-limit></el-input> | ||||
|                   </el-form-item> | ||||
|                 </div> | ||||
|                 <div class="right"> | ||||
|                   <el-form-item label="性别" prop="sex" > | ||||
|                     <el-select size="medium" style="width: 100%" v-model="forms.sex" placeholder="请选择..." clearable> | ||||
|                       <el-option | ||||
|                         v-for="(item,i) in dict.getDict('sex')" | ||||
|                         :key="i" | ||||
|                         :label="item.dictName" | ||||
|                         :value="item.dictValue" | ||||
|                       > | ||||
|                       </el-option> | ||||
|                     </el-select> | ||||
|                   </el-form-item> | ||||
|                   <el-form-item label="电子邮箱" prop="mail" > | ||||
|                       <el-input v-model="forms.mail" placeholder="请输入…"></el-input> | ||||
|                   </el-form-item> | ||||
|                 </div> | ||||
|               </div> | ||||
|               <template  v-if="editOne==false"> | ||||
|                 <div class="above"> | ||||
|                   <div class="left"> | ||||
|                     <ai-wrapper label-width="120px"  :columnsNumber="1"  style="margin-top: 16px;"> | ||||
|                       <ai-info-item label="网格员姓名:"><span >{{forms.name}}</span></ai-info-item> | ||||
|                       <ai-info-item label="选用日期:"><span >{{forms.selectionDate}}</span></ai-info-item> | ||||
|                       <ai-info-item label="身份证号:"><span >{{forms.idNumber}}</span></ai-info-item> | ||||
|                       <ai-info-item label="性别:"><span >{{dict.getLabel('sex', forms.sex)}}</span></ai-info-item> | ||||
|                       <ai-info-item label="出生日期:"><span >{{forms.birthday}}</span></ai-info-item> | ||||
|                       <ai-info-item label="电子邮箱:"><span >{{forms.mail}}</span></ai-info-item> | ||||
|                     </ai-wrapper> | ||||
|                   </div> | ||||
|                   <div class="right"> | ||||
|                     <ai-wrapper label-width="120px"  :columnsNumber="1"  style="margin-top: 16px;"> | ||||
|                       <ai-info-item label="照片:" v-if="forms.photo"> | ||||
|                         <span > | ||||
|                           <ai-uploader :instance="instance" v-model="photoList" disabled :limit="1" @change="photoChange"></ai-uploader> | ||||
|                         </span> | ||||
|                       </ai-info-item> | ||||
|                       <ai-info-item label="联系电话:"><span >{{forms.phone}}</span></ai-info-item> | ||||
|                     </ai-wrapper> | ||||
|                   </div> | ||||
|                 </div> | ||||
|               </template> | ||||
|             </template> | ||||
|           </ai-card> | ||||
|           <ai-card title="关联信息" > | ||||
|             <template #right  v-if="title=='网格员详情'"> | ||||
|               <span style="color:#2266FF;cursor: pointer;font-size: 12px;" class="iconfont iconEdit" v-if="editTwo==false" @click="editTwo=true">修改</span> | ||||
|               <span style="color:#2266FF;margin-left: 16px;cursor: pointer;font-size: 12px;" v-if="editTwo==true" @click="searchDetail(),editTwo=false">取消</span> | ||||
|               <span style="color:#2266FF;margin-left: 16px;cursor: pointer;font-size: 12px;" v-if="editTwo==true" @click="save()">保存</span> | ||||
|             </template> | ||||
|             <template slot="content"> | ||||
|               <template v-if="editTwo==true"> | ||||
|                 <el-form-item label="责任网格" prop="girdInfoList" style="margin-top: 8px;"> | ||||
|                   <el-form-item style="width: 100%" label-width="80px" :label="'网格' + (index + 1)" v-for="(item, index) in forms.girdInfoList" :key="'选项' + (index + 1)"> | ||||
|                     <div class="form-flex"> | ||||
|                       <el-select v-model="item.checkType" placeholder="请选择网格角色"> | ||||
|                         <el-option | ||||
|                           v-for="item in options" | ||||
|                           :key="item.value" | ||||
|                           :label="item.label" | ||||
|                           :value="item.value"> | ||||
|                         </el-option> | ||||
|                       </el-select> | ||||
|                       <el-input disabled v-model="item.girdName" :maxlength="200" size="small" placeholder="请选择责任网格"> | ||||
|                         <template slot="append"> | ||||
|                           <el-button size="small" @click="currIndex = index, showGrid = true">选择网格</el-button> | ||||
|                         </template> | ||||
|                       </el-input> | ||||
|                       <el-button type="danger" size="small" @click="removeGrid(index)">删除</el-button> | ||||
|                     </div> | ||||
|                   </el-form-item> | ||||
|                   <el-button type="primary" size="small" @click="addGrid">添加选项</el-button> | ||||
|                   <!-- <el-button size="small" @click="showGrid=true">选择网格</el-button> --> | ||||
|                 </el-form-item> | ||||
|                 <div class="above"> | ||||
|                   <div class="left"> | ||||
|                     <el-form-item label="是否特殊网格员" prop="isGirdMember" > | ||||
|                       <el-radio-group v-model="forms.isGirdMember"> | ||||
|                         <el-radio label="0">否</el-radio> | ||||
|                         <el-radio label="1">是</el-radio> | ||||
|                       </el-radio-group> | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="政治面貌" prop="politicsStatus" > | ||||
|                       <el-select v-model="forms.politicsStatus" size="small" style="width: 100%" placeholder="请选择..." clearable> | ||||
|                         <el-option v-for="(item,i) in dict.getDict('politicsStatus')" :key="i" :label="item.dictName" :value="item.dictValue"></el-option> | ||||
|                       </el-select> | ||||
|                     </el-form-item> | ||||
|                   </div> | ||||
|                   <div class="right"> | ||||
|                     <el-form-item label="特殊网格员" prop="girdMemberType" v-if="forms.isGirdMember==1"> | ||||
|                       <el-select v-model="forms.girdMemberType" size="small" placeholder="请选择..." clearable> | ||||
|                         <el-option v-for="(item,i) in dict.getDict('girdMemberType')" :key="i" :label="item.dictName" :value="item.dictValue"></el-option> | ||||
|                       </el-select> | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="学历" prop="education" > | ||||
|                       <el-select v-model="forms.education" style="width: 100%" size="small" placeholder="请选择..." clearable> | ||||
|                         <el-option v-for="(item,i) in dict.getDict('education')" :key="i" :label="item.dictName" :value="item.dictValue"></el-option> | ||||
|                       </el-select> | ||||
|                     </el-form-item> | ||||
|                   </div> | ||||
|                 </div> | ||||
|                 <el-form-item label="个人简介" prop="introduction" > | ||||
|                   <el-input | ||||
|                     type="textarea" | ||||
|                     maxlength="200" | ||||
|                     show-word-limit | ||||
|                     :rows="4" | ||||
|                     placeholder="请输入内容" | ||||
|                     v-model="forms.introduction"> | ||||
|                   </el-input> | ||||
|                 </el-form-item> | ||||
|                 <el-form-item label="人生格言" prop="motto" > | ||||
|                   <el-input | ||||
|                     type="textarea" | ||||
|                     maxlength="200" | ||||
|                     show-word-limit | ||||
|                     :rows="4" | ||||
|                     placeholder="请输入内容" | ||||
|                     v-model="forms.motto"> | ||||
|                   </el-input> | ||||
|                 </el-form-item> | ||||
|               </template> | ||||
|               <template v-if="editTwo==false"> | ||||
|                 <ai-wrapper label-width="120px" :columnsNumber="2" style="margin-top: 16px;"> | ||||
|                   <ai-info-item label="责任网格:" style="width: 100%;"><span v-html="girdInfoStr || '-'"></span></ai-info-item> | ||||
|                   <ai-info-item label="是否特殊网格员:"> | ||||
|                     <span>{{ !forms.isGirdMember ? '-' : forms.isGirdMember === '0' ? '否' : '是' }}</span> | ||||
|                   </ai-info-item> | ||||
|                   <ai-info-item label="特殊网格员:" v-if="forms.isGirdMember==1"><span >{{dict.getLabel('girdMemberType', forms.girdMemberType)}}</span></ai-info-item> | ||||
|                   <ai-info-item label="政治面貌:"><span >{{dict.getLabel('politicsStatus', forms.politicsStatus)}}</span></ai-info-item> | ||||
|                   <ai-info-item label="学历:"><span >{{dict.getLabel('education', forms.education)}}</span></ai-info-item> | ||||
|                   <ai-info-item label="人生格言:" style="width: 100%;"><span >{{forms.motto}}</span></ai-info-item> | ||||
|                   <ai-info-item label="个人简介:" style="width: 100%;"><span >{{forms.introduction}}</span></ai-info-item> | ||||
|                 </ai-wrapper> | ||||
|               </template> | ||||
|             </template> | ||||
|           </ai-card> | ||||
|         </el-form> | ||||
|         <ai-dialog title="选择网格" :visible.sync="showGrid" :customFooter="true"  :destroyOnClose="true" border  width="720px"> | ||||
|           <div class="grid"> | ||||
|             <el-tree | ||||
|               :data="treeObj.treeList" | ||||
|               :props="treeObj.defaultProps" | ||||
|               node-key="id" | ||||
|               ref="tree" | ||||
|               :check-strictly="true" | ||||
|               show-checkbox | ||||
|               :default-checked-keys="currCheckedKeys" | ||||
|               default-expand-all | ||||
|               @check="onCheckChange"> | ||||
|             </el-tree> | ||||
|           </div> | ||||
|           <div class="dialog-footer" slot="footer" > | ||||
|             <el-button  size="medium" @click="showGrid=false">取消</el-button> | ||||
|             <el-button  type="primary" size="medium" @click="getCheckedTree()">确认</el-button> | ||||
|           </div> | ||||
|         </ai-dialog> | ||||
|       </template> | ||||
|       <template #footer v-if="title=='添加网格员'"> | ||||
|         <el-button @click="cancel(false)" class="delete-btn footer-btn" >取 消</el-button> | ||||
|         <el-button type="primary" @click="save()"  class="footer-btn">提 交</el-button> | ||||
|       </template> | ||||
|     </ai-detail> | ||||
|   </section> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| export default { | ||||
|   name: "add", | ||||
|   props: { | ||||
|     instance: Function, | ||||
|     dict: Object, | ||||
|     permissions: Function, | ||||
|     params: Object, | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       users: [], | ||||
|       currIndex: 0, | ||||
|       forms: { | ||||
|         birthday: "", | ||||
|         education: "", | ||||
|         girdId: "", | ||||
|         girdInfoList: [], | ||||
|         girdMemberType: "", | ||||
|         id: "", | ||||
|         wxUserId: '', | ||||
|         introduction: "", | ||||
|         isGirdMember: "", | ||||
|         mail: "", | ||||
|         motto: "", | ||||
|         name: "", | ||||
|         phone: "", | ||||
|         photo: "", | ||||
|         politicsStatus: "", | ||||
|         selectionDate: "", | ||||
|         sex: "", | ||||
|         userId: "", | ||||
|       }, | ||||
|       options: [{ | ||||
|         value: '2', | ||||
|         label: '网格长' | ||||
|       }, { | ||||
|         value: '1', | ||||
|         label: '网格员' | ||||
|       }], | ||||
|       showGrid: false, | ||||
|       treeObj: { | ||||
|         treeList: [], | ||||
|         defaultProps: { | ||||
|           children: "girdList", | ||||
|           label: "girdName", | ||||
|         }, | ||||
|         checkedKeys: [], | ||||
|       }, | ||||
|       girdInfoStr: '', | ||||
|       photoList: [], | ||||
|       title: "添加网格员", | ||||
|       editOne: false, | ||||
|       editTwo: false, | ||||
|     }; | ||||
|   }, | ||||
|   created() { | ||||
|     this.beforeSelectTree() | ||||
|     if (this.params.id) { | ||||
|       this.searchDetail(); | ||||
|       this.title = "网格员详情"; | ||||
|       this.editOne = false; | ||||
|       this.editTwo = false; | ||||
|     } else { | ||||
|       this.title = "添加网格员"; | ||||
|       this.editOne = true; | ||||
|       this.editTwo = true; | ||||
|     } | ||||
|   }, | ||||
|   computed: { | ||||
|     currCheckedKeys () { | ||||
|       if (this.forms && this.forms.girdInfoList && this.forms.girdInfoList[this.currIndex] && this.forms.girdInfoList[this.currIndex].id) { | ||||
|         return [this.forms.girdInfoList[this.currIndex].id] | ||||
|       } | ||||
|  | ||||
|       return [] | ||||
|     }, | ||||
|     formRules() { | ||||
|       let phonePass = (rule, value, callback) => { | ||||
|         let reg = /^(?:(?:\+|00)86)?1\d{10}$/; | ||||
|         if (value) { | ||||
|           if (reg.test(value)) { | ||||
|             callback(); | ||||
|           } else { | ||||
|             callback(new Error("联系电话格式错误")); | ||||
|           } | ||||
|         } else { | ||||
|           callback(new Error("请输入联系电话")); | ||||
|         } | ||||
|       }; | ||||
|       return { | ||||
|         name: [ | ||||
|           { required: true, message: "请输入网格员姓名", trigger: "change" }, | ||||
|         ], | ||||
|         selectionDate: [ | ||||
|           { required: true, message: "请选择选用日期", trigger: "change" }, | ||||
|         ], | ||||
|         phone: [{ required: true, validator: phonePass, trigger: "blur" }], | ||||
|         girdInfoList: [ | ||||
|           { required: true, message: "请选择责任网络", trigger: "change" }, | ||||
|         ], | ||||
|         mail: [ | ||||
|           { | ||||
|             type: "email", | ||||
|             message: "请输入正确的邮箱地址", | ||||
|             trigger: ["blur", "change"], | ||||
|           }, | ||||
|         ] | ||||
|       }; | ||||
|     }, | ||||
|   }, | ||||
|   methods: { | ||||
|     cancel (isRefresh) { | ||||
|       this.$emit('change', { | ||||
|         type: 'list', | ||||
|         isRefresh: !!isRefresh, | ||||
|       }) | ||||
|     }, | ||||
|  | ||||
|     onCheckChange (e) { | ||||
|       this.$nextTick(() => { | ||||
|         this.$refs.tree.getCheckedKeys().forEach(v => { | ||||
|           this.$refs.tree.setChecked(v, false) | ||||
|         }) | ||||
|         this.$refs.tree.setChecked(e.id, true) | ||||
|       }) | ||||
|     }, | ||||
|  | ||||
|     removeGrid (index) { | ||||
|       this.forms.girdInfoList.splice(index, 1) | ||||
|     }, | ||||
|  | ||||
|     addGrid () { | ||||
|       this.forms.girdInfoList.push({ | ||||
|         id: '', | ||||
|         girdName: '', | ||||
|         checkType: '' | ||||
|       }) | ||||
|     }, | ||||
|     photoChange(val) { | ||||
|       this.forms.photo = val[0].url; | ||||
|     }, | ||||
|     getSelectPerson(val) { | ||||
|       this.forms.name = val[0].name; | ||||
|       this.forms.phone = val[0].phone; | ||||
|       this.forms.userId = val[0].sysUserId | ||||
|       this.forms.wxUserId = val[0].id | ||||
|     }, | ||||
|     getCheckedTree() { | ||||
|       if (!this.$refs.tree.getCheckedNodes().length) { | ||||
|         return this.$message.error('请选择网格') | ||||
|       } | ||||
|  | ||||
|       if (this.$refs.tree.getCheckedNodes().length > 1) { | ||||
|         return this.$message.error('不支持多选') | ||||
|       } | ||||
|       this.$set(this.forms.girdInfoList, this.currIndex, { | ||||
|         ...this.$refs.tree.getCheckedNodes()[0], | ||||
|         checkType: this.forms.girdInfoList[this.currIndex].checkType | ||||
|       }) | ||||
|       this.showGrid = false; | ||||
|     }, | ||||
|     handleClose(tag) { | ||||
|       this.forms.girdInfoList.splice(this.forms.girdInfoList.indexOf(tag), 1); | ||||
|     }, | ||||
|     beforeSelectTree() { | ||||
|       this.treeObj.checkedKeys = []; | ||||
|       this.instance.post(`/app/appgirdinfo/listAll`, null, null).then((res) => { | ||||
|         if (res.code == 0) { | ||||
|           this.treeObj.treeList = res.data; | ||||
|           this.forms.girdInfoList.map((e) => { | ||||
|             this.treeObj.checkedKeys.push(e.id); | ||||
|           }); | ||||
|         } | ||||
|       }); | ||||
|     }, | ||||
|     save() { | ||||
|       this.$refs["rules"].validate((valid) => { | ||||
|         if (valid) { | ||||
|           for (let i = 0; i < this.forms.girdInfoList.length; i++) { | ||||
|             const currInfo = this.forms.girdInfoList[i] | ||||
|             const arr = JSON.parse(JSON.stringify(this.forms.girdInfoList)) | ||||
|             arr.splice(i, 1) | ||||
|             const sameInfo = arr.filter(v => v.id === currInfo.id) | ||||
|             if (!currInfo.checkType) { | ||||
|               return this.$message.error('请选择网格员类型') | ||||
|             } | ||||
|  | ||||
|             if (!currInfo.id) { | ||||
|               return this.$message.error('请选择网格') | ||||
|             } | ||||
|  | ||||
|             if (currInfo.checkType === '1' && currInfo.girdLevel !== '2') { | ||||
|               return this.$message.error(`一级、二级网格不能添加网格员`) | ||||
|             } | ||||
|  | ||||
|             if (sameInfo.length) { | ||||
|               return this.$message.error('不能选择同一网格重复绑定') | ||||
|             } | ||||
|           } | ||||
|  | ||||
|           this.instance.post(`/app/appgirdmemberinfo/addOrUpdate`,{ | ||||
|             ...this.forms, | ||||
|             girdInfoListStr: this.forms.girdInfoList.map(v => v.girdName).join(',') | ||||
|           }).then((res) => { | ||||
|             if (res.code == 0) { | ||||
|               if (this.title == "添加网格员") { | ||||
|                 this.cancel(true) | ||||
|               } else { | ||||
|                 this.editOne = false | ||||
|                 this.editTwo = false | ||||
|                 this.searchDetail() | ||||
|               } | ||||
|             } | ||||
|           }); | ||||
|         } else { | ||||
|           return false | ||||
|         } | ||||
|       }); | ||||
|     }, | ||||
|     searchDetail() { | ||||
|       this.instance | ||||
|         .post(`/app/appgirdmemberinfo/queryDetailById`, null, { | ||||
|           params: { id: this.params.id }, | ||||
|         }) | ||||
|         .then((res) => { | ||||
|           if (res.code == 0) { | ||||
|             this.forms = { | ||||
|               ...res.data, | ||||
|               girdInfoList: res.data.girdInfoList || [] | ||||
|             }; | ||||
|             this.users = [{ | ||||
|               name: res.data.name, | ||||
|               phone: res.data.phone, | ||||
|               userId: res.data.id, | ||||
|               id: res.data.wxUserId | ||||
|             }] | ||||
|             this.girdInfoStr = '' | ||||
|             this.photoList = [{ url: this.forms.photo }]; | ||||
|             if (res.data.girdInfoList) { | ||||
|               res.data.girdInfoList.forEach((e) => { | ||||
|                 this.girdInfoStr = this.girdInfoStr + `${e.checkType === '1' ? '网格员' : '网格长'}-${e.girdName} ` | ||||
|               }) | ||||
|             } | ||||
|           } | ||||
|         }); | ||||
|     }, | ||||
|   }, | ||||
| }; | ||||
| </script> | ||||
|  | ||||
| <style lang="scss" scoped> | ||||
| .add { | ||||
|   height: 100%; | ||||
|  | ||||
|     .form-flex { | ||||
|       display: flex; | ||||
|       align-items: center; | ||||
|  | ||||
|       & > .el-button { | ||||
|         margin-left: 20px; | ||||
|       } | ||||
|  | ||||
|       .el-input { | ||||
|         width: 300px; | ||||
|         margin-left: 20px; | ||||
|       } | ||||
|  | ||||
|       ::v-deep .el-form-item__content { | ||||
|         margin-left: 0!important; | ||||
|       } | ||||
|     } | ||||
|   .ai-detail__title { | ||||
|     background-color: #fff; | ||||
|   } | ||||
|   .ai-detail__content { | ||||
|     .ai-detail__content--wrapper { | ||||
|       .el-form { | ||||
|         // background-color: #fff; | ||||
|         // padding: 0 60px; | ||||
|         .flex { | ||||
|           display: flex; | ||||
|           flex-wrap: wrap; | ||||
|           justify-content: space-between; | ||||
|           .el-form-item { | ||||
|             width: 48%; | ||||
|           } | ||||
|           .buildingTypes { | ||||
|             width: 100%; | ||||
|           } | ||||
|         } | ||||
|       } | ||||
|     } | ||||
|   } | ||||
|   ::v-deep .el-tag { | ||||
|     margin-right: 8px; | ||||
|     color: #333333; | ||||
|   } | ||||
|   .footer-btn { | ||||
|     width: 92px; | ||||
|   } | ||||
|   .above{ | ||||
|     display: flex; | ||||
|     .left, .right{ | ||||
|       flex: 1; | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </style> | ||||
| @@ -11,7 +11,8 @@ | ||||
|                   <el-form-item label="户主姓名" prop="name"> | ||||
|                     <el-input size="small" class="user-selecter" v-model="form.name" placeholder="请输入姓名" clearable :disabled="isEdit || isSelectUser"> | ||||
|                       <template slot="append"> | ||||
|                         <ai-person-select :instance="instance" @selectPerson="checkName" :url="'/app/appresident/list?auditStatus=1&householdName=1&areaId='+user.info.areaId"></ai-person-select> | ||||
|                         <ai-person-select :instance="instance" @selectPerson="checkName" | ||||
|                                           :url="'/app/appresident/list?auditStatus=1&householdName=1&areaId='+user.info.areaId"/> | ||||
|                       </template> | ||||
|                     </el-input> | ||||
|                   </el-form-item> | ||||
| @@ -19,7 +20,8 @@ | ||||
|                     <el-input v-model="form.phone" placeholder="请输入联系方式" :maxlength="11" show-word-limit/> | ||||
|                   </el-form-item> | ||||
|                   <el-form-item label="证件号码" prop="idNumber"> | ||||
|                     <el-input v-model="form.idNumber" placeholder="请输入证件号码" :maxlength="20" :disabled="isEdit || isSelectUser" @change="handleIdNumberAutocomplete"/> | ||||
|                     <el-input v-model="form.idNumber" placeholder="请输入证件号码" :maxlength="20" :disabled="isEdit || isSelectUser" | ||||
|                               @change="handleIdNumberAutocomplete"/> | ||||
|                   </el-form-item> | ||||
|                 </div> | ||||
|                 <el-form-item label="个人照片" prop="photo"> | ||||
| @@ -49,25 +51,25 @@ | ||||
|               </div> | ||||
|               <el-form-item label="健康状况"> | ||||
|                 <el-checkbox-group v-model="form.healthyStatusList"> | ||||
|                   <el-checkbox :label="item.dictValue" v-for="(item, index) in dict.getDict('fpHealth')" :key="index">{{item.dictName}}</el-checkbox> | ||||
|                   <el-checkbox :label="item.dictValue" v-for="(item, index) in dict.getDict('fpHealth')" :key="index">{{ item.dictName }}</el-checkbox> | ||||
|                 </el-checkbox-group> | ||||
|               </el-form-item> | ||||
|               <div flex class="half wrap"> | ||||
|                 <el-form-item label="残疾类别"> | ||||
|                   <ai-select v-model="form.disabilityType" :selectList="dict.getDict('fpDisabilityType')" /> | ||||
|                   <ai-select v-model="form.disabilityType" :selectList="dict.getDict('fpDisabilityType')"/> | ||||
|                 </el-form-item> | ||||
|                 <el-form-item label="残疾办证年度"> | ||||
|                   <ai-select v-model="form.disabilityCertificateYear" :selectList="dict.getDict('fpYear')" /> | ||||
|                   <ai-select v-model="form.disabilityCertificateYear" :selectList="dict.getDict('fpYear')"/> | ||||
|                 </el-form-item> | ||||
|               </div> | ||||
|               <el-form-item label="基础保险"> | ||||
|                 <el-checkbox-group v-model="form.basicsList"> | ||||
|                   <el-checkbox :label="item.value" v-for="(item, index) in basicsCheckList" :key="index">{{item.label}}</el-checkbox> | ||||
|                   <el-checkbox :label="item.value" v-for="(item, index) in basicsCheckList" :key="index">{{ item.label }}</el-checkbox> | ||||
|                 </el-checkbox-group> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="保障措施"> | ||||
|                 <el-checkbox-group v-model="form.guaranteeList"> | ||||
|                   <el-checkbox :label="item.value" v-for="(item, index) in guaranteeCheckList" :key="index">{{item.label}}</el-checkbox> | ||||
|                   <el-checkbox :label="item.value" v-for="(item, index) in guaranteeCheckList" :key="index">{{ item.label }}</el-checkbox> | ||||
|                 </el-checkbox-group> | ||||
|               </el-form-item> | ||||
|               <div flex class="half wrap"> | ||||
| @@ -75,13 +77,13 @@ | ||||
|                   <ai-select v-model="form.labourStatus" :selectList="dict.getDict('fpLaborSkills')"/> | ||||
|                 </el-form-item> | ||||
|                 <el-form-item label="是否会讲普通话"> | ||||
|                   <ai-select v-model="form.mandarin" :selectList="dict.getDict('fpYesOrNo')" /> | ||||
|                   <ai-select v-model="form.mandarin" :selectList="dict.getDict('fpYesOrNo')"/> | ||||
|                 </el-form-item> | ||||
|                 <el-form-item label="务工时间(月)"> | ||||
|                   <el-input type="number" v-model="form.workeMonths" placeholder="请输入" clearable @input="numberInput('workeMonths')" /> | ||||
|                   <el-input type="number" v-model="form.workeMonths" placeholder="请输入" clearable @input="numberInput('workeMonths')"/> | ||||
|                 </el-form-item> | ||||
|                 <el-form-item label="就业渠道"> | ||||
|                   <ai-select v-model="form.employmentChannels" :selectList="dict.getDict('fpEmploymentChannels')" /> | ||||
|                   <ai-select v-model="form.employmentChannels" :selectList="dict.getDict('fpEmploymentChannels')"/> | ||||
|                 </el-form-item> | ||||
|                 <el-form-item label="务工企业名称"> | ||||
|                   <el-input v-model="form.migrantEnterprises" placeholder="请输入" clearable/> | ||||
| @@ -90,10 +92,10 @@ | ||||
|                   <el-input v-model="form.publicWelfarePosts" placeholder="请输入" clearable/> | ||||
|                 </el-form-item> | ||||
|                 <el-form-item label="是否国外务工"> | ||||
|                   <ai-select v-model="form.foreignWorkers" :selectList="dict.getDict('fpYesOrNo')" /> | ||||
|                   <ai-select v-model="form.foreignWorkers" :selectList="dict.getDict('fpYesOrNo')"/> | ||||
|                 </el-form-item> | ||||
|                 <el-form-item label="公益性岗位(月数)"> | ||||
|                   <el-input type="number" v-model="form.publicWelfarePostsMonths" placeholder="请输入" clearable @input="numberInput('publicWelfarePostsMonths')" /> | ||||
|                   <el-input type="number" v-model="form.publicWelfarePostsMonths" placeholder="请输入" clearable @input="numberInput('publicWelfarePostsMonths')"/> | ||||
|                 </el-form-item> | ||||
|               </div> | ||||
|               <el-form-item label="务工所在地"> | ||||
| @@ -207,14 +209,14 @@ | ||||
|               <el-form-item label="备注说明"> | ||||
|                 <el-input v-model="form.detail" placeholder="请输入" type="textarea" maxlength="500" show-word-limit clearable/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="图片(最多9张)" > | ||||
|               <el-form-item label="图片(最多9张)"> | ||||
|                 <ai-uploader | ||||
|                   :isShowTip="true" | ||||
|                   :instance="instance" | ||||
|                   v-model="form.files" | ||||
|                   fileType="img" | ||||
|                   acceptType=".png,.jpg,.jpeg" | ||||
|                   :limit="9"> | ||||
|                     :isShowTip="true" | ||||
|                     :instance="instance" | ||||
|                     v-model="form.files" | ||||
|                     fileType="img" | ||||
|                     acceptType=".png,.jpg,.jpeg" | ||||
|                     :limit="9"> | ||||
|                   <template slot="tips">最多上传9张图片,单张图片最大10MB<br/>支持.png,.jpg,.jpeg格式</template> | ||||
|                 </ai-uploader> | ||||
|               </el-form-item> | ||||
| @@ -336,7 +338,7 @@ export default { | ||||
|     }, | ||||
|     rules() { | ||||
|       return { | ||||
|         idNumber: [{required: true, message: "请输入身份证号"}], | ||||
|         idNumber: [{required: true, message: "请输入证件号"}], | ||||
|         name: [{required: true, message: "请输入姓名"}], | ||||
|         sex: [{required: true, message: "请选择性别"}], | ||||
|         phone: [{required: true, message: "请输入联系方式"}], | ||||
| @@ -346,7 +348,7 @@ export default { | ||||
|         ], | ||||
|         isHousehold: [{required: true, message: "请选择是否户主"}], | ||||
|         householdRelation: [{required: true, message: "请选择与户主关系"}], | ||||
|         householdIdNumber: [{required: true, message: "请选择户主身份证号"}], | ||||
|         householdIdNumber: [{required: true, message: "请选择户主证件号"}], | ||||
|         riskType: [{required: true, message: "请选择风险因素"}], | ||||
|         objectType: [{required: true, message: "请选择监测对象类型"}], | ||||
|       } | ||||
| @@ -383,22 +385,22 @@ export default { | ||||
|         healthyStatusList: [], | ||||
|         guaranteeList: [], | ||||
|         basicsList: [], | ||||
|         file: [],  | ||||
|         file: [], | ||||
|       }, | ||||
|       isSelectUser: false, //是否选择人员 | ||||
|     } | ||||
|   }, | ||||
|   methods: { | ||||
|     checkName(e) { | ||||
|       if(!e) { | ||||
|       if (!e) { | ||||
|         this.isSelectUser = false | ||||
|         this.form.name = '' | ||||
|         this.form.idNumber = '' | ||||
|         this.form.phone ='' | ||||
|         this.form.phone = '' | ||||
|         this.form.currentAreaId = '' | ||||
|         this.form.currentAddress = '' | ||||
|         this.form.birthDate = ''  | ||||
|         this.form.sex = ''  | ||||
|         this.form.birthDate = '' | ||||
|         this.form.sex = '' | ||||
|         this.form.age = '' | ||||
|         return | ||||
|       } | ||||
| @@ -422,13 +424,13 @@ export default { | ||||
|           res.data.healthyStatusList = [] | ||||
|           res.data.basicsList = [] | ||||
|           res.data.guaranteeList = [] | ||||
|           if(res.data.healthyStatus) { | ||||
|           if (res.data.healthyStatus) { | ||||
|             res.data.healthyStatusList = res.data.healthyStatus.split(',') | ||||
|           } | ||||
|           if(res.data.basicsCheck) { | ||||
|           if (res.data.basicsCheck) { | ||||
|             res.data.basicsList = res.data.basicsCheck.split(',') | ||||
|           } | ||||
|           if(res.data.guaranteeCheck) { | ||||
|           if (res.data.guaranteeCheck) { | ||||
|             res.data.guaranteeList = res.data.guaranteeCheck.split(',') | ||||
|           } | ||||
|           console.log(res.data) | ||||
| @@ -438,8 +440,8 @@ export default { | ||||
|     }, | ||||
|     handleIdNumberAutocomplete(v) { | ||||
|       var idNumber = v | ||||
|       if(v.length == 20) { | ||||
|         idNumber = v.substring(0, 17) | ||||
|       if (v.length == 20) { | ||||
|         idNumber = v.substring(0, 18) | ||||
|       } | ||||
|       let {birthday: birthDate, sex} = this.idCardNoUtil.getIdCardInfo(idNumber) | ||||
|       this.form = {...this.form, birthDate, sex, age: this.$calcAge(idNumber)} | ||||
| @@ -452,58 +454,60 @@ export default { | ||||
|           if (this.form.healthyStatusList.length) { | ||||
|             this.form.healthyStatus = this.form.healthyStatusList.join(',') | ||||
|           } | ||||
|           if(this.user.info.girdCheckType == 1) { | ||||
|           if (this.user.info.girdCheckType == 1) { | ||||
|             this.form.girdId = this.user.info.girdId | ||||
|           } | ||||
|           if(this.form.basicsList.length) { | ||||
|           if (this.form.basicsList.length) { | ||||
|             this.form.basicsCheck = this.form.basicsList.join(',') | ||||
|           } | ||||
|           if(this.form.guaranteeList.length) { | ||||
|           if (this.form.guaranteeList.length) { | ||||
|             this.form.guaranteeCheck = this.form.basicsList.join(',') | ||||
|           } | ||||
|           if([1, 2, 3].includes(2)) { | ||||
|           if ([1, 2, 3].includes(2)) { | ||||
|             this.form.jcbxCxyiliao = '01' | ||||
|           }else { | ||||
|           } else { | ||||
|             this.form.jcbxCxyiliao = '02' | ||||
|           } | ||||
|           this.checkInit('jcbxCxyiliao',this.form.basicsList, '0') | ||||
|           this.checkInit('jcbxCzyiliao',this.form.basicsList, '1') | ||||
|           this.checkInit('jcbxDabing',this.form.basicsList, '2') | ||||
|           this.checkInit('jcbxShangye',this.form.basicsList, '3') | ||||
|           this.checkInit('jcbxCxyanglao',this.form.basicsList, '4') | ||||
|           this.checkInit('jcbxCzyanglao',this.form.basicsList, '5') | ||||
|           this.checkInit('jcbxRenshenyiwai',this.form.basicsList, '6') | ||||
|  | ||||
|           this.checkInit('bzcsNongcundibao',this.form.guaranteeList, '0') | ||||
|           this.checkInit('bzcsTekungongyang',this.form.guaranteeList, '1') | ||||
|           this.checkInit('bzcsWubaohu',this.form.guaranteeList, '2') | ||||
|           this.checkInit('bzcsYiliaojiuzhu',this.form.guaranteeList, '3') | ||||
|           this.checkInit('bzcsQita',this.form.guaranteeList, '4') | ||||
|           this.checkInit('jcbxCxyiliao', this.form.basicsList, '0') | ||||
|           this.checkInit('jcbxCzyiliao', this.form.basicsList, '1') | ||||
|           this.checkInit('jcbxDabing', this.form.basicsList, '2') | ||||
|           this.checkInit('jcbxShangye', this.form.basicsList, '3') | ||||
|           this.checkInit('jcbxCxyanglao', this.form.basicsList, '4') | ||||
|           this.checkInit('jcbxCzyanglao', this.form.basicsList, '5') | ||||
|           this.checkInit('jcbxRenshenyiwai', this.form.basicsList, '6') | ||||
|  | ||||
|           this.checkInit('bzcsNongcundibao', this.form.guaranteeList, '0') | ||||
|           this.checkInit('bzcsTekungongyang', this.form.guaranteeList, '1') | ||||
|           this.checkInit('bzcsWubaohu', this.form.guaranteeList, '2') | ||||
|           this.checkInit('bzcsYiliaojiuzhu', this.form.guaranteeList, '3') | ||||
|           this.checkInit('bzcsQita', this.form.guaranteeList, '4') | ||||
|           let loading = this.$loading({text: "提交中..."}) | ||||
|           this.instance.post(`/app/apppreventionreturntopoverty/addOrUpdate`, this.form).then(res => { | ||||
|             if (res.code == 0) { | ||||
|               this.$message.success('提交成功!'); | ||||
|               this.back() | ||||
|             } | ||||
|           }).finally(() => { | ||||
|             loading.close() | ||||
|           }) | ||||
|         } | ||||
|       }) | ||||
|     }, | ||||
|     checkInit(formName, list, value) { | ||||
|       if(list.includes(value)) { | ||||
|       if (list.includes(value)) { | ||||
|         this.form[formName] = '01' | ||||
|       }else { | ||||
|       } else { | ||||
|         this.form[formName] = '02' | ||||
|       } | ||||
|     }, | ||||
|     decimalInput(name) { | ||||
|       if(!/^(([1-9]{1}\d*)|(0{1}))(\.\d{1,2})?$/g.test(this.form[name])){ | ||||
|       if (!/^(([1-9]{1}\d*)|(0{1}))(\.\d{1,2})?$/g.test(this.form[name])) { | ||||
|         this.form[name] = '' | ||||
|         return this.$message.error('最多只保留两位小数点') | ||||
|       } | ||||
|     }, | ||||
|     numberInput(name) { | ||||
|       if(!/^[0-9]*[1-9][0-9]*$/g.test(this.form[name])){ | ||||
|       if (!/^[0-9]*[1-9][0-9]*$/g.test(this.form[name])) { | ||||
|         this.form[name] = '' | ||||
|         return this.$message.error('请输入正整数') | ||||
|       } | ||||
|   | ||||
| @@ -3,22 +3,30 @@ | ||||
|     <ai-detail> | ||||
|       <ai-title slot="title" title="监测对象详情" isShowBottomBorder isShowBack @onBackClick="back"> | ||||
|         <template #rightBtn> | ||||
|           <el-button type="primary" icon="iconfont iconEdit" @click="gotoEdit" v-if="$permissions('app_apppreventionreturntopoverty_edit')">编辑</el-button> | ||||
|           <el-button type="primary" icon="iconfont iconEdit" @click="gotoEdit" | ||||
|                      v-if="$permissions('app_apppreventionreturntopoverty_edit')">编辑 | ||||
|           </el-button> | ||||
|           <template v-if="isGridAdmin"> | ||||
|             <template v-if="detail.status == 0 || detail.status == 4"> | ||||
|               <el-button type="primary" @click="applyMonitor('纳入监测', 1)" v-if="girdAdminApplyStatus != 1">纳入监测</el-button> | ||||
|               <el-button type="primary" @click="examine('纳入监测审批', 2)" v-if="girdAdminApplyStatus == 1">纳入监测审批</el-button> | ||||
|               <el-button type="primary" @click="applyMonitor('纳入监测', 1)" v-if="girdAdminApplyStatus != 1">纳入监测 | ||||
|               </el-button> | ||||
|               <el-button type="primary" @click="examine('纳入监测审批', 2)" v-if="girdAdminApplyStatus == 1">纳入监测审批 | ||||
|               </el-button> | ||||
|             </template> | ||||
|             <el-button type="primary" @click="applyMonitor('纳入监测', 1)" v-if="detail.status == 3">纳入监测</el-button> | ||||
|             <el-button type="primary" @click="applyMonitor('解除风险', 4)" v-if="detail.status == 1">解除风险</el-button> | ||||
|             <el-button type="primary" @click="examine('解除风险审批', 5)" v-if="detail.status == 2">解除风险审批</el-button> | ||||
|           </template> | ||||
|           <template v-if="user.info.girdCheckType == 1"> | ||||
|             <el-button type="primary" @click="applyMonitor('申请纳入监测', 0)" v-if="detail.status == 4 || detail.status == 3">申请纳入监测</el-button> | ||||
|             <el-button type="primary" @click="applyMonitor('申请纳入监测', 0)" | ||||
|                        v-if="detail.status == 4 || detail.status == 3">申请纳入监测 | ||||
|             </el-button> | ||||
|             <el-button type="primary" @click="applyMonitor('申请解除风险', 3)" v-if="detail.status == 1">申请解除风险</el-button> | ||||
|           </template> | ||||
|           <template v-if="detail.status == 3 || detail.status == 4"> | ||||
|             <el-button v-if="$permissions('app_apppreventionreturntopoverty_del') && user.info.girdCheckType != 0" icon="iconfont iconDelete" @click="handleDelete(detail.id)">删除</el-button> | ||||
|             <el-button v-if="$permissions('app_apppreventionreturntopoverty_del') && user.info.girdCheckType != 0" | ||||
|                        icon="iconfont iconDelete" @click="handleDelete(detail.id)">删除 | ||||
|             </el-button> | ||||
|           </template> | ||||
|         </template> | ||||
|       </ai-title> | ||||
| @@ -30,96 +38,123 @@ | ||||
|                 <template #content> | ||||
|                   <div flex class="flex-start"> | ||||
|                     <div flex class="half wrap fill"> | ||||
|                       <el-form-item label="联系电话">{{ detail.phone}}</el-form-item> | ||||
|                       <el-form-item label="身份证号">{{ detail.idNumber}}</el-form-item> | ||||
|                       <el-form-item label="性别" prop="sex">{{ dict.getLabel("sex", detail.sex)}}</el-form-item> | ||||
|                       <el-form-item label="出生日期">{{ detail.birthDate}}</el-form-item> | ||||
|                       <el-form-item label="联系电话">{{ detail.phone }}</el-form-item> | ||||
|                       <el-form-item label="证件号">{{ detail.idNumber }}</el-form-item> | ||||
|                       <el-form-item label="性别" prop="sex">{{ dict.getLabel("sex", detail.sex) }}</el-form-item> | ||||
|                       <el-form-item label="出生日期">{{ detail.birthDate }}</el-form-item> | ||||
|                       <!-- <el-form-item label="年龄" prop="age">{{ detail.age}}</el-form-item> --> | ||||
|                       <el-form-item label="民族">{{dict.getLabel("fpNation", detail.nation)}}</el-form-item> | ||||
|                       <el-form-item label="文化程度">{{ dict.getLabel("fpEducation", detail.education)}}</el-form-item> | ||||
|                       <el-form-item label="政治面貌">{{dict.getLabel("fpPoliticalOutlook",detail.politicsStatus)}}</el-form-item> | ||||
|                       <el-form-item label="在校生状况">{{dict.getLabel( "fpStudentsInSchool", detail.schoolStatus)}}</el-form-item> | ||||
|                       <el-form-item label="民族">{{ dict.getLabel("fpNation", detail.nation) }}</el-form-item> | ||||
|                       <el-form-item label="文化程度">{{ dict.getLabel("fpEducation", detail.education) }}</el-form-item> | ||||
|                       <el-form-item label="政治面貌">{{ dict.getLabel("fpPoliticalOutlook", detail.politicsStatus) }} | ||||
|                       </el-form-item> | ||||
|                       <el-form-item label="在校生状况">{{ dict.getLabel("fpStudentsInSchool", detail.schoolStatus) }} | ||||
|                       </el-form-item> | ||||
|                     </div> | ||||
|                     <ai-avatar :instance="instance" v-model="detail.photo" :editable="false" /> | ||||
|                     <ai-avatar :instance="instance" v-model="detail.photo" :editable="false"/> | ||||
|                   </div> | ||||
|                   <el-form-item label="健康状况"> | ||||
|                     <span v-for="(item, index) in detail.healthyStatusList" :key="index"><span v-if="index > 0">,</span>{{dict.getLabel("fpHealth", item)}}</span> | ||||
|                     <span v-for="(item, index) in detail.healthyStatusList" :key="index"><span v-if="index > 0">,</span>{{ | ||||
|                         dict.getLabel("fpHealth", item) | ||||
|                       }}</span> | ||||
|                   </el-form-item> | ||||
|                   <div flex class="half wrap"> | ||||
|                     <el-form-item label="残疾类别">{{dict.getLabel("fpDisabilityType", detail.disabilityType)}}</el-form-item> | ||||
|                     <el-form-item label="残疾办证年度">{{dict.getLabel("fpYear", detail.disabilityCertificateYear)}}</el-form-item> | ||||
|                     <el-form-item label="残疾类别">{{ dict.getLabel("fpDisabilityType", detail.disabilityType) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="残疾办证年度">{{ dict.getLabel("fpYear", detail.disabilityCertificateYear) }} | ||||
|                     </el-form-item> | ||||
|                   </div> | ||||
|                   <div flex class="half wrap"> | ||||
|                     <el-form-item label="城乡居民基本医疗保险">{{dict.getLabel("fpYesOrNo", detail.jcbxCxyiliao)}}</el-form-item> | ||||
|                     <el-form-item label="城镇职工基本医疗保险">{{dict.getLabel("fpYesOrNo", detail.jcbxCzyiliao)}}</el-form-item> | ||||
|                     <el-form-item label="大病保险">{{dict.getLabel("fpYesOrNo", detail.jcbxDabing)}}</el-form-item> | ||||
|                     <el-form-item label="商业补充医疗保险">{{dict.getLabel("fpYesOrNo", detail.jcbxShangye)}}</el-form-item> | ||||
|                     <el-form-item label="城乡居民基本养老保险">{{dict.getLabel("fpYesOrNo", detail.jcbxCxyanglao)}}</el-form-item> | ||||
|                     <el-form-item label="城镇职工基本养老保险">{{dict.getLabel("fpYesOrNo", detail.jcbxCzyanglao)}}</el-form-item> | ||||
|                     <el-form-item label="享受人身意外保险补贴">{{dict.getLabel("fpYesOrNo", detail.jcbxRenshenyiwai)}}</el-form-item> | ||||
|                     <el-form-item label="享受农村最低生活保障">{{dict.getLabel("fpYesOrNo", detail.bzcsNongcundibao)}}</el-form-item> | ||||
|                     <el-form-item label="是否特困供养人员">{{dict.getLabel("fpYesOrNo", detail.bzcsTekungongyang)}}</el-form-item> | ||||
|                     <el-form-item label="分散供养五保户转集中供养(减少)">{{dict.getLabel("fpYesOrNo", detail.bzcsWubaohu)}}</el-form-item> | ||||
|                     <el-form-item label="是否接受医疗救助">{{dict.getLabel("fpYesOrNo", detail.bzcsYiliaojiuzhu)}}</el-form-item> | ||||
|                     <el-form-item label="是否接受其它健康扶贫">{{dict.getLabel("fpYesOrNo", detail.bzcsQita)}}</el-form-item> | ||||
|                     <el-form-item label="劳动技能">{{dict.getLabel("fpLaborSkills", detail.labourStatus)}}</el-form-item> | ||||
|                     <el-form-item label="是否会讲普通话">{{dict.getLabel("fpYesOrNo", detail.mandarin)}}</el-form-item> | ||||
|                     <el-form-item label="务工时间(月)">{{detail.workeMonths}}</el-form-item> | ||||
|                     <el-form-item label="就业渠道">{{dict.getLabel("fpEmploymentChannels", detail.employmentChannels)}}</el-form-item> | ||||
|                     <el-form-item label="务工企业名称">{{detail.migrantEnterprises}}</el-form-item> | ||||
|                     <el-form-item label="公益性岗位">{{detail.publicWelfarePosts}}</el-form-item> | ||||
|                     <el-form-item label="是否国外务工">{{dict.getLabel("fpYesOrNo", detail.foreignWorkers)}}</el-form-item> | ||||
|                     <el-form-item label="公益性岗位(月数)">{{detail.publicWelfarePostsMonths}}</el-form-item> | ||||
|                     <el-form-item label="城乡居民基本医疗保险">{{ dict.getLabel("fpYesOrNo", detail.jcbxCxyiliao) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="城镇职工基本医疗保险">{{ dict.getLabel("fpYesOrNo", detail.jcbxCzyiliao) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="大病保险">{{ dict.getLabel("fpYesOrNo", detail.jcbxDabing) }}</el-form-item> | ||||
|                     <el-form-item label="商业补充医疗保险">{{ dict.getLabel("fpYesOrNo", detail.jcbxShangye) }}</el-form-item> | ||||
|                     <el-form-item label="城乡居民基本养老保险">{{ dict.getLabel("fpYesOrNo", detail.jcbxCxyanglao) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="城镇职工基本养老保险">{{ dict.getLabel("fpYesOrNo", detail.jcbxCzyanglao) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="享受人身意外保险补贴">{{ dict.getLabel("fpYesOrNo", detail.jcbxRenshenyiwai) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="享受农村最低生活保障">{{ dict.getLabel("fpYesOrNo", detail.bzcsNongcundibao) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="是否特困供养人员">{{ dict.getLabel("fpYesOrNo", detail.bzcsTekungongyang) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="分散供养五保户转集中供养(减少)">{{ dict.getLabel("fpYesOrNo", detail.bzcsWubaohu) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="是否接受医疗救助">{{ dict.getLabel("fpYesOrNo", detail.bzcsYiliaojiuzhu) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="是否接受其它健康扶贫">{{ dict.getLabel("fpYesOrNo", detail.bzcsQita) }}</el-form-item> | ||||
|                     <el-form-item label="劳动技能">{{ dict.getLabel("fpLaborSkills", detail.labourStatus) }}</el-form-item> | ||||
|                     <el-form-item label="是否会讲普通话">{{ dict.getLabel("fpYesOrNo", detail.mandarin) }}</el-form-item> | ||||
|                     <el-form-item label="务工时间(月)">{{ detail.workeMonths }}</el-form-item> | ||||
|                     <el-form-item label="就业渠道">{{ dict.getLabel("fpEmploymentChannels", detail.employmentChannels) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="务工企业名称">{{ detail.migrantEnterprises }}</el-form-item> | ||||
|                     <el-form-item label="公益性岗位">{{ detail.publicWelfarePosts }}</el-form-item> | ||||
|                     <el-form-item label="是否国外务工">{{ dict.getLabel("fpYesOrNo", detail.foreignWorkers) }}</el-form-item> | ||||
|                     <el-form-item label="公益性岗位(月数)">{{ detail.publicWelfarePostsMonths }}</el-form-item> | ||||
|                   </div> | ||||
|                   <el-form-item label="务工所在地">{{detail.foreignWorkersAddress}} | ||||
|                   <el-form-item label="务工所在地">{{ detail.foreignWorkersAddress }} | ||||
|                   </el-form-item> | ||||
|                   <el-form-item label="现住址">{{currentFullAddress}}</el-form-item> | ||||
|                   <el-form-item label="现住址">{{ currentFullAddress }}</el-form-item> | ||||
|                 </template> | ||||
|               </ai-card> | ||||
|               <ai-card title="生产生活条件"> | ||||
|                 <template slot="content"> | ||||
|                   <div flex class="half wrap"> | ||||
|                     <el-form-item label="住房面积(m²)">{{detail.houseArea}}</el-form-item> | ||||
|                     <el-form-item label="户类型">{{ dict.getLabel("fpYesOrNo", detail.houseType)}}</el-form-item> | ||||
|                     <el-form-item label="与村主干路距离(公里)">{{ detail.trunkRoadDistance}}</el-form-item> | ||||
|                     <el-form-item label="入户路类型">{{ dict.getLabel("fpHouseRoadType", detail.houseRoadType)}}</el-form-item> | ||||
|                     <el-form-item label="是否危房">{{ dict.getLabel("fpYesOrNo", detail.dilapidatedHousehold)}}</el-form-item> | ||||
|                     <el-form-item label="是否住房损耗">{{ dict.getLabel("fpYesOrNo", detail.houseDamage)}}</el-form-item> | ||||
|                     <el-form-item label="是否解决安全饮水">{{ dict.getLabel("fpYesOrNo", detail.drinkingWaterSafety)}}</el-form-item> | ||||
|                     <el-form-item label="是否饮水设施损坏">{{ dict.getLabel("fpYesOrNo", detail.drinkingWaterDamage)}}</el-form-item> | ||||
|                     <el-form-item label="是否有卫生厕所">{{ dict.getLabel("fpYesOrNo", detail.toilet)}}</el-form-item> | ||||
|                     <el-form-item label="主要燃料类型">{{ dict.getLabel("fpFuelType", detail.fuelType)}}</el-form-item> | ||||
|                     <el-form-item label="是否通生活用电">{{ dict.getLabel("fpYesOrNo", detail.electric)}}</el-form-item> | ||||
|                     <el-form-item label="是否通广播电视">{{ dict.getLabel("fpYesOrNo", detail.television)}}</el-form-item> | ||||
|                     <el-form-item label="耕地面积(亩)">{{detail.cultivatedLandArea}}</el-form-item> | ||||
|                     <el-form-item label="林地面积(亩)">{{detail.woodlandArea}}</el-form-item> | ||||
|                     <el-form-item label="林果面积(亩)">{{detail.orchardArea}}</el-form-item> | ||||
|                     <el-form-item label="退耕还林面积(亩)">{{detail.grainForGreenArea}}</el-form-item> | ||||
|                     <el-form-item label="牧草地面积(亩)">{{detail.grazingGrasslandArea}}</el-form-item> | ||||
|                     <el-form-item label="水面面积(亩)">{{detail.watersArea}}</el-form-item> | ||||
|                     <el-form-item label="是否加入农民专业合作社">{{ dict.getLabel("fpYesOrNo", detail.nongheshe)}}</el-form-item> | ||||
|                     <el-form-item label="是否有龙头企业带动">{{ dict.getLabel("fpYesOrNo", detail.longtouqiye)}}</el-form-item> | ||||
|                     <el-form-item label="是否有创业致富人带头人带动">{{ dict.getLabel("fpYesOrNo", detail.cyzfdtr)}}</el-form-item> | ||||
|                     <el-form-item label="是否通生产通电">{{ dict.getLabel("fpYesOrNo", detail.produceElectric)}}</el-form-item> | ||||
|                     <el-form-item label="住房面积(m²)">{{ detail.houseArea }}</el-form-item> | ||||
|                     <el-form-item label="户类型">{{ dict.getLabel("fpHouseType", detail.houseType) }}</el-form-item> | ||||
|                     <el-form-item label="与村主干路距离(公里)">{{ detail.trunkRoadDistance }}</el-form-item> | ||||
|                     <el-form-item label="入户路类型">{{ dict.getLabel("fpHouseRoadType", detail.houseRoadType) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="是否危房">{{ dict.getLabel("fpYesOrNo", detail.dilapidatedHousehold) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="是否住房损耗">{{ dict.getLabel("fpYesOrNo", detail.houseDamage) }}</el-form-item> | ||||
|                     <el-form-item label="是否解决安全饮水">{{ dict.getLabel("fpYesOrNo", detail.drinkingWaterSafety) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="是否饮水设施损坏">{{ dict.getLabel("fpYesOrNo", detail.drinkingWaterDamage) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="是否有卫生厕所">{{ dict.getLabel("fpYesOrNo", detail.toilet) }}</el-form-item> | ||||
|                     <el-form-item label="主要燃料类型">{{ dict.getLabel("fpFuelType", detail.fuelType) }}</el-form-item> | ||||
|                     <el-form-item label="是否通生活用电">{{ dict.getLabel("fpYesOrNo", detail.electric) }}</el-form-item> | ||||
|                     <el-form-item label="是否通广播电视">{{ dict.getLabel("fpYesOrNo", detail.television) }}</el-form-item> | ||||
|                     <el-form-item label="耕地面积(亩)">{{ detail.cultivatedLandArea }}</el-form-item> | ||||
|                     <el-form-item label="林地面积(亩)">{{ detail.woodlandArea }}</el-form-item> | ||||
|                     <el-form-item label="林果面积(亩)">{{ detail.orchardArea }}</el-form-item> | ||||
|                     <el-form-item label="退耕还林面积(亩)">{{ detail.grainForGreenArea }}</el-form-item> | ||||
|                     <el-form-item label="牧草地面积(亩)">{{ detail.grazingGrasslandArea }}</el-form-item> | ||||
|                     <el-form-item label="水面面积(亩)">{{ detail.watersArea }}</el-form-item> | ||||
|                     <el-form-item label="是否加入农民专业合作社">{{ dict.getLabel("fpYesOrNo", detail.nongheshe) }}</el-form-item> | ||||
|                     <el-form-item label="是否有龙头企业带动">{{ dict.getLabel("fpYesOrNo", detail.longtouqiye) }}</el-form-item> | ||||
|                     <el-form-item label="是否有创业致富人带头人带动">{{ dict.getLabel("fpYesOrNo", detail.cyzfdtr) }}</el-form-item> | ||||
|                     <el-form-item label="是否通生产通电">{{ dict.getLabel("fpYesOrNo", detail.produceElectric) }} | ||||
|                     </el-form-item> | ||||
|                   </div> | ||||
|                 </template> | ||||
|               </ai-card> | ||||
|               <ai-card title="家庭风险情况"> | ||||
|                 <template slot="content"> | ||||
|                   <div flex class="half wrap"> | ||||
|                     <el-form-item label="监测对象类型" prop="objectType">{{ dict.getLabel("fpType", detail.objectType)}}</el-form-item> | ||||
|                     <el-form-item label="是否军烈属">{{ dict.getLabel("fpYesOrNo", detail.militaryMartyrs)}}</el-form-item> | ||||
|                     <el-form-item label="风险因素" prop="riskType">{{ dict.getLabel("fpRiskType", detail.riskType)}} </el-form-item> | ||||
|                     <el-form-item label="脱贫年度">{{ dict.getLabel("fpYear", detail.povertyYear)}} </el-form-item> | ||||
|                     <el-form-item label="因自然灾害子项">{{ dict.getLabel("fpNaturalDisaster", detail.naturalDisasterType)}}</el-form-item> | ||||
|                     <el-form-item label="是否义务阶段失学辍学">{{ dict.getLabel("fpYesOrNo", detail.dropOutOfSchool)}}</el-form-item> | ||||
|                     <el-form-item label="识别监测时间">{{ detail.createTime}}</el-form-item> | ||||
|                     <el-form-item label="风险是否已消除">{{ dict.getLabel("fpYesOrNo", detail.riskEliminated)}}</el-form-item> | ||||
|                     <el-form-item label="是否有家庭成员未参加医疗保险">{{ dict.getLabel("fpYesOrNo", detail.notCoveredMedicalInsurance)}}</el-form-item> | ||||
|                     <el-form-item label="信息采集人">{{detail.updateUserName}}</el-form-item> | ||||
|                     <el-form-item label="信息采集人联系电话">{{ detail.updateUserPhone}}</el-form-item> | ||||
|                     <el-form-item label="监测对象类型" prop="objectType">{{ dict.getLabel("fpType", detail.objectType) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="是否军烈属">{{ dict.getLabel("fpYesOrNo", detail.militaryMartyrs) }}</el-form-item> | ||||
|                     <el-form-item label="风险因素" prop="riskType">{{ dict.getLabel("fpRiskType", detail.riskType) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="脱贫年度">{{ dict.getLabel("fpYear", detail.povertyYear) }}</el-form-item> | ||||
|                     <el-form-item label="因自然灾害子项">{{ dict.getLabel("fpNaturalDisaster", detail.naturalDisasterType) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="是否义务阶段失学辍学">{{ dict.getLabel("fpYesOrNo", detail.dropOutOfSchool) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="识别监测时间">{{ detail.createTime }}</el-form-item> | ||||
|                     <el-form-item label="风险是否已消除">{{ dict.getLabel("fpYesOrNo", detail.riskEliminated) }}</el-form-item> | ||||
|                     <el-form-item label="是否有家庭成员未参加医疗保险"> | ||||
|                       {{ dict.getLabel("fpYesOrNo", detail.notCoveredMedicalInsurance) }} | ||||
|                     </el-form-item> | ||||
|                     <el-form-item label="信息采集人">{{ detail.updateUserName }}</el-form-item> | ||||
|                     <el-form-item label="信息采集人联系电话">{{ detail.updateUserPhone }}</el-form-item> | ||||
|                   </div> | ||||
|                   <el-form-item label="义务阶段未上学原因">{{detail.dropOutOfSchoolReason}}</el-form-item> | ||||
|                   <el-form-item label="义务阶段未上学原因">{{ detail.dropOutOfSchoolReason }}</el-form-item> | ||||
|                   <!-- <el-form-item label="备注说明">{{detail.detail}}</el-form-item> | ||||
|                   <el-form-item label="图片"> | ||||
|                     <ai-uploader disabled v-model="detail.files"></ai-uploader> | ||||
| @@ -129,53 +164,56 @@ | ||||
|               <ai-card title="家庭收支情况"> | ||||
|                 <template slot="content"> | ||||
|                   <div flex class="half wrap"> | ||||
|                     <el-form-item label="纳入监测对象的收入参考范围">{{detail.income1}}</el-form-item> | ||||
|                     <el-form-item label="纳入监测对象的人均收入参考范围">{{detail.income2}}</el-form-item> | ||||
|                     <el-form-item label="工资性收入(元)">{{detail.income3}}</el-form-item> | ||||
|                     <el-form-item label="生产经营性收入(元)">{{detail.income4}}</el-form-item> | ||||
|                     <el-form-item label="计划生育金(元)">{{detail.income5}}</el-form-item> | ||||
|                     <el-form-item label="资产收益扶贫分红收入">{{detail.income6}}</el-form-item> | ||||
|                     <el-form-item label="低保金(元)">{{detail.income7}}</el-form-item> | ||||
|                     <el-form-item label="特困供养金(元)">{{detail.income8}}</el-form-item> | ||||
|                     <el-form-item label="养老保险金(元)">{{detail.income9}}</el-form-item> | ||||
|                     <el-form-item label="生态补偿金(元)">{{detail.income10}}</el-form-item> | ||||
|                     <el-form-item label="转移性收入(元)">{{detail.income11}}</el-form-item> | ||||
|                     <el-form-item label="其它转移性收入(元)">{{detail.income12}}</el-form-item> | ||||
|                     <el-form-item label="财产性收入(元)">{{detail.income13}}</el-form-item> | ||||
|                     <el-form-item label="其它财产收入(元)">{{detail.income14}}</el-form-item> | ||||
|                     <el-form-item label="生产经营性支出(元)">{{detail.income15}}</el-form-item> | ||||
|                     <el-form-item label="年收入(元)">{{detail.income16}}</el-form-item> | ||||
|                     <el-form-item label="家庭纯收入(元)">{{detail.familyIncome}}</el-form-item> | ||||
|                     <el-form-item label="人均纯收入(元)">{{detail.perCapitaIncome}}</el-form-item> | ||||
|                     <el-form-item label="纳入监测对象的收入参考范围">{{ detail.income1 }}</el-form-item> | ||||
|                     <el-form-item label="纳入监测对象的人均收入参考范围">{{ detail.income2 }}</el-form-item> | ||||
|                     <el-form-item label="工资性收入(元)">{{ detail.income3 }}</el-form-item> | ||||
|                     <el-form-item label="生产经营性收入(元)">{{ detail.income4 }}</el-form-item> | ||||
|                     <el-form-item label="计划生育金(元)">{{ detail.income5 }}</el-form-item> | ||||
|                     <el-form-item label="资产收益扶贫分红收入">{{ detail.income6 }}</el-form-item> | ||||
|                     <el-form-item label="低保金(元)">{{ detail.income7 }}</el-form-item> | ||||
|                     <el-form-item label="特困供养金(元)">{{ detail.income8 }}</el-form-item> | ||||
|                     <el-form-item label="养老保险金(元)">{{ detail.income9 }}</el-form-item> | ||||
|                     <el-form-item label="生态补偿金(元)">{{ detail.income10 }}</el-form-item> | ||||
|                     <el-form-item label="转移性收入(元)">{{ detail.income11 }}</el-form-item> | ||||
|                     <el-form-item label="其它转移性收入(元)">{{ detail.income12 }}</el-form-item> | ||||
|                     <el-form-item label="财产性收入(元)">{{ detail.income13 }}</el-form-item> | ||||
|                     <el-form-item label="其它财产收入(元)">{{ detail.income14 }}</el-form-item> | ||||
|                     <el-form-item label="生产经营性支出(元)">{{ detail.income15 }}</el-form-item> | ||||
|                     <el-form-item label="年收入(元)">{{ detail.income16 }}</el-form-item> | ||||
|                     <el-form-item label="家庭纯收入(元)">{{ detail.familyIncome }}</el-form-item> | ||||
|                     <el-form-item label="人均纯收入(元)">{{ detail.perCapitaIncome }}</el-form-item> | ||||
|                   </div> | ||||
|                 </template> | ||||
|               </ai-card> | ||||
|               <ai-card title="风险消除情况" v-if="detail.status == 3"> | ||||
|                 <template slot="content"> | ||||
|                   <div flex class="half wrap"> | ||||
|                     <el-form-item label="工资性收入情况">{{detail.fxxcIncome1}}</el-form-item> | ||||
|                     <el-form-item label="生产经营性收入情况">{{detail.fxxcIncome2}}</el-form-item> | ||||
|                     <el-form-item label="财产性收入情况">{{detail.fxxcIncome3}}</el-form-item> | ||||
|                     <el-form-item label="转移性收入情况">{{detail.fxxcIncome4}}</el-form-item> | ||||
|                     <el-form-item label="理赔收入情况">{{detail.fxxcIncome5}}</el-form-item> | ||||
|                     <el-form-item label="生产经营性支出情况">{{detail.fxxcIncome6}}</el-form-item> | ||||
|                     <el-form-item label="合规自然收支情况">{{detail.fxxcIncome7}}</el-form-item> | ||||
|                     <el-form-item label="家庭纯收入情况">{{detail.fxxcIncome8}}</el-form-item> | ||||
|                     <el-form-item label="家庭人均纯收入情况">{{detail.fxxcIncome9}}</el-form-item> | ||||
|                     <el-form-item label="工资性收入情况">{{ detail.fxxcIncome1 }}</el-form-item> | ||||
|                     <el-form-item label="生产经营性收入情况">{{ detail.fxxcIncome2 }}</el-form-item> | ||||
|                     <el-form-item label="财产性收入情况">{{ detail.fxxcIncome3 }}</el-form-item> | ||||
|                     <el-form-item label="转移性收入情况">{{ detail.fxxcIncome4 }}</el-form-item> | ||||
|                     <el-form-item label="理赔收入情况">{{ detail.fxxcIncome5 }}</el-form-item> | ||||
|                     <el-form-item label="生产经营性支出情况">{{ detail.fxxcIncome6 }}</el-form-item> | ||||
|                     <el-form-item label="合规自然收支情况">{{ detail.fxxcIncome7 }}</el-form-item> | ||||
|                     <el-form-item label="家庭纯收入情况">{{ detail.fxxcIncome8 }}</el-form-item> | ||||
|                     <el-form-item label="家庭人均纯收入情况">{{ detail.fxxcIncome9 }}</el-form-item> | ||||
|                   </div> | ||||
|                 </template> | ||||
|               </ai-card> | ||||
|               <ai-card title="家庭成员"> | ||||
|                 <template #right> | ||||
|                   <span style=" color: #2266ff; margin-left: 16px;cursor: pointer;font-size: 12px;" @click="addFamily({})">添加</span> | ||||
|                   <span style=" color: #2266ff; margin-left: 16px;cursor: pointer;font-size: 12px;" | ||||
|                         @click="addFamily({})">添加</span> | ||||
|                 </template> | ||||
|                 <template #content> | ||||
|                   <ai-table :tableData="detail.family" :colConfigs="colConfigs" :dict="dict" :isShowPagination="false"> | ||||
|                     <el-table-column slot="options" label="操作" align="center" width="200px"> | ||||
|                       <template slot-scope="{ row }"> | ||||
|                         <el-button type="text" @click="viewFamily(row)">详情</el-button> | ||||
|                         <el-button type="text" @click="addFamily(row)">编辑</el-button> | ||||
|                         <el-button type="text" @click="delFamily(row)">删除</el-button> | ||||
|                         <template v-if="row.isHousehold==0"> | ||||
|                           <el-button type="text" @click="addFamily(row)">编辑</el-button> | ||||
|                           <el-button type="text" @click="delFamily(row)">删除</el-button> | ||||
|                         </template> | ||||
|                       </template> | ||||
|                     </el-table-column> | ||||
|                   </ai-table> | ||||
| @@ -183,116 +221,133 @@ | ||||
|               </ai-card> | ||||
|               <div style="height:20px;"></div> | ||||
|             </el-tab-pane> | ||||
|             <el-tab-pane label="走访日志" lazy name="HrLog" v-if="$permissions('app_apppreventionreturntopovertylog_detail')"> | ||||
|               <hr-log v-if="currentTab == 'HrLog'" :instance="instance" :dict="dict" :permissions="permissions" /> | ||||
|             <el-tab-pane label="走访日志" lazy name="HrLog" | ||||
|                          v-if="$permissions('app_apppreventionreturntopovertylog_detail')"> | ||||
|               <hr-log v-if="currentTab == 'HrLog'" :instance="instance" :dict="dict" :permissions="permissions"/> | ||||
|             </el-tab-pane> | ||||
|             <el-tab-pane label="帮扶措施" lazy name="HrMeasure"> | ||||
|               <hr-measure v-if="currentTab == 'HrMeasure'" :instance="instance" :dict="dict" :permissions="permissions" /> | ||||
|               <hr-measure v-if="currentTab == 'HrMeasure'" :instance="instance" :dict="dict" | ||||
|                           :permissions="permissions"/> | ||||
|             </el-tab-pane> | ||||
|           </el-tabs> | ||||
|         </el-form> | ||||
|         <ai-dialog :visible.sync="isShowAdd" width="1000px" height="500px" title="添加家庭成员" @close="onClose" @onConfirm="onConfirm"> | ||||
|         <ai-dialog :visible.sync="isShowAdd" width="1000px" height="500px" title="添加家庭成员" @close="onClose" | ||||
|                    @onConfirm="onConfirm"> | ||||
|           <el-form :model="form" ref="ruleForm" :rules="rules" label-width="130px" label-position="right" size="small"> | ||||
|             <div flex class="half wrap"> | ||||
|               <div flex class="column"> | ||||
|                 <el-form-item label="户主姓名" prop="name"> | ||||
|                   <el-input size="small" class="user-selecter" v-model="form.name" placeholder="请输入姓名" clearable :disabled="isEdit || isSelectUser"> | ||||
|                 <el-form-item label="成员姓名" prop="name"> | ||||
|                   <el-input size="small" class="user-selecter" v-model="form.name" placeholder="请输入姓名" clearable | ||||
|                             :disabled="isEdit || isSelectUser"> | ||||
|                     <template slot="append"> | ||||
|                       <ai-person-select :instance="instance" @selectPerson="checkName" :url="'/app/appresident/list?auditStatus=1&areaId='+user.info.areaId"></ai-person-select> | ||||
|                       <ai-person-select :instance="instance" @selectPerson="checkName" | ||||
|                                         :url="'/app/appresident/list?auditStatus=1&areaId='+user.info.areaId"></ai-person-select> | ||||
|                     </template> | ||||
|                   </el-input> | ||||
|                 </el-form-item> | ||||
|                 <el-form-item label="联系方式" prop="phone"> | ||||
|                   <el-input v-model="form.phone" placeholder="请输入联系方式" :maxlength="11" show-word-limit /> | ||||
|                   <el-input v-model="form.phone" placeholder="请输入联系方式" :maxlength="11" show-word-limit/> | ||||
|                 </el-form-item> | ||||
|                 <el-form-item label="证件号码" prop="idNumber"> | ||||
|                   <el-input v-model="form.idNumber" placeholder="请输入证件号码" :maxlength="18" :disabled="isEdit || isSelectUser" @change="handleIdNumberAutocomplete" /> | ||||
|                   <el-input v-model="form.idNumber" placeholder="请输入证件号码" :maxlength="18" | ||||
|                             :disabled="isEdit || isSelectUser" @change="handleIdNumberAutocomplete"/> | ||||
|                 </el-form-item> | ||||
|               </div> | ||||
|               <el-form-item label="个人照片" prop="photo"> | ||||
|                 <ai-avatar :instance="instance" v-model="form.photo" /> | ||||
|                 <ai-avatar :instance="instance" v-model="form.photo"/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="性别" prop="sex"> | ||||
|                 <ai-select v-model="form.sex" :selectList="dict.getDict('sex')" disabled /> | ||||
|                 <ai-select v-model="form.sex" :selectList="dict.getDict('sex')" disabled/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="出生日期" prop="birthDate"> | ||||
|                 <el-date-picker disabled value-format="yyyy-MM-dd HH:mm:ss" format="yyyy-MM-dd" v-model="form.birthDate" type="date" placeholder="选择日期" /> | ||||
|                 <el-date-picker disabled value-format="yyyy-MM-dd HH:mm:ss" format="yyyy-MM-dd" v-model="form.birthDate" | ||||
|                                 type="date" placeholder="选择日期"/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="与户主关系" prop="householdRelation"> | ||||
|                 <ai-select v-model="form.householdRelation" :selectList="dict.getDict('fpRelationship')" /> | ||||
|                 <ai-select v-model="form.householdRelation" :selectList="dict.getDict('fpRelationship')"/> | ||||
|               </el-form-item> | ||||
|               <!-- <el-form-item label="年龄" prop="age"> | ||||
|                 <el-input disabled v-model="form.age" placeholder="请输入年龄" type="number"/> | ||||
|               </el-form-item> --> | ||||
|               <el-form-item label="民族"> | ||||
|                 <ai-select v-model="form.nation" :selectList="dict.getDict('fpNation')" /> | ||||
|                 <ai-select v-model="form.nation" :selectList="dict.getDict('fpNation')"/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="文化程度"> | ||||
|                 <ai-select v-model="form.education" :selectList="dict.getDict('fpEducation')" /> | ||||
|                 <ai-select v-model="form.education" :selectList="dict.getDict('fpEducation')"/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="政治面貌"> | ||||
|                 <ai-select v-model="form.politicsStatus" :selectList="dict.getDict('fpPoliticalOutlook')" /> | ||||
|                 <ai-select v-model="form.politicsStatus" :selectList="dict.getDict('fpPoliticalOutlook')"/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="在校生状况"> | ||||
|                 <ai-select v-model="form.schoolStatus" :selectList="dict.getDict('fpStudentsInSchool')" /> | ||||
|                 <ai-select v-model="form.schoolStatus" :selectList="dict.getDict('fpStudentsInSchool')"/> | ||||
|               </el-form-item> | ||||
|             </div> | ||||
|             <el-form-item label="健康状况"> | ||||
|               <el-checkbox-group v-model="form.healthyStatusList"> | ||||
|                 <el-checkbox :label="item.dictValue" v-for="(item, index) in dict.getDict('fpHealth')" :key="index">{{item.dictName}}</el-checkbox> | ||||
|                 <el-checkbox :label="item.dictValue" v-for="(item, index) in dict.getDict('fpHealth')" :key="index"> | ||||
|                   {{ item.dictName }} | ||||
|                 </el-checkbox> | ||||
|               </el-checkbox-group> | ||||
|             </el-form-item> | ||||
|             <div flex class="half wrap"> | ||||
|               <el-form-item label="残疾类别"> | ||||
|                 <ai-select v-model="form.disabilityType" :selectList="dict.getDict('fpDisabilityType')" placeholder="请选择" /> | ||||
|                 <ai-select v-model="form.disabilityType" :selectList="dict.getDict('fpDisabilityType')" | ||||
|                            placeholder="请选择"/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="残疾办证年度"> | ||||
|                 <el-date-picker v-model="form.disabilityCertificateYear" type="year" placeholder="请选择" /> | ||||
|                 <ai-select v-model="form.disabilityCertificateYear" :selectList="dict.getDict('fpYear')"/> | ||||
|               </el-form-item> | ||||
|             </div> | ||||
|             <el-form-item label="基础保险"> | ||||
|               <el-checkbox-group v-model="form.basicsList"> | ||||
|                 <el-checkbox :label="item.value" v-for="(item, index) in basicsCheckList" :key="index">{{item.label}}</el-checkbox> | ||||
|                 <el-checkbox :label="item.value" v-for="(item, index) in basicsCheckList" :key="index"> | ||||
|                   {{ item.label }} | ||||
|                 </el-checkbox> | ||||
|               </el-checkbox-group> | ||||
|             </el-form-item> | ||||
|             <el-form-item label="保障措施"> | ||||
|               <el-checkbox-group v-model="form.guaranteeList"> | ||||
|                 <el-checkbox :label="item.value" v-for="(item, index) in guaranteeCheckList" :key="index">{{item.label}}</el-checkbox> | ||||
|                 <el-checkbox :label="item.value" v-for="(item, index) in guaranteeCheckList" :key="index"> | ||||
|                   {{ item.label }} | ||||
|                 </el-checkbox> | ||||
|               </el-checkbox-group> | ||||
|             </el-form-item> | ||||
|             <div flex class="half wrap"> | ||||
|               <el-form-item label="劳动技能"> | ||||
|                 <ai-select v-model="form.labourStatus" :selectList="dict.getDict('fpLaborSkills')" /> | ||||
|                 <ai-select v-model="form.labourStatus" :selectList="dict.getDict('fpLaborSkills')"/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="是否会讲普通话"> | ||||
|                 <ai-select v-model="form.mandarin" :selectList="dict.getDict('fpYesOrNo')" placeholder="请选择" /> | ||||
|                 <ai-select v-model="form.mandarin" :selectList="dict.getDict('fpYesOrNo')" placeholder="请选择"/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="务工时间(月)"> | ||||
|                 <el-input type="number" v-model="form.workeMonths" placeholder="请输入" clearable @input="numberInput('workeMonths')" /> | ||||
|                 <el-input type="number" v-model="form.workeMonths" placeholder="请输入" clearable | ||||
|                           @input="numberInput('workeMonths')"/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="就业渠道"> | ||||
|                 <ai-select v-model="form.employmentChannels" :selectList="dict.getDict('fpEmploymentChannels')" /> | ||||
|                 <ai-select v-model="form.employmentChannels" :selectList="dict.getDict('fpEmploymentChannels')"/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="务工企业名称"> | ||||
|                 <el-input v-model="form.migrantEnterprises" placeholder="请输入" clearable /> | ||||
|                 <el-input v-model="form.migrantEnterprises" placeholder="请输入" clearable/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="公益性岗位"> | ||||
|                 <el-input v-model="form.publicWelfarePosts" placeholder="请输入" clearable /> | ||||
|                 <el-input v-model="form.publicWelfarePosts" placeholder="请输入" clearable/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="是否国外务工"> | ||||
|                 <ai-select v-model="form.foreignWorkers" :selectList="dict.getDict('fpYesOrNo')" placeholder="请选择" /> | ||||
|                 <ai-select v-model="form.foreignWorkers" :selectList="dict.getDict('fpYesOrNo')" placeholder="请选择"/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="公益性岗位(月数)"> | ||||
|                 <el-input type="number" v-model="form.publicWelfarePostsMonths" placeholder="请输入" clearable @input="numberInput('publicWelfarePostsMonths')" /> | ||||
|                 <el-input type="number" v-model="form.publicWelfarePostsMonths" placeholder="请输入" clearable | ||||
|                           @input="numberInput('publicWelfarePostsMonths')"/> | ||||
|               </el-form-item> | ||||
|             </div> | ||||
|             <el-form-item label="务工所在地"> | ||||
|               <el-input v-model="form.foreignWorkersAddress" placeholder="请输入" clearable maxlength="30" show-word-limit /> | ||||
|               <el-input v-model="form.foreignWorkersAddress" placeholder="请输入" clearable maxlength="30" | ||||
|                         show-word-limit/> | ||||
|             </el-form-item> | ||||
|             <el-form-item label="现住址" prop="currentAreaId"> | ||||
|               <ai-area-get :instance="instance" v-model="form.currentAreaId" :root="rootArea" valueLevel="5" /> | ||||
|               <ai-area-get :instance="instance" v-model="form.currentAreaId" :root="rootArea" valueLevel="5"/> | ||||
|               <el-form-item prop="currentAddress"> | ||||
|                 <el-input v-model="form.currentAddress" placeholder="详细地址" maxlength="30" show-word-limit clearable /> | ||||
|                 <el-input v-model="form.currentAddress" placeholder="详细地址" maxlength="30" show-word-limit clearable/> | ||||
|               </el-form-item> | ||||
|             </el-form-item> | ||||
|           </el-form> | ||||
| @@ -301,66 +356,72 @@ | ||||
|           <el-form :model="familyInfo" label-width="160px" label-position="right" size="small"> | ||||
|             <div flex class="flex-start"> | ||||
|               <div flex class="half wrap fill"> | ||||
|                 <el-form-item label="联系电话">{{ familyInfo.phone}}</el-form-item> | ||||
|                 <el-form-item label="身份证号">{{ familyInfo.idNumber}}</el-form-item> | ||||
|                 <el-form-item label="性别" prop="sex">{{ dict.getLabel("sex", familyInfo.sex)}}</el-form-item> | ||||
|                 <el-form-item label="出生日期">{{ familyInfo.birthDate}}</el-form-item> | ||||
|                 <el-form-item label="与户主关系">{{dict.getLabel("fpRelationship", familyInfo.householdRelation)}}</el-form-item> | ||||
|                 <el-form-item label="联系电话">{{ familyInfo.phone }}</el-form-item> | ||||
|                 <el-form-item label="证件号">{{ familyInfo.idNumber }}</el-form-item> | ||||
|                 <el-form-item label="性别" prop="sex">{{ dict.getLabel("sex", familyInfo.sex) }}</el-form-item> | ||||
|                 <el-form-item label="出生日期">{{ familyInfo.birthDate }}</el-form-item> | ||||
|                 <el-form-item label="与户主关系">{{ dict.getLabel("fpRelationship", familyInfo.householdRelation) }} | ||||
|                 </el-form-item> | ||||
|                 <!-- <el-form-item label="年龄" prop="age">{{ familyInfo.age}}</el-form-item> --> | ||||
|                 <el-form-item label="民族">{{dict.getLabel("fpNation", familyInfo.nation)}}</el-form-item> | ||||
|                 <el-form-item label="文化程度">{{ dict.getLabel("fpEducation", familyInfo.education)}}</el-form-item> | ||||
|                 <el-form-item label="政治面貌">{{dict.getLabel("fpPoliticalOutlook",familyInfo.politicsStatus)}}</el-form-item> | ||||
|                 <el-form-item label="在校生状况">{{dict.getLabel( "fpStudentsInSchool", familyInfo.schoolStatus)}}</el-form-item> | ||||
|                 <el-form-item label="民族">{{ dict.getLabel("fpNation", familyInfo.nation) }}</el-form-item> | ||||
|                 <el-form-item label="文化程度">{{ dict.getLabel("fpEducation", familyInfo.education) }}</el-form-item> | ||||
|                 <el-form-item label="政治面貌">{{ dict.getLabel("fpPoliticalOutlook", familyInfo.politicsStatus) }} | ||||
|                 </el-form-item> | ||||
|                 <el-form-item label="在校生状况">{{ dict.getLabel("fpStudentsInSchool", familyInfo.schoolStatus) }} | ||||
|                 </el-form-item> | ||||
|               </div> | ||||
|               <ai-avatar :instance="instance" v-model="familyInfo.photo" :editable="false" /> | ||||
|               <ai-avatar :instance="instance" v-model="familyInfo.photo" :editable="false"/> | ||||
|             </div> | ||||
|             <el-form-item label="健康状况"> | ||||
|               <span v-for="(item, index) in familyInfo.healthyStatusList" :key="index"><span v-if="index > 0">,</span>{{dict.getLabel("fpHealth", item)}}</span> | ||||
|               <span v-for="(item, index) in familyInfo.healthyStatusList" :key="index"><span | ||||
|                   v-if="index > 0">,</span>{{ dict.getLabel("fpHealth", item) }}</span> | ||||
|             </el-form-item> | ||||
|             <div flex class="half wrap"> | ||||
|               <el-form-item label="残疾类别">{{dict.getLabel("fpDisabilityType", familyInfo.disabilityType)}}</el-form-item> | ||||
|               <el-form-item label="残疾办证年度">{{familyInfo.disabilityCertificateYear}}</el-form-item> | ||||
|               <el-form-item label="残疾类别">{{ dict.getLabel("fpDisabilityType", familyInfo.disabilityType) }}</el-form-item> | ||||
|               <el-form-item label="残疾办证年度">{{ dict.getLabel("fpYear", familyInfo.disabilityCertificateYear) }}</el-form-item> | ||||
|             </div> | ||||
|             <div flex class="half wrap"> | ||||
|               <el-form-item label="城乡居民基本医疗保险">{{dict.getLabel("fpYesOrNo", familyInfo.jcbxCxyiliao)}}</el-form-item> | ||||
|               <el-form-item label="城镇职工基本医疗保险">{{dict.getLabel("fpYesOrNo", familyInfo.jcbxCzyiliao)}}</el-form-item> | ||||
|               <el-form-item label="大病保险">{{dict.getLabel("fpYesOrNo", familyInfo.jcbxDabing)}}</el-form-item> | ||||
|               <el-form-item label="商业补充医疗保险">{{dict.getLabel("fpYesOrNo", familyInfo.jcbxShangye)}}</el-form-item> | ||||
|               <el-form-item label="城乡居民基本养老保险">{{dict.getLabel("fpYesOrNo", familyInfo.jcbxCxyanglao)}}</el-form-item> | ||||
|               <el-form-item label="城镇职工基本养老保险">{{dict.getLabel("fpYesOrNo", familyInfo.jcbxCzyanglao)}}</el-form-item> | ||||
|               <el-form-item label="享受人身意外保险补贴">{{dict.getLabel("fpYesOrNo", familyInfo.jcbxRenshenyiwai)}}</el-form-item> | ||||
|               <el-form-item label="享受农村最低生活保障">{{dict.getLabel("fpYesOrNo", familyInfo.bzcsNongcundibao)}}</el-form-item> | ||||
|               <el-form-item label="是否特困供养人员">{{dict.getLabel("fpYesOrNo", familyInfo.bzcsTekungongyang)}}</el-form-item> | ||||
|               <el-form-item label="分散供养五保户转集中供养(减少)">{{dict.getLabel("fpYesOrNo", familyInfo.bzcsWubaohu)}}</el-form-item> | ||||
|               <el-form-item label="是否接受医疗救助">{{dict.getLabel("fpYesOrNo", familyInfo.bzcsYiliaojiuzhu)}}</el-form-item> | ||||
|               <el-form-item label="是否接受其它健康扶贫">{{dict.getLabel("fpYesOrNo", familyInfo.bzcsQita)}}</el-form-item> | ||||
|               <el-form-item label="劳动技能">{{dict.getLabel("fpLaborSkills", familyInfo.labourStatus)}}</el-form-item> | ||||
|               <el-form-item label="是否会讲普通话">{{dict.getLabel("fpYesOrNo", familyInfo.mandarin)}}</el-form-item> | ||||
|               <el-form-item label="务工时间(月)">{{familyInfo.workeMonths}}</el-form-item> | ||||
|               <el-form-item label="就业渠道">{{dict.getLabel("fpEmploymentChannels", familyInfo.employmentChannels)}}</el-form-item> | ||||
|               <el-form-item label="务工企业名称">{{familyInfo.migrantEnterprises}}</el-form-item> | ||||
|               <el-form-item label="公益性岗位">{{familyInfo.publicWelfarePosts}}</el-form-item> | ||||
|               <el-form-item label="是否国外务工">{{dict.getLabel("fpYesOrNo", familyInfo.foreignWorkers)}}</el-form-item> | ||||
|               <el-form-item label="公益性岗位(月数)">{{familyInfo.publicWelfarePostsMonths}}</el-form-item> | ||||
|               <el-form-item label="城乡居民基本医疗保险">{{ dict.getLabel("fpYesOrNo", familyInfo.jcbxCxyiliao) }}</el-form-item> | ||||
|               <el-form-item label="城镇职工基本医疗保险">{{ dict.getLabel("fpYesOrNo", familyInfo.jcbxCzyiliao) }}</el-form-item> | ||||
|               <el-form-item label="大病保险">{{ dict.getLabel("fpYesOrNo", familyInfo.jcbxDabing) }}</el-form-item> | ||||
|               <el-form-item label="商业补充医疗保险">{{ dict.getLabel("fpYesOrNo", familyInfo.jcbxShangye) }}</el-form-item> | ||||
|               <el-form-item label="城乡居民基本养老保险">{{ dict.getLabel("fpYesOrNo", familyInfo.jcbxCxyanglao) }}</el-form-item> | ||||
|               <el-form-item label="城镇职工基本养老保险">{{ dict.getLabel("fpYesOrNo", familyInfo.jcbxCzyanglao) }}</el-form-item> | ||||
|               <el-form-item label="享受人身意外保险补贴">{{ dict.getLabel("fpYesOrNo", familyInfo.jcbxRenshenyiwai) }}</el-form-item> | ||||
|               <el-form-item label="享受农村最低生活保障">{{ dict.getLabel("fpYesOrNo", familyInfo.bzcsNongcundibao) }}</el-form-item> | ||||
|               <el-form-item label="是否特困供养人员">{{ dict.getLabel("fpYesOrNo", familyInfo.bzcsTekungongyang) }}</el-form-item> | ||||
|               <el-form-item label="分散供养五保户转集中供养(减少)">{{ dict.getLabel("fpYesOrNo", familyInfo.bzcsWubaohu) }}</el-form-item> | ||||
|               <el-form-item label="是否接受医疗救助">{{ dict.getLabel("fpYesOrNo", familyInfo.bzcsYiliaojiuzhu) }}</el-form-item> | ||||
|               <el-form-item label="是否接受其它健康扶贫">{{ dict.getLabel("fpYesOrNo", familyInfo.bzcsQita) }}</el-form-item> | ||||
|               <el-form-item label="劳动技能">{{ dict.getLabel("fpLaborSkills", familyInfo.labourStatus) }}</el-form-item> | ||||
|               <el-form-item label="是否会讲普通话">{{ dict.getLabel("fpYesOrNo", familyInfo.mandarin) }}</el-form-item> | ||||
|               <el-form-item label="务工时间(月)">{{ familyInfo.workeMonths }}</el-form-item> | ||||
|               <el-form-item label="就业渠道">{{ dict.getLabel("fpEmploymentChannels", familyInfo.employmentChannels) }}</el-form-item> | ||||
|               <el-form-item label="务工企业名称">{{ familyInfo.migrantEnterprises }}</el-form-item> | ||||
|               <el-form-item label="公益性岗位">{{ familyInfo.publicWelfarePosts }}</el-form-item> | ||||
|               <el-form-item label="是否国外务工">{{ dict.getLabel("fpYesOrNo", familyInfo.foreignWorkers) }}</el-form-item> | ||||
|               <el-form-item label="公益性岗位(月数)">{{ familyInfo.publicWelfarePostsMonths }}</el-form-item> | ||||
|             </div> | ||||
|             <el-form-item label="务工所在地">{{familyInfo.foreignWorkersAddress}} | ||||
|             </el-form-item> | ||||
|             <el-form-item label="现住址">{{currentFullAddressFamily}}</el-form-item> | ||||
|             <el-form-item label="务工所在地">{{ familyInfo.foreignWorkersAddress }}</el-form-item> | ||||
|             <el-form-item label="现住址">{{ currentFullAddressFamily }}</el-form-item> | ||||
|           </el-form> | ||||
|           <template slot="footer"> | ||||
|             <el-button @click="isShowDetail=false">关闭</el-button> | ||||
|           </template> | ||||
|         </ai-dialog> | ||||
|         <ai-dialog :visible.sync="isShowApply" :title="dialogTitle" @closed="applyInfo={},applyFileList=[]" @onConfirm="submitApply" width="600px"> | ||||
|         <ai-dialog :visible.sync="isShowApply" :title="dialogTitle" @closed="applyInfo={},applyFileList=[]" | ||||
|                    @onConfirm="submitApply" width="600px"> | ||||
|           <el-form :model="applyInfo" :rules="rulesApply" ref="dialogApplyInfo" size="small" label-width="120px"> | ||||
|             <el-form-item label="风险因素" prop="riskType" v-if="changeStatus == 0 || changeStatus == 1"> | ||||
|               <ai-select v-model="applyInfo.riskType" :selectList="dict.getDict('fpRiskType')" /> | ||||
|               <ai-select v-model="applyInfo.riskType" :selectList="dict.getDict('fpRiskType')"/> | ||||
|             </el-form-item> | ||||
|             <el-form-item label="风险消除方式" prop="riskEliminationMethod" v-if="changeStatus == 3 || changeStatus == 4"> | ||||
|               <ai-select v-model="applyInfo.riskEliminationMethod" :selectList="dict.getDict('fpRiskEliminationMethod')" /> | ||||
|               <ai-select v-model="applyInfo.riskEliminationMethod" | ||||
|                          :selectList="dict.getDict('fpRiskEliminationMethod')"/> | ||||
|             </el-form-item> | ||||
|             <el-form-item label="备注说明"> | ||||
|               <el-input type="textarea" v-model="applyInfo.opinion" placeholder="请输入" maxlength="500" show-word-limit rows="5" /> | ||||
|               <el-input type="textarea" v-model="applyInfo.opinion" placeholder="请输入" maxlength="500" show-word-limit | ||||
|                         rows="5"/> | ||||
|             </el-form-item> | ||||
|             <el-form-item label="图片"> | ||||
|               <ai-uploader v-model="applyFileList" :instance="instance" acceptType=".jpg,.jpeg,.png"> | ||||
| @@ -379,16 +440,18 @@ | ||||
|           </el-steps> | ||||
|           <div class="info" v-if="examineStep == 1"> | ||||
|             <ai-wrapper label-width="120px" :columnsNumber="2" style="margin-top: 16px;"> | ||||
|               <ai-info-item label="操作类型" :value="changeStatus == 2 ? '申请纳入监测' : '申请解除风险' " /> | ||||
|               <ai-info-item label="风险因素" :value="dict.getLabel('fpRiskType', examineInfo.bizDictValue)" v-if="changeStatus == 2" /> | ||||
|               <ai-info-item label="风险消除方式" :value="dict.getLabel('fpRiskEliminationMethod', examineInfo.bizDictValue)" v-if="changeStatus == 5" /> | ||||
|               <ai-info-item label="申请人" :value="examineInfo.operationUserName" /> | ||||
|               <ai-info-item label="申请时间" :value="examineInfo.createTime" /> | ||||
|               <ai-info-item label="操作类型" :value="changeStatus == 2 ? '申请纳入监测' : '申请解除风险' "/> | ||||
|               <ai-info-item label="风险因素" :value="dict.getLabel('fpRiskType', examineInfo.bizDictValue)" | ||||
|                             v-if="changeStatus == 2"/> | ||||
|               <ai-info-item label="风险消除方式" :value="dict.getLabel('fpRiskEliminationMethod', examineInfo.bizDictValue)" | ||||
|                             v-if="changeStatus == 5"/> | ||||
|               <ai-info-item label="申请人" :value="examineInfo.operationUserName"/> | ||||
|               <ai-info-item label="申请时间" :value="examineInfo.createTime"/> | ||||
|             </ai-wrapper> | ||||
|             <ai-wrapper label-width="120px" :columnsNumber="1"> | ||||
|               <ai-info-item label="备注说明" :value="examineInfo.detail" /> | ||||
|               <ai-info-item label="备注说明" :value="examineInfo.detail"/> | ||||
|             </ai-wrapper> | ||||
|             <ai-uploader v-model="examineInfo.files" disabled style="padding-left:150px;" /> | ||||
|             <ai-uploader v-model="examineInfo.files" disabled style="padding-left:150px;"/> | ||||
|           </div> | ||||
|           <div class="form" v-if="examineStep == 2"> | ||||
|             <el-form :model="examineFrom" size="small" label-width="80px"> | ||||
| @@ -400,7 +463,8 @@ | ||||
|                 </el-radio-group> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="备注说明"> | ||||
|                 <el-input type="textarea" v-model="examineFrom.opinion" placeholder="请输入" maxlength="500" show-word-limit rows="5" /> | ||||
|                 <el-input type="textarea" v-model="examineFrom.opinion" placeholder="请输入" maxlength="500" | ||||
|                           show-word-limit rows="5"/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="图片"> | ||||
|                 <ai-uploader v-model="examineFileList" :instance="instance" acceptType=".jpg,.jpeg,.png"> | ||||
| @@ -416,7 +480,7 @@ | ||||
|             <p>审核成功</p> | ||||
|           </div> | ||||
|           <template slot="footer" v-if="examineStep != 3"> | ||||
|             <el-button @click="cancelExamine">{{examineStep == 2 ? '上一步' : '取消'}}</el-button> | ||||
|             <el-button @click="cancelExamine">{{ examineStep == 2 ? '上一步' : '取消' }}</el-button> | ||||
|             <el-button type="primary" @click="examineNext">下一步</el-button> | ||||
|           </template> | ||||
|           <template slot="footer" v-if="examineStep == 3"> | ||||
| @@ -429,13 +493,13 @@ | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import { mapState } from "vuex"; | ||||
| import {mapState} from "vuex"; | ||||
| import HrMeasure from "./detail/hrMeasure"; | ||||
| import HrLog from "./detail/hrLog"; | ||||
|  | ||||
| export default { | ||||
|   name: "hrDetail", | ||||
|   components: { HrLog, HrMeasure }, | ||||
|   components: {HrLog, HrMeasure}, | ||||
|   props: { | ||||
|     instance: Function, | ||||
|     dict: Object, | ||||
| @@ -450,47 +514,47 @@ export default { | ||||
|           prop: "householdRelation", | ||||
|           dict: "fpRelationship", | ||||
|         }, | ||||
|         { label: "姓名", prop: "name" }, | ||||
|         { label: "性别", prop: "sex", dict: "sex" }, | ||||
|         { label: "年龄", prop: "age" }, | ||||
|         {label: "姓名", prop: "name"}, | ||||
|         {label: "性别", prop: "sex", dict: "sex"}, | ||||
|         {label: "年龄", prop: "age"}, | ||||
|         { | ||||
|           label: "身份证号", | ||||
|           render: (h, { row }) => | ||||
|             h("p", null, this.idCardNoUtil.hideId(row.idNumber)), | ||||
|           label: "证件号", | ||||
|           render: (h, {row}) => | ||||
|               h("p", null, this.idCardNoUtil.hideId(row.idNumber)), | ||||
|         }, | ||||
|         { slot: "options" }, | ||||
|         {slot: "options"}, | ||||
|       ]; | ||||
|     }, | ||||
|     isGridAdmin() { | ||||
|       return this.user.info.girdCheckType == 2; | ||||
|     }, | ||||
|     currentFullAddress() { | ||||
|       let { countyName, townName, villageName, currentAddress } = this.detail; | ||||
|       let {countyName, townName, villageName, currentAddress} = this.detail; | ||||
|       return [countyName, townName, villageName, currentAddress].join(""); | ||||
|     }, | ||||
|     currentFullAddressFamily() { | ||||
|       let { countyName, townName, villageName, currentAddress } = this.familyInfo; | ||||
|       let {countyName, townName, villageName, currentAddress} = this.familyInfo; | ||||
|       return [countyName, townName, villageName, currentAddress].join(""); | ||||
|     }, | ||||
|     rules() { | ||||
|       return { | ||||
|         idNumber: [{ required: true, message: "请输入身份证号" }], | ||||
|         name: [{ required: true, message: "请输入姓名" }], | ||||
|         sex: [{ required: true, message: "请选择性别" }], | ||||
|         phone: [{ required: true, message: "请输入联系方式" }], | ||||
|         idNumber: [{required: true, message: "请输入证件号"}], | ||||
|         name: [{required: true, message: "请输入姓名"}], | ||||
|         sex: [{required: true, message: "请选择性别"}], | ||||
|         phone: [{required: true, message: "请输入联系方式"}], | ||||
|         currentAreaId: [ | ||||
|           { required: true, message: "请选择现住址" }, | ||||
|           { pattern: /[^0]0{0,2}$/, message: "请选择到村/社区" }, | ||||
|           {required: true, message: "请选择现住址"}, | ||||
|           {pattern: /[^0]0{0,2}$/, message: "请选择到村/社区"}, | ||||
|         ], | ||||
|         isHousehold: [{ required: true, message: "请选择是否户主" }], | ||||
|         householdRelation: [{ required: true, message: "请选择与户主关系" }], | ||||
|         householdIdNumber: [{ required: true, message: "请选择户主身份证号" }], | ||||
|         isHousehold: [{required: true, message: "请选择是否户主"}], | ||||
|         householdRelation: [{required: true, message: "请选择与户主关系"}], | ||||
|         householdIdNumber: [{required: true, message: "请选择户主证件号"}], | ||||
|       }; | ||||
|     }, | ||||
|     rulesApply() { | ||||
|       return { | ||||
|         riskType: [{ required: true, message: "请选择风险因素" }], | ||||
|         riskEliminationMethod: [{ required: true, message: "请选择风险消除方式" }], | ||||
|         riskType: [{required: true, message: "请选择风险因素"}], | ||||
|         riskEliminationMethod: [{required: true, message: "请选择风险消除方式"}], | ||||
|       }; | ||||
|     }, | ||||
|     rootArea() { | ||||
| @@ -522,7 +586,7 @@ export default { | ||||
|       detail: {}, | ||||
|       currentTab: "", | ||||
|       isShowAdd: false, | ||||
|       form: { healthyStatusList: [], basicsList: [], guaranteeList: [] }, | ||||
|       form: {healthyStatusList: [], basicsList: [], guaranteeList: []}, | ||||
|       isEdit: false, | ||||
|       isShowDetail: false, | ||||
|       familyInfo: {}, | ||||
| @@ -533,7 +597,7 @@ export default { | ||||
|       isShowExamine: false, | ||||
|       examineInfo: {}, | ||||
|       examineStep: 1, //审批步骤 | ||||
|       examineFrom: { pass: 1 }, | ||||
|       examineFrom: {pass: 1}, | ||||
|       applyFileList: [], | ||||
|       examineFileList: [], | ||||
|       changeStatus: 0,  //操作状态 0:申请纳入监测 1:纳入监测 2:纳入监测审批 3:申请解除风险 4:解除风险 5:解除风险审批 | ||||
| @@ -579,7 +643,7 @@ export default { | ||||
|       if (row && row.guaranteeCheck) { | ||||
|         row.guaranteeList = row.guaranteeCheck.split(',') | ||||
|       } | ||||
|       this.form = { ...row } | ||||
|       this.form = {...row} | ||||
|       this.isShowAdd = true | ||||
|     }, | ||||
|     viewFamily(row) { | ||||
| @@ -595,7 +659,7 @@ export default { | ||||
|       if (row.guaranteeCheck) { | ||||
|         row.guaranteeList = row.guaranteeCheck.split(',') | ||||
|       } | ||||
|       this.familyInfo = { ...row } | ||||
|       this.familyInfo = {...row} | ||||
|       this.isShowDetail = true | ||||
|     }, | ||||
|     delFamily(row) { | ||||
| @@ -612,8 +676,8 @@ export default { | ||||
|       }) | ||||
|     }, | ||||
|     handleIdNumberAutocomplete(v) { | ||||
|       let { birthday: birthDate, sex } = this.idCardNoUtil.getIdCardInfo(v); | ||||
|       this.form = { ...this.form, birthDate, sex, age: this.$calcAge(v) }; | ||||
|       let {birthday: birthDate, sex} = this.idCardNoUtil.getIdCardInfo(v); | ||||
|       this.form = {...this.form, birthDate, sex, age: this.$calcAge(v)}; | ||||
|     }, | ||||
|     onConfirm() { | ||||
|       this.$refs.ruleForm.validate((v) => { | ||||
| @@ -629,19 +693,19 @@ export default { | ||||
|           if (this.form.guaranteeList.length) { | ||||
|             this.form.guaranteeCheck = this.form.basicsList.join(',') | ||||
|           } | ||||
|           this.checkInit('jcbxCxyiliao',this.form.basicsList, '0') | ||||
|           this.checkInit('jcbxCzyiliao',this.form.basicsList, '1') | ||||
|           this.checkInit('jcbxDabing',this.form.basicsList, '2') | ||||
|           this.checkInit('jcbxShangye',this.form.basicsList, '3') | ||||
|           this.checkInit('jcbxCxyanglao',this.form.basicsList, '4') | ||||
|           this.checkInit('jcbxCzyanglao',this.form.basicsList, '5') | ||||
|           this.checkInit('jcbxRenshenyiwai',this.form.basicsList, '6') | ||||
|           this.checkInit('jcbxCxyiliao', this.form.basicsList, '0') | ||||
|           this.checkInit('jcbxCzyiliao', this.form.basicsList, '1') | ||||
|           this.checkInit('jcbxDabing', this.form.basicsList, '2') | ||||
|           this.checkInit('jcbxShangye', this.form.basicsList, '3') | ||||
|           this.checkInit('jcbxCxyanglao', this.form.basicsList, '4') | ||||
|           this.checkInit('jcbxCzyanglao', this.form.basicsList, '5') | ||||
|           this.checkInit('jcbxRenshenyiwai', this.form.basicsList, '6') | ||||
|  | ||||
|           this.checkInit('bzcsNongcundibao',this.form.guaranteeList, '0') | ||||
|           this.checkInit('bzcsTekungongyang',this.form.guaranteeList, '1') | ||||
|           this.checkInit('bzcsWubaohu',this.form.guaranteeList, '2') | ||||
|           this.checkInit('bzcsYiliaojiuzhu',this.form.guaranteeList, '3') | ||||
|           this.checkInit('bzcsQita',this.form.guaranteeList, '4') | ||||
|           this.checkInit('bzcsNongcundibao', this.form.guaranteeList, '0') | ||||
|           this.checkInit('bzcsTekungongyang', this.form.guaranteeList, '1') | ||||
|           this.checkInit('bzcsWubaohu', this.form.guaranteeList, '2') | ||||
|           this.checkInit('bzcsYiliaojiuzhu', this.form.guaranteeList, '3') | ||||
|           this.checkInit('bzcsQita', this.form.guaranteeList, '4') | ||||
|           this.instance.post(`/app/apppreventionreturntopoverty/addOrUpdate`, this.form).then(res => { | ||||
|             if (res.code == 0) { | ||||
|               this.getDetail() | ||||
| @@ -653,9 +717,9 @@ export default { | ||||
|       }); | ||||
|     }, | ||||
|     checkInit(formName, list, value) { | ||||
|       if(list.includes(value)) { | ||||
|       if (list.includes(value)) { | ||||
|         this.form[formName] = '01' | ||||
|       }else { | ||||
|       } else { | ||||
|         this.form[formName] = '02' | ||||
|       } | ||||
|     }, | ||||
| @@ -666,42 +730,42 @@ export default { | ||||
|       this.$router.push({}); | ||||
|     }, | ||||
|     getDetail() { | ||||
|       let { id } = this.$route.query; | ||||
|       let {id} = this.$route.query; | ||||
|       id && | ||||
|         this.instance | ||||
|           .post("/app/apppreventionreturntopoverty/queryDetailById", null, { | ||||
|             params: { id }, | ||||
|           }) | ||||
|           .then((res) => { | ||||
|             if (res?.data) { | ||||
|               this.detail = res.data; | ||||
|               this.detail.family?.map((e) => { | ||||
|                 e.householdRelation = e.householdRelation || "户主"; | ||||
|               }); | ||||
|  | ||||
|               if (this.detail.healthyStatus) { | ||||
|                 this.detail.healthyStatusList = this.detail.healthyStatus.split(',') | ||||
|               } | ||||
|               if (this.detail.basicsCheck) { | ||||
|                 this.detail.basicsList = this.detail.basicsCheck.split(',') | ||||
|               } | ||||
|               if (this.detail.guaranteeCheck) { | ||||
|                 this.detail.guaranteeList = this.detail.guaranteeCheck.split(',') | ||||
|               } | ||||
|  | ||||
|               if (this.detail.status == 0 && this.isGridAdmin) { | ||||
|                 this.instance.post(`/app/apppreventionreturntopoverty/popup?id=${this.detail.id}`).then(res => { | ||||
|                   if (res.code == 0 && res.data) { //纳入监测审批 | ||||
|                     this.girdAdminApplyStatus = 1 | ||||
|                   } | ||||
|                 }) | ||||
|               } | ||||
|             } | ||||
|       this.instance | ||||
|       .post("/app/apppreventionreturntopoverty/queryDetailById", null, { | ||||
|         params: {id}, | ||||
|       }) | ||||
|       .then((res) => { | ||||
|         if (res?.data) { | ||||
|           this.detail = res.data; | ||||
|           this.detail.family?.map((e) => { | ||||
|             e.householdRelation = e.householdRelation || "户主"; | ||||
|           }); | ||||
|  | ||||
|           if (this.detail.healthyStatus) { | ||||
|             this.detail.healthyStatusList = this.detail.healthyStatus.split(',') | ||||
|           } | ||||
|           if (this.detail.basicsCheck) { | ||||
|             this.detail.basicsList = this.detail.basicsCheck.split(',') | ||||
|           } | ||||
|           if (this.detail.guaranteeCheck) { | ||||
|             this.detail.guaranteeList = this.detail.guaranteeCheck.split(',') | ||||
|           } | ||||
|  | ||||
|           if (this.detail.status == 0 && this.isGridAdmin) { | ||||
|             this.instance.post(`/app/apppreventionreturntopoverty/popup?id=${this.detail.id}`).then(res => { | ||||
|               if (res.code == 0 && res.data) { //纳入监测审批 | ||||
|                 this.girdAdminApplyStatus = 1 | ||||
|               } | ||||
|             }) | ||||
|           } | ||||
|         } | ||||
|       }); | ||||
|     }, | ||||
|     gotoEdit() { | ||||
|       let { query } = this.$route; | ||||
|       this.$router.push({ query, hash: "#add" }); | ||||
|       let {query} = this.$route; | ||||
|       this.$router.push({query, hash: "#add"}); | ||||
|     }, | ||||
|     applyMonitor(title, status) { | ||||
|       this.dialogTitle = title | ||||
| @@ -768,7 +832,7 @@ export default { | ||||
|         for (let key in this.examineFrom) { | ||||
|           fromData.append(key, this.examineFrom[key]) | ||||
|         } | ||||
|         this.instance.post(url, fromData ).then(res => { | ||||
|         this.instance.post(url, fromData).then(res => { | ||||
|           if (res.code == 0) { | ||||
|             this.getDetail() | ||||
|             this.$message.success('提交成功!'); | ||||
| @@ -777,7 +841,7 @@ export default { | ||||
|       } | ||||
|       if (this.examineStep == 3) { | ||||
|         this.isShowExamine = false | ||||
|         this.examineFrom = { pass: 1 } | ||||
|         this.examineFrom = {pass: 1} | ||||
|         return | ||||
|       } | ||||
|       this.examineStep++ | ||||
| @@ -790,7 +854,7 @@ export default { | ||||
|     }, | ||||
|     handleDelete(ids) { | ||||
|       this.$confirm("是否要删除监测对象").then(() => { | ||||
|         this.instance.post("/app/apppreventionreturntopoverty/delete", null, { params: { ids: ids?.toString() }, }).then((res) => { | ||||
|         this.instance.post("/app/apppreventionreturntopoverty/delete", null, {params: {ids: ids?.toString()},}).then((res) => { | ||||
|           if (res?.code == 0) { | ||||
|             this.$message.success("删除成功!"); | ||||
|             this.back(); | ||||
| @@ -799,7 +863,7 @@ export default { | ||||
|       }) | ||||
|     }, | ||||
|     numberInput(name) { | ||||
|       if(!/^[0-9]*[1-9][0-9]*$/g.test(this.form[name])){ | ||||
|       if (!/^[0-9]*[1-9][0-9]*$/g.test(this.form[name])) { | ||||
|         this.form[name] = '' | ||||
|         return this.$message.error('请输入正整数') | ||||
|       } | ||||
| @@ -838,10 +902,12 @@ export default { | ||||
|   .success { | ||||
|     text-align: center; | ||||
|     padding-top: 20px; | ||||
|  | ||||
|     .el-icon-success { | ||||
|       color: rgb(46, 162, 34); | ||||
|       font-size: 100px; | ||||
|     } | ||||
|  | ||||
|     p { | ||||
|       text-align: center; | ||||
|       font-size: 16px; | ||||
| @@ -866,16 +932,20 @@ export default { | ||||
|   ::v-deep .el-step__icon { | ||||
|     border-color: #ccc !important; | ||||
|   } | ||||
|  | ||||
|   ::v-deep .el-step__line { | ||||
|     background-color: #ccc !important; | ||||
|   } | ||||
|  | ||||
|   ::v-deep .el-step__title, | ||||
|   ::v-deep .is-wait { | ||||
|     color: #666 !important; | ||||
|   } | ||||
|  | ||||
|   ::v-deep .is-finish { | ||||
|     color: #26f !important; | ||||
|   } | ||||
|  | ||||
|   ::v-deep .is-finish .el-step__icon { | ||||
|     border-color: #26f !important; | ||||
|   } | ||||
|   | ||||
| @@ -4,7 +4,9 @@ | ||||
|       <ai-title slot="title" title="监测对象" isShowBottomBorder isShowArea v-model="search.areaId" :instance="instance" | ||||
|                 @change="page.current=1,getTableData()"> | ||||
|         <template #rightBtn> | ||||
|           <el-button type="primary" icon="iconfont iconSetting" @click="dialog=true" v-if="$permissions('app_apppreventionreturntopovertyalarmconfig_edit')">预警规则</el-button> | ||||
|           <el-button type="primary" icon="iconfont iconSetting" @click="dialog=true" v-if="$permissions('app_apppreventionreturntopovertyalarmconfig_edit')"> | ||||
|             预警规则 | ||||
|           </el-button> | ||||
|         </template> | ||||
|       </ai-title> | ||||
|       <template #content> | ||||
| @@ -13,31 +15,32 @@ | ||||
|             <ai-select placeholder="档案状态" v-model="search.status" :selectList="dict.getDict('fpPrtpStatus')" @change="page.current=1,getTableData()"/> | ||||
|             <ai-select placeholder="监测对象类型" v-model="search.objectType" :selectList="dict.getDict('fpType')" @change="page.current=1,getTableData()"/> | ||||
|             <ai-select placeholder="风险因素" v-model="search.riskType" :selectList="dict.getDict('fpRiskType')" @change="page.current=1,getTableData()"/> | ||||
|             <el-date-picker value-format="yyyy-MM-dd HH:mm:ss" v-model="search.birthStart"  type="date" size="small" | ||||
|               unlink-panels placeholder="选择出生开始日期" @change="page.current=1,getTableData()" /> | ||||
|             <el-date-picker value-format="yyyy-MM-dd HH:mm:ss" v-model="search.birthEnd" type="date" size="small" placeholder="选择出生结束日期" | ||||
|               unlink-panels @change="page.current=1,getTableData()" /> | ||||
|             <el-date-picker value-format="yyyy-MM-dd HH:mm:ss" v-model="search.birthStart" type="date" size="small" unlink-panels placeholder="选择出生开始日期" | ||||
|                             @change="page.current=1,getTableData()"/> | ||||
|             <el-date-picker value-format="yyyy-MM-dd HH:mm:ss" v-model="search.birthEnd" type="date" size="small" placeholder="选择出生结束日期" unlink-panels | ||||
|                             @change="page.current=1,getTableData()"/> | ||||
|             <ai-select placeholder="性别" v-model="search.sex" :selectList="dict.getDict('sex')" @change="page.current=1,getTableData()"/> | ||||
|             <!-- <ai-select placeholder="文化程度" v-model="search.education" :selectList="dict.getDict('fpEducation')" @change="page.current=1,getTableData()"/> | ||||
|             <ai-select placeholder="民族" v-model="search.nation" :selectList="dict.getDict('fpNation')" @change="page.current=1,getTableData()"/> | ||||
|             <ai-select placeholder="政治面貌" v-model="search.politicsStatus" :selectList="dict.getDict('fpPoliticalOutlook')" @change="page.current=1,getTableData()"/> --> | ||||
|           </template> | ||||
|           <template #right> | ||||
|             <el-input size="small" placeholder="姓名/身份证/联系方式" v-model="search.con" clearable | ||||
|                       @change="page.current=1,getTableData()"/> | ||||
|             <el-input size="small" placeholder="姓名/证件/联系方式" v-model="search.con" clearable @change="page.current=1,getTableData()"/> | ||||
|           </template> | ||||
|         </ai-search-bar> | ||||
|         <ai-search-bar> | ||||
|           <template #left> | ||||
|             <el-button type="primary" icon="iconfont iconAdd" @click="showEdit()" v-if="$permissions('app_apppreventionreturntopoverty_edit')">添加</el-button> | ||||
|             <el-button icon="iconfont iconDelete" :disabled="!ids.length" @click="handleDelete(ids)" v-if="$permissions('app_apppreventionreturntopoverty_del')">删除</el-button> | ||||
|             <el-button icon="iconfont iconDelete" :disabled="!ids.length" @click="handleDelete(ids)" | ||||
|                        v-if="$permissions('app_apppreventionreturntopoverty_del')">删除 | ||||
|             </el-button> | ||||
|           </template> | ||||
|           <template #right> | ||||
|             <ai-import :instance="instance" name="监测对象" title="导入监测对象" | ||||
|                        suffixName="xlsx" | ||||
|                        url="/app/apppreventionreturntopoverty/downloadTemplate" | ||||
|                        importUrl="/app/apppreventionreturntopoverty/import" | ||||
|                        @onSuccess="page.current=1,search={},getTableData()"/> | ||||
|                        @onSuccess="page.current=1,getTableData()"/> | ||||
|             <ai-download url="/app/apppreventionreturntopoverty/export" :params="{...search,ids}" | ||||
|                          :instance="instance" fileName="监测对象导出文件"/> | ||||
|           </template> | ||||
| @@ -45,15 +48,11 @@ | ||||
|         <ai-table :tableData="tableData" :total="page.total" :current.sync="page.current" :size.sync="page.size" | ||||
|                   @getList="getTableData" :col-configs="colConfigs" :dict="dict" | ||||
|                   @selection-change="v=>ids=v.map(e=>e.id)"> | ||||
|           <el-table-column slot="idNumber" label="身份证号" show-overflow-tooltip align="center"> | ||||
|             <template slot-scope="{row}"> | ||||
|               <ai-id mode="show" v-model="row.idNumber" :showEyes="false"/> | ||||
|             </template> | ||||
|           </el-table-column> | ||||
|           <el-table-column slot="options" label="操作" fixed="right" align="center"> | ||||
|             <template slot-scope="{row}"> | ||||
|               <el-button type="text" @click="showDetail(row.id)" v-if="$permissions('app_apppreventionreturntopoverty_detail')">详情</el-button> | ||||
|               <el-button type="text" @click="handleDelete(row.id)" v-if="$permissions('app_apppreventionreturntopoverty_del') && row.status == 4">删除</el-button> | ||||
|               <el-button type="text" @click="handleDelete(row.id)" v-if="$permissions('app_apppreventionreturntopoverty_del') &&/[34]/.test(row.status)">删除 | ||||
|               </el-button> | ||||
|             </template> | ||||
|           </el-table-column> | ||||
|         </ai-table> | ||||
| @@ -83,26 +82,28 @@ export default { | ||||
|     permissions: Function | ||||
|   }, | ||||
|   computed: { | ||||
|     ...mapState(['user']) | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       search: {name: '', objectType: '', riskType: '',isHousehold: 1}, | ||||
|       page: {current: 1, size: 10, total: 0}, | ||||
|       tableData: [], | ||||
|       colConfigs: [ | ||||
|     ...mapState(['user']), | ||||
|     colConfigs() { | ||||
|       return [ | ||||
|         {type: 'selection'}, | ||||
|         {label: "姓名", prop: "name", align: "center"}, | ||||
|         {label: "性别", prop: "sex", dict: 'sex', align: "center"}, | ||||
|         {slot: "idNumber"}, | ||||
|         {label: "证件号", render: (h, {row}) => h('p', this.idCardNoUtil.hideId(row.idNumber))}, | ||||
|         {label: "年龄", prop: "age", align: "center"}, | ||||
|         {label: "民族", prop: "nation", align: "center", dict: "fpNation"}, | ||||
|         {label: "文化程度", prop: "education", align: "center", dict: "fpEducation"}, | ||||
|         {label: "监测对象类型", prop: "objectType", align: "center", dict:"fpType"}, | ||||
|         {label: "风险因素", prop: "riskType", align: "center", dict:"fpRiskType"}, | ||||
|         {label: "监测对象类型", prop: "objectType", align: "center", dict: "fpType"}, | ||||
|         {label: "风险因素", prop: "riskType", align: "center", dict: "fpRiskType"}, | ||||
|         {label: "档案状态", prop: "status", dict: "fpPrtpStatus", align: "center"}, | ||||
|         {slot: "options"} | ||||
|       ], | ||||
|       ] | ||||
|     } | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       search: {name: '', objectType: '', riskType: '', isHousehold: 1}, | ||||
|       page: {current: 1, size: 10, total: 0}, | ||||
|       tableData: [], | ||||
|       ids: [], | ||||
|       dialog: false, | ||||
|       form: {}, | ||||
| @@ -144,12 +145,15 @@ export default { | ||||
|     submitDialog() { | ||||
|       this.$refs.DialogForm.validate(v => { | ||||
|         if (v) { | ||||
|           let loading = this.$loading({text: "提交中..."}) | ||||
|           this.instance.post(`/app/apppreventionreturntopovertyalarmconfig/addOrUpdate`, this.form).then(res => { | ||||
|             if (res.code == 0) { | ||||
|               this.$message.success('预警规则设置成功'); | ||||
|               this.getTableData() | ||||
|               this.dialog = false | ||||
|             } | ||||
|           }).finally(() => { | ||||
|             loading.close() | ||||
|           }) | ||||
|         } | ||||
|       }) | ||||
|   | ||||
| @@ -148,7 +148,7 @@ export default { | ||||
|     submit() { | ||||
|       this.$refs.ruleForm.validate(v => { | ||||
|         if (v) { | ||||
|           if(this.form.pictureUrlList.length) { | ||||
|           if(this.form.pictureUrlList && this.form.pictureUrlList.length) { | ||||
|             this.form.pictureUrl = this.form.pictureUrlList[0].url | ||||
|           } | ||||
|           this.instance.post(`/app/apppublicityinfo/addOrUpdate`, this.form).then(res => { | ||||
| @@ -166,6 +166,7 @@ export default { | ||||
|         params: {id} | ||||
|       }).then(res => { | ||||
|         if (res?.data) { | ||||
|           res.data.pictureUrlList = [] | ||||
|           if(res.data.pictureUrl) { | ||||
|             res.data.pictureUrlList = [{url: res.data.pictureUrl}] | ||||
|           } | ||||
|   | ||||
| @@ -7,8 +7,9 @@ | ||||
|       <template #content> | ||||
|         <div class="flex fill"> | ||||
|           <div class="type"> | ||||
|             <div class="title">宣传板块<span><el-button type="text" | ||||
|                                                     @click="addType(0, typeList.length+1, '')">添加</el-button></span> | ||||
|             <div class="title">宣传板块 | ||||
|               <span> | ||||
|               <el-button type="text" @click="addType(0, typeList.length+1, '')">添加</el-button></span> | ||||
|             </div> | ||||
|             <div class="list"> | ||||
|               <div class="item" v-for="(item, index) in typeList" :key="index" | ||||
| @@ -36,30 +37,29 @@ | ||||
|             </div> | ||||
|           </div> | ||||
|           <div class="content"> | ||||
|             <ai-search-bar> | ||||
|               <template #right> | ||||
|                 <el-input size="small" placeholder="请输入标题" v-model="search.title" clearable | ||||
|                           @change="page.current=1,getTableData()"/> | ||||
|               </template> | ||||
|             </ai-search-bar> | ||||
|             <ai-search-bar> | ||||
|               <template #left> | ||||
|                 <el-button type="primary" icon="iconfont iconAdd" @click="showEdit('')" | ||||
|                            v-if="typeList.length && miniTypeList.length">添加 | ||||
|                 </el-button> | ||||
|                 <!-- <el-button icon="iconfont iconDelete" :disabled="!ids.length" @click="handleDelete(ids)">删除</el-button> --> | ||||
|               </template> | ||||
|             </ai-search-bar> | ||||
|             <ai-table :tableData="tableData" :total="page.total" :current.sync="page.current" :size.sync="page.size" | ||||
|                       @getList="getTableData" :col-configs="colConfigs" :dict="dict" | ||||
|                       @selection-change="v=>ids=v.map(e=>e.id)"> | ||||
|               <el-table-column slot="options" label="操作" fixed="right" align="center" width='150px'> | ||||
|                 <template slot-scope="{row}"> | ||||
|                   <el-button type="text" @click="showEdit(row.id)">编辑</el-button> | ||||
|                   <el-button type="text" @click="handleDelete(row.id)">删除</el-button> | ||||
|             <template v-if="typeList.length && miniTypeList.length"> | ||||
|               <ai-search-bar> | ||||
|                 <template #left> | ||||
|                   <el-button type="primary" icon="iconfont iconAdd" @click="showEdit('')">添加</el-button> | ||||
|                   <!-- <el-button icon="iconfont iconDelete" :disabled="!ids.length" @click="handleDelete(ids)">删除</el-button> --> | ||||
|                 </template> | ||||
|               </el-table-column> | ||||
|             </ai-table> | ||||
|                 <template #right> | ||||
|                   <el-input size="small" placeholder="请输入标题" v-model="search.title" clearable | ||||
|                             @change="page.current=1,getTableData()"/> | ||||
|                 </template> | ||||
|               </ai-search-bar> | ||||
|               <ai-table :tableData="tableData" :total="page.total" :current.sync="page.current" :size.sync="page.size" | ||||
|                         @getList="getTableData" :col-configs="colConfigs" :dict="dict" | ||||
|                         @selection-change="v=>ids=v.map(e=>e.id)"> | ||||
|                 <el-table-column slot="options" label="操作" fixed="right" align="center" width='150px'> | ||||
|                   <template slot-scope="{row}"> | ||||
|                     <el-button type="text" @click="showEdit(row.id)">编辑</el-button> | ||||
|                     <el-button type="text" @click="handleDelete(row.id)">删除</el-button> | ||||
|                   </template> | ||||
|                 </el-table-column> | ||||
|               </ai-table> | ||||
|             </template> | ||||
|             <ai-empty v-else>请选择或者添加模块</ai-empty> | ||||
|           </div> | ||||
|         </div> | ||||
|       </template> | ||||
|   | ||||
| @@ -13,7 +13,6 @@ const promisify = fn => { | ||||
|     return new Promise(function (resolve, reject) { | ||||
|       [].push.call(args, function (err, result) { | ||||
|         if (err) { | ||||
|           console.log(err) | ||||
|           reject(err); | ||||
|         } else { | ||||
|           resolve(result); | ||||
| @@ -50,8 +49,6 @@ const start = () => { | ||||
|     }]) | ||||
|   }).then(res => new Promise(resolve => { | ||||
|     const {PROJECT} = res | ||||
|     let install = path.join(__dirname, PROJECT, 'index.js') | ||||
|     fsExtra.ensureFile(install) | ||||
|     const coreLib = path.join(__dirname, PROJECT, 'core.import.json') | ||||
|     fsExtra.readJson(coreLib, (err, data) => { | ||||
|       chalkTag.info("加载核心库配置..") | ||||
| @@ -94,6 +91,7 @@ const start = () => { | ||||
|           name: "CONFIRM", | ||||
|           type: 'confirm', | ||||
|           message: "未读取到业务应用配置文件,是否要打包整个packages?", | ||||
|           default: false | ||||
|         }]).then(res => { | ||||
|           if (res.CONFIRM) { | ||||
|             findApp(appDir, file => { | ||||
| @@ -115,14 +113,15 @@ const start = () => { | ||||
|     }) | ||||
|   })).then(prj => new Promise(resolve => { | ||||
|     if (prj == 'dvui') { | ||||
|       return resolve(prj) | ||||
|     } | ||||
|     chalkTag.info('正在生成打包文件...') | ||||
|     let bin = path.join(__dirname, prj.toString(), 'index.js'), | ||||
|         coreApps = cores.map(e => `{name:'${e.name}',component:require('../../${e.component}').default}`), | ||||
|         bizApps = apps.map(e => `{name:'${e.name}',component:require('../../${e.component}').default}`), | ||||
|         comps = [...coreApps, ...bizApps], | ||||
|         content = ` | ||||
|       resolve(prj) | ||||
|     } else { | ||||
|       chalkTag.info('正在生成打包文件...') | ||||
|       let install = path.join(__dirname, PROJECT, 'index.js') | ||||
|       fsExtra.ensureFile(install) | ||||
|       let coreApps = cores.map(e => `{name:'${e.name}',component:require('../../${e.component}').default}`), | ||||
|           bizApps = apps.map(e => `{name:'${e.name}',component:require('../../${e.component}').default}`), | ||||
|           comps = [...coreApps, ...bizApps], | ||||
|           content = ` | ||||
|         const apps = [${comps.toString()}] | ||||
|         const install = function (Vue) { | ||||
|           if (install.installed) return Promise.resolve() | ||||
| @@ -154,13 +153,14 @@ const start = () => { | ||||
|             install | ||||
|          } | ||||
|         ` | ||||
|     fsExtra.outputFile(bin, content, err => { | ||||
|       if (err) { | ||||
|         chalkTag.error(err) | ||||
|         reject() | ||||
|       } else chalkTag.done('生成打包文件') | ||||
|       resolve(prj) | ||||
|     }) | ||||
|       fsExtra.outputFile(install, content, err => { | ||||
|         if (err) { | ||||
|           chalkTag.error(err) | ||||
|           reject() | ||||
|         } else chalkTag.done('生成打包文件') | ||||
|         resolve(prj) | ||||
|       }) | ||||
|     } | ||||
|   })).then(project => new Promise((resolve, reject) => { | ||||
|     fsExtra.readJson(path.join(__dirname, project.toString(), 'package.json'), (err, json) => { | ||||
|       let cmd = `vue-cli-service build --target lib --dest project/${project}/dist project/${project}/${project == 'dvui' ? 'entries' : 'index'}.js --name ${json.name}` | ||||
| @@ -171,18 +171,18 @@ const start = () => { | ||||
|         log(stdout); | ||||
|         if (!err) { | ||||
|           chalkTag.done('打包成功!') | ||||
|           resolve(project) | ||||
|           resolve({project, name: json.name}) | ||||
|         } else { | ||||
|           chalkTag.error(err) | ||||
|           reject() | ||||
|         } | ||||
|       }) | ||||
|     }) | ||||
|   })).then(project => { | ||||
|   })).then((prj) => { | ||||
|     chalkTag.info('正在发布中...') | ||||
|     let cmd = `cd ${project}&npm unpublish --force&npm publish` | ||||
|     let cmd = `npm unpublish ${prj.name} --force&npm publish --workspace project/${prj.project}` | ||||
|     exec(cmd, { | ||||
|       cwd: path.join(__dirname, '.') | ||||
|       cwd: path.join(__dirname, '..') | ||||
|     }, (err, stdout) => { | ||||
|       log(stdout); | ||||
|       if (!err) { | ||||
|   | ||||
							
								
								
									
										1
									
								
								project/dvui/layout/AiDvPanel/asset/dq.svg
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								project/dvui/layout/AiDvPanel/asset/dq.svg
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1 @@ | ||||
| <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="180" height="40" viewBox="0 0 180 40"><defs><linearGradient id="a" x1="100%" x2="0%" y1="50%" y2="50%"><stop offset="0%" stop-color="#FF5244"/><stop offset="100%" stop-color="#D21600"/></linearGradient><linearGradient id="d" x1="50%" x2="50%" y1="0%" y2="100%"><stop offset="0%" stop-color="#FFF6C7"/><stop offset="100%" stop-color="#FF9A02"/></linearGradient><filter id="c" width="170%" height="170%" x="-35%" y="-25%" filterUnits="objectBoundingBox"><feOffset dy="2" in="SourceAlpha" result="shadowOffsetOuter1"/><feGaussianBlur in="shadowOffsetOuter1" result="shadowBlurOuter1" stdDeviation="2"/><feColorMatrix in="shadowBlurOuter1" values="0 0 0 0 0.457823822 0 0 0 0 0.0353836399 0 0 0 0 0.0353836399 0 0 0 0.5 0"/></filter><path id="b" d="M14.0068268,4.00341841 C19.1676737,5.93854789 22.2992804,12.1241478 19.6165546,17.1359344 L13.0698171,10.5587743 L15.5689049,8.05113932 L14.0059386,6.49580357 C13.1435377,7.34040354 11.7729399,7.52047681 10.8486002,7.14810955 L5.8726766,12.1267591 L8.69064405,14.9339591 L10.5689895,13.0633646 L17.1135326,19.6296095 C13.9108489,21.3881387 9.47146108,20.8339486 6.19504112,17.4306894 L4.60852179,19.0122006 C5.08399639,19.6710504 5.48226026,20.2679818 5.97736409,20.7685363 C5.93418188,20.8204223 5.79807822,20.9320541 5.79546587,20.9351093 C5.71214222,20.9215829 5.61356765,20.8893337 5.52588659,20.8893337 C4.6818088,20.8893337 4,21.6240357 4,22.4686514 C4,23.3119353 4.68835536,24 5.53242792,24 C6.3769498,24 7.09931278,23.3058249 7.09931278,22.4616793 C7.09931278,22.3631299 7.0770712,22.2733022 7.06004909,22.1804193 L7.30389669,21.941044 C11.0706294,24.4813878 15.1989851,24.797947 19.6409696,22.1398662 L21.4752551,23.9808072 L23.9861142,21.5041262 L22.140047,19.6387699 C27.4379223,11.6549703 20.3738238,3.81244048 14.0068268,4.00341841 L14.0068268,4.00341841 L14.0068268,4.00341841 Z"/></defs><g fill="none" fill-rule="evenodd"><path fill="#850100" d="M148,0 L148,20 L59.9048072,11.9285139 L10,13.9990592 C15.970231,4.66635305 27.2050908,0.226703614 43.7045795,0.680110841 C68.4538125,1.36022168 99.8326471,7.79622159 116.382143,8.89811079 C127.415141,9.6327036 137.954427,6.66666667 148,0 Z"/><path fill="url(#a)" d="M0,32.567 C0,30.6617245 0,28.1127921 0,24.9202028 C9.58415484,22.7190157 8.28549035,6.15276659 30.4031861,2.50814365 C52.5208819,-1.13647928 100.23732,16.019279 119.855503,16.019279 C132.934291,16.019279 145.385696,13.1031801 157.209716,7.27098241 L157.209716,22.1589448 C166.282732,22.9696483 173.879493,26.439 180,32.567 C168.804955,37.9116546 144.843267,40 124.922081,40 C105.000895,40 83.8242706,36.2095908 66.6700235,27.6117443 C49.5157764,19.0138977 29.8385713,12.4021534 20,21 C13.4409524,26.7318977 6.77428577,30.5875644 0,32.567 Z"/><g transform="translate(0 2)"><rect width="28" height="28" fill="#000" fill-rule="nonzero" opacity="0"/><use xlink:href="#b" fill="#000" filter="url(#c)"/><use xlink:href="#b" fill="url(#d)"/></g></g></svg> | ||||
| After Width: | Height: | Size: 2.9 KiB | 
							
								
								
									
										1
									
								
								project/dvui/layout/AiDvPanel/asset/gz.svg
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								project/dvui/layout/AiDvPanel/asset/gz.svg
									
									
									
									
									
										Normal file
									
								
							
										
											
												File diff suppressed because one or more lines are too long
											
										
									
								
							| After Width: | Height: | Size: 12 KiB | 
							
								
								
									
										79
									
								
								project/dvui/layout/AiDvPanel/borders/border5.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										79
									
								
								project/dvui/layout/AiDvPanel/borders/border5.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,79 @@ | ||||
| <template> | ||||
|   <section class="border5"> | ||||
|     <div class="title"> | ||||
|       <div class="title-left"> | ||||
|         <h2>{{ title }}</h2> | ||||
|       </div> | ||||
|       <img src="https://cdn.cunwuyun.cn/dvcp/dv/img/gz.svg" /> | ||||
|     </div> | ||||
|     <div class="slot"> | ||||
|       <slot/> | ||||
|     </div> | ||||
|   </section> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| export default { | ||||
|   name: 'border5', | ||||
|   props: {title: String} | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style lang="scss" scoped> | ||||
|   .border5 { | ||||
|     width: 100%; | ||||
|     height: 100%; | ||||
|     padding-top: 10px; | ||||
|     box-sizing: border-box; | ||||
|     overflow: hidden; | ||||
|  | ||||
|     .slot { | ||||
|       width: 100%; | ||||
|       height: calc(100% - 0px); | ||||
|       padding: 20px 10px 20px; | ||||
|       background: rgba(120, 0, 0, 0.2); | ||||
|       border: 1px solid rgba(203, 45, 0, 0.5); | ||||
|     } | ||||
|  | ||||
|     .title { | ||||
|       display: flex; | ||||
|       position: absolute; | ||||
|       align-items: center; | ||||
|       justify-content: space-between; | ||||
|       top: 0; | ||||
|       left: 0; | ||||
|       z-index: 111; | ||||
|       width: 100%; | ||||
|  | ||||
|       .title-left { | ||||
|         width: 180px; | ||||
|         height: 38px; | ||||
|         padding-left: 32px; | ||||
|         background: url(./../asset/dq.svg); | ||||
|         background-size: 100% 100%; | ||||
|  | ||||
|         h2 { | ||||
|           padding-top: 4px; | ||||
|           font-size: 18px; | ||||
|           font-family: MicrosoftYaHei-Bold, MicrosoftYaHei; | ||||
|           font-weight: bold; | ||||
|           color: #FFFFFF; | ||||
|           line-height: 24px; | ||||
|           text-shadow: 0px 2px 4px rgba(117, 9, 9, 0.5); | ||||
|           background: linear-gradient(180deg, #FFF6C7 0%, #FF9A02 100%); | ||||
|           -webkit-background-clip: text; | ||||
|           -webkit-text-fill-color: transparent; | ||||
|         } | ||||
|       } | ||||
|  | ||||
|       img { | ||||
|         width: 64px; | ||||
|         height: 26px; | ||||
|       } | ||||
|     } | ||||
|  | ||||
|     * { | ||||
|       box-sizing: border-box; | ||||
|     } | ||||
|   } | ||||
| </style> | ||||
| @@ -137,9 +137,9 @@ export default { | ||||
|  | ||||
|     format (list) { | ||||
|       return list.map(item => { | ||||
|         if (item.girdLevel !== '2') { | ||||
|           item.disabled = true | ||||
|         } | ||||
|         // if (item.girdLevel !== '2') { | ||||
|         //   item.disabled = true | ||||
|         // } | ||||
|  | ||||
|         if (item.girdList && item.girdList.length) { | ||||
|           item.girdList = this.format(item.girdList) | ||||
|   | ||||
| @@ -176,7 +176,7 @@ export default { | ||||
|           this.saveData.fileList.map((item) => { | ||||
|             this.saveData.files.push(item.id) | ||||
|           }) | ||||
|           this.instance.post(`/app/appmeetinginfo/add-update`, { | ||||
|           this.instance.post(`/app/appmeetinginfo/add-update-web`, { | ||||
|             ...this.saveData, | ||||
|             status: status, | ||||
|           }).then(res => { | ||||
|   | ||||
| @@ -117,7 +117,7 @@ | ||||
|             if(this.form.releaseTime && (new Date(this.form.releaseTime).getTime() <= Date.now())){ | ||||
|               return this.$message.error("发送时间要大于当前时间") | ||||
|             } | ||||
|             this.instance.post("/app/appannouncement/addOrUpdate", { | ||||
|             this.instance.post("/app/appannouncement/addOrUpdateWeb", { | ||||
|               ...this.form, | ||||
|               status: e | ||||
|             }).then(res => { | ||||
|   | ||||
| @@ -347,10 +347,6 @@ export default { | ||||
|  | ||||
|     format (list) { | ||||
|       return list.map(item => { | ||||
|         if (item.girdLevel !== '2') { | ||||
|           item.disabled = true | ||||
|         } | ||||
|  | ||||
|         if (item.girdList && item.girdList.length) { | ||||
|           item.girdList = this.format(item.girdList) | ||||
|         } | ||||
|   | ||||
| @@ -17,10 +17,10 @@ | ||||
|                 <el-input v-model="forms.girdName" placeholder="请输入…" :maxlength="50" show-word-limit clearable/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="网格长" prop="girdMemberManageList"> | ||||
|                 <AiUserGet :instance="instance" v-model="forms.girdMemberManageList" isShowUser :props="{label:'wxUserId'}"/> | ||||
|                 <AiUserGet :instance="instance" v-model="forms.girdMemberManageList" isShowUser :props="{label:'name', id: 'id'}"/> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="网格员" prop="girdMemberList"> | ||||
|                 <AiUserGet :instance="instance" v-model="forms.girdMemberList" isShowUser :props="{label:'wxUserId'}"/> | ||||
|                 <AiUserGet :instance="instance" v-model="forms.girdMemberList" isShowUser :props="{label:'name', id: 'id'}"/> | ||||
|               </el-form-item> | ||||
|             </template> | ||||
|           </ai-card> | ||||
| @@ -50,7 +50,9 @@ | ||||
|                 <el-input v-model="forms.address" placeholder="限200字" maxlength="200"></el-input> | ||||
|               </el-form-item> | ||||
|               <el-form-item label="网格范围" prop="enclosure"> | ||||
|                 <el-button size="small" @click="showMap = true">地图标绘</el-button> | ||||
|                 <map-plotting v-model="forms.points"> | ||||
|                   <el-button size="small">地图标绘</el-button> | ||||
|                 </map-plotting> | ||||
|               </el-form-item> | ||||
|             </template> | ||||
|           </ai-card> | ||||
| @@ -65,56 +67,16 @@ | ||||
|         </el-button> | ||||
|       </template> | ||||
|     </ai-detail> | ||||
|     <ai-dialog | ||||
|         title="网格范围" | ||||
|         :visible.sync="showMap" | ||||
|         :customFooter="true" | ||||
|         :destroyOnClose="true" | ||||
|         @opened="beforeSelectMap" | ||||
|         border | ||||
|         width="850px" | ||||
|     > | ||||
|       <div class="map"> | ||||
|         <div class="tipinput"> | ||||
|           <el-input | ||||
|               v-model="searchAddress" | ||||
|               @change="addressChange" | ||||
|               clearable | ||||
|               placeholder="请输入关键字" | ||||
|               id="tipinput" | ||||
|               size="medium" | ||||
|               style="width: 200px" | ||||
|           /> | ||||
|         </div> | ||||
|         <div id="panel"/> | ||||
|         <div class="container" id="container"></div> | ||||
|         <el-button-group style="margin-top: 8px" v-if="forms.plottingStatus==1"> | ||||
|           <el-button type="primary" size="mini" @click="polyEditor.open()">开始编辑</el-button> | ||||
|           <el-button size="mini" @click="polyEditor.close()">结束编辑</el-button> | ||||
|         </el-button-group> | ||||
|         <el-button-group | ||||
|             style="margin-top: 8px" | ||||
|             v-if="forms.plottingStatus == 0" | ||||
|         > | ||||
|           <el-button size="mini" @click="draw('polygon')">开始绘制多边形</el-button> | ||||
|           <!-- <el-button  size="mini" @click="close()">关闭绘制</el-button> --> | ||||
|           <el-button size="mini" @click="clear()">清除绘制</el-button> | ||||
|         </el-button-group> | ||||
|       </div> | ||||
|       <div class="dialog-footer" slot="footer"> | ||||
|         <el-button size="medium" @click="showMap = false">取消</el-button> | ||||
|         <el-button type="primary" size="medium" @click="surePotting()">确认</el-button> | ||||
|       </div> | ||||
|     </ai-dialog> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import AMapLoader from "@amap/amap-jsapi-loader"; | ||||
| import {mapState} from "vuex"; | ||||
| import MapPlotting from "./mapPlotting"; | ||||
|  | ||||
| export default { | ||||
|   name: "addBlock", | ||||
|   components: {MapPlotting}, | ||||
|   props: { | ||||
|     instance: Function, | ||||
|     dict: Object, | ||||
| @@ -126,17 +88,7 @@ export default { | ||||
|         girdMemberManageList: [], | ||||
|         girdMemberList: [] | ||||
|       }, | ||||
|       showMap: false, | ||||
|       map: "", | ||||
|       mouseTool: "", | ||||
|       searchAddress: "", | ||||
|       placeSearch: "", | ||||
|       overlays: [], | ||||
|       options: [], | ||||
|       path: [], | ||||
|       location: {}, | ||||
|       polyEditor: "", | ||||
|       title: "添加网格区块", | ||||
|       parentGirdInfo: {}, | ||||
|     }; | ||||
|   }, | ||||
| @@ -177,11 +129,13 @@ export default { | ||||
|     } | ||||
|   }, | ||||
|   created() { | ||||
|     this.getCorpLocation() | ||||
|     if (this.isEdit) { | ||||
|       this.searchDetail(); | ||||
|     } else { | ||||
|       this.forms = this.$route.query | ||||
|       this.forms = { | ||||
|         ...this.forms, | ||||
|         ...this.$route.query | ||||
|       } | ||||
|     } | ||||
|   }, | ||||
|   methods: { | ||||
| @@ -203,147 +157,6 @@ export default { | ||||
|         } | ||||
|       }); | ||||
|     }, | ||||
|     beforeSelectMap() { | ||||
|       AMapLoader.load({ | ||||
|         key: "b553334ba34f7ac3cd09df9bc8b539dc", // 申请好的Web端开发者Key,首次调用 load 时必填 | ||||
|         version: "2.0", // 指定要加载的 JSAPI 的版本,缺省时默认为 1.4.15 | ||||
|         plugins: ["AMap.MouseTool", "AMap.PlaceSearch", "AMap.PolygonEditor"], // 需要使用的的插件列表,如比例尺'AMap.Scale'等 | ||||
|         AMapUI: { | ||||
|           // 是否加载 AMapUI,缺省不加载 | ||||
|           version: "1.1", // AMapUI 缺省 1.1 | ||||
|           plugins: [], // 需要加载的 AMapUI ui插件 | ||||
|         }, | ||||
|       }) | ||||
|       .then((AMap) => { | ||||
|         this.map = new AMap.Map("container", { | ||||
|           resizeEnable: true, | ||||
|         }); | ||||
|         if (this.forms.plottingStatus == 1) { | ||||
|           let path = []; | ||||
|           this.forms.points.map((e, index) => { | ||||
|             path[index] = [e.lng, e.lat]; | ||||
|           }); | ||||
|           let polygon = new AMap.Polygon({ | ||||
|             path: path, | ||||
|             strokeColor: "#FF33FF", | ||||
|             strokeWeight: 6, | ||||
|             strokeOpacity: 0.2, | ||||
|             fillOpacity: 0.4, | ||||
|             fillColor: "#1791fc", | ||||
|             zIndex: 50, | ||||
|             bubble: true, | ||||
|           }); | ||||
|           this.map.add([polygon]); | ||||
|           this.map.setFitView(); | ||||
|           this.polyEditor = new AMap.PolygonEditor(this.map, polygon); | ||||
|         } else { | ||||
|           this.mouseTool = new AMap.MouseTool(this.map); | ||||
|           // this.map.add(new AMap.Marker({ | ||||
|           //     position:this.map.getCenter() | ||||
|           // })); | ||||
|           this.placeSearch = new AMap.PlaceSearch({ | ||||
|             pageSize: 3, // 单页显示结果条数 | ||||
|             pageIndex: 1, // 页码 | ||||
|             city: "", // 兴趣点城市 | ||||
|             citylimit: false, //是否强制限制在设置的城市内搜索 | ||||
|             map: this.map, // 展现结果的地图实例 | ||||
|             panel: "panel", // 结果列表将在此容器中进行展示。 | ||||
|             autoFitView: true, // 是否自动调整地图视野使绘制的 Marker点都处于视口的可见范围 | ||||
|           }); | ||||
|           // this.map.setZoomAndCenter(14, [this.location.lng, this.location.lat], false, 600); | ||||
|           this.eventOn(); | ||||
|         } | ||||
|       }) | ||||
|     }, | ||||
|     getCorpLocation() { | ||||
|       this.instance.post("/app/appdvcpconfig/getCorpLocation").then(res => { | ||||
|         if (res?.data) { | ||||
|           this.location = res.data | ||||
|         } | ||||
|       }) | ||||
|     }, | ||||
|     //地图事件绑定 | ||||
|     eventOn() { | ||||
|       this.path = []; | ||||
|       this.overlays = []; | ||||
|       this.map.on("mousemove", null, this); | ||||
|       this.mouseTool.on("draw", ({obj}) => { | ||||
|         obj.getPath().map((e) => { | ||||
|           this.path.push({lat: e.getLat(), lng: e.getLng()}); | ||||
|         }); | ||||
|         this.overlays.push(obj); | ||||
|       }) | ||||
|     }, | ||||
|     //map搜索 | ||||
|     addressChange(val) { | ||||
|       this.placeSearch.search(val); | ||||
|     }, | ||||
|     close() { | ||||
|       this.mouseTool.close(true); | ||||
|     }, | ||||
|     clear() { | ||||
|       this.map.remove(this.overlays); | ||||
|       this.overlays = []; | ||||
|       this.path = []; | ||||
|     }, | ||||
|     draw(type) { | ||||
|       switch (type) { | ||||
|         case "marker": { | ||||
|           this.mouseTool.marker({ | ||||
|             //同Marker的Option设置 | ||||
|           }); | ||||
|           break; | ||||
|         } | ||||
|         case "polyline": { | ||||
|           this.mouseTool.polyline({ | ||||
|             strokeColor: "#80d8ff", | ||||
|             //同Polyline的Option设置 | ||||
|           }); | ||||
|           break; | ||||
|         } | ||||
|         case "polygon": { | ||||
|           this.mouseTool.polygon({ | ||||
|             fillColor: "#00b0ff", | ||||
|             strokeColor: "#80d8ff", | ||||
|             borderWeight: 2, | ||||
|             strokeWeight: 4, | ||||
|             //同Polygon的Option设置 | ||||
|           }); | ||||
|           break; | ||||
|         } | ||||
|         case "rectangle": { | ||||
|           this.mouseTool.rectangle({ | ||||
|             fillColor: "#00b0ff", | ||||
|             strokeColor: "#80d8ff", | ||||
|             //同Polygon的Option设置 | ||||
|           }); | ||||
|           break; | ||||
|         } | ||||
|         case "circle": { | ||||
|           this.mouseTool.circle({ | ||||
|             fillColor: "#00b0ff", | ||||
|             strokeColor: "#80d8ff", | ||||
|             //同Circle的Option设置 | ||||
|           }); | ||||
|           break; | ||||
|         } | ||||
|       } | ||||
|     }, | ||||
|     surePotting() { | ||||
|       this.forms.points = []; | ||||
|       // this.forms.eventReportUnit = this.$refs.cascader.getCheckedNodes().label; | ||||
|       if (this.forms.plottingStatus == 1) { | ||||
|         this.polyEditor | ||||
|         .getTarget() | ||||
|         .getPath() | ||||
|         .map((e) => { | ||||
|           this.forms.points.push({lng: e.lng, lat: e.lat}); | ||||
|         }); | ||||
|       } else { | ||||
|         this.forms.points = [...this.path]; | ||||
|       } | ||||
|       this.showMap = false; | ||||
|     }, | ||||
|     save() { | ||||
|       this.$refs["rules"].validate((valid) => { | ||||
|         if (valid) { | ||||
| @@ -352,6 +165,16 @@ export default { | ||||
|               `/app/appgirdinfo/addOrUpdate`, | ||||
|               { | ||||
|                 ...this.forms, | ||||
|                 girdMemberManageList: this.forms.girdMemberManageList.length ? this.forms.girdMemberManageList.map(v => { | ||||
|                   return { | ||||
|                     wxUserId: v.wxOpenUserId || v.wxUserId | ||||
|                   } | ||||
|                 }) : [], | ||||
|                 girdMemberList: this.forms.girdMemberList.length ? this.forms.girdMemberList.map(v => { | ||||
|                   return { | ||||
|                     wxUserId: v.wxOpenUserId || v.wxUserId | ||||
|                   } | ||||
|                 }) : [] | ||||
|               }, | ||||
|               null | ||||
|           ) | ||||
| @@ -372,7 +195,21 @@ export default { | ||||
|         params: {id}, | ||||
|       }).then((res) => { | ||||
|         if (res?.data) { | ||||
|           this.forms = {...res.data}; | ||||
|           this.forms = { | ||||
|             ...res.data, | ||||
|             girdMemberManageList: res.data.girdMemberManageList ? res.data.girdMemberManageList.map(v => { | ||||
|               return { | ||||
|                 ...v, | ||||
|                 id: v.wxUserId | ||||
|               } | ||||
|             }) : [], | ||||
|             girdMemberList: res.data.girdMemberList ? res.data.girdMemberList.map(v => { | ||||
|               return { | ||||
|                 ...v, | ||||
|                 id: v.wxUserId | ||||
|               } | ||||
|             }) : [] | ||||
|           }; | ||||
|           this.parentGirdInfo = res.data.parentGirdInfo; | ||||
|           this.forms.parentGirdName = res.data.parentGirdInfo && res.data.parentGirdInfo.girdName; | ||||
|         } | ||||
| @@ -387,48 +224,8 @@ export default { | ||||
|   width: 100%; | ||||
|   height: 100%; | ||||
|  | ||||
|   ::v-deep .amap-copyright { | ||||
|     display: none !important; | ||||
|   } | ||||
|  | ||||
|   ::v-deep .amap-logo { | ||||
|     display: none !important; | ||||
|   } | ||||
|  | ||||
|   .footer-btn { | ||||
|     width: 92px; | ||||
|   } | ||||
|  | ||||
|   .map { | ||||
|     width: 780px; | ||||
|     position: relative; | ||||
|     overflow: hidden; | ||||
|  | ||||
|     .container { | ||||
|       width: 760px; | ||||
|       height: 420px; | ||||
|       border-radius: 2px; | ||||
|       border: 1px solid #d0d4dc; | ||||
|     } | ||||
|  | ||||
|     #panel { | ||||
|       position: absolute; | ||||
|       height: 400px; | ||||
|       right: 30px; | ||||
|       top: 20px; | ||||
|       width: 280px; | ||||
|       overflow: hidden; | ||||
|       z-index: 10000; | ||||
|     } | ||||
|  | ||||
|     .tipinput { | ||||
|       position: absolute; | ||||
|       width: 200px; | ||||
|       height: 38px; | ||||
|       left: 20px; | ||||
|       top: 20px; | ||||
|       z-index: 10000; | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </style> | ||||
|   | ||||
| @@ -5,7 +5,7 @@ | ||||
|         <ai-title title="网格区块" :isShowBottomBorder="true"></ai-title> | ||||
|       </template> | ||||
|       <template slot="left"> | ||||
|         <ai-tree-menu title="网格层级" @search="(v) => $refs.tree.filter(v)"> | ||||
|         <ai-tree-menu title="网格层级" @search="v=> $refs.tree.filter(v)"> | ||||
|           <el-tree | ||||
|               :data="treeObj.treeList" | ||||
|               :props="treeObj.defaultProps" | ||||
| @@ -14,8 +14,11 @@ | ||||
|               ref="tree" | ||||
|               :filter-node-method="filterNode" | ||||
|               default-expand-all | ||||
|               highlight-current | ||||
|           /> | ||||
|               highlight-current> | ||||
|             <template slot-scope="{node,data}"> | ||||
|               <div v-text="node.label"/> | ||||
|             </template> | ||||
|           </el-tree> | ||||
|         </ai-tree-menu> | ||||
|       </template> | ||||
|       <template slot="content"> | ||||
| @@ -115,69 +118,14 @@ | ||||
|               fixed="right" | ||||
|               width="160"> | ||||
|             <template slot-scope="{ row }"> | ||||
|               <div class="table-options"> | ||||
|                 <el-button type="text" @click="showEdit(row.id)">编辑</el-button> | ||||
|                 <el-button type="text" @click="poltting(row)">标绘</el-button> | ||||
|                 <el-button type="text" @click="deleteById(row.id)">删除</el-button> | ||||
|               </div> | ||||
|               <el-button type="text" @click="showEdit(row.id)">编辑</el-button> | ||||
|               <map-plotting :value="row.points" @change="v=>confirm(row,v)"/> | ||||
|               <el-button type="text" @click="deleteById(row.id)">删除</el-button> | ||||
|             </template> | ||||
|           </el-table-column> | ||||
|         </ai-table> | ||||
|       </template> | ||||
|     </ai-list> | ||||
|     <ai-dialog | ||||
|         title="网格范围" | ||||
|         :visible.sync="showMap" | ||||
|         :customFooter="true" | ||||
|         :destroyOnClose="true" | ||||
|         border | ||||
|         width="850px" | ||||
|     > | ||||
|       <div class="map"> | ||||
|         <div class="tipinput"> | ||||
|           <el-input | ||||
|               v-if="editRow.plottingStatus == 0" | ||||
|               v-model="searchAddress" | ||||
|               @change="addressChange" | ||||
|               clearable | ||||
|               placeholder="请输入关键字" | ||||
|               id="tipinput" | ||||
|               size="medium" | ||||
|               style="width: 200px" | ||||
|           ></el-input> | ||||
|         </div> | ||||
|         <div id="panel" v-if="editRow.plottingStatus == 0"></div> | ||||
|         <div class="container" id="container"></div> | ||||
|         <el-button-group | ||||
|             style="margin-top: 8px" | ||||
|             v-if="editRow.plottingStatus == 1" | ||||
|         > | ||||
|           <el-button type="primary" size="mini" @click="beginPoltting()" | ||||
|           >开始编辑 | ||||
|           </el-button | ||||
|           > | ||||
|           <el-button size="mini" @click="finishPoltting()">结束编辑</el-button> | ||||
|         </el-button-group> | ||||
|         <el-button-group | ||||
|             style="margin-top: 8px" | ||||
|             v-if="editRow.plottingStatus == 0" | ||||
|         > | ||||
|           <el-button size="mini" @click="draw('polygon')" | ||||
|           >开始绘制多边形 | ||||
|           </el-button | ||||
|           > | ||||
|           <!-- <el-button  size="mini" @click="close()">关闭绘制</el-button> --> | ||||
|           <el-button size="mini" @click="clear()">清除绘制</el-button> | ||||
|         </el-button-group> | ||||
|       </div> | ||||
|       <div class="dialog-footer" slot="footer"> | ||||
|         <el-button size="medium" @click="showMap = false">取消</el-button> | ||||
|         <el-button type="primary" size="medium" @click="confirm()" | ||||
|         >确认 | ||||
|         </el-button | ||||
|         > | ||||
|       </div> | ||||
|     </ai-dialog> | ||||
|     <ai-dialog :title="`${gridInfo.girdName}网格成员`" :visible.sync="dialog" customFooter @closed="gridInfo={}" | ||||
|                width="700px"> | ||||
|       <ai-table :tableData="gridInfo.tableData" :colConfigs="gridMemberColConfigs" :dict="dict" | ||||
| @@ -196,10 +144,11 @@ | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import AMapLoader from "@amap/amap-jsapi-loader"; | ||||
| import MapPlotting from "./mapPlotting"; | ||||
|  | ||||
| export default { | ||||
|   name: "List", | ||||
|   components: {MapPlotting}, | ||||
|   label: "网格区块", | ||||
|   props: { | ||||
|     instance: Function, | ||||
| @@ -241,12 +190,11 @@ export default { | ||||
|       isEdit: false, | ||||
|       searchId: "", | ||||
|       fileList: [], | ||||
|       location: {}, | ||||
|       dialog: false, | ||||
|       gridInfo: {}, | ||||
|       gridMemberColConfigs: [ | ||||
|         {prop: "wxUserId", openType: 'userName'}, | ||||
|         {prop: "girdMemberType", dict: "girdMemberType"}, | ||||
|         {prop: "checkType", formart: v => v === '1' ? '网格员' : '网格长'}, | ||||
|         {slot: "tags"} | ||||
|       ] | ||||
|     }; | ||||
| @@ -254,7 +202,6 @@ export default { | ||||
|   created() { | ||||
|     this.getTreeList(); | ||||
|     this.getList(); | ||||
|     this.getCorpLocation() | ||||
|     this.dict.load("girdLevel", "girdType", "isLastLevel", "plottingStatus", "girdMemberType"); | ||||
|   }, | ||||
|   computed: { | ||||
| @@ -270,13 +217,6 @@ export default { | ||||
|     }, | ||||
|   }, | ||||
|   methods: { | ||||
|     getCorpLocation() { | ||||
|       this.instance.post("/app/appdvcpconfig/getCorpLocation").then(res => { | ||||
|         if (res.code == 0) { | ||||
|           this.location = res.data | ||||
|         } | ||||
|       }) | ||||
|     }, | ||||
|     handleNodeClick(val) { | ||||
|       this.info = {...val}; | ||||
|       this.searchId = val.id; | ||||
| @@ -303,7 +243,7 @@ export default { | ||||
|     }, | ||||
|     deleteById(ids) { | ||||
|       ids && | ||||
|       this.$confirm("是否要删除该网格区块?", { | ||||
|       this.$confirm("删除网格后,会清除网格内网格员和责任家庭信息,如有下级网格,会同步删除下级网格所有数据!", { | ||||
|         type: "error", | ||||
|       }) | ||||
|       .then(() => { | ||||
| @@ -316,6 +256,7 @@ export default { | ||||
|             this.$message.success("删除成功!"); | ||||
|  | ||||
|             this.getList(); | ||||
|             this.getTreeList(); | ||||
|           } | ||||
|         }); | ||||
|       }) | ||||
| @@ -386,162 +327,18 @@ export default { | ||||
|         this.getTreeList(); | ||||
|       }); | ||||
|     }, | ||||
|     poltting(row) { | ||||
|       this.showMap = true; | ||||
|       this.editRow = {...row}; | ||||
|       AMapLoader.load({ | ||||
|         key: "b553334ba34f7ac3cd09df9bc8b539dc", // 申请好的Web端开发者Key,首次调用 load 时必填 | ||||
|         version: "2.0", // 指定要加载的 JSAPI 的版本,缺省时默认为 1.4.15 | ||||
|         plugins: ["AMap.PolygonEditor", "AMap.MouseTool", "AMap.PlaceSearch"], // 需要使用的的插件列表,如比例尺'AMap.Scale'等 | ||||
|         AMapUI: { | ||||
|           // 是否加载 AMapUI,缺省不加载 | ||||
|           version: "1.1", // AMapUI 缺省 1.1 | ||||
|           plugins: [], // 需要加载的 AMapUI ui插件 | ||||
|         }, | ||||
|       }) | ||||
|       .then((AMap) => { | ||||
|         this.map = new AMap.Map("container", { | ||||
|           resizeEnable: true, | ||||
|           zoom: 14, | ||||
|         }); | ||||
|         if (this.editRow.plottingStatus == 1) { | ||||
|           let path = []; | ||||
|           this.editRow.points.map((e, index) => { | ||||
|             path[index] = [e.lng, e.lat]; | ||||
|           }); | ||||
|           let polygon = new AMap.Polygon({ | ||||
|             path: path, | ||||
|             strokeColor: "#FF33FF", | ||||
|             strokeWeight: 6, | ||||
|             strokeOpacity: 0.2, | ||||
|             fillOpacity: 0.4, | ||||
|             fillColor: "#1791fc", | ||||
|             zIndex: 50, | ||||
|             bubble: true, | ||||
|           }); | ||||
|           this.map.add([polygon]); | ||||
|           this.map.setFitView(); | ||||
|           this.polyEditor = new AMap.PolygonEditor(this.map, polygon); | ||||
|         } else { | ||||
|           this.mouseTool = new AMap.MouseTool(this.map); | ||||
|           this.placeSearch = new AMap.PlaceSearch({ | ||||
|             pageSize: 3, // 单页显示结果条数 | ||||
|             pageIndex: 1, // 页码 | ||||
|             city: "", // 兴趣点城市 | ||||
|             citylimit: false, //是否强制限制在设置的城市内搜索 | ||||
|             map: this.map, // 展现结果的地图实例 | ||||
|             panel: "panel", // 结果列表将在此容器中进行展示。 | ||||
|             autoFitView: true, // 是否自动调整地图视野使绘制的 Marker点都处于视口的可见范围 | ||||
|           }); | ||||
|           // this.map.setZoomAndCenter(14, [this.location.lng, this.location.lat], false, 600); | ||||
|           this.eventOn(); | ||||
|         } | ||||
|       }) | ||||
|       .catch((e) => { | ||||
|         console.log(e); | ||||
|       }); | ||||
|     }, | ||||
|     showEdit(id) { | ||||
|       this.$router.push({hash: "#add", query: {id}}) | ||||
|     }, | ||||
|     draw(type) { | ||||
|       switch (type) { | ||||
|         case "marker": { | ||||
|           this.mouseTool.marker({ | ||||
|             //同Marker的Option设置 | ||||
|           }); | ||||
|           break; | ||||
|         } | ||||
|         case "polyline": { | ||||
|           this.mouseTool.polyline({ | ||||
|             strokeColor: "#80d8ff", | ||||
|             //同Polyline的Option设置 | ||||
|           }); | ||||
|           break; | ||||
|         } | ||||
|         case "polygon": { | ||||
|           this.mouseTool.polygon({ | ||||
|             fillColor: "#00b0ff", | ||||
|             strokeColor: "#80d8ff", | ||||
|             borderWeight: 2, | ||||
|             strokeWeight: 4, | ||||
|             //同Polygon的Option设置 | ||||
|           }); | ||||
|           break; | ||||
|         } | ||||
|         case "rectangle": { | ||||
|           this.mouseTool.rectangle({ | ||||
|             fillColor: "#00b0ff", | ||||
|             strokeColor: "#80d8ff", | ||||
|             //同Polygon的Option设置 | ||||
|           }); | ||||
|           break; | ||||
|         } | ||||
|         case "circle": { | ||||
|           this.mouseTool.circle({ | ||||
|             fillColor: "#00b0ff", | ||||
|             strokeColor: "#80d8ff", | ||||
|             //同Circle的Option设置 | ||||
|           }); | ||||
|           break; | ||||
|         } | ||||
|       } | ||||
|     }, | ||||
|     //map搜索 | ||||
|     addressChange(val) { | ||||
|       this.placeSearch.search(val); | ||||
|     }, | ||||
|     close() { | ||||
|       this.mouseTool.close(true); | ||||
|     }, | ||||
|     clear() { | ||||
|       this.map.remove(this.overlays); | ||||
|       this.overlays = []; | ||||
|       this.path = []; | ||||
|     }, | ||||
|     beginPoltting() { | ||||
|       this.polyEditor.open(); | ||||
|     }, | ||||
|     finishPoltting() { | ||||
|       this.polyEditor.close(); | ||||
|     }, | ||||
|     confirm() { | ||||
|       let path = []; | ||||
|       if (this.editRow.plottingStatus == 1) { | ||||
|         this.polyEditor | ||||
|         .getTarget() | ||||
|         .getPath() | ||||
|         .map((e) => { | ||||
|           path.push({lng: e.lng, lat: e.lat}); | ||||
|         }); | ||||
|       } else { | ||||
|         path = [...this.path]; | ||||
|       } | ||||
|       delete this.editRow.points; | ||||
|       let {girdMemberNames} = this.editRow | ||||
|       this.instance.post(`/app/appgirdinfo/addOrUpdate`, { | ||||
|         ...this.editRow, | ||||
|         points: path, | ||||
|         girdMemberNames: girdMemberNames?.toString() | ||||
|       }).then((res) => { | ||||
|     confirm(row, points) { | ||||
|       this.instance.post(`/app/appgirdinfo/addOrUpdate`, {...row, points}).then((res) => { | ||||
|         if (res.code == 0) { | ||||
|           this.$message.success("提交成功!") | ||||
|           this.getList(); | ||||
|           this.showMap = false; | ||||
|         } | ||||
|       }); | ||||
|     }, | ||||
|     eventOn() { | ||||
|       this.path = []; | ||||
|       this.overlays = []; | ||||
|       this.map.on("mousemove", this.showInfoMove, this); | ||||
|       this.mouseTool.on("draw", ({type, obj}) => { | ||||
|         obj.getPath().map((e) => { | ||||
|           console.log(e) | ||||
|           this.path.push({lat: e.getLat(), lng: e.getLng()}); | ||||
|         }); | ||||
|         this.overlays.push(obj); | ||||
|       }); | ||||
|     }, | ||||
|     resetSearch() { | ||||
|       Object.keys(this.searchObj).map((e) => { | ||||
|         this.searchObj[e] = ""; | ||||
| @@ -601,6 +398,8 @@ export default { | ||||
|     } | ||||
|  | ||||
|     .is-current > .el-tree-node__content { | ||||
|       color: #fff !important; | ||||
|  | ||||
|       &:hover { | ||||
|         background: #2266FF; | ||||
|         color: #fff; | ||||
| @@ -608,7 +407,7 @@ export default { | ||||
|  | ||||
|       background: #2266FF; | ||||
|  | ||||
|       span { | ||||
|       .el-tooltip { | ||||
|         color: #fff; | ||||
|       } | ||||
|     } | ||||
| @@ -633,40 +432,27 @@ export default { | ||||
|     padding: 8px 0; | ||||
|   } | ||||
|  | ||||
|   .map { | ||||
|     width: 780px; | ||||
|     position: relative; | ||||
|     overflow: hidden; | ||||
|   ::v-deep.fullscreenMap { | ||||
|     .el-dialog { | ||||
|       display: flex; | ||||
|       flex-direction: column; | ||||
|  | ||||
|     .container { | ||||
|       width: 760px; | ||||
|       height: 420px; | ||||
|       border-radius: 2px; | ||||
|       border: 1px solid #d0d4dc; | ||||
|       .el-dialog__body { | ||||
|         padding: 0; | ||||
|         flex: 1; | ||||
|         min-height: 0; | ||||
|  | ||||
|         .ai-dialog__content { | ||||
|           max-height: unset !important; | ||||
|           padding-bottom: 0; | ||||
|           height: 100%; | ||||
|  | ||||
|           .ai-dialog__content--wrapper { | ||||
|             padding-right: 0 !important; | ||||
|           } | ||||
|         } | ||||
|       } | ||||
|     } | ||||
|  | ||||
|     #panel { | ||||
|       position: absolute; | ||||
|       height: 400px; | ||||
|       right: 30px; | ||||
|       top: 20px; | ||||
|       width: 280px; | ||||
|       overflow: hidden; | ||||
|       z-index: 10000; | ||||
|     } | ||||
|  | ||||
|     .tipinput { | ||||
|       position: absolute; | ||||
|       width: 200px; | ||||
|       height: 38px; | ||||
|       left: 20px; | ||||
|       top: 20px; | ||||
|       z-index: 10000; | ||||
|     } | ||||
|   } | ||||
|  | ||||
|   ::v-deep.ai-list__content--right { | ||||
|     overflow: visible !important; | ||||
|   } | ||||
|  | ||||
|   ::v-deep .treePanel { | ||||
|   | ||||
							
								
								
									
										229
									
								
								project/sass/apps/grid/AppGridBlock/components/mapPlotting.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										229
									
								
								project/sass/apps/grid/AppGridBlock/components/mapPlotting.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,229 @@ | ||||
| <template> | ||||
|   <section class="mapPlotting"> | ||||
|     <div class="clicker" @click="dialog=true,$emit('open')"> | ||||
|       <slot v-if="$slots.default"/> | ||||
|       <el-button v-else type="text">标绘</el-button> | ||||
|     </div> | ||||
|     <ai-dialog :title="title" class="fullscreenMap" | ||||
|                :visible.sync="dialog" | ||||
|                :destroyOnClose="true" | ||||
|                @close="points=[]" | ||||
|                border fullscreen | ||||
|                @open="initMap" :modal="false" | ||||
|                @onConfirm="$emit('change',points.flat()),dialog=false"> | ||||
|       <div class="mapPanel"> | ||||
|         <div class="tipinput"> | ||||
|           <el-input | ||||
|               v-model="searchAddress" | ||||
|               @change="addressChange" | ||||
|               clearable | ||||
|               placeholder="请输入关键字" | ||||
|               id="tipinput" | ||||
|               size="medium"/> | ||||
|         </div> | ||||
|         <div id="panel"/> | ||||
|         <div class="container fill" id="container"/> | ||||
|         <div class="operationBtns" v-if="map"> | ||||
|           <el-alert type="success" title="操作说明:" :closable="false"> | ||||
|             <li>1.双击覆盖物即可编辑</li> | ||||
|             <li>2.编辑状态,对点双击可删除该点</li> | ||||
|             <li>3.绘制状态,右键结束绘制</li> | ||||
|             <li>4.结束编辑才能保存绘制的覆盖物信息</li> | ||||
|           </el-alert> | ||||
|           <el-button-group> | ||||
|             <el-button type="primary" @click="handleAdd">新建</el-button> | ||||
|             <el-button @click="polyEditor.close()">结束编辑</el-button> | ||||
|             <el-button @click="clear()">清除绘制</el-button> | ||||
|           </el-button-group> | ||||
|         </div> | ||||
|       </div> | ||||
|     </ai-dialog> | ||||
|   </section> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
| import AMapLoader from "@amap/amap-jsapi-loader"; | ||||
| import {mapState} from "vuex"; | ||||
|  | ||||
| export default { | ||||
|   name: "mapPlotting", | ||||
|   model: { | ||||
|     prop: "value", | ||||
|     event: "change" | ||||
|   }, | ||||
|   props: { | ||||
|     title: {default: "地图标绘"}, | ||||
|     value: Array | ||||
|   }, | ||||
|   computed: { | ||||
|     ...mapState(['user']), | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       map: null, | ||||
|       polyEditor: null, | ||||
|       placeSearch: null, | ||||
|       searchAddress: "", | ||||
|       overlays: [], | ||||
|       points: [], | ||||
|       dialog: false | ||||
|     } | ||||
|   }, | ||||
|   methods: { | ||||
|     addressChange(val) { | ||||
|       this.placeSearch.search(val); | ||||
|     }, | ||||
|     clear() { | ||||
|       this.map.remove(this.overlays); | ||||
|       this.overlays = []; | ||||
|       this.points = [] | ||||
|     }, | ||||
|     handleAdd() { | ||||
|       let {polyEditor} = this | ||||
|       polyEditor.close(); | ||||
|       polyEditor.setTarget(); | ||||
|       polyEditor.open(); | ||||
|     }, | ||||
|     initMap() { | ||||
|       setTimeout(() => AMapLoader.load({ | ||||
|         key: "b553334ba34f7ac3cd09df9bc8b539dc", // 申请好的Web端开发者Key,首次调用 load 时必填 | ||||
|         version: "2.0", // 指定要加载的 JSAPI 的版本,缺省时默认为 1.4.15 | ||||
|         plugins: ["AMap.PlaceSearch", "AMap.PolygonEditor"], // 需要使用的的插件列表,如比例尺'AMap.Scale'等 | ||||
|         AMapUI: { | ||||
|           // 是否加载 AMapUI,缺省不加载 | ||||
|           version: "1.1", // AMapUI 缺省 1.1 | ||||
|           plugins: [], // 需要加载的 AMapUI ui插件 | ||||
|         }, | ||||
|       }).then((AMap) => { | ||||
|         this.map = new AMap.Map("container", { | ||||
|           resizeEnable: true, | ||||
|         }); | ||||
|         this.placeSearch = new AMap.PlaceSearch({ | ||||
|           pageSize: 5, // 单页显示结果条数 | ||||
|           pageIndex: 1, // 页码 | ||||
|           city: this.user.info.areaId?.substring(0, 6), // 兴趣点城市 | ||||
|           citylimit: true, //是否强制限制在设置的城市内搜索 | ||||
|           map: this.map, // 展现结果的地图实例 | ||||
|           panel: "panel", // 结果列表将在此容器中进行展示。 | ||||
|           autoFitView: true, // 是否自动调整地图视野使绘制的 Marker点都处于视口的可见范围 | ||||
|         }); | ||||
|         this.polyEditor = new AMap.PolygonEditor(this.map).on('add', ({target}) => { | ||||
|           this.polyEditor.addAdsorbPolygons(target) | ||||
|           target.on("dblclick", () => { | ||||
|             this.polyEditor.setTarget(target); | ||||
|             this.polyEditor.open() | ||||
|           }) | ||||
|         }) | ||||
|         this.polyEditor.on('end', ({target}) => { | ||||
|           this.overlays.push(target); | ||||
|           this.points.push(target.getPath().map((e) => ({lat: e.getLat(), lng: e.getLng()}))) | ||||
|         }); | ||||
|         if (this.value?.length > 0) { | ||||
|           let path = this.value.map(e => [e.lng, e.lat]); | ||||
|           let polygon = new AMap.Polygon({ | ||||
|             path, | ||||
|             strokeColor: "#FF33FF", | ||||
|             strokeWeight: 6, | ||||
|             strokeOpacity: 0.2, | ||||
|             fillOpacity: 0.4, | ||||
|             fillColor: "#1791fc", | ||||
|           }) | ||||
|           this.map.add([polygon]); | ||||
|           this.map.setFitView(); | ||||
|           this.polyEditor.addAdsorbPolygons(polygon) | ||||
|           polygon.on('dblclick', () => { | ||||
|             this.polyEditor.setTarget(polygon); | ||||
|             this.polyEditor.open() | ||||
|           }); | ||||
|           this.polyEditor.setTarget(polygon); | ||||
|           this.polyEditor.open() | ||||
|         } else { | ||||
|           this.map.setCity(this.user.info.areaId?.substring(0, 6)) | ||||
|           this.map.setZoom(14, false, 600) | ||||
|         } | ||||
|       }), 500) | ||||
|     } | ||||
|   } | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style lang="scss" scoped> | ||||
| .mapPlotting { | ||||
|   display: inline-block; | ||||
|   text-align: left; | ||||
|  | ||||
|   .clicker { | ||||
|     display: inline-block; | ||||
|   } | ||||
|  | ||||
|   .mapPanel { | ||||
|     width: 100%; | ||||
|     height: 100%; | ||||
|     position: relative; | ||||
|     overflow: hidden; | ||||
|     display: flex; | ||||
|     flex-direction: column; | ||||
|  | ||||
|     .container { | ||||
|       width: inherit; | ||||
|     } | ||||
|  | ||||
|     #panel { | ||||
|       position: absolute; | ||||
|       height: 400px; | ||||
|       right: 30px; | ||||
|       top: 20px; | ||||
|       width: 280px; | ||||
|       overflow: hidden; | ||||
|       z-index: 10000; | ||||
|     } | ||||
|  | ||||
|     .tipinput { | ||||
|       position: absolute; | ||||
|       width: 300px; | ||||
|       height: 38px; | ||||
|       left: 20px; | ||||
|       top: 20px; | ||||
|       z-index: 10000; | ||||
|     } | ||||
|  | ||||
|     .operationBtns { | ||||
|       position: absolute; | ||||
|       left: 20px; | ||||
|       bottom: 20px; | ||||
|       z-index: 10000; | ||||
|     } | ||||
|   } | ||||
|  | ||||
|   ::v-deep.fullscreenMap { | ||||
|     .el-dialog { | ||||
|       display: flex; | ||||
|       flex-direction: column; | ||||
|  | ||||
|       .el-dialog__body { | ||||
|         padding: 0; | ||||
|         flex: 1; | ||||
|         min-height: 0; | ||||
|  | ||||
|         .ai-dialog__content { | ||||
|           max-height: unset !important; | ||||
|           padding-bottom: 0; | ||||
|           height: 100%; | ||||
|  | ||||
|           .ai-dialog__content--wrapper { | ||||
|             padding-right: 0 !important; | ||||
|           } | ||||
|         } | ||||
|       } | ||||
|     } | ||||
|   } | ||||
|  | ||||
|   ::v-deep .amap-copyright { | ||||
|     display: none !important; | ||||
|   } | ||||
|  | ||||
|   ::v-deep .amap-logo { | ||||
|     display: none !important; | ||||
|   } | ||||
| } | ||||
| </style> | ||||
| @@ -13,17 +13,20 @@ | ||||
|           </header> | ||||
|           <div class="tree-div"> | ||||
|             <el-tree | ||||
|               :data="treeObj.treeList" | ||||
|               :props="treeObj.defaultProps" | ||||
|               @node-click="handleNodeClick" | ||||
|               node-key="id" | ||||
|               ref="tree" | ||||
|               :expand-on-click-node="false" | ||||
|               :filter-node-method="filterNode" | ||||
|               default-expand-all | ||||
|               highlight-current> | ||||
|                | ||||
|               <span class="custom-tree-node" :title="node.label" style="" slot-scope="{ node, data }">{{ node.label }}</span> | ||||
|                 :data="treeObj.treeList" | ||||
|                 :props="treeObj.defaultProps" | ||||
|                 @node-click="handleNodeClick" | ||||
|                 node-key="id" | ||||
|                 ref="tree" | ||||
|                 :expand-on-click-node="false" | ||||
|                 :filter-node-method="filterNode" | ||||
|                 default-expand-all | ||||
|                 highlight-current> | ||||
|               <template slot-scope="{ node, data }"> | ||||
|                 <el-tooltip effect="light" :content="node.label" placement="right"> | ||||
|                   <div v-text="node.label"/> | ||||
|                 </el-tooltip> | ||||
|               </template> | ||||
|             </el-tree> | ||||
|           </div> | ||||
|         </div> | ||||
| @@ -35,112 +38,111 @@ | ||||
|   </div> | ||||
| </template> | ||||
| <script> | ||||
|   import {mapState} from 'vuex' | ||||
| import {mapState} from 'vuex' | ||||
|  | ||||
|   export default { | ||||
|     name: 'AppGridMap', | ||||
|     label: "网格地图", | ||||
|     props: { | ||||
|       instance: Function, | ||||
|       dict: Object, | ||||
|       permissions: Function, | ||||
|     }, | ||||
|     data() { | ||||
|       return { | ||||
|         map: null, | ||||
|         mapLib: null, | ||||
|         show: true, | ||||
|         retryMapCount: 0, | ||||
|         polygons: [], | ||||
| export default { | ||||
|   name: 'AppGridMap', | ||||
|   label: "网格地图", | ||||
|   props: { | ||||
|     instance: Function, | ||||
|     dict: Object, | ||||
|     permissions: Function, | ||||
|   }, | ||||
|   data() { | ||||
|     return { | ||||
|       map: null, | ||||
|       mapLib: null, | ||||
|       show: true, | ||||
|       retryMapCount: 0, | ||||
|       polygons: [], | ||||
|  | ||||
|         drawer: false, | ||||
|         filterText: "", | ||||
|         treeObj: { | ||||
|           treeList: [], | ||||
|           defaultProps: { | ||||
|             children: "girdList", | ||||
|             label: "girdName", | ||||
|           }, | ||||
|           defaultExpandedKeys: [], | ||||
|       drawer: false, | ||||
|       filterText: "", | ||||
|       treeObj: { | ||||
|         treeList: [], | ||||
|         defaultProps: { | ||||
|           children: "girdList", | ||||
|           label: "girdName", | ||||
|         }, | ||||
|         ops: {}, | ||||
|         defaultExpandedKeys: [], | ||||
|       }, | ||||
|       ops: {}, | ||||
|  | ||||
|         path: [], | ||||
|         searchObj: { | ||||
|           onlineStatus: "", | ||||
|           girdMemberName: "", | ||||
|         }, | ||||
|         member: { | ||||
|           memberList: [], | ||||
|         }, | ||||
|         currInfo: {}, | ||||
|         infoWindowHtml: "", | ||||
|         marker: {}, | ||||
|         activeId: null, | ||||
|         labels: [] | ||||
|       }; | ||||
|       path: [], | ||||
|       searchObj: { | ||||
|         onlineStatus: "", | ||||
|         girdMemberName: "", | ||||
|       }, | ||||
|       member: { | ||||
|         memberList: [], | ||||
|       }, | ||||
|       currInfo: {}, | ||||
|       infoWindowHtml: "", | ||||
|       marker: {}, | ||||
|       activeId: null, | ||||
|       labels: [] | ||||
|     }; | ||||
|   }, | ||||
|   computed: { | ||||
|     ...mapState(['user']), | ||||
|   }, | ||||
|   created() { | ||||
|     this.dict.load("onlineStatus") | ||||
|     this.getTreeList().then(() => { | ||||
|       this.getLeafNodes() | ||||
|     }) | ||||
|   }, | ||||
|   watch: { | ||||
|     filterText(val) { | ||||
|       this.$refs.tree.filter(val); | ||||
|     }, | ||||
|     computed: { | ||||
|       ...mapState(['user']), | ||||
|   }, | ||||
|   methods: { | ||||
|     filterNode(value, data) { | ||||
|       if (!value) return true; | ||||
|       return data.girdName.indexOf(value) !== -1; | ||||
|     }, | ||||
|     created() { | ||||
|       this.dict.load("onlineStatus") | ||||
|       this.getTreeList().then(() => { | ||||
|         this.getLeafNodes() | ||||
|     getTreeList() { | ||||
|       return this.instance.post(`/app/appgirdinfo/listAllByTop`).then((res) => { | ||||
|         if (res.code == 0) { | ||||
|           this.treeObj.treeList = [res.data]; | ||||
|  | ||||
|           this.$nextTick(() => { | ||||
|             res.data.length && this.$refs.tree.setCurrentKey(res.data[0].id) | ||||
|           }) | ||||
|         } | ||||
|       }) | ||||
|     }, | ||||
|     watch: { | ||||
|       filterText(val) { | ||||
|         this.$refs.tree.filter(val); | ||||
|       }, | ||||
|  | ||||
|     onMapInit() { | ||||
|       this.instance.post("/app/appdvcpconfig/getCorpLocation").then(res => { | ||||
|         if (res.code === 0) { | ||||
|           this.map.setCenter(new this.mapLib.LatLng(res.data.lat, res.data.lng)) | ||||
|         } | ||||
|       }) | ||||
|     }, | ||||
|     methods: { | ||||
|       filterNode(value, data) { | ||||
|         if (!value) return true; | ||||
|         return data.girdName.indexOf(value) !== -1; | ||||
|       }, | ||||
|       getTreeList() { | ||||
|         return this.instance.post(`/app/appgirdinfo/listAll`).then((res) => { | ||||
|           if (res.code == 0) { | ||||
|             this.treeObj.treeList = res.data; | ||||
|  | ||||
|             this.$nextTick(() => { | ||||
|               res.data.length && this.$refs.tree.setCurrentKey(res.data[0].id) | ||||
|             }) | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|     getLeafNodes() { | ||||
|       this.instance.post(`/app/appgirdinfo/listAll2`).then((res) => { | ||||
|         if (res?.data) { | ||||
|           const arr = res.data.map(v => { | ||||
|             return { | ||||
|               id: v.id, | ||||
|               girdName: v.girdName, | ||||
|               points: v.points ? v.points.map(p => [p.lng, p.lat]) : [] | ||||
|             } | ||||
|           }).filter(v => v.points.length) | ||||
|  | ||||
|       onMapInit () { | ||||
|         this.instance.post("/app/appdvcpconfig/getCorpLocation").then(res=>{ | ||||
|           if (res.code === 0) { | ||||
|             this.map.setCenter(new this.mapLib.LatLng(res.data.lat, res.data.lng)) | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       getLeafNodes() { | ||||
|         this.instance.post(`/app/appgirdinfo/listAll2`).then((res) => { | ||||
|           if (res?.data) { | ||||
|             const arr = res.data.map(v => { | ||||
|               return { | ||||
|                 id: v.id, | ||||
|                 girdName: v.girdName, | ||||
|                 points: v.points ? v.points.map(p => [p.lng, p.lat]) : [] | ||||
|               } | ||||
|             }).filter(v => v.points.length) | ||||
|  | ||||
|             this.renderGridMap(arr) | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|       handleNodeClick (val) { | ||||
|         if (val.girdLevel === '0') { | ||||
|           this.getLeafNodes() | ||||
|           this.renderGridMap(arr) | ||||
|         } | ||||
|       }) | ||||
|     }, | ||||
|     handleNodeClick(val) { | ||||
|       if (val.girdLevel === '0') { | ||||
|         this.getLeafNodes() | ||||
|  | ||||
|           return false | ||||
|         } | ||||
|          | ||||
|         this.instance.post(`/app/appgirdinfo/queryChildGirdInfoByGirdId?girdId=${val.id}`).then((res) => { | ||||
|           if (res?.data) { | ||||
|             const arr = res.data.map(v => { | ||||
| @@ -151,179 +153,179 @@ | ||||
|               } | ||||
|             }).filter(v => v.points.length) | ||||
|  | ||||
|             if (!arr.length) { | ||||
|               return this.$message.error('该网格还未标绘') | ||||
|             } | ||||
|           if (!arr.length) { | ||||
|             return this.$message.error('该网格还未标绘') | ||||
|           } | ||||
|  | ||||
|             this.renderGridMap(arr) | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       fitBounds(latLngList, count = 0) { | ||||
|         let {mapLib: TMap} = this | ||||
|         if (TMap) { | ||||
|           if (latLngList.length === 0) { | ||||
|             return null; | ||||
|           } | ||||
|           let boundsN = latLngList[0].getLat(); | ||||
|           let boundsS = boundsN; | ||||
|           let boundsW = latLngList[0].getLng(); | ||||
|           let boundsE = boundsW; | ||||
|           latLngList.forEach((point) => { | ||||
|             point.getLat() > boundsN && (boundsN = point.getLat()); | ||||
|             point.getLat() < boundsS && (boundsS = point.getLat()); | ||||
|             point.getLng() > boundsE && (boundsE = point.getLng()); | ||||
|             point.getLng() < boundsW && (boundsW = point.getLng()); | ||||
|           }); | ||||
|           return new TMap.LatLngBounds( | ||||
|               new TMap.LatLng(boundsS, boundsW), | ||||
|               new TMap.LatLng(boundsN, boundsE) | ||||
|           ); | ||||
|         } else { | ||||
|           if (count < 5) { | ||||
|             this.fitBounds(latLngList, ++count) | ||||
|           } | ||||
|           this.renderGridMap(arr) | ||||
|         } | ||||
|       }, | ||||
|       }) | ||||
|     }, | ||||
|  | ||||
|       renderGridMap(paths) { | ||||
|         let {map, mapLib: TMap } = this | ||||
|         if (TMap) { | ||||
|           if (this.polygons.length > 0) { | ||||
|             this.polygons.forEach(e => e.destroy()) | ||||
|             this.labels.forEach(e => { | ||||
|               e.destroy(e.id) | ||||
|             }) | ||||
|             this.polygons = [] | ||||
|             this.labels = [] | ||||
|           } | ||||
|           if (paths?.length > 0) { | ||||
|             let bounds = [] | ||||
|             paths.forEach((path, i) => { | ||||
|               let polygon = new TMap.MultiPolygon({ | ||||
|                 map, styles: { | ||||
|                   default: new TMap.PolygonStyle({ | ||||
|                     showBorder: true, | ||||
|                     borderColor: '#5088FF', | ||||
|                     borderWidth: 2, | ||||
|                     color: this.$colorUtils.Hex2RGBA('#5088FF', 0.1) | ||||
|                   }) | ||||
|                 }, | ||||
|                 id: path.id, | ||||
|                 geometries: [{paths: path.points.map(e => new TMap.LatLng(e[1], e[0]))}] | ||||
|               }) | ||||
|               this.polygons.push(polygon) | ||||
|               bounds.push(this.fitBounds(path.points.map(e => new TMap.LatLng(e[1], e[0])))) | ||||
|  | ||||
|               polygon.on('click', e => { | ||||
|                 // const id = e.target.id | ||||
|                 // this.getGridInfo(id) | ||||
|               }) | ||||
|  | ||||
|               const points = path.points.map(e => new TMap.LatLng(e[1], e[0])) | ||||
|  | ||||
|               var position = TMap.geometry.computeCentroid(points) | ||||
|  | ||||
|               let label = new TMap.MultiLabel({ | ||||
|                 id: `label~${path.id}`, | ||||
|                 data: path.id, | ||||
|                 map: map, | ||||
|                 styles: { | ||||
|                   building:  new TMap.LabelStyle({ | ||||
|                     color: '#3777FF', | ||||
|                     size: 20, | ||||
|                     alignment: 'center', | ||||
|                     verticalAlignment: 'middle' | ||||
|                   }) | ||||
|                 }, | ||||
|                 geometries: [ | ||||
|                   { | ||||
|                     id: `label-class-${i}`, | ||||
|                     styleId: 'building', | ||||
|                     position: position, | ||||
|                     content: path.girdName, | ||||
|                   } | ||||
|                 ] | ||||
|               }) | ||||
|               this.labels.push(label) | ||||
|               label.on('click', e => { | ||||
|                 // this.getGridInfo(e.target.id.split('~')[1]) | ||||
|               }); | ||||
|             }) | ||||
|             bounds = bounds.reduce((a, b) => { | ||||
|               return this.fitBounds([ | ||||
|                 a.getNorthEast(), | ||||
|                 a.getSouthWest(), | ||||
|                 b.getNorthEast(), | ||||
|                 b.getSouthWest(), | ||||
|               ]); | ||||
|             }); | ||||
|             map.fitBounds(bounds, {padding: 100}) | ||||
|           } | ||||
|     fitBounds(latLngList, count = 0) { | ||||
|       let {mapLib: TMap} = this | ||||
|       if (TMap) { | ||||
|         if (latLngList.length === 0) { | ||||
|           return null; | ||||
|         } | ||||
|       }, | ||||
|       hasClass(ele, cls) { | ||||
|         return ele.className.match(new RegExp("(\\s|^)" + cls + "(\\s|$)")); | ||||
|       }, | ||||
|       addClass(ele, cls) { | ||||
|         if (!this.hasClass(ele, cls)) ele.className += " " + cls; | ||||
|       }, | ||||
|       removeClass(ele, cls) { | ||||
|         if (this.hasClass(ele, cls)) { | ||||
|           const reg = new RegExp("(\\s|^)" + cls + "(\\s|$)"); | ||||
|           ele.className = ele.className.replace(reg, " "); | ||||
|         } | ||||
|       }, | ||||
|       changClass(ele, className) { | ||||
|         if (!this.hasClass(ele, className)) { | ||||
|           this.addClass(ele, className); | ||||
|         } else { | ||||
|           this.removeClass(ele, className); | ||||
|         } | ||||
|       }, | ||||
|       percentage() { | ||||
|         if (this.member.onlineNumber == 0) { | ||||
|           return 0; | ||||
|         } else { | ||||
|           return ( | ||||
|               100 * | ||||
|               (this.member.onlineNumber / this.member.allMemberNumber) | ||||
|           ).toFixed(2); | ||||
|         } | ||||
|       }, | ||||
|       getMemberList() { | ||||
|         this.instance.post(`/app/appgirdmemberinfo/queryGirdMemberByMap`, this.searchObj).then((res) => { | ||||
|           if (res.code == 0) { | ||||
|             let markers = []; | ||||
|             this.member = res.data; | ||||
|             this.member.memberList.map((e) => { | ||||
|               if (e.onlineStatus == "1") { | ||||
|                 markers.push({lng: e.lng, lat: e.lat, name: e.name}); | ||||
|               } | ||||
|             }); | ||||
|             this.initMap(null, null, markers); | ||||
|           } | ||||
|         let boundsN = latLngList[0].getLat(); | ||||
|         let boundsS = boundsN; | ||||
|         let boundsW = latLngList[0].getLng(); | ||||
|         let boundsE = boundsW; | ||||
|         latLngList.forEach((point) => { | ||||
|           point.getLat() > boundsN && (boundsN = point.getLat()); | ||||
|           point.getLat() < boundsS && (boundsS = point.getLat()); | ||||
|           point.getLng() > boundsE && (boundsE = point.getLng()); | ||||
|           point.getLng() < boundsW && (boundsW = point.getLng()); | ||||
|         }); | ||||
|       }, | ||||
|       clickMember(marker) { | ||||
|         if (marker.onlineStatus == 1) { | ||||
|           this.activeId = marker.id; | ||||
|           this.marker = marker; | ||||
|           this.infoWindowContent(marker); | ||||
|         return new TMap.LatLngBounds( | ||||
|             new TMap.LatLng(boundsS, boundsW), | ||||
|             new TMap.LatLng(boundsN, boundsE) | ||||
|         ); | ||||
|       } else { | ||||
|         if (count < 5) { | ||||
|           this.fitBounds(latLngList, ++count) | ||||
|         } | ||||
|       }, | ||||
|       infoWindowContent(marker) { | ||||
|         this.instance | ||||
|         .post(`/app/location/xyToAddress`, null, { | ||||
|           params: { | ||||
|             x: marker.lat, | ||||
|             y: marker.lng, | ||||
|           }, | ||||
|         }) | ||||
|         .then((res) => { | ||||
|           if (res.code == 0) { | ||||
|             this.infoWindowHtml = `<div class="info"> | ||||
|       } | ||||
|     }, | ||||
|  | ||||
|     renderGridMap(paths) { | ||||
|       let {map, mapLib: TMap} = this | ||||
|       if (TMap) { | ||||
|         if (this.polygons.length > 0) { | ||||
|           this.polygons.forEach(e => e.destroy()) | ||||
|           this.labels.forEach(e => { | ||||
|             e.destroy(e.id) | ||||
|           }) | ||||
|           this.polygons = [] | ||||
|           this.labels = [] | ||||
|         } | ||||
|         if (paths?.length > 0) { | ||||
|           let bounds = [] | ||||
|           paths.forEach((path, i) => { | ||||
|             let polygon = new TMap.MultiPolygon({ | ||||
|               map, styles: { | ||||
|                 default: new TMap.PolygonStyle({ | ||||
|                   showBorder: true, | ||||
|                   borderColor: '#5088FF', | ||||
|                   borderWidth: 2, | ||||
|                   color: this.$colorUtils.Hex2RGBA('#5088FF', 0.1) | ||||
|                 }) | ||||
|               }, | ||||
|               id: path.id, | ||||
|               geometries: [{paths: path.points.map(e => new TMap.LatLng(e[1], e[0]))}] | ||||
|             }) | ||||
|             this.polygons.push(polygon) | ||||
|             bounds.push(this.fitBounds(path.points.map(e => new TMap.LatLng(e[1], e[0])))) | ||||
|  | ||||
|             polygon.on('click', e => { | ||||
|               // const id = e.target.id | ||||
|               // this.getGridInfo(id) | ||||
|             }) | ||||
|  | ||||
|             const points = path.points.map(e => new TMap.LatLng(e[1], e[0])) | ||||
|  | ||||
|             var position = TMap.geometry.computeCentroid(points) | ||||
|  | ||||
|             let label = new TMap.MultiLabel({ | ||||
|               id: `label~${path.id}`, | ||||
|               data: path.id, | ||||
|               map: map, | ||||
|               styles: { | ||||
|                 building: new TMap.LabelStyle({ | ||||
|                   color: '#3777FF', | ||||
|                   size: 20, | ||||
|                   alignment: 'center', | ||||
|                   verticalAlignment: 'middle' | ||||
|                 }) | ||||
|               }, | ||||
|               geometries: [ | ||||
|                 { | ||||
|                   id: `label-class-${i}`, | ||||
|                   styleId: 'building', | ||||
|                   position: position, | ||||
|                   content: path.girdName, | ||||
|                 } | ||||
|               ] | ||||
|             }) | ||||
|             this.labels.push(label) | ||||
|             label.on('click', e => { | ||||
|               // this.getGridInfo(e.target.id.split('~')[1]) | ||||
|             }); | ||||
|           }) | ||||
|           bounds = bounds.reduce((a, b) => { | ||||
|             return this.fitBounds([ | ||||
|               a.getNorthEast(), | ||||
|               a.getSouthWest(), | ||||
|               b.getNorthEast(), | ||||
|               b.getSouthWest(), | ||||
|             ]); | ||||
|           }); | ||||
|           map.fitBounds(bounds, {padding: 100}) | ||||
|         } | ||||
|       } | ||||
|     }, | ||||
|     hasClass(ele, cls) { | ||||
|       return ele.className.match(new RegExp("(\\s|^)" + cls + "(\\s|$)")); | ||||
|     }, | ||||
|     addClass(ele, cls) { | ||||
|       if (!this.hasClass(ele, cls)) ele.className += " " + cls; | ||||
|     }, | ||||
|     removeClass(ele, cls) { | ||||
|       if (this.hasClass(ele, cls)) { | ||||
|         const reg = new RegExp("(\\s|^)" + cls + "(\\s|$)"); | ||||
|         ele.className = ele.className.replace(reg, " "); | ||||
|       } | ||||
|     }, | ||||
|     changClass(ele, className) { | ||||
|       if (!this.hasClass(ele, className)) { | ||||
|         this.addClass(ele, className); | ||||
|       } else { | ||||
|         this.removeClass(ele, className); | ||||
|       } | ||||
|     }, | ||||
|     percentage() { | ||||
|       if (this.member.onlineNumber == 0) { | ||||
|         return 0; | ||||
|       } else { | ||||
|         return ( | ||||
|             100 * | ||||
|             (this.member.onlineNumber / this.member.allMemberNumber) | ||||
|         ).toFixed(2); | ||||
|       } | ||||
|     }, | ||||
|     getMemberList() { | ||||
|       this.instance.post(`/app/appgirdmemberinfo/queryGirdMemberByMap`, this.searchObj).then((res) => { | ||||
|         if (res.code == 0) { | ||||
|           let markers = []; | ||||
|           this.member = res.data; | ||||
|           this.member.memberList.map((e) => { | ||||
|             if (e.onlineStatus == "1") { | ||||
|               markers.push({lng: e.lng, lat: e.lat, name: e.name}); | ||||
|             } | ||||
|           }); | ||||
|           this.initMap(null, null, markers); | ||||
|         } | ||||
|       }); | ||||
|     }, | ||||
|     clickMember(marker) { | ||||
|       if (marker.onlineStatus == 1) { | ||||
|         this.activeId = marker.id; | ||||
|         this.marker = marker; | ||||
|         this.infoWindowContent(marker); | ||||
|       } | ||||
|     }, | ||||
|     infoWindowContent(marker) { | ||||
|       this.instance | ||||
|       .post(`/app/location/xyToAddress`, null, { | ||||
|         params: { | ||||
|           x: marker.lat, | ||||
|           y: marker.lng, | ||||
|         }, | ||||
|       }) | ||||
|       .then((res) => { | ||||
|         if (res.code == 0) { | ||||
|           this.infoWindowHtml = `<div class="info"> | ||||
|                                           <p> | ||||
|                                               <span class="name">${marker.name}</span> | ||||
|                                               <span class="lat">${marker.lng},${marker.lat}</span> | ||||
| @@ -335,31 +337,31 @@ | ||||
|                                               <span class="iconfont iconarea" id="addressSpan">当日轨迹</span> | ||||
|                                           </p> | ||||
|                                       </div>`; | ||||
|             this.initMap(false, marker); | ||||
|           } | ||||
|         }); | ||||
|       }, | ||||
|       queryTrajectory() { | ||||
|         this.instance | ||||
|         .post(`/app/appgirdmembertrajectory/queryTrajectory`, null, { | ||||
|           params: { | ||||
|             userId: this.marker.userId, | ||||
|           }, | ||||
|         }) | ||||
|         .then((res) => { | ||||
|           if (res.code == 0) { | ||||
|             let path = []; | ||||
|             if (res.data) { | ||||
|               res.data.map((e, index) => { | ||||
|                 path[index] = [e.lng, e.lat]; | ||||
|               }); | ||||
|             } | ||||
|             this.initMap(path, this.marker); | ||||
|           } | ||||
|         }); | ||||
|       }, | ||||
|           this.initMap(false, marker); | ||||
|         } | ||||
|       }); | ||||
|     }, | ||||
|   } | ||||
|     queryTrajectory() { | ||||
|       this.instance | ||||
|       .post(`/app/appgirdmembertrajectory/queryTrajectory`, null, { | ||||
|         params: { | ||||
|           userId: this.marker.userId, | ||||
|         }, | ||||
|       }) | ||||
|       .then((res) => { | ||||
|         if (res.code == 0) { | ||||
|           let path = []; | ||||
|           if (res.data) { | ||||
|             res.data.map((e, index) => { | ||||
|               path[index] = [e.lng, e.lat]; | ||||
|             }); | ||||
|           } | ||||
|           this.initMap(path, this.marker); | ||||
|         } | ||||
|       }); | ||||
|     }, | ||||
|   }, | ||||
| } | ||||
| </script> | ||||
|  | ||||
| <style lang="scss" scoped> | ||||
| @@ -374,7 +376,7 @@ | ||||
|   } | ||||
|  | ||||
|   ::v-deep .is-current { | ||||
|     & > .el-tree-node__content > .custom-tree-node { | ||||
|     & > .el-tree-node__content > .el-tooltip { | ||||
|       color: #5088ff; | ||||
|     } | ||||
|   } | ||||
| @@ -576,7 +578,7 @@ | ||||
|             background: #333c53; | ||||
|           } | ||||
|  | ||||
|           .el-tree-node__label { | ||||
|           .el-tooltip { | ||||
|             color: #fff; | ||||
|           } | ||||
|  | ||||
| @@ -585,7 +587,7 @@ | ||||
|           } | ||||
|  | ||||
|           .is-current > .el-tree-node__content { | ||||
|             .el-tree-node__label { | ||||
|             .el-tooltip { | ||||
|               color: #5088ff; | ||||
|             } | ||||
|           } | ||||
|   | ||||
| @@ -267,7 +267,7 @@ | ||||
|             size: 200, | ||||
|             con: this.name, | ||||
|             householdName: 1, | ||||
|             areaId: this.areaId, | ||||
|             searchAreaId: this.areaId, | ||||
|           } | ||||
|         }).then(res => { | ||||
|           if (res.code == 0) { | ||||
|   | ||||
| @@ -24,7 +24,7 @@ | ||||
|                   <el-form-item label="网格员姓名" prop="wxUserId" > | ||||
|                     <div class="flex-box"> | ||||
|                       <ai-open-data :style="{marginRight: forms.wxUserId ? '20px' : 0}" type="userName" :openid="forms.wxUserId" /> | ||||
|                       <AiUserGet :isMultiple="false" refs="addTags" :instance="instance" v-model="users" @change="getSelectPerson"> | ||||
|                       <AiUserGet :isMultiple="false" refs="addTags" :instance="instance" v-model="users" @change="getSelectPerson" :props="{label:'name', id: 'id'}"> | ||||
|                         <el-button size="small" type="primary"><span style="color: #fff">选择网格员</span></el-button> | ||||
|                       </AiUserGet> | ||||
|                     </div> | ||||
| @@ -425,14 +425,6 @@ export default { | ||||
|             if (!currInfo.id) { | ||||
|               return this.$message.error('请选择网格') | ||||
|             } | ||||
|  | ||||
|             if (currInfo.checkType === '1' && currInfo.girdLevel !== '2') { | ||||
|               return this.$message.error(`一级、二级网格不能添加网格员`) | ||||
|             } | ||||
|  | ||||
|             if (sameInfo.length) { | ||||
|               return this.$message.error('不能选择同一网格重复绑定') | ||||
|             } | ||||
|           } | ||||
|  | ||||
|           this.instance.post(`/app/appgirdmemberinfo/addOrUpdate`,{ | ||||
|   | ||||
		Reference in New Issue
	
	Block a user