目录代码整合
This commit is contained in:
		
							
								
								
									
										62
									
								
								packages/conv/AppHealthReport/AppHealthReport.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										62
									
								
								packages/conv/AppHealthReport/AppHealthReport.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,62 @@ | ||||
| <template> | ||||
|   <div class="AppHealthReport"> | ||||
|     <keep-alive :include="['List']"> | ||||
|       <component ref="component" :is="component" @change="onChange" :params="params" :instance="instance" :dict="dict"></component> | ||||
|     </keep-alive> | ||||
|   </div> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
|   import List from './components/List.vue' | ||||
|   import Detail from './components/Detail.vue' | ||||
|  | ||||
|   export default { | ||||
|     name: 'AppHealthReport', | ||||
|     label: '健康上报', | ||||
|  | ||||
|     components: { | ||||
|       List, | ||||
|       Detail | ||||
|     }, | ||||
|  | ||||
|     props: { | ||||
|       instance: Function, | ||||
|       dict: Object, | ||||
|       permissions: Function | ||||
|     }, | ||||
|  | ||||
|     data () { | ||||
|       return { | ||||
|         component: 'List', | ||||
|         params: {} | ||||
|       } | ||||
|     }, | ||||
|  | ||||
|     methods: { | ||||
|       onChange (data) { | ||||
|         if (data.type === 'Detail') { | ||||
|           this.component = 'Detail' | ||||
|           this.isShowDetail = true | ||||
|           this.params = data.params | ||||
|         } | ||||
|  | ||||
|         if (data.type === 'list') { | ||||
|           this.component = 'List' | ||||
|           this.params = data.params | ||||
|  | ||||
|           this.$nextTick(() => { | ||||
|             if (data.isRefresh) { | ||||
|               this.$refs.component.getList() | ||||
|             } | ||||
|           }) | ||||
|         } | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| </script> | ||||
|  | ||||
| <style lang="scss" scoped> | ||||
|   .AppHealthReport { | ||||
|     height: 100%; | ||||
|   } | ||||
| </style> | ||||
							
								
								
									
										316
									
								
								packages/conv/AppHealthReport/components/Detail.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										316
									
								
								packages/conv/AppHealthReport/components/Detail.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,316 @@ | ||||
|  <template> | ||||
|   <ai-detail isHasSidebar> | ||||
|     <template slot="title"> | ||||
|       <ai-title title="详情" isShowBack isShowBottomBorder @onBackClick="cancel(true)"> | ||||
|       </ai-title> | ||||
|     </template> | ||||
|     <template slot="content"> | ||||
|       <AiSidebar :tabTitle="tabList" v-model="currIndex"></AiSidebar> | ||||
|       <div v-show="currIndex === 0"> | ||||
|         <ai-card title="基本信息" v-show="currIndex === 0"> | ||||
|           <template #content> | ||||
|             <ai-wrapper | ||||
|               label-width="120px"> | ||||
|               <ai-info-item label="姓名" :value="info.name"></ai-info-item> | ||||
|               <ai-info-item label="上报时间" :value="info.createTime"></ai-info-item> | ||||
|               <ai-info-item label="身份证号" :value="info.idNumber"></ai-info-item> | ||||
|               <ai-info-item label="所属地区" :value="info.areaName"></ai-info-item> | ||||
|               <ai-info-item label="详细地址" isLine :value="info.address"></ai-info-item> | ||||
|             </ai-wrapper> | ||||
|           </template> | ||||
|         </ai-card> | ||||
|       </div> | ||||
|       <ai-card title="每日上报" v-show="currIndex === 1"> | ||||
|         <template #content> | ||||
|           <ai-table | ||||
|             class="detail-table__table" | ||||
|             :tableData="tableData" | ||||
|             :col-configs="colConfigs" | ||||
|             :total="total" | ||||
|             :current.sync="search.current" | ||||
|             :size.sync="search.size" | ||||
|             @getList="getList"> | ||||
|             <el-table-column slot="options" width="140px" fixed="right" label="操作" align="center"> | ||||
|               <template slot-scope="{ row }"> | ||||
|                 <div class="table-options"> | ||||
|                   <el-button type="text" @click="toDetail(row.id)">详情</el-button> | ||||
|                 </div> | ||||
|               </template> | ||||
|             </el-table-column> | ||||
|           </ai-table> | ||||
|           <ai-dialog | ||||
|             :visible.sync="isShow" | ||||
|             width="890px" | ||||
|             customFooter | ||||
|             title="上报详情"> | ||||
|             <ai-bar title="健康状况"></ai-bar> | ||||
|             <ai-wrapper | ||||
|               label-width="120px"> | ||||
|               <ai-info-item label="当前体温"> | ||||
|                 <span :style="{color: reportInfo.temperature > 37.3 ? '#FF4466' : '#42D784'}">{{ reportInfo.temperature }}℃</span> | ||||
|               </ai-info-item> | ||||
|               <ai-info-item label="14天内是否接触新冠确诊或疑似患者"> | ||||
|                 <span :style="{color: reportInfo.touchInFourteen === '0' ? '#42D784' : '#FF4466'}">{{ $dict.getLabel('epidemicTouchInFourteen', reportInfo.touchInFourteen) }}</span> | ||||
|               </ai-info-item> | ||||
|               <ai-info-item label="当前健康状况" isLine> | ||||
|                 <span :style="{color: !reportInfo.isHealth ? '#42D784' : '#FF4466'}">{{ reportInfo.healthName }}</span> | ||||
|               </ai-info-item> | ||||
|             </ai-wrapper> | ||||
|             <ai-bar title="核酸检测信息"></ai-bar> | ||||
|             <ai-wrapper | ||||
|               label-width="120px"> | ||||
|               <ai-info-item label="检测日期"> | ||||
|                 <span>{{ reportInfo.checkTime && reportInfo.checkTime.split(' ')[0] }}</span> | ||||
|               </ai-info-item> | ||||
|               <ai-info-item label="检测结果"> | ||||
|                 <span :style="{color: reportInfo.checkResult === '0' ? '#42D784' : '#FF4466'}">{{ $dict.getLabel('epidemicRecentTestResult', reportInfo.checkResult) }}</span> | ||||
|               </ai-info-item> | ||||
|               <ai-info-item label="健康码状态"> | ||||
|                 <span :style="{color: (reportInfo.healthCode === '0' || reportInfo.healthCode === '1') ? '#42D784' : '#FF4466'}">{{ $dict.getLabel('epidemicHealthCode', reportInfo.healthCode) }}</span> | ||||
|               </ai-info-item> | ||||
|               <ai-info-item label="已接种疫苗次数"> | ||||
|                 <span>{{ $dict.getLabel('epidemicVaccineTime', reportInfo.vaccine) }}</span> | ||||
|               </ai-info-item> | ||||
|               <ai-info-item label="本人健康码截图" isLine> | ||||
|                 <ai-uploader | ||||
|                   :instance="instance" | ||||
|                   v-model="reportInfo.checkPhoto" | ||||
|                   disabled | ||||
|                   :limit="9"> | ||||
|                 </ai-uploader> | ||||
|               </ai-info-item> | ||||
|             </ai-wrapper> | ||||
|             <div class="dialog-footer" slot="footer"> | ||||
|               <el-button @click="isShow = false">关闭</el-button> | ||||
|             </div> | ||||
|           </ai-dialog> | ||||
|         </template> | ||||
|       </ai-card> | ||||
|       <div v-show="currIndex === 2"> | ||||
|         <ai-card title="异常处理"> | ||||
|           <template #right> | ||||
|             <el-button type="primary" v-if="info.status === '0'" @click="release">解除异常</el-button> | ||||
|           </template> | ||||
|           <template #content> | ||||
|             <ai-wrapper | ||||
|               label-width="120px"> | ||||
|               <ai-info-item label="姓名" :value="info.name"></ai-info-item> | ||||
|               <ai-info-item label="填报时间" :value="info.createTime"></ai-info-item> | ||||
|               <ai-info-item label="身份证号" :value="info.idNumber"></ai-info-item> | ||||
|               <ai-info-item label="手机号码" :value="info.phone"></ai-info-item> | ||||
|               <ai-info-item label="异常状况" isLine> | ||||
|                 <span :style="{color: info.unusual ? 'red' : '#333'}">{{ info.unusual || '-' }}</span> | ||||
|               </ai-info-item> | ||||
|               <ai-info-item label="异常解除人" v-if="info.releaseName && info.status === '1'" :value="info.releaseName"></ai-info-item> | ||||
|               <ai-info-item label="异常解除时间" v-if="info.releaseTime && info.status === '1'" :value="info.releaseTime"></ai-info-item> | ||||
|             </ai-wrapper> | ||||
|           </template> | ||||
|         </ai-card> | ||||
|         <ai-card title="异常情况记录"> | ||||
|           <template #right> | ||||
|             <el-button type="primary" v-if="info.status === '0'" @click="isShowAdd = true">添加记录</el-button> | ||||
|           </template> | ||||
|           <template #content> | ||||
|             <ai-table | ||||
|               :tableData="recordList" | ||||
|               :col-configs="recordConfigs" | ||||
|               :total="recordTotal" | ||||
|               :current.sync="recordSerch.current" | ||||
|               :size.sync="recordSerch.size" | ||||
|               @getList="getRecordList"> | ||||
|               <el-table-column slot="options" width="120px" fixed="right" label="操作" align="center"> | ||||
|                 <template slot-scope="{ row }"> | ||||
|                   <div class="table-options"> | ||||
|                     <el-button type="text" @click="remove(row.id)">删除</el-button> | ||||
|                   </div> | ||||
|                 </template> | ||||
|               </el-table-column> | ||||
|             </ai-table> | ||||
|           </template> | ||||
|         </ai-card> | ||||
|         <ai-dialog | ||||
|           :visible.sync="isShowAdd" | ||||
|           width="800px" | ||||
|           @close="form.content = ''" | ||||
|           title="添加异常记录" | ||||
|           @onConfirm="onConfirm"> | ||||
|           <el-form class="ai-form" label-width="120px" :model="form" ref="form"> | ||||
|             <el-form-item label="异常记录" prop="content" style="width: 100%;" :rules="[{ required: true, message: '请输入异常记录' }]"> | ||||
|               <el-input type="textarea" :rows="5" :maxlength="500" v-model="form.content" clearable placeholder="请输入异常记录" show-word-limit></el-input> | ||||
|             </el-form-item> | ||||
|           </el-form> | ||||
|         </ai-dialog> | ||||
|       </div> | ||||
|     </template> | ||||
|   </ai-detail> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
|   export default { | ||||
|     name: 'Detail', | ||||
|  | ||||
|     props: { | ||||
|       instance: Function, | ||||
|       dict: Object, | ||||
|       params: Object | ||||
|     }, | ||||
|  | ||||
|     data () { | ||||
|       return { | ||||
|         total: 0, | ||||
|         info: {}, | ||||
|         id: '', | ||||
|         isShowAdd: false, | ||||
|         recordTotal: 0, | ||||
|         recordSerch: { | ||||
|           current: 1, | ||||
|           size: 10 | ||||
|         }, | ||||
|         search: { | ||||
|           current: 1, | ||||
|           size: 10 | ||||
|         }, | ||||
|         form: { | ||||
|           content: '' | ||||
|         }, | ||||
|         recordConfigs: [ | ||||
|           {prop: 'content', label: '异常记录', align: 'center' }, | ||||
|           {prop: 'createTime', label: '创建时间', align: 'center'}, | ||||
|           {prop: 'createUserName', label: '记录人', align: 'center' } | ||||
|         ], | ||||
|         reportInfo: {}, | ||||
|         isShow: false, | ||||
|         currIndex: 0, | ||||
|         tableData: [], | ||||
|         recordList: [], | ||||
|         colConfigs: [ | ||||
|           {prop: 'createTime', label: '上报日期', align: 'center', dateFormat: 'YYYY-MM-DD'}, | ||||
|           {prop: 'status', label: '健康状态', align: 'center', formart: v => v === '0' ? '异常' : '正常' } | ||||
|         ], | ||||
|         tabList: ['基本信息', '每日上报', '异常处理'] | ||||
|       } | ||||
|     }, | ||||
|  | ||||
|     created () { | ||||
|       if (this.params && this.params.id) { | ||||
|         this.id = this.params.id | ||||
|         this.dict.load(['epidemicRecentHealth', 'epidemicRecentTravel', 'epidemicTouchInFourteen', 'epidemicMemberType', 'epidemicRecentTestResult']).then(() => { | ||||
|           this.getInfo(this.params.id) | ||||
|           this.getList() | ||||
|           this.getRecordList() | ||||
|         }) | ||||
|       } | ||||
|     }, | ||||
|  | ||||
|     methods: { | ||||
|       getInfo (id) { | ||||
|         this.instance.post(`/app/appepidemicreportmember/queryDetailById?id=${id}`).then(res => { | ||||
|           if (res.code === 0) { | ||||
|             this.info = res.data | ||||
|             this.currIndex = 0 | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       getRecordList () { | ||||
|         this.instance.post(`/app/appepidemicunusuallog/list`, null, { | ||||
|           params: { | ||||
|             ...this.search, | ||||
|             recordId: this.params.id | ||||
|           } | ||||
|         }).then(res => { | ||||
|           if (res.code == 0) { | ||||
|             this.recordList = res.data.records | ||||
|             this.recordTotal = res.data.total | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       onConfirm() { | ||||
|         this.$refs.form.validate(v => { | ||||
|           if (v) { | ||||
|             this.instance.post('/app/appepidemicunusuallog/addOrUpdate', { | ||||
|               ...this.form, | ||||
|               recordId: this.params.id | ||||
|             }).then(res => { | ||||
|               if (res?.code == 0) { | ||||
|                 this.isShowAdd = false | ||||
|                 this.getRecordList(this.params.id) | ||||
|                 this.$message.success('添加成功!') | ||||
|               } | ||||
|             }) | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       release () { | ||||
|         this.$confirm('确定解除异常?').then(() => { | ||||
|           this.instance.post(`/app/appepidemicreportmember/release`, { | ||||
|             id: this.params.id | ||||
|           }).then(res => { | ||||
|             if (res.code == 0) { | ||||
|               this.$message.success('解除异常成功!') | ||||
|               this.currIndex = 0 | ||||
|               this.getInfo(this.params.id) | ||||
|             } | ||||
|           }) | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       remove(id) { | ||||
|         this.$confirm('确定删除该数据?').then(() => { | ||||
|           this.instance.post(`/app/appepidemicunusuallog/delete?ids=${id}`).then(res => { | ||||
|             if (res.code == 0) { | ||||
|               this.$message.success('删除成功!') | ||||
|               this.getRecordList(this.params.id) | ||||
|             } | ||||
|           }) | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       toDetail (id) { | ||||
|         this.instance.post(`/app/appepidemichealthreport/queryDetailById?id=${id}`).then(res => { | ||||
|           if (res.code === 0) { | ||||
|             this.reportInfo = res.data | ||||
|             this.reportInfo.checkPhoto = JSON.parse(res.data.checkPhoto) | ||||
|             let healthName = '' | ||||
|             this.reportInfo.isHealth = false | ||||
|             res.data.health.split(',').forEach(v => { | ||||
|               if (v > 0) { | ||||
|                 this.reportInfo.isHealth = true | ||||
|               } | ||||
|               healthName = healthName + this.dict.getLabel('epidemicRecentHealth', v) | ||||
|             }) | ||||
|             this.reportInfo.healthName = healthName | ||||
|  | ||||
|             this.isShow = true | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       getList () { | ||||
|         this.instance.post(`/app/appepidemichealthreport/list`, null, { | ||||
|           params: { | ||||
|             ...this.search, | ||||
|             memberId: this.params.id | ||||
|           } | ||||
|         }).then(res => { | ||||
|           if (res.code == 0) { | ||||
|             this.tableData = res.data.records | ||||
|             this.total = res.data.total | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       cancel (isRefresh) { | ||||
|         this.$emit('change', { | ||||
|           type: 'list', | ||||
|           isRefresh: !!isRefresh | ||||
|         }) | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| </script> | ||||
|  | ||||
| <style scoped lang="scss"> | ||||
| </style> | ||||
							
								
								
									
										293
									
								
								packages/conv/AppHealthReport/components/List.vue
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										293
									
								
								packages/conv/AppHealthReport/components/List.vue
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,293 @@ | ||||
| <template> | ||||
|   <ai-list class="list"> | ||||
|     <ai-title slot="title" title="健康上报" v-if="search.areaId" isShowBottomBorder :instance="instance" :disabledLevel="disabledLevel" isShowArea v-model="search.areaId" @change="changeArea"></ai-title> | ||||
|     <template slot="content"> | ||||
|       <div class="statistics-top"> | ||||
|         <div class="statistics-top__item"> | ||||
|           <span>上报人数</span> | ||||
|           <h2 style="color: #2266FF;">{{ info.total }}</h2> | ||||
|         </div> | ||||
|         <div class="statistics-top__item"> | ||||
|           <span>今日上报</span> | ||||
|           <h2 style="color: #22AA99;">{{ info.today }}</h2> | ||||
|         </div> | ||||
|         <div class="statistics-top__item"> | ||||
|           <span>今日未报</span> | ||||
|           <h2 style="color: #F8B425">{{ info.unReport }}</h2> | ||||
|         </div> | ||||
|         <div class="statistics-top__item"> | ||||
|           <span>今日异常</span> | ||||
|           <h2 style="color: red">{{ info.unusual }}</h2> | ||||
|         </div> | ||||
|       </div> | ||||
|       <div class="content"> | ||||
|         <ai-search-bar bottomBorder> | ||||
|           <template #left> | ||||
|             <ai-select | ||||
|               v-model="search.checkResult" | ||||
|               clearable | ||||
|               placeholder="请选择检查结果" | ||||
|               :selectList="dict.getDict('epidemicRecentTestResult')" | ||||
|               @change="search.current = 1, getList()"> | ||||
|             </ai-select> | ||||
|             <ai-select | ||||
|               v-model="search.today" | ||||
|               clearable | ||||
|               placeholder="今日是否上报" | ||||
|               :selectList="dictList" | ||||
|               @change="search.current = 1, getList()"> | ||||
|             </ai-select> | ||||
|             <ai-download :instance="instance" url="/app/appepidemicreportmember/export" :params="search" fileName="健康上报" :disabled="tableData.length == 0"> | ||||
|               <el-button icon="iconfont iconExported" :disabled="tableData.length == 0">导出</el-button> | ||||
|             </ai-download> | ||||
|           </template> | ||||
|           <template #right> | ||||
|             <el-input | ||||
|               v-model="search.name" | ||||
|               size="small" | ||||
|               placeholder="请输入姓名" | ||||
|               clearable | ||||
|               v-throttle="() => {search.current = 1, getList()}" | ||||
|               @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" | ||||
|           v-loading="loading" | ||||
|           style="margin-top: 16px;" | ||||
|           :current.sync="search.current" | ||||
|           :size.sync="search.size" | ||||
|           @getList="getList"> | ||||
|           <el-table-column slot="healthCode" align="center" label="健康码"> | ||||
|             <template slot-scope="{ row }"> | ||||
|               <ai-uploader | ||||
|                 v-if="row.healthCode" | ||||
|                 :instance="instance" | ||||
|                 :value="JSON.parse(row.healthCode)" | ||||
|                 disabled | ||||
|                 :limit="1"> | ||||
|               </ai-uploader> | ||||
|             </template> | ||||
|           </el-table-column> | ||||
|           <el-table-column slot="options" width="140px" fixed="right" label="操作" align="center"> | ||||
|             <template slot-scope="{ row }"> | ||||
|               <div class="table-options"> | ||||
|                 <el-button type="text" @click="toDetail(row.id)">详情</el-button> | ||||
|                 <el-button type="text" @click="remove(row.id)">删除</el-button> | ||||
|               </div> | ||||
|             </template> | ||||
|           </el-table-column> | ||||
|         </ai-table> | ||||
|       </div> | ||||
|     </template> | ||||
|   </ai-list> | ||||
| </template> | ||||
|  | ||||
| <script> | ||||
|   import { mapState } from 'vuex' | ||||
|   export default { | ||||
|     name: 'List', | ||||
|  | ||||
|     props: { | ||||
|       instance: Function, | ||||
|       dict: Object | ||||
|     }, | ||||
|  | ||||
|     data () { | ||||
|       return { | ||||
|         search: { | ||||
|           current: 1, | ||||
|           size: 10, | ||||
|           name: '', | ||||
|           checkResult: '', | ||||
|           areaId: '', | ||||
|           today: '' | ||||
|         }, | ||||
|         dictList: [{ | ||||
|           dictName: '否', | ||||
|           dictValue: '0' | ||||
|         }, { | ||||
|           dictName: '是', | ||||
|           dictValue: '1' | ||||
|         }], | ||||
|         info: {}, | ||||
|         colConfigs: [ | ||||
|           { prop: 'name', label: '姓名' }, | ||||
|           { prop: 'phone', align: 'center', label: '手机号码' }, | ||||
|           { prop: 'areaName', align: 'center', label: '所属地区', width: '200px' }, | ||||
|           { prop: 'reportTime', align: 'center', label: '上报时间', width: '200px' },  | ||||
|           { | ||||
|             prop: 'vaccine', | ||||
|             align: 'center', | ||||
|             label: '已接种情况', | ||||
|             render: (h, {row}) => { | ||||
|               return h('span', { | ||||
|                 style: { | ||||
|                 } | ||||
|               }, row.today === '0' ? '-' : (row.vaccine || 0 + '次')) | ||||
|             } | ||||
|           },  | ||||
|           { prop: 'healthCode', align: 'center', label: '健康码', formart: v => v ? this.dict.getLabel('epidemicHealthCode', v) : '-' },  | ||||
|           { prop: 'checkTime', align: 'center', label: '核酸日期', formart: v => v ? v.split(' ')[0] : '-' },  | ||||
|           { prop: 'checkResult', align: 'center', label: '检测结果', formart: v => v ? this.dict.getLabel('epidemicRecentTestResult', v) : '-' },  | ||||
|           { | ||||
|             prop: 'status', | ||||
|             align: 'center', | ||||
|             label: '健康状态', | ||||
|             render: (h, {row}) => { | ||||
|               return h('span', { | ||||
|                 style: { | ||||
|                   color: row.status === '0' ? 'red' : '#333' | ||||
|                 } | ||||
|               }, row.today === '0' ? '-' : (row.status === '0' ? '异常' : '正常')) | ||||
|             } | ||||
|           }, | ||||
|           { prop: 'today', align: 'center', label: '今日上报', formart: v => v === '0' ? '未上报' : '已上报' }, | ||||
|         ], | ||||
|         tableData: [], | ||||
|         total: 0, | ||||
|         loading: false, | ||||
|         disabledLevel: 0 | ||||
|       } | ||||
|     }, | ||||
|  | ||||
|     computed: { | ||||
|       ...mapState(['user']), | ||||
|  | ||||
|       param () { | ||||
|         return { | ||||
|  | ||||
|         } | ||||
|       } | ||||
|     }, | ||||
|  | ||||
|     created () { | ||||
|       this.disabledLevel = this.user.info.areaList.length - 1 | ||||
|       this.search.areaId = this.user.info.areaId | ||||
|       this.loading = true | ||||
|       this.dict.load(['epidemicTouchInFourteen', 'epidemicRecentHealth', 'epidemicRecentTestResult', 'epidemicHealthCode', 'epidemicVaccineTime']).then(() => { | ||||
|         this.getList() | ||||
|       }) | ||||
|     }, | ||||
|  | ||||
|     methods: { | ||||
|       getList () { | ||||
|         this.instance.post(`/app/appepidemicreportmember/list`, null, { | ||||
|           params: { | ||||
|             ...this.search | ||||
|           } | ||||
|         }).then(res => { | ||||
|           if (res.code == 0) { | ||||
|             this.tableData = res.data.records | ||||
|             this.total = res.data.total | ||||
|             this.loading = false | ||||
|           } else { | ||||
|             this.loading = false | ||||
|           } | ||||
|         }).catch(() => { | ||||
|           this.loading = false | ||||
|         }) | ||||
|          | ||||
|         this.getTotalInfo() | ||||
|       }, | ||||
|  | ||||
|       remove(id) { | ||||
|         this.$confirm('确定删除该数据?').then(() => { | ||||
|           this.instance.post(`/app/appepidemicreportmember/delete?ids=${id}`).then(res => { | ||||
|             if (res.code == 0) { | ||||
|               this.$message.success('删除成功!') | ||||
|               this.getTotalInfo() | ||||
|               this.getList() | ||||
|             } | ||||
|           }) | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       toDetail (id) { | ||||
|         this.$emit('change', { | ||||
|           type: 'Detail', | ||||
|           params: { | ||||
|             id: id || '' | ||||
|           } | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       changeArea () { | ||||
|         this.search.current = 1 | ||||
|  | ||||
|         this.$nextTick(() => { | ||||
|           this.getList() | ||||
|           this.getTotalInfo() | ||||
|         }) | ||||
|       }, | ||||
|  | ||||
|       getTotalInfo () { | ||||
|         this.instance.post(`/app/appepidemicreportmember/statistic`, null, { | ||||
|           params: { | ||||
|             areaId: this.search.areaId | ||||
|           } | ||||
|         }).then(res => { | ||||
|           if (res.code == 0) { | ||||
|             this.info = res.data | ||||
|           } | ||||
|         }) | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| </script> | ||||
|  | ||||
| <style scoped lang="scss"> | ||||
|   .list { | ||||
|     ::v-deep .ai-list__content { | ||||
|       padding: 0!important; | ||||
|  | ||||
|       .ai-list__content--right-wrapper { | ||||
|         background: transparent!important; | ||||
|         box-shadow: none!important; | ||||
|         margin: 0!important; | ||||
|         padding: 12px 16px 12px!important; | ||||
|       } | ||||
|     } | ||||
|     .statistics-top { | ||||
|       display: flex; | ||||
|       align-items: center; | ||||
|       margin-bottom: 20px; | ||||
|  | ||||
|       & > div { | ||||
|         flex: 1; | ||||
|         height: 96px; | ||||
|         line-height: 1; | ||||
|         margin-right: 20px; | ||||
|         padding: 16px 24px; | ||||
|         background: #FFFFFF; | ||||
|         box-shadow: 0px 4px 6px -2px rgba(15, 15, 21, 0.15); | ||||
|         border-radius: 4px; | ||||
|  | ||||
|         &:last-child { | ||||
|           margin-right: 0; | ||||
|         } | ||||
|  | ||||
|         h3 { | ||||
|           font-size: 24px; | ||||
|         } | ||||
|  | ||||
|         span { | ||||
|           display: block; | ||||
|           margin-bottom: 16px; | ||||
|           color: #888888; | ||||
|           font-size: 16px; | ||||
|         } | ||||
|       } | ||||
|     } | ||||
|  | ||||
|     .content { | ||||
|       padding: 16px; | ||||
|       background: #FFFFFF; | ||||
|       box-shadow: 0px 4px 6px -2px rgba(15, 15, 21, 0.15); | ||||
|     } | ||||
|   } | ||||
| </style> | ||||
		Reference in New Issue
	
	Block a user