import http from '@/http'

// export const procdefBizForm = data =>
//   http.post('/ls_workflow_rebuild/api/v1/procdef/biz_form', data) // 根据业务编号查询流程
export const processConfigDetail = params =>
  http.get(`/api/v1/sys/procdef/detail/${params.formId}`)// 系统流程配置详情java
export const procdefUnit = params =>
  http.get('/api/v1/organization/procdef/list', { params }) // 根据单位编号查询流程java
export const procdefList = data =>
  http.post('/ls_workflow_rebuild/api/v1/procdef/list', data) // 主流程列表
export const processConfigList = params =>
  http.get('/api/v1/sys/procdef/list', { params })// 主流程列表java
export const processStatusSet = data =>
  http.put(`/api/v1/sys/procdef/${data.formId}/active/${data.state}`, data) // 系统流程配置发启用(禁用)java
export const procdefSave = data =>
  http.post('/api/v1/organization/procdef/save', data) // 单位流程保存java
export const systemProcessSave = data =>
  http.post('/api/v1/sys/procdef/save', data) // 系统流程保存java
export const systemProcessRelease = formId =>
  http.post(`/api/v1/sys/procdef/deploy/${formId}`) // 系统流程发布java
export const procEnable = data =>
  http.put(`/api/v1/organization/procdef/enable/${data.processDefId}`, data) // 流程启用java
export const procDisable = data =>
  http.put(`/api/v1/organization/procdef/disable/${data.processDefId}`, data) // 流程禁用java
export const procDefRelease = data =>
  http.post(`/api/v1/organization/procdef/deploy/${data.processDefId}`, data) // 流程配置发布java
