Commit 0fb08017cb02cb0b70bf3cd7ee24ea6bbfaca144
1 parent
20ddb876
物品放行功能测试完成
Showing
17 changed files
with
1246 additions
and
441 deletions
src/api/work/editItemReleaseViewApi.js
0 → 100644
| 1 | +import request from '@/utils/request' | ||
| 2 | +import { getCommunityId } from '@/api/community/communityApi' | ||
| 3 | + | ||
| 4 | +// 更新放行信息 | ||
| 5 | +export function updateItemRelease(data) { | ||
| 6 | + return new Promise((resolve, reject) => { | ||
| 7 | + request({ | ||
| 8 | + url: '/itemRelease.updateItemRelease', | ||
| 9 | + method: 'post', | ||
| 10 | + data: { | ||
| 11 | + ...data, | ||
| 12 | + communityId: getCommunityId() | ||
| 13 | + } | ||
| 14 | + }).then(response => { | ||
| 15 | + const res = response.data | ||
| 16 | + resolve(res) | ||
| 17 | + }).catch(error => { | ||
| 18 | + reject(error) | ||
| 19 | + }) | ||
| 20 | + }) | ||
| 21 | +} | ||
| 22 | + | ||
| 23 | +// 获取放行类型列表 | ||
| 24 | +export function listItemReleaseType(params) { | ||
| 25 | + return new Promise((resolve, reject) => { | ||
| 26 | + request({ | ||
| 27 | + url: '/itemRelease.listItemReleaseType', | ||
| 28 | + method: 'get', | ||
| 29 | + params: { | ||
| 30 | + ...params, | ||
| 31 | + communityId: getCommunityId() | ||
| 32 | + } | ||
| 33 | + }).then(response => { | ||
| 34 | + const res = response.data | ||
| 35 | + resolve(res) | ||
| 36 | + }).catch(error => { | ||
| 37 | + reject(error) | ||
| 38 | + }) | ||
| 39 | + }) | ||
| 40 | +} | ||
| 41 | + | ||
| 42 | +// 获取放行列表 | ||
| 43 | +export function listItemRelease(params) { | ||
| 44 | + return new Promise((resolve, reject) => { | ||
| 45 | + request({ | ||
| 46 | + url: '/itemRelease.listItemRelease', | ||
| 47 | + method: 'get', | ||
| 48 | + params: { | ||
| 49 | + ...params, | ||
| 50 | + communityId: getCommunityId() | ||
| 51 | + } | ||
| 52 | + }).then(response => { | ||
| 53 | + const res = response.data | ||
| 54 | + resolve(res) | ||
| 55 | + }).catch(error => { | ||
| 56 | + reject(error) | ||
| 57 | + }) | ||
| 58 | + }) | ||
| 59 | +} | ||
| 60 | + | ||
| 61 | +// 获取放行物品列表 | ||
| 62 | +export function listItemReleaseRes(params) { | ||
| 63 | + return new Promise((resolve, reject) => { | ||
| 64 | + request({ | ||
| 65 | + url: '/itemRelease.listItemReleaseRes', | ||
| 66 | + method: 'get', | ||
| 67 | + params: { | ||
| 68 | + ...params, | ||
| 69 | + communityId: getCommunityId() | ||
| 70 | + } | ||
| 71 | + }).then(response => { | ||
| 72 | + const res = response.data | ||
| 73 | + resolve(res) | ||
| 74 | + }).catch(error => { | ||
| 75 | + reject(error) | ||
| 76 | + }) | ||
| 77 | + }) | ||
| 78 | +} | ||
| 0 | \ No newline at end of file | 79 | \ No newline at end of file |
src/api/work/itemReleaseDetailApi.js
0 → 100644
| 1 | +import request from '@/utils/request' | ||
| 2 | +import { getCommunityId } from '@/api/community/communityApi' | ||
| 3 | + | ||
| 4 | +// 获取放行物品列表 | ||
| 5 | +export function listItemReleaseRes(params) { | ||
| 6 | + return new Promise((resolve, reject) => { | ||
| 7 | + request({ | ||
| 8 | + url: '/itemRelease.listItemReleaseRes', | ||
| 9 | + method: 'get', | ||
| 10 | + params: { | ||
| 11 | + ...params, | ||
| 12 | + communityId: getCommunityId() | ||
| 13 | + } | ||
| 14 | + }).then(response => { | ||
| 15 | + const res = response.data | ||
| 16 | + resolve(res) | ||
| 17 | + }).catch(error => { | ||
| 18 | + reject(error) | ||
| 19 | + }) | ||
| 20 | + }) | ||
| 21 | +} | ||
| 22 | + | ||
| 23 | +// 获取放行详情列表 | ||
| 24 | +export function listItemRelease(params) { | ||
| 25 | + return new Promise((resolve, reject) => { | ||
| 26 | + request({ | ||
| 27 | + url: '/itemRelease.listItemRelease', | ||
| 28 | + method: 'get', | ||
| 29 | + params: { | ||
| 30 | + ...params, | ||
| 31 | + communityId: getCommunityId() | ||
| 32 | + } | ||
| 33 | + }).then(response => { | ||
| 34 | + const res = response.data | ||
| 35 | + resolve(res) | ||
| 36 | + }).catch(error => { | ||
| 37 | + reject(error) | ||
| 38 | + }) | ||
| 39 | + }) | ||
| 40 | +} | ||
| 41 | + | ||
| 42 | +// 审核放行 | ||
| 43 | +export function auditUndoItemRelease(data) { | ||
| 44 | + return new Promise((resolve, reject) => { | ||
| 45 | + request({ | ||
| 46 | + url: '/itemRelease.auditUndoItemRelease', | ||
| 47 | + method: 'post', | ||
| 48 | + data: { | ||
| 49 | + ...data, | ||
| 50 | + communityId: getCommunityId() | ||
| 51 | + } | ||
| 52 | + }).then(response => { | ||
| 53 | + const res = response.data | ||
| 54 | + resolve(res) | ||
| 55 | + }).catch(error => { | ||
| 56 | + reject(error) | ||
| 57 | + }) | ||
| 58 | + }) | ||
| 59 | +} | ||
| 60 | + | ||
| 61 | +// 获取组织树 | ||
| 62 | +export function listOrgTree(params) { | ||
| 63 | + return new Promise((resolve, reject) => { | ||
| 64 | + request({ | ||
| 65 | + url: '/org.listOrgTree', | ||
| 66 | + method: 'get', | ||
| 67 | + params: { | ||
| 68 | + ...params, | ||
| 69 | + communityId: getCommunityId() | ||
| 70 | + } | ||
| 71 | + }).then(response => { | ||
| 72 | + const res = response.data | ||
| 73 | + resolve(res) | ||
| 74 | + }).catch(error => { | ||
| 75 | + reject(error) | ||
| 76 | + }) | ||
| 77 | + }) | ||
| 78 | +} | ||
| 79 | + | ||
| 80 | +// 查询员工信息 | ||
| 81 | +export function queryStaffInfos(params) { | ||
| 82 | + return new Promise((resolve, reject) => { | ||
| 83 | + request({ | ||
| 84 | + url: '/query.staff.infos', | ||
| 85 | + method: 'get', | ||
| 86 | + params: { | ||
| 87 | + ...params, | ||
| 88 | + communityId: getCommunityId() | ||
| 89 | + } | ||
| 90 | + }).then(response => { | ||
| 91 | + const res = response.data | ||
| 92 | + resolve(res) | ||
| 93 | + }).catch(error => { | ||
| 94 | + reject(error) | ||
| 95 | + }) | ||
| 96 | + }) | ||
| 97 | +} | ||
| 98 | + | ||
| 99 | +// 查询工单用户 | ||
| 100 | +export function queryOaWorkflowUser(params) { | ||
| 101 | + return new Promise((resolve, reject) => { | ||
| 102 | + request({ | ||
| 103 | + url: '/oaWorkflow/queryOaWorkflowUser', | ||
| 104 | + method: 'get', | ||
| 105 | + params: { | ||
| 106 | + ...params, | ||
| 107 | + communityId: getCommunityId() | ||
| 108 | + } | ||
| 109 | + }).then(response => { | ||
| 110 | + const res = response.data | ||
| 111 | + resolve(res) | ||
| 112 | + }).catch(error => { | ||
| 113 | + reject(error) | ||
| 114 | + }) | ||
| 115 | + }) | ||
| 116 | +} | ||
| 117 | + | ||
| 118 | +// 查询下一处理人 | ||
| 119 | +export function queryNextDealUser(params) { | ||
| 120 | + return new Promise((resolve, reject) => { | ||
| 121 | + request({ | ||
| 122 | + url: '/oaWorkflow.queryNextDealUser', | ||
| 123 | + method: 'get', | ||
| 124 | + params: { | ||
| 125 | + ...params, | ||
| 126 | + communityId: getCommunityId() | ||
| 127 | + } | ||
| 128 | + }).then(response => { | ||
| 129 | + const res = response.data | ||
| 130 | + resolve(res) | ||
| 131 | + }).catch(error => { | ||
| 132 | + reject(error) | ||
| 133 | + }) | ||
| 134 | + }) | ||
| 135 | +} | ||
| 136 | + | ||
| 137 | +// 获取流程图 | ||
| 138 | +export function listRunWorkflowImage(params) { | ||
| 139 | + return new Promise((resolve, reject) => { | ||
| 140 | + request({ | ||
| 141 | + url: '/workflow.listRunWorkflowImage', | ||
| 142 | + method: 'get', | ||
| 143 | + params: { | ||
| 144 | + ...params, | ||
| 145 | + communityId: getCommunityId() | ||
| 146 | + } | ||
| 147 | + }).then(response => { | ||
| 148 | + const res = response.data | ||
| 149 | + resolve(res) | ||
| 150 | + }).catch(error => { | ||
| 151 | + reject(error) | ||
| 152 | + }) | ||
| 153 | + }) | ||
| 154 | +} | ||
| 0 | \ No newline at end of file | 155 | \ No newline at end of file |
src/components/machine/cameraControlVideo.vue
| 1 | <template> | 1 | <template> |
| 2 | <div class="camera-control-video"> | 2 | <div class="camera-control-video"> |
| 3 | <el-row> | 3 | <el-row> |
| 4 | - <el-col :span="12"> | 4 | + <el-col :span="12" class="text-left"> |
| 5 | <h3>{{ $t('cameraControlVideo.camera') }}</h3> | 5 | <h3>{{ $t('cameraControlVideo.camera') }}</h3> |
| 6 | </el-col> | 6 | </el-col> |
| 7 | <el-col :span="12" class="text-right"> | 7 | <el-col :span="12" class="text-right"> |
src/components/work/editItemRelease.vue
| 1 | <template> | 1 | <template> |
| 2 | - <el-dialog | ||
| 3 | - :title="$t('itemReleaseManage.edit.title')" | ||
| 4 | - :visible.sync="visible" | ||
| 5 | - width="60%" | ||
| 6 | - @close="handleClose" | ||
| 7 | - > | ||
| 8 | - <el-form | ||
| 9 | - ref="form" | ||
| 10 | - :model="formData" | ||
| 11 | - :rules="rules" | ||
| 12 | - label-width="120px" | ||
| 13 | - label-position="right" | ||
| 14 | - > | ||
| 15 | - <el-form-item | ||
| 16 | - :label="$t('itemReleaseManage.form.releaseType')" | ||
| 17 | - prop="typeId" | ||
| 18 | - > | ||
| 19 | - <el-select | ||
| 20 | - v-model="formData.typeId" | ||
| 21 | - :placeholder="$t('itemReleaseManage.placeholder.requiredSelect')" | ||
| 22 | - style="width: 100%" | ||
| 23 | - > | ||
| 24 | - <el-option | ||
| 25 | - v-for="item in releaseTypes" | ||
| 26 | - :key="item.typeId" | ||
| 27 | - :label="item.typeName" | ||
| 28 | - :value="item.typeId" | ||
| 29 | - /> | 2 | + <el-dialog :title="$t('itemReleaseManage.edit.title')" :visible.sync="visible" width="60%" @close="handleClose"> |
| 3 | + <el-form ref="form" :model="formData" :rules="rules" label-width="120px" label-position="right"> | ||
| 4 | + <el-form-item :label="$t('itemReleaseManage.form.releaseType')" prop="typeId"> | ||
| 5 | + <el-select v-model="formData.typeId" :placeholder="$t('itemReleaseManage.placeholder.requiredSelect')" | ||
| 6 | + style="width: 100%"> | ||
| 7 | + <el-option v-for="item in releaseTypes" :key="item.typeId" :label="item.typeName" :value="item.typeId" /> | ||
| 30 | </el-select> | 8 | </el-select> |
| 31 | </el-form-item> | 9 | </el-form-item> |
| 32 | 10 | ||
| 33 | - <el-form-item | ||
| 34 | - :label="$t('itemReleaseManage.form.applyCompany')" | ||
| 35 | - prop="applyCompany" | ||
| 36 | - > | ||
| 37 | - <el-input | ||
| 38 | - v-model="formData.applyCompany" | ||
| 39 | - :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" | ||
| 40 | - /> | 11 | + <el-form-item :label="$t('itemReleaseManage.form.applyCompany')" prop="applyCompany"> |
| 12 | + <el-input v-model="formData.applyCompany" :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" /> | ||
| 41 | </el-form-item> | 13 | </el-form-item> |
| 42 | 14 | ||
| 43 | - <el-form-item | ||
| 44 | - :label="$t('itemReleaseManage.form.applyPerson')" | ||
| 45 | - prop="applyPerson" | ||
| 46 | - > | ||
| 47 | - <el-input | ||
| 48 | - v-model="formData.applyPerson" | ||
| 49 | - :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" | ||
| 50 | - /> | 15 | + <el-form-item :label="$t('itemReleaseManage.form.applyPerson')" prop="applyPerson"> |
| 16 | + <el-input v-model="formData.applyPerson" :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" /> | ||
| 51 | </el-form-item> | 17 | </el-form-item> |
| 52 | 18 | ||
| 53 | - <el-form-item | ||
| 54 | - :label="$t('itemReleaseManage.form.idCard')" | ||
| 55 | - prop="idCard" | ||
| 56 | - > | ||
| 57 | - <el-input | ||
| 58 | - v-model="formData.idCard" | ||
| 59 | - :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" | ||
| 60 | - maxlength="18" | ||
| 61 | - /> | 19 | + <el-form-item :label="$t('itemReleaseManage.form.idCard')" prop="idCard"> |
| 20 | + <el-input v-model="formData.idCard" :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" | ||
| 21 | + maxlength="18" /> | ||
| 62 | </el-form-item> | 22 | </el-form-item> |
| 63 | 23 | ||
| 64 | - <el-form-item | ||
| 65 | - :label="$t('itemReleaseManage.form.phone')" | ||
| 66 | - prop="applyTel" | ||
| 67 | - > | ||
| 68 | - <el-input | ||
| 69 | - v-model="formData.applyTel" | ||
| 70 | - :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" | ||
| 71 | - maxlength="11" | ||
| 72 | - /> | 24 | + <el-form-item :label="$t('itemReleaseManage.form.phone')" prop="applyTel"> |
| 25 | + <el-input v-model="formData.applyTel" :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" | ||
| 26 | + maxlength="11" /> | ||
| 73 | </el-form-item> | 27 | </el-form-item> |
| 74 | 28 | ||
| 75 | - <el-form-item | ||
| 76 | - :label="$t('itemReleaseManage.form.passTime')" | ||
| 77 | - prop="passTime" | ||
| 78 | - > | ||
| 79 | - <el-input | ||
| 80 | - v-model="formData.passTime" | ||
| 81 | - :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" | ||
| 82 | - /> | 29 | + <el-form-item :label="$t('itemReleaseManage.form.passTime')" prop="passTime"> |
| 30 | + <el-input v-model="formData.passTime" :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" /> | ||
| 83 | </el-form-item> | 31 | </el-form-item> |
| 84 | 32 | ||
| 85 | - <el-form-item | ||
| 86 | - :label="$t('itemReleaseManage.form.releaseItems')" | ||
| 87 | - prop="resName" | ||
| 88 | - > | ||
| 89 | - <el-input | ||
| 90 | - v-model="formData.resName" | ||
| 91 | - :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" | ||
| 92 | - /> | 33 | + <el-form-item :label="$t('itemReleaseManage.form.releaseItems')" prop="resName"> |
| 34 | + <el-input v-model="formData.resName" :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" /> | ||
| 93 | </el-form-item> | 35 | </el-form-item> |
| 94 | 36 | ||
| 95 | - <el-form-item | ||
| 96 | - :label="$t('itemReleaseManage.form.itemAmount')" | ||
| 97 | - prop="amount" | ||
| 98 | - > | ||
| 99 | - <el-input | ||
| 100 | - v-model="formData.amount" | ||
| 101 | - :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" | ||
| 102 | - /> | 37 | + <el-form-item :label="$t('itemReleaseManage.form.itemAmount')" prop="amount"> |
| 38 | + <el-input v-model="formData.amount" :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" /> | ||
| 103 | </el-form-item> | 39 | </el-form-item> |
| 104 | 40 | ||
| 105 | - <el-form-item | ||
| 106 | - :label="$t('itemReleaseManage.form.status')" | ||
| 107 | - prop="state" | ||
| 108 | - > | ||
| 109 | - <el-select | ||
| 110 | - v-model="formData.state" | ||
| 111 | - :placeholder="$t('itemReleaseManage.placeholder.requiredSelect')" | ||
| 112 | - style="width: 100%" | ||
| 113 | - > | ||
| 114 | - <el-option | ||
| 115 | - :label="$t('itemReleaseManage.status.waiting')" | ||
| 116 | - value="W" | ||
| 117 | - /> | ||
| 118 | - <el-option | ||
| 119 | - :label="$t('itemReleaseManage.status.processing')" | ||
| 120 | - value="D" | ||
| 121 | - /> | ||
| 122 | - <el-option | ||
| 123 | - :label="$t('itemReleaseManage.status.completed')" | ||
| 124 | - value="C" | ||
| 125 | - /> | ||
| 126 | - <el-option | ||
| 127 | - :label="$t('itemReleaseManage.status.failed')" | ||
| 128 | - value="F" | ||
| 129 | - /> | 41 | + <el-form-item :label="$t('itemReleaseManage.form.status')" prop="state"> |
| 42 | + <el-select v-model="formData.state" :placeholder="$t('itemReleaseManage.placeholder.requiredSelect')" | ||
| 43 | + style="width: 100%"> | ||
| 44 | + <el-option :label="$t('itemReleaseManage.status.waiting')" value="W" /> | ||
| 45 | + <el-option :label="$t('itemReleaseManage.status.processing')" value="D" /> | ||
| 46 | + <el-option :label="$t('itemReleaseManage.status.completed')" value="C" /> | ||
| 47 | + <el-option :label="$t('itemReleaseManage.status.failed')" value="F" /> | ||
| 130 | </el-select> | 48 | </el-select> |
| 131 | </el-form-item> | 49 | </el-form-item> |
| 132 | 50 | ||
| 133 | - <el-form-item | ||
| 134 | - :label="$t('itemReleaseManage.form.carNumber')" | ||
| 135 | - prop="carNum" | ||
| 136 | - > | ||
| 137 | - <el-input | ||
| 138 | - v-model="formData.carNum" | ||
| 139 | - :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" | ||
| 140 | - /> | 51 | + <el-form-item :label="$t('itemReleaseManage.form.carNumber')" prop="carNum"> |
| 52 | + <el-input v-model="formData.carNum" :placeholder="$t('itemReleaseManage.placeholder.requiredInput')" /> | ||
| 141 | </el-form-item> | 53 | </el-form-item> |
| 142 | 54 | ||
| 143 | - <el-form-item | ||
| 144 | - :label="$t('itemReleaseManage.form.remark')" | ||
| 145 | - prop="remark" | ||
| 146 | - > | ||
| 147 | - <el-input | ||
| 148 | - v-model="formData.remark" | ||
| 149 | - type="textarea" | ||
| 150 | - :placeholder="$t('itemReleaseManage.placeholder.optionalInput')" | ||
| 151 | - /> | 55 | + <el-form-item :label="$t('itemReleaseManage.form.remark')" prop="remark"> |
| 56 | + <el-input v-model="formData.remark" type="textarea" | ||
| 57 | + :placeholder="$t('itemReleaseManage.placeholder.optionalInput')" /> | ||
| 152 | </el-form-item> | 58 | </el-form-item> |
| 153 | </el-form> | 59 | </el-form> |
| 154 | 60 | ||
| @@ -212,7 +118,6 @@ export default { | @@ -212,7 +118,6 @@ export default { | ||
| 212 | ], | 118 | ], |
| 213 | passTime: [ | 119 | passTime: [ |
| 214 | { required: true, message: this.$t('itemReleaseManage.validate.required'), trigger: 'blur' }, | 120 | { required: true, message: this.$t('itemReleaseManage.validate.required'), trigger: 'blur' }, |
| 215 | - { max: 12, message: this.$t('itemReleaseManage.validate.maxLength12'), trigger: 'blur' } | ||
| 216 | ], | 121 | ], |
| 217 | resName: [ | 122 | resName: [ |
| 218 | { required: true, message: this.$t('itemReleaseManage.validate.required'), trigger: 'blur' }, | 123 | { required: true, message: this.$t('itemReleaseManage.validate.required'), trigger: 'blur' }, |
src/components/work/orgTreeShow.vue
| 1 | <template> | 1 | <template> |
| 2 | - <div class="org-tree-show-container"> | 2 | + <div class="org-tree-container"> |
| 3 | <el-tree | 3 | <el-tree |
| 4 | ref="orgTree" | 4 | ref="orgTree" |
| 5 | - :data="orgs" | 5 | + :data="orgTreeShowInfo.orgs" |
| 6 | :props="defaultProps" | 6 | :props="defaultProps" |
| 7 | node-key="id" | 7 | node-key="id" |
| 8 | default-expand-all | 8 | default-expand-all |
| @@ -13,44 +13,46 @@ | @@ -13,44 +13,46 @@ | ||
| 13 | </template> | 13 | </template> |
| 14 | 14 | ||
| 15 | <script> | 15 | <script> |
| 16 | -import { listOrgTree } from '@/api/work/addItemReleaseViewApi' | ||
| 17 | import { getCommunityId } from '@/api/community/communityApi' | 16 | import { getCommunityId } from '@/api/community/communityApi' |
| 17 | +import { listOrgTree } from '@/api/work/itemReleaseDetailApi' | ||
| 18 | 18 | ||
| 19 | export default { | 19 | export default { |
| 20 | name: 'OrgTreeShow', | 20 | name: 'OrgTreeShow', |
| 21 | - props: { | ||
| 22 | - callBackListener: { | ||
| 23 | - type: String, | ||
| 24 | - default: '' | ||
| 25 | - } | ||
| 26 | - }, | ||
| 27 | data() { | 21 | data() { |
| 28 | return { | 22 | return { |
| 29 | - orgs: [], | 23 | + communityId: '', |
| 24 | + orgTreeShowInfo: { | ||
| 25 | + orgs: [], | ||
| 26 | + orgId: '', | ||
| 27 | + curOrg: {} | ||
| 28 | + }, | ||
| 30 | defaultProps: { | 29 | defaultProps: { |
| 31 | children: 'children', | 30 | children: 'children', |
| 32 | label: 'text' | 31 | label: 'text' |
| 33 | - }, | ||
| 34 | - communityId: '' | 32 | + } |
| 35 | } | 33 | } |
| 36 | }, | 34 | }, |
| 37 | created() { | 35 | created() { |
| 38 | this.communityId = getCommunityId() | 36 | this.communityId = getCommunityId() |
| 39 | }, | 37 | }, |
| 40 | methods: { | 38 | methods: { |
| 41 | - async refreshTree() { | 39 | + refreshTree() { |
| 40 | + this._loadOrgsShow() | ||
| 41 | + }, | ||
| 42 | + async _loadOrgsShow() { | ||
| 42 | try { | 43 | try { |
| 43 | - const params = { | 44 | + const { data } = await listOrgTree({ |
| 44 | communityId: this.communityId | 45 | communityId: this.communityId |
| 45 | - } | ||
| 46 | - const res = await listOrgTree(params) | ||
| 47 | - this.orgs = res.data || [] | 46 | + }) |
| 47 | + this.orgTreeShowInfo.orgs = data | ||
| 48 | } catch (error) { | 48 | } catch (error) { |
| 49 | - console.error('Failed to load org tree:', error) | 49 | + console.error('获取组织树失败:', error) |
| 50 | } | 50 | } |
| 51 | }, | 51 | }, |
| 52 | handleNodeClick(data) { | 52 | handleNodeClick(data) { |
| 53 | - this.$emit('switch-org', { | 53 | + this.orgTreeShowInfo.curOrg = data |
| 54 | + this.orgTreeShowInfo.curOrg.orgId = data.id | ||
| 55 | + this.$emit('switchOrg', { | ||
| 54 | orgId: data.id, | 56 | orgId: data.id, |
| 55 | orgName: data.text | 57 | orgName: data.text |
| 56 | }) | 58 | }) |
| @@ -59,9 +61,19 @@ export default { | @@ -59,9 +61,19 @@ export default { | ||
| 59 | } | 61 | } |
| 60 | </script> | 62 | </script> |
| 61 | 63 | ||
| 62 | -<style scoped> | ||
| 63 | -.org-tree-show-container { | ||
| 64 | - height: 100%; | 64 | +<style lang="scss" scoped> |
| 65 | +.org-tree-container { | ||
| 66 | + height: 400px; | ||
| 65 | overflow-y: auto; | 67 | overflow-y: auto; |
| 68 | + | ||
| 69 | + /deep/ .el-tree { | ||
| 70 | + .el-tree-node__content { | ||
| 71 | + height: 40px; | ||
| 72 | + } | ||
| 73 | + | ||
| 74 | + .el-tree-node.is-current > .el-tree-node__content { | ||
| 75 | + background-color: #f0f7ff; | ||
| 76 | + } | ||
| 77 | + } | ||
| 66 | } | 78 | } |
| 67 | </style> | 79 | </style> |
| 68 | \ No newline at end of file | 80 | \ No newline at end of file |
src/components/work/selectStaff.vue
| 1 | <template> | 1 | <template> |
| 2 | - <el-dialog | ||
| 3 | - :visible.sync="visible" | ||
| 4 | - :title="$t('selectStaff.title')" | 2 | + <el-dialog |
| 3 | + :visible.sync="visible" | ||
| 4 | + :title="$t('selectStaff.selectStaff')" | ||
| 5 | width="80%" | 5 | width="80%" |
| 6 | @close="handleClose" | 6 | @close="handleClose" |
| 7 | > | 7 | > |
| 8 | <el-row :gutter="20"> | 8 | <el-row :gutter="20"> |
| 9 | - <el-col :span="12" class="border-right"> | ||
| 10 | - <div class="text-center mb-20"> | ||
| 11 | - <h4>{{ $t('selectStaff.orgInfo') }}</h4> | ||
| 12 | - </div> | ||
| 13 | - <div class="org-tree-container"> | ||
| 14 | - <OrgTreeShow ref="orgTree" @switch-org="handleSwitchOrg" /> | ||
| 15 | - </div> | 9 | + <el-col :span="12"> |
| 10 | + <div class="section-title">{{ $t('selectStaff.orgInfo') }}</div> | ||
| 11 | + <org-tree-show ref="orgTree" @switchOrg="handleSwitchOrg" /> | ||
| 16 | </el-col> | 12 | </el-col> |
| 17 | <el-col :span="12"> | 13 | <el-col :span="12"> |
| 18 | - <div class="text-center mb-20"> | ||
| 19 | - <h4>{{ $t('selectStaff.staffInfo') }}</h4> | ||
| 20 | - </div> | ||
| 21 | - <div class="staff-list-container"> | ||
| 22 | - <div | ||
| 23 | - v-for="item in staffs" | ||
| 24 | - :key="item.staffId" | 14 | + <div class="section-title">{{ $t('selectStaff.staffInfo') }}</div> |
| 15 | + <div class="staff-list"> | ||
| 16 | + <div | ||
| 17 | + v-for="(item,index) in selectStaffInfo.staffs" | ||
| 18 | + :key="index" | ||
| 25 | class="staff-item" | 19 | class="staff-item" |
| 26 | - :class="{ 'selected': currentStaffId === item.staffId }" | ||
| 27 | - @click="selectStaff(item)" | 20 | + :class="{ 'selected': selectStaffInfo.curStaffId === item.staffId }" |
| 21 | + @click="handleChangeStaff(item)" | ||
| 28 | > | 22 | > |
| 29 | <div> | 23 | <div> |
| 30 | <i class="el-icon-user"></i> | 24 | <i class="el-icon-user"></i> |
| @@ -35,21 +29,28 @@ | @@ -35,21 +29,28 @@ | ||
| 35 | </div> | 29 | </div> |
| 36 | </el-col> | 30 | </el-col> |
| 37 | </el-row> | 31 | </el-row> |
| 38 | - <div | ||
| 39 | - v-if="staff.from === 'bpmn' || staff.from === 'purchase' || staff.from === 'contract'" | ||
| 40 | - slot="footer" | ||
| 41 | - class="dialog-footer" | ||
| 42 | - > | ||
| 43 | - <el-button @click="selectFirstUser">{{ $t('selectStaff.submitter') }}</el-button> | ||
| 44 | - <el-button @click="selectCustomUser">{{ $t('selectStaff.dynamicAssign') }}</el-button> | 32 | + <div slot="footer" class="dialog-footer"> |
| 33 | + <el-button | ||
| 34 | + v-if="staff.from === 'bpmn' || staff.from === 'purchase' || staff.from === 'contract'" | ||
| 35 | + @click="handleFirstUser" | ||
| 36 | + > | ||
| 37 | + {{ $t('selectStaff.submitter') }} | ||
| 38 | + </el-button> | ||
| 39 | + <el-button | ||
| 40 | + v-if="staff.from === 'bpmn' || staff.from === 'purchase' || staff.from === 'contract'" | ||
| 41 | + @click="handleCustomUser" | ||
| 42 | + > | ||
| 43 | + {{ $t('selectStaff.dynamicAssign') }} | ||
| 44 | + </el-button> | ||
| 45 | + <el-button @click="visible = false">{{ $t('common.cancel') }}</el-button> | ||
| 45 | </div> | 46 | </div> |
| 46 | </el-dialog> | 47 | </el-dialog> |
| 47 | </template> | 48 | </template> |
| 48 | 49 | ||
| 49 | <script> | 50 | <script> |
| 50 | -import OrgTreeShow from './orgTreeShow' | ||
| 51 | -import { queryStaffInfos } from '@/api/work/addItemReleaseViewApi' | 51 | +import OrgTreeShow from './OrgTreeShow' |
| 52 | import { getCommunityId } from '@/api/community/communityApi' | 52 | import { getCommunityId } from '@/api/community/communityApi' |
| 53 | +import { queryStaffInfos } from '@/api/work/itemReleaseDetailApi' | ||
| 53 | 54 | ||
| 54 | export default { | 55 | export default { |
| 55 | name: 'SelectStaff', | 56 | name: 'SelectStaff', |
| @@ -59,10 +60,13 @@ export default { | @@ -59,10 +60,13 @@ export default { | ||
| 59 | data() { | 60 | data() { |
| 60 | return { | 61 | return { |
| 61 | visible: false, | 62 | visible: false, |
| 63 | + communityId: '', | ||
| 62 | staff: {}, | 64 | staff: {}, |
| 63 | - staffs: [], | ||
| 64 | - currentStaffId: '', | ||
| 65 | - communityId: '' | 65 | + selectStaffInfo: { |
| 66 | + staffs: [], | ||
| 67 | + curStaffId: '', | ||
| 68 | + curStaffName: '' | ||
| 69 | + } | ||
| 66 | } | 70 | } |
| 67 | }, | 71 | }, |
| 68 | created() { | 72 | created() { |
| @@ -77,82 +81,93 @@ export default { | @@ -77,82 +81,93 @@ export default { | ||
| 77 | }) | 81 | }) |
| 78 | }, | 82 | }, |
| 79 | handleClose() { | 83 | handleClose() { |
| 80 | - this.visible = false | ||
| 81 | - this.staffs = [] | ||
| 82 | - this.currentStaffId = '' | 84 | + this.selectStaffInfo.staffs = [] |
| 85 | + this.selectStaffInfo.curStaffId = '' | ||
| 83 | }, | 86 | }, |
| 84 | async handleSwitchOrg(org) { | 87 | async handleSwitchOrg(org) { |
| 85 | try { | 88 | try { |
| 86 | - const params = { | 89 | + const { data } = await queryStaffInfos({ |
| 87 | page: 1, | 90 | page: 1, |
| 88 | rows: 50, | 91 | rows: 50, |
| 89 | - row: 50, | ||
| 90 | - orgId: org.orgId | ||
| 91 | - } | ||
| 92 | - const res = await queryStaffInfos(params) | ||
| 93 | - this.staffs = res.staffs || [] | ||
| 94 | - if (this.staffs.length > 0) { | ||
| 95 | - this.currentStaffId = this.staffs[0].staffId | 92 | + orgId: org.orgId, |
| 93 | + communityId: this.communityId | ||
| 94 | + }) | ||
| 95 | + this.selectStaffInfo.staffs = data.staffs | ||
| 96 | + if (data.staffs.length > 0) { | ||
| 97 | + this.selectStaffInfo.curStaffId = data.staffs[0].orgId | ||
| 96 | } | 98 | } |
| 97 | } catch (error) { | 99 | } catch (error) { |
| 98 | - console.error('Failed to load staffs:', error) | 100 | + console.error('获取员工信息失败:', error) |
| 99 | } | 101 | } |
| 100 | }, | 102 | }, |
| 101 | - selectStaff(item) { | ||
| 102 | - this.currentStaffId = item.staffId | ||
| 103 | - this.$emit('select', { | ||
| 104 | - staffId: item.userId, | ||
| 105 | - staffName: item.userName, | ||
| 106 | - staffTel: item.tel | ||
| 107 | - }) | 103 | + handleChangeStaff(item) { |
| 104 | + this.staff.staffId = item.userId | ||
| 105 | + this.staff.staffName = item.userName | ||
| 106 | + this.staff.staffTel = item.tel | ||
| 108 | this.visible = false | 107 | this.visible = false |
| 108 | + | ||
| 109 | + if (typeof this.staff.call === 'function') { | ||
| 110 | + this.staff.call(this.staff) | ||
| 111 | + } | ||
| 109 | }, | 112 | }, |
| 110 | - selectFirstUser() { | ||
| 111 | - this.$emit('select', { | ||
| 112 | - staffId: '${startUserId}', | ||
| 113 | - staffName: this.$t('selectStaff.submitter') | ||
| 114 | - }) | 113 | + handleFirstUser() { |
| 114 | + this.staff.staffId = '${startUserId}' | ||
| 115 | + this.staff.staffName = this.$t('selectStaff.submitter') | ||
| 115 | this.visible = false | 116 | this.visible = false |
| 117 | + | ||
| 118 | + if (typeof this.staff.call === 'function') { | ||
| 119 | + this.staff.call(this.staff) | ||
| 120 | + } | ||
| 116 | }, | 121 | }, |
| 117 | - selectCustomUser() { | ||
| 118 | - this.$emit('select', { | ||
| 119 | - staffId: '${nextUserId}', | ||
| 120 | - staffName: this.$t('selectStaff.dynamicAssign') | ||
| 121 | - }) | 122 | + handleCustomUser() { |
| 123 | + this.staff.staffId = '${nextUserId}' | ||
| 124 | + this.staff.staffName = this.$t('selectStaff.dynamicAssign') | ||
| 122 | this.visible = false | 125 | this.visible = false |
| 126 | + | ||
| 127 | + if (typeof this.staff.call === 'function') { | ||
| 128 | + this.staff.call(this.staff) | ||
| 129 | + } | ||
| 123 | } | 130 | } |
| 124 | } | 131 | } |
| 125 | } | 132 | } |
| 126 | </script> | 133 | </script> |
| 127 | 134 | ||
| 128 | -<style scoped> | ||
| 129 | -.border-right { | ||
| 130 | - border-right: 1px solid #ebeef5; | 135 | +<style lang="scss" scoped> |
| 136 | +.section-title { | ||
| 137 | + font-size: 16px; | ||
| 138 | + font-weight: bold; | ||
| 139 | + margin-bottom: 15px; | ||
| 140 | + text-align: center; | ||
| 131 | } | 141 | } |
| 132 | -.org-tree-container, | ||
| 133 | -.staff-list-container { | ||
| 134 | - height: 400px; | 142 | + |
| 143 | +.staff-list { | ||
| 144 | + max-height: 400px; | ||
| 135 | overflow-y: auto; | 145 | overflow-y: auto; |
| 136 | - padding: 10px; | ||
| 137 | } | 146 | } |
| 147 | + | ||
| 138 | .staff-item { | 148 | .staff-item { |
| 139 | padding: 10px; | 149 | padding: 10px; |
| 140 | margin-bottom: 10px; | 150 | margin-bottom: 10px; |
| 141 | border: 1px solid #ebeef5; | 151 | border: 1px solid #ebeef5; |
| 142 | border-radius: 4px; | 152 | border-radius: 4px; |
| 143 | cursor: pointer; | 153 | cursor: pointer; |
| 154 | + transition: all 0.3s; | ||
| 155 | + | ||
| 156 | + &:hover { | ||
| 157 | + background-color: #f5f7fa; | ||
| 158 | + } | ||
| 159 | + | ||
| 160 | + &.selected { | ||
| 161 | + background-color: #ecf5ff; | ||
| 162 | + border-color: #d9ecff; | ||
| 163 | + } | ||
| 164 | + | ||
| 165 | + .el-icon-user { | ||
| 166 | + margin-right: 5px; | ||
| 167 | + } | ||
| 144 | } | 168 | } |
| 145 | -.staff-item:hover { | ||
| 146 | - background-color: #f5f7fa; | ||
| 147 | -} | ||
| 148 | -.staff-item.selected { | ||
| 149 | - background-color: #ecf5ff; | ||
| 150 | - border-color: #d9ecff; | ||
| 151 | -} | ||
| 152 | -.text-center { | ||
| 153 | - text-align: center; | ||
| 154 | -} | ||
| 155 | -.mb-20 { | ||
| 156 | - margin-bottom: 20px; | 169 | + |
| 170 | +.dialog-footer { | ||
| 171 | + text-align: right; | ||
| 157 | } | 172 | } |
| 158 | </style> | 173 | </style> |
| 159 | \ No newline at end of file | 174 | \ No newline at end of file |
src/i18n/workI18n.js
| @@ -2,15 +2,21 @@ import { messages as itemReleaseTypeManageMessages } from '../views/work/itemRel | @@ -2,15 +2,21 @@ import { messages as itemReleaseTypeManageMessages } from '../views/work/itemRel | ||
| 2 | import { messages as itemReleaseManageMessages } from '../views/work/itemReleaseManageLang' | 2 | import { messages as itemReleaseManageMessages } from '../views/work/itemReleaseManageLang' |
| 3 | 3 | ||
| 4 | import { messages as addItemReleaseViewMessages } from '../views/work/addItemReleaseViewLang' | 4 | import { messages as addItemReleaseViewMessages } from '../views/work/addItemReleaseViewLang' |
| 5 | +import { messages as editItemReleaseViewMessages } from '../views/work/editItemReleaseViewLang' | ||
| 6 | +import { messages as itemReleaseDetailMessages } from '../views/work/itemReleaseDetailLang' | ||
| 5 | export const messages = { | 7 | export const messages = { |
| 6 | zh: { | 8 | zh: { |
| 7 | ...itemReleaseTypeManageMessages.zh, | 9 | ...itemReleaseTypeManageMessages.zh, |
| 8 | ...itemReleaseManageMessages.zh, | 10 | ...itemReleaseManageMessages.zh, |
| 9 | ...addItemReleaseViewMessages.zh, | 11 | ...addItemReleaseViewMessages.zh, |
| 12 | + ...editItemReleaseViewMessages.zh, | ||
| 13 | + ...itemReleaseDetailMessages.zh, | ||
| 10 | }, | 14 | }, |
| 11 | en: { | 15 | en: { |
| 12 | ...itemReleaseTypeManageMessages.en, | 16 | ...itemReleaseTypeManageMessages.en, |
| 13 | ...itemReleaseManageMessages.en, | 17 | ...itemReleaseManageMessages.en, |
| 14 | ...addItemReleaseViewMessages.en, | 18 | ...addItemReleaseViewMessages.en, |
| 19 | + ...editItemReleaseViewMessages.en, | ||
| 20 | + ...itemReleaseDetailMessages.en, | ||
| 15 | } | 21 | } |
| 16 | } | 22 | } |
| 17 | \ No newline at end of file | 23 | \ No newline at end of file |
src/lang/owner/auditAuthOwnerUndoLang.js deleted
| 1 | -export const messages = { | ||
| 2 | - en: { | ||
| 3 | - auditAuthOwnerUndo: { | ||
| 4 | - title: 'Authentication Review', | ||
| 5 | - back: 'Back', | ||
| 6 | - roomNumber: 'Room Number:', | ||
| 7 | - roomArea: 'Room Area:', | ||
| 8 | - roomType: 'Room Type:', | ||
| 9 | - roomStatus: 'Room Status:', | ||
| 10 | - owner: 'Owner:', | ||
| 11 | - ownerPhone: 'Owner Phone:', | ||
| 12 | - authPerson: 'Authenticator:', | ||
| 13 | - housePersonnel: 'House Personnel', | ||
| 14 | - ownerFace: 'Owner Face', | ||
| 15 | - name: 'Name', | ||
| 16 | - contact: 'Contact', | ||
| 17 | - address: 'Address', | ||
| 18 | - idCard: 'ID Card', | ||
| 19 | - audit: 'Audit', | ||
| 20 | - action: 'Action', | ||
| 21 | - selectAudit: 'Please Audit', | ||
| 22 | - agree: 'Agree', | ||
| 23 | - reject: 'Reject', | ||
| 24 | - auditRemark: 'Audit Remark', | ||
| 25 | - requiredRemark: 'Required, please fill in the work order description', | ||
| 26 | - submit: 'Submit', | ||
| 27 | - submitSuccess: 'Submitted successfully', | ||
| 28 | - submitFailed: 'Submission failed:' | ||
| 29 | - } | ||
| 30 | - }, | ||
| 31 | - zh: { | ||
| 32 | - auditAuthOwnerUndo: { | ||
| 33 | - title: '认证审核', | ||
| 34 | - back: '返回', | ||
| 35 | - roomNumber: '房屋编号:', | ||
| 36 | - roomArea: '房屋面积:', | ||
| 37 | - roomType: '房屋类型:', | ||
| 38 | - roomStatus: '房屋状态:', | ||
| 39 | - owner: '业主:', | ||
| 40 | - ownerPhone: '业主电话:', | ||
| 41 | - authPerson: '认证人员:', | ||
| 42 | - housePersonnel: '房屋人员', | ||
| 43 | - ownerFace: '业主人脸', | ||
| 44 | - name: '姓名', | ||
| 45 | - contact: '联系方式', | ||
| 46 | - address: '家庭住址', | ||
| 47 | - idCard: '身份证', | ||
| 48 | - audit: '审核', | ||
| 49 | - action: '动作', | ||
| 50 | - selectAudit: '请审核', | ||
| 51 | - agree: '同意', | ||
| 52 | - reject: '拒绝', | ||
| 53 | - auditRemark: '审核说明', | ||
| 54 | - requiredRemark: '必填,请填写工单说明', | ||
| 55 | - submit: '提交', | ||
| 56 | - submitSuccess: '提交成功', | ||
| 57 | - submitFailed: '提交失败:' | ||
| 58 | - } | ||
| 59 | - } | ||
| 60 | -} | ||
| 61 | \ No newline at end of file | 0 | \ No newline at end of file |
src/router/workRouter.js
| @@ -14,4 +14,14 @@ export default [ | @@ -14,4 +14,14 @@ export default [ | ||
| 14 | name: '/views/work/addItemReleaseView', | 14 | name: '/views/work/addItemReleaseView', |
| 15 | component: () => import('@/views/work/addItemReleaseViewList.vue') | 15 | component: () => import('@/views/work/addItemReleaseViewList.vue') |
| 16 | }, | 16 | }, |
| 17 | + { | ||
| 18 | + path: '/views/work/editItemReleaseView', | ||
| 19 | + name: '/views/work/editItemReleaseView', | ||
| 20 | + component: () => import('@/views/work/editItemReleaseViewList.vue') | ||
| 21 | + }, | ||
| 22 | + { | ||
| 23 | + path: '/views/work/itemReleaseDetail', | ||
| 24 | + name: '/views/work/itemReleaseDetail', | ||
| 25 | + component: () => import('@/views/work/itemReleaseDetailList.vue') | ||
| 26 | + }, | ||
| 17 | ] | 27 | ] |
| 18 | \ No newline at end of file | 28 | \ No newline at end of file |
src/views/community/addCommunityPublicityList.vue
| 1 | <template> | 1 | <template> |
| 2 | <el-card class="add-publicity-container"> | 2 | <el-card class="add-publicity-container"> |
| 3 | - <div slot="header"> | 3 | + <div slot="header" class="flex justify-between"> |
| 4 | <span>{{ $t('addCommunityPublicity.title') }}</span> | 4 | <span>{{ $t('addCommunityPublicity.title') }}</span> |
| 5 | <el-button | 5 | <el-button |
| 6 | style="float: right; padding: 3px 0" | 6 | style="float: right; padding: 3px 0" |
src/views/community/editCommunityPublicityList.vue
| 1 | <template> | 1 | <template> |
| 2 | <div class="edit-community-publicity-container"> | 2 | <div class="edit-community-publicity-container"> |
| 3 | <el-card> | 3 | <el-card> |
| 4 | - <div slot="header" class="clearfix"> | 4 | + <div slot="header" class="flex justify-between"> |
| 5 | <span>{{ $t('editCommunityPublicity.title') }}</span> | 5 | <span>{{ $t('editCommunityPublicity.title') }}</span> |
| 6 | <el-button | 6 | <el-button |
| 7 | style="float: right; padding: 3px 0" | 7 | style="float: right; padding: 3px 0" |
src/views/work/addItemReleaseViewList.vue
| @@ -51,7 +51,7 @@ | @@ -51,7 +51,7 @@ | ||
| 51 | </el-col> | 51 | </el-col> |
| 52 | <el-col :span="12"> | 52 | <el-col :span="12"> |
| 53 | <el-form-item :label="$t('addItemReleaseView.passTime')"> | 53 | <el-form-item :label="$t('addItemReleaseView.passTime')"> |
| 54 | - <el-date-picker v-model="form.passTime" type="datetime" style="width:100%" | 54 | + <el-date-picker v-model="form.passTime" type="datetime" style="width:100%" value-format="yyyy-MM-dd HH:mm:ss" |
| 55 | :placeholder="$t('addItemReleaseView.requiredPassTime')" /> | 55 | :placeholder="$t('addItemReleaseView.requiredPassTime')" /> |
| 56 | </el-form-item> | 56 | </el-form-item> |
| 57 | </el-col> | 57 | </el-col> |
| @@ -134,7 +134,7 @@ | @@ -134,7 +134,7 @@ | ||
| 134 | </el-col> | 134 | </el-col> |
| 135 | </el-row> | 135 | </el-row> |
| 136 | 136 | ||
| 137 | - <SelectStaff ref="selectStaff" @select="handleStaffSelect" /> | 137 | + <SelectStaff ref="selectStaff" @selectStaff="handleStaffSelect" /> |
| 138 | 138 | ||
| 139 | <div class="mt-20 text-right"> | 139 | <div class="mt-20 text-right"> |
| 140 | <el-button type="warning" class="mr-20" @click="goBack"> | 140 | <el-button type="warning" class="mr-20" @click="goBack"> |
src/views/work/editItemReleaseViewLang.js
0 → 100644
| 1 | +export const messages = { | ||
| 2 | + en: { | ||
| 3 | + editItemReleaseView: { | ||
| 4 | + title: 'Edit Release', | ||
| 5 | + releaseType: 'Release Type', | ||
| 6 | + applyCompany: 'Apply Company', | ||
| 7 | + applyPerson: 'Applicant', | ||
| 8 | + idCard: 'ID Card', | ||
| 9 | + phone: 'Phone', | ||
| 10 | + passTime: 'Pass Time', | ||
| 11 | + carNum: 'Car Number', | ||
| 12 | + remark: 'Remark', | ||
| 13 | + releaseItems: 'Release Items', | ||
| 14 | + itemName: 'Item Name', | ||
| 15 | + itemAmount: 'Quantity', | ||
| 16 | + addItem: 'Add Item', | ||
| 17 | + selectReleaseType: 'Required, please select release type', | ||
| 18 | + inputApplyCompany: 'Required, please enter apply company', | ||
| 19 | + inputApplyPerson: 'Required, please enter applicant', | ||
| 20 | + inputIdCard: 'Required, please enter ID card', | ||
| 21 | + inputPhone: 'Required, please enter phone', | ||
| 22 | + selectPassTime: 'Required, please select pass time', | ||
| 23 | + inputCarNum: 'Optional, please enter car number', | ||
| 24 | + inputRemark: 'Optional, please enter remark', | ||
| 25 | + inputItemName: 'Required, please enter item name', | ||
| 26 | + inputItemAmount: 'Required, please enter quantity' | ||
| 27 | + } | ||
| 28 | + }, | ||
| 29 | + zh: { | ||
| 30 | + editItemReleaseView: { | ||
| 31 | + title: '编辑放行', | ||
| 32 | + releaseType: '放行类型', | ||
| 33 | + applyCompany: '申请单位', | ||
| 34 | + applyPerson: '申请人', | ||
| 35 | + idCard: '身份证', | ||
| 36 | + phone: '手机号', | ||
| 37 | + passTime: '通行时间', | ||
| 38 | + carNum: '车牌号', | ||
| 39 | + remark: '备注', | ||
| 40 | + releaseItems: '放行物品', | ||
| 41 | + itemName: '物品名称', | ||
| 42 | + itemAmount: '物品数量', | ||
| 43 | + addItem: '添加物品', | ||
| 44 | + selectReleaseType: '必填,请选择放行类型', | ||
| 45 | + inputApplyCompany: '必填,请填写申请单位', | ||
| 46 | + inputApplyPerson: '必填,请填写申请人', | ||
| 47 | + inputIdCard: '必填,请填写身份证', | ||
| 48 | + inputPhone: '必填,请填写手机号', | ||
| 49 | + selectPassTime: '必填,请选择通行时间', | ||
| 50 | + inputCarNum: '选填,请填写车牌号', | ||
| 51 | + inputRemark: '选填,请填写备注', | ||
| 52 | + inputItemName: '必填,请填写物品名称', | ||
| 53 | + inputItemAmount: '必填,请填写数量' | ||
| 54 | + } | ||
| 55 | + } | ||
| 56 | +} | ||
| 0 | \ No newline at end of file | 57 | \ No newline at end of file |
src/views/work/editItemReleaseViewList.vue
0 → 100644
| 1 | +<template> | ||
| 2 | + <div class="edit-item-release-container"> | ||
| 3 | + <el-card class="box-card"> | ||
| 4 | + <div slot="header" class="flex justify-between"> | ||
| 5 | + <span>{{ $t('editItemReleaseView.title') }}</span> | ||
| 6 | + <div> | ||
| 7 | + <el-button type="text" size="small" @click="goBack"> | ||
| 8 | + {{ $t('common.back') }} | ||
| 9 | + </el-button> | ||
| 10 | + </div> | ||
| 11 | + </div> | ||
| 12 | + | ||
| 13 | + <el-row :gutter="20"> | ||
| 14 | + <el-col :span="24"> | ||
| 15 | + <el-card shadow="never"> | ||
| 16 | + <el-form label-position="right" label-width="120px"> | ||
| 17 | + <el-row :gutter="20"> | ||
| 18 | + <el-col :span="12"> | ||
| 19 | + <el-form-item :label="$t('editItemReleaseView.releaseType')"> | ||
| 20 | + <el-select v-model="editItemReleaseViewInfo.typeId" disabled style="width:100%"> | ||
| 21 | + <el-option disabled value="" :label="$t('editItemReleaseView.selectReleaseType')" /> | ||
| 22 | + <template v-for="item in editItemReleaseViewInfo.itemReleaseTypes"> | ||
| 23 | + <el-option :key="item.typeId" :label="item.typeName" :value="item.typeId" | ||
| 24 | + v-if="item.state == 'C'" /> | ||
| 25 | + </template> | ||
| 26 | + </el-select> | ||
| 27 | + </el-form-item> | ||
| 28 | + </el-col> | ||
| 29 | + <el-col :span="12"> | ||
| 30 | + <el-form-item :label="$t('editItemReleaseView.applyCompany')"> | ||
| 31 | + <el-input v-model.trim="editItemReleaseViewInfo.applyCompany" | ||
| 32 | + :placeholder="$t('editItemReleaseView.inputApplyCompany')" /> | ||
| 33 | + </el-form-item> | ||
| 34 | + </el-col> | ||
| 35 | + </el-row> | ||
| 36 | + | ||
| 37 | + <el-row :gutter="20"> | ||
| 38 | + <el-col :span="12"> | ||
| 39 | + <el-form-item :label="$t('editItemReleaseView.applyPerson')"> | ||
| 40 | + <el-input v-model.trim="editItemReleaseViewInfo.applyPerson" | ||
| 41 | + :placeholder="$t('editItemReleaseView.inputApplyPerson')" /> | ||
| 42 | + </el-form-item> | ||
| 43 | + </el-col> | ||
| 44 | + <el-col :span="12"> | ||
| 45 | + <el-form-item :label="$t('editItemReleaseView.idCard')"> | ||
| 46 | + <el-input v-model.trim="editItemReleaseViewInfo.idCard" | ||
| 47 | + :placeholder="$t('editItemReleaseView.inputIdCard')" /> | ||
| 48 | + </el-form-item> | ||
| 49 | + </el-col> | ||
| 50 | + </el-row> | ||
| 51 | + | ||
| 52 | + <el-row :gutter="20"> | ||
| 53 | + <el-col :span="12"> | ||
| 54 | + <el-form-item :label="$t('editItemReleaseView.phone')"> | ||
| 55 | + <el-input v-model.trim="editItemReleaseViewInfo.applyTel" | ||
| 56 | + :placeholder="$t('editItemReleaseView.inputPhone')" /> | ||
| 57 | + </el-form-item> | ||
| 58 | + </el-col> | ||
| 59 | + <el-col :span="12"> | ||
| 60 | + <el-form-item :label="$t('editItemReleaseView.passTime')"> | ||
| 61 | + <el-date-picker v-model="editItemReleaseViewInfo.passTime" type="datetime" | ||
| 62 | + :placeholder="$t('editItemReleaseView.selectPassTime')" style="width:100%" /> | ||
| 63 | + </el-form-item> | ||
| 64 | + </el-col> | ||
| 65 | + </el-row> | ||
| 66 | + | ||
| 67 | + <el-row :gutter="20"> | ||
| 68 | + <el-col :span="12"> | ||
| 69 | + <el-form-item :label="$t('editItemReleaseView.carNum')"> | ||
| 70 | + <el-input v-model.trim="editItemReleaseViewInfo.carNum" | ||
| 71 | + :placeholder="$t('editItemReleaseView.inputCarNum')" /> | ||
| 72 | + </el-form-item> | ||
| 73 | + </el-col> | ||
| 74 | + <el-col :span="12"> | ||
| 75 | + <el-form-item :label="$t('editItemReleaseView.remark')"> | ||
| 76 | + <el-input v-model.trim="editItemReleaseViewInfo.remark" type="textarea" | ||
| 77 | + :placeholder="$t('editItemReleaseView.inputRemark')" /> | ||
| 78 | + </el-form-item> | ||
| 79 | + </el-col> | ||
| 80 | + </el-row> | ||
| 81 | + </el-form> | ||
| 82 | + </el-card> | ||
| 83 | + </el-col> | ||
| 84 | + </el-row> | ||
| 85 | + | ||
| 86 | + <el-row :gutter="20" class="margin-top"> | ||
| 87 | + <el-col :span="24"> | ||
| 88 | + <el-card shadow="never"> | ||
| 89 | + <div slot="header" class="clearfix"> | ||
| 90 | + <span>{{ $t('editItemReleaseView.releaseItems') }}</span> | ||
| 91 | + <el-button type="primary" size="small" style="float: right;" @click="addResName"> | ||
| 92 | + <i class="el-icon-plus"></i> | ||
| 93 | + {{ $t('editItemReleaseView.addItem') }} | ||
| 94 | + </el-button> | ||
| 95 | + </div> | ||
| 96 | + | ||
| 97 | + <el-table :data="editItemReleaseViewInfo.resNames" border style="width: 100%"> | ||
| 98 | + <el-table-column :label="$t('editItemReleaseView.itemName')" align="center"> | ||
| 99 | + <template slot-scope="scope"> | ||
| 100 | + <el-input v-model.trim="scope.row.resName" :placeholder="$t('editItemReleaseView.inputItemName')" /> | ||
| 101 | + </template> | ||
| 102 | + </el-table-column> | ||
| 103 | + <el-table-column :label="$t('editItemReleaseView.itemAmount')" align="center"> | ||
| 104 | + <template slot-scope="scope"> | ||
| 105 | + <el-input v-model.trim="scope.row.amount" type="number" | ||
| 106 | + :placeholder="$t('editItemReleaseView.inputItemAmount')" /> | ||
| 107 | + </template> | ||
| 108 | + </el-table-column> | ||
| 109 | + <el-table-column :label="$t('common.operation')" align="center" width="120"> | ||
| 110 | + <template slot-scope="scope"> | ||
| 111 | + <el-button type="danger" size="mini" @click="removeResName(scope.row.resName)"> | ||
| 112 | + {{ $t('common.delete') }} | ||
| 113 | + </el-button> | ||
| 114 | + </template> | ||
| 115 | + </el-table-column> | ||
| 116 | + </el-table> | ||
| 117 | + </el-card> | ||
| 118 | + </el-col> | ||
| 119 | + </el-row> | ||
| 120 | + | ||
| 121 | + <div class="action-buttons"> | ||
| 122 | + <el-button type="primary" @click="updateItemReleaseInfo"> | ||
| 123 | + {{ $t('common.submit') }} | ||
| 124 | + </el-button> | ||
| 125 | + <el-button type="warning" @click="goBack"> | ||
| 126 | + {{ $t('common.cancel') }} | ||
| 127 | + </el-button> | ||
| 128 | + </div> | ||
| 129 | + </el-card> | ||
| 130 | + </div> | ||
| 131 | +</template> | ||
| 132 | + | ||
| 133 | +<script> | ||
| 134 | +import { getCommunityId } from '@/api/community/communityApi' | ||
| 135 | +import { | ||
| 136 | + updateItemRelease, | ||
| 137 | + listItemReleaseType, | ||
| 138 | + listItemRelease, | ||
| 139 | + listItemReleaseRes | ||
| 140 | +} from '@/api/work/editItemReleaseViewApi' | ||
| 141 | + | ||
| 142 | +export default { | ||
| 143 | + name: 'EditItemReleaseView', | ||
| 144 | + data() { | ||
| 145 | + return { | ||
| 146 | + editItemReleaseViewInfo: { | ||
| 147 | + irId: '', | ||
| 148 | + typeId: '', | ||
| 149 | + applyCompany: '', | ||
| 150 | + applyPerson: '', | ||
| 151 | + idCard: '', | ||
| 152 | + applyTel: '', | ||
| 153 | + passTime: '', | ||
| 154 | + resNames: [], | ||
| 155 | + state: '', | ||
| 156 | + carNum: '', | ||
| 157 | + remark: '', | ||
| 158 | + itemReleaseTypes: [] | ||
| 159 | + }, | ||
| 160 | + communityId: '' | ||
| 161 | + } | ||
| 162 | + }, | ||
| 163 | + created() { | ||
| 164 | + this.communityId = getCommunityId() | ||
| 165 | + this.editItemReleaseViewInfo.irId = this.$route.query.irId | ||
| 166 | + this.listItemReleaseTypes() | ||
| 167 | + this.listItemReleases() | ||
| 168 | + this.loadItemReleaseRes() | ||
| 169 | + }, | ||
| 170 | + methods: { | ||
| 171 | + goBack() { | ||
| 172 | + this.$router.go(-1) | ||
| 173 | + }, | ||
| 174 | + validateForm() { | ||
| 175 | + // 这里添加表单验证逻辑 | ||
| 176 | + return true | ||
| 177 | + }, | ||
| 178 | + async updateItemReleaseInfo() { | ||
| 179 | + if (!this.validateForm()) { | ||
| 180 | + return | ||
| 181 | + } | ||
| 182 | + | ||
| 183 | + try { | ||
| 184 | + this.editItemReleaseViewInfo.communityId = this.communityId | ||
| 185 | + const res = await updateItemRelease(this.editItemReleaseViewInfo) | ||
| 186 | + if (res.code === 0) { | ||
| 187 | + this.$message.success(this.$t('common.updateSuccess')) | ||
| 188 | + this.goBack() | ||
| 189 | + } else { | ||
| 190 | + this.$message.error(res.msg) | ||
| 191 | + } | ||
| 192 | + } catch (error) { | ||
| 193 | + this.$message.error(this.$t('common.updateFailed')) | ||
| 194 | + } | ||
| 195 | + }, | ||
| 196 | + async listItemReleaseTypes() { | ||
| 197 | + try { | ||
| 198 | + const params = { | ||
| 199 | + page: 1, | ||
| 200 | + row: 100, | ||
| 201 | + communityId: this.communityId | ||
| 202 | + } | ||
| 203 | + const res = await listItemReleaseType(params) | ||
| 204 | + this.editItemReleaseViewInfo.itemReleaseTypes = res.data | ||
| 205 | + } catch (error) { | ||
| 206 | + console.error('Failed to fetch item release types:', error) | ||
| 207 | + } | ||
| 208 | + }, | ||
| 209 | + addResName() { | ||
| 210 | + this.editItemReleaseViewInfo.resNames.push({ | ||
| 211 | + resName: '', | ||
| 212 | + amount: '' | ||
| 213 | + }) | ||
| 214 | + }, | ||
| 215 | + removeResName(resName) { | ||
| 216 | + this.editItemReleaseViewInfo.resNames = this.editItemReleaseViewInfo.resNames.filter( | ||
| 217 | + item => item.resName !== resName | ||
| 218 | + ) | ||
| 219 | + }, | ||
| 220 | + async listItemReleases() { | ||
| 221 | + try { | ||
| 222 | + const params = { | ||
| 223 | + page: 1, | ||
| 224 | + row: 1, | ||
| 225 | + communityId: this.communityId, | ||
| 226 | + irId: this.editItemReleaseViewInfo.irId | ||
| 227 | + } | ||
| 228 | + const res = await listItemRelease(params) | ||
| 229 | + if (res.data && res.data.length > 0) { | ||
| 230 | + Object.assign(this.editItemReleaseViewInfo, res.data[0]) | ||
| 231 | + } | ||
| 232 | + } catch (error) { | ||
| 233 | + console.error('Failed to fetch item releases:', error) | ||
| 234 | + } | ||
| 235 | + }, | ||
| 236 | + async loadItemReleaseRes() { | ||
| 237 | + try { | ||
| 238 | + const params = { | ||
| 239 | + page: 1, | ||
| 240 | + row: 500, | ||
| 241 | + communityId: this.communityId, | ||
| 242 | + irId: this.editItemReleaseViewInfo.irId | ||
| 243 | + } | ||
| 244 | + const res = await listItemReleaseRes(params) | ||
| 245 | + this.editItemReleaseViewInfo.resNames = res.data | ||
| 246 | + } catch (error) { | ||
| 247 | + console.error('Failed to fetch item release resources:', error) | ||
| 248 | + } | ||
| 249 | + } | ||
| 250 | + } | ||
| 251 | +} | ||
| 252 | +</script> | ||
| 253 | + | ||
| 254 | +<style lang="scss" scoped> | ||
| 255 | +.edit-item-release-container { | ||
| 256 | + padding: 20px; | ||
| 257 | + | ||
| 258 | + .box-card { | ||
| 259 | + margin-bottom: 20px; | ||
| 260 | + } | ||
| 261 | + | ||
| 262 | + .header-tools { | ||
| 263 | + float: right; | ||
| 264 | + } | ||
| 265 | + | ||
| 266 | + .margin-top { | ||
| 267 | + margin-top: 20px; | ||
| 268 | + } | ||
| 269 | + | ||
| 270 | + .action-buttons { | ||
| 271 | + margin-top: 20px; | ||
| 272 | + text-align: right; | ||
| 273 | + | ||
| 274 | + .el-button { | ||
| 275 | + margin-left: 10px; | ||
| 276 | + } | ||
| 277 | + } | ||
| 278 | +} | ||
| 279 | +</style> | ||
| 0 | \ No newline at end of file | 280 | \ No newline at end of file |
src/views/work/itemReleaseDetailLang.js
0 → 100644
| 1 | +export const messages = { | ||
| 2 | + en: { | ||
| 3 | + itemReleaseDetail: { | ||
| 4 | + releaseDetails: 'Release Details', | ||
| 5 | + back: 'Back', | ||
| 6 | + applyCompany: 'Application Unit:', | ||
| 7 | + passType: 'Pass Type:', | ||
| 8 | + applicant: 'Applicant:', | ||
| 9 | + idCard: 'ID Card:', | ||
| 10 | + phone: 'Phone:', | ||
| 11 | + applyTime: 'Application Time:', | ||
| 12 | + status: 'Status:', | ||
| 13 | + licensePlate: 'License Plate:', | ||
| 14 | + passTime: 'Pass Time:', | ||
| 15 | + totalQuantity: 'Total Quantity:', | ||
| 16 | + releaseItems: 'Release Items', | ||
| 17 | + itemName: 'Item Name', | ||
| 18 | + quantity: 'Quantity', | ||
| 19 | + workflowProcess: 'Workflow Process', | ||
| 20 | + serialNumber: 'No.', | ||
| 21 | + department: 'Department', | ||
| 22 | + handler: 'Handler', | ||
| 23 | + processed: 'Processed', | ||
| 24 | + processing: 'Processing', | ||
| 25 | + timeConsumed: 'Time Consumed', | ||
| 26 | + comment: 'Comment', | ||
| 27 | + workOrderProcessing: 'Work Order Processing', | ||
| 28 | + action: 'Action', | ||
| 29 | + pleaseSelect: 'Please Select', | ||
| 30 | + agree: 'Agree', | ||
| 31 | + return: 'Return', | ||
| 32 | + returnToSubmitter: 'Return to Submitter', | ||
| 33 | + transfer: 'Transfer', | ||
| 34 | + workOrderDescription: 'Work Order Description', | ||
| 35 | + requiredDescription: 'Required, please fill in work order description', | ||
| 36 | + nextHandler: 'Next Handler', | ||
| 37 | + requiredNextHandler: 'Required, please select next handler', | ||
| 38 | + select: 'Select', | ||
| 39 | + submit: 'Submit', | ||
| 40 | + flowChart: 'Flow Chart', | ||
| 41 | + illegalOperation: 'Illegal operation', | ||
| 42 | + selectStatus: 'Please select status', | ||
| 43 | + fillDescription: 'Please fill in description', | ||
| 44 | + selectNextHandler: 'Please select next handler', | ||
| 45 | + submitSuccess: 'Submit successfully', | ||
| 46 | + submitFailed: 'Submit failed', | ||
| 47 | + administrator: 'Administrator' | ||
| 48 | + } | ||
| 49 | + }, | ||
| 50 | + zh: { | ||
| 51 | + itemReleaseDetail: { | ||
| 52 | + releaseDetails: '放行详情', | ||
| 53 | + back: '返回', | ||
| 54 | + applyCompany: '申请单位:', | ||
| 55 | + passType: '通行类型:', | ||
| 56 | + applicant: '申请人:', | ||
| 57 | + idCard: '身份证:', | ||
| 58 | + phone: '手机号:', | ||
| 59 | + applyTime: '申请时间:', | ||
| 60 | + status: '状态:', | ||
| 61 | + licensePlate: '车牌号:', | ||
| 62 | + passTime: '通行时间:', | ||
| 63 | + totalQuantity: '物品总数量:', | ||
| 64 | + releaseItems: '放行物品', | ||
| 65 | + itemName: '物品名称', | ||
| 66 | + quantity: '数量', | ||
| 67 | + workflowProcess: '工单流转', | ||
| 68 | + serialNumber: '序号', | ||
| 69 | + department: '部门', | ||
| 70 | + handler: '处理人', | ||
| 71 | + processed: '处理完成', | ||
| 72 | + processing: '正在处理', | ||
| 73 | + timeConsumed: '耗时', | ||
| 74 | + comment: '意见', | ||
| 75 | + workOrderProcessing: '工单办理', | ||
| 76 | + action: '动作', | ||
| 77 | + pleaseSelect: '请选择', | ||
| 78 | + agree: '同意', | ||
| 79 | + return: '退回', | ||
| 80 | + returnToSubmitter: '退回至提交者', | ||
| 81 | + transfer: '转单', | ||
| 82 | + workOrderDescription: '工单说明', | ||
| 83 | + requiredDescription: '必填,请填写工单说明', | ||
| 84 | + nextHandler: '下一处理人', | ||
| 85 | + requiredNextHandler: '必填,请选择下一处理人', | ||
| 86 | + select: '选择', | ||
| 87 | + submit: '提交', | ||
| 88 | + flowChart: '流程图', | ||
| 89 | + illegalOperation: '非法操作', | ||
| 90 | + selectStatus: '请选择状态', | ||
| 91 | + fillDescription: '请填写说明', | ||
| 92 | + selectNextHandler: '请选择下一节点处理人', | ||
| 93 | + submitSuccess: '提交成功', | ||
| 94 | + submitFailed: '提交失败', | ||
| 95 | + administrator: '管理员' | ||
| 96 | + } | ||
| 97 | + } | ||
| 98 | +} | ||
| 0 | \ No newline at end of file | 99 | \ No newline at end of file |
src/views/work/itemReleaseDetailList.vue
0 → 100644
| 1 | +<template> | ||
| 2 | + <div class="item-release-detail-container"> | ||
| 3 | + <!-- 放行详情 --> | ||
| 4 | + <el-row> | ||
| 5 | + <el-col :span="24"> | ||
| 6 | + <el-card> | ||
| 7 | + <div slot="header" class="flex justify-between"> | ||
| 8 | + <span>{{ $t('itemReleaseDetail.releaseDetails') }}</span> | ||
| 9 | + <div class="card-header-right"> | ||
| 10 | + <el-button type="primary" size="small" @click="_goBack">{{ $t('itemReleaseDetail.back') }}</el-button> | ||
| 11 | + </div> | ||
| 12 | + </div> | ||
| 13 | + <div v-if="itemReleaseDetailInfo.pools"> | ||
| 14 | + <el-row :gutter="20"> | ||
| 15 | + <el-col :span="8"> | ||
| 16 | + <div class="form-group"> | ||
| 17 | + <label class="form-label">{{ $t('itemReleaseDetail.applyCompany') }}</label> | ||
| 18 | + <div class="form-content">{{ itemReleaseDetailInfo.pools.applyCompany }}</div> | ||
| 19 | + </div> | ||
| 20 | + </el-col> | ||
| 21 | + <el-col :span="8"> | ||
| 22 | + <div class="form-group"> | ||
| 23 | + <label class="form-label">{{ $t('itemReleaseDetail.passType') }}</label> | ||
| 24 | + <div class="form-content">{{ itemReleaseDetailInfo.pools.typeName }}</div> | ||
| 25 | + </div> | ||
| 26 | + </el-col> | ||
| 27 | + <el-col :span="8"> | ||
| 28 | + <div class="form-group"> | ||
| 29 | + <label class="form-label">{{ $t('itemReleaseDetail.applicant') }}</label> | ||
| 30 | + <div class="form-content">{{ itemReleaseDetailInfo.pools.applyPerson }}</div> | ||
| 31 | + </div> | ||
| 32 | + </el-col> | ||
| 33 | + <el-col :span="8"> | ||
| 34 | + <div class="form-group"> | ||
| 35 | + <label class="form-label">{{ $t('itemReleaseDetail.idCard') }}</label> | ||
| 36 | + <div class="form-content">{{ itemReleaseDetailInfo.pools.idCard }}</div> | ||
| 37 | + </div> | ||
| 38 | + </el-col> | ||
| 39 | + <el-col :span="8"> | ||
| 40 | + <div class="form-group"> | ||
| 41 | + <label class="form-label">{{ $t('itemReleaseDetail.phone') }}</label> | ||
| 42 | + <div class="form-content">{{ itemReleaseDetailInfo.pools.applyTel }}</div> | ||
| 43 | + </div> | ||
| 44 | + </el-col> | ||
| 45 | + <el-col :span="8"> | ||
| 46 | + <div class="form-group"> | ||
| 47 | + <label class="form-label">{{ $t('itemReleaseDetail.applyTime') }}</label> | ||
| 48 | + <div class="form-content">{{ itemReleaseDetailInfo.pools.createTime }}</div> | ||
| 49 | + </div> | ||
| 50 | + </el-col> | ||
| 51 | + <el-col :span="8"> | ||
| 52 | + <div class="form-group"> | ||
| 53 | + <label class="form-label">{{ $t('itemReleaseDetail.status') }}</label> | ||
| 54 | + <div class="form-content">{{ itemReleaseDetailInfo.pools.stateName }}</div> | ||
| 55 | + </div> | ||
| 56 | + </el-col> | ||
| 57 | + <el-col :span="8"> | ||
| 58 | + <div class="form-group"> | ||
| 59 | + <label class="form-label">{{ $t('itemReleaseDetail.licensePlate') }}</label> | ||
| 60 | + <div class="form-content">{{ itemReleaseDetailInfo.pools.carNum }}</div> | ||
| 61 | + </div> | ||
| 62 | + </el-col> | ||
| 63 | + <el-col :span="8"> | ||
| 64 | + <div class="form-group"> | ||
| 65 | + <label class="form-label">{{ $t('itemReleaseDetail.passTime') }}</label> | ||
| 66 | + <div class="form-content">{{ itemReleaseDetailInfo.pools.passTime }}</div> | ||
| 67 | + </div> | ||
| 68 | + </el-col> | ||
| 69 | + <el-col :span="8"> | ||
| 70 | + <div class="form-group"> | ||
| 71 | + <label class="form-label">{{ $t('itemReleaseDetail.totalQuantity') }}</label> | ||
| 72 | + <div class="form-content">{{ itemReleaseDetailInfo.pools.amount }}</div> | ||
| 73 | + </div> | ||
| 74 | + </el-col> | ||
| 75 | + </el-row> | ||
| 76 | + </div> | ||
| 77 | + </el-card> | ||
| 78 | + </el-col> | ||
| 79 | + </el-row> | ||
| 80 | + | ||
| 81 | + <!-- 放行物品 --> | ||
| 82 | + <el-row> | ||
| 83 | + <el-col :span="24"> | ||
| 84 | + <el-card> | ||
| 85 | + <div slot="header" class="flex justify-between"> | ||
| 86 | + <span>{{ $t('itemReleaseDetail.releaseItems') }}</span> | ||
| 87 | + </div> | ||
| 88 | + <el-table :data="itemReleaseDetailInfo.resNames" border style="width: 100%"> | ||
| 89 | + <el-table-column prop="resName" :label="$t('itemReleaseDetail.itemName')" align="center" /> | ||
| 90 | + <el-table-column prop="amount" :label="$t('itemReleaseDetail.quantity')" align="center" /> | ||
| 91 | + </el-table> | ||
| 92 | + </el-card> | ||
| 93 | + </el-col> | ||
| 94 | + </el-row> | ||
| 95 | + | ||
| 96 | + <!-- 工单流转 --> | ||
| 97 | + <el-row> | ||
| 98 | + <el-col :span="24"> | ||
| 99 | + <el-card> | ||
| 100 | + <div slot="header" class="flex justify-between"> | ||
| 101 | + <span>{{ $t('itemReleaseDetail.workflowProcess') }}</span> | ||
| 102 | + </div> | ||
| 103 | + <el-table :data="itemReleaseDetailInfo.comments" border style="width: 100%"> | ||
| 104 | + <el-table-column type="index" :label="$t('itemReleaseDetail.serialNumber')" align="center" width="80" /> | ||
| 105 | + <el-table-column prop="orgName" :label="$t('itemReleaseDetail.department')" align="center"> | ||
| 106 | + <template slot-scope="scope"> | ||
| 107 | + {{ scope.row.orgName || $t('itemReleaseDetail.administrator') }} | ||
| 108 | + </template> | ||
| 109 | + </el-table-column> | ||
| 110 | + <el-table-column prop="staffName" :label="$t('itemReleaseDetail.handler')" align="center" /> | ||
| 111 | + <el-table-column :label="$t('itemReleaseDetail.status')" align="center"> | ||
| 112 | + <template slot-scope="scope"> | ||
| 113 | + {{ scope.row.endTime ? $t('itemReleaseDetail.processed') : $t('itemReleaseDetail.processing') }} | ||
| 114 | + </template> | ||
| 115 | + </el-table-column> | ||
| 116 | + <el-table-column prop="duration" :label="$t('itemReleaseDetail.timeConsumed')" align="center" /> | ||
| 117 | + <el-table-column prop="context" :label="$t('itemReleaseDetail.comment')" align="center" /> | ||
| 118 | + </el-table> | ||
| 119 | + </el-card> | ||
| 120 | + </el-col> | ||
| 121 | + </el-row> | ||
| 122 | + | ||
| 123 | + <!-- 工单办理 --> | ||
| 124 | + <el-row v-if="itemReleaseDetailInfo.action"> | ||
| 125 | + <el-col :span="24"> | ||
| 126 | + <el-card> | ||
| 127 | + <div slot="header" class="flex justify-between"> | ||
| 128 | + <span>{{ $t('itemReleaseDetail.workOrderProcessing') }}</span> | ||
| 129 | + </div> | ||
| 130 | + <el-form label-width="120px"> | ||
| 131 | + <el-form-item :label="$t('itemReleaseDetail.action')"> | ||
| 132 | + <el-select v-model="itemReleaseDetailInfo.audit.auditCode" style="width:100%"> | ||
| 133 | + <el-option :label="$t('itemReleaseDetail.pleaseSelect')" value="" disabled /> | ||
| 134 | + <el-option v-if="itemReleaseDetailInfo.nextAudit.next || itemReleaseDetailInfo.nextAudit.exit" | ||
| 135 | + value="1100" :label="$t('itemReleaseDetail.agree')" /> | ||
| 136 | + <el-option v-if="itemReleaseDetailInfo.nextAudit.back" value="1200" | ||
| 137 | + :label="$t('itemReleaseDetail.return')" /> | ||
| 138 | + <el-option v-if="itemReleaseDetailInfo.nextAudit.backIndex" value="1400" | ||
| 139 | + :label="$t('itemReleaseDetail.returnToSubmitter')" /> | ||
| 140 | + <el-option value="1300" :label="$t('itemReleaseDetail.transfer')" /> | ||
| 141 | + </el-select> | ||
| 142 | + </el-form-item> | ||
| 143 | + <el-form-item :label="$t('itemReleaseDetail.workOrderDescription')"> | ||
| 144 | + <el-input type="textarea" :placeholder="$t('itemReleaseDetail.requiredDescription')" | ||
| 145 | + v-model="itemReleaseDetailInfo.audit.auditMessage" /> | ||
| 146 | + </el-form-item> | ||
| 147 | + <!-- 下一处理人 --> | ||
| 148 | + <el-form-item v-if="(itemReleaseDetailInfo.audit.auditCode == '1100' && itemReleaseDetailInfo.nextAudit.assignee == '-2') || | ||
| 149 | + itemReleaseDetailInfo.audit.auditCode == '1300'" :label="$t('itemReleaseDetail.nextHandler')"> | ||
| 150 | + <el-input v-model="itemReleaseDetailInfo.audit.staffName" | ||
| 151 | + :placeholder="$t('itemReleaseDetail.requiredNextHandler')" disabled style="width: calc(100% - 120px)" /> | ||
| 152 | + <el-button style="width: 120px" @click="chooseStaff">{{ $t('itemReleaseDetail.select') }}</el-button> | ||
| 153 | + </el-form-item> | ||
| 154 | + <el-form-item> | ||
| 155 | + <el-button type="primary" @click="_auditSubmit">{{ $t('itemReleaseDetail.submit') }}</el-button> | ||
| 156 | + </el-form-item> | ||
| 157 | + </el-form> | ||
| 158 | + </el-card> | ||
| 159 | + </el-col> | ||
| 160 | + </el-row> | ||
| 161 | + | ||
| 162 | + <!-- 流程图 --> | ||
| 163 | + <el-row> | ||
| 164 | + <el-col :span="24"> | ||
| 165 | + <el-card> | ||
| 166 | + <div slot="header" class="flex justify-between"> | ||
| 167 | + <span>{{ $t('itemReleaseDetail.flowChart') }}</span> | ||
| 168 | + </div> | ||
| 169 | + <div class="text-center"> | ||
| 170 | + <img :src="itemReleaseDetailInfo.imgData" alt="" style="height:300px"> | ||
| 171 | + </div> | ||
| 172 | + </el-card> | ||
| 173 | + </el-col> | ||
| 174 | + </el-row> | ||
| 175 | + | ||
| 176 | + <!-- 选择员工组件 --> | ||
| 177 | + <select-staff ref="selectStaff" @selectStaff="handleStaffSelect" /> | ||
| 178 | + </div> | ||
| 179 | +</template> | ||
| 180 | + | ||
| 181 | +<script> | ||
| 182 | +import { getCommunityId } from '@/api/community/communityApi' | ||
| 183 | +import SelectStaff from '@/components/staff/SelectStaff' | ||
| 184 | +import { | ||
| 185 | + listItemReleaseRes, | ||
| 186 | + listItemRelease, | ||
| 187 | + auditUndoItemRelease | ||
| 188 | +} from '@/api/work/itemReleaseDetailApi' | ||
| 189 | + | ||
| 190 | +export default { | ||
| 191 | + name: 'ItemReleaseDetailList', | ||
| 192 | + components: { | ||
| 193 | + SelectStaff | ||
| 194 | + }, | ||
| 195 | + data() { | ||
| 196 | + return { | ||
| 197 | + communityId: '', | ||
| 198 | + itemReleaseDetailInfo: { | ||
| 199 | + irId: '', | ||
| 200 | + flowId: '', | ||
| 201 | + pools: {}, | ||
| 202 | + resNames: [], | ||
| 203 | + comments: [], | ||
| 204 | + action: '', | ||
| 205 | + audit: { | ||
| 206 | + auditCode: '1100', | ||
| 207 | + auditMessage: '', | ||
| 208 | + staffId: '', | ||
| 209 | + staffName: '', | ||
| 210 | + taskId: '' | ||
| 211 | + }, | ||
| 212 | + imgData: '', | ||
| 213 | + nextAudit: {}, | ||
| 214 | + files: [] | ||
| 215 | + } | ||
| 216 | + } | ||
| 217 | + }, | ||
| 218 | + created() { | ||
| 219 | + this.communityId = getCommunityId() | ||
| 220 | + this.initData() | ||
| 221 | + }, | ||
| 222 | + methods: { | ||
| 223 | + initData() { | ||
| 224 | + const irId = this.$route.query.irId | ||
| 225 | + if (!irId) { | ||
| 226 | + this.$message.error(this.$t('itemReleaseDetail.illegalOperation')) | ||
| 227 | + return | ||
| 228 | + } | ||
| 229 | + this.itemReleaseDetailInfo.irId = irId | ||
| 230 | + this.itemReleaseDetailInfo.flowId = this.$route.query.flowId | ||
| 231 | + this.itemReleaseDetailInfo.action = this.$route.query.action | ||
| 232 | + this.itemReleaseDetailInfo.audit.taskId = this.$route.query.taskId | ||
| 233 | + | ||
| 234 | + this._listOaWorkflowDetails() | ||
| 235 | + this._loadItemReleaseRes() | ||
| 236 | + this._loadComments() | ||
| 237 | + this._openNewOaWorkflowDetailImg() | ||
| 238 | + }, | ||
| 239 | + async _loadItemReleaseRes() { | ||
| 240 | + try { | ||
| 241 | + const { data } = await listItemReleaseRes({ | ||
| 242 | + page: 1, | ||
| 243 | + row: 500, | ||
| 244 | + communityId: this.communityId, | ||
| 245 | + irId: this.itemReleaseDetailInfo.irId | ||
| 246 | + }) | ||
| 247 | + this.itemReleaseDetailInfo.resNames = data | ||
| 248 | + } catch (error) { | ||
| 249 | + console.error('获取放行物品失败:', error) | ||
| 250 | + } | ||
| 251 | + }, | ||
| 252 | + async _listOaWorkflowDetails() { | ||
| 253 | + try { | ||
| 254 | + const { data } = await listItemRelease({ | ||
| 255 | + page: 1, | ||
| 256 | + row: 1, | ||
| 257 | + irId: this.itemReleaseDetailInfo.irId, | ||
| 258 | + flowId: this.itemReleaseDetailInfo.flowId, | ||
| 259 | + communityId: this.communityId | ||
| 260 | + }) | ||
| 261 | + this.itemReleaseDetailInfo.pools = data[0] | ||
| 262 | + if (this.itemReleaseDetailInfo.action) { | ||
| 263 | + this._loadNextAuditPerson() | ||
| 264 | + } | ||
| 265 | + } catch (error) { | ||
| 266 | + console.error('获取放行详情失败:', error) | ||
| 267 | + } | ||
| 268 | + }, | ||
| 269 | + _loadComments() { | ||
| 270 | + // TODO: 需要实现工单评论接口 | ||
| 271 | + console.log('加载评论') | ||
| 272 | + }, | ||
| 273 | + _goBack() { | ||
| 274 | + this.$router.go(-1) | ||
| 275 | + }, | ||
| 276 | + chooseStaff() { | ||
| 277 | + this.$refs.selectStaff.open(this.itemReleaseDetailInfo.audit) | ||
| 278 | + }, | ||
| 279 | + async _auditSubmit() { | ||
| 280 | + const _audit = this.itemReleaseDetailInfo.audit | ||
| 281 | + _audit.flowId = this.itemReleaseDetailInfo.flowId | ||
| 282 | + _audit.irId = this.itemReleaseDetailInfo.irId | ||
| 283 | + | ||
| 284 | + if (this.itemReleaseDetailInfo.nextAudit.assignee != '-2') { | ||
| 285 | + _audit.staffId = this.itemReleaseDetailInfo.nextAudit.assignee | ||
| 286 | + } | ||
| 287 | + | ||
| 288 | + if (!_audit.auditCode) { | ||
| 289 | + this.$message.error(this.$t('itemReleaseDetail.selectStatus')) | ||
| 290 | + return | ||
| 291 | + } | ||
| 292 | + if (!_audit.auditMessage) { | ||
| 293 | + this.$message.error(this.$t('itemReleaseDetail.fillDescription')) | ||
| 294 | + return | ||
| 295 | + } | ||
| 296 | + if (_audit.auditCode != '1200' && _audit.auditCode != '1400' && !_audit.staffId) { | ||
| 297 | + this.$message.error(this.$t('itemReleaseDetail.selectNextHandler')) | ||
| 298 | + return | ||
| 299 | + } | ||
| 300 | + | ||
| 301 | + try { | ||
| 302 | + await auditUndoItemRelease(_audit) | ||
| 303 | + this.$message.success(this.$t('itemReleaseDetail.submitSuccess')) | ||
| 304 | + this._goBack() | ||
| 305 | + } catch (error) { | ||
| 306 | + this.$message.error(error.message || this.$t('itemReleaseDetail.submitFailed')) | ||
| 307 | + } | ||
| 308 | + }, | ||
| 309 | + _loadNextAuditPerson() { | ||
| 310 | + // TODO: 需要实现获取下一处理人接口 | ||
| 311 | + console.log('加载下一处理人') | ||
| 312 | + }, | ||
| 313 | + _openNewOaWorkflowDetailImg() { | ||
| 314 | + // TODO: 需要实现获取流程图接口 | ||
| 315 | + console.log('加载流程图') | ||
| 316 | + }, | ||
| 317 | + handleStaffSelect(staff) { | ||
| 318 | + this.itemReleaseDetailInfo.audit.staffId = staff.staffId | ||
| 319 | + this.itemReleaseDetailInfo.audit.staffName = staff.staffName | ||
| 320 | + } | ||
| 321 | + } | ||
| 322 | +} | ||
| 323 | +</script> | ||
| 324 | + | ||
| 325 | +<style lang="scss" scoped> | ||
| 326 | +.item-release-detail-container { | ||
| 327 | + padding: 20px; | ||
| 328 | + | ||
| 329 | + .el-row { | ||
| 330 | + margin-bottom: 20px; | ||
| 331 | + | ||
| 332 | + &:last-child { | ||
| 333 | + margin-bottom: 0; | ||
| 334 | + } | ||
| 335 | + } | ||
| 336 | + | ||
| 337 | + .form-group { | ||
| 338 | + margin-bottom: 20px; | ||
| 339 | + display: flex; | ||
| 340 | + justify-content: flex-start; | ||
| 341 | + | ||
| 342 | + .form-label { | ||
| 343 | + margin-bottom: 5px; | ||
| 344 | + color: #606266; | ||
| 345 | + } | ||
| 346 | + | ||
| 347 | + .form-content { | ||
| 348 | + } | ||
| 349 | + } | ||
| 350 | + | ||
| 351 | + .card-header-right { | ||
| 352 | + float: right; | ||
| 353 | + } | ||
| 354 | + | ||
| 355 | + .text-center { | ||
| 356 | + text-align: center; | ||
| 357 | + } | ||
| 358 | +} | ||
| 359 | +</style> | ||
| 0 | \ No newline at end of file | 360 | \ No newline at end of file |
src/views/work/itemReleaseManageList.vue
| @@ -4,41 +4,25 @@ | @@ -4,41 +4,25 @@ | ||
| 4 | <el-card class="search-card"> | 4 | <el-card class="search-card"> |
| 5 | <div slot="header" class="flex justify-between"> | 5 | <div slot="header" class="flex justify-between"> |
| 6 | <span>{{ $t('itemReleaseManage.search.title') }}</span> | 6 | <span>{{ $t('itemReleaseManage.search.title') }}</span> |
| 7 | - <el-button | ||
| 8 | - type="text" | ||
| 9 | - style="float: right; padding: 3px 0" | ||
| 10 | - @click="_moreCondition" | ||
| 11 | - > | 7 | + <el-button type="text" style="float: right; padding: 3px 0" @click="_moreCondition"> |
| 12 | {{ itemReleaseManageInfo.moreCondition ? $t('common.hide') : $t('common.more') }} | 8 | {{ itemReleaseManageInfo.moreCondition ? $t('common.hide') : $t('common.more') }} |
| 13 | </el-button> | 9 | </el-button> |
| 14 | </div> | 10 | </div> |
| 15 | <el-row :gutter="20"> | 11 | <el-row :gutter="20"> |
| 16 | <el-col :span="6"> | 12 | <el-col :span="6"> |
| 17 | - <el-select | ||
| 18 | - v-model="itemReleaseManageInfo.conditions.typeId" | ||
| 19 | - :placeholder="$t('itemReleaseManage.placeholder.selectReleaseType')" | ||
| 20 | - style="width: 100%" | ||
| 21 | - > | ||
| 22 | - <el-option | ||
| 23 | - v-for="item in itemReleaseManageInfo.itemReleaseTypes" | ||
| 24 | - :key="item.typeId" | ||
| 25 | - :label="item.typeName" | ||
| 26 | - :value="item.typeId" | ||
| 27 | - :disabled="item.state !== 'C'" | ||
| 28 | - /> | 13 | + <el-select v-model="itemReleaseManageInfo.conditions.typeId" |
| 14 | + :placeholder="$t('itemReleaseManage.placeholder.selectReleaseType')" style="width: 100%"> | ||
| 15 | + <el-option v-for="item in itemReleaseManageInfo.itemReleaseTypes" :key="item.typeId" :label="item.typeName" | ||
| 16 | + :value="item.typeId" :disabled="item.state !== 'C'" /> | ||
| 29 | </el-select> | 17 | </el-select> |
| 30 | </el-col> | 18 | </el-col> |
| 31 | <el-col :span="8"> | 19 | <el-col :span="8"> |
| 32 | - <el-input | ||
| 33 | - v-model="itemReleaseManageInfo.conditions.applyCompany" | ||
| 34 | - :placeholder="$t('itemReleaseManage.placeholder.selectApplyCompany')" | ||
| 35 | - /> | 20 | + <el-input v-model="itemReleaseManageInfo.conditions.applyCompany" |
| 21 | + :placeholder="$t('itemReleaseManage.placeholder.selectApplyCompany')" /> | ||
| 36 | </el-col> | 22 | </el-col> |
| 37 | <el-col :span="6"> | 23 | <el-col :span="6"> |
| 38 | - <el-input | ||
| 39 | - v-model="itemReleaseManageInfo.conditions.applyPerson" | ||
| 40 | - :placeholder="$t('itemReleaseManage.placeholder.selectApplyPerson')" | ||
| 41 | - /> | 24 | + <el-input v-model="itemReleaseManageInfo.conditions.applyPerson" |
| 25 | + :placeholder="$t('itemReleaseManage.placeholder.selectApplyPerson')" /> | ||
| 42 | </el-col> | 26 | </el-col> |
| 43 | <el-col :span="4"> | 27 | <el-col :span="4"> |
| 44 | <el-button type="primary" @click="_queryItemReleaseMethod"> | 28 | <el-button type="primary" @click="_queryItemReleaseMethod"> |
| @@ -54,39 +38,20 @@ | @@ -54,39 +38,20 @@ | ||
| 54 | 38 | ||
| 55 | <el-row v-show="itemReleaseManageInfo.moreCondition" :gutter="20" style="margin-top: 20px"> | 39 | <el-row v-show="itemReleaseManageInfo.moreCondition" :gutter="20" style="margin-top: 20px"> |
| 56 | <el-col :span="6"> | 40 | <el-col :span="6"> |
| 57 | - <el-input | ||
| 58 | - v-model="itemReleaseManageInfo.conditions.idCard" | ||
| 59 | - :placeholder="$t('itemReleaseManage.placeholder.selectIdCard')" | ||
| 60 | - /> | 41 | + <el-input v-model="itemReleaseManageInfo.conditions.idCard" |
| 42 | + :placeholder="$t('itemReleaseManage.placeholder.selectIdCard')" /> | ||
| 61 | </el-col> | 43 | </el-col> |
| 62 | <el-col :span="8"> | 44 | <el-col :span="8"> |
| 63 | - <el-input | ||
| 64 | - v-model="itemReleaseManageInfo.conditions.applyTel" | ||
| 65 | - :placeholder="$t('itemReleaseManage.placeholder.selectPhone')" | ||
| 66 | - /> | 45 | + <el-input v-model="itemReleaseManageInfo.conditions.applyTel" |
| 46 | + :placeholder="$t('itemReleaseManage.placeholder.selectPhone')" /> | ||
| 67 | </el-col> | 47 | </el-col> |
| 68 | <el-col :span="6"> | 48 | <el-col :span="6"> |
| 69 | - <el-select | ||
| 70 | - v-model="itemReleaseManageInfo.conditions.state" | ||
| 71 | - :placeholder="$t('itemReleaseManage.placeholder.selectStatus')" | ||
| 72 | - style="width: 100%" | ||
| 73 | - > | ||
| 74 | - <el-option | ||
| 75 | - :label="$t('itemReleaseManage.status.waiting')" | ||
| 76 | - value="W" | ||
| 77 | - /> | ||
| 78 | - <el-option | ||
| 79 | - :label="$t('itemReleaseManage.status.processing')" | ||
| 80 | - value="D" | ||
| 81 | - /> | ||
| 82 | - <el-option | ||
| 83 | - :label="$t('itemReleaseManage.status.completed')" | ||
| 84 | - value="C" | ||
| 85 | - /> | ||
| 86 | - <el-option | ||
| 87 | - :label="$t('itemReleaseManage.status.failed')" | ||
| 88 | - value="F" | ||
| 89 | - /> | 49 | + <el-select v-model="itemReleaseManageInfo.conditions.state" |
| 50 | + :placeholder="$t('itemReleaseManage.placeholder.selectStatus')" style="width: 100%"> | ||
| 51 | + <el-option :label="$t('itemReleaseManage.status.waiting')" value="W" /> | ||
| 52 | + <el-option :label="$t('itemReleaseManage.status.processing')" value="D" /> | ||
| 53 | + <el-option :label="$t('itemReleaseManage.status.completed')" value="C" /> | ||
| 54 | + <el-option :label="$t('itemReleaseManage.status.failed')" value="F" /> | ||
| 90 | </el-select> | 55 | </el-select> |
| 91 | </el-col> | 56 | </el-col> |
| 92 | </el-row> | 57 | </el-row> |
| @@ -96,61 +61,21 @@ | @@ -96,61 +61,21 @@ | ||
| 96 | <el-card class="list-card"> | 61 | <el-card class="list-card"> |
| 97 | <div slot="header" class="flex justify-between"> | 62 | <div slot="header" class="flex justify-between"> |
| 98 | <span>{{ $t('itemReleaseManage.list.title') }}</span> | 63 | <span>{{ $t('itemReleaseManage.list.title') }}</span> |
| 99 | - <el-button | ||
| 100 | - type="primary" | ||
| 101 | - size="small" | ||
| 102 | - @click="_openAddItemReleaseModal" | ||
| 103 | - > | 64 | + <el-button type="primary" size="small" @click="_openAddItemReleaseModal"> |
| 104 | <i class="el-icon-plus"></i> | 65 | <i class="el-icon-plus"></i> |
| 105 | {{ $t('itemReleaseManage.button.applyRelease') }} | 66 | {{ $t('itemReleaseManage.button.applyRelease') }} |
| 106 | </el-button> | 67 | </el-button> |
| 107 | </div> | 68 | </div> |
| 108 | 69 | ||
| 109 | - <el-table | ||
| 110 | - :data="itemReleaseManageInfo.itemReleases" | ||
| 111 | - border | ||
| 112 | - style="width: 100%" | ||
| 113 | - v-loading="loading" | ||
| 114 | - > | ||
| 115 | - <el-table-column | ||
| 116 | - prop="irId" | ||
| 117 | - :label="$t('itemReleaseManage.table.orderNo')" | ||
| 118 | - align="center" | ||
| 119 | - /> | ||
| 120 | - <el-table-column | ||
| 121 | - prop="typeName" | ||
| 122 | - :label="$t('itemReleaseManage.table.releaseType')" | ||
| 123 | - align="center" | ||
| 124 | - /> | ||
| 125 | - <el-table-column | ||
| 126 | - prop="applyCompany" | ||
| 127 | - :label="$t('itemReleaseManage.table.applyCompany')" | ||
| 128 | - align="center" | ||
| 129 | - /> | ||
| 130 | - <el-table-column | ||
| 131 | - prop="applyPerson" | ||
| 132 | - :label="$t('itemReleaseManage.table.applyPerson')" | ||
| 133 | - align="center" | ||
| 134 | - /> | ||
| 135 | - <el-table-column | ||
| 136 | - prop="idCard" | ||
| 137 | - :label="$t('itemReleaseManage.table.idCard')" | ||
| 138 | - align="center" | ||
| 139 | - /> | ||
| 140 | - <el-table-column | ||
| 141 | - prop="applyTel" | ||
| 142 | - :label="$t('itemReleaseManage.table.phone')" | ||
| 143 | - align="center" | ||
| 144 | - /> | ||
| 145 | - <el-table-column | ||
| 146 | - prop="passTime" | ||
| 147 | - :label="$t('itemReleaseManage.table.passTime')" | ||
| 148 | - align="center" | ||
| 149 | - /> | ||
| 150 | - <el-table-column | ||
| 151 | - :label="$t('itemReleaseManage.table.items')" | ||
| 152 | - align="center" | ||
| 153 | - > | 70 | + <el-table :data="itemReleaseManageInfo.itemReleases" border style="width: 100%" v-loading="loading"> |
| 71 | + <el-table-column prop="irId" :label="$t('itemReleaseManage.table.orderNo')" align="center" /> | ||
| 72 | + <el-table-column prop="typeName" :label="$t('itemReleaseManage.table.releaseType')" align="center" /> | ||
| 73 | + <el-table-column prop="applyCompany" :label="$t('itemReleaseManage.table.applyCompany')" align="center" /> | ||
| 74 | + <el-table-column prop="applyPerson" :label="$t('itemReleaseManage.table.applyPerson')" align="center" /> | ||
| 75 | + <el-table-column prop="idCard" :label="$t('itemReleaseManage.table.idCard')" align="center" /> | ||
| 76 | + <el-table-column prop="applyTel" :label="$t('itemReleaseManage.table.phone')" align="center" /> | ||
| 77 | + <el-table-column prop="passTime" :label="$t('itemReleaseManage.table.passTime')" align="center" /> | ||
| 78 | + <el-table-column :label="$t('itemReleaseManage.table.items')" align="center"> | ||
| 154 | <template slot-scope="scope"> | 79 | <template slot-scope="scope"> |
| 155 | {{ scope.row.amount }}( | 80 | {{ scope.row.amount }}( |
| 156 | <el-link type="primary" @click="viewResName(scope.row)"> | 81 | <el-link type="primary" @click="viewResName(scope.row)"> |
| @@ -158,60 +83,30 @@ | @@ -158,60 +83,30 @@ | ||
| 158 | </el-link>) | 83 | </el-link>) |
| 159 | </template> | 84 | </template> |
| 160 | </el-table-column> | 85 | </el-table-column> |
| 161 | - <el-table-column | ||
| 162 | - prop="stateName" | ||
| 163 | - :label="$t('itemReleaseManage.table.status')" | ||
| 164 | - align="center" | ||
| 165 | - /> | ||
| 166 | - <el-table-column | ||
| 167 | - prop="carNum" | ||
| 168 | - :label="$t('itemReleaseManage.table.carNumber')" | ||
| 169 | - align="center" | ||
| 170 | - > | 86 | + <el-table-column prop="stateName" :label="$t('itemReleaseManage.table.status')" align="center" /> |
| 87 | + <el-table-column prop="carNum" :label="$t('itemReleaseManage.table.carNumber')" align="center"> | ||
| 171 | <template slot-scope="scope"> | 88 | <template slot-scope="scope"> |
| 172 | {{ scope.row.carNum || $t('common.none') }} | 89 | {{ scope.row.carNum || $t('common.none') }} |
| 173 | </template> | 90 | </template> |
| 174 | </el-table-column> | 91 | </el-table-column> |
| 175 | - <el-table-column | ||
| 176 | - :label="$t('common.operation')" | ||
| 177 | - align="center" | ||
| 178 | - width="240" | ||
| 179 | - > | 92 | + <el-table-column :label="$t('common.operation')" align="center" width="240"> |
| 180 | <template slot-scope="scope"> | 93 | <template slot-scope="scope"> |
| 181 | - <el-button | ||
| 182 | - size="mini" | ||
| 183 | - @click="_openDetail(scope.row)" | ||
| 184 | - > | 94 | + <el-button size="mini" @click="_openDetail(scope.row)"> |
| 185 | {{ $t('common.detail') }} | 95 | {{ $t('common.detail') }} |
| 186 | </el-button> | 96 | </el-button> |
| 187 | - <el-button | ||
| 188 | - size="mini" | ||
| 189 | - type="primary" | ||
| 190 | - @click="_openEditItemReleaseModel(scope.row)" | ||
| 191 | - > | 97 | + <el-button size="mini" type="primary" @click="_openEditItemReleaseModel(scope.row)"> |
| 192 | {{ $t('common.edit') }} | 98 | {{ $t('common.edit') }} |
| 193 | </el-button> | 99 | </el-button> |
| 194 | - <el-button | ||
| 195 | - size="mini" | ||
| 196 | - type="danger" | ||
| 197 | - @click="_openDeleteItemReleaseModel(scope.row)" | ||
| 198 | - > | 100 | + <el-button size="mini" type="danger" @click="_openDeleteItemReleaseModel(scope.row)"> |
| 199 | {{ $t('common.delete') }} | 101 | {{ $t('common.delete') }} |
| 200 | </el-button> | 102 | </el-button> |
| 201 | </template> | 103 | </template> |
| 202 | </el-table-column> | 104 | </el-table-column> |
| 203 | </el-table> | 105 | </el-table> |
| 204 | 106 | ||
| 205 | - <el-pagination | ||
| 206 | - :current-page.sync="page.current" | ||
| 207 | - :page-sizes="[10, 20, 30, 50]" | ||
| 208 | - :page-size="page.size" | ||
| 209 | - :total="page.total" | ||
| 210 | - layout="total, sizes, prev, pager, next, jumper" | ||
| 211 | - @size-change="handleSizeChange" | ||
| 212 | - @current-change="handleCurrentChange" | ||
| 213 | - style="margin-top: 20px" | ||
| 214 | - /> | 107 | + <el-pagination :current-page.sync="page.current" :page-sizes="[10, 20, 30, 50]" :page-size="page.size" |
| 108 | + :total="page.total" layout="total, sizes, prev, pager, next, jumper" @size-change="handleSizeChange" | ||
| 109 | + @current-change="handleCurrentChange" style="margin-top: 20px" /> | ||
| 215 | </el-card> | 110 | </el-card> |
| 216 | 111 | ||
| 217 | <!-- 组件 --> | 112 | <!-- 组件 --> |
| @@ -224,14 +119,12 @@ | @@ -224,14 +119,12 @@ | ||
| 224 | <script> | 119 | <script> |
| 225 | import { getCommunityId } from '@/api/community/communityApi' | 120 | import { getCommunityId } from '@/api/community/communityApi' |
| 226 | import { listItemRelease, listItemReleaseType } from '@/api/work/itemReleaseManageApi' | 121 | import { listItemRelease, listItemReleaseType } from '@/api/work/itemReleaseManageApi' |
| 227 | -import EditItemRelease from '@/components/work/editItemRelease' | ||
| 228 | import DeleteItemRelease from '@/components/work/deleteItemRelease' | 122 | import DeleteItemRelease from '@/components/work/deleteItemRelease' |
| 229 | import ViewItemReleaseRes from '@/components/work/viewItemReleaseRes' | 123 | import ViewItemReleaseRes from '@/components/work/viewItemReleaseRes' |
| 230 | 124 | ||
| 231 | export default { | 125 | export default { |
| 232 | name: 'ItemReleaseManageList', | 126 | name: 'ItemReleaseManageList', |
| 233 | components: { | 127 | components: { |
| 234 | - EditItemRelease, | ||
| 235 | DeleteItemRelease, | 128 | DeleteItemRelease, |
| 236 | ViewItemReleaseRes | 129 | ViewItemReleaseRes |
| 237 | }, | 130 | }, |
| @@ -304,7 +197,7 @@ export default { | @@ -304,7 +197,7 @@ export default { | ||
| 304 | this.$router.push('/views/work/addItemReleaseView') | 197 | this.$router.push('/views/work/addItemReleaseView') |
| 305 | }, | 198 | }, |
| 306 | _openEditItemReleaseModel(item) { | 199 | _openEditItemReleaseModel(item) { |
| 307 | - this.$refs.editItemRelease.open(item) | 200 | + this.$router.push(`/views/work/editItemReleaseView?irId=${item.irId}&flowId=${item.flowId}`) |
| 308 | }, | 201 | }, |
| 309 | _openDeleteItemReleaseModel(item) { | 202 | _openDeleteItemReleaseModel(item) { |
| 310 | this.$refs.deleteItemRelease.open(item) | 203 | this.$refs.deleteItemRelease.open(item) |