DxDynamicCode.js 1.31 KB
import {
  get,
  del,
  post
} from '../utils/http'

export function groupScopeByCondition(params) {
  return get('/DxDynamicCode/groupScopeByCondition', params)
}

export function generateCodeExecuteTemplate(params) {
  return get('/DxDynamicCode/generateCodeExecuteTemplate', params)
}

export function preCompile(params) {
  return post('/DxDynamicCode/preCompile', params)
}

export function getHistory(id) {
  return get(`/DxDynamicCode/findHistory/${id}`)
}

export function cancelCheckout(objId) {
  return post(`/DxDynamicCode/version/${objId}/undoCheckout`)
}

export function checkin(objId) {
  return post(`/DxDynamicCode/version/${objId}/checkin`)
}

export function checkout(objId) {
  return post(`/DxDynamicCode/version/${objId}/checkout`)
}

export function getWorkingCopy(id) {
  return get(`/DxDynamicCode/version/getWorkingCopy/${id}`)
}

export function getRefInfo(id) {
  return get(`/DxDynamicCodeReferenceInfo/associated?dynamicCodeId=${id}`)
}

export function deleteAllCode(id) {
  return del(`/DxDynamicCode/version/${id}`)
}

export function deleteCode(id) {
  return del(`/DxDynamicCode/${id}`)
}

export function getAbility(params) {
  return get(`/DxDynamicCodeScopeAbility/allContainParentsScope`, params)
}

export function getCondition(params) {
  return get(`/DxDynamicCode/referenceCodeByCondition`, params)
}