完善自动评估模块,规范性分析报告的后台任务和结果下载逻辑
| | |
| | | }, |
| | | |
| | | /** |
| | | * æ ¹æ®å·¡æ¥ä»»å¡è·åè¯åç»å |
| | | */ |
| | | |
| | | |
| | | /** |
| | | * æ¥è¯¢è¯ä¼°æ»è§å |
| | | * @param {Object} param |
| | | * @returns |
| | |
| | | return $fysp.post(`evaluation/auto`, param).then((res) => res.data); |
| | | }, |
| | | |
| | | downloadAutoEvaluation(param) { |
| | | /** |
| | | * ä¸è½½è§èæ§è¯ä¼°ä¸åææ¥å |
| | | */ |
| | | downloadAutoEvaluation(param, forceUpdate) { |
| | | return $fysp |
| | | .post(`evaluation/auto/record/download`, param, { responseType: 'blob' }) |
| | | .post(`evaluation/auto/record/download?forceUpdate=${forceUpdate}`, param, { responseType: 'blob' }) |
| | | .then((res) => { |
| | | // ææ¡£æªçæï¼å·²å¯å¨ææ¡£çæåå°ä»»å¡ |
| | | if (res.data.type == 'application/json') { |
| | |
| | | |
| | | const debug = true; |
| | | |
| | | let ip1 = 'http://47.100.191.150:9005/'; |
| | | let ip1_file = 'http://47.100.191.150:9005/'; |
| | | // let ip1 = 'http://47.100.191.150:9005/'; |
| | | // let ip1_file = 'http://47.100.191.150:9005/'; |
| | | let ip1 = 'https://fyami.com.cn:447/'; |
| | | let ip1_file = 'https://fyami.com.cn:447/'; |
| | | let ip2 = 'https://fyami.com.cn/'; |
| | | let ip2_file = 'https://fyami.com.cn/'; |
| | | |
| | |
| | | ElButtonGroup: typeof import('element-plus/es')['ElButtonGroup'] |
| | | ElCard: typeof import('element-plus/es')['ElCard'] |
| | | ElCascader: typeof import('element-plus/es')['ElCascader'] |
| | | ElCheckbox: typeof import('element-plus/es')['ElCheckbox'] |
| | | ElCol: typeof import('element-plus/es')['ElCol'] |
| | | ElConfigProvider: typeof import('element-plus/es')['ElConfigProvider'] |
| | | ElContainer: typeof import('element-plus/es')['ElContainer'] |
| | |
| | | FYOptionText: typeof import('./components/search-option/base/FYOptionText.vue')['default'] |
| | | FYOptionTime: typeof import('./components/search-option/FYOptionTime.vue')['default'] |
| | | FYOptionUserType: typeof import('./components/search-option/FYOptionUserType.vue')['default'] |
| | | FYPageHeader: typeof import('./components/head/FYPageHeader.vue')['default'] |
| | | FYReconfrimButton: typeof import('./components/button/FYReconfrimButton.vue')['default'] |
| | | FYSearchBar: typeof import('./components/search-option/FYSearchBar.vue')['default'] |
| | | FYTable: typeof import('./components/table/FYTable.vue')['default'] |
| | |
| | | }); |
| | | }, |
| | | gotoResult(index) {} |
| | | }, |
| | | mounted() { |
| | | this.fetchTask(); |
| | | // setInterval(() => { |
| | | // this.fetchTask(); |
| | | // }, 10000); |
| | | } |
| | | }; |
| | | </script> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <el-page-header @back="onBack" class="page-header"> |
| | | <template #content> |
| | | <span> {{ title }} </span> |
| | | </template> |
| | | </el-page-header> |
| | | <el-divider /> |
| | | </template> |
| | | |
| | | <script> |
| | | export default { |
| | | props: { |
| | | title: { |
| | | type: String, |
| | | default: 'å½å为é»è®¤é¡µé¢æ é¢ï¼è¯·ä¼ å
¥æ é¢åå' |
| | | } |
| | | }, |
| | | methods: { |
| | | // åéé¡µé¢ |
| | | onBack() { |
| | | this.$router.back(); |
| | | } |
| | | } |
| | | }; |
| | | </script> |
| | |
| | | meta: { keepAlive: true } |
| | | }, |
| | | { |
| | | //è¯ä¼°ç»æè¯¦æ
|
| | | name: 'fyspEvalutationEdit', |
| | | path: '/fysp/evaluation/evalutationEdit/:subTaskId', |
| | | component: () => import('@/views/fysp/evaluation/EvalutationEdit.vue'), |
| | | }, |
| | | { |
| | | //åºæ¯ä¿¡æ¯ |
| | | name: 'fyspSceneInfo', |
| | | path: '/fysp/sceneInfo', |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <FYPageHeader title="è¯ä¼°ç»æè¯¦æ
"></FYPageHeader> |
| | | </template> |
| | | |
| | | <script> |
| | | export default { |
| | | data() { |
| | | return {}; |
| | | }, |
| | | methods: {} |
| | | }; |
| | | </script> |
| | | <style scoped></style> |
| | |
| | | <template> |
| | | <!-- <CompPreCheck @pre-check="autoEvaluate"></CompPreCheck> --> |
| | | |
| | | <FYTable @search="onSearch" :pagination="false" ref="tableRef"> |
| | | <template #options> |
| | | <!-- åºå¿ --> |
| | |
| | | ></FYOptionScene> |
| | | <!-- æ¶é´ --> |
| | | <FYOptionTime :initValue="false" type="month" v-model:value="formSearch.time"></FYOptionTime> |
| | | </template> |
| | | <template #buttons> |
| | | <!-- <el-button icon="Download" size="default" type="success" @click="download" |
| | | >è§èæ§è¯ä¼°ä¸åææ¥å</el-button |
| | | > --> |
| | | <CompReport |
| | | :locations="formSearch.locations" |
| | | :scenetype="formSearch.scenetype" |
| | | :time="formSearch.time" |
| | | ></CompReport> |
| | | </template> |
| | | |
| | | <template #options-expand> |
| | |
| | | <!-- <el-table-column prop="biArea" label="éä¸åº" width="110" /> |
| | | <el-table-column prop="biManagementCompany" label="ç©ä¸" min-width="110"/> --> |
| | | <el-table-column fixed="right" align="right" label="æä½" width="160"> |
| | | <template #header> |
| | | <el-button icon="Download" size="default" type="success" @click="download" |
| | | >ä¸è½½ç»æ</el-button |
| | | <!-- <template #header> |
| | | <el-button icon="Download" size="default" type="success" @click="exportExcel" |
| | | >导åºç»æ</el-button |
| | | > |
| | | </template> |
| | | </template> --> |
| | | <template #default="{ row }"> |
| | | <el-button type="primary" size="small" @click="editRow(row)">æ¥ç</el-button> |
| | | </template> |
| | |
| | | import evaluateApi from '@/api/fysp/evaluateApi'; |
| | | import { envCreditCode } from '@/constants/index'; |
| | | import CompQuickSet from './components/CompQuickSet.vue'; |
| | | import CompReport from './components/CompReport.vue'; |
| | | |
| | | export default { |
| | | name: 'ResultManage', |
| | | components: { CompQuickSet }, |
| | | components: { CompQuickSet, CompReport }, |
| | | data() { |
| | | return { |
| | | formSearch: { |
| | |
| | | scensetypeid: scenetype.value |
| | | }; |
| | | }, |
| | | editRow(row) { |
| | | this.$router.push(`evalutationEdit/${row.subTaskId}`); |
| | | }, |
| | | setOptions(param) { |
| | | this.formSearch.locations = param.locations; |
| | | this.formSearch.scenetype = param.scenetype; |
| | |
| | | } |
| | | }); |
| | | }, |
| | | // è§èæ§è¯ä¼°ä¸åææ¥ååå°çæä»»å¡ |
| | | download() { |
| | | const area = this._getParam(); |
| | | evaluateApi.downloadAutoEvaluation(area).then((res) => { |
| | |
| | | } |
| | | }); |
| | | }, |
| | | // 导åºè¡¨æ ¼ä¸ºexcelæ ¼å¼ |
| | | exportExcel() {}, |
| | | getFilters(data) { |
| | | const townList = []; |
| | | data.forEach((e) => { |
| | |
| | | }}</el-button> |
| | | </el-space> |
| | | </el-form-item> |
| | | <!-- <el-row class="row"> |
| | | <el-space> |
| | | <el-text>å¿«æ·éæ©</el-text> |
| | | <el-button v-for="(v, i) in quickSetting" :key="i" type="primary" size="small" @click="quickSet(v)">{{ |
| | | v.name |
| | | }}</el-button> |
| | | </el-space> |
| | | </el-row> --> |
| | | </template> |
| | | <script> |
| | | export default { |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <el-button icon="Download" type="success" @click="dialogVisible = true" |
| | | >è§èæ§è¯ä¼°ä¸åææ¥å</el-button |
| | | > |
| | | <el-dialog |
| | | v-model="dialogVisible" |
| | | title="è§èæ§è¯ä¼°ä¸åææ¥åçæ" |
| | | width="500" |
| | | :before-close="handleClose" |
| | | > |
| | | <el-text tag="b" size="large">æ°æ®èå´ç¡®è®¤</el-text> |
| | | <el-text tag="div">åºåï¼{{ locationText }}</el-text> |
| | | <el-text tag="div">ç±»åï¼{{ scenetype.label }}</el-text> |
| | | <el-text tag="div">æ¶é´ï¼{{ timeText }}</el-text> |
| | | <template #footer> |
| | | <div class="dialog-footer"> |
| | | <el-row align="middle"> |
| | | <el-checkbox v-model="forceUpdate" label="强å¶çææ°æ¥å" /> |
| | | <el-tooltip placement="bottom-start" effect="light"> |
| | | <template #content> |
| | | <el-text tag="b" size="small">ä¸å¾éï¼</el-text><br /> |
| | | <el-text size="small" |
| | | >ä¸å¾éæ¶ï¼å¦æå·²çæè¿ç¸ååºåçæ¥åï¼åç´æ¥è·å该份æ¥åè®°å½</el-text |
| | | ><br /> |
| | | <el-text tag="b" size="small">å¾éï¼</el-text><br /> |
| | | <el-text size="small" |
| | | >å¾éæ¶ï¼æ 论æ¯å¦æåå²è®°å½ï¼é½ä¼å¯å¨æ¥åçæä»»å¡è¦çæ§è®°å½ï¼å¯å¨åå°ä»»å¡ç颿¥çä»»å¡è¿åº¦</el-text |
| | | ><br /> |
| | | </template> |
| | | <el-icon class="m-l-8 cursor-p" :size="16" color="var(--el-color-warning)" |
| | | ><QuestionFilled |
| | | /></el-icon> |
| | | </el-tooltip> |
| | | </el-row> |
| | | <div> |
| | | <el-button @click="dialogVisible = false">åæ¶</el-button> |
| | | <el-button type="primary" @click="download">ç¡®å®</el-button> |
| | | </div> |
| | | </div> |
| | | </template> |
| | | </el-dialog> |
| | | </template> |
| | | |
| | | <script> |
| | | import dayjs from 'dayjs'; |
| | | import evaluateApi from '@/api/fysp/evaluateApi'; |
| | | |
| | | export default { |
| | | props: ['locations', 'time', 'scenetype'], |
| | | data() { |
| | | return { |
| | | dialogVisible: false, |
| | | forceUpdate: false |
| | | }; |
| | | }, |
| | | computed: { |
| | | locationText() { |
| | | const loc = this.locations; |
| | | let text = ''; |
| | | text = loc.pName == loc.cName ? loc.pName : loc.pName + loc.cName; |
| | | text += loc.dName; |
| | | return text; |
| | | }, |
| | | timeText() { |
| | | return dayjs(this.time).format('YYYYå¹´MMæ'); |
| | | } |
| | | }, |
| | | methods: { |
| | | // è§èæ§è¯ä¼°ä¸åææ¥ååå°çæä»»å¡ |
| | | download() { |
| | | const locations = this.locations; |
| | | const time = this.time; |
| | | const scenetype = this.scenetype; |
| | | const area = { |
| | | provincecode: locations.pCode, |
| | | provincename: locations.pName, |
| | | citycode: locations.cCode, |
| | | cityname: locations.cName, |
| | | districtcode: locations.dCode, |
| | | districtname: locations.dName, |
| | | starttime: dayjs(this.time).format('YYYY-MM-DD HH:mm:ss'), |
| | | scensetypeid: scenetype.value |
| | | }; |
| | | evaluateApi.downloadAutoEvaluation(area, this.forceUpdate).then((res) => { |
| | | if (res == false) { |
| | | // æªä¸è½½ææ¡£ï¼èæ¯å¼å¯äºææ¡£çæåå°ä»»å¡ |
| | | this.$parent; |
| | | } |
| | | this.dialogVisible = false; |
| | | }); |
| | | } |
| | | } |
| | | }; |
| | | </script> |
| | | <style scoped> |
| | | .dialog-footer { |
| | | display: flex; |
| | | justify-content: space-between; |
| | | align-items: center; |
| | | gap: 2px; |
| | | } |
| | | </style> |
| | |
| | | <el-form-item label="åºæ¯åç§°" prop="name"> |
| | | <el-input clearable show-word-limit v-model="formObj.name" placeholder="åºæ¯åç§°" /> |
| | | </el-form-item> |
| | | <el-form-item label="åºæ¯ç±»å" prop="_typeObj"> |
| | | <el-select v-model="formObj._typeObj" placeholder="åºæ¯ç±»å"> |
| | | <!-- <el-form-item label="åºæ¯ç±»å" prop="_scenetype"> |
| | | <el-select v-model="formObj._scenetype" placeholder="åºæ¯ç±»å"> |
| | | <el-option v-for="s in sceneTypes" :key="s.value" :label="s.label" :value="s" /> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="ç/å¸/åº/é" prop="_locations"> |
| | | <el-cascader |
| | | v-model="formObj._locations" |
| | | :options="locations" |
| | | placeholder="ç/å¸/åº/é" |
| | | style="width: 300px" |
| | | :props="cascaderProps" |
| | | /> |
| | | </el-form-item> |
| | | </el-form-item> --> |
| | | <!-- åºæ¯ç±»å --> |
| | | <FYOptionScene |
| | | :allOption="false" |
| | | :type="2" |
| | | v-model:value="formObj._scenetype" |
| | | ></FYOptionScene> |
| | | <!-- åºå¿ --> |
| | | <FYOptionLocation |
| | | :allOption="false" |
| | | :level="4" |
| | | :initValue="false" |
| | | :checkStrictly="true" |
| | | v-model:value="formObj._locations" |
| | | ></FYOptionLocation> |
| | | <el-form-item label="å°å" prop="location"> |
| | | <el-input show-word-limit clearable v-model="formObj.location" placeholder="å°å" /> |
| | | </el-form-item> |
| | |
| | | </template> |
| | | |
| | | <script setup> |
| | | import { defineProps, defineEmits, reactive, ref, watch, computed } from 'vue'; |
| | | import { defineProps, defineEmits, reactive, ref, unref, watch, computed } from 'vue'; |
| | | import { enumScene } from '@/enum/scene'; |
| | | import { enumLocation } from '@/enum/location'; |
| | | import sceneApi from '@/api/fysp/sceneApi'; |
| | | |
| | | const props = defineProps({ |
| | |
| | | |
| | | const emit = defineEmits(['onSubmit', 'onCancel']); |
| | | |
| | | const sceneTypes = reactive(enumScene(2, false)); |
| | | const locations = reactive(enumLocation(false)); |
| | | const cascaderProps = reactive({ |
| | | checkStrictly: true |
| | | }); |
| | | const sceneTypes = ref(enumScene(2, false)); |
| | | const rules = reactive({ |
| | | name: [ |
| | | { |
| | |
| | | trigger: 'blur' |
| | | } |
| | | ], |
| | | _typeObj: [ |
| | | _scenetype: [ |
| | | { |
| | | required: true, |
| | | message: 'åºæ¯ç±»åä¸è½ä¸ºç©º', |
| | |
| | | * å¯¹åºæ¯ç±»åãåºæ¯è¡æ¿åºåååºæ¯å¯ç¨ç¶æè¿è¡æ ¼å¼å |
| | | * @param {*} s åºæ¯ä¿¡æ¯ |
| | | */ |
| | | function parseSceneBaseInfo(s) { |
| | | s._typeObj = { |
| | | function parseSceneBaseInfo(param) { |
| | | const s = unref(param); |
| | | s._scenetype = { |
| | | label: s.type, |
| | | value: s.typeid + '' |
| | | }; |
| | | |
| | | s._locations = []; |
| | | if (s.provincecode && s.provincecode.length > 0) |
| | | s._locations.push([s.provincecode, s.provincename]); |
| | | if (s.citycode && s.citycode.length > 0) s._locations.push([s.citycode, s.cityname]); |
| | | if (s.districtcode && s.districtcode.length > 0) |
| | | s._locations.push([s.districtcode, s.districtname]); |
| | | if (s.towncode && s.towncode.length > 0) s._locations.push([s.towncode, s.townname]); |
| | | s._locations = { |
| | | pCode: s.provincecode, |
| | | pName: s.provincename, |
| | | cCode: s.citycode, |
| | | cName: s.cityname, |
| | | dCode: s.districtcode, |
| | | dName: s.districtname, |
| | | tCode: s.towncode, |
| | | tName: s.townname |
| | | }; |
| | | |
| | | s.online = s.extension1 != '0'; |
| | | |
| | |
| | | function submit(v, success, fail) { |
| | | // è¡æ¿åºåä¿¡æ¯å¡«å
|
| | | const a = v.value._locations; |
| | | if (a[0]) { |
| | | v.value.provincecode = a[0][0]; |
| | | v.value.provincename = a[0][1]; |
| | | } |
| | | if (a[1]) { |
| | | v.value.citycode = a[1][0]; |
| | | v.value.cityname = a[1][1]; |
| | | } |
| | | if (a[2]) { |
| | | v.value.districtcode = a[2][0]; |
| | | v.value.districtname = a[2][1]; |
| | | } |
| | | if (a[3]) { |
| | | v.value.towncode = a[3][0]; |
| | | v.value.townname = a[3][1]; |
| | | } |
| | | v.value.provincecode = a.pCode; |
| | | v.value.provincename = a.pName; |
| | | v.value.citycode = a.cCode; |
| | | v.value.cityname = a.cName; |
| | | v.value.districtcode = a.dCode; |
| | | v.value.districtname = a.dName; |
| | | v.value.towncode = a.tCode; |
| | | v.value.townname = a.tName; |
| | | |
| | | // åºæ¯ç±»åä¿¡æ¯å¡«å
|
| | | const b = v.value._typeObj; |
| | | const b = v.value._scenetype; |
| | | v.value.typeid = b.value; |
| | | v.value.type = b.label; |
| | | |
| | |
| | | <template> |
| | | <el-page-header @back="onBack"> |
| | | <el-page-header @back="onBack" class="page-header"> |
| | | <template #content> |
| | | <span> åºæ¯ä¿¡æ¯ç¼è¾ </span> |
| | | </template> |
| | |
| | | margin-bottom: 30px; |
| | | margin-left: 20px; |
| | | } |
| | | .page-header { |
| | | /* position: absolute; */ |
| | | } |
| | | </style> |
| | |
| | | :level="4" |
| | | v-model:value="formSearch._locations" |
| | | ></FYOptionLocation> |
| | | <FYOptionText |
| | | label="åºæ¯åç§°" |
| | | placeholder="è¾å
¥åç§°å
³é®å" |
| | | v-model:value="formSearch.searchText" |
| | | ></FYOptionText> |
| | | <FYOptionScene |
| | | :allOption="true" |
| | | :type="2" |
| | | v-model:value="formSearch.scensetype" |
| | | v-model:value="formSearch._scenetype" |
| | | ></FYOptionScene> |
| | | <FYOptionOnlineStatus |
| | | :allOption="true" |
| | |
| | | return { |
| | | formSearch: { |
| | | _locations: {}, |
| | | scensetype: {}, |
| | | searchText: '', |
| | | _scenetype: {}, |
| | | online: {} |
| | | } |
| | | }; |
| | |
| | | area.districtcode = f._locations.dCode; |
| | | area.towncode = f._locations.tCode; |
| | | // åºæ¯ç±»å |
| | | area.scensetypeid = f.scensetype.value; |
| | | area.scensetypeid = f._scenetype.value; |
| | | if (area.scensetypeid == '0') area.scensetypeid = null; |
| | | // ä¸ä¸çº¿ç¶æ |
| | | area.online = f.online.value; |
| | | // æ¥è¯¢å
³é®å(åºæ¯åç§°) |
| | | area.sceneName = f.searchText |
| | | |
| | | return sceneApi.searchScene(area, page.currentPage, page.pageSize).then((res) => { |
| | | if (res.success) { |
| | |
| | | v-model:value="formSearch._locations" |
| | | ></FYOptionLocation> |
| | | <FYOptionText |
| | | label="å
³é®å" |
| | | label="åºæ¯åç§°" |
| | | placeholder="è¾å
¥åç§°å
³é®å" |
| | | v-model:value="formSearch.searchText" |
| | | ></FYOptionText> |
| | |
| | | :doClear="active" |
| | | :useCancel="create" |
| | | :useReset="!create" |
| | | @updateEdit="(v) => $emit('updateEdit', v)" |
| | | @update:isEdit="(v) => $emit('updateEdit', v)" |
| | | @submit="submit" |
| | | @cancel="$emit('onCancel')" |
| | | > |
| | |
| | | // å¼¹åºç¡®è®¤æ¡ |
| | | useMessageBox({ |
| | | confirmMsg: 'æ¯å¦æ¾å¼å·²ç¼è¾çå
容ï¼', |
| | | confirmTitle: 'åæ¶', |
| | | confirmTitle: 'å
³éå¼¹åºæ¡', |
| | | onConfirm: () => { |
| | | done(); |
| | | } |