¶Ô±ÈÐÂÎļþ |
| | |
| | | import { $clue } from '../index'; |
| | | |
| | | export default { |
| | | /** |
| | | * åå»ºçº¿ç´¢ä»»å¡ |
| | | * @param {*} clueTask |
| | | * @returns |
| | | */ |
| | | createClueTask(clueTask) { |
| | | return $clue |
| | | .put(`clue/task/create`, clueTask) |
| | | }, |
| | | |
| | | /** |
| | | * æ´æ°çº¿ç´¢ä»»å¡ |
| | | * @param {*} clueTask |
| | | * @returns |
| | | */ |
| | | updateClueTask(clueTask) { |
| | | return $clue |
| | | .post(`clue/task/update`, clueTask) |
| | | }, |
| | | |
| | | /** |
| | | * æ¥è¯¢çº¿ç´¢ä»»å¡ |
| | | * @param {*} clueTask |
| | | * @returns |
| | | */ |
| | | fetchClueTask(clueTask) { |
| | | return $clue |
| | | .post(`clue/task/fetch`, clueTask) |
| | | } |
| | | }; |
¶Ô±ÈÐÂÎļþ |
| | |
| | | import { $fysp } from '../index'; |
| | | |
| | | export default { |
| | | /** |
| | | * è·åç¨æ·è¯¦æ
|
| | | */ |
| | | getUserById(id) { |
| | | return $fysp.get(`userinfo/${id}`).then((res) => res.data); |
| | | }, |
| | | |
| | | /** |
| | | * æ´æ°ç¨æ·è¯¦æ
|
| | | */ |
| | | updateUser(user) { |
| | | return $fysp.post(`userinfo`, user).then((res) => res.data); |
| | | }, |
| | | |
| | | /** |
| | | * è·ååºæ¯çç¨æ·è¯¦æ
|
| | | */ |
| | | getUserByScene(sId) { |
| | | return $fysp |
| | | .get(`userinfo/scene/get?sceneId=${sId}`) |
| | | .then((res) => res.data); |
| | | }, |
| | | |
| | | /** |
| | | * èªå¨åå»ºè´¦æ· |
| | | */ |
| | | autoCreateAccount(sId) { |
| | | return $fysp.post(`userinfo/create?sceneId=${sId}`).then((res) => res.data); |
| | | }, |
| | | /** |
| | | * è·ååºæ¯å¯¹åºçé£ç¾½ç¯å¢ç³»ç»ç¨æ·id |
| | | */ |
| | | getTzId(sceneId) { |
| | | return $fysp.get(`usermap?sceneId=${sceneId}`).then((res) => res.data); |
| | | }, |
| | | |
| | | /** |
| | | * æç¨æ·ç±»åè·åç¨æ·ä¿¡æ¯ |
| | | */ |
| | | getUserByType(typeId, enable = true) { |
| | | return $fysp |
| | | .get(`userinfo/type/get`, { params: { typeId, enable } }) |
| | | .then((res) => res.data); |
| | | } |
| | | }; |
| | |
| | | import axios from 'axios'; |
| | | import { setInterceptors } from "./config"; |
| | | |
| | | // const url = 'http://47.100.191.150:9031/'; |
| | | const url = 'http://192.168.0.110:8084/'; |
| | | // const imgUrl = 'http://47.100.191.150:9031/images/'; |
| | | const imgUrl = 'http://192.168.0.110:8084/images/'; |
| | | const debug = true; |
| | | |
| | | // let url1 = 'http://47.100.191.150:9031/'; |
| | | // let url1_file = 'http://47.100.191.150:9031'; |
| | | let url1 = 'https://fyami.com.cn:448/'; |
| | | let url1_file = 'https://fyami.com.cn:448/'; |
| | | let url2 = 'http://47.100.191.150:9005/'; |
| | | let url2_file = 'http://47.100.191.150:9005/'; |
| | | |
| | | if (debug) { |
| | | url1 = 'http://192.168.0.110:8084/'; |
| | | url1_file = 'http://192.168.0.110:8084/'; |
| | | // url2 = 'http://192.168.0.110:9001/'; |
| | | // url2_file = 'http://192.168.0.138:8080/'; |
| | | } |
| | | |
| | | //é£ç¾½ç管 |
| | | const $clue = axios.create({ |
| | | baseURL: url, |
| | | timeout: 10000 |
| | | baseURL: url1, |
| | | timeout: 20000 |
| | | // headers: addHeaders() |
| | | }); |
| | | $clue.imgUrl = `${url1_file}images/`; |
| | | |
| | | //é£ç¾½ç管 |
| | | const $fysp = axios.create({ |
| | | baseURL: url2, |
| | | timeout: 20000 |
| | | }); |
| | | $fysp.imgUrl = `${url2_file}images/`; |
| | | $fysp.downloadUrl = `${url2_file}files/`; |
| | | |
| | | // function getHeaders() { |
| | | // const token = 'e6dc8bb9e1ff0ce973fb92b4af2e4c3f'; |
| | |
| | | |
| | | //æ·»å æ¦æªå¨ |
| | | setInterceptors($clue) |
| | | setInterceptors($fysp) |
| | | |
| | | export { $clue, imgUrl }; |
| | | export { $clue, $fysp }; |
| | |
| | | DescriptionsList: typeof import('./components/list/DescriptionsList.vue')['default'] |
| | | DescriptionsListItem: typeof import('./components/list/DescriptionsListItem.vue')['default'] |
| | | ElButton: typeof import('element-plus/es')['ElButton'] |
| | | ElCascader: typeof import('element-plus/es')['ElCascader'] |
| | | ElCol: typeof import('element-plus/es')['ElCol'] |
| | | ElConfigProvider: typeof import('element-plus/es')['ElConfigProvider'] |
| | | ElDatePicker: typeof import('element-plus/es')['ElDatePicker'] |
| | |
| | | ElScrollbar: typeof import('element-plus/es')['ElScrollbar'] |
| | | ElSelect: typeof import('element-plus/es')['ElSelect'] |
| | | ElSpace: typeof import('element-plus/es')['ElSpace'] |
| | | ElSwitch: typeof import('element-plus/es')['ElSwitch'] |
| | | ElTag: typeof import('element-plus/es')['ElTag'] |
| | | ElText: typeof import('element-plus/es')['ElText'] |
| | | ElUpload: typeof import('element-plus/es')['ElUpload'] |
| | | MapSearch: typeof import('./components/map/MapSearch.vue')['default'] |
| | | OptionExecutors: typeof import('./components/search-option/OptionExecutors.vue')['default'] |
| | | OptionLocation: typeof import('./components/search-option/OptionLocation.vue')['default'] |
| | | OptionResponseLevel: typeof import('./components/search-option/OptionResponseLevel.vue')['default'] |
| | | OptionTime: typeof import('./components/search-option/OptionTime.vue')['default'] |
| | | OptionTravelMode: typeof import('./components/search-option/OptionTravelMode.vue')['default'] |
| | | RouterLink: typeof import('vue-router')['RouterLink'] |
| | | RouterView: typeof import('vue-router')['RouterView'] |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <el-select |
| | | :model-value="modelValue" |
| | | @update:model-value="handleChange" |
| | | multiple |
| | | clearable |
| | | placeholder="éæ©æ§è¡äºº" |
| | | class="w-300" |
| | | > |
| | | <el-option |
| | | v-for="(s, i) in executorOptions" |
| | | :key="i" |
| | | :label="s.label" |
| | | :value="s.value" |
| | | /> |
| | | </el-select> |
| | | </template> |
| | | |
| | | <script> |
| | | /** |
| | | * çº¿ç´¢ä»»å¡æ§è¡äººé项 |
| | | */ |
| | | import userApi from '@/api/fysp/userApi'; |
| | | export default { |
| | | props: { |
| | | modelValue: { |
| | | type: Array, |
| | | default: () => [] |
| | | }, |
| | | userType: { |
| | | type: Number, |
| | | default: 1 |
| | | } |
| | | }, |
| | | emits: ['update:modelValue', 'initOver'], |
| | | data() { |
| | | return { |
| | | executorOptions: [] |
| | | }; |
| | | }, |
| | | methods: { |
| | | getOptions() { |
| | | return userApi.getUserByType(this.userType).then((res) => { |
| | | res.forEach((v) => { |
| | | this.executorOptions.push({ |
| | | label: v.realname, |
| | | value: v.guid |
| | | // data: v |
| | | }); |
| | | }); |
| | | // this.executorOptions = res.map((v) => { |
| | | // return { |
| | | // label: v.realname, |
| | | // value: v.guid |
| | | // // data: v |
| | | // }; |
| | | // }); |
| | | }); |
| | | }, |
| | | handleChange(value) { |
| | | this.$emit('update:modelValue', value); |
| | | } |
| | | }, |
| | | mounted() { |
| | | this.getOptions().finally(() => this.$emit('initOver')); |
| | | // this.handleChange(this.pollutionList[0].value); |
| | | } |
| | | }; |
| | | </script> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <!-- <el-form-item :label="placeholder" :prop="prop"> --> |
| | | <el-cascader |
| | | :model-value="formatedValue" |
| | | @change="handleChange" |
| | | :options="locations" |
| | | :placeholder="placeholder" |
| | | :props="optionProps" |
| | | :style="'width: ' + width + 'px'" |
| | | /> |
| | | <!-- </el-form-item> --> |
| | | </template> |
| | | |
| | | <script> |
| | | import { enumLocation } from '@/constant/location'; |
| | | |
| | | export default { |
| | | props: { |
| | | // æ¯å¦å¨é¦é项夿·»å âå
¨é¨âé项 |
| | | allOption: { |
| | | type: Boolean, |
| | | default: true |
| | | }, |
| | | // æ¥è¯¢çè¡æ¿çº§å«ï¼åå¼1ï¼2ï¼3ï¼4, 5, 6 |
| | | level: { |
| | | type: Number, |
| | | default: 4 |
| | | }, |
| | | // ç»æè¿å |
| | | modelValue: Object, |
| | | // æ¯å¦é»è®¤è¿ååå§é项 |
| | | initValue: { |
| | | type: Boolean, |
| | | default: true |
| | | }, |
| | | // è½å¦éæ©ä»»æä¸çº§é项 |
| | | checkStrictly: { |
| | | type: Boolean, |
| | | default: true |
| | | }, |
| | | prop: { |
| | | type: String, |
| | | default: '_locations' |
| | | }, |
| | | width: { |
| | | type: Number, |
| | | default: 220 |
| | | } |
| | | }, |
| | | emits: ['update:modelValue'], |
| | | data() { |
| | | return { |
| | | locations: enumLocation(this.allOption, this.level), |
| | | optionProps: { |
| | | checkStrictly: this.checkStrictly |
| | | } |
| | | }; |
| | | }, |
| | | computed: { |
| | | placeholder() { |
| | | const list = 'ç/å¸/åº/é/é/ç©'.split('/'); |
| | | const p = []; |
| | | for (let i = 0; i < this.level; i++) { |
| | | p.push(list[i]); |
| | | } |
| | | return p.join('/'); |
| | | }, |
| | | formatedValue() { |
| | | return this.optionFormatReverse(this.modelValue); |
| | | } |
| | | }, |
| | | methods: { |
| | | handleChange(value) { |
| | | this.$emit('update:modelValue', this.optionFormat(value)); |
| | | }, |
| | | /** |
| | | * å°åºéé¡¹ç»ææ ¼å¼å |
| | | */ |
| | | optionFormat(val) { |
| | | const res = { |
| | | pCode: null, |
| | | pName: null, |
| | | cCode: null, |
| | | cName: null, |
| | | dCode: null, |
| | | dName: null, |
| | | tCode: null, |
| | | tName: null, |
| | | aCode: null, |
| | | aName: null, |
| | | mCode: null, |
| | | mName: null |
| | | }; |
| | | if (val.length > 0) { |
| | | res.pCode = val[0][0]; |
| | | res.pName = val[0][1]; |
| | | } |
| | | if (val.length > 1) { |
| | | res.cCode = val[1][0]; |
| | | res.cName = val[1][1]; |
| | | } |
| | | if (val.length > 2) { |
| | | res.dCode = val[2][0]; |
| | | res.dName = val[2][1]; |
| | | } |
| | | if (val.length > 3) { |
| | | res.tCode = val[3][0]; |
| | | res.tName = val[3][1]; |
| | | } |
| | | if (val.length > 4) { |
| | | res.aCode = val[4][0]; |
| | | res.aName = val[4][1]; |
| | | } |
| | | if (val.length > 5) { |
| | | res.mCode = val[5][0]; |
| | | res.mName = val[5][1]; |
| | | } |
| | | return res; |
| | | }, |
| | | optionFormatReverse(val) { |
| | | const res = []; |
| | | if (val) { |
| | | if (val.pName) { |
| | | res.push([val.pCode, val.pName]); |
| | | } |
| | | if (val.cName) { |
| | | res.push([val.cCode, val.cName]); |
| | | } |
| | | if (val.dName) { |
| | | res.push([val.dCode, val.dName]); |
| | | } |
| | | if (val.tName) { |
| | | res.push([val.tCode, val.tName]); |
| | | } |
| | | if (val.aName) { |
| | | res.push([val.aCode, val.aName]); |
| | | } |
| | | if (val.mName) { |
| | | res.push([val.mCode, val.mName]); |
| | | } |
| | | } |
| | | return res; |
| | | } |
| | | }, |
| | | mounted() { |
| | | if (this.initValue) { |
| | | if (this.checkStrictly) { |
| | | this.handleChange([this.locations[0].value]); |
| | | } else { |
| | | const f = (location) => { |
| | | if (location.children && location.children.length > 0) { |
| | | const r = f(location.children[0]); |
| | | r.unshift(location.value); |
| | | return r; |
| | | } else { |
| | | return [location.value]; |
| | | } |
| | | }; |
| | | this.handleChange(f(this.locations[0])); |
| | | } |
| | | } |
| | | } |
| | | }; |
| | | </script> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <el-select |
| | | :model-value="modelValue" |
| | | @update:model-value="handleChange" |
| | | placeholder="ååºçº§å«" |
| | | class="w-120" |
| | | > |
| | | <el-option |
| | | v-for="(s, i) in responseLevelList" |
| | | :key="i" |
| | | :label="s.label" |
| | | :value="s.value" |
| | | /> |
| | | </el-select> |
| | | </template> |
| | | |
| | | <script> |
| | | /** |
| | | * 线索任å¡ååºçº§å«é项 |
| | | */ |
| | | import { responseLevelList } from '@/constant/response-level'; |
| | | export default { |
| | | props: { |
| | | modelValue: String |
| | | }, |
| | | emits: ['update:modelValue', 'initOver'], |
| | | data() { |
| | | return { |
| | | responseLevelList: responseLevelList() |
| | | }; |
| | | }, |
| | | methods: { |
| | | handleChange(value) { |
| | | this.$emit('update:modelValue', value); |
| | | } |
| | | }, |
| | | mounted() { |
| | | this.$emit('initOver'); |
| | | // this.handleChange(this.pollutionList[0].value); |
| | | } |
| | | }; |
| | | </script> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <el-select |
| | | :model-value="modelValue" |
| | | @update:model-value="handleChange" |
| | | placeholder="åºè¡æ¹å¼" |
| | | class="w-120" |
| | | > |
| | | <el-option |
| | | v-for="(s, i) in travelModeList" |
| | | :key="i" |
| | | :label="s.label" |
| | | :value="s.value" |
| | | /> |
| | | </el-select> |
| | | </template> |
| | | |
| | | <script> |
| | | /** |
| | | * 线索任å¡åºè¡æ¹å¼é项 |
| | | */ |
| | | import { travelModeList } from '@/constant/travel-mode'; |
| | | export default { |
| | | props: { |
| | | modelValue: String |
| | | }, |
| | | emits: ['update:modelValue', 'initOver'], |
| | | data() { |
| | | return { |
| | | travelModeList: travelModeList() |
| | | }; |
| | | }, |
| | | methods: { |
| | | handleChange(value) { |
| | | this.$emit('update:modelValue', value); |
| | | } |
| | | }, |
| | | mounted() { |
| | | this.$emit('initOver'); |
| | | // this.handleChange(this.pollutionList[0].value); |
| | | } |
| | | }; |
| | | </script> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | /** |
| | | * è·åè¡æ¿åºå |
| | | * @param {Boolean} allOption æ¯å¦å¨å¤´é¨æ·»å âå
¨é¨âé项 |
| | | * @param {Number} level è·åçå类深度ï¼èå´ 1 - 4 |
| | | * @returns |
| | | */ |
| | | function enumLocation(allOption = true, level = 4) { |
| | | const l = _enumLocation(); |
| | | if (!allOption) { |
| | | l.shift(); |
| | | } |
| | | _deleteByLevel(l, level, 1); |
| | | |
| | | return l; |
| | | } |
| | | |
| | | function _enumLocation() { |
| | | return [ |
| | | { |
| | | label: 'å
¨å¸', |
| | | value: [null, 'å
¨å¸'] |
| | | }, |
| | | { |
| | | label: '䏿µ·å¸', |
| | | value: ['31', '䏿µ·å¸'], |
| | | children: [ |
| | | { |
| | | label: '䏿µ·å¸', |
| | | value: ['3100', '䏿µ·å¸'], |
| | | children: [ |
| | | { |
| | | label: 'éå±±åº', |
| | | value: ['310116', 'éå±±åº'], |
| | | children: [ |
| | | { label: 'å¼ å °é', value: ['310116103', 'å¼ å °é'] }, |
| | | { label: 'äºæé', value: ['310116104', 'äºæé'] }, |
| | | { label: 'åå··é', value: ['310116105', 'åå··é'] }, |
| | | { label: 'å»ä¸é', value: ['310116107', 'å»ä¸é'] }, |
| | | { label: '髿°åº', value: ['310116503', '髿°åº'] }, |
| | | { label: 'éå±±å«é', value: ['310116109', 'éå±±å«é'] }, |
| | | { label: 'æ¼æ³¾é', value: ['310116112', 'æ¼æ³¾é'] }, |
| | | { |
| | | label: 'å±±é³é', |
| | | value: ['310116113', 'å±±é³é'], |
| | | children: [ |
| | | { |
| | | label: 'ä¸è¾¾å¹¿åº', |
| | | value: ['31011611301', 'ä¸è¾¾å¹¿åº'] |
| | | } |
| | | ] |
| | | }, |
| | | { label: 'ç³åè¡é', value: ['310116001', 'ç³åè¡é'] }, |
| | | { label: 'æ±æ³¾é', value: ['310116101', 'æ±æ³¾é'] }, |
| | | { label: 'æ«æ³¾é', value: ['310116102', 'æ«æ³¾é'] }, |
| | | { label: '碳谷绿湾', value: ['9000', '碳谷绿湾'] } |
| | | ] |
| | | }, |
| | | { |
| | | label: '徿±åº', |
| | | value: ['310104', '徿±åº'], |
| | | children: [ |
| | | { |
| | | label: 'æ¼æ²³æ³¾æ°å
´ææ¯å¼ååº', |
| | | value: ['310104501', 'æ¼æ²³æ³¾æ°å
´ææ¯å¼ååº'] |
| | | }, |
| | | { label: 'æ¹åè·¯è¡é', value: ['310104004', 'æ¹åè·¯è¡é'] }, |
| | | { label: '天平路è¡é', value: ['310104003', '天平路è¡é'] }, |
| | | { label: 'è¹æ¢
è·¯è¡é', value: ['310104012', 'è¹æ¢
è·¯è¡é'] }, |
| | | { label: 'æ«æè·¯è¡é', value: ['310104008', 'æ«æè·¯è¡é'] }, |
| | | { label: 'æåè·¯è¡é', value: ['310104007', 'æåè·¯è¡é'] }, |
| | | { label: 'é¿æ¡¥è¡é', value: ['310104010', 'é¿æ¡¥è¡é'] }, |
| | | { |
| | | label: 'ç°æè¡é', |
| | | value: ['310104011', 'ç°æè¡é'], |
| | | children: [ |
| | | { |
| | | label: 'ç°å°å', |
| | | value: ['31010401101', 'ç°å°å'] |
| | | } |
| | | ] |
| | | }, |
| | | { label: 'åº·å¥æ°æè¡é', value: ['310104013', 'åº·å¥æ°æè¡é'] }, |
| | | { |
| | | label: 'å¾å®¶æ±è¡é', |
| | | value: ['310104014', 'å¾å®¶æ±è¡é'], |
| | | children: [ |
| | | { |
| | | label: '天饿¡¥', |
| | | value: ['31010401401', '天饿¡¥'] |
| | | } |
| | | ] |
| | | }, |
| | | { label: 'åäºè·¯è¡é', value: ['310104015', 'åäºè·¯è¡é'] }, |
| | | { label: 'é¾åè¡é', value: ['310104016', 'é¾åè¡é'] }, |
| | | { label: 'æ¼æ²³æ³¾è¡é', value: ['310104017', 'æ¼æ²³æ³¾è¡é'] }, |
| | | { label: 'åæ³¾é', value: ['310104103', 'åæ³¾é'] } |
| | | ] |
| | | }, |
| | | { |
| | | label: 'éå®åº', |
| | | value: ['310106', 'éå®åº'], |
| | | children: [ |
| | | { |
| | | label: '大å®è·¯è¡é', |
| | | value: ['310106019', '大å®è·¯è¡é'], |
| | | children: [ |
| | | { |
| | | label: 'ä¹
å
ä¸å¿', |
| | | value: ['31010601901', 'ä¹
å
ä¸å¿'] |
| | | } |
| | | ] |
| | | }, |
| | | { label: '彿µ¦æ°æè¡é', value: ['310106020', '彿µ¦æ°æè¡é'] }, |
| | | { label: '临汾路è¡é', value: ['310106021', '临汾路è¡é'] }, |
| | | { label: 'è·æ±è¥¿è·¯è¡é', value: ['310106022', 'è·æ±è¥¿è·¯è¡é'] }, |
| | | { |
| | | label: '彿µ¦é', |
| | | value: ['310106101', '彿µ¦é'], |
| | | children: [ |
| | | { |
| | | label: '大èå', |
| | | value: ['31010610101', '大èå'] |
| | | } |
| | | ] |
| | | }, |
| | | { label: 'æ±å®è·¯è¡é', value: ['310106006', 'æ±å®è·¯è¡é'] }, |
| | | { label: 'ç³é¨äºè·¯è¡é', value: ['310106011', 'ç³é¨äºè·¯è¡é'] }, |
| | | { |
| | | label: 'å京西路è¡é', |
| | | value: ['310106012', 'å京西路è¡é'], |
| | | children: [ |
| | | { |
| | | label: 'X88', |
| | | value: ['31010601201', 'X88'] |
| | | } |
| | | ] |
| | | }, |
| | | { label: 'éå®å¯ºè¡é', value: ['310106013', 'éå®å¯ºè¡é'] }, |
| | | { |
| | | label: 'æ¹å®¶æ¸¡è¡é', |
| | | value: ['310106014', 'æ¹å®¶æ¸¡è¡é'], |
| | | children: [ |
| | | { |
| | | label: '889', |
| | | value: ['31010601401', '889'] |
| | | } |
| | | ] |
| | | }, |
| | | { label: '天ç®è¥¿è·¯è¡é', value: ['310106015', '天ç®è¥¿è·¯è¡é'] }, |
| | | { |
| | | label: 'åç«è¡é', |
| | | value: ['310106016', 'åç«è¡é'], |
| | | children: [ |
| | | { |
| | | label: '大æ¦å', |
| | | value: ['31010601601', '大æ¦å'] |
| | | } |
| | | ] |
| | | }, |
| | | { label: 'å®å±±è·¯è¡é', value: ['310106017', 'å®å±±è·¯è¡é'] }, |
| | | { label: 'å
±åæ°è·¯è¡é', value: ['310106018', 'å
±åæ°è·¯è¡é'] } |
| | | ] |
| | | }, |
| | | { |
| | | label: 'æ®éåº', |
| | | value: ['310107', 'æ®éåº'], |
| | | children: [ |
| | | { label: 'æ¹æ¨æ°æè¡é', value: ['310107005', 'æ¹æ¨æ°æè¡é'] }, |
| | | { label: 'ä¸éè¡é', value: ['310107021', 'ä¸éè¡é'] }, |
| | | { label: 'çå¦éè¡é', value: ['310107022', 'çå¦éè¡é'] }, |
| | | { label: 'é¿å¾é', value: ['310107102', 'é¿å¾é'] }, |
| | | { label: 'æ¡æµ¦é', value: ['310107103', 'æ¡æµ¦é'] }, |
| | | { label: 'ç³æ³è·¯è¡é', value: ['310107017', 'ç³æ³è·¯è¡é'] }, |
| | | { label: 'çæ³è·¯è¡é', value: ['310107016', 'çæ³è·¯è¡é'] }, |
| | | { label: 'é¿å¯¿è·¯è¡é', value: ['310107015', 'é¿å¯¿è·¯è¡é'] }, |
| | | { label: 'é¿é£æ°æè¡é', value: ['310107014', 'é¿é£æ°æè¡é'] }, |
| | | { label: 'å®å·è·¯è¡é', value: ['310107020', 'å®å·è·¯è¡é'] } |
| | | ] |
| | | }, |
| | | { |
| | | label: 'éµè¡åº', |
| | | value: ['310112', 'éµè¡åº'], |
| | | children: [ |
| | | { label: 'æ±å·è·¯è¡é', value: ['310112001', 'æ±å·è·¯è¡é'] }, |
| | | { label: 'å¤ç¾è¡é', value: ['310112006', 'å¤ç¾è¡é'] }, |
| | | { label: 'æ°è¹è¡é', value: ['310112008', 'æ°è¹è¡é'] }, |
| | | { label: '浦é¦è¡é', value: ['310112009', '浦é¦è¡é'] }, |
| | | { label: 'èåºé', value: ['310112101', 'èåºé'] }, |
| | | { label: 'ä¸å®é', value: ['310112102', 'ä¸å®é'] }, |
| | | { label: '颿¡¥é', value: ['310112103', '颿¡¥é'] }, |
| | | { label: 'åæ¼é', value: ['310112106', 'åæ¼é'] }, |
| | | { label: 'è¹æ¡¥é', value: ['310112107', 'è¹æ¡¥é'] }, |
| | | { label: 'æ¢
éé', value: ['310112108', 'æ¢
éé'] }, |
| | | { label: 'å´æ³¾é', value: ['310112110', 'å´æ³¾é'] }, |
| | | { label: '马桥é', value: ['310112112', '马桥é'] }, |
| | | { label: '浦æ±é', value: ['310112114', '浦æ±é'] }, |
| | | { label: 'èåºå·¥ä¸åº', value: ['310112501', 'èåºå·¥ä¸åº'] } |
| | | ] |
| | | }, |
| | | { |
| | | label: 'é¿å®åº', |
| | | value: ['310105', 'é¿å®åº'], |
| | | children: [ |
| | | { label: 'åé³è·¯è¡é', value: ['310105001', 'åé³è·¯è¡é'] }, |
| | | { label: 'æ±èè·¯è¡é', value: ['310105002', 'æ±èè·¯è¡é'] }, |
| | | { label: 'æ°åè·¯è¡é', value: ['310105004', 'æ°åè·¯è¡é'] }, |
| | | { label: 'å¨å®¶æ¡¥è¡é', value: ['310105005', 'å¨å®¶æ¡¥è¡é'] }, |
| | | { label: '天山路è¡é', value: ['310105006', '天山路è¡é'] }, |
| | | { label: 'ä»éæ°æè¡é', value: ['310105008', 'ä»éæ°æè¡é'] }, |
| | | { label: 'è¹æ¡¥è¡é', value: ['310105009', 'è¹æ¡¥è¡é'] }, |
| | | { label: 'ç¨å®¶æ¡¥è¡é', value: ['310105010', 'ç¨å®¶æ¡¥è¡é'] }, |
| | | { label: 'åæ°æ³¾è¡é', value: ['310105011', 'åæ°æ³¾è¡é'] }, |
| | | { label: 'æ°æ³¾é', value: ['310105102', 'æ°æ³¾é'] } |
| | | ] |
| | | }, |
| | | { |
| | | label: 'å®å±±åº', |
| | | value: ['310113', 'å®å±±åº'], |
| | | children: [] |
| | | }, |
| | | { |
| | | label: 'åå®åº', |
| | | value: ['310114', 'åå®åº'], |
| | | children: [] |
| | | }, |
| | | { |
| | | label: 'æµ¦ä¸æ°åº', |
| | | value: ['310115', 'æµ¦ä¸æ°åº'], |
| | | children: [] |
| | | } |
| | | ] |
| | | } |
| | | ] |
| | | } |
| | | ]; |
| | | } |
| | | |
| | | // æç
§éæ±çå®ä½ç²¾åº¦è¿åå¯¹åºæ°æ® |
| | | function _deleteByLevel(locations, level, step) { |
| | | if (step == level) { |
| | | locations.forEach((l) => { |
| | | if (l.children) { |
| | | l.children = undefined; |
| | | } |
| | | }); |
| | | return; |
| | | } else { |
| | | step++; |
| | | locations.forEach((l) => { |
| | | if (l.children) { |
| | | _deleteByLevel(l.children, level, step); |
| | | } |
| | | }); |
| | | } |
| | | } |
| | | |
| | | export { enumLocation }; |
¶Ô±ÈÐÂÎļþ |
| | |
| | | function responseLevelList() { |
| | | return [ |
| | | { |
| | | label: '彿¥', |
| | | value: 0 |
| | | }, |
| | | { |
| | | label: 'ä¸å¤©å
', |
| | | value: 1 |
| | | }, |
| | | { |
| | | label: 'ä¸å¨å
', |
| | | value: 2 |
| | | }, |
| | | { |
| | | label: '彿', |
| | | value: 3 |
| | | }, |
| | | ]; |
| | | } |
| | | |
| | | function responseLevelName(type) { |
| | | return responseLevelList().find((v) => v.value == type).label; |
| | | } |
| | | |
| | | export { responseLevelList, responseLevelName }; |
¶Ô±ÈÐÂÎļþ |
| | |
| | | function travelModeList() { |
| | | return [ |
| | | { |
| | | label: '驾车', |
| | | value: 0 |
| | | }, |
| | | { |
| | | label: 'å
Œ
±äº¤é', |
| | | value: 1 |
| | | }, |
| | | { |
| | | label: 'æ¥è¡', |
| | | value: 2 |
| | | }, |
| | | ]; |
| | | } |
| | | |
| | | function travelModeName(type) { |
| | | return travelModeList().find((v) => v.value == type).label; |
| | | } |
| | | |
| | | export { travelModeList, travelModeName }; |
| | |
| | | import { imgUrl } from '@/api/index'; |
| | | import { $clue } from '@/api/index'; |
| | | |
| | | function getClueQuestion(data) { |
| | | data.cqFilePath = data.cqFilePath.split(';').map((val) => { |
| | | return imgUrl + val; |
| | | return $clue.imgUrl + val; |
| | | }); |
| | | return data; |
| | | } |
| | |
| | | v-model:show="show" |
| | | :clueData="selectedClue" |
| | | @pushed="(e) => (selectedClue.cuploaded = e)" |
| | | @onClueTaskChange="handleClueTaskChange" |
| | | ></ClueReport> |
| | | </el-col> |
| | | </el-row> |
| | |
| | | show.value = true; |
| | | selectedClue.value = clue; |
| | | }; |
| | | |
| | | function handleClueTaskChange() { |
| | | selectedClue.value.taskCount = 1; |
| | | } |
| | | </script> |
| | | |
| | | <style scoped></style> |
| | |
| | | </div> |
| | | <el-scrollbar height="70vh" class="p-h-1"> |
| | | <ClueList :dataList="clueList" @itemSelected="selectClue"> |
| | | <!-- <template #extra> |
| | | <el-button size="small" type="primary" @click="getClues"> |
| | | åå¸ä»»å¡ |
| | | </el-button> |
| | | </template> --> |
| | | </ClueList> |
| | | </el-scrollbar> |
| | | <el-row justify="space-between" class="p-8"> |
| | |
| | | import clueApi from '@/api/clue/clueApi'; |
| | | import { onMapMounted } from '@/components/map/baseMap'; |
| | | import moment from 'moment'; |
| | | import { ref, onMounted } from 'vue'; |
| | | import { ref, onMounted, reactive } from 'vue'; |
| | | |
| | | const emits = defineEmits('itemSelected'); |
| | | |
| | |
| | | > |
| | | <div class="clue-item"> |
| | | <el-row justify="space-between"> |
| | | <el-col span="20"> |
| | | <el-col :span="18"> |
| | | <div class="flex gap-1"> |
| | | <div class="clue-num">{{ $nf(item.cid) }}</div> |
| | | <el-text class="fy-h1" truncated>{{ |
| | |
| | | }}</el-text> |
| | | </div> |
| | | </el-col> |
| | | <!-- <el-col :span="4"> |
| | | <el-col :span="6"> |
| | | <el-row justify="end"> |
| | | <slot name="extra"></slot> |
| | | <el-tag |
| | | :type="item.taskCount > 0 ? 'info' : 'danger'" |
| | | effect="plain" |
| | | > |
| | | {{ item.taskCount > 0 ? 'å·²åå¸ä»»å¡' : 'æªåå¸ä»»å¡' }} |
| | | </el-tag> |
| | | </el-row> |
| | | </el-col> --> |
| | | </el-col> |
| | | </el-row> |
| | | <el-space> |
| | | <el-row align="middle"> |
| | |
| | | </el-scrollbar> |
| | | </div> |
| | | </CloseButton> |
| | | <ClueTaskEdit |
| | | v-model="clueTaskDialog" |
| | | :clue-task="clueTask" |
| | | :clue-data="clueData" |
| | | :create="isCreateMode" |
| | | @on-submit="handelClueTaskEdit" |
| | | ></ClueTaskEdit> |
| | | </template> |
| | | |
| | | <script> |
| | | import ClueReportClue from './components/ClueReportClue.vue'; |
| | | import ClueReportConclusion from './components/ClueReportConclusion.vue'; |
| | | import ClueReportQuestion from './components/ClueReportQuestion.vue'; |
| | | import ClueTaskEdit from '@/views/overlay-clue/task/ClueTaskEdit.vue'; |
| | | |
| | | import { useMessageBoxTip } from '@/composables/messageBox'; |
| | | import clueApi from '@/api/clue/clueApi'; |
| | | import clueTaskApi from '@/api/clue/clueTaskApi'; |
| | | |
| | | export default { |
| | | components: { |
| | | ClueReportClue, |
| | | ClueReportConclusion, |
| | | ClueReportQuestion |
| | | ClueReportQuestion, |
| | | ClueTaskEdit |
| | | }, |
| | | props: { |
| | | clueData: { |
| | |
| | | }, |
| | | show: Boolean |
| | | }, |
| | | emits: ['update:show', 'pushed'], |
| | | emits: ['update:show', 'pushed', 'onClueTaskChange'], |
| | | data() { |
| | | return { |
| | | clueTask: undefined |
| | | clueTask: undefined, |
| | | clueTaskDialog: false, |
| | | isCreateMode: true |
| | | }; |
| | | }, |
| | | watch: { |
| | | clueData(nV, oV) { |
| | | if (nV && nV != oV) { |
| | | this.getClueTask(); |
| | | } |
| | | } |
| | | }, |
| | | methods: { |
| | | closeEdit() { |
| | |
| | | this.$emit('pushed', res); |
| | | }); |
| | | }, |
| | | publishTask() { |
| | | |
| | | getClueTask() { |
| | | clueTaskApi |
| | | .fetchClueTask({ clueId: this.clueData.cid }) |
| | | .then((res) => { |
| | | this.isCreateMode = res.data.length == 0; |
| | | if (res.data.length > 0) { |
| | | this.clueTask = res.data[0]; |
| | | } else { |
| | | this.clueTask = undefined; |
| | | } |
| | | }); |
| | | }, |
| | | publishTask() { |
| | | this.clueTaskDialog = true; |
| | | }, |
| | | handelClueTaskEdit() { |
| | | this.getClueTask(); |
| | | this.$emit('onClueTaskChange'); |
| | | } |
| | | } |
| | | }; |
| | |
| | | <template> |
| | | |
| | | </template> |
| | | <el-dialog |
| | | style="pointer-events: auto" |
| | | :model-value="modelValue" |
| | | @update:modelValue="handleDialogChange" |
| | | width="50%" |
| | | :close-on-click-modal="false" |
| | | :close-on-press-escape="false" |
| | | destroy-on-close |
| | | > |
| | | <template #header> |
| | | <span> {{ create ? 'åå¸çº¿ç´¢ä»»å¡' : 'æ´æ°çº¿ç´¢ä»»å¡' }}</span> |
| | | </template> |
| | | <el-form |
| | | label-width="120px" |
| | | label-position="right" |
| | | :rules="rules" |
| | | :model="formObj" |
| | | ref="formRef" |
| | | > |
| | | <el-form-item label="线索ç¼å·" prop="clueId"> |
| | | <el-input |
| | | v-model="formObj.clueId" |
| | | placeholder="请è¾å
¥çº¿ç´¢ç¼å·" |
| | | class="w-200" |
| | | :disabled="true" |
| | | ></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="任塿¶é´" prop="taskTime"> |
| | | <el-date-picker |
| | | v-model="formObj.taskTime" |
| | | type="date" |
| | | placeholder="éæ©æ¥æ" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="åºå¿" prop="_location"> |
| | | <OptionLocation |
| | | :level="3" |
| | | :initValue="false" |
| | | :checkStrictly="false" |
| | | :allOption="false" |
| | | v-model="formObj._location" |
| | | ></OptionLocation> |
| | | </el-form-item> |
| | | <el-form-item label="ååºçº§å«" prop="responseLevel"> |
| | | <OptionResponseLevel |
| | | v-model="formObj.responseLevel" |
| | | ></OptionResponseLevel> |
| | | </el-form-item> |
| | | <el-form-item label="åºè¡æ¹å¼" prop="travelMode"> |
| | | <OptionTravelMode |
| | | v-model="formObj.travelMode" |
| | | ></OptionTravelMode> |
| | | </el-form-item> |
| | | <el-form-item label="æ 人æº" prop="hasUav"> |
| | | <el-switch |
| | | v-model="formObj.hasUav" |
| | | inline-prompt |
| | | active-text="æ" |
| | | inactive-text="æ " |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="æ§è¡äºº" prop="executorIds"> |
| | | <OptionExecutors |
| | | v-model="formObj.executorIds" |
| | | ></OptionExecutors> |
| | | </el-form-item> |
| | | </el-form> |
| | | <template #footer> |
| | | <el-button @click="onCancel">åæ¶</el-button> |
| | | <el-button |
| | | :disabled="!edit" |
| | | type="primary" |
| | | :loading="loading" |
| | | @click="onSubmit" |
| | | >ç¡®å®</el-button |
| | | > |
| | | </template> |
| | | </el-dialog> |
| | | </template> |
| | | <script setup> |
| | | import { ref, reactive, watch, onMounted } from 'vue'; |
| | | import { useFormConfirm } from '@/composables/formConfirm'; |
| | | import clueTaskApi from '@/api/clue/clueTaskApi'; |
| | | |
| | | const props = defineProps({ |
| | | modelValue: Boolean, |
| | | clueData: { |
| | | type: Object, |
| | | default: () => { |
| | | return {}; |
| | | } |
| | | }, |
| | | clueTask: Object, |
| | | create: { |
| | | type: Boolean, |
| | | default: true |
| | | } |
| | | }); |
| | | |
| | | const emits = defineEmits(['update:modelValue', 'onSubmit']); |
| | | |
| | | function handleDialogChange(value) { |
| | | emits('update:modelValue', value); |
| | | } |
| | | |
| | | const { formObj, formRef, edit, onSubmit, onCancel, clear } = |
| | | useFormConfirm({ |
| | | submit: { |
| | | do: submit |
| | | }, |
| | | cancel: { |
| | | do: cancel |
| | | } |
| | | }); |
| | | const loading = ref(false); |
| | | // è¡¨åæ£æ¥è§å |
| | | const rules = reactive({ |
| | | clueId: [ |
| | | { |
| | | required: true, |
| | | message: '线索ç¼å·ä¸è½ä¸ºç©º', |
| | | trigger: 'blur' |
| | | } |
| | | ], |
| | | taskTime: [ |
| | | { |
| | | required: true, |
| | | message: '线索æ¶é´ä¸è½ä¸ºç©º', |
| | | trigger: 'change' |
| | | } |
| | | ], |
| | | _location: [ |
| | | { |
| | | required: true, |
| | | message: 'åºå¿ä¸è½ä¸ºç©º', |
| | | trigger: 'change' |
| | | } |
| | | ], |
| | | responseLevel: [ |
| | | { |
| | | required: true, |
| | | message: 'ååºçº§å«ä¸è½ä¸ºç©º', |
| | | trigger: 'change' |
| | | } |
| | | ], |
| | | executorIds: [ |
| | | { |
| | | required: true, |
| | | message: 'æ§è¡äººä¸è½ä¸ºç©º', |
| | | trigger: 'change' |
| | | } |
| | | ] |
| | | }); |
| | | |
| | | function submit() { |
| | | const param = getParams(); |
| | | return props.create ? createClueTask(param) : updateClueTask(param); |
| | | } |
| | | |
| | | function cancel() { |
| | | emits('update:modelValue', false); |
| | | } |
| | | |
| | | function createClueTask(param) { |
| | | return clueTaskApi |
| | | .createClueTask(param) |
| | | .then(() => { |
| | | emits('update:modelValue', false); |
| | | emits('onSubmit'); |
| | | // clear(); |
| | | }) |
| | | .finally(() => { |
| | | loading.value = false; |
| | | }); |
| | | } |
| | | |
| | | function updateClueTask(param) { |
| | | return clueTaskApi |
| | | .updateClueTask(param) |
| | | .then(() => { |
| | | emits('update:modelValue', false); |
| | | emits('onSubmit'); |
| | | // clear(); |
| | | }) |
| | | .finally(() => { |
| | | loading.value = false; |
| | | }); |
| | | } |
| | | |
| | | function getParams() { |
| | | return { |
| | | guid: formObj.value.guid, |
| | | clueId: formObj.value.clueId, |
| | | taskTime: formObj.value.taskTime, |
| | | provinceCode: formObj.value._location.pCode, |
| | | provinceName: formObj.value._location.pName, |
| | | cityCode: formObj.value._location.cCode, |
| | | cityName: formObj.value._location.cName, |
| | | districtCode: formObj.value._location.dCode, |
| | | districtName: formObj.value._location.dName, |
| | | townCode: formObj.value._location.tCode, |
| | | townName: formObj.value._location.tName, |
| | | responseLevel: formObj.value.responseLevel, |
| | | travelMode: formObj.value.travelMode, |
| | | hasUav: formObj.value.hasUav, |
| | | executorIds: formObj.value.executorIds.join(';') |
| | | }; |
| | | } |
| | | |
| | | // watch( |
| | | // () => props.clueData, |
| | | // (nV, oV) => { |
| | | // if (nV && nV != oV) { |
| | | // formObj.value.clueId = nV.cid; |
| | | // } |
| | | // } |
| | | // ); |
| | | |
| | | // watch( |
| | | // () => props.clueTask, |
| | | // (nV, oV) => { |
| | | // if (nV && nV != oV) { |
| | | // formObj.value.guid = nV.guid; |
| | | // formObj.value.clueId = nV.clueId; |
| | | // formObj.value.taskTime = nV.taskTime; |
| | | // formObj.value._location = { |
| | | // pCode: nV.provinceCode, |
| | | // pName: nV.provinceName, |
| | | // cCode: nV.cityCode, |
| | | // cName: nV.cityName, |
| | | // dCode: nV.districtCode, |
| | | // dName: nV.districtName, |
| | | // tCode: nV.townCode, |
| | | // tName: nV.townName |
| | | // }; |
| | | // formObj.value.responseLevel = nV.responseLevel; |
| | | // formObj.value.travelMode = nV.travelMode; |
| | | // formObj.value.hasUav = nV.hasUav; |
| | | // formObj.value.executorIds = nV.executorIds.split(';'); |
| | | // } |
| | | // } |
| | | // ); |
| | | |
| | | watch( |
| | | () => [props.modelValue, props.clueData, props.clueTask], |
| | | (nV, oV) => { |
| | | const [m, d, t] = nV; |
| | | if (m) { |
| | | formObj.value = { |
| | | taskTime: new Date(), |
| | | _location: { |
| | | pCode: '31', |
| | | pName: '䏿µ·å¸', |
| | | cCode: '3100', |
| | | cName: '䏿µ·å¸', |
| | | dCode: '310106', |
| | | dName: 'éå®åº', |
| | | tCode: undefined, |
| | | tName: undefined |
| | | } |
| | | }; |
| | | if (d) { |
| | | formObj.value.clueId = d.cid; |
| | | } |
| | | if (t) { |
| | | formObj.value.guid = t.guid; |
| | | formObj.value.clueId = t.clueId; |
| | | formObj.value.taskTime = t.taskTime; |
| | | formObj.value._location = { |
| | | pCode: t.provinceCode, |
| | | pName: t.provinceName, |
| | | cCode: t.cityCode, |
| | | cName: t.cityName, |
| | | dCode: t.districtCode, |
| | | dName: t.districtName, |
| | | tCode: t.townCode, |
| | | tName: t.townName |
| | | }; |
| | | formObj.value.responseLevel = t.responseLevel; |
| | | formObj.value.travelMode = t.travelMode; |
| | | formObj.value.hasUav = t.hasUav; |
| | | formObj.value.executorIds = t.executorIds.split(';'); |
| | | } |
| | | } |
| | | } |
| | | ); |
| | | </script> |