综合办公系统
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

definition.js 2.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149
  1. import request from '@/utils/request'
  2. // 查询流程定义列表
  3. export function listDefinition(query) {
  4. return request({
  5. url: '/flowable/definition/list',
  6. method: 'get',
  7. params: query
  8. })
  9. }
  10. // 部署流程实例
  11. export function definitionStart(procDefId, data) {
  12. return request({
  13. url: '/flowable/definition/start/' + procDefId,
  14. method: 'post',
  15. data: data
  16. })
  17. }
  18. // 获取流程变量
  19. export function getProcessVariables(taskId) {
  20. return request({
  21. url: '/flowable/task/processVariables/' + taskId,
  22. method: 'get'
  23. })
  24. }
  25. // 激活/挂起流程
  26. export function updateState(params) {
  27. return request({
  28. url: '/flowable/definition/updateState',
  29. method: 'put',
  30. params: params
  31. })
  32. }
  33. // 指定流程办理人员列表
  34. export function userList(query) {
  35. return request({
  36. url: '/flowable/definition/userList',
  37. method: 'get',
  38. params: query
  39. })
  40. }
  41. // 指定流程办理组列表
  42. export function roleList(query) {
  43. return request({
  44. url: '/flowable/definition/roleList',
  45. method: 'get',
  46. params: query
  47. })
  48. }
  49. // 指定流程表达式
  50. export function expList(query) {
  51. return request({
  52. url: '/flowable/definition/expList',
  53. method: 'get',
  54. params: query
  55. })
  56. }
  57. // 读取xml文件
  58. export function readXml(deployId) {
  59. return request({
  60. url: '/flowable/definition/readXml/' + deployId,
  61. method: 'get'
  62. })
  63. }
  64. // 读取image文件
  65. export function readImage(deployId) {
  66. return request({
  67. url: '/flowable/definition/readImage/' + deployId,
  68. method: 'get'
  69. })
  70. }
  71. // 获取流程执行节点
  72. export function getFlowViewer(procInsId, executionId) {
  73. return request({
  74. url: '/flowable/task/flowViewer/' + procInsId + '/' + executionId,
  75. method: 'get'
  76. })
  77. }
  78. // 流程节点数据
  79. export function flowXmlAndNode(query) {
  80. return request({
  81. url: '/flowable/task/flowXmlAndNode',
  82. method: 'get',
  83. params: query
  84. })
  85. }
  86. // 通过表单id及流程名获取流程节点信息
  87. export function flowXmlAndNodeByFormId(query) {
  88. return request({
  89. url: '/flowable/task/flowXmlAndNodeByFormId',
  90. method: 'get',
  91. params: query
  92. })
  93. }
  94. // 读取xml文件
  95. export function saveXml(data) {
  96. return request({
  97. url: '/flowable/definition/save',
  98. method: 'post',
  99. data: data
  100. })
  101. }
  102. // 新增流程定义
  103. export function addDeployment(data) {
  104. return request({
  105. url: '/system/deployment',
  106. method: 'post',
  107. data: data
  108. })
  109. }
  110. // 修改流程定义
  111. export function updateDeployment(data) {
  112. return request({
  113. url: '/system/deployment',
  114. method: 'put',
  115. data: data
  116. })
  117. }
  118. // 删除流程定义
  119. export function delDeployment(deployId) {
  120. return request({
  121. url: '/flowable/definition/' + deployId,
  122. method: 'delete',
  123. })
  124. }
  125. // 导出流程定义
  126. export function exportDeployment(query) {
  127. return request({
  128. url: '/system/deployment/export',
  129. method: 'get',
  130. params: query
  131. })
  132. }