12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152 |
- import axios from '@/common/services/axios-instance'
- class AuditFindCatTreeService {
- // getParentOrgInfo() {
- // return axios({
- // url: '/api/xcoa-mobile/v1/law-institution/getList',
- // method: 'post',
- // data: { parentId: 'AUDIT_FIND_CATEGORY' },
- // }).then((res) => {
- // res.data.forEach((item) => {
- // item.isLeaf = item.leaf
- // if (item.props.orgId === null) {
- // item.props = { ORG_ID: null, BELONGED_ORG_ID: -1 }
- // } else {
- // item.props = { ORG_ID: item.props.orgId, BELONGED_ORG_ID: -1 }
- // }
- // })
- // return res
- // })
- // }
- // 业务类型分类树
- getCategoryTree(parentId) {
- // url: `api/xcoa-mobile/v1/iam-tree/findTreeNodeById/${params.configId}/${parentId}`,
- return axios({
- url: `api/xcoa-mobile/v1/audit-report-find/find-audit-tree?parentId=` + parentId,
- method: 'post',
- }).then((res) => {
- res.data.forEach((item) => {
- item.isLeaf = item.leaf
- // if (item.props.orgId === null) {
- item.props = {}
- // } else {
- // item.props = { ORG_ID: Number(item.props.orgId), BELONGED_ORG_ID: -1 }
- // }
- })
- return res
- })
- }
- // 拖拽功能
- dragNode(params) {
- return axios({
- url: `api/xcoa-mobile/v1/iam-tree/moveTreeNode/${params.configId}/${params.id}/${params.targetId}/${params.position}`,
- method: 'post',
- data: null,
- }).then((res) => {
- res.data.forEach((item) => (item.isLeaf = item.leaf))
- return res
- })
- }
- }
- export default new AuditFindCatTreeService()
|