Commit 99dad679 by qinjianhui

Merge branch 'dev' into 'master'

Dev

See merge request !8
parents f32a8a6b 72bcd04c
{ {
"tabWidth": 2, "tabWidth": 2,
"singleQuote": true, "singleQuote": true,
"printWidth": 80, "printWidth": 180,
"semi": false, "semi": false,
"trailingComma": "none", "trailingComma": "none",
"bracketSpacing": true, "bracketSpacing": true,
......
...@@ -2012,6 +2012,49 @@ ...@@ -2012,6 +2012,49 @@
"webpack-merge": "^5.7.3", "webpack-merge": "^5.7.3",
"webpack-virtual-modules": "^0.4.2", "webpack-virtual-modules": "^0.4.2",
"whatwg-fetch": "^3.6.2" "whatwg-fetch": "^3.6.2"
},
"dependencies": {
"@vue/vue-loader-v15": {
"version": "npm:vue-loader@15.10.1",
"resolved": "https://registry.npmmirror.com/vue-loader/-/vue-loader-15.10.1.tgz",
"integrity": "sha512-SaPHK1A01VrNthlix6h1hq4uJu7S/z0kdLUb6klubo738NeQoLbS6V9/d8Pv19tU0XdQKju3D1HSKuI8wJ5wMA==",
"dev": true,
"requires": {
"@vue/component-compiler-utils": "^3.1.0",
"hash-sum": "^1.0.2",
"loader-utils": "^1.1.0",
"vue-hot-reload-api": "^2.3.0",
"vue-style-loader": "^4.1.0"
},
"dependencies": {
"hash-sum": {
"version": "1.0.2",
"resolved": "https://registry.npmmirror.com/hash-sum/-/hash-sum-1.0.2.tgz",
"integrity": "sha512-fUs4B4L+mlt8/XAtSOGMUO1TXmAelItBPtJG7CyHJfYTdDjwisntGO2JQz7oUsatOY9o68+57eziUVNw/mRHmA==",
"dev": true
}
}
},
"json5": {
"version": "1.0.2",
"resolved": "https://registry.npmmirror.com/json5/-/json5-1.0.2.tgz",
"integrity": "sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA==",
"dev": true,
"requires": {
"minimist": "^1.2.0"
}
},
"loader-utils": {
"version": "1.4.2",
"resolved": "https://registry.npmmirror.com/loader-utils/-/loader-utils-1.4.2.tgz",
"integrity": "sha512-I5d00Pd/jwMD2QCduo657+YM/6L3KZu++pmX9VFncxaxvHcru9jx1lBaFft+r4Mt2jK0Yhp41XlRAihzPxHNCg==",
"dev": true,
"requires": {
"big.js": "^5.2.2",
"emojis-list": "^3.0.0",
"json5": "^1.0.1"
}
}
} }
}, },
"@vue/cli-shared-utils": { "@vue/cli-shared-utils": {
...@@ -2172,47 +2215,6 @@ ...@@ -2172,47 +2215,6 @@
"eslint-import-resolver-webpack": "^0.13.1" "eslint-import-resolver-webpack": "^0.13.1"
} }
}, },
"@vue/vue-loader-v15": {
"version": "npm:vue-loader@15.10.0",
"resolved": "https://registry.npmmirror.com/vue-loader/-/vue-loader-15.10.0.tgz",
"integrity": "sha512-VU6tuO8eKajrFeBzMssFUP9SvakEeeSi1BxdTH5o3+1yUyrldp8IERkSdXlMI2t4kxF2sqYUDsQY+WJBxzBmZg==",
"dev": true,
"requires": {
"@vue/component-compiler-utils": "^3.1.0",
"hash-sum": "^1.0.2",
"loader-utils": "^1.1.0",
"vue-hot-reload-api": "^2.3.0",
"vue-style-loader": "^4.1.0"
},
"dependencies": {
"hash-sum": {
"version": "1.0.2",
"resolved": "https://registry.npmmirror.com/hash-sum/-/hash-sum-1.0.2.tgz",
"integrity": "sha512-fUs4B4L+mlt8/XAtSOGMUO1TXmAelItBPtJG7CyHJfYTdDjwisntGO2JQz7oUsatOY9o68+57eziUVNw/mRHmA==",
"dev": true
},
"json5": {
"version": "1.0.1",
"resolved": "https://registry.npmmirror.com/json5/-/json5-1.0.1.tgz",
"integrity": "sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow==",
"dev": true,
"requires": {
"minimist": "^1.2.0"
}
},
"loader-utils": {
"version": "1.4.0",
"resolved": "https://registry.npmmirror.com/loader-utils/-/loader-utils-1.4.0.tgz",
"integrity": "sha512-qH0WSMBtn/oHuwjy/NucEgbx5dbxxnxup9s4PVXJUDHZBQY+s0NWA9rJf53RBnQZxfch7euUui7hpoAPvALZdA==",
"dev": true,
"requires": {
"big.js": "^5.2.2",
"emojis-list": "^3.0.0",
"json5": "^1.0.1"
}
}
}
},
"@vue/web-component-wrapper": { "@vue/web-component-wrapper": {
"version": "1.3.0", "version": "1.3.0",
"resolved": "https://registry.npmmirror.com/@vue/web-component-wrapper/-/web-component-wrapper-1.3.0.tgz", "resolved": "https://registry.npmmirror.com/@vue/web-component-wrapper/-/web-component-wrapper-1.3.0.tgz",
...@@ -2670,7 +2672,7 @@ ...@@ -2670,7 +2672,7 @@
}, },
"async-validator": { "async-validator": {
"version": "1.8.5", "version": "1.8.5",
"resolved": "https://registry.npmmirror.com/async-validator/-/async-validator-1.8.5.tgz", "resolved": "https://registry.npmjs.org/async-validator/-/async-validator-1.8.5.tgz",
"integrity": "sha512-tXBM+1m056MAX0E8TL2iCjg8WvSyXu0Zc8LNtYqrVeyoL3+esHRZ4SieE9fKQyyU09uONjnMEjrNBMqT0mbvmA==", "integrity": "sha512-tXBM+1m056MAX0E8TL2iCjg8WvSyXu0Zc8LNtYqrVeyoL3+esHRZ4SieE9fKQyyU09uONjnMEjrNBMqT0mbvmA==",
"requires": { "requires": {
"babel-runtime": "6.x" "babel-runtime": "6.x"
...@@ -2713,7 +2715,7 @@ ...@@ -2713,7 +2715,7 @@
}, },
"babel-helper-vue-jsx-merge-props": { "babel-helper-vue-jsx-merge-props": {
"version": "2.0.3", "version": "2.0.3",
"resolved": "https://registry.npmmirror.com/babel-helper-vue-jsx-merge-props/-/babel-helper-vue-jsx-merge-props-2.0.3.tgz", "resolved": "https://registry.npmjs.org/babel-helper-vue-jsx-merge-props/-/babel-helper-vue-jsx-merge-props-2.0.3.tgz",
"integrity": "sha512-gsLiKK7Qrb7zYJNgiXKpXblxbV5ffSwR0f5whkPAaBAR4fhi6bwRZxX9wBlIc5M/v8CCkXUbXZL4N/nSE97cqg==" "integrity": "sha512-gsLiKK7Qrb7zYJNgiXKpXblxbV5ffSwR0f5whkPAaBAR4fhi6bwRZxX9wBlIc5M/v8CCkXUbXZL4N/nSE97cqg=="
}, },
"babel-loader": { "babel-loader": {
...@@ -2769,7 +2771,7 @@ ...@@ -2769,7 +2771,7 @@
}, },
"babel-runtime": { "babel-runtime": {
"version": "6.26.0", "version": "6.26.0",
"resolved": "https://registry.npmmirror.com/babel-runtime/-/babel-runtime-6.26.0.tgz", "resolved": "https://registry.npmjs.org/babel-runtime/-/babel-runtime-6.26.0.tgz",
"integrity": "sha512-ITKNuq2wKlW1fJg9sSW52eepoYgZBggvOAHC0u/CYu/qxQ9EVzThCgR69BnSXLHjy2f7SY5zaQ4yt7H9ZVxY2g==", "integrity": "sha512-ITKNuq2wKlW1fJg9sSW52eepoYgZBggvOAHC0u/CYu/qxQ9EVzThCgR69BnSXLHjy2f7SY5zaQ4yt7H9ZVxY2g==",
"requires": { "requires": {
"core-js": "^2.4.0", "core-js": "^2.4.0",
...@@ -2778,12 +2780,12 @@ ...@@ -2778,12 +2780,12 @@
"dependencies": { "dependencies": {
"core-js": { "core-js": {
"version": "2.6.12", "version": "2.6.12",
"resolved": "https://registry.npmmirror.com/core-js/-/core-js-2.6.12.tgz", "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.6.12.tgz",
"integrity": "sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ==" "integrity": "sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ=="
}, },
"regenerator-runtime": { "regenerator-runtime": {
"version": "0.11.1", "version": "0.11.1",
"resolved": "https://registry.npmmirror.com/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz", "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz",
"integrity": "sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg==" "integrity": "sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg=="
} }
} }
...@@ -3923,7 +3925,7 @@ ...@@ -3923,7 +3925,7 @@
}, },
"element-ui": { "element-ui": {
"version": "2.15.10", "version": "2.15.10",
"resolved": "https://registry.npmmirror.com/element-ui/-/element-ui-2.15.10.tgz", "resolved": "https://registry.npmjs.org/element-ui/-/element-ui-2.15.10.tgz",
"integrity": "sha512-jmD++mU2wKXbisvx4fxOl2mHaU+HWHTAq/3Wf8x9Bwyu4GdDZPLABb+CGi3DWN6fPqdgRcd74aX39DO+YHObLw==", "integrity": "sha512-jmD++mU2wKXbisvx4fxOl2mHaU+HWHTAq/3Wf8x9Bwyu4GdDZPLABb+CGi3DWN6fPqdgRcd74aX39DO+YHObLw==",
"requires": { "requires": {
"async-validator": "~1.8.1", "async-validator": "~1.8.1",
...@@ -6661,7 +6663,7 @@ ...@@ -6661,7 +6663,7 @@
}, },
"normalize-wheel": { "normalize-wheel": {
"version": "1.0.1", "version": "1.0.1",
"resolved": "https://registry.npmmirror.com/normalize-wheel/-/normalize-wheel-1.0.1.tgz", "resolved": "https://registry.npmjs.org/normalize-wheel/-/normalize-wheel-1.0.1.tgz",
"integrity": "sha512-1OnlAPZ3zgrk8B91HyRj+eVv+kS5u+Z0SCsak6Xil/kmgEia50ga7zfkumayonZrImffAxPU/5WcyGhzetHNPA==" "integrity": "sha512-1OnlAPZ3zgrk8B91HyRj+eVv+kS5u+Z0SCsak6Xil/kmgEia50ga7zfkumayonZrImffAxPU/5WcyGhzetHNPA=="
}, },
"npm-run-path": { "npm-run-path": {
...@@ -7722,7 +7724,7 @@ ...@@ -7722,7 +7724,7 @@
}, },
"resize-observer-polyfill": { "resize-observer-polyfill": {
"version": "1.5.1", "version": "1.5.1",
"resolved": "https://registry.npmmirror.com/resize-observer-polyfill/-/resize-observer-polyfill-1.5.1.tgz", "resolved": "https://registry.npmjs.org/resize-observer-polyfill/-/resize-observer-polyfill-1.5.1.tgz",
"integrity": "sha512-LwZrotdHOo12nQuZlHEmtuXdqGoOD0OhaxopaNFxWzInpEgaLWoVuAMbTzixuosCx2nEG58ngzW3vxdWoxIgdg==" "integrity": "sha512-LwZrotdHOo12nQuZlHEmtuXdqGoOD0OhaxopaNFxWzInpEgaLWoVuAMbTzixuosCx2nEG58ngzW3vxdWoxIgdg=="
}, },
"resolve": { "resolve": {
...@@ -8544,7 +8546,7 @@ ...@@ -8544,7 +8546,7 @@
}, },
"throttle-debounce": { "throttle-debounce": {
"version": "1.1.0", "version": "1.1.0",
"resolved": "https://registry.npmmirror.com/throttle-debounce/-/throttle-debounce-1.1.0.tgz", "resolved": "https://registry.npmjs.org/throttle-debounce/-/throttle-debounce-1.1.0.tgz",
"integrity": "sha512-XH8UiPCQcWNuk2LYePibW/4qL97+ZQ1AN3FNXwZRBNPPowo/NRU5fAlDCSNBJIYCKbioZfuYtMhG4quqoJhVzg==" "integrity": "sha512-XH8UiPCQcWNuk2LYePibW/4qL97+ZQ1AN3FNXwZRBNPPowo/NRU5fAlDCSNBJIYCKbioZfuYtMhG4quqoJhVzg=="
}, },
"thunky": { "thunky": {
......
import axios from './axios'
export function getOrderTree() {
return axios.get('platform/platformWorkOrder/erp/findStateGroupList')
}
export function workConfirmed(id) {
return axios.post('platform/platformWorkOrder/confirmed', {
id: id,
})
}
export function workAssigned(id, user) {
return axios.post('platform/platformWorkOrder/assign', {
id: id,
leader: user,
})
}
export function startWorder(id) {
return axios.post('platform/platformWorkOrder/start', {
id: id,
})
}
export function archiveWorkOrder(id) {
return axios.post('platform/platformWorkOrder/archive', {
id: id,
})
}
export function replyTocustomer(id, msg) {
return axios.post('platform/platformWorkOrderChat/add', {
msg: msg,
workOrderId: id,
})
}
export function getOrderType() {
return axios.get('platform/platformWorkOrder/orderTypeList')
}
import axios from './axios'
// 获取系统用户
export function getSystemUserList() {
return axios.get('platform/user/list')
}
...@@ -66,6 +66,10 @@ ...@@ -66,6 +66,10 @@
padding-top: 5px; padding-top: 5px;
padding-bottom: 5px; padding-bottom: 5px;
} }
.el-form-item--mini.el-form-item {
margin-bottom: 10px;
}
.icon-view{ .icon-view{
font-size: 18px; font-size: 18px;
cursor: pointer; cursor: pointer;
...@@ -74,3 +78,52 @@ ...@@ -74,3 +78,52 @@
.icon-view + .icon-view{ .icon-view + .icon-view{
margin-left: 10px; margin-left: 10px;
} }
.icon-view {
width: 23px;
height: 23px;
font-size: 16px;
line-height: 23px;
border-radius: 4px;
text-align: center;
display: inline-block;
color: #fff;
cursor: pointer;
vertical-align: middle;
}
.icon-view:not(:first-child) {
margin-left: 5px;
}
.icon-edit-view {
background-color: #ff9900;
}
.icon-edit-view:hover {
background-color: #ffd36a;
}
.icon-del-view {
background-color: #f56c6c;
}
.icon-del-view:hover {
background-color: #f78989;
}
.icon-tools-view {
background-color: #8cc34b;
}
.icon-tools-view:hover {
background-color: #85ce61;
}
.icon-primary-view {
background-color: #4168FF;
}
.icon-primary-view:hover {
background-color: #66b1ff;
}
...@@ -5,9 +5,11 @@ import store from './store' ...@@ -5,9 +5,11 @@ import store from './store'
import element from '@/common/components/element-ui.js' import element from '@/common/components/element-ui.js'
import vxeTable from '@/common/components/vxeTable.js' import vxeTable from '@/common/components/vxeTable.js'
import './common/style/index.scss' import './common/style/index.scss'
import Directives from './utils/directives'
// import { getToken } from '@/utils/auth' // import { getToken } from '@/utils/auth'
Vue.config.productionTip = false Vue.config.productionTip = false
Vue.use(Directives)
Vue.use(element) Vue.use(element)
Vue.use(vxeTable) Vue.use(vxeTable)
......
/**
* @type {import("vue/types/options").DirectiveOptions}
*/
const enterSubmit = {
inserted: (el, binding) => {
el._enterSubmitFn = (e) => {
if (e.key !== 'Enter') return
if (typeof binding.value === 'function') {
setTimeout(() => {
binding.value()
}, 100)
}
}
el.addEventListener('keydown', el._enterSubmitFn, true)
},
unbind: (el) => {
el.removeEventListener(
'keydown',
el._enterSubmitFn,
true,
)
},
}
export default enterSubmit
import enterSubmit from './enter-submit'
export default {
install(Vue) {
Vue.directive('enter-submit', enterSubmit)
},
}
...@@ -12,8 +12,10 @@ ...@@ -12,8 +12,10 @@
:data="treeData" :data="treeData"
:props="defaultProps" :props="defaultProps"
highlight-current highlight-current
:node-key="'continentCode'" :node-key="'statusCode'"
current-node-key="" :expand-on-click-node="false"
current-node-key="PRE_HANDLING"
default-expand-all
@node-click="handleNodeClick" @node-click="handleNodeClick"
> >
<span <span
...@@ -37,21 +39,20 @@ ...@@ -37,21 +39,20 @@
> >
<el-form-item label="创建时间"> <el-form-item label="创建时间">
<choose-time-period <choose-time-period
@change="getStatusTree"
v-model="periodTime" v-model="periodTime"
></choose-time-period> ></choose-time-period>
</el-form-item> </el-form-item>
<el-form-item label="工单编号"> <el-form-item label="工单编号">
<el-input <el-input
style="width: 120px" style="width: 120px"
v-model="searchForm.taskNumber" v-model="searchForm.orderNo"
placeholder="请输入" placeholder="请输入"
clearable clearable
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="工单类型"> <el-form-item label="工单类型">
<el-select <el-select
v-model="searchForm.taskType" v-model="searchForm.orderType"
style="width: 120px" style="width: 120px"
value-key="" value-key=""
placeholder="请选择" placeholder="请选择"
...@@ -59,40 +60,35 @@ ...@@ -59,40 +60,35 @@
filterable filterable
> >
<el-option <el-option
v-for="(type, index) in taskTypes" v-for="(type, index) in orderTypes"
:key="index" :key="index"
:label="type.name" :label="type.value"
:value="type.code" :value="type.key"
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="工单标题"> <el-form-item label="工单标题">
<el-input <el-input
style="width: 120px" style="width: 120px"
v-model="searchForm.taskTitle" v-model="searchForm.title"
placeholder="请输入" placeholder="请输入"
clearable clearable
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="创建人">
<el-cascader
clearable
style="width: 120px"
v-model="searchForm.taskCreator"
:props="{ emitPath: false }"
:options="deptStaff"
:show-all-levels="false"
></el-cascader>
</el-form-item>
<el-form-item label="负责人"> <el-form-item label="负责人">
<el-cascader <el-select
clearable
style="width: 120px" style="width: 120px"
v-model="searchForm.taskLeader" placeholder="请选择"
:props="{ emitPath: false }" clearable
:options="deptStaff" v-model="searchForm.leader"
:show-all-levels="false" >
></el-cascader> <el-option
v-for="user in userList"
:key="user.id"
:label="user.realName"
:value="user.id"
></el-option>
</el-select>
</el-form-item> </el-form-item>
<el-form-item label> <el-form-item label>
<el-button <el-button
...@@ -103,360 +99,213 @@ ...@@ -103,360 +99,213 @@
查询 查询
</el-button> </el-button>
</el-form-item> </el-form-item>
<!-- <el-form-item label>
<el-button
@click="showEdit()"
type="success"
size="mini"
>
新增
</el-button>
</el-form-item> -->
<el-form-item label v-if="statusCode === '8'">
<el-button
@click="archive()"
type="success"
size="mini"
>
归档
</el-button>
</el-form-item>
</el-form> </el-form>
<div class="table-wrap"> <div class="table-wrap" v-loading="loading">
<table-view <table-view
:tableColumns="tableColumns" :tableColumns="tableColumns"
:sourceData="sourceData" :sourceData="sourceData"
:selectionChange="selectionChange" selection
@selectionChange="selectionChange"
></table-view> ></table-view>
</div> </div>
<div class="pagination"> <div class="pagination">
<el-pagination <el-pagination
layout="sizes, total, prev, pager, next, jumper" layout="sizes, total, prev, pager, next, jumper"
background background
:total="total" :total="centerPageOptions.total"
:page-size="pageSize" :page-size="centerPageOptions.pageSize"
:current-page="currentPage" :current-page="centerPageOptions.currentPage"
@size-change="sizeChange" @size-change="sizeChange"
@current-change="onCurrentChange" @current-change="onCurrentChange"
> >
</el-pagination> </el-pagination>
</div> </div>
</div> </div>
<!-- 编辑 -->
<edit
:editDialog.sync="editDialog"
@onSubmit="onSubmit"
:selectOptions="selectOptions"
:editForm="editForm"
:taskTypes="taskTypes"
:isEdit="isEdit"
:employee="deptStaff"
ref="edit"
></edit>
<!-- 详情 --> <!-- 详情 -->
<el-dialog <el-dialog
title="详情" title="详情"
:close-on-click-modal="false"
:visible.sync="detailVisible" :visible.sync="detailVisible"
width="900px" width="900px"
> >
<div class="step-bar">
<!-- step-pass 已经完成,step-active当前步骤 -->
<div
class="step step-after step-pass"
:class="{
'step-pass':
detail.orderStatus === 'TO_BE_ASSIGN' ||
detail.orderStatus === 'TO_BE_CONFIRMED' ||
detail.orderStatus === 'IN_PROGRESS' ||
detail.orderStatus === 'CLOSED' ||
detail.orderStatus === 'ARCHIVE',
'step-active':
detail.orderStatus === 'PRE_HANDLING',
}"
>
<span>已受理</span>
</div>
<div
class="step step-after step-before"
:class="{
'step-pass':
detail.orderStatus === 'CLOSED' ||
detail.orderStatus === 'ARCHIVE',
'step-active':
detail.orderStatus === 'IN_PROGRESS' ||
detail.orderStatus === 'TO_BE_ASSIGN' ||
detail.orderStatus === 'TO_BE_CONFIRMED',
}"
>
<span>处理中</span>
</div>
<div
class="step step-after step-before"
:class="{
'step-pass': detail.orderStatus === 'ARCHIVE',
'step-active': detail.orderStatus === 'CLOSED',
}"
>
<span>已关闭</span>
</div>
<div
class="step step-before"
:class="{
'step-pass': detail.orderStatus === 'ARCHIVE',
'step-active': detail.orderStatus === 'ARCHIVE',
}"
>
<span>已归档</span>
</div>
</div>
<div class="content">
<div class="detail_list"> <div class="detail_list">
<div class="item_wrap"> <div class="item_wrap">
<p class="item" style="width: 100%"> <p class="item" style="width: 100%">
<span class="label">工单标题</span> <span class="label">工单标题</span>
<span class="value" style="width: 732px">{{ <span class="value" style="width: 732px">{{
detail.taskTitle detail.title
}}</span> }}</span>
</p> </p>
<p class="item"> <p class="item">
<span class="label">工单编码</span> <span class="label">工单编码</span>
<span class="value">{{ <span class="value">{{
detail.taskNumber detail.orderNo
}}</span> }}</span>
</p> </p>
<p class="item"> <p class="item">
<span class="label">工单类型</span> <span class="label">工单类型</span>
<span class="value"> <span class="value">
{{ detail.taskType && detail.taskType.desc }} {{ detail.orderTypeTxt }}
</span> </span>
</p> </p>
<p class="item"> <p class="item">
<span class="label">工单状态</span> <span class="label">工单状态</span>
<span class="value"> <span class="value">
{{ {{ detail.orderStatusTxt }}
detail.taskStatus && detail.taskStatus.desc
}}
</span> </span>
</p> </p>
<p
class="item"
style="width: 100%; display: flex"
>
<span class="label">工单内容</span>
<span
style="flex: 1; display: inline-block"
class="value"
v-html="detail.content"
></span>
</p>
</div> </div>
<div <div
style="padding: 5px; overflow: auto" style="padding: 5px; overflow: auto"
v-html="detail.taskContent" v-html="detail.taskContent"
@click="fullScreenDisplay" @click="fullScreenDisplay"
></div>
</div>
<div class="record">
<div class="title">沟通记录</div>
<ul
class="chat_content"
v-if="chatRecord.length > 0"
>
<li
v-for="(item, index) in chatRecord"
:key="index"
class="chat_item"
:class="{ chat_right: item.type === 1 }"
> >
这里有一段描述 <div class="chat_warp" v-if="item.type === 1">
<div class="chat_user">
<div class="chat_user_time">
{{
item.createTime
}}&nbsp;&nbsp;&nbsp;&nbsp;{{
item.sendUserName
}}
</div>
<div class="chat_text">
{{ item.msg }}
</div>
</div>
<div class="chat_icon">
<img
width="100%"
src="http://img.alicdn.com/tfs/TB14feR0AL0gK0jSZFAXXcA9pXa-64-64.png"
alt=""
/>
</div>
</div>
<div v-else class="chat_warp">
<div class="chat_icon">
<img
width="100%"
src="http://img.alicdn.com/tfs/TB14feR0AL0gK0jSZFAXXcA9pXa-64-64.png"
alt=""
/>
</div> </div>
<div class="chat_user">
<div class="chat_user_time">
客服:&nbsp;&nbsp;&nbsp;&nbsp;{{
item.createTime
}}
</div>
<div class="chat_text">
{{ item.msg }}
</div>
</div>
</div>
</li>
</ul>
<div class="empty-data" v-else>暂无数据</div>
</div>
</div>
<div style="margin-top: 10px"> <div style="margin-top: 10px">
<div> <div>
<el-input <el-input
type="textarea" type="textarea"
:rows="2" :rows="4"
maxlength="1000"
placeholder="请输入内容" placeholder="请输入内容"
v-model="textarea" v-model="textarea"
> >
</el-input> </el-input>
</div> </div>
<div style="margin-top: 10px"> <div style="margin-top: 10px; text-align: right">
<el-button size="mini" type="success" <!-- <el-button size="mini" type="success"
>确认执行</el-button >确认执行</el-button
> > -->
<el-button size="mini" type="primary" <el-button
size="mini"
type="primary"
@click="reply"
>回复</el-button >回复</el-button
> >
</div> </div>
</div> </div>
</div>
<span slot="footer">
<!-- 确认 -->
<span
@click="confimTask(detail)"
class="detail_btn"
style="background: green"
title="确认"
v-if="
this.statusCode !== '-1' &&
detail.taskStatus &&
detail.taskStatus.name === 'HAS_NOT_CONFIRM' &&
(employeeId == detail.taskLeader ||
(detail.taskCompleteUserId &&
detail.taskCompleteUserId.indexOf(
employeeId,
) !== -1))
"
>
<i
class="el-icon-video-play"
style="font-size: 18px"
></i>
&nbsp;确认
</span>
<!-- 开始 -->
<span
@click="startTask(detail)"
class="detail_btn"
style="background: green"
title="开始"
v-if="
this.statusCode !== '-1' &&
detail.taskStatus &&
detail.taskStatus.name === 'HAS_NOT_STARTED' &&
(employeeId == detail.taskLeader ||
(detail.taskCompleteUserId &&
detail.taskCompleteUserId.indexOf(
employeeId,
) !== -1))
"
>
<i class="el-icon-video-play"></i>
&nbsp;开始
</span>
<!-- 终止 -->
<span
class="detail_btn"
style="background: red"
@click="cadence(detail)"
title="终止"
v-if="
employeeId === detail.taskCreator &&
detail.taskStatus &&
(detail.taskStatus.name === 'PROCESSING' ||
detail.taskStatus.name === 'REJECTED_ING')
"
>
<svg
t="1627628609045"
style="
margin-top: 3px;
vertical-align: text-bottom;
"
viewBox="0 0 1024 1024"
version="1.1"
xmlns="http://www.w3.org/2000/svg"
p-id="2698"
width="18"
height="18"
>
<path
d="M509.41569707 75.874304c-238.88418133 0-432.5376 193.65341867-432.5376 432.5376s193.65341867 432.5376 432.5376 432.5376c107.184128 0 205.26312107-38.98627413 280.8283136-103.55234133a435.09787307 435.09787307 0 0 0 17.56255573-15.8564352c10.69438293-8.75342507 19.63567787-18.8809216 19.63567787-33.1808768a37.70395307 37.70395307 0 0 0-9.74411094-25.346048l0.01201494-0.01201494-0.29709654-0.29709653a38.1026304 38.1026304 0 0 0-2.162688-2.162688L285.3830656 230.67579733c61.24776107-49.4665728 139.1722496-79.10741333 224.03263147-79.10741333 197.07876693 0 356.84352 159.76475307 356.84352 356.84352 0 28.71022933-3.39039573 56.6296576-9.79326294 83.37708373l0.0425984 0.01419947a37.91694507 37.91694507 0 0 0-1.1370496 9.22309973c0 20.9027072 16.9443328 37.84704 37.84704 37.84704 17.3146112 0 31.9029248-11.63154773 36.40415574-27.50327466l0.00218453-0.00436907 0.0065536-0.0294912c0.29709653-1.05294507 0.55268693-2.1233664 0.75912533-3.211264a429.9194368 429.9194368 0 0 0 4.554752-21.7546752c4.60281173-25.28815787 7.00689067-51.34199467 7.00689067-77.9583488 0.00109227-238.88418133-193.6523264-432.5376-432.53650773-432.5376z m-356.84352 432.5376c0-84.95213227 29.704192-162.95417173 79.26797653-224.23251627l501.82116693 501.82116694c-61.27834453 49.56378453-139.2934912 79.25377707-224.24562346 79.25377706-197.0798592 0.00109227-356.84352-159.76256853-356.84352-356.84242773z"
fill="#fff"
p-id="2699"
></path>
</svg>
&nbsp;终止
</span>
<!-- 完成 -->
<span
class="detail_btn"
style="background: green"
title="完成"
@click="operation('1', detail)"
v-if="
this.statusCode !== '-1' &&
detail.taskStatus &&
detail.taskStatus.name === 'PROCESSING' &&
(employeeId == detail.taskLeader ||
(detail.taskCompleteUserId &&
detail.taskCompleteUserId.indexOf(
employeeId,
) !== -1))
"
>
<i class="el-icon-circle-check"></i>
完成
</span>
<!-- 验收 -->
<span
class="detail_btn"
@click="operation('2', detail)"
style="background: green"
title="验收"
v-if="
this.statusCode !== '-1' &&
detail.taskStatus &&
detail.taskStatus.name === 'FOR_ACCEPTANCE' &&
employeeId === detail.taskAcceptanceUser
"
>
<i class="el-icon-s-claim"></i>
&nbsp;验收
</span>
<!-- 删除 -->
<span
class="detail_btn"
@click="remove(detail)"
style="background: green"
title="删除"
v-if="
this.statusCode !== '-1' &&
employeeId === detail.taskCreator &&
detail.taskStatus &&
detail.taskStatus.name === 'NOT_YET_ASSIGNED' &&
!detail.reasonForReject
"
>
<i class="el-icon-delete"></i>
&nbsp;删除
</span>
<!-- 指派给 -->
<span
class="detail_btn"
@click="showAssign(detail)"
style="background: green"
title="指派给"
v-if="
this.statusCode !== '-1' &&
detail.taskStatus &&
detail.taskStatus.name === 'NOT_YET_ASSIGNED'
"
>
<svg
t="1629105857363"
style="
vertical-align: middle;
margin-bottom: 3px;
"
viewBox="0 0 1024 1024"
version="1.1"
xmlns="http://www.w3.org/2000/svg"
p-id="1916"
width="18"
height="18"
>
<path
d="M865.83 328.187H545.556l21.133-26.23a34.055 34.055 0 0 0 4.407-7.141c13.433-30.053 25.274-91.855-15.716-132.846-46.246-46.167-127.854-32.84-169.003 22.115L286.08 305.329c-17.894 11.336-74.76 48.874-105.608 86.944l-105.394 6.292c-17.203 1.036-30.636 15.318-30.636 32.574v320.008c0 17.654 14.017 32.096 31.698 32.6l122.439 3.478 270.735 86.998c3.345 1.62 33.397 15.822 68.068 15.822h0.053c40.725 0 72.741-19.592 90.528-56.334a102.65 102.65 0 0 0 7.805-27.212c23.68-0.716 63.343-11.92 82.192-74.732 6.477-23.92 6.902-46.511 1.38-65.758 23.31-12.584 38.654-34.672 42.69-63.583 2.6-18.476 4.034-40.431-2.655-61.139H863.39c57.82 0 116.173-31.83 116.173-102.953-0.002-82.166-73.22-107.944-113.732-110.147z m-3.505 147.845H620.633c-17.999 0-32.6 14.601-32.6 32.627 0 18.025 14.601 32.627 32.6 32.627 54.902 0 69.821 10.327 73.697 14.76 4.832 5.549 5.84 17.787 3.132 37.326-1.009 7.169-2.708 19.194-28.777 19.194-3.982 0-6.903-0.344-7.38-0.424-17.257-2.974-34.406 8.707-37.645 26.362-3.132 17.628 8.496 34.512 26.07 37.857 2.867 0.531 3.982 1.514 4.99 3.16 3.186 5.043 5.15 17.282 0.532 34.3-8.283 27.476-18.69 27.476-22.088 27.476-7.434 0-15.451-3.796-17.575-5.07-12.265-7.7-27.875-6.133-38.76 3.372-10.884 9.478-14.017 25.38-8.017 38.521 0.265 0.558 6.212 13.91-0.053 28.194-6.371 13.141-15.451 18.504-31.327 18.504h-0.053c-19.858 0-39.344-9.186-43.697-10.939l-279.496-90.156c-2.974-0.956-6-1.487-9.132-1.567l-95.413-2.707V461.882l90.156-5.39c10.62-0.637 20.283-6.45 25.858-15.53 15.663-25.592 69.237-64.485 99.289-82.988 3.027-1.885 5.788-4.248 8.017-7.009l104.599-126.5c19.38-25.752 52.405-35.575 71.68-16.354 15.981 16.008 7.008 46.857 3.503 56.838l-60.795 75.397c-7.91 9.769-9.451 23.202-4.035 34.538a32.576 32.576 0 0 0 29.415 18.557l386.43-0.08c8.443 0.61 50.6 5.602 50.6 44.972 0 32.787-31.857 37.699-52.033 37.699z"
fill="#fff"
p-id="1917"
></path>
</svg>
&nbsp;指派
</span>
<!-- 作废 -->
<span
class="detail_btn"
@click="invalid(detail)"
style="background: red"
title="作废"
v-if="
this.statusCode !== '-1' &&
employeeId === detail.taskCreator &&
detail.taskStatus &&
detail.taskStatus.name === 'NOT_YET_ASSIGNED' &&
detail.reasonForReject
"
>
<svg
t="1635313137975"
style="
margin-left: 3px;
margin-top: 3px;
margin-bottom: 1px;
vertical-align: text-top;
"
viewBox="0 0 1024 1024"
version="1.1"
xmlns="http://www.w3.org/2000/svg"
p-id="4954"
width="18"
height="18"
>
<path
d="M526.5 385.2c-17.6 0-32-14.3-32-31.9L493.9 63c0-12.8 7.6-24.4 19.4-29.5 11.8-5.1 25.4-2.6 34.7 6.2l305 290.2c9.5 9 12.5 22.9 7.7 35.1-4.9 12.2-16.6 20.1-29.7 20.1l-304.5 0.1z m31.6-247.6l0.4 183.6 192.5-0.1-192.9-183.5z"
fill="#ffffff"
p-id="4955"
></path>
<path
d="M799.2 353.9v469.3c0 27.9-11 54.2-30.9 74.1s-46.2 30.9-74.1 30.9H200.3c-27.9 0-54.2-11-74.1-30.9s-30.9-46.2-30.9-74.1V200.3c0-27.9 11-54.2 30.9-74.1 19.9-19.9 46.2-30.9 74.1-30.9h322.1v-64H200.3c-93.2 0-169 75.8-169 169v622.9c0 93.2 75.8 169 169 169h493.9c93.2 0 169-75.8 169-169V353.9h-64z"
fill="#ffffff"
p-id="4956"
></path>
<path
d="M624 497.1L314.9 806.2c-12.6 12.6-33.3 12.6-46 0-12.6-12.6-12.6-33.3 0-46L578 451.1c12.6-12.6 33.3-12.6 46 0 12.7 12.7 12.7 33.3 0 46z"
fill="#ffffff"
p-id="4957"
></path>
<path
d="M267 490.2l317 317c12.6 12.6 33.3 12.6 46 0 12.6-12.6 12.6-33.3 0-46l-317-317c-12.6-12.6-33.3-12.6-46 0-12.6 12.7-12.6 33.4 0 46z"
fill="#ffffff"
p-id="4958"
></path>
</svg>
&nbsp;作废
</span>
<!-- 驳回 -->
<span
class="detail_btn"
@click="rejectTask(detail)"
style="background: red"
title="驳回"
v-if="
this.statusCode !== '-1' &&
(employeeId === detail.taskLeader ||
(detail.taskCompleteUserId &&
detail.taskCompleteUserId.indexOf(
employeeId,
) !== -1)) &&
detail.taskStatus &&
(detail.taskStatus.name === 'HAS_NOT_CONFIRM' ||
detail.taskStatus.name === 'HAS_NOT_STARTED')
"
>
<i class="el-icon-s-claim"></i>
&nbsp;驳回
</span>
</span>
</el-dialog> </el-dialog>
<!-- 指派 --> <!-- 指派 -->
...@@ -466,18 +315,28 @@ ...@@ -466,18 +315,28 @@
:visible.sync="assignVisible" :visible.sync="assignVisible"
width="300px" width="300px"
> >
<el-cascader <el-select
style="width: 100%"
size="small" size="small"
v-model="taskLeader" v-model="user"
:props="{ emitPath: false, multiple: true }" >
:options="deptStaff" <el-option
:show-all-levels="false" v-for="user in userList"
></el-cascader> :key="user.id"
:label="user.realName"
:value="user.id"
></el-option>
</el-select>
<span slot="footer"> <span slot="footer">
<el-button @click="assignVisible = false" <el-button
size="mini"
@click="assignVisible = false"
>取消</el-button >取消</el-button
> >
<el-button type="primary" @click="submitAssign" <el-button
size="mini"
type="primary"
@click="submitAssign"
>确定</el-button >确定</el-button
> >
</span> </span>
...@@ -486,21 +345,30 @@ ...@@ -486,21 +345,30 @@
</template> </template>
<script> <script>
import axios from '../../common/api/axios' import tableView from '@/common/components/base/tableView.vue'
import { emptyArray, getIds } from '../../utils/commonUtil' import ChooseTimePeriod from '../../components/base/chooseTimePeriod.vue'
import pagination from '../../mixins/pagination' import pagination from '../../mixins/pagination'
import Edit from './edit.vue' import axios from '../../common/api/axios'
import {
getOrderTree,
workConfirmed,
workAssigned,
startWorder,
archiveWorkOrder,
replyTocustomer,
getOrderType,
} from '@/common/api/order'
import { getSystemUserList } from '@/common/api/system'
import { mapState } from 'vuex' import { mapState } from 'vuex'
import ChooseTimePeriod from '../../components/base/chooseTimePeriod.vue' import confirmWork from '@/assets/work/confirm.png'
/* 工单管理 */ import assignWork from '@/assets/work/assign.png'
import tableView from '@/common/components/base/tableView.vue' import startWork from '@/assets/work/start.png'
import archiveWork from '@/assets/work/archive.png'
export default { export default {
name: 'task_center', name: 'task_center',
mixins: [pagination], mixins: [pagination],
components: { components: {
Edit,
ChooseTimePeriod, ChooseTimePeriod,
tableView, tableView,
}, },
...@@ -512,206 +380,78 @@ export default { ...@@ -512,206 +380,78 @@ export default {
} }
return { return {
pickerOption: { loading: false,
disabledDate: (time) => { user: '',
return time.getTime() < Date.now() - 8.64e7 textarea: '',
},
},
centerPageOptions: { centerPageOptions: {
pageSize: 100, pageSize: 100,
currentPage: 1, currentPage: 1,
total: 0, total: 0,
}, },
planPageOptions: {
pageSize: 100,
currentPage: 1,
total: 0,
},
taskLeader: '', taskLeader: '',
assignVisible: false, assignVisible: false,
expectedEndVisible: false,
expectedEndTime: '',
periodTime: [], periodTime: [],
assignMe: null,
planCycle: '',
terminationVisible: false,
timeConsuming: '',
terminationReason: '',
selections: [], selections: [],
statusTree: [],
is_tab: '1', is_tab: '1',
statusCode: '', statusCode: 'PRE_HANDLING',
commentsForm: {},
completeForm: {},
searchForm: { timeProp: 'create_time' }, searchForm: { timeProp: 'create_time' },
expectedStartForm: {
expectedStartDate: '',
planCycle: '',
},
addrules: {
expectedStartDate: [
{
required: true,
message: '请选择预计开始时间',
trigger: 'blur',
},
],
planCycle: [
{
required: true,
message: '请输入预计工时',
trigger: 'blur',
},
],
},
isEdit: false, isEdit: false,
sourceData: [], sourceData: [],
planData: [],
currentRowId: '', currentRowId: '',
editDialog: false,
editForm: {}, editForm: {},
commentsVisible: false, commentsVisible: false,
selectOptions: {
emergencyLevel: [],
importanceLevel: [],
priorityLevel: [],
taskCompletion: [],
taskRating: [],
taskStatus: [],
taskType: [],
},
detail: {}, detail: {},
detailVisible: false, detailVisible: false,
updateVisible: false,
employeeId, employeeId,
iconClasses: [
'icon-rate-face-1',
'icon-rate-face-2',
'icon-rate-face-3',
],
expectedStartDate: '',
confimVisible: false,
defauntIndex: 0,
taskTypes: [], taskTypes: [],
treeData: [], treeData: [],
defaultProps: { defaultProps: {
children: 'children', children: 'children',
label: 'statusName', label: 'statusName',
}, },
total: 0, userList: [],
pageSize: 100, orderTypes: [],
currentPage: 1, chatRecord: [],
} }
}, },
mounted() { mounted() {
const arr = [ this.getOrderTree()
{
statusCode: 'all',
statusName: '全部',
quantity: 35,
children: null,
},
{
statusCode: 'preprocessing',
statusName: '预处理',
quantity: 27,
children: null,
},
{
statusCode: 'to_be_dispatched',
statusName: '待分派',
quantity: 3,
children: null,
},
{
statusCode: 'to_be_confirmed',
statusName: '待确认',
quantity: 0,
children: null,
},
{
statusCode: 'processing',
statusName: '处理中',
quantity: 0,
children: null,
},
{
statusCode: 'pending_feedback',
statusName: '待反馈',
quantity: 0,
children: null,
},
{
statusCode: 'closed',
statusName: '已关闭',
quantity: 0,
children: null,
},
]
this.treeData = arr
this.getlist() this.getlist()
this.getSystemUserList()
this.getOrderTypes()
}, },
computed: { computed: {
...mapState(['deptStaff']), ...mapState(['deptStaff']),
tableColumns() { tableColumns() {
const employeeId = this.employeeId // const employeeId = this.employeeId
return [ return [
{ label: '工单编号', key: 'taskNumber', width: 90 }, { label: '工单编号', key: 'orderNo', width: 110 },
{
label: '工单模块',
key: 'taskModuleName',
width: 110,
align: 'left',
},
{ {
label: '工单类型', label: '工单类型',
key: 'type', key: 'orderTypeTxt',
width: 60, width: 80,
render: (item) => item.taskType?.desc,
}, },
{ {
label: '工单标题', label: '工单标题',
key: 'taskTitle', key: 'title',
width: 120, minWidth: 120,
align: 'left', align: 'left',
}, },
{ {
label: '负责人', label: '负责人',
key: 'taskLeaderName', key: 'leaderName',
width: 65, width: 80,
},
{
label: '执行人',
key: 'taskCompleteUserName',
width: 65,
},
{
label: '验收人',
key: 'taskAcceptanceUserName',
width: 65,
}, },
{ label: '抄送人', key: 'ccName', width: 80 },
{ {
label: '创建人', label: '创建人',
key: 'taskCreatorName', key: 'fromBusiness',
width: 65, width: 80,
}, },
{ {
label: '工单状态', label: '工单状态',
key: 'taskStatus', key: 'orderStatusTxt',
width: 60, width: 80,
render: (item) => (
<span
style={{
color: this.getStatusColor(
item?.taskStatus?.name,
),
}}
>
{item?.taskStatus?.desc}
</span>
),
}, },
{ {
...@@ -722,10 +462,12 @@ export default { ...@@ -722,10 +462,12 @@ export default {
{ {
label: '操作', label: '操作',
fixed: 'right', fixed: 'right',
width: 135, width: 80,
align: 'left', align: 'center',
render: (item) => ( render: (item) => (
<span> <span>
{(item.orderStatus === 'PRE_HANDLING' ||
item.orderStatus === 'IN_PROGRESS') && (
<span <span
title="详情" title="详情"
class="icon-view icon-tools-view" class="icon-view icon-tools-view"
...@@ -735,239 +477,47 @@ export default { ...@@ -735,239 +477,47 @@ export default {
onClick={() => this.showDetail(item)} onClick={() => this.showDetail(item)}
></i> ></i>
</span> </span>
{this.statusCode !== '-1' &&
employeeId === item.taskCreator &&
item?.taskStatus?.name ===
'NOT_YET_ASSIGNED' &&
item.reasonForReject && (
<span
title="作废"
class="icon-view icon-del-view"
style="text-align:center;"
onClick={() => this.invalid(item)}
>
<svg
t="1635313137975"
style="margin-left:3px;margin-top:3px"
viewBox="0 0 1024 1024"
version="1.1"
xmlns="http://www.w3.org/2000/svg"
p-id="4954"
width="18"
height="18"
>
<path
d="M526.5 385.2c-17.6 0-32-14.3-32-31.9L493.9 63c0-12.8 7.6-24.4 19.4-29.5 11.8-5.1 25.4-2.6 34.7 6.2l305 290.2c9.5 9 12.5 22.9 7.7 35.1-4.9 12.2-16.6 20.1-29.7 20.1l-304.5 0.1z m31.6-247.6l0.4 183.6 192.5-0.1-192.9-183.5z"
fill="#ffffff"
p-id="4955"
></path>
<path
d="M799.2 353.9v469.3c0 27.9-11 54.2-30.9 74.1s-46.2 30.9-74.1 30.9H200.3c-27.9 0-54.2-11-74.1-30.9s-30.9-46.2-30.9-74.1V200.3c0-27.9 11-54.2 30.9-74.1 19.9-19.9 46.2-30.9 74.1-30.9h322.1v-64H200.3c-93.2 0-169 75.8-169 169v622.9c0 93.2 75.8 169 169 169h493.9c93.2 0 169-75.8 169-169V353.9h-64z"
fill="#ffffff"
p-id="4956"
></path>
<path
d="M624 497.1L314.9 806.2c-12.6 12.6-33.3 12.6-46 0-12.6-12.6-12.6-33.3 0-46L578 451.1c12.6-12.6 33.3-12.6 46 0 12.7 12.7 12.7 33.3 0 46z"
fill="#ffffff"
p-id="4957"
></path>
<path
d="M267 490.2l317 317c12.6 12.6 33.3 12.6 46 0 12.6-12.6 12.6-33.3 0-46l-317-317c-12.6-12.6-33.3-12.6-46 0-12.6 12.7-12.6 33.4 0 46z"
fill="#ffffff"
p-id="4958"
></path>
</svg>
</span>
)}
{this.statusCode !== '-1' &&
item?.taskStatus?.name ===
'NOT_YET_ASSIGNED' && (
<span
class="icon-view icon-tools-view"
title="指派给"
onClick={() => this.showAssign(item)}
>
<svg
t="1629105857363"
style="vertical-align: middle;margin-bottom: 3px;"
viewBox="0 0 1024 1024"
version="1.1"
xmlns="http://www.w3.org/2000/svg"
p-id="1916"
width="18"
height="18"
>
<path
d="M865.83 328.187H545.556l21.133-26.23a34.055 34.055 0 0 0 4.407-7.141c13.433-30.053 25.274-91.855-15.716-132.846-46.246-46.167-127.854-32.84-169.003 22.115L286.08 305.329c-17.894 11.336-74.76 48.874-105.608 86.944l-105.394 6.292c-17.203 1.036-30.636 15.318-30.636 32.574v320.008c0 17.654 14.017 32.096 31.698 32.6l122.439 3.478 270.735 86.998c3.345 1.62 33.397 15.822 68.068 15.822h0.053c40.725 0 72.741-19.592 90.528-56.334a102.65 102.65 0 0 0 7.805-27.212c23.68-0.716 63.343-11.92 82.192-74.732 6.477-23.92 6.902-46.511 1.38-65.758 23.31-12.584 38.654-34.672 42.69-63.583 2.6-18.476 4.034-40.431-2.655-61.139H863.39c57.82 0 116.173-31.83 116.173-102.953-0.002-82.166-73.22-107.944-113.732-110.147z m-3.505 147.845H620.633c-17.999 0-32.6 14.601-32.6 32.627 0 18.025 14.601 32.627 32.6 32.627 54.902 0 69.821 10.327 73.697 14.76 4.832 5.549 5.84 17.787 3.132 37.326-1.009 7.169-2.708 19.194-28.777 19.194-3.982 0-6.903-0.344-7.38-0.424-17.257-2.974-34.406 8.707-37.645 26.362-3.132 17.628 8.496 34.512 26.07 37.857 2.867 0.531 3.982 1.514 4.99 3.16 3.186 5.043 5.15 17.282 0.532 34.3-8.283 27.476-18.69 27.476-22.088 27.476-7.434 0-15.451-3.796-17.575-5.07-12.265-7.7-27.875-6.133-38.76 3.372-10.884 9.478-14.017 25.38-8.017 38.521 0.265 0.558 6.212 13.91-0.053 28.194-6.371 13.141-15.451 18.504-31.327 18.504h-0.053c-19.858 0-39.344-9.186-43.697-10.939l-279.496-90.156c-2.974-0.956-6-1.487-9.132-1.567l-95.413-2.707V461.882l90.156-5.39c10.62-0.637 20.283-6.45 25.858-15.53 15.663-25.592 69.237-64.485 99.289-82.988 3.027-1.885 5.788-4.248 8.017-7.009l104.599-126.5c19.38-25.752 52.405-35.575 71.68-16.354 15.981 16.008 7.008 46.857 3.503 56.838l-60.795 75.397c-7.91 9.769-9.451 23.202-4.035 34.538a32.576 32.576 0 0 0 29.415 18.557l386.43-0.08c8.443 0.61 50.6 5.602 50.6 44.972 0 32.787-31.857 37.699-52.033 37.699z"
fill="#fff"
p-id="1917"
></path>
</svg>
</span>
)}
{this.statusCode !== '-1' &&
item.taskCompleteUserId &&
item.taskCompleteUserId.indexOf(
employeeId,
) !== -1 &&
item?.taskStatus?.name ===
'HAS_NOT_CONFIRM' && (
<span
class="icon-view icon-tools-view"
title="确认"
onClick={() => this.confimTask(item)}
>
<i class="el-icon-circle-check"></i>
</span>
)}
{this.statusCode !== '-1' &&
item.taskCompleteUserId &&
item.taskCompleteUserId.indexOf(
employeeId,
) !== -1 &&
(item?.taskStatus?.name ===
'HAS_NOT_STARTED' ||
item?.taskStatus?.name ===
'REJECTED') && (
<span
title="开始"
class="icon-view icon-tools-view"
>
<i
class="el-icon-video-play"
onClick={() => this.startTask(item)}
></i>
</span>
)}
{this.statusCode !== '-1' &&
item.taskCompleteUserId &&
item.taskCompleteUserId.indexOf(
employeeId,
) !== -1 &&
(item?.taskStatus?.name ===
'HAS_NOT_CONFIRM' ||
item?.taskStatus?.name ===
'HAS_NOT_STARTED' ||
item?.taskStatus?.name === 'REJECTED' ||
item?.taskStatus?.name ===
'REJECTED_ING') && (
<span
title="驳回"
class="icon-view icon-del-view"
style="text-align:center;"
onClick={() => this.rejectTask(item)}
>
<svg
t="1635312421961"
style="margin-top:3px"
class="icon"
viewBox="0 0 1024 1024"
version="1.1"
xmlns="http://www.w3.org/2000/svg"
p-id="2573"
width="18"
height="18"
>
<path
fill="#fff"
d="M84.80292 468.232171l384.630101-267.805372c0 0 89.454358-47.038316 111.239524 32.574906l0 126.663818c0 0 411.269831 54.283324 374.97009 477.706963 0 0-146.379858-238.867296-374.97009-224.37728l0 137.492444c0 0 1.233084 86.883813-114.861004 47.062875L81.205998 518.906294C81.205998 518.906294 44.906258 493.562069 84.80292 468.232171z"
p-id="2574"
></path>
</svg>
</span>
)} )}
{this.statusCode !== '-1' && {item.orderStatus === 'PRE_HANDLING' && (
employeeId === item.taskCreator && <span title="确认" class="icon-view">
(item?.taskStatus?.name === 'PROCESSING' || <img
item?.taskStatus?.name === 'REJECTED' || width="24"
item?.taskStatus?.name === height="24"
'REJECTED_ING') && ( src={confirmWork}
<span onClick={() => this.confirm(item)}
title="终止" />
class="icon-view icon-del-view"
style="text-align:center;"
onClick={() => this.cadence(item)}
>
<svg
t="1627628609045"
class="icon"
style="margin-top:3px"
viewBox="0 0 1024 1024"
version="1.1"
xmlns="http://www.w3.org/2000/svg"
p-id="2698"
width="18"
height="18"
>
<path
d="M509.41569707 75.874304c-238.88418133 0-432.5376 193.65341867-432.5376 432.5376s193.65341867 432.5376 432.5376 432.5376c107.184128 0 205.26312107-38.98627413 280.8283136-103.55234133a435.09787307 435.09787307 0 0 0 17.56255573-15.8564352c10.69438293-8.75342507 19.63567787-18.8809216 19.63567787-33.1808768a37.70395307 37.70395307 0 0 0-9.74411094-25.346048l0.01201494-0.01201494-0.29709654-0.29709653a38.1026304 38.1026304 0 0 0-2.162688-2.162688L285.3830656 230.67579733c61.24776107-49.4665728 139.1722496-79.10741333 224.03263147-79.10741333 197.07876693 0 356.84352 159.76475307 356.84352 356.84352 0 28.71022933-3.39039573 56.6296576-9.79326294 83.37708373l0.0425984 0.01419947a37.91694507 37.91694507 0 0 0-1.1370496 9.22309973c0 20.9027072 16.9443328 37.84704 37.84704 37.84704 17.3146112 0 31.9029248-11.63154773 36.40415574-27.50327466l0.00218453-0.00436907 0.0065536-0.0294912c0.29709653-1.05294507 0.55268693-2.1233664 0.75912533-3.211264a429.9194368 429.9194368 0 0 0 4.554752-21.7546752c4.60281173-25.28815787 7.00689067-51.34199467 7.00689067-77.9583488 0.00109227-238.88418133-193.6523264-432.5376-432.53650773-432.5376z m-356.84352 432.5376c0-84.95213227 29.704192-162.95417173 79.26797653-224.23251627l501.82116693 501.82116694c-61.27834453 49.56378453-139.2934912 79.25377707-224.24562346 79.25377706-197.0798592 0.00109227-356.84352-159.76256853-356.84352-356.84242773z"
fill="#fff"
p-id="2699"
></path>
</svg>
</span> </span>
)} )}
{((this.statusCode !== '-1' && {item.orderStatus === 'TO_BE_ASSIGN' && (
item?.taskStatus?.name === 'PROCESSING') || <span title="指派给" class="icon-view">
item?.taskStatus?.name === <img
'REJECTED_ING') && ( width="24"
<span height="24"
title="完成" src={assignWork}
class="icon-view icon-tools-view" onClick={() => this.showAssign(item)}
> />
<i
class="el-icon-circle-check"
onClick={() =>
this.operation('1', item)
}
></i>
</span> </span>
)} )}
{this.statusCode !== '-1' && {item.orderStatus === 'TO_BE_CONFIRMED' && (
item?.taskStatus?.name === <span title="开始" class="icon-view">
'FOR_ACCEPTANCE' && <img
employeeId === item.taskAcceptanceUser && ( width="24"
<span height="24"
title="验收" src={startWork}
class="icon-view icon-tools-view"
>
<i
class="el-icon-s-claim"
onClick={() => onClick={() =>
this.operation('2', item) this.startWorkOrder(item)
} }
></i> />
</span>
)}
{employeeId === item.taskCreator &&
item?.taskStatus?.name ===
'NOT_YET_ASSIGNED' && (
<span
title="删除"
class="icon-view icon-del-view"
>
<i
class="el-icon-delete"
onClick={() => this.remove(item)}
></i>
</span> </span>
)} )}
{this.statusCode !== '-1' && {item.orderStatus === 'CLOSED' && (
this.statusCode === '8' && <span title="归档" class="icon-view">
item?.taskStatus?.name === 'COMPLETED' && <img
employeeId === item.taskAcceptanceUser && width="24"
!item.score && ( height="24"
<span src={archiveWork}
title="评价" onClick={() => this.archive(item)}
class="icon-view icon-tools-view" />
>
<i
class="el-icon-chat-dot-square"
onClick={() =>
this.operation('2', item)
}
></i>
</span> </span>
)} )}
</span> </span>
...@@ -975,308 +525,67 @@ export default { ...@@ -975,308 +525,67 @@ export default {
}, },
] ]
}, },
planTableColumns() {
return [
{ label: '工单编号', key: 'taskNumber', width: 90 },
{
label: '工单模块',
key: 'taskModuleName',
width: 120,
align: 'left',
}, },
{ methods: {
label: '工单类型', async getOrderTypes() {
key: 'type', try {
width: 120, const res = await getOrderType()
render: (item) => item.taskType?.desc, this.orderTypes = res.data
} catch (e) {
console.error(e)
}
}, },
{ sizeChange(pageSize) {
label: '工单标题', this.centerPageOptions.pageSize = pageSize
key: 'taskTitle', this.getlist()
width: 425,
align: 'left',
}, },
{ onCurrentChange(currentPage) {
label: '紧急程度', this.centerPageOptions.currentPage = currentPage
key: 'emergencyLevel', this.getlist()
width: 90,
render: (item) => (
<svg
t="1627697200171"
viewBox="0 0 1024 1024"
version="1.1"
xmlns="http://www.w3.org/2000/svg"
p-id="629"
width="18"
style="vertical-align: middle;"
height="18"
>
<title>{item.emergencyLevel?.desc}</title>
<path
fill={this.setIconColor(
item.emergencyLevel?.value,
)}
d="M444.970667 850.090667l151.978666-64.512a85.290667 85.290667 0 0 1-151.978666 64.512z m231.765333-760.746667c89.002667 48.597333 155.818667 111.018667 199.765333 187.178667 43.946667 76.117333 64.64 165.205333 62.250667 266.581333a32 32 0 0 1-64-1.536c2.133333-90.069333-15.872-167.552-53.674667-233.045333-37.802667-65.536-95.957333-119.850667-175.018666-163.029334a32 32 0 1 1 30.72-56.192z m-390.4 188.629333a248.490667 248.490667 0 0 1 324.266667 117.162667l4.181333 8.917333 54.954667 123.392 72.448 62.72c3.968 3.413333 7.381333 7.381333 11.349333 13.824l2.517333 4.906667a53.333333 53.333333 0 0 1-27.178666 70.357333L288.213333 874.24A53.333333 53.333333 0 0 1 213.333333 825.472l-0.042666-99.968-52.992-119.082667A248.405333 248.405333 0 0 1 286.293333 277.973333z m380.288-34.986666c41.258667 22.442667 74.325333 55.210667 98.816 97.621333 24.490667 42.453333 36.309333 87.466667 35.157333 134.442667a32 32 0 1 1-64-1.578667c0.853333-35.029333-7.893333-68.437333-26.581333-100.864-18.688-32.384-43.264-56.661333-74.026667-73.472a32 32 0 0 1 30.634667-56.192z"
p-id="630"
></path>
</svg>
),
}, },
{ operation() {},
label: '重要程度', async getSystemUserList() {
key: 'importanceLevel', try {
width: 90, const res = await getSystemUserList()
render: (item) => ( this.userList = res.data
<svg } catch (e) {
t="1627697337193" console.error(e)
viewBox="0 0 1024 1024" }
version="1.1"
xmlns="http://www.w3.org/2000/svg"
p-id="937"
width="18"
style="vertical-align: middle;"
height="18"
>
<title>{item.importanceLevel?.desc}</title>
<path
fill={this.setIconColor(
item.importanceLevel?.value,
)}
d="M858.1 315l-119 85.9c-15.8 11.4-37.8 7.7-49-8.2L541.6 181.8c-13.9-19.8-43.3-19.7-57.2 0.1L337.8 392.5c-11.1 15.9-33.1 19.7-48.9 8.4l-119.6-85.5c-25.5-18.2-60.2 3.8-54.6 34.6l68.9 380c3 16.6 17.5 28.7 34.3 28.7h598.3c17.1 0 31.7-12.4 34.4-29.3l62.3-380.7c5.1-30.5-29.6-51.9-54.8-33.7zM513.7 620.6c-43.1 0-78-34.9-78-78s34.9-78 78-78 78 34.9 78 78-34.9 78-78 78z"
p-id="938"
></path>
</svg>
),
}, },
{ // 确认
label: '优先级', async confirm(item) {
key: 'priorityLevel', try {
width: 90, await this.$confirm('确定执行吗?', '提示', {
render: (item) => (
<svg
t="1627697676079"
viewBox="0 0 1024 1024"
version="1.1"
xmlns="http://www.w3.org/2000/svg"
p-id="1266"
width="18"
style="vertical-align: middle;"
height="18"
>
<title>{item.priorityLevel?.desc}</title>
<path
d="M215.4 160.6H177c-8.9 0-16 7.2-16 16V849c0 8.9 7.2 16 16 16h38.4c8.9 0 16-7.2 16-16V176.7c0.1-8.9-7.1-16.1-16-16.1zM848.1 236c-189 152.5-378-180.6-567.1-28.2-8.8 7.1-16 21.3-16 30.1v430.9c0 8.9 7.2 9 16 1.9 189-152.5 378.1 180.7 567.1 28.2 8.9-7.1 16-21.3 16-30.1V237.9c0.1-8.8-7.1-9-16-1.9z"
fill={this.setIconColor(
item.priorityLevel?.value,
)}
p-id="1267"
></path>
</svg>
),
},
{
label: '工单状态',
key: 'taskStatus',
width: 120,
render: (item) => item.taskStatus?.desc,
},
{
label: '预计开始时间',
key: 'expectedStartDate',
width: 100,
},
{
label: '期望完成时间',
key: 'expectedCompletionTime',
width: 100,
},
{
label: '计划完成日期',
key: 'plannedCompletionTime',
width: 100,
},
{
label: '预计工时(h)',
key: 'planCycle',
width: 100,
},
{ label: '开始时间', key: 'startTime', width: 100 },
{
label: '实际完成时间',
key: 'actualCompletionTime',
width: 100,
},
{
label: '操作',
width: 140,
align: 'left',
render: (item) => (
<span>
<span
title="详情"
class="icon-view icon-tools-view"
>
<i
class="el-icon-tickets"
onClick={() => this.showDetail(item)}
></i>
</span>
{(item?.taskStatus?.name === 'PROCESSING' ||
item?.taskStatus?.name ===
'REJECTED_ING') && (
<span
title="完成"
class="icon-view icon-tools-view"
>
<i
class="el-icon-circle-check"
onClick={() =>
this.operation('1', item)
}
></i>
</span>
)}
{item?.taskStatus?.name ===
'HAS_NOT_STARTED' && (
<span
title="修改计划"
class="icon-view icon-tools-view"
>
<i
class="el-icon-edit-outline"
onClick={() => this.updatePlan(item)}
></i>
</span>
)}
</span>
),
},
]
},
},
methods: {
sizeChange() {},
onCurrentChange() {},
getStatusColor(type) {
if (type === 'NOT_YET_ASSIGNED') {
return '#CCCCCC'
}
if (type === 'HAS_NOT_CONFIRM') {
return '#FF0033'
}
if (type === 'HAS_NOT_STARTED') {
return '#FF9933'
}
if (type === 'PROCESSING' || type === 'REJECTED') {
return '#0066FF'
}
if (
type === 'FOR_ACCEPTANCE' ||
type === 'REJECTED_ING'
) {
return '#00CC33'
}
return '#666'
},
handleClick(v) {
this.is_tab = v
this.getlist()
},
invalid(item) {
this.$confirm('确认作废吗?', '提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',
type: 'warning', type: 'warning',
}) })
.then(() => { } catch {
axios return
.post('financeTaskManagement/invalidTask', { }
id: item.id, try {
}) const res = await workConfirmed(item.id)
.then((res) => {
this.$message.success(res.message)
this.getStatusTree()
})
.catch(() => {})
})
.catch(() => {})
},
rejectTask(item) {
this.$prompt('请输入驳回原因', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
inputPattern: /.+/,
inputErrorMessage: '驳回原因不能为空',
})
.then(({ value }) => {
axios
.post('financeTaskManagement/rejectTask', {
id: item.id,
reasonForReject: value,
})
.then((res) => {
this.$message.success(res.message)
this.getStatusTree()
})
.catch(() => {})
})
.catch(() => {})
},
submitConfim() {
this.$refs.expectedStartForm.validate((v) => {
if (v) {
axios
.get('financeTaskManagement/confirmTask', {
taskId: this.currentRowId,
expectedStartDate:
this.expectedStartForm.expectedStartDate,
planCycle: this.expectedStartForm.planCycle,
})
.then((res) => {
if (res.code === 200) { if (res.code === 200) {
this.confimVisible = false this.getlist()
this.getStatusTree() this.getOrderTree()
} else { }
this.$confirm(res.message, '提示', { } catch (e) {
confirmButtonText: '确定', console.error(e)
cancelButtonText: '取消', }
type: 'warning',
})
.then(() => {
axios
.get(
'financeTaskManagement/confirmContinueTask',
{
taskId: this.currentRowId,
expectedStartDate:
this.expectedStartForm
.expectedStartDate,
planCycle:
this.expectedStartForm
.planCycle,
isContinue: true,
}, },
) async getOrderTree() {
.then(() => { try {
this.confimVisible = false const res = await getOrderTree()
this.getStatusTree() if (res.code === 200) {
}) this.treeData = [res.data]
})
.catch(() => {})
} }
}) } catch (e) {
.catch(() => {}) console.error(e)
} else {
return false
} }
})
}, },
confimTask(item) { handleClick(v) {
this.currentRowId = item.id this.is_tab = v
this.expectedStartForm.expectedStartDate = '' this.getlist()
this.expectedStartForm.planCycle = ''
this.confimVisible = true
}, },
fullScreenDisplay(e) { fullScreenDisplay(e) {
if (e.target.nodeName === 'IMG') { if (e.target.nodeName === 'IMG') {
...@@ -1290,339 +599,161 @@ export default { ...@@ -1290,339 +599,161 @@ export default {
this.taskLeader = '' this.taskLeader = ''
this.assignVisible = true this.assignVisible = true
}, },
submitAssign() { // 开始工单
axios async startWorkOrder(item) {
.get('financeTaskManagement/assign', { try {
taskId: this.currentRowId, await this.$confirm('确定开始吗?', '提示', {
taskExecutor: this.taskLeader.join(), confirmButtonText: '确定',
}) cancelButtonText: '取消',
.then(() => { type: 'warning',
this.assignVisible = false
this.getStatusTree()
})
},
submitExpectedEnd() {
axios
.get('financeTaskManagement/startTask', {
taskId: this.currentRowId,
plannedCompletionTime: this.expectedEndTime,
})
.then((res) => {
this.$message.success(res.message)
this.getStatusTree()
this.expectedEndVisible = false
}) })
}, } catch {
return
setAssign(v, i) {
if (i === 1) {
this.assignMe2 = false
this.assignMe = v ? 'ASSIGN' : null
} else {
this.assignMe1 = false
this.assignMe = v ? true : null
}
this.getStatusTree()
},
setIconColor(index) {
if (index === 3) {
return '#F54D66'
}
if (index === 2) {
return '#FDC834'
}
if (index === 1) {
return '#5DE088'
} }
return '#ddd' try {
}, const res = await startWorder(item.id)
if (res.code === 200) {
handleNodeClick({ item }) {
if (item) {
this.statusCode = item.statusCode
this.getlist() this.getlist()
this.getOrderTree()
} }
}, } catch (e) {
getStatusTree() { console.error(e)
this.detailVisible = false
axios
.get('financeTaskManagement/getStatusTree', {
copyMe: this.assignMe,
})
.then((res) => {
this.statusTree = res.data
const bool = res.data.some(
(item) =>
item.statusCode === this.statusCode &&
item.quantity === 0,
)
if (bool) {
this.statusCode = null
}
for (let i = 1; i < res.data.length; i++) {
if (
!this.statusCode &&
res.data[i].quantity > 0
) {
this.statusCode = res.data[i].statusCode
this.defauntIndex = i
break
} else if (
this.statusCode === res.data[i].statusCode
) {
this.defauntIndex = i
break
}
} }
this.getlist()
})
}, },
startTask(item) { // 提交分派
if (item?.taskStatus?.name === 'REJECTED') { async submitAssign() {
this.$confirm('确认返工?', '提示', { if (!this.user) {
confirmButtonText: '确定', return this.$message.warning('请选择负责人')
cancelButtonText: '取消',
type: 'success',
}).then(() => {
axios
.get('financeTaskManagement/reStartTask', {
taskId: item.id,
})
.then((res) => {
this.$message.success(res.message)
this.getStatusTree()
this.expectedEndVisible = false
})
})
} else {
this.currentRowId = item.id
this.expectedEndTime = ''
this.expectedEndVisible = true
} }
},
async showEdit(v, callback) {
if (v) {
this.isEdit = true
let res = null
try { try {
res = await axios.get( const res = await workAssigned(
'financeTaskManagement/get/' + v.id, this.selections[0].id,
this.user,
) )
} catch (error) { if (res.code === 200) {
this.$message.warning(error.message) this.assignVisible = false
return this.getlist()
} this.getOrderTree()
if (res) {
this.editForm = res.data
this.editDialog = true
}
} else {
this.isEdit = false
this.editForm = {
taskAcceptanceUser: this.employeeId,
} }
this.editDialog = true } catch (e) {
this.$refs.editForm && console.error(e)
this.$refs.editForm.resetFields()
} }
callback && callback()
}, },
getlist() { handleNodeClick(data) {
// const { pageSize, currentPage } = this.statusCode = data.statusCode
// this.centerPageOptions this.getlist()
// axios
// .post('financeTaskManagement/list_page', {
// pageSize,
// currentPage,
// taskStatus: this.statusCode,
// copyMe: this.assignMe,
// startTime:
// this.periodTime && this.periodTime[0],
// endTime: this.periodTime && this.periodTime[1],
// ...this.searchForm,
// })
// .then((res) => {
// this.sourceData = res.data.records
// this.centerPageOptions.total = res.data.total
// })
this.sourceData = [{}]
}, },
planList() { async getlist() {
const { pageSize, currentPage } = this.planPageOptions this.loading = true
const { pageSize, currentPage } =
this.centerPageOptions
axios axios
.get('financeTaskManagement/getFinanceTaskRecord', { .post('platform/platformWorkOrder/list_page', {
pageSize, pageSize,
currentPage, currentPage,
orderStatus: this.statusCode,
startTime: this.periodTime && this.periodTime[0],
endTime: this.periodTime && this.periodTime[1],
...this.searchForm,
}) })
.then((res) => { .then((res) => {
if (res.code === 200) { this.sourceData = res.data.records
this.planData = res.data.records this.centerPageOptions.total = res.data.total
this.planPageOptions.total = res.data.total this.loading = false
} else {
this.$alert(res.message, '错误提示', {
dangerouslyUseHTMLString: true,
})
}
}) })
}, },
onSubmit() { async archive(item) {
this.editDialog = false try {
this.getStatusTree() await this.$confirm('确定归档吗?', '提示', {
},
operation(type, row) {
this.currentRowId = row.id
this.rework = row.rework
if (type === '1') {
this.$confirm('确认完成?', '提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',
type: 'success', type: 'warning',
})
.then(() => {
axios
.post(
'financeTaskManagement/completeTask/' +
row.id,
)
.then((res) => {
this.$message.success(res.message)
this.getStatusTree()
})
})
.catch((err) => {
console.log(err)
}) })
} else { } catch {
this.commentsVisible = true return
this.commentsForm = {}
} }
}, try {
commentsSubmit() { const res = await archiveWorkOrder(item.id)
if ( if (res.code === 200) {
this.rework == null && this.getlist()
this.commentsForm.score < 4 && this.getOrderTree()
this.commentsForm.taskRating
) {
this.$alert(
'若您不满意,请选择不通过',
'错误提示',
{
dangerouslyUseHTMLString: true,
},
)
} else {
let url = 'financeTaskManagement/acceptanceTask'
if (this.statusCode === '8') {
url = 'financeTaskManagement/score'
} }
axios } catch (e) {
.post(url, { console.error(e)
id: this.currentRowId,
rework: this.rework,
...this.commentsForm,
})
.then((res) => {
this.$message.success(res.message)
this.commentsVisible = false
this.getStatusTree()
})
} }
}, },
archive() {
if (emptyArray(this.selections)) return
axios
.get('financeTaskManagement/archive', {
ids: getIds(this.selections, true),
})
.then((res) => {
this.$message.success(res.message)
this.getStatusTree()
})
},
selectionChange(selection) { selectionChange(selection) {
this.selections = selection this.selections = selection
}, },
cadence(item) { async reply() {
this.currentRowId = item.id if (!this.textarea) {
this.terminationVisible = true return this.$message.warning('请输入内容')
}, }
submitCadence() {
axios try {
.post('financeTaskManagement/terminateTheTask', { const res = await replyTocustomer(
id: this.currentRowId, this.currentRowId,
reasonForTermination: this.terminationReason, this.textarea,
timeConsuming: this.timeConsuming,
})
.then((res) => {
this.$message.success(res.message)
this.terminationVisible = false
this.getStatusTree()
})
},
remove(item) {
this.$confirm('确定删除选中的信息?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
})
.then(() => {
axios
.post(
'financeTaskManagement/deleteTask/' + item.id,
) )
.then((res) => { if (res.code === 200) {
this.$message.success(res.message) this.showDetail(this.detail)
this.getStatusTree() }
}) } catch (e) {
}) console.error(e)
.catch((err) => { }
console.log(err)
})
},
showDetail(item) {
this.detailVisible = true
// axios
// .get('financeTaskManagement/get/' + item.id)
// .then((res) => {
// this.detail = res.data
// this.detailVisible = true
// })
}, },
updatePlan(item) { async showDetail(item) {
axios
.get('financeTaskManagement/get/' + item.id)
.then((res) => {
this.expectedStartDate =
res.data.expectedStartDate
this.planCycle = res.data.planCycle
})
this.updateVisible = true
this.currentRowId = item.id this.currentRowId = item.id
}, this.detail = item
updateTime() {
axios axios
.get('financeTaskManagement/editTaskTime', { .get(
taskId: this.currentRowId, `platform/platformWorkOrderChat/getByWorkOrder?workOrderId=${item.id}`,
expectedStartDate: this.expectedStartDate, )
planCycle: this.planCycle,
})
.then((res) => { .then((res) => {
this.$message.success(res.message) if (res.code === 200) {
this.planList() this.chatRecord = res.data
this.updateVisible = false }
}) })
this.detailVisible = true
this.textarea = ''
}, },
}, },
} }
</script> </script>
<style scoped> <style lang="scss" scoped>
.wraper { .wraper {
height: 100%; height: 100%;
display: flex; display: flex;
overflow: hidden; overflow: hidden;
&::v-deep {
.el-tree-node {
font-size: 14px;
}
.el-tree-node__content {
height: 32px;
padding: 4px 0px;
padding-left: 10px !important;
}
.el-tree-node__children .el-tree-node.is-current {
.el-tree-node__content {
position: relative;
color: #1565c0;
font-size: 16px;
}
.el-tree-node__content::before {
position: absolute;
content: '';
top: 0;
bottom: 0;
left: 0;
width: 4px;
display: block;
background-color: #1565c0;
}
}
}
} }
.page_left { .page_left {
width: 200px; width: 200px;
...@@ -1639,45 +770,6 @@ export default { ...@@ -1639,45 +770,6 @@ export default {
border-radius: 5px; border-radius: 5px;
overflow: hidden; overflow: hidden;
} }
.top_wrap {
display: flex;
border-bottom: 1px solid #ddd;
}
.tab_bar {
width: 220px;
margin-right: 6px;
box-sizing: border-box;
font-size: 0;
display: flex;
margin-bottom: -1px;
}
.tab_bar li {
flex: 1;
height: 38px;
line-height: 38px;
background: #fff;
cursor: pointer;
user-select: none;
}
.tab_bar span {
display: block;
text-align: center;
color: #333;
font-size: 16px;
}
.tab_bar li + li {
border-left: 1px solid #ddd;
}
.tab_bar li:nth-last-child(1) {
border-right: 1px solid #ddd;
}
.tab_bar li.active {
border-bottom: 1px solid #fff;
}
.tab_bar li.active span {
color: #3366ff;
}
.search_form { .search_form {
margin-top: 5px; margin-top: 5px;
margin-left: 10px; margin-left: 10px;
...@@ -1685,27 +777,13 @@ export default { ...@@ -1685,27 +777,13 @@ export default {
.search_form >>> .el-form-item { .search_form >>> .el-form-item {
margin-bottom: 5px; margin-bottom: 5px;
} }
.page_content { .content {
display: flex;
height: calc(100% - 40px);
padding: 10px 10px 0 10px;
box-sizing: border-box;
flex-direction: column;
}
.main {
height: 100%;
padding-top: 10px;
display: flex;
flex-direction: column;
}
.detail_list {
max-height: 68vh; max-height: 68vh;
overflow: auto; overflow: auto;
} }
.item_wrap { .detail_list {
background: #efefef;
padding-top: 10px; padding-top: 10px;
background-color: #efefef;
} }
.detail_list .item { .detail_list .item {
display: inline-block; display: inline-block;
...@@ -1723,6 +801,20 @@ export default { ...@@ -1723,6 +801,20 @@ export default {
.detail_list .item .value { .detail_list .item .value {
color: #222; color: #222;
} }
.item_wrap {
background: #efefef;
padding-top: 10px;
}
.detail_list .item .label {
display: inline-block;
color: #999;
width: 100px;
text-align: right;
margin-right: 5px;
}
.detail_list .item .value {
color: #222;
}
.form_item >>> .el-radio { .form_item >>> .el-radio {
margin-right: 13px; margin-right: 13px;
} }
...@@ -1742,25 +834,146 @@ export default { ...@@ -1742,25 +834,146 @@ export default {
.detail_btn + .detail_btn { .detail_btn + .detail_btn {
margin-left: 10px; margin-left: 10px;
} }
.split_line { .table-wrap {
height: 1px; background: #fff;
background: #ddd; flex: 1;
overflow: hidden;
width: 100%;
}
.step-bar {
margin-bottom: 10px; margin-bottom: 10px;
} }
.log_item { .step {
position: relative;
width: 25%;
font-size: 14px;
height: 32px;
line-height: 32px;
color: #fff;
background-color: #cacaca;
z-index: 1;
text-align: center;
}
.step,
.step span {
display: inline-block;
}
.step span {
width: 90%;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.step-before:before {
left: -16px;
z-index: 8;
border-top: 16px solid #cacaca;
border-left: 16px solid transparent !important;
border-bottom: 16px solid #cacaca;
}
.step-after:after {
width: 22px;
height: 32px;
right: 0;
z-index: 9;
border-top: 16px solid transparent !important;
border-left: 16px solid #cacaca;
border-bottom: 16px solid transparent !important;
background-color: #fff;
}
.step-after:after,
.step-before:before {
content: '';
display: block;
position: absolute;
top: 0;
box-sizing: border-box;
}
.step-active {
background-color: #ff6a00;
}
.step-active:after,
.step-active:before {
border-color: #ff6a00;
}
.step-pass {
background-color: rgba(255, 106, 0, 0.5);
}
.step-pass:after,
.step-pass:before {
border-color: rgba(255, 106, 0, 0.5);
}
.record {
border: 1px solid #efefef;
margin-top: 10px;
}
.record .title {
height: 40px;
line-height: 40px;
font-size: 16px;
padding-left: 10px;
background: #efefef;
border-left: 2px solid #ff6a00;
}
.chat_content {
padding: 10px;
}
.chat_item {
margin-bottom: 10px;
}
.chat_item.chat_right {
text-align: right;
}
.chat_warp {
display: flex; display: flex;
} }
.log_item > div:nth-of-type(1) { .chat_right .chat_warp {
width: 130px; justify-content: end;
} }
.log_item > div:nth-of-type(2) { .chat_icon {
flex: 1; width: 30px;
margin-right: 10px; height: 30px;
background: #efefef;
border-radius: 50%;
margin-top: 5px;
margin-right: 5px;
margin-left: 5px;
} }
.table-wrap {
background: #fff; .empty-data {
flex: 1; display: flex;
overflow: hidden; align-items: center;
width: 100%; justify-content: center;
padding: 20px 0;
}
.detail_list {
&::v-deep {
table {
border-right: 1px solid #000000;
border-bottom: 1px solid #000000;
text-align: center;
width: 100% !important;
border-spacing: 0;
}
table th {
border-left: 1px solid #000000;
border-top: 1px solid #000000;
padding: 6px;
}
table td {
border-left: 1px solid #000000;
border-top: 1px solid #000000;
padding: 6px;
height: 20px;
}
}
} }
</style> </style>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment