Commit 6cf559c2 authored by 李苏's avatar 李苏 💬

履职设置

parent bacbf533
......@@ -727,6 +727,20 @@ export const powerRoutes=[
name:'performanceReport',
path:"performanceReport"
},
{
component:'daily/performanceReportSet/index',
hidden:false,
meta:{
"title": "履职设置",
"icon": "",
"noCache": false,
"link": null,
"mkid":'test',
},
name:'performanceReportSet',
path:"performanceReportSet"
},
]
},
......
This diff is collapsed.
<template>
<div class="min_full">
<!-- 查询条件-->
<div class="search" v-condition>
<SearchButton :app='app'></SearchButton>
<el-row :gutter="20" class="search-row-1">
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">名称:</span>
<el-input v-model="queryParams.name"></el-input>
</div>
</el-col>
</el-row>
</div>
<!-- 按钮操作-->
<el-row class="tool-bar">
<!-- <PrintButton :app='app'></PrintButton> -->
<ViewButton ref="view" :app='app'></ViewButton>
<AddButton ref="add" :app='app'></AddButton>
<CopyButton ref="copy" :app='app'></CopyButton>
<EditButton ref="edit" :app='app'></EditButton>
<!-- <FieldButton :app='app'></FieldButton>
<ExcelButton :app='app'></ExcelButton> -->
<el-button @click="doStart" size='mini'type="primary">启动</el-button>
<el-button @click="doStop" size='mini' type="primary">停止</el-button>
<el-button @click="doExcute" size='mini' type="primary">立即执行</el-button>
<!-- 额外按钮-->
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem'
@getRow='getRow'>
</TablePager>
</div>
</div>
</template>
<script>
/* 引入需要的接口*/
import {
doQuery,
doAdd,
doUpdate,
doDelete,
doQueryDetail,
start,
stop,
excute
} from '@/api/riskPrecontrol/riskSet';
/* edit页面*/
import Edit from './edit'
import {
tableMixin
} from 'common'
export default {
mixins: [tableMixin],
name: 'maintenanceRisk',
/* 初始额外赋值*/
async mounted() {
this.$refs['TablePager'].pageQuery()
},
data() {
return {
/*需要的额外参数 */
showDialog: false,
DialogName: '',
type: '',
DialogTitle: '',
/* 基础url*/
baseUrl: '/aqgl/fxsj',
/* 查询参数*/
queryParams: {
name:'',
},
/* 表格标题对应参数*/
tableTitle: [
{label:"名称", prop:"name",width: 230},
{label:"公司", prop:"gsName",width: 230},
{label: "描述", prop: "desc",width: 230},
{label: "上次执行时间", prop: "pretime",width: 200},
{label: "下次执行时间", prop: "nexttime",width: 200},
{label: "状态", prop: "status",width:90,formatter:function (a,b,value) {
var map={1:"正在运行",0:"停止"};
return map[value]||map[0];
}},
{label: "执行结果", prop: "result",width: 390}
]
}
},
methods: {
doStart(){
if (this.app.selectOne || this.app.clickOne) {
this.singleItem.id&&start(this.singleItem.id).then(e=>{
if(e.success){
this.$success('操作成功')
this.$refs['TablePager'].reLoad()
}
})
} else {
this.$warning('请选中一行操作');
}
},
doStop(){
if (this.app.selectOne || this.app.clickOne) {
this.singleItem.id&&stop(this.singleItem.id).then(e=>{
if(e.success){
this.$success('操作成功')
this.$refs['TablePager'].reLoad()
}
})
} else {
this.$warning('请选中一行操作');
}
},
doExcute(){
if (this.app.selectOne || this.app.clickOne) {
this.singleItem.id&&excute(this.singleItem.id).then(e=>{
if(e.success){
this.$success('操作成功')
this.$refs['TablePager'].reLoad()
this
}
})
} else {
this.$warning('请选中一行操作');
}
},
query: doQuery,
/* 基础增*/
apiAdd: doAdd,
/* 基础更新*/
apiUpdate: doUpdate,
/* 删除操作*/
apiDelete: doDelete,
/* 初始化赋值操作*/
queryDetail:doQueryDetail,
init() {
},
},
components: {
Edit,
}
}
</script>
<style scoped>
</style>
<template>
<DefaultDialog :app='app'>
<div slot="form" style="height: 70vh;">
<!-- 按钮-->
<div class="min_full" style='height:100%;width: 100%;'>
<div class="search" v-condition>
<SearchButton :app='this'></SearchButton>
<el-row :gutter="20" class="search-row-1">
<el-col :span="12" class="search-col">
<div class="search-item">
<span class="search-span">任务类型:</span>
<RelSelect style="width: 100%;" src='aqgl/fxyk/fxpc/init/rwlx' clearable :match="{value:'id',label:'name'}" v-model='queryParams.rwlx' ></RelSelect>
</div>
</el-col>
<el-col :span="12" class="search-col">
<div class="search-item">
<span class="search-span">人员:&nbsp;&nbsp;</span>
<el-input v-model='queryParams.condition' ></el-input>
</div>
</el-col>
</el-row>
</div>
<div class="tablePagers">
<TablePager showSelection :delButton='false' @getData='getData' :ref="'TablePager'" :app='this' :query='query' @selectItem='selectItem'
@getRow='getRow'>
</TablePager>
</div>
</div>
<!-- 表格-->
</div>
<div slot="reFooter" class="refooter">
<span slot="footer" class="dialog-footer" style="position: absolute;right: 10px;top: 12px;">
<el-button @click="app.showDialog=false">取 消</el-button>
<el-button type="primary" @click="save()">保 存</el-button>
</span>
</div>
</DefaultDialog>
</template>
<script>
import {
doQuery,
doAdd,
doUpdate,
doDelete,
doQueryJcnr,
doAddJcnr,
doUpdateJcnr,
doDeleteJcnr,
doAutoGen,
doQueryScgw
} from "@/api/riskPrecontrol/screeningCriteria.js";
import {
tableMixin_noapp
} from 'common'
export default {
mixins:[tableMixin_noapp],
props: {
app: {
type: Object,
default: {}
}
},
async mounted() {
this.$nextTick(()=>{
this.queryParams.gsid=this.app.form.gsid
this.queryParams.notInIds=this.app.notInIds
// this.queryParams.bmid=this.app.form.bmid
this.$refs['TablePager'].pageQuery()
})
},
methods: {
query: doQueryJcnr,
/* 基础增*/
apiAdd: doAdd,
/* 基础更新*/
apiUpdate: doUpdate,
/* 删除操作*/
apiDelete: doDelete,
save(){
if(this.multipleSelection.length==0){
this.$warning('请勾选一条数据')
return
}else{
let idList=[]
this.app.formDetail.forEach(e=>{
idList.push(e.id)
})
this.multipleSelection.forEach(item=>{
item.jcnrid=item.id
item.id=''
})
let addData=this.multipleSelection.filter((item)=>{
if(idList.indexOf(item.jcnrid)==-1){
return true
}else{
return false
}
})
this.app.formDetail=[...this.app.formDetail,...addData]
console.log(this.app.formDetail)
this.app.showDialog=false
}
}
},
data() {
return {
queryParams:{
gwid:'',
condition:'',
rwlx:'',
notInIds:[]
},
tableTitle: [
{label: "检查内容", prop: "nr", fieldType: "ftString",width:300},
{label: "岗位", prop: "scgwName", fieldType: "ftString",width:150},
{label: "任务类型", prop: "rwlxName", fieldType: "ftString",width:150},
{label: "检查人", prop: "fzrName", fieldType: "ftString",width:150},
],
baseUrl: '/aqgl/fxyk/fxbz',
}
}
}
</script>
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