rev:修改任务下发字段与acs反馈统一;add
This commit is contained in:
@@ -74,6 +74,15 @@
|
||||
</el-form>
|
||||
</div>
|
||||
<!--如果想在工具栏加入更多按钮,可以使用插槽方式, slot = 'left' or 'right'-->
|
||||
<span>
|
||||
未完成数:
|
||||
<el-input
|
||||
v-model="undo"
|
||||
clearable
|
||||
style="width: 60px"
|
||||
/>
|
||||
<el-button type="primary" @click="taskScheduler()">任务调度</el-button>
|
||||
</span>
|
||||
<crudOperation :permission="permission"/>
|
||||
<!--表单组件-->
|
||||
<el-dialog :close-on-click-modal="false" :before-close="crud.cancelCU" :visible.sync="crud.status.cu > 0"
|
||||
@@ -181,7 +190,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import crudSchBaseTask from './schBaseTask'
|
||||
import crudSchBaseTask, {scheduler} from './schBaseTask'
|
||||
// import crudSchBaseTaskconfig from './config/schBaseTaskconfig'
|
||||
import CRUD, {crud, form, header, presenter} from '@crud/crud'
|
||||
import rrOperation from '@crud/RR.operation'
|
||||
@@ -238,6 +247,7 @@ export default {
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
undo: 0,
|
||||
permission: {},
|
||||
rules: {},
|
||||
taskStatusList: [],
|
||||
@@ -261,29 +271,28 @@ export default {
|
||||
this.crud.toQuery()
|
||||
},
|
||||
doOperate(row, command) {
|
||||
let method_name = ''
|
||||
let status = ''
|
||||
switch (command) {
|
||||
case 'a':// 完成
|
||||
method_name = '90'
|
||||
status = '90'
|
||||
break
|
||||
case 'b':// 取消
|
||||
method_name = '100'
|
||||
status = '100'
|
||||
break
|
||||
case 'c':// 下发
|
||||
method_name = '20'
|
||||
status = '20'
|
||||
break
|
||||
case 'd':// 详情
|
||||
method_name = 'view'
|
||||
status = 'view'
|
||||
break
|
||||
}
|
||||
if (method_name === 'view') {
|
||||
if (status === 'view') {
|
||||
// this.view(row)
|
||||
return
|
||||
}
|
||||
const data = {
|
||||
task_code: row.task_code,
|
||||
method_name: method_name,
|
||||
config_code: row.config_code
|
||||
taskCode: row.task_code,
|
||||
status: status
|
||||
}
|
||||
crudSchBaseTask.operation(data).then(res => {
|
||||
this.crud.toQuery()
|
||||
@@ -291,7 +300,12 @@ export default {
|
||||
}).catch(err => {
|
||||
console.log(err.response.data.message)
|
||||
})
|
||||
|
||||
},
|
||||
taskScheduler(){
|
||||
crudSchBaseTask.scheduler().then(res => {
|
||||
this.crud.toQuery()
|
||||
this.crud.notify('操作成功', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -38,5 +38,11 @@ export function operation(data) {
|
||||
data
|
||||
})
|
||||
}
|
||||
export function scheduler() {
|
||||
return request({
|
||||
url: 'api/schBaseTask/taskSchedule',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
|
||||
export default { add, edit, del, getTaskStatusList, operation}
|
||||
export default { add, edit, del, getTaskStatusList, operation, scheduler}
|
||||
|
||||
Reference in New Issue
Block a user