Commit 72de60dc82cf3ad4391b93dae5dbb3aadf2b01f4
1 parent
26fd2f03
优化报修完成
Showing
33 changed files
with
1109 additions
and
327 deletions
src/api/role/roleApi.js
| ... | ... | @@ -4,7 +4,7 @@ import request from '@/utils/request' |
| 4 | 4 | export function savePrivilegeGroup(data) { |
| 5 | 5 | return new Promise((resolve, reject) => { |
| 6 | 6 | request({ |
| 7 | - url: '/privilegeGroup.savePrivilegeGroup', | |
| 7 | + url: '/save.privilegeGroup.info', | |
| 8 | 8 | method: 'post', |
| 9 | 9 | data |
| 10 | 10 | }).then(response => { |
| ... | ... | @@ -24,7 +24,7 @@ export function savePrivilegeGroup(data) { |
| 24 | 24 | export function updatePrivilegeGroup(data) { |
| 25 | 25 | return new Promise((resolve, reject) => { |
| 26 | 26 | request({ |
| 27 | - url: '/privilegeGroup.updatePrivilegeGroup', | |
| 27 | + url: '/edit.privilegeGroup.info', | |
| 28 | 28 | method: 'post', |
| 29 | 29 | data |
| 30 | 30 | }).then(response => { |
| ... | ... | @@ -44,7 +44,7 @@ export function updatePrivilegeGroup(data) { |
| 44 | 44 | export function deletePrivilegeGroup(data) { |
| 45 | 45 | return new Promise((resolve, reject) => { |
| 46 | 46 | request({ |
| 47 | - url: '/privilegeGroup.deletePrivilegeGroup', | |
| 47 | + url: '/delete.privilegeGroup.info', | |
| 48 | 48 | method: 'post', |
| 49 | 49 | data |
| 50 | 50 | }).then(response => { | ... | ... |
src/api/work/finishRepairApi.js
0 → 100644
| 1 | +import request from '@/utils/request' | |
| 2 | +import { getCommunityId } from '@/api/community/communityApi' | |
| 3 | + | |
| 4 | +// 获取资源类型列表 | |
| 5 | +export function listResourceStoreTypes(params) { | |
| 6 | + return new Promise((resolve, reject) => { | |
| 7 | + const communityId = getCommunityId() | |
| 8 | + request({ | |
| 9 | + url: '/resourceStoreType.listResourceStoreTypes', | |
| 10 | + method: 'get', | |
| 11 | + params: { | |
| 12 | + ...params, | |
| 13 | + communityId | |
| 14 | + } | |
| 15 | + }).then(response => { | |
| 16 | + const res = response.data | |
| 17 | + resolve(res) | |
| 18 | + }).catch(error => { | |
| 19 | + reject(error) | |
| 20 | + }) | |
| 21 | + }) | |
| 22 | +} | |
| 23 | + | |
| 24 | +// 获取用户仓库商品列表 | |
| 25 | +export function listUserStorehouses(params) { | |
| 26 | + return new Promise((resolve, reject) => { | |
| 27 | + const communityId = getCommunityId() | |
| 28 | + request({ | |
| 29 | + url: '/resourceStore.listUserStorehouses', | |
| 30 | + method: 'get', | |
| 31 | + params: { | |
| 32 | + ...params, | |
| 33 | + communityId | |
| 34 | + } | |
| 35 | + }).then(response => { | |
| 36 | + const res = response.data | |
| 37 | + resolve(res) | |
| 38 | + }).catch(error => { | |
| 39 | + reject(error) | |
| 40 | + }) | |
| 41 | + }) | |
| 42 | +} | |
| 43 | + | |
| 44 | +// 完成报修 | |
| 45 | +export function repairFinish(data) { | |
| 46 | + return new Promise((resolve, reject) => { | |
| 47 | + const communityId = getCommunityId() | |
| 48 | + request({ | |
| 49 | + url: '/ownerRepair.repairFinish', | |
| 50 | + method: 'post', | |
| 51 | + data: { | |
| 52 | + ...data, | |
| 53 | + communityId | |
| 54 | + } | |
| 55 | + }).then(response => { | |
| 56 | + const res = response.data | |
| 57 | + resolve(res) | |
| 58 | + }).catch(error => { | |
| 59 | + reject(error) | |
| 60 | + }) | |
| 61 | + }) | |
| 62 | +} | |
| 63 | + | |
| 64 | +// 上传文件 | |
| 65 | +export function uploadFile(data) { | |
| 66 | + return new Promise((resolve, reject) => { | |
| 67 | + const communityId = getCommunityId() | |
| 68 | + const formData = new FormData() | |
| 69 | + formData.append('uploadFile', data.file) | |
| 70 | + formData.append('communityId', communityId) | |
| 71 | + | |
| 72 | + request({ | |
| 73 | + url: '/uploadFile', | |
| 74 | + method: 'post', | |
| 75 | + data: formData, | |
| 76 | + headers: { | |
| 77 | + 'Content-Type': 'multipart/form-data' | |
| 78 | + } | |
| 79 | + }).then(response => { | |
| 80 | + const res = response.data | |
| 81 | + resolve(res) | |
| 82 | + }).catch(error => { | |
| 83 | + reject(error) | |
| 84 | + }) | |
| 85 | + }) | |
| 86 | +} | |
| 0 | 87 | \ No newline at end of file | ... | ... |
src/api/work/printRepairDetailApi.js
0 → 100644
| 1 | +import request from '@/utils/request' | |
| 2 | +import { getCommunityId } from '@/api/community/communityApi' | |
| 3 | + | |
| 4 | +// 获取报修单详情 | |
| 5 | +export function listOwnerRepairs(params) { | |
| 6 | + return new Promise((resolve, reject) => { | |
| 7 | + request({ | |
| 8 | + url: '/ownerRepair.listOwnerRepairs', | |
| 9 | + method: 'get', | |
| 10 | + params: { | |
| 11 | + ...params, | |
| 12 | + communityId: params.communityId || getCommunityId() | |
| 13 | + } | |
| 14 | + }).then(response => { | |
| 15 | + resolve(response.data) | |
| 16 | + }).catch(error => { | |
| 17 | + reject(error) | |
| 18 | + }) | |
| 19 | + }) | |
| 20 | +} | |
| 21 | + | |
| 22 | +// 获取维修人员处理轨迹 | |
| 23 | +export function listRepairStaffs(params) { | |
| 24 | + return new Promise((resolve, reject) => { | |
| 25 | + request({ | |
| 26 | + url: '/ownerRepair.listRepairStaffs', | |
| 27 | + method: 'get', | |
| 28 | + params: { | |
| 29 | + ...params, | |
| 30 | + communityId: params.communityId || getCommunityId() | |
| 31 | + } | |
| 32 | + }).then(response => { | |
| 33 | + resolve(response.data) | |
| 34 | + }).catch(error => { | |
| 35 | + reject(error) | |
| 36 | + }) | |
| 37 | + }) | |
| 38 | +} | |
| 0 | 39 | \ No newline at end of file | ... | ... |
src/api/work/repairPoolManageApi.js
| ... | ... | @@ -38,7 +38,7 @@ export function listRepairPools(params) { |
| 38 | 38 | export function dispatchRepair(data) { |
| 39 | 39 | return new Promise((resolve, reject) => { |
| 40 | 40 | request({ |
| 41 | - url: '/ownerRepair.repairDispatch', | |
| 41 | + url: '/callComponent/ownerRepair.repairDispatch', | |
| 42 | 42 | method: 'post', |
| 43 | 43 | data: { |
| 44 | 44 | ...data, | ... | ... |
src/components/staff/SelectStaff.vue
src/components/work/AddRepairSetting.vue
| ... | ... | @@ -33,7 +33,8 @@ |
| 33 | 33 | <el-col :span="12"> |
| 34 | 34 | <el-form-item :label="$t('repairSetting.publicArea')" prop="publicArea"> |
| 35 | 35 | <el-select v-model="formData.publicArea" |
| 36 | - :placeholder="$t('repairSetting.required') + $t('repairSetting.publicAreaPlaceholder')" style="width:100%"> | |
| 36 | + :placeholder="$t('repairSetting.required') + $t('repairSetting.publicAreaPlaceholder')" | |
| 37 | + style="width:100%"> | |
| 37 | 38 | <el-option :label="$t('repairSetting.nonHouse')" value="T" /> |
| 38 | 39 | <el-option :label="$t('repairSetting.house')" value="F" /> |
| 39 | 40 | </el-select> |
| ... | ... | @@ -203,7 +204,7 @@ export default { |
| 203 | 204 | if (valid) { |
| 204 | 205 | try { |
| 205 | 206 | await saveRepairSetting(this.formData) |
| 206 | - this.$message.success(this.$t('repairSetting.addSuccess')) | |
| 207 | + this.$message.success(this.$t('common.submitSuccess')) | |
| 207 | 208 | this.$emit('success') |
| 208 | 209 | this.closeDialog() |
| 209 | 210 | } catch (error) { | ... | ... |
src/components/work/DeleteRepairSetting.vue
| 1 | 1 | <template> |
| 2 | - <el-dialog | |
| 3 | - :title="$t('repairSetting.confirmDeleteTitle')" | |
| 4 | - :visible.sync="visible" | |
| 5 | - width="30%" | |
| 6 | - center | |
| 7 | - > | |
| 2 | + <el-dialog :title="$t('repairSetting.confirmDeleteTitle')" :visible.sync="visible" width="30%" center> | |
| 8 | 3 | <div style="text-align: center"> |
| 9 | 4 | <p>{{ $t('repairSetting.confirmDeleteContent') }} [{{ currentRow.repairTypeName }}]?</p> |
| 10 | 5 | </div> |
| ... | ... | @@ -31,16 +26,16 @@ export default { |
| 31 | 26 | this.currentRow = { ...row } |
| 32 | 27 | this.visible = true |
| 33 | 28 | }, |
| 34 | - | |
| 29 | + | |
| 35 | 30 | closeDialog() { |
| 36 | 31 | this.visible = false |
| 37 | 32 | this.currentRow = {} |
| 38 | 33 | }, |
| 39 | - | |
| 34 | + | |
| 40 | 35 | async confirmDelete() { |
| 41 | 36 | try { |
| 42 | 37 | await deleteRepairSetting(this.currentRow.settingId) |
| 43 | - this.$message.success(this.$t('repairSetting.deleteSuccess')) | |
| 38 | + this.$message.success(this.$t('common.submitSuccess')) | |
| 44 | 39 | this.$emit('success') |
| 45 | 40 | this.closeDialog() |
| 46 | 41 | } catch (error) { | ... | ... |
src/components/work/EditRepairSetting.vue
| 1 | 1 | <template> |
| 2 | - <el-dialog | |
| 3 | - :title="$t('repairSetting.editTitle')" | |
| 4 | - :visible.sync="visible" | |
| 5 | - width="50%" | |
| 6 | - @close="closeDialog" | |
| 7 | - > | |
| 2 | + <el-dialog :title="$t('repairSetting.editTitle')" :visible.sync="visible" width="50%" @close="closeDialog"> | |
| 8 | 3 | <el-form ref="form" :model="formData" :rules="rules" label-width="150px"> |
| 9 | 4 | <el-row> |
| 10 | 5 | <el-col :span="12"> |
| 11 | 6 | <el-form-item :label="$t('repairSetting.typeName')" prop="repairTypeName"> |
| 12 | - <el-input | |
| 13 | - v-model="formData.repairTypeName" | |
| 14 | - :placeholder="$t('repairSetting.repairTypeNamePlaceholder')" | |
| 15 | - /> | |
| 7 | + <el-input v-model="formData.repairTypeName" :placeholder="$t('repairSetting.repairTypeNamePlaceholder')" /> | |
| 16 | 8 | </el-form-item> |
| 17 | 9 | </el-col> |
| 18 | 10 | <el-col :span="12"> |
| 19 | 11 | <el-form-item :label="$t('repairSetting.settingType')" prop="repairSettingType"> |
| 20 | - <el-select | |
| 21 | - v-model="formData.repairSettingType" | |
| 12 | + <el-select v-model="formData.repairSettingType" | |
| 22 | 13 | :placeholder="$t('repairSetting.required') + $t('repairSetting.repairSettingTypePlaceholder')" |
| 23 | - style="width:100%" | |
| 24 | - > | |
| 14 | + style="width:100%"> | |
| 25 | 15 | <el-option :label="$t('repairSetting.cleaningOrder')" value="100" /> |
| 26 | 16 | <el-option :label="$t('repairSetting.repairOrder')" value="200" /> |
| 27 | 17 | </el-select> |
| 28 | 18 | </el-form-item> |
| 29 | 19 | </el-col> |
| 30 | 20 | </el-row> |
| 31 | - | |
| 21 | + | |
| 32 | 22 | <el-row> |
| 33 | 23 | <el-col :span="12"> |
| 34 | 24 | <el-form-item :label="$t('repairSetting.dispatchMethod')" prop="repairWay"> |
| 35 | - <el-select | |
| 36 | - v-model="formData.repairWay" | |
| 37 | - :placeholder="$t('repairSetting.required') + $t('repairSetting.repairWayPlaceholder')" | |
| 38 | - style="width:100%" | |
| 39 | - > | |
| 25 | + <el-select v-model="formData.repairWay" | |
| 26 | + :placeholder="$t('repairSetting.required') + $t('repairSetting.repairWayPlaceholder')" style="width:100%"> | |
| 40 | 27 | <el-option :label="$t('repairSetting.grabOrder')" value="100" /> |
| 41 | 28 | <el-option :label="$t('repairSetting.assign')" value="200" /> |
| 42 | 29 | <el-option :label="$t('repairSetting.polling')" value="300" /> |
| ... | ... | @@ -45,26 +32,21 @@ |
| 45 | 32 | </el-col> |
| 46 | 33 | <el-col :span="12"> |
| 47 | 34 | <el-form-item :label="$t('repairSetting.publicArea')" prop="publicArea"> |
| 48 | - <el-select | |
| 49 | - v-model="formData.publicArea" | |
| 35 | + <el-select v-model="formData.publicArea" | |
| 50 | 36 | :placeholder="$t('repairSetting.required') + $t('repairSetting.publicAreaPlaceholder')" |
| 51 | - style="width:100%" | |
| 52 | - > | |
| 37 | + style="width:100%"> | |
| 53 | 38 | <el-option :label="$t('repairSetting.nonHouse')" value="T" /> |
| 54 | 39 | <el-option :label="$t('repairSetting.house')" value="F" /> |
| 55 | 40 | </el-select> |
| 56 | 41 | </el-form-item> |
| 57 | 42 | </el-col> |
| 58 | 43 | </el-row> |
| 59 | - | |
| 44 | + | |
| 60 | 45 | <el-row> |
| 61 | 46 | <el-col :span="12"> |
| 62 | 47 | <el-form-item :label="$t('repairSetting.ownerDisplay')" prop="isShow"> |
| 63 | - <el-select | |
| 64 | - v-model="formData.isShow" | |
| 65 | - :placeholder="$t('repairSetting.ownerDisplayPlaceholder')" | |
| 66 | - style="width:100%" | |
| 67 | - > | |
| 48 | + <el-select v-model="formData.isShow" :placeholder="$t('repairSetting.ownerDisplayPlaceholder')" | |
| 49 | + style="width:100%"> | |
| 68 | 50 | <el-option :label="$t('repairSetting.yes')" value="Y" /> |
| 69 | 51 | <el-option :label="$t('repairSetting.no')" value="N" /> |
| 70 | 52 | </el-select> |
| ... | ... | @@ -72,11 +54,8 @@ |
| 72 | 54 | </el-col> |
| 73 | 55 | <el-col :span="12"> |
| 74 | 56 | <el-form-item :label="$t('repairSetting.notificationMethod')" prop="notifyWay"> |
| 75 | - <el-select | |
| 76 | - v-model="formData.notifyWay" | |
| 77 | - :placeholder="$t('repairSetting.notificationMethodPlaceholder')" | |
| 78 | - style="width:100%" | |
| 79 | - > | |
| 57 | + <el-select v-model="formData.notifyWay" :placeholder="$t('repairSetting.notificationMethodPlaceholder')" | |
| 58 | + style="width:100%"> | |
| 80 | 59 | <el-option :label="$t('repairSetting.sms')" value="SMS" /> |
| 81 | 60 | <el-option :label="$t('repairSetting.wechat')" value="WECHAT" /> |
| 82 | 61 | <el-option :label="$t('repairSetting.wechatWorkLicense')" value="WORK_LICENSE" /> |
| ... | ... | @@ -84,40 +63,32 @@ |
| 84 | 63 | </el-form-item> |
| 85 | 64 | </el-col> |
| 86 | 65 | </el-row> |
| 87 | - | |
| 66 | + | |
| 88 | 67 | <el-row> |
| 89 | 68 | <el-col :span="12"> |
| 90 | 69 | <el-form-item :label="$t('repairSetting.processingTime')" prop="doTime"> |
| 91 | - <el-input | |
| 92 | - v-model.number="formData.doTime" | |
| 93 | - type="number" | |
| 94 | - :placeholder="$t('repairSetting.required') + $t('repairSetting.processingTimePlaceholder')" | |
| 95 | - > | |
| 70 | + <el-input v-model.number="formData.doTime" type="number" | |
| 71 | + :placeholder="$t('repairSetting.required') + $t('repairSetting.processingTimePlaceholder')"> | |
| 96 | 72 | <template slot="append">{{ $t('repairSetting.processingTimeUnit') }}</template> |
| 97 | 73 | </el-input> |
| 98 | 74 | </el-form-item> |
| 99 | 75 | </el-col> |
| 100 | 76 | <el-col :span="12"> |
| 101 | 77 | <el-form-item :label="$t('repairSetting.timeoutWarning')" prop="warningTime"> |
| 102 | - <el-input | |
| 103 | - v-model.number="formData.warningTime" | |
| 104 | - type="number" | |
| 105 | - :placeholder="$t('repairSetting.required') + $t('repairSetting.timeoutWarningPlaceholder')" | |
| 106 | - > | |
| 78 | + <el-input v-model.number="formData.warningTime" type="number" | |
| 79 | + :placeholder="$t('repairSetting.required') + $t('repairSetting.timeoutWarningPlaceholder')"> | |
| 107 | 80 | <template slot="append">{{ $t('repairSetting.timeoutWarningUnit') }}</template> |
| 108 | 81 | </el-input> |
| 109 | 82 | </el-form-item> |
| 110 | 83 | </el-col> |
| 111 | 84 | </el-row> |
| 112 | - | |
| 85 | + | |
| 113 | 86 | <el-row> |
| 114 | 87 | <el-col :span="12"> |
| 115 | 88 | <el-form-item :label="$t('repairSetting.returnVisitSetting')" prop="returnVisitFlag"> |
| 116 | - <el-select | |
| 117 | - v-model="formData.returnVisitFlag" | |
| 89 | + <el-select v-model="formData.returnVisitFlag" | |
| 118 | 90 | :placeholder="$t('repairSetting.required') + $t('repairSetting.returnVisitFlagPlaceholder')" |
| 119 | - style="width:100%" | |
| 120 | - > | |
| 91 | + style="width:100%"> | |
| 121 | 92 | <el-option :label="$t('repairSetting.noFollowUp')" value="001" /> |
| 122 | 93 | <el-option :label="$t('repairSetting.followUpAfterEvaluation')" value="002" /> |
| 123 | 94 | <el-option :label="$t('repairSetting.followUp')" value="003" /> |
| ... | ... | @@ -125,21 +96,17 @@ |
| 125 | 96 | </el-form-item> |
| 126 | 97 | </el-col> |
| 127 | 98 | </el-row> |
| 128 | - | |
| 99 | + | |
| 129 | 100 | <el-row> |
| 130 | 101 | <el-col :span="24"> |
| 131 | 102 | <el-form-item :label="$t('repairSetting.explanation')" prop="remark"> |
| 132 | - <el-input | |
| 133 | - v-model="formData.remark" | |
| 134 | - type="textarea" | |
| 135 | - :rows="3" | |
| 136 | - :placeholder="$t('repairSetting.remarkPlaceholder')" | |
| 137 | - /> | |
| 103 | + <el-input v-model="formData.remark" type="textarea" :rows="3" | |
| 104 | + :placeholder="$t('repairSetting.remarkPlaceholder')" /> | |
| 138 | 105 | </el-form-item> |
| 139 | 106 | </el-col> |
| 140 | 107 | </el-row> |
| 141 | 108 | </el-form> |
| 142 | - | |
| 109 | + | |
| 143 | 110 | <div slot="footer" class="dialog-footer"> |
| 144 | 111 | <el-button @click="closeDialog">{{ $t('repairSetting.cancel') }}</el-button> |
| 145 | 112 | <el-button type="primary" @click="submitForm">{{ $t('repairSetting.save') }}</el-button> |
| ... | ... | @@ -213,18 +180,18 @@ export default { |
| 213 | 180 | this.formData = { ...row } |
| 214 | 181 | this.visible = true |
| 215 | 182 | }, |
| 216 | - | |
| 183 | + | |
| 217 | 184 | closeDialog() { |
| 218 | 185 | this.visible = false |
| 219 | 186 | this.$refs.form.resetFields() |
| 220 | 187 | }, |
| 221 | - | |
| 188 | + | |
| 222 | 189 | submitForm() { |
| 223 | 190 | this.$refs.form.validate(async valid => { |
| 224 | 191 | if (valid) { |
| 225 | 192 | try { |
| 226 | 193 | await updateRepairSetting(this.formData) |
| 227 | - this.$message.success(this.$t('repairSetting.updateSuccess')) | |
| 194 | + this.$message.success(this.$t('common.submitSuccess')) | |
| 228 | 195 | this.$emit('success') |
| 229 | 196 | this.closeDialog() |
| 230 | 197 | } catch (error) { | ... | ... |
src/components/work/EditRepairTypeUser.vue
| 1 | 1 | <template> |
| 2 | - <el-dialog :visible="visible" :title="$t('editRepairTypeUser.title')" width="50%" @close="handleClose"> | |
| 2 | + <el-dialog :visible="visible" :title="$t('editRepairTypeUser.title')" width="40%" @close="handleClose"> | |
| 3 | 3 | <el-form ref="form" :model="form" label-width="120px"> |
| 4 | 4 | <el-form-item :label="$t('editRepairTypeUser.status')" prop="state" required> |
| 5 | 5 | <el-select v-model="form.state" style="width: 100%"> |
| 6 | - <el-option :value="9999" :label="$t('editRepairTypeUser.online')"></el-option> | |
| 7 | - <el-option :value="8888" :label="$t('editRepairTypeUser.offline')"></el-option> | |
| 6 | + <el-option value="9999" :label="$t('editRepairTypeUser.online')"></el-option> | |
| 7 | + <el-option value="8888" :label="$t('editRepairTypeUser.offline')"></el-option> | |
| 8 | 8 | </el-select> |
| 9 | 9 | </el-form-item> |
| 10 | 10 | <el-form-item :label="$t('editRepairTypeUser.description')" prop="remark"> | ... | ... |
src/components/work/StopRepair.vue
| 1 | 1 | <template> |
| 2 | - <el-dialog | |
| 3 | - :title="$t('repairDispatchManage.pauseRepair')" | |
| 4 | - :visible.sync="visible" | |
| 5 | - width="50%" | |
| 6 | - @close="resetForm" | |
| 7 | - > | |
| 2 | + <el-dialog :title="$t('repairDispatchManage.pause')" :visible.sync="visible" width="50%" @close="resetForm"> | |
| 8 | 3 | <el-form :model="form" ref="form" label-width="120px"> |
| 9 | - <el-form-item | |
| 10 | - :label="$t('repairDispatchManage.pauseReason')" | |
| 11 | - prop="remark" | |
| 12 | - :rules="[{ required: true, message: $t('repairDispatchManage.requiredPauseReason'), trigger: 'blur' }]" | |
| 13 | - > | |
| 14 | - <el-input | |
| 15 | - type="textarea" | |
| 16 | - :rows="4" | |
| 17 | - v-model="form.remark" | |
| 18 | - :placeholder="$t('repairDispatchManage.requiredPauseReason')" | |
| 19 | - /> | |
| 4 | + <el-form-item :label="$t('repairDispatchManage.pauseReason')" prop="remark" | |
| 5 | + :rules="[{ required: true, message: $t('repairDispatchManage.requiredPauseReason'), trigger: 'blur' }]"> | |
| 6 | + <el-input type="textarea" :rows="4" v-model="form.remark" | |
| 7 | + :placeholder="$t('repairDispatchManage.requiredPauseReason')" /> | |
| 20 | 8 | </el-form-item> |
| 21 | 9 | </el-form> |
| 22 | - | |
| 10 | + | |
| 23 | 11 | <div slot="footer" class="dialog-footer"> |
| 24 | 12 | <el-button @click="visible = false">{{ $t('common.cancel') }}</el-button> |
| 25 | 13 | <el-button type="primary" @click="submitForm">{{ $t('common.submit') }}</el-button> |
| ... | ... | @@ -55,13 +43,13 @@ export default { |
| 55 | 43 | async submitForm() { |
| 56 | 44 | this.$refs.form.validate(async valid => { |
| 57 | 45 | if (!valid) return |
| 58 | - | |
| 46 | + | |
| 59 | 47 | try { |
| 60 | 48 | const data = { |
| 61 | 49 | ...this.form, |
| 62 | 50 | communityId: getCommunityId() |
| 63 | 51 | } |
| 64 | - | |
| 52 | + | |
| 65 | 53 | await repairStop(data) |
| 66 | 54 | this.$emit('success') |
| 67 | 55 | this.visible = false | ... | ... |
src/components/work/addOwnerRepair.vue
| ... | ... | @@ -63,7 +63,7 @@ |
| 63 | 63 | import * as ownerRepairManageApi from '@/api/work/ownerRepairManageApi' |
| 64 | 64 | import { getCommunityName } from '@/api/community/communityApi' |
| 65 | 65 | import {getFloors, getUnits, queryRooms} from '@/api/room/roomApi' |
| 66 | -import {getDateYYYYMMDD} from '@/utils/dateUtil' | |
| 66 | +//import {getDateYYYYMMDD} from '@/utils/dateUtil' | |
| 67 | 67 | |
| 68 | 68 | export default { |
| 69 | 69 | name: 'AddOwnerRepair', |
| ... | ... | @@ -100,7 +100,7 @@ export default { |
| 100 | 100 | open() { |
| 101 | 101 | this.visible = true |
| 102 | 102 | this.resetForm() |
| 103 | - this.formData.appointmentTime =getDateYYYYMMDD() | |
| 103 | + // this.formData.appointmentTime =getDateYYYYMMDD() | |
| 104 | 104 | this.listRepairSettings('T') |
| 105 | 105 | }, |
| 106 | 106 | closeDialog() { | ... | ... |
src/components/work/chooseSingleResource.vue
| 1 | 1 | <template> |
| 2 | - <el-dialog | |
| 3 | - :title="$t('chooseSingleResource.title')" | |
| 4 | - :visible.sync="visible" | |
| 5 | - width="60%" | |
| 6 | - @close="closeDialog" | |
| 7 | - > | |
| 8 | - <el-form label-width="120px"> | |
| 2 | + <el-dialog :title="$t('chooseSingleResource.title')" :visible.sync="dialogVisible" width="60%" @close="handleClose"> | |
| 3 | + | |
| 4 | + <el-form :model="form" label-width="120px"> | |
| 9 | 5 | <el-form-item :label="$t('chooseSingleResource.goodsType')"> |
| 10 | - <el-select | |
| 11 | - v-model="form.rsId" | |
| 12 | - placeholder="请选择" | |
| 13 | - style="width:100%" | |
| 14 | - @change="listSonResourceStoreType" | |
| 15 | - > | |
| 16 | - <el-option | |
| 17 | - v-for="item in resourceStoreTypes" | |
| 18 | - :key="item.rstId" | |
| 19 | - :label="item.name" | |
| 20 | - :value="item.rstId" | |
| 21 | - /> | |
| 6 | + <el-select v-model="form.rsId" :placeholder="$t('chooseSingleResource.selectGoodsType')" style="width:100%" | |
| 7 | + @change="handleRsIdChange"> | |
| 8 | + <el-option v-for="item in resourceStoreTypes" :key="item.rstId" :label="item.name" :value="item.rstId"> | |
| 9 | + </el-option> | |
| 22 | 10 | </el-select> |
| 23 | 11 | </el-form-item> |
| 24 | 12 | |
| 25 | 13 | <template v-if="form.isCustom"> |
| 26 | 14 | <el-form-item :label="$t('chooseSingleResource.goodsName')"> |
| 27 | - <el-input | |
| 28 | - v-model="form.customGoodsName" | |
| 29 | - :placeholder="$t('chooseSingleResource.goodsNamePlaceholder')" | |
| 30 | - /> | |
| 15 | + <el-input v-model="form.customGoodsName" :placeholder="$t('chooseSingleResource.inputGoodsName')"> | |
| 16 | + </el-input> | |
| 17 | + </el-form-item> | |
| 18 | + | |
| 19 | + <el-form-item :label="$t('chooseSingleResource.customPrice')" v-if="form.maintenanceType === '1001'"> | |
| 20 | + <el-input-number v-model="form.price" :placeholder="$t('chooseSingleResource.inputPrice')" :min="0" | |
| 21 | + style="width:100%"> | |
| 22 | + </el-input-number> | |
| 31 | 23 | </el-form-item> |
| 32 | 24 | </template> |
| 33 | - | |
| 25 | + | |
| 34 | 26 | <template v-else> |
| 35 | - <el-form-item :label="$t('chooseSingleResource.secondaryCategory')"> | |
| 36 | - <el-select | |
| 37 | - v-model="form.rstId" | |
| 38 | - placeholder="请选择" | |
| 39 | - style="width:100%" | |
| 40 | - @change="choseGoods" | |
| 41 | - > | |
| 42 | - <el-option | |
| 43 | - v-for="item in sonResourceStoreTypes" | |
| 44 | - :key="item.rstId" | |
| 45 | - :label="item.name" | |
| 46 | - :value="item.rstId" | |
| 47 | - /> | |
| 27 | + <el-form-item :label="$t('chooseSingleResource.subCategory')"> | |
| 28 | + <el-select v-model="form.rstId" :placeholder="$t('chooseSingleResource.selectSubCategory')" style="width:100%" | |
| 29 | + @change="handleRstIdChange"> | |
| 30 | + <el-option v-for="item in sonResourceStoreTypes" :key="item.rstId" :label="item.name" :value="item.rstId"> | |
| 31 | + </el-option> | |
| 48 | 32 | </el-select> |
| 49 | 33 | </el-form-item> |
| 50 | 34 | |
| 51 | - <el-form-item v-if="form.rstId" :label="$t('chooseSingleResource.goods')"> | |
| 52 | - <el-select | |
| 53 | - v-model="form.resId" | |
| 54 | - placeholder="请选择" | |
| 55 | - style="width:100%" | |
| 56 | - @change="chosePrice" | |
| 57 | - > | |
| 58 | - <el-option | |
| 59 | - v-for="item in resourceStores" | |
| 60 | - :key="item.resId" | |
| 61 | - :label="item.resName" | |
| 62 | - :value="item.resId" | |
| 63 | - /> | |
| 35 | + <el-form-item :label="$t('chooseSingleResource.goods')" v-if="form.rstId"> | |
| 36 | + <el-select v-model="form.resId" :placeholder="$t('chooseSingleResource.selectGoods')" style="width:100%" | |
| 37 | + @change="handleResIdChange"> | |
| 38 | + <el-option v-for="item in resourceStores" :key="item.resId" :label="item.resName" :value="item.resId"> | |
| 39 | + </el-option> | |
| 64 | 40 | </el-select> |
| 65 | 41 | </el-form-item> |
| 66 | - </template> | |
| 67 | 42 | |
| 68 | - <template v-if="form.resId || form.isCustom"> | |
| 69 | - <el-form-item :label="$t('chooseSingleResource.quantity')"> | |
| 70 | - <el-input-number | |
| 71 | - v-model="form.useNumber" | |
| 72 | - :min="1" | |
| 73 | - label="数量" | |
| 74 | - /> | |
| 75 | - </el-form-item> | |
| 43 | + <template v-if="form.resId"> | |
| 44 | + <el-form-item :label="$t('chooseSingleResource.goodsPrice')" | |
| 45 | + v-if="form.maintenanceType === '1001' && form.outLowPrice === form.outHighPrice"> | |
| 46 | + <el-input-number v-model="form.price" disabled style="width:100%"> | |
| 47 | + </el-input-number> | |
| 48 | + </el-form-item> | |
| 49 | + | |
| 50 | + <el-form-item :label="$t('chooseSingleResource.customPrice')" | |
| 51 | + v-if="form.maintenanceType === '1001' && form.outLowPrice !== form.outHighPrice"> | |
| 52 | + <el-input-number v-model="form.price" :min="form.outLowPrice" :max="form.outHighPrice" style="width:100%"> | |
| 53 | + </el-input-number> | |
| 54 | + <span>{{ $t('chooseSingleResource.priceRange') }} {{ form.outLowPrice }}-{{ form.outHighPrice }}</span> | |
| 55 | + </el-form-item> | |
| 56 | + | |
| 57 | + <el-form-item :label="$t('chooseSingleResource.spec')"> | |
| 58 | + <el-input v-model="form.selectedGoodsInfo.specName" disabled> | |
| 59 | + </el-input> | |
| 60 | + </el-form-item> | |
| 61 | + </template> | |
| 76 | 62 | </template> |
| 63 | + | |
| 64 | + <el-form-item :label="$t('chooseSingleResource.quantity')"> | |
| 65 | + <el-input-number v-model="form.useNumber" :min="1" @change="handleQuantityChange"> | |
| 66 | + </el-input-number> | |
| 67 | + </el-form-item> | |
| 77 | 68 | </el-form> |
| 78 | 69 | |
| 79 | - <div slot="footer" class="dialog-footer"> | |
| 80 | - <el-button @click="closeDialog">{{ $t('chooseSingleResource.cancel') }}</el-button> | |
| 81 | - <el-button type="primary" @click="confirmSelection">{{ $t('chooseSingleResource.confirm') }}</el-button> | |
| 82 | - </div> | |
| 70 | + <span slot="footer" class="dialog-footer"> | |
| 71 | + <el-button @click="dialogVisible = false">{{ $t('common.cancel') }}</el-button> | |
| 72 | + <el-button type="primary" @click="handleConfirm" :loading="loading"> | |
| 73 | + {{ $t('common.confirm') }} | |
| 74 | + </el-button> | |
| 75 | + </span> | |
| 83 | 76 | </el-dialog> |
| 84 | 77 | </template> |
| 85 | 78 | |
| 86 | 79 | <script> |
| 87 | -import { listResourceStoreTypes, listUserStorehouses } from '@/api/work/repairForceFinishManageApi' | |
| 80 | +//import { getDict } from '@/api/community/communityApi' | |
| 81 | +import { getCommunityId } from '@/api/community/communityApi' | |
| 82 | +import { listResourceStoreTypes, listUserStorehouses } from '@/api/work/finishRepairApi' | |
| 88 | 83 | |
| 89 | 84 | export default { |
| 90 | 85 | name: 'ChooseSingleResource', |
| 91 | - props: { | |
| 92 | - visible: { | |
| 93 | - type: Boolean, | |
| 94 | - default: false | |
| 95 | - }, | |
| 96 | - maintenanceType: { | |
| 97 | - type: String, | |
| 98 | - default: '' | |
| 99 | - }, | |
| 100 | - repairId: { | |
| 101 | - type: String, | |
| 102 | - default: '' | |
| 103 | - } | |
| 104 | - }, | |
| 105 | 86 | data() { |
| 106 | 87 | return { |
| 88 | + dialogVisible: false, | |
| 89 | + loading: false, | |
| 107 | 90 | form: { |
| 108 | 91 | maintenanceType: '', |
| 109 | 92 | resourceStoreTypes: [], |
| 110 | 93 | sonResourceStoreTypes: [], |
| 111 | - rstId: '', | |
| 112 | 94 | rsId: '', |
| 95 | + rstId: '', | |
| 113 | 96 | resId: '', |
| 114 | 97 | repairId: '', |
| 115 | 98 | selectedGoodsInfo: {}, |
| ... | ... | @@ -121,124 +104,191 @@ export default { |
| 121 | 104 | outHighPrice: '', |
| 122 | 105 | useNumber: 1, |
| 123 | 106 | sign: '' |
| 124 | - } | |
| 125 | - } | |
| 126 | - }, | |
| 127 | - watch: { | |
| 128 | - maintenanceType(newVal) { | |
| 129 | - this.form.maintenanceType = newVal | |
| 130 | - }, | |
| 131 | - repairId(newVal) { | |
| 132 | - this.form.repairId = newVal | |
| 107 | + }, | |
| 108 | + resourceStoreTypes: [], | |
| 109 | + sonResourceStoreTypes: [], | |
| 110 | + resourceStores: [], | |
| 111 | + communityId: '' | |
| 133 | 112 | } |
| 134 | 113 | }, |
| 135 | - mounted() { | |
| 136 | - this.listResourceStoreType() | |
| 137 | - }, | |
| 138 | 114 | methods: { |
| 139 | - open(param) { | |
| 140 | - this.form = { | |
| 141 | - ...this.form, | |
| 142 | - maintenanceType: param.maintenanceType, | |
| 143 | - repairId: param.repairId || '', | |
| 144 | - sign: param.sign || '' | |
| 115 | + open(params) { | |
| 116 | + this.resetForm() | |
| 117 | + this.communityId = getCommunityId() | |
| 118 | + this.form.maintenanceType = params.maintenanceType | |
| 119 | + if (params.sign) { | |
| 120 | + this.form.sign = params.sign | |
| 145 | 121 | } |
| 146 | - this.listResourceStoreType() | |
| 147 | - }, | |
| 148 | - closeDialog() { | |
| 149 | - this.$emit('update:visible', false) | |
| 122 | + if (params.repairId) { | |
| 123 | + this.form.repairId = params.repairId | |
| 124 | + } | |
| 125 | + this.dialogVisible = true | |
| 126 | + this.loadResourceStoreTypes() | |
| 150 | 127 | }, |
| 151 | - async listResourceStoreType() { | |
| 128 | + async loadResourceStoreTypes() { | |
| 152 | 129 | try { |
| 153 | - const data = await listResourceStoreTypes('0') | |
| 154 | - this.form.resourceStoreTypes = [...data, { rstId: 'custom', name: '自定义' }] | |
| 130 | + const params = { | |
| 131 | + page: 1, | |
| 132 | + row: 100, | |
| 133 | + communityId: this.communityId, | |
| 134 | + parentId: '0', | |
| 135 | + giveType: 1 | |
| 136 | + } | |
| 137 | + const { data } = await listResourceStoreTypes(params) | |
| 138 | + this.resourceStoreTypes = data | |
| 139 | + // 添加自定义选项 | |
| 140 | + this.resourceStoreTypes.push({ | |
| 141 | + rstId: 'custom', | |
| 142 | + name: this.$t('chooseSingleResource.custom') | |
| 143 | + }) | |
| 155 | 144 | } catch (error) { |
| 156 | - console.error('获取资源类型失败:', error) | |
| 157 | - this.$message.error('获取资源类型失败') | |
| 145 | + console.error('加载商品类型失败:', error) | |
| 158 | 146 | } |
| 159 | 147 | }, |
| 160 | - async listSonResourceStoreType() { | |
| 161 | - if (this.form.rsId === 'custom') { | |
| 148 | + async handleRsIdChange(val) { | |
| 149 | + this.form.rstId = '' | |
| 150 | + this.sonResourceStoreTypes = [] | |
| 151 | + this.form.resId = '' | |
| 152 | + this.resourceStores = [] | |
| 153 | + | |
| 154 | + if (val === 'custom') { | |
| 162 | 155 | this.form.isCustom = true |
| 163 | 156 | return |
| 164 | 157 | } |
| 165 | - | |
| 158 | + | |
| 166 | 159 | this.form.isCustom = false |
| 167 | 160 | try { |
| 168 | - const data = await listResourceStoreTypes(this.form.rsId) | |
| 169 | - this.form.sonResourceStoreTypes = data | |
| 161 | + const params = { | |
| 162 | + page: 1, | |
| 163 | + row: 100, | |
| 164 | + parentId: val, | |
| 165 | + communityId: this.communityId | |
| 166 | + } | |
| 167 | + const { data } = await listResourceStoreTypes(params) | |
| 168 | + this.sonResourceStoreTypes = data | |
| 170 | 169 | } catch (error) { |
| 171 | - console.error('获取子资源类型失败:', error) | |
| 172 | - this.$message.error('获取子资源类型失败') | |
| 170 | + console.error('加载二级分类失败:', error) | |
| 173 | 171 | } |
| 174 | 172 | }, |
| 175 | - async choseGoods() { | |
| 176 | - if (!this.form.rstId) return | |
| 177 | - | |
| 173 | + async handleRstIdChange(val) { | |
| 174 | + this.form.resId = '' | |
| 175 | + this.resourceStores = [] | |
| 176 | + | |
| 178 | 177 | try { |
| 179 | 178 | const params = { |
| 179 | + page: 1, | |
| 180 | + row: 100, | |
| 180 | 181 | repairId: this.form.repairId, |
| 181 | - rstId: this.form.rstId, | |
| 182 | - sign: this.form.sign | |
| 182 | + rstId: val, | |
| 183 | + resId: this.form.resId, | |
| 184 | + communityId: this.communityId, | |
| 185 | + chooseType: "repair", | |
| 186 | + flag: 1, | |
| 187 | + sign: this.form.sign, | |
| 188 | + giveType: 1 | |
| 183 | 189 | } |
| 184 | - const data = await listUserStorehouses(params) | |
| 185 | - this.form.resourceStores = data | |
| 190 | + const { data } = await listUserStorehouses(params) | |
| 191 | + this.resourceStores = data | |
| 186 | 192 | } catch (error) { |
| 187 | - console.error('获取商品失败:', error) | |
| 188 | - this.$message.error('获取商品失败') | |
| 193 | + console.error('加载商品失败:', error) | |
| 189 | 194 | } |
| 190 | 195 | }, |
| 191 | - chosePrice() { | |
| 192 | - const selected = this.form.resourceStores.find(item => item.resId === this.form.resId) | |
| 193 | - if (selected) { | |
| 194 | - this.form.selectedGoodsInfo = selected | |
| 195 | - if (selected.outLowPrice === selected.outHighPrice) { | |
| 196 | - this.form.price = selected.outLowPrice | |
| 197 | - } else { | |
| 198 | - this.form.price = '' | |
| 196 | + handleResIdChange(val) { | |
| 197 | + this.resourceStores.forEach(item => { | |
| 198 | + if (item.resId === val) { | |
| 199 | + this.form.selectedGoodsInfo = item | |
| 200 | + if (item.outLowPrice === item.outHighPrice) { | |
| 201 | + this.form.price = item.outLowPrice | |
| 202 | + } else { | |
| 203 | + this.form.price = '' | |
| 204 | + } | |
| 205 | + this.form.outLowPrice = item.outLowPrice | |
| 206 | + this.form.outHighPrice = item.outHighPrice | |
| 199 | 207 | } |
| 200 | - this.form.outLowPrice = selected.outLowPrice | |
| 201 | - this.form.outHighPrice = selected.outHighPrice | |
| 208 | + }) | |
| 209 | + }, | |
| 210 | + handleQuantityChange(val) { | |
| 211 | + if (val < 1) { | |
| 212 | + this.form.useNumber = 1 | |
| 202 | 213 | } |
| 203 | 214 | }, |
| 204 | - confirmSelection() { | |
| 205 | - if (this.validateForm()) { | |
| 206 | - this.$emit('confirm', { | |
| 207 | - ...this.form.selectedGoodsInfo, | |
| 208 | - price: this.form.price, | |
| 209 | - useNumber: this.form.useNumber, | |
| 210 | - isCustom: this.form.isCustom, | |
| 211 | - customGoodsName: this.form.customGoodsName | |
| 212 | - }) | |
| 213 | - this.closeDialog() | |
| 215 | + handleClose() { | |
| 216 | + this.resetForm() | |
| 217 | + }, | |
| 218 | + resetForm() { | |
| 219 | + this.form = { | |
| 220 | + maintenanceType: '', | |
| 221 | + resourceStoreTypes: [], | |
| 222 | + sonResourceStoreTypes: [], | |
| 223 | + rsId: '', | |
| 224 | + rstId: '', | |
| 225 | + resId: '', | |
| 226 | + repairId: '', | |
| 227 | + selectedGoodsInfo: {}, | |
| 228 | + resourceStores: [], | |
| 229 | + isCustom: false, | |
| 230 | + customGoodsName: '', | |
| 231 | + price: '', | |
| 232 | + outLowPrice: '', | |
| 233 | + outHighPrice: '', | |
| 234 | + useNumber: 1, | |
| 235 | + sign: '' | |
| 214 | 236 | } |
| 215 | 237 | }, |
| 216 | 238 | validateForm() { |
| 217 | 239 | if (this.form.isCustom) { |
| 218 | 240 | if (!this.form.customGoodsName) { |
| 219 | - this.$message.warning('请填写商品名') | |
| 241 | + this.$message.error(this.$t('chooseSingleResource.validate.goodsNameRequired')) | |
| 220 | 242 | return false |
| 221 | 243 | } |
| 222 | 244 | if (this.form.maintenanceType === '1001' && !this.form.price) { |
| 223 | - this.$message.warning('请填写价格') | |
| 245 | + this.$message.error(this.$t('chooseSingleResource.validate.priceRequired')) | |
| 224 | 246 | return false |
| 225 | 247 | } |
| 226 | 248 | } else { |
| 227 | 249 | if (!this.form.rsId) { |
| 228 | - this.$message.warning('请选择商品类型') | |
| 250 | + this.$message.error(this.$t('chooseSingleResource.validate.goodsTypeRequired')) | |
| 229 | 251 | return false |
| 230 | 252 | } |
| 231 | 253 | if (!this.form.rstId) { |
| 232 | - this.$message.warning('请选择二级分类') | |
| 254 | + this.$message.error(this.$t('chooseSingleResource.validate.subCategoryRequired')) | |
| 233 | 255 | return false |
| 234 | 256 | } |
| 235 | 257 | if (!this.form.resId) { |
| 236 | - this.$message.warning('请选择商品') | |
| 258 | + this.$message.error(this.$t('chooseSingleResource.validate.goodsRequired')) | |
| 259 | + return false | |
| 260 | + } | |
| 261 | + if (this.form.maintenanceType === '1001' && !this.form.price) { | |
| 262 | + this.$message.error(this.$t('chooseSingleResource.validate.priceRequired')) | |
| 237 | 263 | return false |
| 238 | 264 | } |
| 239 | 265 | } |
| 240 | 266 | return true |
| 267 | + }, | |
| 268 | + handleConfirm() { | |
| 269 | + if (!this.validateForm()) return | |
| 270 | + | |
| 271 | + const selectedGoods = { | |
| 272 | + ...this.form.selectedGoodsInfo, | |
| 273 | + price: this.form.price, | |
| 274 | + useNumber: this.form.useNumber, | |
| 275 | + isCustom: this.form.isCustom, | |
| 276 | + customGoodsName: this.form.customGoodsName | |
| 277 | + } | |
| 278 | + | |
| 279 | + if (this.form.isCustom) { | |
| 280 | + selectedGoods.rstName = this.$t('chooseSingleResource.custom') | |
| 281 | + } | |
| 282 | + | |
| 283 | + this.$emit('choose-single-resource', selectedGoods) | |
| 284 | + this.dialogVisible = false | |
| 241 | 285 | } |
| 242 | 286 | } |
| 243 | 287 | } |
| 244 | -</script> | |
| 245 | 288 | \ No newline at end of file |
| 289 | +</script> | |
| 290 | + | |
| 291 | +<style scoped> | |
| 292 | +.el-input-number { | |
| 293 | + width: 100%; | |
| 294 | +} | |
| 295 | +</style> | |
| 246 | 296 | \ No newline at end of file | ... | ... |
src/components/work/deleteOwnerRepair.vue
src/components/work/dispatchRepair.vue
| ... | ... | @@ -15,7 +15,7 @@ |
| 15 | 15 | <el-form-item :label="$t('repairPoolManage.operationSuggestions')" prop="context" |
| 16 | 16 | :rules="[{ required: true, message: $t('repairPoolManage.operationSuggestions'), trigger: 'blur' }]"> |
| 17 | 17 | <el-input v-model="formData.context" type="textarea" :rows="4" |
| 18 | - :placeholder="$t('repairPoolManage.processingOpinionsPlaceholder')" /> | |
| 18 | + :placeholder="$t('repairPoolManage.operationSuggestions')" /> | |
| 19 | 19 | </el-form-item> |
| 20 | 20 | </el-form> |
| 21 | 21 | |
| ... | ... | @@ -30,6 +30,7 @@ |
| 30 | 30 | import { dispatchRepair } from '@/api/work/repairPoolManageApi' |
| 31 | 31 | import {listRepairTypeUsers} from '@/api/work/repairTypeUserApi' |
| 32 | 32 | import { getCommunityId } from '@/api/community/communityApi' |
| 33 | +import { getUserId } from '@/api/user/userApi' | |
| 33 | 34 | |
| 34 | 35 | export default { |
| 35 | 36 | name: 'DispatchRepair', |
| ... | ... | @@ -55,7 +56,8 @@ export default { |
| 55 | 56 | ...this.formData, |
| 56 | 57 | repairId: repair.repairId, |
| 57 | 58 | repairType: repair.repairType, |
| 58 | - action: repair.action || 'DISPATCH' | |
| 59 | + action: repair.action || 'DISPATCH', | |
| 60 | + currentUserId: getUserId() | |
| 59 | 61 | } |
| 60 | 62 | |
| 61 | 63 | if (repair.action === 'BACK') { | ... | ... |
src/components/work/forceFinishRepair.vue
| 1 | 1 | <template> |
| 2 | - <el-dialog :title="$t('forceFinishRepair.title')" :visible.sync="visible" width="60%" @close="closeDialog"> | |
| 2 | + <el-dialog :title="$t('forceFinishRepair.title')" :visible.sync="visible" width="40%" @close="closeDialog"> | |
| 3 | 3 | <el-form label-width="120px"> |
| 4 | 4 | <el-form-item v-if="form.repairObjType !== '004'" :label="$t('forceFinishRepair.useMaterial')"> |
| 5 | 5 | <el-select v-model="form.maintenanceType" placeholder="请选择" style="width:100%"> |
| ... | ... | @@ -64,7 +64,7 @@ |
| 64 | 64 | </template> |
| 65 | 65 | |
| 66 | 66 | <el-form-item :label="$t('forceFinishRepair.explanation')"> |
| 67 | - <el-input v-model="form.context" type="textarea" :placeholder="$t('forceFinishRepair.explanationPlaceholder')" | |
| 67 | + <el-input v-model="form.context" type="textarea" :placeholder="$t('forceFinishRepair.explanation')" | |
| 68 | 68 | :rows="4" /> |
| 69 | 69 | </el-form-item> |
| 70 | 70 | </el-form> |
| ... | ... | @@ -80,9 +80,9 @@ |
| 80 | 80 | import { |
| 81 | 81 | listResourceStoreTypes, |
| 82 | 82 | listUserStorehouses, |
| 83 | - repairForceFinish, | |
| 84 | - getDict | |
| 83 | + repairForceFinish | |
| 85 | 84 | } from '@/api/work/repairForceFinishManageApi' |
| 85 | +import { getDict } from '@/api/community/communityApi' | |
| 86 | 86 | |
| 87 | 87 | export default { |
| 88 | 88 | name: 'ForceFinishRepair', | ... | ... |
src/components/work/repairDetailPhotos.vue
| 1 | 1 | <template> |
| 2 | - <div class="margin-top"> | |
| 2 | + <div class="margin-top text-left"> | |
| 3 | 3 | <div v-if="photos.length > 0" class="row padding"> |
| 4 | 4 | <div class="text-title">{{ $t('repairDetail.orderPhotos') }}</div> |
| 5 | 5 | <div v-for="(item, index) in photos" :key="index" class="form-group margin-left"> | ... | ... |
src/components/work/visitOwnerRepair.vue
| 1 | 1 | <template> |
| 2 | - <el-dialog | |
| 3 | - :title="$t('repairReturnVisit.visitTitle')" | |
| 4 | - :visible.sync="visible" | |
| 5 | - width="600px" | |
| 6 | - @close="resetForm" | |
| 7 | - > | |
| 8 | - <el-form | |
| 9 | - ref="visitForm" | |
| 10 | - :model="formData" | |
| 11 | - :rules="rules" | |
| 12 | - label-width="100px" | |
| 13 | - label-position="right" | |
| 14 | - > | |
| 15 | - <el-form-item | |
| 16 | - :label="$t('repairReturnVisit.satisfaction')" | |
| 17 | - prop="visitType" | |
| 18 | - > | |
| 19 | - <el-select | |
| 20 | - v-model="formData.visitType" | |
| 21 | - :placeholder="$t('repairReturnVisit.satisfactionPlaceholder')" | |
| 22 | - style="width:100%" | |
| 23 | - > | |
| 24 | - <el-option | |
| 25 | - :label="$t('repairReturnVisit.satisfied')" | |
| 26 | - value="1001" | |
| 27 | - /> | |
| 28 | - <el-option | |
| 29 | - :label="$t('repairReturnVisit.unsatisfied')" | |
| 30 | - value="2002" | |
| 31 | - /> | |
| 2 | + <el-dialog :title="$t('repairReturnVisit.visitTitle')" :visible.sync="visible" width="600px" @close="resetForm"> | |
| 3 | + <el-form ref="visitForm" :model="formData" :rules="rules" label-width="100px" label-position="right"> | |
| 4 | + <el-form-item :label="$t('repairReturnVisit.satisfaction')" prop="visitType"> | |
| 5 | + <el-select v-model="formData.visitType" :placeholder="$t('repairReturnVisit.satisfaction')" | |
| 6 | + style="width:100%"> | |
| 7 | + <el-option :label="$t('repairReturnVisit.satisfied')" value="1001" /> | |
| 8 | + <el-option :label="$t('repairReturnVisit.unsatisfied')" value="2002" /> | |
| 32 | 9 | </el-select> |
| 33 | 10 | </el-form-item> |
| 34 | - | |
| 35 | - <el-form-item | |
| 36 | - :label="$t('repairReturnVisit.visitContent')" | |
| 37 | - prop="context" | |
| 38 | - > | |
| 39 | - <el-input | |
| 40 | - v-model="formData.context" | |
| 41 | - type="textarea" | |
| 42 | - :rows="4" | |
| 43 | - :placeholder="$t('repairReturnVisit.visitContentPlaceholder')" | |
| 44 | - /> | |
| 11 | + | |
| 12 | + <el-form-item :label="$t('repairReturnVisit.visitContent')" prop="context"> | |
| 13 | + <el-input v-model="formData.context" type="textarea" :rows="4" | |
| 14 | + :placeholder="$t('repairReturnVisit.visitContent')" /> | |
| 45 | 15 | </el-form-item> |
| 46 | 16 | </el-form> |
| 47 | - | |
| 17 | + | |
| 48 | 18 | <div slot="footer" class="dialog-footer"> |
| 49 | 19 | <el-button @click="visible = false"> |
| 50 | 20 | {{ $t('common.cancel') }} | ... | ... |
src/i18n/workI18n.js
| ... | ... | @@ -4,6 +4,8 @@ import { messages as itemReleaseManageMessages } from '../views/work/itemRelease |
| 4 | 4 | import { messages as addItemReleaseViewMessages } from '../views/work/addItemReleaseViewLang' |
| 5 | 5 | import { messages as editItemReleaseViewMessages } from '../views/work/editItemReleaseViewLang' |
| 6 | 6 | import { messages as itemReleaseDetailMessages } from '../views/work/itemReleaseDetailLang' |
| 7 | +import { messages as printRepairDetailMessages } from '../views/work/printRepairDetailLang' | |
| 8 | +import { messages as finishRepairMessages } from '../views/work/finishRepairLang' | |
| 7 | 9 | export const messages = { |
| 8 | 10 | zh: { |
| 9 | 11 | ...itemReleaseTypeManageMessages.zh, |
| ... | ... | @@ -11,6 +13,8 @@ export const messages = { |
| 11 | 13 | ...addItemReleaseViewMessages.zh, |
| 12 | 14 | ...editItemReleaseViewMessages.zh, |
| 13 | 15 | ...itemReleaseDetailMessages.zh, |
| 16 | + ...printRepairDetailMessages.zh, | |
| 17 | + ...finishRepairMessages.zh, | |
| 14 | 18 | }, |
| 15 | 19 | en: { |
| 16 | 20 | ...itemReleaseTypeManageMessages.en, |
| ... | ... | @@ -18,5 +22,7 @@ export const messages = { |
| 18 | 22 | ...addItemReleaseViewMessages.en, |
| 19 | 23 | ...editItemReleaseViewMessages.en, |
| 20 | 24 | ...itemReleaseDetailMessages.en, |
| 25 | + ...printRepairDetailMessages.en, | |
| 26 | + ...finishRepairMessages.en, | |
| 21 | 27 | } |
| 22 | 28 | } |
| 23 | 29 | \ No newline at end of file | ... | ... |
src/router/index.js
| ... | ... | @@ -704,6 +704,11 @@ const routes = [ |
| 704 | 704 | name:'/pages/property/printSmallAccountReceipt', |
| 705 | 705 | component: () => import('@/views/account/printSmallAccountReceiptList.vue') |
| 706 | 706 | }, |
| 707 | + { | |
| 708 | + path:'/pages/property/printRepairDetail', | |
| 709 | + name:'/pages/property/printRepairDetail', | |
| 710 | + component: () => import('@/views/work/printRepairDetailList.vue') | |
| 711 | + }, | |
| 707 | 712 | ] |
| 708 | 713 | |
| 709 | 714 | const router = new VueRouter({ | ... | ... |
src/router/workRouter.js
| ... | ... | @@ -24,4 +24,9 @@ export default [ |
| 24 | 24 | name: '/views/work/itemReleaseDetail', |
| 25 | 25 | component: () => import('@/views/work/itemReleaseDetailList.vue') |
| 26 | 26 | }, |
| 27 | + { | |
| 28 | + path:'/views/work/finishRepair', | |
| 29 | + name:'/views/work/finishRepair', | |
| 30 | + component: () => import('@/views/work/finishRepairList.vue') | |
| 31 | + }, | |
| 27 | 32 | ] |
| 28 | 33 | \ No newline at end of file | ... | ... |
src/views/role/roleList.vue
| ... | ... | @@ -12,9 +12,9 @@ |
| 12 | 12 | <el-button :type="activeTab === 'privilege' ? 'primary' : ''" @click="changeTab('privilege')"> |
| 13 | 13 | {{ $t('role.privilege') }} |
| 14 | 14 | </el-button> |
| 15 | - <el-button :type="activeTab === 'community' ? 'primary' : ''" @click="changeTab('community')"> | |
| 15 | + <!-- <el-button :type="activeTab === 'community' ? 'primary' : ''" @click="changeTab('community')"> | |
| 16 | 16 | {{ $t('role.community') }} |
| 17 | - </el-button> | |
| 17 | + </el-button> --> | |
| 18 | 18 | <el-button :type="activeTab === 'staff' ? 'primary' : ''" @click="changeTab('staff')"> |
| 19 | 19 | {{ $t('role.staff') }} |
| 20 | 20 | </el-button> |
| ... | ... | @@ -36,11 +36,11 @@ |
| 36 | 36 | </el-row> |
| 37 | 37 | </div> |
| 38 | 38 | </template> |
| 39 | - | |
| 39 | + | |
| 40 | 40 | <script> |
| 41 | 41 | import RoleDiv from '@/components/role/RoleDiv' |
| 42 | 42 | import PrivilegeTree from '@/components/role/PrivilegeTree' |
| 43 | -import RoleCommunity from '@/components/role/RoleCommunity' | |
| 43 | +// import RoleCommunity from '@/components/role/RoleCommunity' | |
| 44 | 44 | import RoleStaff from '@/components/role/RoleStaff' |
| 45 | 45 | |
| 46 | 46 | export default { |
| ... | ... | @@ -48,7 +48,7 @@ export default { |
| 48 | 48 | components: { |
| 49 | 49 | RoleDiv, |
| 50 | 50 | PrivilegeTree, |
| 51 | - RoleCommunity, | |
| 51 | + // RoleCommunity, | |
| 52 | 52 | RoleStaff |
| 53 | 53 | }, |
| 54 | 54 | data() { |
| ... | ... | @@ -70,7 +70,7 @@ export default { |
| 70 | 70 | } |
| 71 | 71 | } |
| 72 | 72 | </script> |
| 73 | - | |
| 73 | + | |
| 74 | 74 | <style lang="scss" scoped> |
| 75 | 75 | .role-container { |
| 76 | 76 | |
| ... | ... | @@ -113,9 +113,10 @@ export default { |
| 113 | 113 | .role-menu { |
| 114 | 114 | text-align: left; |
| 115 | 115 | margin-left: 15px; |
| 116 | + | |
| 116 | 117 | .el-button { |
| 117 | 118 | margin-top: 15px; |
| 118 | - | |
| 119 | + | |
| 119 | 120 | } |
| 120 | 121 | } |
| 121 | 122 | } | ... | ... |
src/views/work/finishRepairLang.js
0 → 100644
| 1 | +export const messages = { | |
| 2 | + en: { | |
| 3 | + finishRepair: { | |
| 4 | + title: 'Repair Completion', | |
| 5 | + materialUsage: 'Material Usage', | |
| 6 | + selectMaterialUsage: 'Please select material usage', | |
| 7 | + repairType: 'Repair Type', | |
| 8 | + selectRepairType: 'Please select repair type', | |
| 9 | + selectGoods: 'Select Goods', | |
| 10 | + usedGoods: 'Used Goods', | |
| 11 | + category: 'Category', | |
| 12 | + goods: 'Goods', | |
| 13 | + price: 'Price', | |
| 14 | + quantity: 'Quantity', | |
| 15 | + unit: 'Unit', | |
| 16 | + spec: 'Spec', | |
| 17 | + operation: 'Operation', | |
| 18 | + totalAmount: 'Total Amount', | |
| 19 | + paymentMethod: 'Payment Method', | |
| 20 | + selectPaymentMethod: 'Please select payment method', | |
| 21 | + suggestion: 'Suggestion', | |
| 22 | + inputSuggestion: 'Required, please input suggestion', | |
| 23 | + beforeRepairPhoto: 'Before Repair Photo', | |
| 24 | + afterRepairPhoto: 'After Repair Photo', | |
| 25 | + validate: { | |
| 26 | + repairIdRequired: 'Repair ID is required', | |
| 27 | + maintenanceTypeRequired: 'Maintenance type is required', | |
| 28 | + contextRequired: 'Suggestion is required', | |
| 29 | + beforePhotoRequired: 'Before repair photo is required', | |
| 30 | + afterPhotoRequired: 'After repair photo is required', | |
| 31 | + goodsRequired: 'Please select goods', | |
| 32 | + paymentMethodRequired: 'Payment method is required' | |
| 33 | + }, | |
| 34 | + submitSuccess: 'Submit successfully', | |
| 35 | + submitError: 'Submit failed' | |
| 36 | + }, | |
| 37 | + chooseSingleResource: { | |
| 38 | + title: 'Select Item', | |
| 39 | + goodsType: 'Goods Type', | |
| 40 | + selectGoodsType: 'Please select goods type', | |
| 41 | + goodsName: 'Goods Name', | |
| 42 | + inputGoodsName: 'Required, please input goods name', | |
| 43 | + subCategory: 'Sub Category', | |
| 44 | + selectSubCategory: 'Please select sub category', | |
| 45 | + goods: 'Goods', | |
| 46 | + selectGoods: 'Please select goods', | |
| 47 | + goodsPrice: 'Goods Price', | |
| 48 | + customPrice: 'Custom Price', | |
| 49 | + inputPrice: 'Required, please input price', | |
| 50 | + priceRange: 'Price Range', | |
| 51 | + spec: 'Spec', | |
| 52 | + quantity: 'Quantity', | |
| 53 | + custom: 'Custom', | |
| 54 | + validate: { | |
| 55 | + goodsTypeRequired: 'Goods type is required', | |
| 56 | + subCategoryRequired: 'Sub category is required', | |
| 57 | + goodsRequired: 'Goods is required', | |
| 58 | + priceRequired: 'Price is required', | |
| 59 | + goodsNameRequired: 'Goods name is required' | |
| 60 | + } | |
| 61 | + } | |
| 62 | + }, | |
| 63 | + zh: { | |
| 64 | + finishRepair: { | |
| 65 | + title: '报修结单', | |
| 66 | + materialUsage: '是否用料', | |
| 67 | + selectMaterialUsage: '请选择是否用料', | |
| 68 | + repairType: '维修类型', | |
| 69 | + selectRepairType: '请选择维修类型', | |
| 70 | + selectGoods: '选择商品', | |
| 71 | + usedGoods: '使用商品', | |
| 72 | + category: '分类', | |
| 73 | + goods: '商品', | |
| 74 | + price: '价格', | |
| 75 | + quantity: '数量', | |
| 76 | + unit: '单位', | |
| 77 | + spec: '规格', | |
| 78 | + operation: '操作', | |
| 79 | + totalAmount: '商品总金额', | |
| 80 | + paymentMethod: '支付方式', | |
| 81 | + selectPaymentMethod: '请选择支付方式', | |
| 82 | + suggestion: '处理意见', | |
| 83 | + inputSuggestion: '必填,请填写处理意见', | |
| 84 | + beforeRepairPhoto: '维修前图片', | |
| 85 | + afterRepairPhoto: '维修后图片', | |
| 86 | + validate: { | |
| 87 | + repairIdRequired: '报修单不能为空', | |
| 88 | + maintenanceTypeRequired: '维修类型不能为空', | |
| 89 | + contextRequired: '处理意见不能为空', | |
| 90 | + beforePhotoRequired: '维修前图片不能为空', | |
| 91 | + afterPhotoRequired: '维修后图片不能为空', | |
| 92 | + goodsRequired: '请选择商品', | |
| 93 | + paymentMethodRequired: '请选择支付方式' | |
| 94 | + }, | |
| 95 | + submitSuccess: '提交成功', | |
| 96 | + submitError: '提交失败' | |
| 97 | + }, | |
| 98 | + chooseSingleResource: { | |
| 99 | + title: '选择物品', | |
| 100 | + goodsType: '商品类型', | |
| 101 | + selectGoodsType: '请选择商品类型', | |
| 102 | + goodsName: '商品名', | |
| 103 | + inputGoodsName: '必填,请填写商品名', | |
| 104 | + subCategory: '二级分类', | |
| 105 | + selectSubCategory: '请选择二级类型', | |
| 106 | + goods: '商品', | |
| 107 | + selectGoods: '请选择商品', | |
| 108 | + goodsPrice: '商品价格', | |
| 109 | + customPrice: '自定义价格', | |
| 110 | + inputPrice: '必填,请填写自定义价格', | |
| 111 | + priceRange: '价格范围', | |
| 112 | + spec: '规格', | |
| 113 | + quantity: '商品数量', | |
| 114 | + custom: '自定义', | |
| 115 | + validate: { | |
| 116 | + goodsTypeRequired: '商品类型不能为空', | |
| 117 | + subCategoryRequired: '二级分类不能为空', | |
| 118 | + goodsRequired: '商品不能为空', | |
| 119 | + priceRequired: '商品价格不能为空', | |
| 120 | + goodsNameRequired: '商品名不能为空' | |
| 121 | + } | |
| 122 | + } | |
| 123 | + } | |
| 124 | +} | |
| 0 | 125 | \ No newline at end of file | ... | ... |
src/views/work/finishRepairList.vue
0 → 100644
| 1 | +<template> | |
| 2 | + <div class="finish-repair-container"> | |
| 3 | + <el-card class="box-card"> | |
| 4 | + <div slot="header" class="flex justify-between"> | |
| 5 | + <span>{{ $t('finishRepair.title') }}</span> | |
| 6 | + </div> | |
| 7 | + <el-row :gutter="20"> | |
| 8 | + <el-col :span="24"> | |
| 9 | + <div class="form-wrapper"> | |
| 10 | + <el-form label-width="120px"> | |
| 11 | + <el-form-item :label="$t('finishRepair.materialUsage')" v-if="finishRepairInfo.repairObjType != '004'"> | |
| 12 | + <el-select v-model="finishRepairInfo.maintenanceType" | |
| 13 | + :placeholder="$t('finishRepair.selectMaterialUsage')" style="width:100%"> | |
| 14 | + <template v-for="(item, index) in finishRepairInfo.maintenanceTypes"> | |
| 15 | + <el-option :key="index" :label="item.name" :value="item.statusCd" | |
| 16 | + v-if="item.statusCd != '1001' && item.statusCd != '1002'"> | |
| 17 | + </el-option> | |
| 18 | + </template> | |
| 19 | + </el-select> | |
| 20 | + </el-form-item> | |
| 21 | + | |
| 22 | + <el-form-item :label="$t('finishRepair.repairType')" v-if="finishRepairInfo.repairObjType == '004'"> | |
| 23 | + <el-select v-model="finishRepairInfo.maintenanceType" :placeholder="$t('finishRepair.selectRepairType')" | |
| 24 | + style="width:100%"> | |
| 25 | + <template v-for="(item, index) in finishRepairInfo.maintenanceTypes"> | |
| 26 | + <el-option :key="index" :label="item.name" :value="item.statusCd" | |
| 27 | + v-if="item.statusCd != '1003' && item.statusCd != '1004'"> | |
| 28 | + </el-option> | |
| 29 | + </template> | |
| 30 | + </el-select> | |
| 31 | + </el-form-item> | |
| 32 | + | |
| 33 | + <el-form-item | |
| 34 | + v-if="finishRepairInfo.maintenanceType == '1001' || finishRepairInfo.maintenanceType == '1003'"> | |
| 35 | + <el-button type="primary" @click="openChooseSingleResourceModel"> | |
| 36 | + <i class="el-icon-plus"></i>{{ $t('finishRepair.selectGoods') }} | |
| 37 | + </el-button> | |
| 38 | + </el-form-item> | |
| 39 | + | |
| 40 | + <!-- 商品列表展示 --> | |
| 41 | + <div | |
| 42 | + v-if="(finishRepairInfo.maintenanceType == '1001' || finishRepairInfo.maintenanceType == '1003') && finishRepairInfo.choosedGoodsList.length > 0"> | |
| 43 | + <el-form-item :label="$t('finishRepair.usedGoods')"> | |
| 44 | + <el-table :data="finishRepairInfo.choosedGoodsList" border> | |
| 45 | + <el-table-column prop="rstName" :label="$t('finishRepair.category')" width="120"></el-table-column> | |
| 46 | + <el-table-column prop="resName" :label="$t('finishRepair.goods')" width="120"></el-table-column> | |
| 47 | + <el-table-column prop="price" :label="$t('finishRepair.price')" width="120" | |
| 48 | + v-if="finishRepairInfo.maintenanceType == '1001'"> | |
| 49 | + <template slot-scope="scope"> | |
| 50 | + <el-input-number v-model="scope.row.price" | |
| 51 | + :disabled="!scope.row.isCustom && scope.row.outHighPrice == scope.row.outLowPrice" | |
| 52 | + @change="updateTotalPrice" :min="scope.row.outLowPrice" :max="scope.row.outHighPrice"> | |
| 53 | + </el-input-number> | |
| 54 | + <span v-if="!scope.row.isCustom && scope.row.outHighPrice != scope.row.outLowPrice"> | |
| 55 | + ({{ scope.row.outLowPrice }} - {{ scope.row.outHighPrice }}) | |
| 56 | + </span> | |
| 57 | + </template> | |
| 58 | + </el-table-column> | |
| 59 | + <el-table-column :label="$t('finishRepair.quantity')" width="150"> | |
| 60 | + <template slot-scope="scope"> | |
| 61 | + <el-input-number v-model="scope.row.useNumber" @change="updateTotalPrice" :min="1"> | |
| 62 | + </el-input-number> | |
| 63 | + </template> | |
| 64 | + </el-table-column> | |
| 65 | + <el-table-column prop="miniUnitCodeName" :label="$t('finishRepair.unit')" | |
| 66 | + width="80"></el-table-column> | |
| 67 | + <el-table-column prop="specName" :label="$t('finishRepair.spec')" width="80"></el-table-column> | |
| 68 | + <el-table-column :label="$t('finishRepair.operation')" width="120"> | |
| 69 | + <template slot-scope="scope"> | |
| 70 | + <el-button type="danger" size="mini" @click="removeChoosedGoodsItem(scope.$index)"> | |
| 71 | + <i class="el-icon-delete"></i>{{ $t('common.remove') }} | |
| 72 | + </el-button> | |
| 73 | + </template> | |
| 74 | + </el-table-column> | |
| 75 | + </el-table> | |
| 76 | + </el-form-item> | |
| 77 | + </div> | |
| 78 | + | |
| 79 | + <el-form-item :label="$t('finishRepair.totalAmount')" v-if="finishRepairInfo.maintenanceType == '1001'"> | |
| 80 | + <el-input v-model="finishRepairInfo.totalPrice" disabled></el-input> | |
| 81 | + </el-form-item> | |
| 82 | + | |
| 83 | + <el-form-item :label="$t('finishRepair.paymentMethod')" v-if="finishRepairInfo.maintenanceType == '1001'"> | |
| 84 | + <el-select v-model="finishRepairInfo.payType" :placeholder="$t('finishRepair.selectPaymentMethod')" | |
| 85 | + style="width:100%"> | |
| 86 | + <el-option v-for="(item, index) in finishRepairInfo.payTypes" :key="index" :label="item.name" | |
| 87 | + :value="item.statusCd"> | |
| 88 | + </el-option> | |
| 89 | + </el-select> | |
| 90 | + </el-form-item> | |
| 91 | + | |
| 92 | + <el-form-item :label="$t('finishRepair.suggestion')"> | |
| 93 | + <el-input type="textarea" :rows="4" :placeholder="$t('finishRepair.inputSuggestion')" | |
| 94 | + v-model="finishRepairInfo.context"> | |
| 95 | + </el-input> | |
| 96 | + </el-form-item> | |
| 97 | + | |
| 98 | + <el-form-item :label="$t('finishRepair.beforeRepairPhoto')"> | |
| 99 | + <upload-image-url ref="beforeRepairUpload" @notifyUploadCoverImage="handleBeforeRepairImage"> | |
| 100 | + </upload-image-url> | |
| 101 | + </el-form-item> | |
| 102 | + | |
| 103 | + <el-form-item :label="$t('finishRepair.afterRepairPhoto')"> | |
| 104 | + <upload-image-url ref="afterRepairUpload" @notifyUploadCoverImage="handleAfterRepairImage"> | |
| 105 | + </upload-image-url> | |
| 106 | + </el-form-item> | |
| 107 | + | |
| 108 | + <el-form-item> | |
| 109 | + <el-button type="primary" @click="submitFinishRepair">{{ $t('common.submit') }}</el-button> | |
| 110 | + <el-button @click="backToList">{{ $t('common.back') }}</el-button> | |
| 111 | + </el-form-item> | |
| 112 | + </el-form> | |
| 113 | + </div> | |
| 114 | + </el-col> | |
| 115 | + </el-row> | |
| 116 | + </el-card> | |
| 117 | + | |
| 118 | + <choose-single-resource ref="chooseSingleResource"></choose-single-resource> | |
| 119 | + </div> | |
| 120 | +</template> | |
| 121 | + | |
| 122 | +<script> | |
| 123 | +import { getDict } from '@/api/community/communityApi' | |
| 124 | +import { getCommunityId } from '@/api/community/communityApi' | |
| 125 | +import { repairFinish } from '@/api/work/finishRepairApi' | |
| 126 | +import UploadImageUrl from '@/components/upload/UploadImageUrl' | |
| 127 | +import ChooseSingleResource from '@/components/work/chooseSingleResource' | |
| 128 | + | |
| 129 | +export default { | |
| 130 | + name: 'FinishRepairList', | |
| 131 | + components: { | |
| 132 | + UploadImageUrl, | |
| 133 | + ChooseSingleResource | |
| 134 | + }, | |
| 135 | + data() { | |
| 136 | + return { | |
| 137 | + finishRepairInfo: { | |
| 138 | + repairId: '', | |
| 139 | + repairType: '', | |
| 140 | + context: '', | |
| 141 | + feeFlag: '200', | |
| 142 | + repairObjType: '', | |
| 143 | + publicArea: '', | |
| 144 | + repairChannel: '', | |
| 145 | + maintenanceTypes: [], | |
| 146 | + maintenanceType: '', | |
| 147 | + totalPrice: 0, | |
| 148 | + choosedGoodsList: [], | |
| 149 | + beforeRepairPhotos: [], | |
| 150 | + afterRepairPhotos: [], | |
| 151 | + payTypes: [], | |
| 152 | + payType: '' | |
| 153 | + }, | |
| 154 | + communityId: '' | |
| 155 | + } | |
| 156 | + }, | |
| 157 | + created() { | |
| 158 | + this.communityId = getCommunityId() | |
| 159 | + this.initData() | |
| 160 | + }, | |
| 161 | + methods: { | |
| 162 | + async initData() { | |
| 163 | + this.finishRepairInfo.repairType = this.$route.query.repairType | |
| 164 | + this.finishRepairInfo.repairId = this.$route.query.repairId | |
| 165 | + this.finishRepairInfo.repairObjType = this.$route.query.repairObjType | |
| 166 | + this.finishRepairInfo.publicArea = this.$route.query.publicArea | |
| 167 | + this.finishRepairInfo.repairChannel = this.$route.query.repairChannel | |
| 168 | + | |
| 169 | + try { | |
| 170 | + const maintenanceTypes = await getDict('r_repair_pool', 'maintenance_type') | |
| 171 | + this.finishRepairInfo.maintenanceTypes = maintenanceTypes | |
| 172 | + | |
| 173 | + const payTypes = await getDict('r_repair_pool', 'pay_type') | |
| 174 | + this.finishRepairInfo.payTypes = payTypes | |
| 175 | + } catch (error) { | |
| 176 | + console.error('获取字典数据失败:', error) | |
| 177 | + } | |
| 178 | + }, | |
| 179 | + openChooseSingleResourceModel() { | |
| 180 | + this.$refs.chooseSingleResource.open({ | |
| 181 | + maintenanceType: this.finishRepairInfo.maintenanceType | |
| 182 | + }) | |
| 183 | + }, | |
| 184 | + handleBeforeRepairImage(photos) { | |
| 185 | + this.finishRepairInfo.beforeRepairPhotos = photos.map(item => ({ | |
| 186 | + photo: item | |
| 187 | + })) | |
| 188 | + }, | |
| 189 | + handleAfterRepairImage(photos) { | |
| 190 | + this.finishRepairInfo.afterRepairPhotos = photos.map(item => ({ | |
| 191 | + photo: item | |
| 192 | + })) | |
| 193 | + }, | |
| 194 | + removeChoosedGoodsItem(index) { | |
| 195 | + this.finishRepairInfo.choosedGoodsList.splice(index, 1) | |
| 196 | + this.updateTotalPrice() | |
| 197 | + }, | |
| 198 | + updateTotalPrice() { | |
| 199 | + let totalPrice = 0 | |
| 200 | + this.finishRepairInfo.choosedGoodsList.forEach(item => { | |
| 201 | + totalPrice += item.price * item.useNumber | |
| 202 | + }) | |
| 203 | + this.finishRepairInfo.totalPrice = totalPrice.toFixed(2) | |
| 204 | + }, | |
| 205 | + validateForm() { | |
| 206 | + if (!this.finishRepairInfo.repairId) { | |
| 207 | + this.$message.error(this.$t('finishRepair.validate.repairIdRequired')) | |
| 208 | + return false | |
| 209 | + } | |
| 210 | + if (!this.finishRepairInfo.maintenanceType) { | |
| 211 | + this.$message.error(this.$t('finishRepair.validate.maintenanceTypeRequired')) | |
| 212 | + return false | |
| 213 | + } | |
| 214 | + if (!this.finishRepairInfo.context) { | |
| 215 | + this.$message.error(this.$t('finishRepair.validate.contextRequired')) | |
| 216 | + return false | |
| 217 | + } | |
| 218 | + if (this.finishRepairInfo.beforeRepairPhotos.length === 0) { | |
| 219 | + this.$message.error(this.$t('finishRepair.validate.beforePhotoRequired')) | |
| 220 | + return false | |
| 221 | + } | |
| 222 | + if (this.finishRepairInfo.afterRepairPhotos.length === 0) { | |
| 223 | + this.$message.error(this.$t('finishRepair.validate.afterPhotoRequired')) | |
| 224 | + return false | |
| 225 | + } | |
| 226 | + if ((this.finishRepairInfo.maintenanceType === '1001' || this.finishRepairInfo.maintenanceType === '1003') && | |
| 227 | + this.finishRepairInfo.choosedGoodsList.length === 0) { | |
| 228 | + this.$message.error(this.$t('finishRepair.validate.goodsRequired')) | |
| 229 | + return false | |
| 230 | + } | |
| 231 | + if (this.finishRepairInfo.maintenanceType === '1001' && !this.finishRepairInfo.payType) { | |
| 232 | + this.$message.error(this.$t('finishRepair.validate.paymentMethodRequired')) | |
| 233 | + return false | |
| 234 | + } | |
| 235 | + return true | |
| 236 | + }, | |
| 237 | + async submitFinishRepair() { | |
| 238 | + if (!this.validateForm()) return | |
| 239 | + | |
| 240 | + try { | |
| 241 | + const params = { | |
| 242 | + ...this.finishRepairInfo, | |
| 243 | + communityId: this.communityId | |
| 244 | + } | |
| 245 | + const res = await repairFinish(params) | |
| 246 | + if (res.code === 0) { | |
| 247 | + this.$message.success(this.$t('finishRepair.submitSuccess')) | |
| 248 | + this.backToList() | |
| 249 | + } else { | |
| 250 | + this.$message.error(res.msg) | |
| 251 | + } | |
| 252 | + } catch (error) { | |
| 253 | + this.$message.error(this.$t('finishRepair.submitError')) | |
| 254 | + } | |
| 255 | + }, | |
| 256 | + backToList() { | |
| 257 | + this.$router.go(-1) | |
| 258 | + } | |
| 259 | + } | |
| 260 | +} | |
| 261 | +</script> | |
| 262 | + | |
| 263 | +<style scoped> | |
| 264 | +.finish-repair-container { | |
| 265 | + padding: 20px; | |
| 266 | +} | |
| 267 | + | |
| 268 | +.box-card { | |
| 269 | + margin-bottom: 20px; | |
| 270 | +} | |
| 271 | + | |
| 272 | +.form-wrapper { | |
| 273 | + padding: 20px; | |
| 274 | +} | |
| 275 | +</style> | |
| 0 | 276 | \ No newline at end of file | ... | ... |
src/views/work/ownerRepairManageList.vue
| ... | ... | @@ -70,7 +70,8 @@ |
| 70 | 70 | <template slot-scope="scope"> |
| 71 | 71 | <el-button |
| 72 | 72 | v-if="hasPrivilege('502021012067300023') && (scope.row.state == '1000' || scope.row.state == '1200')" |
| 73 | - size="mini" type="primary" @click="_openEditOwnerRepairModel(scope.row)">{{ $t('common.edit') }}</el-button> | |
| 73 | + size="mini" type="primary" @click="_openEditOwnerRepairModel(scope.row)">{{ $t('common.edit') | |
| 74 | + }}</el-button> | |
| 74 | 75 | <el-button |
| 75 | 76 | v-if="hasPrivilege('502021012051410024') && (scope.row.state == '1000' || scope.row.state == '1200')" |
| 76 | 77 | size="mini" type="danger" @click="_openDeleteOwnerRepairModel(scope.row)">{{ $t('common.delete') |
| ... | ... | @@ -81,7 +82,7 @@ |
| 81 | 82 | <!-- 分页 --> |
| 82 | 83 | <div style="margin-top: 20px"> |
| 83 | 84 | <el-row> |
| 84 | - <el-col :span="18" class="text-left"> | |
| 85 | + <el-col :span="18" class="text-left table-desc"> | |
| 85 | 86 | <div> |
| 86 | 87 | {{ $t('ownerRepairManage.tip1') }} |
| 87 | 88 | </div> | ... | ... |
src/views/work/printRepairDetailLang.js
0 → 100644
| 1 | +export const messages = { | |
| 2 | + en: { | |
| 3 | + printRepairDetail: { | |
| 4 | + repairId: 'Repair ID:', | |
| 5 | + printTime: 'Print Time:', | |
| 6 | + repairInfo: 'Repair Information', | |
| 7 | + repairName: 'Repairer:', | |
| 8 | + tel: 'Contact Number:', | |
| 9 | + location: 'Location:', | |
| 10 | + context: 'Repair Content:', | |
| 11 | + maintenanceType: 'Repair Type:', | |
| 12 | + paidService: 'Paid Service', | |
| 13 | + freeService: 'Free Service', | |
| 14 | + repairMaterials: 'Repair Materials:', | |
| 15 | + repairFee: 'Cost Details:', | |
| 16 | + yuan: 'Yuan', | |
| 17 | + workflow: 'Work Order Flow', | |
| 18 | + serialNumber: 'No.', | |
| 19 | + handler: 'Handler', | |
| 20 | + status: 'Status', | |
| 21 | + processTime: 'Process Time', | |
| 22 | + timeConsuming: 'Time Consuming', | |
| 23 | + comment: 'Comment', | |
| 24 | + remark: 'Remark', | |
| 25 | + repairerSign: 'Repairer Signature', | |
| 26 | + customerSign: 'Customer Signature', | |
| 27 | + time: 'Time' | |
| 28 | + } | |
| 29 | + }, | |
| 30 | + zh: { | |
| 31 | + printRepairDetail: { | |
| 32 | + repairId: '报修单号:', | |
| 33 | + printTime: '打印时间:', | |
| 34 | + repairInfo: '报修信息', | |
| 35 | + repairName: '报修人:', | |
| 36 | + tel: '联系电话:', | |
| 37 | + location: '位置:', | |
| 38 | + context: '报修内容:', | |
| 39 | + maintenanceType: '报修类型:', | |
| 40 | + paidService: '有偿服务', | |
| 41 | + freeService: '无偿服务', | |
| 42 | + repairMaterials: '报修用料:', | |
| 43 | + repairFee: '费用明细:', | |
| 44 | + yuan: '元', | |
| 45 | + workflow: '工单流转', | |
| 46 | + serialNumber: '序号', | |
| 47 | + handler: '处理人', | |
| 48 | + status: '状态', | |
| 49 | + processTime: '处理时间', | |
| 50 | + timeConsuming: '耗时', | |
| 51 | + comment: '意见', | |
| 52 | + remark: '备注', | |
| 53 | + repairerSign: '维修人员签字', | |
| 54 | + customerSign: '客户签字', | |
| 55 | + time: '时间' | |
| 56 | + } | |
| 57 | + } | |
| 58 | +} | |
| 0 | 59 | \ No newline at end of file | ... | ... |
src/views/work/printRepairDetailList.vue
0 → 100644
| 1 | +<template> | |
| 2 | + <div class="print-repair-detail-container"> | |
| 3 | + <el-row :gutter="20" style="width:100%"> | |
| 4 | + <el-col :span="8"> | |
| 5 | + <span>{{ $t('printRepairDetail.repairId') }}</span>{{ printRepairDetailInfo.repairId }} | |
| 6 | + </el-col> | |
| 7 | + <el-col :span="8"> | |
| 8 | + <span></span> | |
| 9 | + </el-col> | |
| 10 | + <el-col :span="8"> | |
| 11 | + <span>{{ $t('printRepairDetail.printTime') }}</span>{{ nowTime }} | |
| 12 | + </el-col> | |
| 13 | + </el-row> | |
| 14 | + | |
| 15 | + <table border="1" class="margin-top" style="margin-bottom: 0;width:100%; border-collapse: collapse;"> | |
| 16 | + <thead> | |
| 17 | + <tr> | |
| 18 | + <th colspan="6" style="text-align: center;">{{ $t('printRepairDetail.repairInfo') }}</th> | |
| 19 | + </tr> | |
| 20 | + <tr> | |
| 21 | + <th>{{ $t('printRepairDetail.repairName') }}</th> | |
| 22 | + <th>{{ $t('printRepairDetail.tel') }}</th> | |
| 23 | + <th>{{ $t('printRepairDetail.location') }}</th> | |
| 24 | + <th>{{ $t('printRepairDetail.context') }}</th> | |
| 25 | + <th v-if="printRepairDetailInfo.maintenanceType">{{ $t('printRepairDetail.maintenanceType') }}</th> | |
| 26 | + <th v-if="printRepairDetailInfo.maintenanceType === '1001'">{{ $t('printRepairDetail.repairMaterials') }}</th> | |
| 27 | + <th v-if="printRepairDetailInfo.maintenanceType === '1001'" colspan="3">{{ $t('printRepairDetail.repairFee') }}</th> | |
| 28 | + </tr> | |
| 29 | + </thead> | |
| 30 | + <tbody> | |
| 31 | + <tr> | |
| 32 | + <td>{{ printRepairDetailInfo.repairName }}</td> | |
| 33 | + <td>{{ printRepairDetailInfo.tel }}</td> | |
| 34 | + <td>{{ printRepairDetailInfo.location }}</td> | |
| 35 | + <td>{{ printRepairDetailInfo.context }}</td> | |
| 36 | + <td v-if="printRepairDetailInfo.maintenanceType">{{ printRepairDetailInfo.maintenanceType }}</td> | |
| 37 | + <td v-if="printRepairDetailInfo.maintenanceType === '1001'">{{ printRepairDetailInfo.repairMaterials }}</td> | |
| 38 | + <td v-if="printRepairDetailInfo.maintenanceType === '1001'" colspan="3">{{ printRepairDetailInfo.repairFee }}</td> | |
| 39 | + </tr> | |
| 40 | + </tbody> | |
| 41 | + </table> | |
| 42 | + | |
| 43 | + <table border="1" style="width:100%; border-collapse: collapse;"> | |
| 44 | + <thead> | |
| 45 | + <tr> | |
| 46 | + <th colspan="6" style="text-align: center;">{{ $t('printRepairDetail.workflow') }}</th> | |
| 47 | + </tr> | |
| 48 | + <tr> | |
| 49 | + <th style="text-align: center;">{{ $t('printRepairDetail.serialNumber') }}</th> | |
| 50 | + <th style="text-align: center;">{{ $t('printRepairDetail.handler') }}</th> | |
| 51 | + <th style="text-align: center;">{{ $t('printRepairDetail.status') }}</th> | |
| 52 | + <th style="text-align: center;">{{ $t('printRepairDetail.processTime') }}</th> | |
| 53 | + <th style="text-align: center;">{{ $t('printRepairDetail.timeConsuming') }}</th> | |
| 54 | + <th style="text-align: center;">{{ $t('printRepairDetail.comment') }}</th> | |
| 55 | + </tr> | |
| 56 | + </thead> | |
| 57 | + <tbody> | |
| 58 | + <tr v-for="(item, index) in printRepairDetailInfo.repairUsers" :key="index"> | |
| 59 | + <td style="text-align: center;">{{ index + 1 }}</td> | |
| 60 | + <td style="text-align: center;">{{ item.staffName }}</td> | |
| 61 | + <td style="text-align: center;">{{ item.stateName }}</td> | |
| 62 | + <td style="text-align: center;">{{ item.startTime }}</td> | |
| 63 | + <td style="text-align: center;">{{ item.duration }}</td> | |
| 64 | + <td style="text-align: center;">{{ item.context }}</td> | |
| 65 | + </tr> | |
| 66 | + <tr> | |
| 67 | + <td colspan="6">{{ printRepairDetailInfo.description }}</td> | |
| 68 | + </tr> | |
| 69 | + <tr> | |
| 70 | + <td colspan="2" style="height:60px; text-align: center;">{{ $t('printRepairDetail.repairerSign') }}</td> | |
| 71 | + <td colspan="2" style="height:60px; text-align: center;">{{ $t('printRepairDetail.customerSign') }}</td> | |
| 72 | + </tr> | |
| 73 | + </tbody> | |
| 74 | + </table> | |
| 75 | + | |
| 76 | + <div id="print-btn" style="margin-top:20px"> | |
| 77 | + <el-button type="primary" class="float-right" @click="_printPurchaseApplyDiv"> | |
| 78 | + {{ $t('common.print') }} | |
| 79 | + </el-button> | |
| 80 | + <el-button type="warning" class="float-right" style="margin-right:20px" @click="_closePage"> | |
| 81 | + {{ $t('common.cancel') }} | |
| 82 | + </el-button> | |
| 83 | + </div> | |
| 84 | + </div> | |
| 85 | +</template> | |
| 86 | + | |
| 87 | +<script> | |
| 88 | +import { getCommunityId } from '@/api/community/communityApi' | |
| 89 | +import { listOwnerRepairs, listRepairStaffs } from '@/api/work/printRepairDetailApi' | |
| 90 | + | |
| 91 | +export default { | |
| 92 | + name: 'PrintRepairDetailList', | |
| 93 | + data() { | |
| 94 | + return { | |
| 95 | + printRepairDetailInfo: { | |
| 96 | + repairId: '', | |
| 97 | + repairTypeName: '', | |
| 98 | + appointmentTime: '', | |
| 99 | + repairName: '', | |
| 100 | + tel: '', | |
| 101 | + repairObjName: '', | |
| 102 | + context: '', | |
| 103 | + repairUsers: [], | |
| 104 | + maintenanceType: '', | |
| 105 | + repairMaterials: '', | |
| 106 | + repairFee: '', | |
| 107 | + description: '' | |
| 108 | + }, | |
| 109 | + printFlag: '0', | |
| 110 | + nowTime: '', | |
| 111 | + communityId: '' | |
| 112 | + } | |
| 113 | + }, | |
| 114 | + created() { | |
| 115 | + this.communityId = getCommunityId() | |
| 116 | + this._initPrintRepairDetailDateInfo() | |
| 117 | + const myDate = new Date() | |
| 118 | + this.nowTime = myDate.toLocaleDateString() | |
| 119 | + }, | |
| 120 | + methods: { | |
| 121 | + _initPrintRepairDetailDateInfo() { | |
| 122 | + const _repairId = this.$route.query.repairId | |
| 123 | + const _repairType = this.$route.query.repairType | |
| 124 | + const param = { | |
| 125 | + page: 1, | |
| 126 | + row: 1, | |
| 127 | + repairId: _repairId, | |
| 128 | + communityId: this.communityId, | |
| 129 | + repairType: _repairType | |
| 130 | + } | |
| 131 | + | |
| 132 | + listOwnerRepairs(param) | |
| 133 | + .then(response => { | |
| 134 | + const _repairDetailInfo = response.data[0] | |
| 135 | + Object.assign(this.printRepairDetailInfo, _repairDetailInfo) | |
| 136 | + this._loadRepairUser() | |
| 137 | + }) | |
| 138 | + .catch(error => { | |
| 139 | + console.error('请求失败处理:', error) | |
| 140 | + }) | |
| 141 | + }, | |
| 142 | + _loadRepairUser() { | |
| 143 | + const param = { | |
| 144 | + page: 1, | |
| 145 | + row: 100, | |
| 146 | + communityId: this.communityId, | |
| 147 | + repairId: this.printRepairDetailInfo.repairId | |
| 148 | + } | |
| 149 | + | |
| 150 | + listRepairStaffs(param) | |
| 151 | + .then(response => { | |
| 152 | + this.printRepairDetailInfo.repairUsers = response.data | |
| 153 | + }) | |
| 154 | + .catch(error => { | |
| 155 | + console.error('请求失败处理:', error) | |
| 156 | + }) | |
| 157 | + }, | |
| 158 | + _printPurchaseApplyDiv() { | |
| 159 | + this.printFlag = '1' | |
| 160 | + document.getElementById('print-btn').style.display = 'none' | |
| 161 | + window.print() | |
| 162 | + window.opener = null | |
| 163 | + window.close() | |
| 164 | + }, | |
| 165 | + _closePage() { | |
| 166 | + window.opener = null | |
| 167 | + window.close() | |
| 168 | + } | |
| 169 | + } | |
| 170 | +} | |
| 171 | +</script> | |
| 172 | + | |
| 173 | +<style lang="scss" scoped> | |
| 174 | +.print-repair-detail-container { | |
| 175 | + padding: 20px; | |
| 176 | + | |
| 177 | + .margin-top { | |
| 178 | + margin-top: 20px; | |
| 179 | + } | |
| 180 | + | |
| 181 | + .float-right { | |
| 182 | + float: right; | |
| 183 | + } | |
| 184 | + | |
| 185 | + table { | |
| 186 | + width: 100%; | |
| 187 | + border: 1px solid #ebeef5; | |
| 188 | + th, td { | |
| 189 | + padding: 12px 0; | |
| 190 | + border: 1px solid #ebeef5; | |
| 191 | + } | |
| 192 | + } | |
| 193 | +} | |
| 194 | +</style> | |
| 0 | 195 | \ No newline at end of file | ... | ... |
src/views/work/repairDetailLang.js
| ... | ... | @@ -33,7 +33,9 @@ export const messages = { |
| 33 | 33 | paidService: 'Paid Service', |
| 34 | 34 | freeService: 'Free Service', |
| 35 | 35 | needMaterials: 'Need Materials', |
| 36 | - noMaterials: 'No Materials' | |
| 36 | + noMaterials: 'No Materials', | |
| 37 | + beforeRepairPhotos: 'Before Repair Photos', | |
| 38 | + afterRepairPhotos: 'After Repair Photos' | |
| 37 | 39 | }, |
| 38 | 40 | repairDetailResource: { |
| 39 | 41 | itemCode: 'Item Code', |
| ... | ... | @@ -103,7 +105,9 @@ export const messages = { |
| 103 | 105 | paidService: '有偿服务', |
| 104 | 106 | freeService: '无偿服务', |
| 105 | 107 | needMaterials: '需要用料', |
| 106 | - noMaterials: '无需用料' | |
| 108 | + noMaterials: '无需用料', | |
| 109 | + beforeRepairPhotos: '维修前照片', | |
| 110 | + afterRepairPhotos: '维修后照片' | |
| 107 | 111 | }, |
| 108 | 112 | repairDetailResource: { |
| 109 | 113 | itemCode: '物品资源编号', | ... | ... |
src/views/work/repairDetailList.vue
| 1 | 1 | <template> |
| 2 | - <el-card class="repair-detail-container"> | |
| 2 | + <div class="repair-detail-container padding"> | |
| 3 | + <el-card class=""> | |
| 3 | 4 | <div class="flex justify-between"> |
| 4 | 5 | <div class="text-title">{{ $t('repairDetail.title') }}</div> |
| 5 | 6 | <div> |
| ... | ... | @@ -182,6 +183,7 @@ |
| 182 | 183 | <view-image ref="viewImage"></view-image> |
| 183 | 184 | <reply-repair-appraise ref="replyAppraise"></reply-repair-appraise> |
| 184 | 185 | </el-card> |
| 186 | +</div> | |
| 185 | 187 | </template> |
| 186 | 188 | |
| 187 | 189 | <script> |
| ... | ... | @@ -256,7 +258,7 @@ export default { |
| 256 | 258 | this.$router.go(-1) |
| 257 | 259 | }, |
| 258 | 260 | printRepairDetail() { |
| 259 | - window.open(`/print.html#/pages/property/printRepairDetail?repairId=${this.repairDetailInfo.repairId}&repairType=${this.repairDetailInfo.repairType}`) | |
| 261 | + window.open(`/pages/property/printRepairDetail?repairId=${this.repairDetailInfo.repairId}&repairType=${this.repairDetailInfo.repairType}`) | |
| 260 | 262 | }, |
| 261 | 263 | changeTab(tab) { |
| 262 | 264 | this.currentTab = tab | ... | ... |
src/views/work/repairDispatchManageList.vue
| ... | ... | @@ -98,7 +98,7 @@ |
| 98 | 98 | {{ $t('repairDispatchManage.complete') }} |
| 99 | 99 | </el-button> |
| 100 | 100 | <el-button |
| 101 | - v-if="$store.getters.hasPrivilege('502021040151320003') && scope.row.state == '1800' && scope.row.returnVisitFlag == '003' && scope.row.state != '2001'" | |
| 101 | + v-if="hasPrivilege('502021040151320003') && scope.row.state == '1800' && scope.row.returnVisitFlag == '003' && scope.row.state != '2001'" | |
| 102 | 102 | size="mini" @click="_openAppraiseRepair(scope.row)"> |
| 103 | 103 | {{ $t('repairDispatchManage.returnVisit') }} |
| 104 | 104 | </el-button> |
| ... | ... | @@ -245,7 +245,7 @@ export default { |
| 245 | 245 | }, |
| 246 | 246 | _openFinishRepair(row) { |
| 247 | 247 | this.$router.push({ |
| 248 | - path: '/property/finishRepair', | |
| 248 | + path: '/views/work/finishRepair', | |
| 249 | 249 | query: { |
| 250 | 250 | repairType: row.repairType, |
| 251 | 251 | repairId: row.repairId, |
| ... | ... | @@ -257,7 +257,7 @@ export default { |
| 257 | 257 | }, |
| 258 | 258 | _openDispatchRepairDetail(row) { |
| 259 | 259 | this.$router.push({ |
| 260 | - path: '/property/ownerRepairDetail', | |
| 260 | + path: '/views/work/repairDetail', | |
| 261 | 261 | query: { repairId: row.repairId } |
| 262 | 262 | }) |
| 263 | 263 | }, | ... | ... |
src/views/work/repairPoolManageList.vue
| 1 | 1 | <template> |
| 2 | - <div class="app-container"> | |
| 2 | + <div class="app-container padding"> | |
| 3 | 3 | <el-row :gutter="20"> |
| 4 | 4 | <!-- 左侧状态栏 --> |
| 5 | 5 | <el-col :span="3"> |
| ... | ... | @@ -82,7 +82,7 @@ |
| 82 | 82 | :placeholder="$t('repairPoolManage.endTime')" value-format="yyyy-MM-dd HH:mm:ss" /> |
| 83 | 83 | </el-form-item> |
| 84 | 84 | </el-col> |
| 85 | - <el-col :span="4" > | |
| 85 | + <el-col :span="4"> | |
| 86 | 86 | <el-button type="primary" @click="queryRepairPool">{{ $t('repairPoolManage.search') }}</el-button> |
| 87 | 87 | <el-button @click="resetRepairPool">{{ $t('repairPoolManage.reset') }}</el-button> |
| 88 | 88 | </el-col> |
| ... | ... | @@ -192,7 +192,7 @@ import DispatchRepair from '@/components/work/dispatchRepair' |
| 192 | 192 | import EndRepair from '@/components/work/endRepair' |
| 193 | 193 | import EditOwnerRepair from '@/components/work/editOwnerRepair' |
| 194 | 194 | import DeleteOwnerRepair from '@/components/work/deleteOwnerRepair' |
| 195 | -import {listRepairSettings} from '@/api/work/ownerRepairManageApi' | |
| 195 | +import { listRepairSettings } from '@/api/work/ownerRepairManageApi' | |
| 196 | 196 | |
| 197 | 197 | export default { |
| 198 | 198 | name: 'RepairPoolManage', | ... | ... |
src/views/work/repairReturnVisitLang.js
| ... | ... | @@ -18,7 +18,11 @@ export const messages = { |
| 18 | 18 | telPlaceholder: 'Please enter repair phone', |
| 19 | 19 | statePlaceholder: 'Please select visit status', |
| 20 | 20 | waiting: 'Pending Visit', |
| 21 | - finish: 'Visited' | |
| 21 | + finish: 'Visited', | |
| 22 | + satisfaction: 'Satisfaction', | |
| 23 | + visitContent: 'Visit Content', | |
| 24 | + satisfied: 'Satisfied', | |
| 25 | + unsatisfied: 'Unsatisfied' | |
| 22 | 26 | } |
| 23 | 27 | }, |
| 24 | 28 | zh: { |
| ... | ... | @@ -40,7 +44,11 @@ export const messages = { |
| 40 | 44 | telPlaceholder: '请输入报修电话', |
| 41 | 45 | statePlaceholder: '请选择回访状态', |
| 42 | 46 | waiting: '待回访', |
| 43 | - finish: '已回访' | |
| 47 | + finish: '已回访', | |
| 48 | + satisfaction: '满意度', | |
| 49 | + visitContent: '回访内容', | |
| 50 | + satisfied: '满意', | |
| 51 | + unsatisfied: '不满意' | |
| 44 | 52 | } |
| 45 | 53 | } |
| 46 | 54 | } |
| 47 | 55 | \ No newline at end of file | ... | ... |
src/views/work/repairReturnVisitList.vue
| ... | ... | @@ -24,7 +24,8 @@ |
| 24 | 24 | :placeholder="$t('repairReturnVisit.repairNamePlaceholder')" clearable /> |
| 25 | 25 | </el-col> |
| 26 | 26 | <el-col :sm="6" :md="4"> |
| 27 | - <el-input v-model.trim="searchForm.tel" :placeholder="$t('repairReturnVisit.telPlaceholder')" clearable /> | |
| 27 | + <el-input v-model.trim="searchForm.tel" :placeholder="$t('repairReturnVisit.telPlaceholder')" | |
| 28 | + clearable /> | |
| 28 | 29 | </el-col> |
| 29 | 30 | <el-col :sm="6" :md="4"> |
| 30 | 31 | <el-select v-model="searchForm.state" :placeholder="$t('repairReturnVisit.statePlaceholder')" clearable |
| ... | ... | @@ -119,7 +120,7 @@ export default { |
| 119 | 120 | this.states = [{ |
| 120 | 121 | value: 'waiting', |
| 121 | 122 | label: '待回访' |
| 122 | - },{ | |
| 123 | + }, { | |
| 123 | 124 | value: 'finish', |
| 124 | 125 | label: '已回访' |
| 125 | 126 | }] |
| ... | ... | @@ -179,7 +180,7 @@ export default { |
| 179 | 180 | }, |
| 180 | 181 | openRepairDetail(repairPool) { |
| 181 | 182 | this.$router.push({ |
| 182 | - path: '/pages/property/ownerRepairDetail', | |
| 183 | + path: '/views/work/repairDetail', | |
| 183 | 184 | query: { repairId: repairPool.repairId } |
| 184 | 185 | }) |
| 185 | 186 | }, | ... | ... |
src/views/work/repairTypeUserList.vue
| ... | ... | @@ -14,7 +14,7 @@ |
| 14 | 14 | </el-button> |
| 15 | 15 | </div> |
| 16 | 16 | </div> |
| 17 | - <div class="ibox-content"> | |
| 17 | + <div > | |
| 18 | 18 | <el-table :data="repairTypeUserManageInfo.repairTypeUsers" style="width: 100%" border stripe> |
| 19 | 19 | <el-table-column prop="staffId" :label="$t('repairTypeUser.repairMasterId')" align="center" /> |
| 20 | 20 | <el-table-column prop="staffName" :label="$t('repairTypeUser.masterName')" align="center" /> |
| ... | ... | @@ -43,7 +43,7 @@ |
| 43 | 43 | </el-col> |
| 44 | 44 | </el-row> |
| 45 | 45 | |
| 46 | - <SelectStaff ref="selectStaff" @selectStaff="handleSelectStaff"/> | |
| 46 | + <SelectStaff ref="selectStaff" @selectStaff="handleSelectStaff" /> | |
| 47 | 47 | <DeleteRepairTypeUser ref="deleteRepairTypeUser" @success="handleDeleteSuccess" /> |
| 48 | 48 | <EditRepairTypeUser ref="editRepairTypeUser" @success="handleEditSuccess" /> |
| 49 | 49 | </div> | ... | ... |