Browse Source

工作流统一升级

master
陈裕财 5 years ago
parent
commit
db2e3ddb81
  1. 20
      src/views/mdp/workflow/biz/bizModel/BizModelMng.vue
  2. 36
      src/views/mdp/workflow/de/model/ModelMng.vue
  3. 475
      src/views/mdp/workflow/hi/procinst/ProcinstMng.vue
  4. 22
      src/views/mdp/workflow/re/deployment/DeploymentMng.vue
  5. 12
      src/views/mdp/workflow/re/procdef/ProcdefListForBizStart.vue
  6. 42
      src/views/mdp/workflow/re/procdef/ProcdefListForParames.vue
  7. 329
      src/views/mdp/workflow/re/procdef/ProcdefListForSimpleStart.vue
  8. 252
      src/views/mdp/workflow/re/procdef/ProcdefListForStart.vue
  9. 36
      src/views/mdp/workflow/re/procdef/ProcdefMng.vue
  10. 39
      src/views/mdp/workflow/re/procdef/ProcdefSuspend.vue
  11. 38
      src/views/mdp/workflow/re/procdefParames/ProcdefParamesSet.vue
  12. 1223
      src/views/mdp/workflow/ru/execution/ExecutionMng.vue
  13. 55
      src/views/mdp/workflow/ru/procinstParames/ProcinstParamesExecutionSet.vue
  14. 67
      src/views/mdp/workflow/ru/procinstParames/ProcinstParamesStartSet.vue
  15. 705
      src/views/mdp/workflow/ru/task/TaskMng.vue

20
src/views/mdp/workflow/biz/bizModel/BizModelMng.vue

@ -7,10 +7,10 @@
<el-button type="primary" v-loading="load.list" :disabled="load.list==true" v-on:click="searchBizModels" icon="el-icon-search">查询</el-button> <el-button type="primary" v-loading="load.list" :disabled="load.list==true" v-on:click="searchBizModels" icon="el-icon-search">查询</el-button>
</template> </template>
</el-input> </el-input>
<el-button type="primary" @click="showAdd" icon="el-icon-plus">业务模块</el-button>
<el-button type="danger" v-loading="load.del" @click="batchDel" :disabled="this.sels.length===0 || load.del==true" icon="el-icon-delete"></el-button>
<el-button @click="showAdd" icon="el-icon-plus" style="margin-left: 13px;">业务模块</el-button>
<el-button type="danger" v-loading="load.del" @click="batchDel" :disabled="this.sels.length===0 || load.del==true" icon="el-icon-delete">批量删除</el-button>
</el-row> </el-row>
<el-row style="padding-top:10px;">
<el-row style="padding-top:20px;">
<!--列表 BizModel mdp_biz_model--> <!--列表 BizModel mdp_biz_model-->
<el-table ref="table" :max-height="tableHeight" :data="bizModels" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;"> <el-table ref="table" :max-height="tableHeight" :data="bizModels" highlight-current-row v-loading="load.list" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column sortable type="selection" width="40"></el-table-column> <el-table-column sortable type="selection" width="40"></el-table-column>
@ -261,3 +261,17 @@
<style scoped> <style scoped>
</style> </style>
<style>
.el-input-group__append, .el-input-group__prepend {
background-color: #409EFF!important;
color: #ffffff!important;
vertical-align: middle;
display: table-cell;
position: relative;
border: 1px solid #409EFF!important;
padding: 0 20px;
width: 1px;
white-space: nowrap;
}
</style>

36
src/views/mdp/workflow/de/model/ModelMng.vue

@ -2,17 +2,17 @@
<section> <section>
<el-row class="app-container"> <el-row class="app-container">
<el-row> <el-row>
<el-input v-model="filters.key" style="width:30%;" placeholder="模糊查询">
<el-input v-model="filters.key" style="width:270px;" placeholder="模糊查询">
<template slot="append"> <template slot="append">
<el-button type="primary" v-on:click="searchModels" icon="el-icon-search">查询</el-button> <el-button type="primary" v-on:click="searchModels" icon="el-icon-search">查询</el-button>
</template> </template>
</el-input> </el-input>
<el-button
<el-button style="margin-left: 13px;"
@click="handleDownload" @click="handleDownload"
icon="el-icon-download" icon="el-icon-download"
>导出数据</el-button> >导出数据</el-button>
</el-row> </el-row>
<el-row style="padding-top:10px;">
<el-row style="padding-top:20px;">
<!--列表 Model act_de_model--> <!--列表 Model act_de_model-->
<el-table ref="table" :max-height="tableHeight" :data="models" highlight-current-row v-loading="listLoading" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;"> <el-table ref="table" :max-height="tableHeight" :data="models" highlight-current-row v-loading="listLoading" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column type="index" width="40"></el-table-column> <el-table-column type="index" width="40"></el-table-column>
@ -21,18 +21,8 @@
<el-link type="primary" @click="showDeploymentList( scope.row,scope.$index)">{{scope.row.name}} </el-link> <el-link type="primary" @click="showDeploymentList( scope.row,scope.$index)">{{scope.row.name}} </el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column sortable prop="version" label="模型版本" min-width="80" show-overflow-tooltip></el-table-column>
<el-table-column sortable prop="version" label="模型版本" min-width="100" show-overflow-tooltip></el-table-column>
<el-table-column prop="description" label="描述" width="120" show-overflow-tooltip> <el-table-column prop="description" label="描述" width="120" show-overflow-tooltip>
<template slot-scope="scope">
<el-popover
placement="top-start"
title="描述"
width="400"
trigger="click"
:content="scope.row.description">
<el-button slot="reference">详细描述</el-button>
</el-popover>
</template>
</el-table-column> </el-table-column>
<el-table-column prop="modelComment" label="备注" min-width="80" show-overflow-tooltip></el-table-column> <el-table-column prop="modelComment" label="备注" min-width="80" show-overflow-tooltip></el-table-column>
@ -42,8 +32,8 @@
<el-table-column label="操作" width="300" fixed="right"> <el-table-column label="操作" width="300" fixed="right">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button @click="showDiagram( scope.row,scope.$index)">流程图</el-button> <el-button @click="showDiagram( scope.row,scope.$index)">流程图</el-button>
<el-button @click="deploy( scope.row,scope.$index)">发布新版</el-button>
<el-button type="danger" @click="handleDel(scope.row,scope.$index)"></el-button>
<el-button @click="deploy( scope.row,scope.$index)" type="primary" icon="el-icon-position"></el-button>
<el-button type="danger" @click="handleDel(scope.row,scope.$index)" icon="el-icon-delete"></el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -409,3 +399,17 @@
<style scoped> <style scoped>
</style> </style>
<style>
.el-input-group__append, .el-input-group__prepend {
background-color: #409EFF!important;
color: #ffffff!important;
vertical-align: middle;
display: table-cell;
position: relative;
border: 1px solid #409EFF!important;
padding: 0 20px;
width: 1px;
white-space: nowrap;
}
</style>

475
src/views/mdp/workflow/hi/procinst/ProcinstMng.vue

@ -1,67 +1,38 @@
<template> <template>
<section> <section>
<el-row class="app-container"> <el-row class="app-container">
<el-col :xs="4" :sm="4" :md="3" :lg="3" :xl="3" class="hidden-sm-and-down">
<category-tree
ref="categoryTree"
multiple
:expandOnClickNode="false"
:defaultExpandAll="true"
show-checkbox
:current-key="addForm.categoryId"
v-on:check-change="handleCategoryCheckChange"
></category-tree>
</el-col>
<el-col :xs="24" :sm="24" :md="21" :lg="21" :xl="21">
<!-- <el-col :xs="4" :sm="4" :md="3" :lg="3" :xl="3" class="hidden-md-and-down">
<category-tree ref="categoryTree" multiple :expandOnClickNode="false" :defaultExpandAll="true" show-checkbox
:current-key="addForm.categoryId" v-on:check-change="handleCategoryCheckChange"></category-tree>
</el-col> -->
<el-col :xs="24" :sm="24" :md="24" :lg="24" :xl="24">
<!--列表 Procinst act_hi_procinst--> <!--列表 Procinst act_hi_procinst-->
<el-row> <el-row>
<el-select v-model="filters.filterType" clearable placeholder="查询范围" class="hidden-md-and-down">
<el-select v-model="filters.filterType" clearable placeholder="查询范围" class="hidden-lg-and-down">
<el-option value="" label="全部"> </el-option> <el-option value="" label="全部"> </el-option>
<el-option value="startUserId" label="我发起"> </el-option> <el-option value="startUserId" label="我发起"> </el-option>
<el-option value="partake" label="我参与"> </el-option> <el-option value="partake" label="我参与"> </el-option>
<el-option value="sponsors" label="我主办"> </el-option> <el-option value="sponsors" label="我主办"> </el-option>
<el-option value="monitors" label="我监控"> </el-option> <el-option value="monitors" label="我监控"> </el-option>
</el-select> </el-select>
<el-select v-model="filters.procCategory" clearable filterable placeholder="选择分类" class="hidden-sm-and-down">
<el-option v-for="item in categorys" :key="item" :label="item" :value="item"></el-option>
</el-select>
<el-date-picker
v-model="filters.startTimeRanger" class="hidden-sm-and-down"
type="daterange"
align="right"
unlink-panels
range-separator="至"
start-placeholder="创建日期"
end-placeholder="创建日期"
value-format="yyyy-MM-dd"
:default-time="['00:00:00','23:59:59']"
:picker-options="pickerOptions">
<el-date-picker v-model="filters.startTimeRanger" class="hidden-sm-and-down" type="daterange" align="right"
unlink-panels range-separator="-" start-placeholder="创建日期" end-placeholder="创建日期" value-format="yyyy-MM-dd"
:default-time="['00:00:00','23:59:59']" :picker-options="pickerOptions">
</el-date-picker> </el-date-picker>
<el-input v-model="filters.key" style="width:20%;" placeholder="模糊查询">
<el-input v-model="filters.key" style="width:270px;" placeholder="模糊查询">
<template slot="append"> <template slot="append">
<el-button v-on:click="searchProcinsts" icon="el-icon-search">查询</el-button> <el-button v-on:click="searchProcinsts" icon="el-icon-search">查询</el-button>
</template> </template>
</el-input> </el-input>
<el-popover
placement="top"
width="375"
trigger="manual"
v-model="weixinContentVisible">
<p>{{weixinContent}}</p>
<div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="doCopyWeixinUrl">拷贝链接</el-button>
<el-button type="primary" size="mini" @click="doCopyWeixinContent">拷贝内容</el-button>
</div>
<el-button slot="reference" class="hidden-sm-and-down" v-on:click="showWeixin">微信催办</el-button>
</el-popover>
<el-popover
title="更多查询条件"
placement="top-start"
width="400"
trigger="click">
<el-popover title="更多查询条件" placement="top-start" width="400" trigger="click">
<el-row class="more-filter-item"> <el-row class="more-filter-item">
<el-col :span="24"> <el-col :span="24">
<font class="more-label-font"> <font class="more-label-font">
查询范围
查询范围
</font> </font>
<el-select size="mini" v-model="filters.filterType" placeholder="查询范围"> <el-select size="mini" v-model="filters.filterType" placeholder="查询范围">
<el-option value="" label="全部"> </el-option> <el-option value="" label="全部"> </el-option>
@ -73,57 +44,42 @@
</el-col> </el-col>
<el-col :span="24"> <el-col :span="24">
<font class="more-label-font"> <font class="more-label-font">
标签查找
分类
</font>
<el-select size="mini" v-model="filters.procCategory" clearable filterable placeholder="选择分类" >
<el-option v-for="item in categorys" :key="item" :label="item" :value="item"></el-option>
</el-select>
</el-col>
<el-col :span="24">
<font class="more-label-font">
标签查找
</font> </font>
<el-row v-show="filters.tags && filters.tags.length>0"> <el-row v-show="filters.tags && filters.tags.length>0">
<el-tag
:key="tag.tagId"
v-for="tag in filters.tags"
:type="''"
closable
:disable-transitions="false"
@click="showTagSelect(false)"
@close="handleFiltersTagClose(tag,'tags')">
<el-tag :key="tag.tagId" v-for="tag in filters.tags" :type="''" closable :disable-transitions="false"
@click="showTagSelect(false)" @close="handleFiltersTagClose(tag,'tags')">
{{tag.tagName}} {{tag.tagName}}
</el-tag> </el-tag>
</el-row> </el-row>
<el-button v-if="filters.tags==null || filters.tags.length==0" size="mini" @click.native="showTagSelect(false)">选择标签</el-button>
<el-button v-if="filters.tags==null || filters.tags.length==0" size="mini"
@click.native="showTagSelect(false)">选择标签</el-button>
</el-col> </el-col>
<el-col :span="24" >
<el-col :span="24">
<font class="more-label-font"> <font class="more-label-font">
任务执行人
任务执行
</font> </font>
<el-tag v-if="filters.assignee"
:type="'success'"
closable
:disable-transitions="false"
@click="userSelectVisible=true"
@close="handleFiltersTagClose('','assignee')">
<el-tag v-if="filters.assignee" :type="'success'" closable :disable-transitions="false"
@click="userSelectVisible=true" @close="handleFiltersTagClose('','assignee')">
{{filters.assignee.username}} {{filters.assignee.username}}
</el-tag> </el-tag>
<el-button v-else size="mini" @click.native="userSelectVisible=true" >选择执行人</el-button>
</el-col>
<el-col :span="24" >
<el-button size="mini" :type="filters.suspensionState=='2'?'success':''" v-on:click="filters.suspensionState='2'">挂起的</el-button>
<el-button size="mini" :type="filters.suspensionState=='1'?'success':''" v-on:click="filters.suspensionState='1'">活动的</el-button>
<el-button v-else size="mini" @click.native="userSelectVisible=true">选择执行人</el-button>
</el-col> </el-col>
<el-col :span="24"> <el-col :span="24">
<font class="more-label-font"> <font class="more-label-font">
开始日期 开始日期
</font> </font>
<el-date-picker
v-model="filters.startTimeRanger"
type="daterange"
align="right"
unlink-panels
range-separator="至"
start-placeholder="创建日期"
end-placeholder="创建日期"
value-format="yyyy-MM-dd"
:default-time="['00:00:00','23:59:59']"
:picker-options="pickerOptions">
<el-date-picker v-model="filters.startTimeRanger" type="daterange" align="right" unlink-panels
range-separator="-" start-placeholder="创建日期" end-placeholder="创建日期" value-format="yyyy-MM-dd"
:default-time="['00:00:00','23:59:59']" :picker-options="pickerOptions">
</el-date-picker> </el-date-picker>
</el-col> </el-col>
<el-col :span="24"> <el-col :span="24">
@ -131,51 +87,33 @@
<font class="more-label-font"> <font class="more-label-font">
计划完成日期 计划完成日期
</font> </font>
<el-date-picker
v-model="filters.planFinishTimeRanger"
type="daterange"
align="right"
unlink-panels
range-separator="至"
start-placeholder="计划完成日期"
end-placeholder="计划完成日期"
value-format="yyyy-MM-dd"
:default-time="['00:00:00','23:59:59']"
:picker-options="pickerOptions">
<el-date-picker v-model="filters.planFinishTimeRanger" type="daterange" align="right" unlink-panels
range-separator="-" start-placeholder="计划完成日期" end-placeholder="计划完成日期" value-format="yyyy-MM-dd"
:default-time="['00:00:00','23:59:59']" :picker-options="pickerOptions">
</el-date-picker> </el-date-picker>
</el-col> </el-col>
<el-col :span="24">
<category-tree class="hidden-md-and-up" ref="categoryTree" multiple :expandOnClickNode="false" :defaultExpandAll="true" show-checkbox :current-key="addForm.categoryId" v-on:check-change="handleCategoryCheckChange" ></category-tree>
</el-col>
<el-col :span="24">
<el-checkbox size="mini" v-model="showCalendar">按日历风格显示</el-checkbox>
<el-button size="mini" type="primary" v-on:click="searchExecutions" icon="el-icon-search">查询</el-button>
<!-- <el-col :span="24">
<category-tree class="hidden-lg-and-up" ref="categoryTree" multiple :expandOnClickNode="false"
:defaultExpandAll="true" show-checkbox :current-key="addForm.categoryId"
v-on:check-change="handleCategoryCheckChange"></category-tree>
</el-col> -->
<el-col :span="24" style="margin-top: 11px;">
<el-button size="mini" type="primary" v-on:click="searchProcinsts" icon="el-icon-search">查询</el-button>
</el-col> </el-col>
<el-col :span="24"> <el-col :span="24">
<el-divider content-position="left">其它操作</el-divider> <el-divider content-position="left">其它操作</el-divider>
<el-button size="mini" @click.native="showTagSelect(true)" >给任务打标签</el-button>
<el-button size="mini" @click.native="showTagSelect(true)">给任务打标签</el-button>
<el-button size="mini" @click="handleDownload">导出数据</el-button> <el-button size="mini" @click="handleDownload">导出数据</el-button>
<el-button size="mini" v-on:click="showWeixinTask">微信催办</el-button>
<el-button size="mini" v-on:click="showSendSms">短信催办</el-button>
<el-button size="mini" v-on:click="showOaMsg">OAMSG催办</el-button>
</el-col> </el-col>
</el-row> </el-row>
<el-button slot="reference" icon="el-icon-more" circle></el-button>
<el-button slot="reference" icon="el-icon-more" style="margin-left: 13px;" circle></el-button>
</el-popover> </el-popover>
</el-row> </el-row>
<el-row style="padding-top:10px;">
<el-table
ref="table"
:max-height="tableHeight"
:data="procinsts"
highlight-current-row
v-loading="listLoading"
border
@selection-change="selsChange"
@row-click="rowClick"
style="width: 100%;"
>
<el-row style="padding-top:20px;">
<el-table ref="table" :max-height="tableHeight" :data="procinsts" highlight-current-row
v-loading="listLoading" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column type="selection" width="40"></el-table-column> <el-table-column type="selection" width="40"></el-table-column>
<el-table-column type="index" width="40"></el-table-column> <el-table-column type="index" width="40"></el-table-column>
<el-table-column sortable prop="mainTitle" label="流程(点击详情)" min-width="300" show-overflow-tooltip> <el-table-column sortable prop="mainTitle" label="流程(点击详情)" min-width="300" show-overflow-tooltip>
@ -183,152 +121,88 @@
<el-link type="primary" @click="showEdit( scope.row,scope.$index)">{{scope.row.mainTitle}}</el-link> <el-link type="primary" @click="showEdit( scope.row,scope.$index)">{{scope.row.mainTitle}}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column
sortable
prop="startDeptName"
label="发起部门"
min-width="180"
show-overflow-tooltip
></el-table-column>
<el-table-column
sortable
prop="startUsername"
label="发起人"
min-width="120"
show-overflow-tooltip
></el-table-column>
<el-table-column sortable prop="tagNames" label="标签" min-width="150"
show-overflow-tooltip>
<el-table-column sortable prop="startDeptName" label="发起部门" min-width="180" show-overflow-tooltip>
</el-table-column>
<el-table-column sortable prop="startUsername" label="发起人" min-width="120" show-overflow-tooltip>
</el-table-column>
<el-table-column sortable prop="tagNames" label="标签" min-width="150" show-overflow-tooltip>
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag
v-for="tagName in (scope.row.tagNames?scope.row.tagNames.split(','):[])"
:key="tagName"
>{{tagName}}</el-tag>
<el-tag v-for="tagName in (scope.row.tagNames?scope.row.tagNames.split(','):[])" :key="tagName">
{{tagName}}</el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column
sortable
prop="startTime"
label="发起时间"
min-width="120"
show-overflow-tooltip
></el-table-column>
<el-table-column
sortable
prop="planFinishTime"
label="到期时间"
min-width="120"
show-overflow-tooltip
></el-table-column>
<el-table-column
sortable
prop="endTime"
label="结束时间"
min-width="120"
show-overflow-tooltip
></el-table-column>
<el-table-column
sortable
prop="duration"
label="执行时长"
min-width="120"
show-overflow-tooltip
:formatter="formatterDuration"
></el-table-column>
<el-table-column sortable prop="startTime" label="发起时间" min-width="120" show-overflow-tooltip>
</el-table-column>
<el-table-column sortable prop="planFinishTime" label="到期时间" min-width="120" show-overflow-tooltip>
</el-table-column>
<el-table-column sortable prop="endTime" label="结束时间" min-width="120" show-overflow-tooltip>
</el-table-column>
<el-table-column sortable prop="duration" label="执行时长" min-width="120" show-overflow-tooltip
:formatter="formatterDuration"></el-table-column>
<el-table-column
sortable
prop="sponsors"
label="主办"
min-width="80"
show-overflow-tooltip
></el-table-column>
<el-table-column
sortable
prop="monitors"
label="监控"
min-width="80"
show-overflow-tooltip
></el-table-column>
<el-table-column
sortable
prop="deleteReason"
label="删除原因"
min-width="120"
show-overflow-tooltip
></el-table-column>
<el-table-column sortable prop="sponsors" label="主办" min-width="80" show-overflow-tooltip></el-table-column>
<el-table-column sortable prop="monitors" label="监控" min-width="80" show-overflow-tooltip></el-table-column>
<el-table-column sortable prop="deleteReason" label="删除原因" min-width="120" show-overflow-tooltip>
</el-table-column>
</el-table> </el-table>
<el-pagination
layout="total, prev, next"
@current-change="handleCurrentChange"
@size-change="handleSizeChange"
:page-sizes="[10,20, 50, 100, 500]"
:current-page="pageInfo.pageNum"
:page-size="pageInfo.pageSize"
:total="pageInfo.total"
style="float:right;"
></el-pagination>
<el-pagination layout="total, sizes, prev, pager, next" @current-change="handleCurrentChange"
@size-change="handleSizeChange" :page-sizes="[10,20, 50, 100, 500]" :current-page="pageInfo.pageNum"
:page-size="pageInfo.pageSize" :total="pageInfo.total" style="float:right;"></el-pagination>
<!--编辑 Execution act_ru_execution界面--> <!--编辑 Execution act_ru_execution界面-->
<el-dialog
title="任务详情"
fullscreen
:visible.sync="editFormVisible"
:width="dialogWidth()"
:close-on-click-modal="false"
>
<procinst-parames-execution-set
:companyEmployees="companyEmployees"
:companyDepts="companyDepts"
:taskInfo="editForm"
:procDefId="editForm.procDefId"
:procInstId="editForm.procInstId"
:visible="editFormVisible"
@cancel="editFormVisible=false"
@submit="afterEditSubmit"
></procinst-parames-execution-set>
<el-dialog title="任务详情" fullscreen :visible.sync="editFormVisible" :width="dialogWidth()"
:close-on-click-modal="false">
<procinst-parames-execution-set :companyEmployees="companyEmployees" :companyDepts="companyDepts"
:taskInfo="editForm" :procDefId="editForm.procDefId" :procInstId="editForm.procInstId"
:visible="editFormVisible" @cancel="editFormVisible=false" @submit="afterEditSubmit">
</procinst-parames-execution-set>
</el-dialog> </el-dialog>
</el-row> </el-row>
</el-col> </el-col>
<el-dialog append-to-body title="选择员工" :visible.sync="userSelectVisible" width="60%"> <el-dialog append-to-body title="选择员工" :visible.sync="userSelectVisible" width="60%">
<users-select
:select-userids="filters.assignee?[filters.assignee.userid]:[]"
@confirm="onUserSelected"
></users-select>
<users-select :select-userids="filters.assignee?[filters.assignee.userid]:[]" @confirm="onUserSelected">
</users-select>
</el-dialog> </el-dialog>
<el-dialog append-to-body title="标签条件" :visible.sync="tagSelectVisible" width="60%"> <el-dialog append-to-body title="标签条件" :visible.sync="tagSelectVisible" width="60%">
<tag-mng
:tagIds="filters.tags?filters.tags.map(i=>i.tagId):[]"
:jump="true"
@select-confirm="onTagSelected"
></tag-mng>
<tag-mng :tagIds="filters.tags?filters.tags.map(i=>i.tagId):[]" :jump="true" @select-confirm="onTagSelected">
</tag-mng>
</el-dialog> </el-dialog>
</el-row> </el-row>
</section> </section>
</template> </template>
<script> <script>
import util from "@/common/js/util"; //
//import { getCompanyEmployees,getCompanyDepts,selectCacheOptions,getDefaultValue,getCodeName } from '../../../../../api/common/code';//
import {
import util from "@/common/js/util"; //
//import { getCompanyEmployees,getCompanyDepts,selectCacheOptions,getDefaultValue,getCodeName } from '../../../../../api/common/code';//
import {
listProcinst, listProcinst,
delProcinst, delProcinst,
batchDelProcinst batchDelProcinst
} from "@/api/mdp/workflow/hi/procinst";
import ProcinstParamesExecutionSet from "../../ru/procinstParames/ProcinstParamesExecutionSet"; //
import { listCategorys } from "@/api/mdp/workflow/re/procdef";
import Sticky from "@/components/Sticky"; // header
import { mapGetters } from "vuex";
import { listUser } from "@/api/mdp/sys/user"; //
import { listDept } from "@/api/mdp/sys/dept"; //
import CategoryTree from "@/views/mdp/arc/category/CategoryTree"; //
import TagMng from "@/views/mdp/arc/tag/TagMng";
import { batchInsertOrDeleteTags } from "@/api/mdp/workflow/ru/procinstTag";
import UsersSelect from "@/views/mdp/sys/user/UsersSelect";
export default {
} from "@/api/mdp/workflow/hi/procinst";
import ProcinstParamesExecutionSet from "../../ru/procinstParames/ProcinstParamesExecutionSet"; //
import {
listCategorys
} from "@/api/mdp/workflow/re/procdef";
import Sticky from "@/components/Sticky"; // header
import {
mapGetters
} from "vuex";
import {
listUser
} from "@/api/mdp/sys/user"; //
import {
listDept
} from "@/api/mdp/sys/dept"; //
import CategoryTree from "@/views/mdp/arc/category/CategoryTree"; //
import TagMng from "@/views/mdp/arc/tag/TagMng";
import {
batchInsertOrDeleteTags
} from "@/api/mdp/workflow/ru/procinstTag";
import UsersSelect from "@/views/mdp/sys/user/UsersSelect";
export default {
name: "ProcinstMng", name: "ProcinstMng",
computed: { computed: {
...mapGetters(["userInfo"]), ...mapGetters(["userInfo"]),
@ -357,11 +231,10 @@ export default {
planFinishTimeRanger: [], planFinishTimeRanger: [],
endTimeRanger: [], endTimeRanger: [],
assignee: null, assignee: null,
filterType:'',
filterType: '',
}, },
pickerOptions: { pickerOptions: {
shortcuts: [
{
shortcuts: [{
text: "最近一周", text: "最近一周",
onClick(picker) { onClick(picker) {
const end = new Date(); const end = new Date();
@ -475,7 +348,7 @@ export default {
tagSelectVisible: false, tagSelectVisible: false,
isBatchSetProcTags: false, isBatchSetProcTags: false,
userSelectVisible: false, userSelectVisible: false,
tableHeight:300,
tableHeight: 300,
/**end 自定义属性请在上面加 请加备注**/ /**end 自定义属性请在上面加 请加备注**/
}; };
}, //end data }, //end data
@ -596,20 +469,20 @@ export default {
params.assignee = this.filters.assignee.userid; params.assignee = this.filters.assignee.userid;
} }
if(this.filters.filterType=='startUserId'){
params.startUserId=this.userInfo.userid
if (this.filters.filterType == 'startUserId') {
params.startUserId = this.userInfo.userid
} }
if(this.filters.filterType=='partake'){
params.partake=this.userInfo.userid
if (this.filters.filterType == 'partake') {
params.partake = this.userInfo.userid
} }
if(this.filters.filterType=='sponsors'){
params.sponsors='%'+this.userInfo.userid+'%'
if (this.filters.filterType == 'sponsors') {
params.sponsors = '%' + this.userInfo.userid + '%'
} }
if(this.filters.filterType=='monitors'){
params.monitors='%'+this.userInfo.userid+'%'
if (this.filters.filterType == 'monitors') {
params.monitors = '%' + this.userInfo.userid + '%'
} }
if (this.filters.proccategory != "") {
params.category = this.filters.proccategory;
if (this.filters.procCategory != "") {
params.category = this.filters.procCategory;
} }
params.tenantId = this.userInfo.branchId; params.tenantId = this.userInfo.branchId;
this.listLoading = true; this.listLoading = true;
@ -621,7 +494,10 @@ export default {
this.pageInfo.count = false; this.pageInfo.count = false;
this.procinsts = res.data.data; this.procinsts = res.data.data;
} else { } else {
this.$message({ message: tips.msg, type: "error" });
this.$message({
message: tips.msg,
type: "error"
});
} }
this.listLoading = false; this.listLoading = false;
}) })
@ -661,7 +537,9 @@ export default {
}) })
.then(() => { .then(() => {
this.listLoading = true; this.listLoading = true;
let params = { id: row.id };
let params = {
id: row.id
};
delProcinst(params).then(res => { delProcinst(params).then(res => {
this.listLoading = false; this.listLoading = false;
var tips = res.data.tips; var tips = res.data.tips;
@ -715,7 +593,9 @@ export default {
this.pageInfo.total = 0; this.pageInfo.total = 0;
this.pageInfo.count = true; this.pageInfo.count = true;
this.filters.allBtn = false; this.filters.allBtn = false;
this.filters.otherParames = { partake: this.userInfo.userid };
this.filters.otherParames = {
partake: this.userInfo.userid
};
this.getProcinsts(); this.getProcinsts();
}, },
searchMyStart() { searchMyStart() {
@ -723,7 +603,9 @@ export default {
this.pageInfo.total = 0; this.pageInfo.total = 0;
this.pageInfo.count = true; this.pageInfo.count = true;
this.filters.allBtn = false; this.filters.allBtn = false;
this.filters.otherParames = { startUserId: this.userInfo.userid };
this.filters.otherParames = {
startUserId: this.userInfo.userid
};
this.getProcinsts(); this.getProcinsts();
}, },
searchMySponsors() { searchMySponsors() {
@ -841,7 +723,10 @@ export default {
branchId: row.branchId, branchId: row.branchId,
userid: this.userInfo.userid, userid: this.userInfo.userid,
tags: tags.map(i => { tags: tags.map(i => {
return { tagId: i.tagId, tagName: i.tagName };
return {
tagId: i.tagId,
tagName: i.tagName
};
}) })
}; };
procinstTagsVos.push(procinstTags); procinstTagsVos.push(procinstTags);
@ -990,9 +875,9 @@ export default {
const data = this.formatJson(filterVal, list); const data = this.formatJson(filterVal, list);
var filename = "历史流程"; var filename = "历史流程";
if (this.formDefSelected) { if (this.formDefSelected) {
filename = this.formDefSelected.formName
? this.formDefSelected.formName
: this.formDefSelected.id + "历史流程";
filename = this.formDefSelected.formName ?
this.formDefSelected.formName :
this.formDefSelected.id + "历史流程";
} }
excel.export_json_to_excel({ excel.export_json_to_excel({
header: tHeader, header: tHeader,
@ -1025,56 +910,70 @@ export default {
UsersSelect UsersSelect
}, },
mounted() { mounted() {
listCategorys({ tenantId: this.userInfo.branchId }).then(res => {
listCategorys({
tenantId: this.userInfo.branchId
}).then(res => {
this.categorys = res.data.data; this.categorys = res.data.data;
}); });
this.$nextTick(() => { this.$nextTick(() => {
var clientRect=this.$refs.table.$el.getBoundingClientRect();
var subHeight=70/1000 * window.innerHeight;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.table.$el.offsetTop-subHeight;
if(this.isMyStart){
this.filters.filterType="startUserId"
}else if(this.isMyMonitors){
this.filters.filterType="monitors"
}else if(this.isMySponsors){
this.filters.filterType="sponsors"
}else if(this.isMyPartake){
this.filters.filterType="partake"
}else if(this.isAll){
var clientRect = this.$refs.table.$el.getBoundingClientRect();
var subHeight = 70 / 1000 * window.innerHeight;
this.tableHeight = window.innerHeight - clientRect.y - this.$refs.table.$el.offsetTop - subHeight;
if (this.isMyStart) {
this.filters.filterType = "startUserId"
} else if (this.isMyMonitors) {
this.filters.filterType = "monitors"
} else if (this.isMySponsors) {
this.filters.filterType = "sponsors"
} else if (this.isMyPartake) {
this.filters.filterType = "partake"
} else if (this.isAll) {
} }
this.getProcinsts(); this.getProcinsts();
}); });
} }
};
};
</script> </script>
<style scoped> <style scoped>
.filters-show {
.filters-show {
margin-left: 20px; margin-left: 20px;
margin-top: 10px; margin-top: 10px;
margin-bottom: 0px; margin-bottom: 0px;
}
.filters-label {
}
.filters-label {
font-size: 14px; font-size: 14px;
color: black; color: black;
font-weight: bold; font-weight: bold;
}
}
.more-filter-item {
margin: 20px 20px;
}
.more-filter-item {
margin: 20px 0px;
}
.more-filter-item .el-col {
.more-filter-item .el-col {
margin: 2px 2px; margin: 2px 2px;
}
.more-filter-item button {
}
.more-filter-item button {
margin: 2px 2px; margin: 2px 2px;
}
}
.more-label-font {
text-align: center;
float: left;
height: 28px;
line-height: 28px;
margin-right: 10px;
}
.more-label-font{
text-align:center;
float:left;
padding-top:5px;
.el-popover__title {
color: #303133;
font-size: 18px;
line-height: 1;
margin-bottom: 12px;
margin-top: 11px;
} }
</style> </style>

22
src/views/mdp/workflow/re/deployment/DeploymentMng.vue

@ -5,14 +5,14 @@
<el-select v-model="filters.category" clearable filterable placeholder="请选择分类"> <el-select v-model="filters.category" clearable filterable placeholder="请选择分类">
<el-option v-for="item in categorys" :key="item" :label="item" :value="item"></el-option> <el-option v-for="item in categorys" :key="item" :label="item" :value="item"></el-option>
</el-select> </el-select>
<el-input v-model="filters.key" style="width:30%;" placeholder="模糊查询">
<el-input v-model="filters.key" style="width:270px;margin-right: 13px;" placeholder="模糊查询">
<template slot="append"> <template slot="append">
<el-button type="primary" v-on:click="searchDeployments" icon="el-icon-search">查询</el-button> <el-button type="primary" v-on:click="searchDeployments" icon="el-icon-search">查询</el-button>
</template> </template>
</el-input> </el-input>
<el-button @click="handleDownload" icon="el-icon-download">导出数据</el-button>
<el-button @click="handleDownload" icon="el-icon-download" style="">导出数据</el-button>
</el-row> </el-row>
<el-row style="padding-top:10px;">
<el-row style="padding-top:20px;">
<!--列表 Deployment act_re_deployment--> <!--列表 Deployment act_re_deployment-->
<el-table <el-table
ref="table" :max-height="tableHeight" ref="table" :max-height="tableHeight"
@ -39,7 +39,7 @@
></el-table-column> ></el-table-column>
<el-table-column label="操作" width="150" fixed="right"> <el-table-column label="操作" width="150" fixed="right">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="danger" @click="handleDel(scope.row,scope.$index)">取消发布</el-button>
<el-button type="danger" @click="handleDel(scope.row,scope.$index)">下架当前版本</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -393,3 +393,17 @@ export default {
<style scoped> <style scoped>
</style> </style>
<style>
.el-input-group__append, .el-input-group__prepend {
background-color: #409EFF!important;
color: #ffffff!important;
vertical-align: middle;
display: table-cell;
position: relative;
border: 1px solid #409EFF!important;
padding: 0 20px;
width: 1px;
white-space: nowrap;
}
</style>

12
src/views/mdp/workflow/re/procdef/ProcdefListForBizStart.vue

@ -28,13 +28,14 @@
data() { data() {
return { return {
filters: { filters: {
params:null,
/**
params:{ params:{
mainTitle:'xxxxxxx',
mainContext:'xxxx',
mainTitle:'',
mainContext:'',
bizUrl:'',// // bizUrl:'',// //
bizKey:'company_regit',//restUrl
restUrl:'xxxxxxxx',//
bizKey:'',//restUrl
restUrl:'',//
formId:'',//form formId:'',//form
formDataId:'',//form formDataId:'',//form
extVars:{ // extVars:{ //
@ -44,6 +45,7 @@
} }
} }
*/
}, },
/**end 自定义属性请在上面加 请加备注**/ /**end 自定义属性请在上面加 请加备注**/
} }

42
src/views/mdp/workflow/re/procdef/ProcdefListForParames.vue

@ -2,33 +2,22 @@
<section> <section>
<el-row class="app-container"> <el-row class="app-container">
<el-row> <el-row>
<el-col :xs="4" :sm="4" :md="4" :lg="4" :xl="4" class="hidden-sm-and-down">
<category-tree
ref="categoryTree"
multiple
:expandOnClickNode="false"
:defaultExpandAll="true"
show-checkbox
:current-key="addForm.categoryId"
v-on:check-change="handleCategoryCheckChange"
></category-tree>
</el-col>
<el-col :xs="24" :sm="24" :md="20" :lg="20" :xl="20">
<el-col>
<el-row> <el-row>
<el-select v-model="filters.procCategory" clearable filterable placeholder="请选择分类"> <el-select v-model="filters.procCategory" clearable filterable placeholder="请选择分类">
<el-option v-for="item in categorys" :key="item" :label="item" :value="item"></el-option> <el-option v-for="item in categorys" :key="item" :label="item" :value="item"></el-option>
</el-select> </el-select>
<el-button @click.native="showTagSelect(false)">标签</el-button>
<el-input v-model="filters.key" style="width:20%;" placeholder="模糊查询">
<el-input v-model="filters.key" style="width:270px;" placeholder="模糊查询">
<template slot="append"> <template slot="append">
<el-button type="primary" v-on:click="searchProcdefs" icon="el-icon-search">查询</el-button> <el-button type="primary" v-on:click="searchProcdefs" icon="el-icon-search">查询</el-button>
</template> </template>
</el-input> </el-input>
<el-button type="primary" @click="handleDownload" icon="el-icon-download">导出数据</el-button>
<el-button @click.native="showTagSelect(true)">打标签</el-button>
<el-button @click.native="showTagSelect(false)" icon="el-icon-search" style="margin-left: 13px;" class="hidden-sm-and-down">标签</el-button>
<el-button @click.native="showTagSelect(true)" icon="el-icon-plus" class="hidden-sm-and-down">标签</el-button>
<el-button @click="handleDownload" icon="el-icon-download" class="hidden-md-and-down">导出数据</el-button>
</el-row> </el-row>
<el-row style="padding-top:10px;">
<el-row style="padding-top:20px;">
<!--列表 Procdef act_re_procdef--> <!--列表 Procdef act_re_procdef-->
<el-table <el-table
ref="table" :max-height="tableHeight" ref="table" :max-height="tableHeight"
@ -78,14 +67,14 @@
width="200" width="200"
trigger="click" trigger="click"
:content="scope.row.description"> :content="scope.row.description">
<el-button slot="reference">细描述</el-button>
<el-button slot="reference"></el-button>
</el-popover> </el-popover>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" width="220" fixed="right"> <el-table-column label="操作" width="220" fixed="right">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="primary" @click="showBizModelDialog(scope.row,scope.$index)">绑定业务</el-button>
<el-button @click="showDiagram( scope.row,scope.$index)">流程图</el-button> <el-button @click="showDiagram( scope.row,scope.$index)">流程图</el-button>
<el-button type="primary" @click="showBizModelDialog(scope.row,scope.$index)">绑定业务</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -629,3 +618,18 @@ export default {
font-weight: bold; font-weight: bold;
} }
</style> </style>
<style>
.el-input-group__append, .el-input-group__prepend {
background-color: #409EFF!important;
color: #ffffff!important;
vertical-align: middle;
display: table-cell;
position: relative;
border: 1px solid #409EFF!important;
padding: 0 20px;
width: 1px;
white-space: nowrap;
}
</style>

329
src/views/mdp/workflow/re/procdef/ProcdefListForSimpleStart.vue

@ -1,40 +1,47 @@
<template> <template>
<section> <section>
<el-row v-if="flowStartVisible==false" class="app-container"> <el-row v-if="flowStartVisible==false" class="app-container">
<el-row >
<el-input v-model="filters.key" style="width:30%;" placeholder="模糊查询">
<el-row>
<el-input v-model="filters.key" style="width:270px;" placeholder="模糊查询">
<template slot="append"> <template slot="append">
<el-button type="primary" v-loading="listLoading" :disabled="listLoading" v-on:click="searchProcdefs" icon="el-icon-search">查询</el-button>
<el-button type="primary" v-loading="listLoading" :disabled="listLoading" v-on:click="searchProcdefs"
icon="el-icon-search">查询</el-button>
</template> </template>
</el-input> </el-input>
<el-tag type="info" v-if="this.procdefs.length==0">如果没有找到流程请将业务编码{{this.filters.params.bizKey}}与流程进行关联</el-tag>
<el-tag type="info" v-if="this.procdefs.length==0">如果没有找到流程请将业务编码{{this.filters.params.bizKey}}与流程进行关联
</el-tag>
</el-row> </el-row>
<el-row style="padding-top:10px;">
<el-row style="padding-top:20px;">
<!--列表 Procdef act_re_procdef--> <!--列表 Procdef act_re_procdef-->
<el-table ref="procdefsTable" :max-height="tableHeight" :data="procdefs" highlight-current-row v-loading="listLoading" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table ref="procdefsTable" :max-height="tableHeight" :data="procdefs" highlight-current-row
v-loading="listLoading" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column type="selection" width="40"></el-table-column> <el-table-column type="selection" width="40"></el-table-column>
<el-table-column type="index" width="40"></el-table-column> <el-table-column type="index" width="40"></el-table-column>
<el-table-column sortable prop="category" label="分类" min-width="80" ></el-table-column>
<el-table-column sortable prop="category" label="分类" min-width="80"></el-table-column>
<el-table-column sortable prop="name" label="流程名称" min-width="200"></el-table-column> <el-table-column sortable prop="name" label="流程名称" min-width="200"></el-table-column>
<el-table-column sortable prop="tagNames" label="标签" min-width="150" >
<el-table-column sortable prop="tagNames" label="标签" min-width="150">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag v-for="tagName in (scope.row.tagNames?scope.row.tagNames.split(','):[])" :key="tagName">{{tagName}}</el-tag>
<el-tag v-for="tagName in (scope.row.tagNames?scope.row.tagNames.split(','):[])" :key="tagName">
{{tagName}}</el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column sortable prop="description" label="描述" min-width="200" ></el-table-column>
<el-table-column sortable prop="version" label="版本" min-width="80" ></el-table-column>
<el-table-column sortable prop="description" label="描述" min-width="200"></el-table-column>
<el-table-column sortable prop="version" label="版本" min-width="80"></el-table-column>
<el-table-column label="操作" :min-width="screenWidth>=500?200:80" fixed="right"> <el-table-column label="操作" :min-width="screenWidth>=500?200:80" fixed="right">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button v-show="isSelectModel" @click="rowClick(scope.row,scope.$index)">选中</el-button> <el-button v-show="isSelectModel" @click="rowClick(scope.row,scope.$index)">选中</el-button>
<el-button type="primary" v-show="!isSelectModel" @click="showFlowStart(scope.row,scope.$index)">发起</el-button>
<el-button type="primary" v-show="!isSelectModel" @click="showFlowStart(scope.row,scope.$index)">发起
</el-button>
<el-button class="hidden-sm-and-down" @click="showDiagram( scope.row,scope.$index)">流程图</el-button> <el-button class="hidden-sm-and-down" @click="showDiagram( scope.row,scope.$index)">流程图</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-pagination layout="total, sizes, prev, pager, next" @current-change="handleCurrentChange" @size-change="handleSizeChange" :page-sizes="[10,20, 50, 100, 500]" :current-page="pageInfo.pageNum" :page-size="pageInfo.pageSize" :total="pageInfo.total" style="float:right;">
<el-pagination layout="total, sizes, prev, pager, next" @current-change="handleCurrentChange"
@size-change="handleSizeChange" :page-sizes="[10,20, 50, 100, 500]" :current-page="pageInfo.pageNum"
:page-size="pageInfo.pageSize" :total="pageInfo.total" style="float:right;">
</el-pagination> </el-pagination>
<!--流程图界面--> <!--流程图界面-->
@ -52,34 +59,39 @@
</el-row> </el-row>
</el-row> </el-row>
<el-row v-else-if="flowStartVisible==true"> <el-row v-else-if="flowStartVisible==true">
<procinst-parames-start-set :procdef="addForm" :visible="flowStartVisible" :params="filters.params" @cancel="startCancel"></procinst-parames-start-set>
<procinst-parames-start-set :procdef="addForm" :visible="flowStartVisible" :params="filters.params"
@cancel="startCancel"></procinst-parames-start-set>
</el-row> </el-row>
</section> </section>
</template> </template>
<script> <script>
import util from '@/common/js/util';//
import config from '@/common/config';//
import util from '@/common/js/util'; //
import config from '@/common/config'; //
//import { selectCacheOptions,getDefaultValue,getCodeName } from '../../../../../api/common/code';// //import { selectCacheOptions,getDefaultValue,getCodeName } from '../../../../../api/common/code';//
import { listProcdef } from '@/api/mdp/workflow/re/procdef';
import {
listProcdef
} from '@/api/mdp/workflow/re/procdef';
import ProcinstParamesStartSet from "../../ru/procinstParames/ProcinstParamesStartSet" import ProcinstParamesStartSet from "../../ru/procinstParames/ProcinstParamesStartSet"
import Sticky from '@/components/Sticky' // header import Sticky from '@/components/Sticky' // header
import { mapGetters } from 'vuex'
import {
mapGetters
} from 'vuex'
export default { export default {
name:'ProcdefListForBizStart',
props:['params','isSelectModel'],
name: 'ProcdefListForBizStart',
props: ['params', 'isSelectModel'],
computed: { computed: {
...mapGetters([ ...mapGetters([
'userInfo' 'userInfo'
]), ]),
screenWidth:function(){
screenWidth: function() {
return screen.width; return screen.width;
}, },
}, },
watch:{
params:function(params){
watch: {
params: function(params) {
this.filters.params=params;
this.filters.params = params;
this.searchProcdefs(); this.searchProcdefs();
} }
}, },
@ -87,81 +99,95 @@
return { return {
filters: { filters: {
key: '', key: '',
procCategory:'',
categoryTreeNodes:[],
tags:[],
params:{
mainTitle:'',
mainContext:'',
bizUrl:'',// //
bizKey:'',//restUrl
restUrl:'',//
formId:'',//form
formDataId:'',//form
extVars:{ //
procCategory: '',
categoryTreeNodes: [],
tags: [],
params: {
mainTitle: '',
mainContext: '',
bizUrl: '', // //
bizKey: '', //restUrl
restUrl: '', //
formId: '', //form
formDataId: '', //form
extVars: { //
}, },
flowVars:{//,flowVarspostrestUrl
flowVars: { //,flowVarspostrestUrl
} }
} }
}, },
procdefs: [],//
pageInfo:{//
total:0,//0>0
pageSize:10,//
pageNum:1,//1
orderFields:[],// ['sex','student_id']
orderDirs:[],// asc,desc ['asc','desc']
count:true,
procdefs: [], //
pageInfo: { //
total: 0, //0>0
pageSize: 10, //
pageNum: 1, //1
orderFields: [], // ['sex','student_id']
orderDirs: [], // asc,desc ['asc','desc']
count: true,
}, },
listLoading: false,//...
sels: [],//
options:{},// options.sex,options.project
listLoading: false, //...
sels: [], //
options: {}, // options.sex,options.project
addFormVisible: false,//procdef
addFormVisible: false, //procdef
//procdef //procdef
addForm: { addForm: {
id:'',rev:'',category:'',name:'',key:'',version:'',deploymentId:'',resourceName:'',dgrmResourceName:'',description:'',hasStartFormKey:'',hasGraphicalNotation:'',suspensionState:'',tenantId:'',engineVersion:''
id: '',
rev: '',
category: '',
name: '',
key: '',
version: '',
deploymentId: '',
resourceName: '',
dgrmResourceName: '',
description: '',
hasStartFormKey: '',
hasGraphicalNotation: '',
suspensionState: '',
tenantId: '',
engineVersion: ''
}, },
drawer:false,
drawer: false,
/**begin 自定义属性请在下面加 请加备注**/ /**begin 自定义属性请在下面加 请加备注**/
diagramVisible:false,//
diagramUrl:'',//
flowStartVisible:false,//
categorys:[],
tagSelectVisible:false,
isBatchSetProcTags:false,
tableHeight:300,
diagramVisible: false, //
diagramUrl: '', //
flowStartVisible: false, //
categorys: [],
tagSelectVisible: false,
isBatchSetProcTags: false,
tableHeight: 300,
/**end 自定义属性请在上面加 请加备注**/ /**end 自定义属性请在上面加 请加备注**/
} }
},//end data
}, //end data
methods: { methods: {
// getCodeName(options.sex,'1'); // getCodeName(options.sex,'1');
getCodeName(options,codeValue){
if(!options)return codeValue;
let code=options.filter(i=>i.codeValue==codeValue);
if(code.length>0){
getCodeName(options, codeValue) {
if (!options) return codeValue;
let code = options.filter(i => i.codeValue == codeValue);
if (code.length > 0) {
return code[0].codeName return code[0].codeName
}else{
} else {
return codeValue return codeValue
} }
}, },
dialogWidth:function(){
if(screen.width>500){
dialogWidth: function() {
if (screen.width > 500) {
return "80%"; return "80%";
}else{
} else {
return "100%"; return "100%";
} }
}, },
handleSizeChange(pageSize) { handleSizeChange(pageSize) {
this.pageInfo.pageSize=pageSize;
this.pageInfo.total=0;
this.pageInfo.count=true
this.pageInfo.pageNum=1;
this.pageInfo.pageSize = pageSize;
this.pageInfo.total = 0;
this.pageInfo.count = true
this.pageInfo.pageNum = 1;
this.getProcdefs(); this.getProcdefs();
}, },
handleCurrentChange(pageNum) { handleCurrentChange(pageNum) {
@ -169,23 +195,23 @@
this.getProcdefs(); this.getProcdefs();
}, },
// obj.order=ascending/descending, asc/desc ; obj.prop=, // obj.order=ascending/descending, asc/desc ; obj.prop=,
sortChange( obj ){
var dir='asc';
if(obj.order=='ascending'){
dir='asc'
}else{
dir='desc';
sortChange(obj) {
var dir = 'asc';
if (obj.order == 'ascending') {
dir = 'asc'
} else {
dir = 'desc';
} }
if(obj.prop=='xxx'){
this.pageInfo.orderFields=['xxx'];
this.pageInfo.orderDirs=[dir];
if (obj.prop == 'xxx') {
this.pageInfo.orderFields = ['xxx'];
this.pageInfo.orderDirs = [dir];
} }
this.getProcdefs(); this.getProcdefs();
}, },
searchProcdefs(){
this.pageInfo.pageNum=1;
this.pageInfo.total=0;
this.pageInfo.count=true
searchProcdefs() {
this.pageInfo.pageNum = 1;
this.pageInfo.total = 0;
this.pageInfo.count = true
this.getProcdefs(); this.getProcdefs();
}, },
@ -195,59 +221,62 @@
pageSize: this.pageInfo.pageSize, pageSize: this.pageInfo.pageSize,
pageNum: this.pageInfo.pageNum, pageNum: this.pageInfo.pageNum,
total: this.pageInfo.total, total: this.pageInfo.total,
count:this.pageInfo.count
count: this.pageInfo.count
}; };
if(this.pageInfo.orderFields!=null && this.pageInfo.orderFields.length>0){
let orderBys=[];
for(var i=0;i<this.pageInfo.orderFields.length;i++){
orderBys.push(this.pageInfo.orderFields[i]+" "+this.pageInfo.orderDirs[i])
if (this.pageInfo.orderFields != null && this.pageInfo.orderFields.length > 0) {
let orderBys = [];
for (var i = 0; i < this.pageInfo.orderFields.length; i++) {
orderBys.push(this.pageInfo.orderFields[i] + " " + this.pageInfo.orderDirs[i])
} }
params.orderBy= orderBys.join(",")
params.orderBy = orderBys.join(",")
} }
if(this.filters.key!==""){
params.filtersKey='%'+this.filters.key+'%'
if (this.filters.key !== "") {
params.filtersKey = '%' + this.filters.key + '%'
} }
if(this.filters.category!==""){
params.category=this.filters.category
if (this.filters.category !== "") {
params.category = this.filters.category
} }
if(this.filters.params.formId!=""&& this.filters.params.formId!=null){
params.formId=this.filters.params.formId
if (this.filters.params.formId != "" && this.filters.params.formId != null) {
params.formId = this.filters.params.formId
} }
if(this.filters.procCategory!='' && this.filters.procCategory!=null){
params.category=this.filters.procCategory
if (this.filters.procCategory != '' && this.filters.procCategory != null) {
params.category = this.filters.procCategory
} }
if(this.filters.categoryTreeNodes!=null && this.filters.categoryTreeNodes.length>0){
params.categoryIds=this.filters.categoryTreeNodes.map(i=>i.id)
if (this.filters.categoryTreeNodes != null && this.filters.categoryTreeNodes.length > 0) {
params.categoryIds = this.filters.categoryTreeNodes.map(i => i.id)
} }
if(this.filters.tags!=null && this.filters.tags.length>0){
params.tagIds=this.filters.tags.map(i=>i.tagId)
if (this.filters.tags != null && this.filters.tags.length > 0) {
params.tagIds = this.filters.tags.map(i => i.tagId)
} }
if(this.filters.params!=null && this.filters.params.bizKey!=null && this.filters.params.bizKey!=''){
params.bizKey=this.filters.params.bizKey
if (this.filters.params != null && this.filters.params.bizKey != null && this.filters.params.bizKey != '') {
params.bizKey = this.filters.params.bizKey
} }
params.tenantId=this.userInfo.branchId
params.includeContext="1";
params.suspensionState=1;
params.tenantId = this.userInfo.branchId
params.includeContext = "1";
params.suspensionState = 1;
this.listLoading = true; this.listLoading = true;
listProcdef(params).then((res) => { listProcdef(params).then((res) => {
var tips=res.data.tips;
if(tips.isOk){
var tips = res.data.tips;
if (tips.isOk) {
this.pageInfo.total = res.data.total this.pageInfo.total = res.data.total
this.pageInfo.count=false
if(res.data.data.length==1){
this.addForm=res.data.data[0]
this.flowStartVisible=true;
}else if(res.data.data.length>1){
this.flowStartVisible=false;
this.pageInfo.count = false
if (res.data.data.length == 1) {
this.addForm = res.data.data[0]
this.flowStartVisible = true;
} else if (res.data.data.length > 1) {
this.flowStartVisible = false;
this.$message.success("请选中一个流程") this.$message.success("请选中一个流程")
} }
this.procdefs = res.data.data; this.procdefs = res.data.data;
}else{
this.$message({ message: tips.msg, type: 'error' });
} else {
this.$message({
message: tips.msg,
type: 'error'
});
} }
this.listLoading = false; this.listLoading = false;
}).catch(() => { }).catch(() => {
@ -257,66 +286,80 @@
}, },
//procdef //procdef
selsChange: function (sels) {
selsChange: function(sels) {
this.sels = sels; this.sels = sels;
}, },
rowClick: function(row, event, column){
this.$emit('row-click',row, event, column);// @row-click="rowClick"
rowClick: function(row, event, column) {
this.$emit('row-click', row, event, column); // @row-click="rowClick"
}, },
/**begin 自定义函数请在下面加**/ /**begin 自定义函数请在下面加**/
showDiagram: function ( row,index ) {
showDiagram: function(row, index) {
this.diagramVisible = true; this.diagramVisible = true;
this.diagramUrl="/"+process.env.BASE_API+"/"+process.env.VERSION+"/"+config.getWorkflowBasePath()+"/mdp/workflow/re/procdef/diagram/"+row.id
this.diagramUrl = "/" + process.env.BASE_API + "/" + process.env.VERSION + "/" + config
.getWorkflowBasePath() + "/mdp/workflow/re/procdef/diagram/" + row.id
}, },
showFlowStart: function ( row,index ) {
this.addForm=row;
this.flowStartVisible=true;
showFlowStart: function(row, index) {
this.addForm = row;
this.flowStartVisible = true;
}, },
startCancel(){
startCancel() {
this.$emit("closeTab"); this.$emit("closeTab");
} }
/**end 自定义函数请在上面加**/ /**end 自定义函数请在上面加**/
},//end methods
}, //end methods
components: { components: {
// //
'procinst-parames-start-set':ProcinstParamesStartSet,
'procinst-parames-start-set': ProcinstParamesStartSet,
'sticky': Sticky, 'sticky': Sticky,
}, },
mounted() { mounted() {
if(this.params){
this.filters.params=this.params;
if (this.params) {
this.filters.params = this.params;
this.searchProcdefs(); this.searchProcdefs();
} }
this.$nextTick(()=>{
this.$nextTick(() => {
var clientRect=this.$refs.procdefsTable.$el.getBoundingClientRect();
var subHeight=70/1000 * window.innerHeight;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.procdefsTable.$el.offsetTop-subHeight;
var clientRect = this.$refs.procdefsTable.$el.getBoundingClientRect();
var subHeight = 70 / 1000 * window.innerHeight;
this.tableHeight = window.innerHeight - clientRect.y - this.$refs.procdefsTable.$el.offsetTop - subHeight;
}) })
} }
} }
</script> </script>
<style scoped> <style scoped>
.filters-show {
.filters-show {
margin-left: 20px; margin-left: 20px;
margin-top: 10px; margin-top: 10px;
margin-bottom: 0px; margin-bottom: 0px;
}
.filters-label {
}
.filters-label {
font-size: 14px; font-size: 14px;
color:black;
color: black;
font-weight: bold; font-weight: bold;
}
}
</style>
<style>
.el-input-group__append,
.el-input-group__prepend {
background-color: #409EFF !important;
color: #ffffff !important;
vertical-align: middle;
display: table-cell;
position: relative;
border: 1px solid #409EFF !important;
padding: 0 20px;
width: 1px;
white-space: nowrap;
}
</style> </style>

252
src/views/mdp/workflow/re/procdef/ProcdefListForStart.vue

@ -1,133 +1,71 @@
<template> <template>
<section> <section>
<el-row class="app-container"> <el-row class="app-container">
<el-col :xs="4" :sm="4" :md="3" :lg="3" :xl="3" class="hidden-sm-and-down">
<category-tree
ref="categoryTree"
multiple
:expandOnClickNode="false"
:defaultExpandAll="true"
show-checkbox
:current-key="addForm.categoryId"
v-on:check-change="handleCategoryCheckChange"
></category-tree>
</el-col>
<el-col :xs="24" :sm="24" :md="21" :lg="21" :xl="21">
<el-col>
<el-row> <el-row>
<el-select
v-model="filters.procCategory"
clearable
filterable
placeholder="请选择分类"
>
<el-select v-model="filters.procCategory" clearable filterable placeholder="请选择分类">
<el-option v-for="item in categorys" :key="item" :label="item" :value="item"></el-option> <el-option v-for="item in categorys" :key="item" :label="item" :value="item"></el-option>
</el-select> </el-select>
<el-input v-model="filters.key" style="width:20%;" placeholder="模糊查询">
<el-input v-model="filters.key" style="width:270px;" placeholder="模糊查询">
<template slot="append"> <template slot="append">
<el-button type="primary" v-on:click="searchProcdefs" icon="el-icon-search">查询</el-button> <el-button type="primary" v-on:click="searchProcdefs" icon="el-icon-search">查询</el-button>
</template> </template>
</el-input> </el-input>
<el-button @click.native="showTagSelect(false)">标签查找</el-button>
<el-button @click.native="showTagSelect(true)">标签</el-button>
<el-button @click.native="showTagSelect(false)" icon="el-icon-search" class="hidden-md-and-down">标签</el-button>
<el-button @click.native="showTagSelect(true)" icon="el-icon-plus" class="hidden-md-and-down">标签</el-button>
<el-button @click="drawer = true" type="text">更多</el-button>
<!-- <el-button @click="drawer = true" icon="el-icon-more" circle="true"></el-button> -->
<el-button @click="handleDownload" icon="el-icon-download" class="hidden-md-and-down">导出数据</el-button>
<el-drawer title="更多查询条件" :visible.sync="drawer" :with-header="false" append-to-body> <el-drawer title="更多查询条件" :visible.sync="drawer" :with-header="false" append-to-body>
<el-button @click.native="showTagSelect(false)">标签查找</el-button>
<el-button @click.native="showTagSelect(true)">打标签</el-button>
<el-button type="primary" @click="handleDownload" icon="el-icon-download">导出数据</el-button>
<category-tree
class="hidden-md-and-up"
ref="categoryTree"
multiple
:expandOnClickNode="false"
:defaultExpandAll="true"
show-checkbox
:current-key="addForm.categoryId"
v-on:check-change="handleCategoryCheckChange"
></category-tree>
<!-- <el-button @click.native="showTagSelect(false)">标签查找</el-button>
<el-button @click.native="showTagSelect(true)">打标签</el-button> -->
<!-- <el-button type="primary" @click="handleDownload" icon="el-icon-download">导出数据</el-button> -->
<category-tree class="hidden-md-and-up" ref="categoryTree" multiple :expandOnClickNode="false"
:defaultExpandAll="true" show-checkbox :current-key="addForm.categoryId"
v-on:check-change="handleCategoryCheckChange"></category-tree>
</el-drawer> </el-drawer>
</el-row> </el-row>
<el-row style="padding-top:10px;">
<el-row style="padding-top:20px;">
<!--列表 Procdef act_re_procdef--> <!--列表 Procdef act_re_procdef-->
<el-table
ref="procdefsTable" :max-height="tableHeight"
:data="procdefs"
highlight-current-row
v-loading="listLoading"
border
@selection-change="selsChange"
@row-click="rowClick"
style="width: 100%;"
>
<el-table ref="procdefsTable" :max-height="tableHeight" :data="procdefs" highlight-current-row
v-loading="listLoading" border @selection-change="selsChange" @row-click="rowClick" style="width: 100%;">
<el-table-column type="selection" width="40"></el-table-column> <el-table-column type="selection" width="40"></el-table-column>
<el-table-column type="index" width="40"></el-table-column> <el-table-column type="index" width="40"></el-table-column>
<el-table-column sortable prop="category" label="分类" min-width="80" ></el-table-column>
<el-table-column v-if="!isSelectModel" sortable prop="name" label="流程(点击发起)" min-width="300" >
<el-table-column sortable prop="category" label="分类" min-width="120" show-overflow-tooltip></el-table-column>
<el-table-column v-if="!isSelectModel" sortable prop="name" label="流程(点击发起)" min-width="300" show-overflow-tooltip>
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="primary" @click="showFlowStart( scope.row,scope.$index)">{{scope.row.name}}</el-link> <el-link type="primary" @click="showFlowStart( scope.row,scope.$index)">{{scope.row.name}}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column v-else sortable prop="name" label="流程(点击选中)" min-width="300" >
<el-table-column v-else sortable prop="name" label="流程(点击选中)" min-width="300" show-overflow-tooltip>
<template slot-scope="scope"> <template slot-scope="scope">
<el-link type="primary" @click="rowClick( scope.row,scope.$index)">{{scope.row.name}}</el-link> <el-link type="primary" @click="rowClick( scope.row,scope.$index)">{{scope.row.name}}</el-link>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column
sortable
prop="tagNames"
label="标签"
min-width="150"
>
<el-table-column prop="tagNames" label="标签" min-width="150">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag
v-for="tagName in (scope.row.tagNames?scope.row.tagNames.split(','):[])"
:key="tagName"
>{{tagName}}</el-tag>
<el-tag v-for="tagName in (scope.row.tagNames?scope.row.tagNames.split(','):[])" :key="tagName">
{{tagName}}</el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column
sortable
prop="description"
label="描述"
min-width="200"
></el-table-column>
<el-table-column sortable prop="version" label="版本" min-width="80" ></el-table-column>
<el-table-column prop="description" label="描述" min-width="200" show-overflow-tooltip></el-table-column>
<el-table-column sortable prop="version" label="版本" min-width="80" show-overflow-tooltip></el-table-column>
<el-table-column label="操作" :min-width="screenWidth>=500?200:80" fixed="right"> <el-table-column label="操作" :min-width="screenWidth>=500?200:80" fixed="right">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button v-show="isSelectModel" @click="rowClick(scope.row,scope.$index)">选中</el-button> <el-button v-show="isSelectModel" @click="rowClick(scope.row,scope.$index)">选中</el-button>
<el-button
type="primary"
v-show="!isSelectModel"
@click="showFlowStart(scope.row,scope.$index)"
>发起</el-button>
<el-button
class="hidden-sm-and-down"
@click="showDiagram( scope.row,scope.$index)"
>流程图</el-button>
<el-button type="primary" v-show="!isSelectModel" @click="showFlowStart(scope.row,scope.$index)">发起
</el-button>
<el-button class="hidden-sm-and-down" @click="showDiagram( scope.row,scope.$index)">流程图</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-pagination
layout="total, sizes, prev, pager, next"
@current-change="handleCurrentChange"
@size-change="handleSizeChange"
:page-sizes="[10,20, 50, 100, 500]"
:current-page="pageInfo.pageNum"
:page-size="pageInfo.pageSize"
:total="pageInfo.total"
style="float:right;"
></el-pagination>
<el-pagination layout="total, sizes, prev, pager, next" @current-change="handleCurrentChange"
@size-change="handleSizeChange" :page-sizes="[10,20, 50, 100, 500]" :current-page="pageInfo.pageNum"
:page-size="pageInfo.pageSize" :total="pageInfo.total" style="float:right;"></el-pagination>
<!--流程图界面--> <!--流程图界面-->
<el-dialog
title="流程图"
:visible.sync="diagramVisible"
width="80%"
:close-on-click-modal="false"
>
<el-dialog title="流程图" :visible.sync="diagramVisible" width="80%" :close-on-click-modal="false">
<el-image :fit="'contain'" :src="diagramUrl"> <el-image :fit="'contain'" :src="diagramUrl">
<div slot="error" class="image-slot"> <div slot="error" class="image-slot">
<i class="el-icon-picture-outline"></i> <i class="el-icon-picture-outline"></i>
@ -139,25 +77,13 @@
</el-image> </el-image>
</el-dialog> </el-dialog>
<!--流程起动界面--> <!--流程起动界面-->
<el-dialog
title="发起流程"
:visible.sync="flowStartVisible"
:width="dialogWidth()"
:close-on-click-modal="false"
>
<procinst-parames-start-set
:procdef="addForm"
:visible="flowStartVisible"
:params="filters.params"
@cancel="flowStartVisible=false"
></procinst-parames-start-set>
<el-dialog title="发起流程" :visible.sync="flowStartVisible" :width="dialogWidth()" :close-on-click-modal="false">
<procinst-parames-start-set :procdef="addForm" :visible="flowStartVisible" :params="filters.params"
@cancel="flowStartVisible=false"></procinst-parames-start-set>
</el-dialog> </el-dialog>
<el-dialog append-to-body title="标签条件" :visible.sync="tagSelectVisible" width="60%"> <el-dialog append-to-body title="标签条件" :visible.sync="tagSelectVisible" width="60%">
<tag-mng
:tagIds="filters.tags?filters.tags.map(i=>i.tagId):[]"
:jump="true"
@select-confirm="onTagSelected"
></tag-mng>
<tag-mng :tagIds="filters.tags?filters.tags.map(i=>i.tagId):[]" :jump="true"
@select-confirm="onTagSelected"></tag-mng>
</el-dialog> </el-dialog>
</el-row> </el-row>
</el-col> </el-col>
@ -166,17 +92,24 @@
</template> </template>
<script> <script>
import util from "@/common/js/util"; //
import config from "@/common/config"; //
//import { selectCacheOptions,getDefaultValue,getCodeName } from '../../../../../api/common/code';//
import { listProcdef, listCategorys } from "@/api/mdp/workflow/re/procdef";
import ProcinstParamesStartSet from "../../ru/procinstParames/ProcinstParamesStartSet";
import Sticky from "@/components/Sticky"; // header
import { mapGetters } from "vuex";
import CategoryTree from "@/views/mdp/arc/category/CategoryTree"; //
import TagMng from "@/views/mdp/arc/tag/TagMng";
import { batchInsertOrDeleteTags } from "@/api/mdp/workflow/re/procdefTag";
export default {
import util from "@/common/js/util"; //
import config from "@/common/config"; //
//import { selectCacheOptions,getDefaultValue,getCodeName } from '../../../../../api/common/code';//
import {
listProcdef,
listCategorys
} from "@/api/mdp/workflow/re/procdef";
import ProcinstParamesStartSet from "../../ru/procinstParames/ProcinstParamesStartSet";
import Sticky from "@/components/Sticky"; // header
import {
mapGetters
} from "vuex";
import CategoryTree from "@/views/mdp/arc/category/CategoryTree"; //
import TagMng from "@/views/mdp/arc/tag/TagMng";
import {
batchInsertOrDeleteTags
} from "@/api/mdp/workflow/re/procdefTag";
export default {
name: "ProcdefListForStart", name: "ProcdefListForStart",
props: ["params", "isSelectModel"], props: ["params", "isSelectModel"],
computed: { computed: {
@ -256,7 +189,7 @@ export default {
categorys: [], categorys: [],
tagSelectVisible: false, tagSelectVisible: false,
isBatchSetProcTags: false, isBatchSetProcTags: false,
tableHeight:300,
tableHeight: 300,
/**end 自定义属性请在上面加 请加备注**/ /**end 自定义属性请在上面加 请加备注**/
}; };
}, //end data }, //end data
@ -343,7 +276,10 @@ export default {
branchId: row.branchId, branchId: row.branchId,
userid: this.userInfo.userid, userid: this.userInfo.userid,
tags: tags.map(i => { tags: tags.map(i => {
return { tagId: i.tagId, tagName: i.tagName };
return {
tagId: i.tagId,
tagName: i.tagName
};
}) })
}; };
procinstTagsVos.push(procinstTags); procinstTagsVos.push(procinstTags);
@ -457,6 +393,9 @@ export default {
params.tenantId = this.userInfo.branchId; params.tenantId = this.userInfo.branchId;
params.includeContext = "1"; params.includeContext = "1";
params.suspensionState = 1; params.suspensionState = 1;
if(this.params && !this.params.bizKey){
return;
}
this.listLoading = true; this.listLoading = true;
listProcdef(params) listProcdef(params)
.then(res => { .then(res => {
@ -466,7 +405,10 @@ export default {
this.pageInfo.count = false; this.pageInfo.count = false;
this.procdefs = res.data.data; this.procdefs = res.data.data;
} else { } else {
this.$message({ message: tips.msg, type: "error" });
this.$message({
message: tips.msg,
type: "error"
});
} }
this.listLoading = false; this.listLoading = false;
}) })
@ -487,7 +429,9 @@ export default {
}) })
.then(() => { .then(() => {
this.listLoading = true; this.listLoading = true;
let params = { id: row.id };
let params = {
id: row.id
};
startProcdef(params).then(res => { startProcdef(params).then(res => {
this.listLoading = false; this.listLoading = false;
var tips = res.data.tips; var tips = res.data.tips;
@ -532,12 +476,18 @@ export default {
this.$emit("closeTab"); this.$emit("closeTab");
this.$router.replace({ this.$router.replace({
name: "ProcinstParamesStartSetRoute", name: "ProcinstParamesStartSetRoute",
params: { procdef: row, params: this.filters.params }
params: {
procdef: row,
params: this.filters.params
}
}); });
} else { } else {
this.$router.push({ this.$router.push({
name: "ProcinstParamesStartSetRoute", name: "ProcinstParamesStartSetRoute",
params: { procdef: row, params: this.filters.params }
params: {
procdef: row,
params: this.filters.params
}
}); });
} }
}, },
@ -610,9 +560,9 @@ export default {
const data = this.formatJson(filterVal, list); const data = this.formatJson(filterVal, list);
var filename = "发起流程导出"; var filename = "发起流程导出";
if (this.formDefSelected) { if (this.formDefSelected) {
filename = this.formDefSelected.formName
? this.formDefSelected.formName
: this.formDefSelected.id + "发起流程导出";
filename = this.formDefSelected.formName ?
this.formDefSelected.formName :
this.formDefSelected.id + "发起流程导出";
} }
excel.export_json_to_excel({ excel.export_json_to_excel({
header: tHeader, header: tHeader,
@ -648,28 +598,50 @@ export default {
this.filters.params = this.params; this.filters.params = this.params;
} }
this.$nextTick(()=>{
var clientRect=this.$refs.procdefsTable.$el.getBoundingClientRect();
var subHeight=70/1000 * window.innerHeight;
this.tableHeight = window.innerHeight -clientRect.y - this.$refs.procdefsTable.$el.offsetTop-subHeight;
this.$nextTick(() => {
var clientRect = this.$refs.procdefsTable.$el.getBoundingClientRect();
var subHeight = 70 / 1000 * window.innerHeight;
this.tableHeight = window.innerHeight - clientRect.y - this.$refs.procdefsTable.$el.offsetTop - subHeight;
}) })
this.searchProcdefs(); this.searchProcdefs();
listCategorys({ tenantId: this.userInfo.branchId }).then(res => {
listCategorys({
tenantId: this.userInfo.branchId
}).then(res => {
this.categorys = res.data.data; this.categorys = res.data.data;
}); });
} }
};
};
</script> </script>
<style scoped> <style scoped>
.filters-show {
.filters-show {
margin-left: 20px; margin-left: 20px;
margin-top: 10px; margin-top: 10px;
margin-bottom: 0px; margin-bottom: 0px;
}
.filters-label {
}
.filters-label {
font-size: 14px; font-size: 14px;
color: black; color: black;
font-weight: bold; font-weight: bold;
}
}
.el-button+.el-button {
margin-left: 0px;
}
</style>
<style>
.el-input-group__append,
.el-input-group__prepend {
background-color: #409EFF !important;
color: #ffffff !important;
vertical-align: middle;
display: table-cell;
position: relative;
border: 1px solid #409EFF !important;
padding: 0 20px;
width: 1px;
white-space: nowrap;
}
</style> </style>

36
src/views/mdp/workflow/re/procdef/ProcdefMng.vue

@ -16,42 +16,6 @@
</el-select> </el-select>
<el-button @click.native="showTagSelect(false)" >标签查找</el-button> <el-button @click.native="showTagSelect(false)" >标签查找</el-button>
<el-button @click.native="showTagSelect(true)" >打标签</el-button> <el-button @click.native="showTagSelect(true)" >打标签</el-button>
</el-row>
<el-row class="filters-show">
<font class="filters-label">已选条件:</font>
<el-tag v-if="filters.tags"
:key="tag.tagId"
v-for="tag in filters.tags"
:type="''"
closable
:disable-transitions="false"
@close="handleFiltersTagClose(tag,'tags')">
{{tag.tagName}}
</el-tag>
<el-tag v-if="filters.categoryTreeNodes"
:key="tag.id"
v-for="tag in filters.categoryTreeNodes"
:type="'info'"
closable
:disable-transitions="false"
@close="handleFiltersTagClose(tag,'categoryTreeNodes')">
{{tag.name}}
</el-tag>
<el-tag v-if="filters.procCategory"
:type="'dangger'"
closable
:disable-transitions="false"
@close="handleFiltersTagClose('','procCategory')" >
{{filters.procCategory}}
</el-tag>
<el-tag v-if="filters.key"
:type="'success'"
closable
:disable-transitions="false"
@close="handleFiltersTagClose('','key')">
{{filters.key}}
</el-tag>
</el-row> </el-row>
<el-row class="app-container"> <el-row class="app-container">
<el-col :xs="4" :sm="4" :md="4" :lg="4" :xl="4" class="hidden-sm-and-down"> <el-col :xs="4" :sm="4" :md="4" :lg="4" :xl="4" class="hidden-sm-and-down">

39
src/views/mdp/workflow/re/procdef/ProcdefSuspend.vue

@ -1,33 +1,22 @@
<template> <template>
<section> <section>
<el-row class="app-container"> <el-row class="app-container">
<el-col :xs="4" :sm="4" :md="4" :lg="4" :xl="4" class="hidden-sm-and-down">
<category-tree
ref="categoryTree"
multiple
:expandOnClickNode="false"
:defaultExpandAll="true"
show-checkbox
:current-key="addForm.categoryId"
v-on:check-change="handleCategoryCheckChange"
></category-tree>
</el-col>
<el-col :xs="24" :sm="24" :md="20" :lg="20" :xl="20">
<el-col>
<el-row> <el-row>
<el-select v-model="filters.procCategory" clearable filterable placeholder="请选择分类"> <el-select v-model="filters.procCategory" clearable filterable placeholder="请选择分类">
<el-option v-for="item in categorys" :key="item" :label="item" :value="item"></el-option> <el-option v-for="item in categorys" :key="item" :label="item" :value="item"></el-option>
</el-select> </el-select>
<el-button @click.native="showTagSelect(false)">标签查找</el-button>
<el-input v-model="filters.key" style="width:20%;" placeholder="模糊查询">
<el-input v-model="filters.key" style="width:270px;" placeholder="模糊查询">
<template slot="append"> <template slot="append">
<el-button type="primary" v-on:click="searchProcdefs" icon="el-icon-search">查询</el-button> <el-button type="primary" v-on:click="searchProcdefs" icon="el-icon-search">查询</el-button>
</template> </template>
</el-input> </el-input>
<el-button type="primary" @click="handleDownload" icon="el-icon-download">导出数据</el-button>
<el-button @click.native="showTagSelect(true)">打标签</el-button>
<el-button @click.native="showTagSelect(false)" icon="el-icon-search" style="margin-left: 13px;" class="hidden-sm-and-down">标签</el-button>
<el-button @click.native="showTagSelect(true)" icon="el-icon-plus" class="hidden-sm-and-down">标签</el-button>
<el-button @click="handleDownload" icon="el-icon-download" class="hidden-md-and-down">导出数据</el-button>
</el-row> </el-row>
<!--列表 Procdef act_re_procdef--> <!--列表 Procdef act_re_procdef-->
<el-row style="padding-top:10px;">
<el-row style="padding-top:20px;">
<el-table <el-table
ref="table" :max-height="tableHeight" ref="table" :max-height="tableHeight"
:data="procdefs" :data="procdefs"
@ -82,7 +71,7 @@
min-width="80" min-width="80"
show-overflow-tooltip show-overflow-tooltip
></el-table-column> ></el-table-column>
<el-table-column label="操作" width="200" fixed="right" >
<el-table-column label="操作" width="220" fixed="right" >
<template slot-scope="scope"> <template slot-scope="scope">
<el-button @click="showDiagram( scope.row,scope.$index)">流程图</el-button> <el-button @click="showDiagram( scope.row,scope.$index)">流程图</el-button>
<el-button <el-button
@ -603,3 +592,17 @@ export default {
font-weight: bold; font-weight: bold;
} }
</style> </style>
<style>
.el-input-group__append, .el-input-group__prepend {
background-color: #409EFF!important;
color: #ffffff!important;
vertical-align: middle;
display: table-cell;
position: relative;
border: 1px solid #409EFF!important;
padding: 0 20px;
width: 1px;
white-space: nowrap;
}
</style>

38
src/views/mdp/workflow/re/procdefParames/ProcdefParamesSet.vue

@ -8,7 +8,7 @@
<el-form-item label="流程标题" prop="mainTitle"> <el-form-item label="流程标题" prop="mainTitle">
<el-input v-model="addForm.mainTitle" auto-complete="off"></el-input> <el-input v-model="addForm.mainTitle" auto-complete="off"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="标签" prop="tagNames">
<el-form-item label="流程标签" prop="tagNames">
<font v-if="addForm.tagNames"> <font v-if="addForm.tagNames">
<el-tag v-for="tag in (addForm.tagNames.split(','))" :key="tag" <el-tag v-for="tag in (addForm.tagNames.split(','))" :key="tag"
:type="'warning'" :type="'warning'"
@ -16,14 +16,14 @@
{{tag}} {{tag}}
</el-tag> </el-tag>
</font> </font>
{{addForm.tagNames?'':'还没有标签,去打一个呗-->'}}
<el-button @click.native="tagSelectVisible=true" :loading="addLoading">标签</el-button>
<el-button v-if="displayDiagram==false" @click="showDiagram()">流程图</el-button>
{{addForm.tagNames?'':''}}
<el-button @click.native="tagSelectVisible=true" :loading="addLoading" icon="el-icon-plus">标签</el-button>
<el-button v-if="displayDiagram==false" @click="showDiagram()" icon="el-icon-view">流程图</el-button>
</el-form-item> </el-form-item>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="监控" prop="monitors">
<el-form-item label="流程监控" prop="monitors">
<el-col :span="16"> <el-col :span="16">
<el-select style="width:100%" v-model="monitors" multiple clearable filterable placeholder="请选择">
<el-select style="width:100%" v-model="monitors" multiple clearable filterable placeholder="请选择人员">
<el-option <el-option
v-for="item in baseUserList" v-for="item in baseUserList"
:key="item.userid" :key="item.userid"
@ -35,15 +35,15 @@
</el-select> </el-select>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-button @click.native="monitorsSelectVisible=true" :loading="addLoading">更多人员</el-button>
<el-button @click.native="monitorsSelectVisible=true" :loading="addLoading" icon="el-icon-more"></el-button>
</el-col> </el-col>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="主办" prop="sponsors">
<el-form-item label="流程主办" prop="sponsors">
<el-col :span="16"> <el-col :span="16">
<el-select style="width:100%" v-model="sponsors" multiple clearable filterable placeholder="请选择">
<el-select style="width:100%" v-model="sponsors" multiple clearable filterable placeholder="请选择人员">
<el-option <el-option
v-for="item in baseUserList" v-for="item in baseUserList"
:key="item.userid" :key="item.userid"
@ -55,15 +55,15 @@
</el-select> </el-select>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-button @click.native="sponsorsSelectVisible=true" :loading="addLoading">更多人员</el-button>
<el-button @click.native="sponsorsSelectVisible=true" :loading="addLoading" icon="el-icon-more"></el-button>
</el-col> </el-col>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-form-item label="流程归档分类" prop="categoryId">
<el-form-item label="归档分类" prop="categoryId">
<el-col :span="14"> <category-tree show-checkbox :current-key="addForm.categoryId" v-on:check-change="handleCategoryCheckChange" ></category-tree> <el-col :span="14"> <category-tree show-checkbox :current-key="addForm.categoryId" v-on:check-change="handleCategoryCheckChange" ></category-tree>
</el-col> </el-col>
</el-form-item> </el-form-item>
<el-form-item label="关联智能表单" prop="isRefForm">
<el-form-item label="关联表单" prop="isRefForm">
<el-col :span="10"> <el-col :span="10">
<el-select style="width:100%" v-model="addForm.formId" clearable filterable placeholder="请选择"> <el-select style="width:100%" v-model="addForm.formId" clearable filterable placeholder="请选择">
<el-option <el-option
@ -74,7 +74,7 @@
</el-option> </el-option>
</el-select> </el-select>
</el-col> </el-col>
<el-col :span="10" style="padding-left:5px;">
<el-col :span="10" style="padding-left:22px;">
<el-radio v-model="addForm.formShowType" label="form">表单形式展现</el-radio> <el-radio v-model="addForm.formShowType" label="form">表单形式展现</el-radio>
<el-radio v-model="addForm.formShowType" label="table">表格形式展现</el-radio> <el-radio v-model="addForm.formShowType" label="table">表格形式展现</el-radio>
</el-col> </el-col>
@ -98,9 +98,9 @@
min-width="250"> min-width="250">
<template slot-scope="scope"> <template slot-scope="scope">
{{showAssigneeTips(scope.row)}} {{showAssigneeTips(scope.row)}}
<el-button round v-if="scope.row.candidate=='1'" type="warning" @click.native="showCandidateSelectDialog(scope.row,'')" :loading="addLoading">选候选人</el-button>
<el-button round v-if="scope.row.candidate!='1' " type="success" @click.native="showUserSelectDialog(scope.row,'')" :loading="addLoading">选人员</el-button>
<el-button round v-if="scope.row.toCreater!='1'" type="primary" @click.native="setAssigneeAsStartUser(scope.row)">转发起人</el-button>
<el-button round v-if="scope.row.candidate=='1'" size="mini" @click.native="showCandidateSelectDialog(scope.row,'')" :loading="addLoading">选候选人</el-button>
<el-button round v-if="scope.row.candidate!='1' " size="mini" @click.native="showUserSelectDialog(scope.row,'')" :loading="addLoading">选人员</el-button>
<el-button round v-if="scope.row.toCreater!='1'" size="mini" @click.native="setAssigneeAsStartUser(scope.row)">转发起人</el-button>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
@ -153,10 +153,10 @@
<el-button @click="showMainQxDialog">点击查看/设置流程权限</el-button> <el-button @click="showMainQxDialog">点击查看/设置流程权限</el-button>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button @click.native="handleCancel">取消</el-button>
<el-button type="primary" @click.native="templateVisible=true" :loading="addLoading">导入模板</el-button>
<el-button type="primary" @click.native="saveAsTemplate" :loading="addLoading">存为模板</el-button>
<el-button type="primary" @click.native="addOrEditSubmit" :loading="addLoading">提交</el-button> <el-button type="primary" @click.native="addOrEditSubmit" :loading="addLoading">提交</el-button>
<el-button @click.native="handleCancel">取消</el-button>
<el-button @click.native="templateVisible=true" :loading="addLoading">导入模板</el-button>
<el-button @click.native="saveAsTemplate" :loading="addLoading">存为模板</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
</el-col> </el-col>

1223
src/views/mdp/workflow/ru/execution/ExecutionMng.vue
File diff suppressed because it is too large
View File

55
src/views/mdp/workflow/ru/procinstParames/ProcinstParamesExecutionSet.vue

@ -71,8 +71,14 @@
placeholder="选择计划完成日期" > placeholder="选择计划完成日期" >
</el-date-picker> </el-date-picker>
完成 <el-button @click.native="updateFlowPlanFinishTime" :loading="addLoading" icon="el-icon-finished">保存日期</el-button> 完成 <el-button @click.native="updateFlowPlanFinishTime" :loading="addLoading" icon="el-icon-finished">保存日期</el-button>
主办人
<el-popover
placement="top-start"
title="设置主办监控人"
width="400"
trigger="manual" v-model="sponsorsAndMonitorsVisible">
<el-row>
<el-col :span="24" style="padding-top:5px;">
<font class="more-label-font">主办人:</font>
<el-select disabled value-key="userid" v-model="sponsors" multiple placeholder="请选择"> <el-select disabled value-key="userid" v-model="sponsors" multiple placeholder="请选择">
<el-option <el-option
v-for="item in baseUserList" v-for="item in baseUserList"
@ -83,8 +89,9 @@
<span style="float: right; color: #8492a6; font-size: 14px">{{ item.shortName }}</span> <span style="float: right; color: #8492a6; font-size: 14px">{{ item.shortName }}</span>
</el-option> </el-option>
</el-select> </el-select>
<font class=" hidden-md-and-down">
监控人
</el-col>
<el-col :span="24" style="padding-top:5px;">
<font class="more-label-font">监控人:</font>
<el-select disabled value-key="userid" v-model="monitors" multiple placeholder="请选择"> <el-select disabled value-key="userid" v-model="monitors" multiple placeholder="请选择">
<el-option <el-option
v-for="item in baseUserList" v-for="item in baseUserList"
@ -95,7 +102,10 @@
<span style="float: right; color: #8492a6; font-size: 13px">{{ item.shortName }}</span> <span style="float: right; color: #8492a6; font-size: 13px">{{ item.shortName }}</span>
</el-option> </el-option>
</el-select> </el-select>
</font>
</el-col>
</el-row>
<el-button slot="reference" icon="el-icon-s-check" @click="showSponsorsAndMonitors">主办人监控人查询</el-button>
</el-popover>
</el-row> </el-row>
<el-row v-if="addForm.isRefForm=='1' && addForm.formId && addForm.formShowType!='table'" style="padding-top:10px;"> <el-row v-if="addForm.isRefForm=='1' && addForm.formId && addForm.formShowType!='table'" style="padding-top:10px;">
<form-data-mng-for-flow-form :formShowType="addForm.formShowType" :companyDepts="companyDepts" :companyEmployees="companyEmployees" :formId="addForm.formId" :qxCode="qxCode" :procInstId="procInstId" :flowStartUserid="addForm.userid" :submitEvent="formDataSubmitEvent" @submit="startSubmit"><div></div></form-data-mng-for-flow-form> <form-data-mng-for-flow-form :formShowType="addForm.formShowType" :companyDepts="companyDepts" :companyEmployees="companyEmployees" :formId="addForm.formId" :qxCode="qxCode" :procInstId="procInstId" :flowStartUserid="addForm.userid" :submitEvent="formDataSubmitEvent" @submit="startSubmit"><div></div></form-data-mng-for-flow-form>
@ -369,9 +379,9 @@
this.task.rejectActivity.taskId='' this.task.rejectActivity.taskId=''
this.$nextTick(() => { this.$nextTick(() => {
this.getProcinstParamess(); this.getProcinstParamess();
this.listNodeInfos();
//this.listNodeInfos();
}); });
this.initBaseUserList();
//this.initBaseUserList();
} }
}, },
data() { data() {
@ -598,7 +608,7 @@
showMainContextOnly:false, showMainContextOnly:false,
nodeInfos:[], nodeInfos:[],
nodeInfoVisible:false, nodeInfoVisible:false,
sponsorsAndMonitorsVisible:false,
/**end 在上面加自定义属性**/ /**end 在上面加自定义属性**/
}//end return }//end return
},//end data },//end data
@ -827,7 +837,7 @@
this.diagramUrl=config.getBaseDomainUrl()+config.getWorkflowBasePath()+'/mdp/workflow/ru/diagram/'+this.procDefId+'/'+this.procInstId this.diagramUrl=config.getBaseDomainUrl()+config.getWorkflowBasePath()+'/mdp/workflow/ru/diagram/'+this.procDefId+'/'+this.procInstId
this.displayDiagram=true; this.displayDiagram=true;
}, },
initBaseUserList(){
initBaseUserList(sponsorsAndMonitorsVisible){
var that=this; var that=this;
var sponsors=that.addForm.sponsors?that.addForm.sponsors.split(',').map(i=>{return {userid:i,username:i}}):[]; var sponsors=that.addForm.sponsors?that.addForm.sponsors.split(',').map(i=>{return {userid:i,username:i}}):[];
var monitors=that.addForm.monitors?that.addForm.monitors.split(',').map(i=>{return {userid:i,username:i}}):[]; var monitors=that.addForm.monitors?that.addForm.monitors.split(',').map(i=>{return {userid:i,username:i}}):[];
@ -852,6 +862,7 @@
}); });
}) })
} }
this.sponsorsAndMonitorsVisible=sponsorsAndMonitorsVisible
}); });
}, },
handleUploadChange(){ handleUploadChange(){
@ -985,9 +996,14 @@
}); });
}, },
showNodeInfoDialog:function(){ showNodeInfoDialog:function(){
if(this.nodeInfos && this.nodeInfos.length>0){
this.nodeInfoVisible=true; this.nodeInfoVisible=true;
}else{
this.listNodeInfos(true)
}
}, },
listNodeInfos(){
listNodeInfos(showNodeInfoDialog){
var params={procInstId:this.taskInfo.procInstId} var params={procInstId:this.taskInfo.procInstId}
getNodeInfos(params).then(res=>{ getNodeInfos(params).then(res=>{
if(res.data.tips.isOk){ if(res.data.tips.isOk){
@ -1006,6 +1022,9 @@
}else{ }else{
this.actAssignee=null; this.actAssignee=null;
} }
if(showNodeInfoDialog){
this.nodeInfoVisible=true;
}
} }
} }
}); });
@ -1050,6 +1069,13 @@
}) })
}, },
showSponsorsAndMonitors(){
if( (this.monitors==null || this.monitors.length==0 || this.sponsors==null||this.sponsors.length==0) && this.sponsorsAndMonitorsVisible==false ){
this.initBaseUserList(true)
}else{
this.sponsorsAndMonitorsVisible=!this.sponsorsAndMonitorsVisible;
}
}
/**end 在上面加自定义方法**/ /**end 在上面加自定义方法**/
},//end method },//end method
@ -1093,7 +1119,7 @@
this.qxCode= this.addForm.mainQx this.qxCode= this.addForm.mainQx
this.initBaseUserList();
//this.initBaseUserList();
console.log("mountedxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx") console.log("mountedxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx")
console.log(this.taskInfo) console.log(this.taskInfo)
if(this.taskInfo.assignee==null || this.taskInfo.assignee==''){ if(this.taskInfo.assignee==null || this.taskInfo.assignee==''){
@ -1108,7 +1134,7 @@
this.$nextTick(() => { this.$nextTick(() => {
this.getProcinstParamess(); this.getProcinstParamess();
}); });
this.listNodeInfos();
//this.listNodeInfos();
} }
/**在下面写其它函数***/ /**在下面写其它函数***/
@ -1141,4 +1167,9 @@
.wf-main-context p > img { .wf-main-context p > img {
max-width: 100%; max-width: 100%;
} }
.more-label-font{
text-align:center;
float:left;
padding-top:5px;
}
</style> </style>

67
src/views/mdp/workflow/ru/procinstParames/ProcinstParamesStartSet.vue

@ -1,6 +1,6 @@
<template> <template>
<section> <section>
<el-row>
<el-row class="app-container">
<!--新增界面 ProcinstParames 流程实例参数设置表--> <!--新增界面 ProcinstParames 流程实例参数设置表-->
<el-col :span="24"> <el-col :span="24">
@ -32,10 +32,8 @@
</el-date-picker> </el-date-picker>
</el-col> <font style="margin-left:5px;"></font> </el-col> <font style="margin-left:5px;"></font>
</el-form-item> </el-form-item>
<el-col :span="24">
<el-col :span="12">
<el-form-item label="发起部门" prop="deptid"> <el-form-item label="发起部门" prop="deptid">
<el-select style="width:99%;" v-model="addForm.deptid" clearable filterable placeholder="请选择">
<el-select v-model="addForm.deptid" clearable filterable placeholder="请选择">
<el-option <el-option
v-for="item in myDepts" v-for="item in myDepts"
:key="item.deptid" :key="item.deptid"
@ -43,26 +41,29 @@
:value="item.deptid"> :value="item.deptid">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item>
</el-col>
</el-col>
<el-col :span="12">
<el-form-item label="主办人" prop="sponsors" >
<el-select value-key="userid" style="width:99%" v-model="sponsors" multiple placeholder="请选择">
<el-popover
placement="top-start"
title="设置主办监控人"
width="400"
trigger="manual" v-model="sponsorsAndMonitorsVisible">
<el-row>
<el-col :span="24" style="padding-top:5px;">
<font class="more-label-font">主办人:</font>
<el-select disabled value-key="userid" v-model="sponsors" multiple placeholder="请选择">
<el-option <el-option
v-for="item in baseUserList" v-for="item in baseUserList"
:key="item.userid" :key="item.userid"
:label="item.username" :label="item.username"
:value="item"> :value="item">
<span style="float: left">{{ item.username }}</span> <span style="float: left">{{ item.username }}</span>
<span style="float: right; color: #8492a6; font-size: 13px">{{ item.shortName }}</span>
<span style="float: right; color: #8492a6; font-size: 14px">{{ item.shortName }}</span>
</el-option> </el-option>
</el-select> </el-select>
</el-form-item>
</el-col> </el-col>
<el-col :span="12">
<el-form-item label="监控人" prop="monitors">
<el-select value-key="userid" style="width:99%" v-model="monitors" multiple placeholder="请选择">
<el-col :span="24" style="padding-top:5px;">
<font class="more-label-font">监控人:</font>
<el-select disabled value-key="userid" v-model="monitors" multiple placeholder="请选择">
<el-option <el-option
v-for="item in baseUserList" v-for="item in baseUserList"
:key="item.userid" :key="item.userid"
@ -72,8 +73,11 @@
<span style="float: right; color: #8492a6; font-size: 13px">{{ item.shortName }}</span> <span style="float: right; color: #8492a6; font-size: 13px">{{ item.shortName }}</span>
</el-option> </el-option>
</el-select> </el-select>
</el-form-item>
</el-col> </el-col>
</el-row>
<el-button slot="reference" icon="el-icon-s-check" @click="showSponsorsAndMonitors">主办人监控人查询</el-button>
</el-popover>
</el-form-item>
<div v-if="addForm.isRefForm=='1' && addForm.formId!=null && addForm.formId!='' && addForm.formShowType!='table' "> <div v-if="addForm.isRefForm=='1' && addForm.formId!=null && addForm.formId!='' && addForm.formShowType!='table' ">
<form-data-mng-for-flow-form :form-data-id="filters.formDataId" :qxCode="addForm.mainQx" :isFlowStart="true" :form-id="addForm.formId" :submit-event="formDataSubmitEvent" @submit="startSubmit"><div></div></form-data-mng-for-flow-form> <form-data-mng-for-flow-form :form-data-id="filters.formDataId" :qxCode="addForm.mainQx" :isFlowStart="true" :form-id="addForm.formId" :submit-event="formDataSubmitEvent" @submit="startSubmit"><div></div></form-data-mng-for-flow-form>
</div> </div>
@ -354,6 +358,7 @@
showAttachment:false, showAttachment:false,
nodeInfoVisible:false, nodeInfoVisible:false,
nodeInfos:[], nodeInfos:[],
sponsorsAndMonitorsVisible:false,
/**end 在上面加自定义属性**/ /**end 在上面加自定义属性**/
}//end return }//end return
},//end data },//end data
@ -377,17 +382,7 @@
params.extVars=this.params.extVars params.extVars=this.params.extVars
params.flowVars=this.params.flowVars params.flowVars=this.params.flowVars
} }
if(this.nodeInfos.length<=0){
this.listBpmnActAssignees(true);
this.$message({ message: "未配置节点审批人,无法提交,将自动加载默认配置,请稍后提交", type: 'error' });
return;
}else{
if(this.nodeInfos.some(i=>i.toCreater!='1' && (i.nodeUsers==null || i.nodeUsers.length==0))){
this.$message.error("还有节点未配置审批人,请配置审批人后再提交");
this.showNodeInfoDialog();
return;
}
}
this.addLoading = true; this.addLoading = true;
params.procinstParames.startDeptName=this.myDepts.filter(d=>d.deptid==this.addForm.deptid)[0].deptName; params.procinstParames.startDeptName=this.myDepts.filter(d=>d.deptid==this.addForm.deptid)[0].deptName;
params.procinstParames.startUsername=this.userInfo.username params.procinstParames.startUsername=this.userInfo.username
@ -450,7 +445,7 @@
}) })
}, },
initBaseUserList(){
initBaseUserList(sponsorsAndMonitorsVisible){
var that=this; var that=this;
var sponsors=[]; var sponsors=[];
var monitors=[]; var monitors=[];
@ -477,6 +472,7 @@
that.monitors=monitors that.monitors=monitors
that.sponsors=sponsors that.sponsors=sponsors
that.baseUserList=baseUserList that.baseUserList=baseUserList
this.sponsorsAndMonitorsVisible=sponsorsAndMonitorsVisible
return; return;
}else{ }else{
listUserNames({userids:baseUserList.map(i=>i.userid),branchId:that.userInfo.branchId}).then(res=>{ listUserNames({userids:baseUserList.map(i=>i.userid),branchId:that.userInfo.branchId}).then(res=>{
@ -498,6 +494,7 @@
that.sponsors=sponsors that.sponsors=sponsors
that.baseUserList=baseUserList that.baseUserList=baseUserList
} }
this.sponsorsAndMonitorsVisible=sponsorsAndMonitorsVisible
}); });
} }
@ -564,7 +561,11 @@
this.mainQxVisible=true; this.mainQxVisible=true;
}, },
showNodeInfoDialog:function(){ showNodeInfoDialog:function(){
if(this.nodeInfos==null || this.nodeInfos.length==0){
this.listBpmnActAssignees(true)
}else{
this.nodeInfoVisible=true; this.nodeInfoVisible=true;
}
}, },
onFormFieldsLoad:function(formFields){ onFormFieldsLoad:function(formFields){
this.formFields=formFields; this.formFields=formFields;
@ -616,6 +617,14 @@
this.addForm.tagNames=this.procdef.tagNames; this.addForm.tagNames=this.procdef.tagNames;
this.addForm.mainQx=this.procdef.mainQx; this.addForm.mainQx=this.procdef.mainQx;
}, },
showSponsorsAndMonitors(){
if( (this.monitors==null || this.monitors.length==0 || this.sponsors==null||this.sponsors.length==0) && this.sponsorsAndMonitorsVisible==false ){
this.initBaseUserList(true)
}else{
this.sponsorsAndMonitorsVisible=!this.sponsorsAndMonitorsVisible;
}
},
listBpmnActAssignees(nodeInfoVisible){ listBpmnActAssignees(nodeInfoVisible){
this.nodeInfos=[]; this.nodeInfos=[];
this.listLoading = true; this.listLoading = true;
@ -649,7 +658,7 @@
this.$nextTick(() => { this.$nextTick(() => {
this.initByProcdef();//procdef this.initByProcdef();//procdef
this.initByParams();// params params this.initByParams();// params params
this.listBpmnActAssignees();
//this.listBpmnActAssignees();
this.initBaseUserList(); this.initBaseUserList();
}); });
/**在下面写其它函数***/ /**在下面写其它函数***/

705
src/views/mdp/workflow/ru/task/TaskMng.vue
File diff suppressed because it is too large
View File

Loading…
Cancel
Save