提交模型设计代码
This commit is contained in:
@@ -9,6 +9,7 @@
|
|||||||
"preview": "vite preview"
|
"preview": "vite preview"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
"@ant-design/colors": "^7.0.2",
|
||||||
"@element-plus/icons-vue": "^2.3.1",
|
"@element-plus/icons-vue": "^2.3.1",
|
||||||
"@fortawesome/fontawesome-free": "^6.5.1",
|
"@fortawesome/fontawesome-free": "^6.5.1",
|
||||||
"@vueuse/core": "^10.7.0",
|
"@vueuse/core": "^10.7.0",
|
||||||
@@ -31,6 +32,7 @@
|
|||||||
"file-saver": "^2.0.5",
|
"file-saver": "^2.0.5",
|
||||||
"html2canvas": "^1.4.1",
|
"html2canvas": "^1.4.1",
|
||||||
"jquery": "^3.7.1",
|
"jquery": "^3.7.1",
|
||||||
|
"js-pinyin": "^0.2.5",
|
||||||
"less": "^4.2.0",
|
"less": "^4.2.0",
|
||||||
"lodash-es": "^4.17.21",
|
"lodash-es": "^4.17.21",
|
||||||
"luckyexcel": "^1.0.1",
|
"luckyexcel": "^1.0.1",
|
||||||
|
|||||||
18
pnpm-lock.yaml
generated
18
pnpm-lock.yaml
generated
@@ -8,6 +8,9 @@ importers:
|
|||||||
|
|
||||||
.:
|
.:
|
||||||
dependencies:
|
dependencies:
|
||||||
|
'@ant-design/colors':
|
||||||
|
specifier: ^7.0.2
|
||||||
|
version: 7.0.2
|
||||||
'@element-plus/icons-vue':
|
'@element-plus/icons-vue':
|
||||||
specifier: ^2.3.1
|
specifier: ^2.3.1
|
||||||
version: 2.3.1(vue@3.4.26(typescript@5.4.5))
|
version: 2.3.1(vue@3.4.26(typescript@5.4.5))
|
||||||
@@ -74,6 +77,9 @@ importers:
|
|||||||
jquery:
|
jquery:
|
||||||
specifier: ^3.7.1
|
specifier: ^3.7.1
|
||||||
version: 3.7.1
|
version: 3.7.1
|
||||||
|
js-pinyin:
|
||||||
|
specifier: ^0.2.5
|
||||||
|
version: 0.2.5
|
||||||
less:
|
less:
|
||||||
specifier: ^4.2.0
|
specifier: ^4.2.0
|
||||||
version: 4.2.0
|
version: 4.2.0
|
||||||
@@ -181,6 +187,9 @@ packages:
|
|||||||
resolution: {integrity: sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==, tarball: https://registry.npmmirror.com/@ampproject/remapping/-/remapping-2.3.0.tgz}
|
resolution: {integrity: sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==, tarball: https://registry.npmmirror.com/@ampproject/remapping/-/remapping-2.3.0.tgz}
|
||||||
engines: {node: '>=6.0.0'}
|
engines: {node: '>=6.0.0'}
|
||||||
|
|
||||||
|
'@ant-design/colors@7.0.2':
|
||||||
|
resolution: {integrity: sha512-7KJkhTiPiLHSu+LmMJnehfJ6242OCxSlR3xHVBecYxnMW8MS/878NXct1GqYARyL59fyeFdKRxXTfvR9SnDgJg==, tarball: https://registry.npmmirror.com/@ant-design/colors/-/colors-7.0.2.tgz}
|
||||||
|
|
||||||
'@babel/code-frame@7.24.2':
|
'@babel/code-frame@7.24.2':
|
||||||
resolution: {integrity: sha512-y5+tLQyV8pg3fsiln67BVLD1P13Eg4lh5RW9mF0zUuvLrv9uIQ4MCL+CRT+FTsBlBjcIan6PGsLcBN0m3ClUyQ==, tarball: https://registry.npmmirror.com/@babel/code-frame/-/code-frame-7.24.2.tgz}
|
resolution: {integrity: sha512-y5+tLQyV8pg3fsiln67BVLD1P13Eg4lh5RW9mF0zUuvLrv9uIQ4MCL+CRT+FTsBlBjcIan6PGsLcBN0m3ClUyQ==, tarball: https://registry.npmmirror.com/@babel/code-frame/-/code-frame-7.24.2.tgz}
|
||||||
engines: {node: '>=6.9.0'}
|
engines: {node: '>=6.9.0'}
|
||||||
@@ -1513,6 +1522,9 @@ packages:
|
|||||||
jquery@3.7.1:
|
jquery@3.7.1:
|
||||||
resolution: {integrity: sha512-m4avr8yL8kmFN8psrbFFFmB/If14iN5o9nw/NgnnM+kybDJpRsAynV2BsfpTYrTRysYUdADVD7CkUUizgkpLfg==, tarball: https://registry.npmmirror.com/jquery/-/jquery-3.7.1.tgz}
|
resolution: {integrity: sha512-m4avr8yL8kmFN8psrbFFFmB/If14iN5o9nw/NgnnM+kybDJpRsAynV2BsfpTYrTRysYUdADVD7CkUUizgkpLfg==, tarball: https://registry.npmmirror.com/jquery/-/jquery-3.7.1.tgz}
|
||||||
|
|
||||||
|
js-pinyin@0.2.5:
|
||||||
|
resolution: {integrity: sha512-XuqAZ9fctWCzKx/ALgsDRtfd/xwaC/IyAwkDkW8jTXhlVNRuj+lG2tKEOWraCHLgaOSPkSFFWXB3qjfNTaMU6A==, tarball: https://registry.npmmirror.com/js-pinyin/-/js-pinyin-0.2.5.tgz}
|
||||||
|
|
||||||
js-tokens@4.0.0:
|
js-tokens@4.0.0:
|
||||||
resolution: {integrity: sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==, tarball: https://registry.npmmirror.com/js-tokens/-/js-tokens-4.0.0.tgz}
|
resolution: {integrity: sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==, tarball: https://registry.npmmirror.com/js-tokens/-/js-tokens-4.0.0.tgz}
|
||||||
|
|
||||||
@@ -2240,6 +2252,10 @@ snapshots:
|
|||||||
'@jridgewell/gen-mapping': 0.3.5
|
'@jridgewell/gen-mapping': 0.3.5
|
||||||
'@jridgewell/trace-mapping': 0.3.25
|
'@jridgewell/trace-mapping': 0.3.25
|
||||||
|
|
||||||
|
'@ant-design/colors@7.0.2':
|
||||||
|
dependencies:
|
||||||
|
'@ctrl/tinycolor': 3.6.1
|
||||||
|
|
||||||
'@babel/code-frame@7.24.2':
|
'@babel/code-frame@7.24.2':
|
||||||
dependencies:
|
dependencies:
|
||||||
'@babel/highlight': 7.24.5
|
'@babel/highlight': 7.24.5
|
||||||
@@ -3744,6 +3760,8 @@ snapshots:
|
|||||||
|
|
||||||
jquery@3.7.1: {}
|
jquery@3.7.1: {}
|
||||||
|
|
||||||
|
js-pinyin@0.2.5: {}
|
||||||
|
|
||||||
js-tokens@4.0.0: {}
|
js-tokens@4.0.0: {}
|
||||||
|
|
||||||
jsesc@2.5.2: {}
|
jsesc@2.5.2: {}
|
||||||
|
|||||||
45
src/api/dbs/dbsApi.js
Normal file
45
src/api/dbs/dbsApi.js
Normal file
@@ -0,0 +1,45 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/tenapp/dbs/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 多租户
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取数据源分页
|
||||||
|
dbsPage(data) {
|
||||||
|
return request('storage/page', data, 'get')
|
||||||
|
},
|
||||||
|
// 提交表单 edit为true时为编辑,默认为新增
|
||||||
|
submitForm(data, edit = false) {
|
||||||
|
return request(edit ? 'storage/edit' : 'storage/add', data)
|
||||||
|
},
|
||||||
|
// 删除数据源
|
||||||
|
dbsDelete(data) {
|
||||||
|
return request('storage/delete', data)
|
||||||
|
},
|
||||||
|
// 获取数据源详情
|
||||||
|
dbsDetail(data) {
|
||||||
|
return request('storage/detail', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取数据库中所有表
|
||||||
|
dbsTables(data) {
|
||||||
|
return request('tables', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取数据库表中所有字段
|
||||||
|
dbsTableColumns(data) {
|
||||||
|
return request('tableColumns', data, 'get')
|
||||||
|
}
|
||||||
|
}
|
||||||
89
src/api/flw/modelApi.js
Normal file
89
src/api/flw/modelApi.js
Normal file
@@ -0,0 +1,89 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/flwapp/flw/model/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 模型
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取模型分页
|
||||||
|
modelPage(data) {
|
||||||
|
return request('page', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取所有模型列表
|
||||||
|
modelAllList(data) {
|
||||||
|
return request('allList', data, 'get')
|
||||||
|
},
|
||||||
|
// 提交表单 edit为true时为编辑,默认为新增
|
||||||
|
submitForm(data, edit = false) {
|
||||||
|
return request(edit ? 'edit' : 'add', data)
|
||||||
|
},
|
||||||
|
// 删除模型
|
||||||
|
modelDelete(data) {
|
||||||
|
return request('delete', data)
|
||||||
|
},
|
||||||
|
// 部署模型
|
||||||
|
modelDeploy(data) {
|
||||||
|
return request('deploy', data)
|
||||||
|
},
|
||||||
|
// 获取模型详情
|
||||||
|
modelDetail(data) {
|
||||||
|
return request('detail', data, 'get')
|
||||||
|
},
|
||||||
|
// 停用模型
|
||||||
|
modelDisable(data) {
|
||||||
|
return request('disableModel', data)
|
||||||
|
},
|
||||||
|
// 启用模型
|
||||||
|
modelEnable(data) {
|
||||||
|
return request('enableModel', data)
|
||||||
|
},
|
||||||
|
// 模型降版
|
||||||
|
modelDownVersion(data) {
|
||||||
|
return request('downVersion', data)
|
||||||
|
},
|
||||||
|
// 获取组织树选择器
|
||||||
|
modelOrgTreeSelector(data) {
|
||||||
|
return request('orgTreeSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取组织列表选择器
|
||||||
|
modelOrgListSelector(data) {
|
||||||
|
return request('orgListSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取职位选择器
|
||||||
|
modelPositionSelector(data) {
|
||||||
|
return request('positionSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取角色选择器
|
||||||
|
modelRoleSelector(data) {
|
||||||
|
return request('roleSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取用户选择器
|
||||||
|
modelUserSelector(data) {
|
||||||
|
return request('userSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取执行监听器选择器
|
||||||
|
modelExecutionListenerSelector(data) {
|
||||||
|
return request('executionListenerSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取自定义事件执行监听器选择器
|
||||||
|
modelExecutionListenerSelectorForCustomEvent(data) {
|
||||||
|
return request('executionListenerSelectorForCustomEvent', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取任务监听器选择器
|
||||||
|
modelTaskListenerSelector(data) {
|
||||||
|
return request('taskListenerSelector', data, 'get')
|
||||||
|
}
|
||||||
|
}
|
||||||
93
src/api/flw/processApi.js
Normal file
93
src/api/flw/processApi.js
Normal file
@@ -0,0 +1,93 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/flwapp/flw/process/monitor/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 流程
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取所有流程分页
|
||||||
|
processMonitorPage(data) {
|
||||||
|
return request('monitorPage', data, 'get')
|
||||||
|
},
|
||||||
|
// 删除流程
|
||||||
|
processDelete(data) {
|
||||||
|
return request('delete', data)
|
||||||
|
},
|
||||||
|
// 终止流程
|
||||||
|
processEnd(data) {
|
||||||
|
return request('end', data)
|
||||||
|
},
|
||||||
|
// 撤回流程
|
||||||
|
processRevoke(data) {
|
||||||
|
return request('revoke', data)
|
||||||
|
},
|
||||||
|
// 挂起流程
|
||||||
|
processSuspend(data) {
|
||||||
|
return request('suspend', data)
|
||||||
|
},
|
||||||
|
// 激活流程
|
||||||
|
processActive(data) {
|
||||||
|
return request('active', data)
|
||||||
|
},
|
||||||
|
// 转办流程
|
||||||
|
processTurn(data) {
|
||||||
|
return request('turn', data)
|
||||||
|
},
|
||||||
|
// 跳转流程
|
||||||
|
processJump(data) {
|
||||||
|
return request('jump', data)
|
||||||
|
},
|
||||||
|
// 复活流程
|
||||||
|
processRestart(data) {
|
||||||
|
return request('restart', data)
|
||||||
|
},
|
||||||
|
// 迁移流程
|
||||||
|
processMigrate(data) {
|
||||||
|
return request('migrate', data)
|
||||||
|
},
|
||||||
|
// 获取流程变量分页
|
||||||
|
processVariablePage(data) {
|
||||||
|
return request('variablePage', data, 'get')
|
||||||
|
},
|
||||||
|
// 批量编辑流程变量
|
||||||
|
processVariableUpdateBatch(data) {
|
||||||
|
return request('variableUpdateBatch', data)
|
||||||
|
},
|
||||||
|
// 获取流程详情
|
||||||
|
processDetail(data) {
|
||||||
|
return request('detail', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取可跳转节点列表
|
||||||
|
processGetCanJumpNodeInfoList(data) {
|
||||||
|
return request('getCanJumpNodeInfoList', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取可复活到节点列表
|
||||||
|
processGetCanRestartNodeInfoList(data) {
|
||||||
|
return request('getCanRestartNodeInfoList', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取可迁移到节点列表
|
||||||
|
processGetCanMigrateNodeInfoList(data) {
|
||||||
|
return request('getCanMigrateNodeInfoList', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取组织树选择器
|
||||||
|
processOrgTreeSelector(data) {
|
||||||
|
return request('orgTreeSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取用户选择器
|
||||||
|
processUserSelector(data) {
|
||||||
|
return request('userSelector', data, 'get')
|
||||||
|
}
|
||||||
|
}
|
||||||
73
src/api/flw/processMyApi.js
Normal file
73
src/api/flw/processMyApi.js
Normal file
@@ -0,0 +1,73 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/flwapp/flw/process/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 我的流程
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取我可以发起的流程模型列表
|
||||||
|
processMyModelList(data) {
|
||||||
|
return request('myModelList', data, 'get')
|
||||||
|
},
|
||||||
|
// 保存草稿
|
||||||
|
processSaveDraft(data) {
|
||||||
|
return request('saveDraft', data)
|
||||||
|
},
|
||||||
|
// 发起流程
|
||||||
|
processStart(data) {
|
||||||
|
return request('start', data)
|
||||||
|
},
|
||||||
|
// 获取我的草稿分页
|
||||||
|
processMyDraftPage(data) {
|
||||||
|
return request('myDraftPage', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取草稿详情
|
||||||
|
processDraftDetail(data) {
|
||||||
|
return request('draftDetail', data, 'get')
|
||||||
|
},
|
||||||
|
// 删除草稿
|
||||||
|
processDeleteDraft(data) {
|
||||||
|
return request('deleteDraft', data)
|
||||||
|
},
|
||||||
|
// 获取我发起的流程分页
|
||||||
|
processMyPage(data) {
|
||||||
|
return request('myPage', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取我的待阅流程分页
|
||||||
|
processMyCopyUnreadPage(data) {
|
||||||
|
return request('myCopyUnreadPage', data, 'get')
|
||||||
|
},
|
||||||
|
// 设置待阅流程为已阅
|
||||||
|
processReadMyCopyProcess(data) {
|
||||||
|
return request('readMyCopyProcess', data)
|
||||||
|
},
|
||||||
|
// 获取我的已阅流程分页
|
||||||
|
processMyCopyHasReadPage(data) {
|
||||||
|
return request('myCopyHasReadPage', data, 'get')
|
||||||
|
},
|
||||||
|
// 删除我的已阅流程
|
||||||
|
processDeleteMyHasReadProcess(data) {
|
||||||
|
return request('deleteMyHasReadProcess', data)
|
||||||
|
},
|
||||||
|
// 撤回流程
|
||||||
|
processRevoke(data) {
|
||||||
|
return request('revoke', data)
|
||||||
|
},
|
||||||
|
// 获取流程详情
|
||||||
|
processDetail(data) {
|
||||||
|
return request('detail', data, 'get')
|
||||||
|
}
|
||||||
|
}
|
||||||
81
src/api/flw/taskApi.js
Normal file
81
src/api/flw/taskApi.js
Normal file
@@ -0,0 +1,81 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/flwapp/flw/task/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 待办任务
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取待办任务分页
|
||||||
|
taskTodoPage(data) {
|
||||||
|
return request('todoPage', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取已办任务分页
|
||||||
|
taskDonePage(data) {
|
||||||
|
return request('donePage', data, 'get')
|
||||||
|
},
|
||||||
|
// 调整申请
|
||||||
|
taskAdjust(data) {
|
||||||
|
return request('adjust', data)
|
||||||
|
},
|
||||||
|
// 审批保存
|
||||||
|
taskSave(data) {
|
||||||
|
return request('save', data)
|
||||||
|
},
|
||||||
|
// 审批同意
|
||||||
|
taskPass(data) {
|
||||||
|
return request('pass', data)
|
||||||
|
},
|
||||||
|
// 审批拒绝
|
||||||
|
taskReject(data) {
|
||||||
|
return request('reject', data)
|
||||||
|
},
|
||||||
|
// 审批退回
|
||||||
|
taskBack(data) {
|
||||||
|
return request('back', data)
|
||||||
|
},
|
||||||
|
// 任务转办
|
||||||
|
taskTurn(data) {
|
||||||
|
return request('turn', data)
|
||||||
|
},
|
||||||
|
// 审批跳转
|
||||||
|
taskJump(data) {
|
||||||
|
return request('jump', data)
|
||||||
|
},
|
||||||
|
// 任务加签
|
||||||
|
taskAddSign(data) {
|
||||||
|
return request('addSign', data)
|
||||||
|
},
|
||||||
|
// 任务详情
|
||||||
|
taskDetail(data) {
|
||||||
|
return request('detail', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取可驳回节点列表
|
||||||
|
taskGetCanBackNodeInfoList(data) {
|
||||||
|
return request('getCanBackNodeInfoList', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取可跳转节点列表
|
||||||
|
taskGetCanJumpNodeInfoList(data) {
|
||||||
|
return request('getCanJumpNodeInfoList', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取组织树选择器
|
||||||
|
taskOrgTreeSelector(data) {
|
||||||
|
return request('orgTreeSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取用户选择器
|
||||||
|
taskUserSelector(data) {
|
||||||
|
return request('userSelector', data, 'get')
|
||||||
|
}
|
||||||
|
}
|
||||||
41
src/api/flw/templatePrintApi.js
Normal file
41
src/api/flw/templatePrintApi.js
Normal file
@@ -0,0 +1,41 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/flwapp/flw/templatePrint/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 打印模板
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取打印模板分页
|
||||||
|
templatePrintPage(data) {
|
||||||
|
return request('page', data, 'get')
|
||||||
|
},
|
||||||
|
// 提交表单 edit为true时为编辑,默认为新增
|
||||||
|
templatePrintSubmitForm(data, edit = false) {
|
||||||
|
return request(edit ? 'edit' : 'add', data)
|
||||||
|
},
|
||||||
|
// 删除打印模板
|
||||||
|
templatePrintDelete(data) {
|
||||||
|
return request('delete', data)
|
||||||
|
},
|
||||||
|
// 获取打印模板详情
|
||||||
|
templatePrintDetail(data) {
|
||||||
|
return request('detail', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取打印模板选择列表
|
||||||
|
templateFlwTemplatePrintSelector(data) {
|
||||||
|
return request('flwTemplatePrintSelector', data, 'get')
|
||||||
|
}
|
||||||
|
}
|
||||||
41
src/api/flw/templateSnApi.js
Normal file
41
src/api/flw/templateSnApi.js
Normal file
@@ -0,0 +1,41 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/flwapp/flw/templateSn/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 流水号
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取流水号模板分页
|
||||||
|
templateSnPage(data) {
|
||||||
|
return request('page', data, 'get')
|
||||||
|
},
|
||||||
|
// 提交表单 edit为true时为编辑,默认为新增
|
||||||
|
templateSnSubmitForm(data, edit = false) {
|
||||||
|
return request(edit ? 'edit' : 'add', data)
|
||||||
|
},
|
||||||
|
// 删除流水号模板
|
||||||
|
templateSnDelete(data) {
|
||||||
|
return request('delete', data)
|
||||||
|
},
|
||||||
|
// 获取流水号模板详情
|
||||||
|
templateSnDetail(data) {
|
||||||
|
return request('detail', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取序列号模板选择列表
|
||||||
|
templateFlwTemplateSnSelector(data) {
|
||||||
|
return request('flwTemplateSnSelector', data, 'get')
|
||||||
|
}
|
||||||
|
}
|
||||||
53
src/api/sys/indexApi.js
Normal file
53
src/api/sys/indexApi.js
Normal file
@@ -0,0 +1,53 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/webapp/sys/index/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 系统首页控制器
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 添加当前用户日程
|
||||||
|
indexScheduleAdd(data) {
|
||||||
|
return request('schedule/add', data)
|
||||||
|
},
|
||||||
|
// 删除日程
|
||||||
|
indexScheduleDeleteSchedule(data) {
|
||||||
|
return request('schedule/deleteSchedule', data)
|
||||||
|
},
|
||||||
|
// 获取当前用户日程列表
|
||||||
|
indexScheduleList(data) {
|
||||||
|
return request('schedule/list', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取当前用户站内信列表
|
||||||
|
indexMessageList(data) {
|
||||||
|
return request('message/list', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取站内信详情
|
||||||
|
indexMessageDetail(data) {
|
||||||
|
return request('message/detail', data, 'get')
|
||||||
|
},
|
||||||
|
//站内信全部标记已读
|
||||||
|
indexMessageAllMarkRead(data) {
|
||||||
|
return request('message/allMessageMarkRead', data)
|
||||||
|
},
|
||||||
|
// 获取当前用户访问日志列表
|
||||||
|
indexVisLogList(data) {
|
||||||
|
return request('visLog/list', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取当前用户操作日志列表
|
||||||
|
indexOpLogList(data) {
|
||||||
|
return request('opLog/list', data, 'get')
|
||||||
|
}
|
||||||
|
}
|
||||||
53
src/api/sys/orgApi.js
Normal file
53
src/api/sys/orgApi.js
Normal file
@@ -0,0 +1,53 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/webapp/sys/org/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 机构
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取组织分页
|
||||||
|
orgPage(data) {
|
||||||
|
return request('page', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取组织列表
|
||||||
|
orgList(data) {
|
||||||
|
return request('list', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取组织树
|
||||||
|
orgTree(data) {
|
||||||
|
return request('tree', data, 'get')
|
||||||
|
},
|
||||||
|
// 提交表单 edit为true时为编辑,默认为新增
|
||||||
|
submitForm(data, edit = false) {
|
||||||
|
return request(edit ? 'edit' : 'add', data)
|
||||||
|
},
|
||||||
|
// 删除组织
|
||||||
|
orgDelete(data) {
|
||||||
|
return request('delete', data)
|
||||||
|
},
|
||||||
|
// 获取组织详情
|
||||||
|
orgDetail(data) {
|
||||||
|
return request('detail', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取组织树选择器
|
||||||
|
orgOrgTreeSelector(data) {
|
||||||
|
return request('orgTreeSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取用户选择器
|
||||||
|
orgUserSelector(data) {
|
||||||
|
return request('userSelector', data, 'get')
|
||||||
|
}
|
||||||
|
}
|
||||||
49
src/api/sys/positionApi.js
Normal file
49
src/api/sys/positionApi.js
Normal file
@@ -0,0 +1,49 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/webapp/sys/position/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 职位
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取职位分页
|
||||||
|
positionPage(data) {
|
||||||
|
return request('page', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取职位列表
|
||||||
|
positionList(data) {
|
||||||
|
return request('list', data, 'get')
|
||||||
|
},
|
||||||
|
// 提交表单 edit为true时为编辑,默认为新增
|
||||||
|
submitForm(data, edit = false) {
|
||||||
|
return request(edit ? 'edit' : 'add', data)
|
||||||
|
},
|
||||||
|
// 删除职位
|
||||||
|
positionDelete(data) {
|
||||||
|
return request('delete', data)
|
||||||
|
},
|
||||||
|
// 获取职位详情
|
||||||
|
positionDetail(data) {
|
||||||
|
return request('detail', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取组织树选择器
|
||||||
|
positionOrgTreeSelector(data) {
|
||||||
|
return request('orgTreeSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取职位选择器
|
||||||
|
positionPositionSelector(data) {
|
||||||
|
return request('positionSelector', data, 'get')
|
||||||
|
}
|
||||||
|
}
|
||||||
37
src/api/sys/resource/buttonApi.js
Normal file
37
src/api/sys/resource/buttonApi.js
Normal file
@@ -0,0 +1,37 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/webapp/sys/button/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 按钮
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取按钮分页
|
||||||
|
buttonPage(data) {
|
||||||
|
return request('page', data, 'get')
|
||||||
|
},
|
||||||
|
// 提交表单 edit为true时为编辑,默认为新增
|
||||||
|
submitForm(data, edit = false) {
|
||||||
|
return request(edit ? 'edit' : 'add', data)
|
||||||
|
},
|
||||||
|
// 删除按钮
|
||||||
|
buttonDelete(data) {
|
||||||
|
return request('delete', data)
|
||||||
|
},
|
||||||
|
// 获取按钮详情
|
||||||
|
buttonDetail(data) {
|
||||||
|
return request('detail', data, 'get')
|
||||||
|
}
|
||||||
|
}
|
||||||
45
src/api/sys/resource/fieldApi.js
Normal file
45
src/api/sys/resource/fieldApi.js
Normal file
@@ -0,0 +1,45 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/webapp/sys/field/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 字段
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取字段分页
|
||||||
|
fieldPage(data) {
|
||||||
|
return request('page', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取字段树
|
||||||
|
fieldTree(data) {
|
||||||
|
return request('tree', data, 'get')
|
||||||
|
},
|
||||||
|
// 提交表单 edit为true时为编辑,默认为新增
|
||||||
|
submitForm(data, edit = false) {
|
||||||
|
return request(edit ? 'edit' : 'add', data)
|
||||||
|
},
|
||||||
|
// 删除字段
|
||||||
|
fieldDelete(data) {
|
||||||
|
return request('delete', data)
|
||||||
|
},
|
||||||
|
// 获取字段详情
|
||||||
|
fieldDetail(data) {
|
||||||
|
return request('detail', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取菜单树选择器
|
||||||
|
fieldMenuTreeSelector(data) {
|
||||||
|
return request('MenuTreeSelector', data, 'get')
|
||||||
|
}
|
||||||
|
}
|
||||||
49
src/api/sys/resource/menuApi.js
Normal file
49
src/api/sys/resource/menuApi.js
Normal file
@@ -0,0 +1,49 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/webapp/sys/menu/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 菜单
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取菜单树
|
||||||
|
menuTree(data) {
|
||||||
|
return request('tree', data, 'get')
|
||||||
|
},
|
||||||
|
// 提交表单 edit为true时为编辑,默认为新增
|
||||||
|
submitForm(data, edit = false) {
|
||||||
|
return request(edit ? 'edit' : 'add', data)
|
||||||
|
},
|
||||||
|
// 更改菜单所属模块
|
||||||
|
menuChangeModule(data) {
|
||||||
|
return request('changeModule', data)
|
||||||
|
},
|
||||||
|
// 删除菜单
|
||||||
|
menuDelete(data) {
|
||||||
|
return request('delete', data)
|
||||||
|
},
|
||||||
|
// 获取菜单详情
|
||||||
|
menuDetail(data) {
|
||||||
|
return request('detail', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取模块选择器
|
||||||
|
menuModuleSelector(data) {
|
||||||
|
return request('moduleSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取菜单树选择器
|
||||||
|
menuTreeSelector(data) {
|
||||||
|
return request('menuTreeSelector', data, 'get')
|
||||||
|
}
|
||||||
|
}
|
||||||
37
src/api/sys/resource/moduleApi.js
Normal file
37
src/api/sys/resource/moduleApi.js
Normal file
@@ -0,0 +1,37 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/webapp/sys/module/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 模块
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取模块分页
|
||||||
|
modulePage(data) {
|
||||||
|
return request('page', data, 'get')
|
||||||
|
},
|
||||||
|
// 提交表单 edit为true时为编辑,默认为新增
|
||||||
|
submitForm(data, edit = false) {
|
||||||
|
return request(edit ? 'edit' : 'add', data)
|
||||||
|
},
|
||||||
|
// 删除模块
|
||||||
|
moduleDelete(data) {
|
||||||
|
return request('delete', data)
|
||||||
|
},
|
||||||
|
// 获取模块详情
|
||||||
|
moduleDetail(data) {
|
||||||
|
return request('detail', data, 'get')
|
||||||
|
}
|
||||||
|
}
|
||||||
97
src/api/sys/roleApi.js
Normal file
97
src/api/sys/roleApi.js
Normal file
@@ -0,0 +1,97 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/webapp/sys/role/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 角色
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取角色分页
|
||||||
|
rolePage(data) {
|
||||||
|
return request('page', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取角色列表
|
||||||
|
roleList(data) {
|
||||||
|
return request('list', data, 'get')
|
||||||
|
},
|
||||||
|
// 提交表单 edit为true时为编辑,默认为新增
|
||||||
|
submitForm(data, edit = false) {
|
||||||
|
return request(edit ? 'edit' : 'add', data)
|
||||||
|
},
|
||||||
|
// 删除角色
|
||||||
|
roleDelete(data) {
|
||||||
|
return request('delete', data)
|
||||||
|
},
|
||||||
|
// 获取角色详情
|
||||||
|
roleDetail(data) {
|
||||||
|
return request('detail', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取角色拥有资源
|
||||||
|
roleOwnResource(data) {
|
||||||
|
return request('ownResource', data, 'get')
|
||||||
|
},
|
||||||
|
// 给角色授权资源
|
||||||
|
roleGrantResource(data) {
|
||||||
|
return request('grantResource', data)
|
||||||
|
},
|
||||||
|
// 获取角色拥有移动端菜单
|
||||||
|
roleOwnMobileMenu(data) {
|
||||||
|
return request('ownMobileMenu', data, 'get')
|
||||||
|
},
|
||||||
|
// 给角色授权移动端菜单
|
||||||
|
roleGrantMobileMenu(data) {
|
||||||
|
return request('grantMobileMenu', data)
|
||||||
|
},
|
||||||
|
// 获取角色拥有权限
|
||||||
|
roleOwnPermission(data) {
|
||||||
|
return request('ownPermission', data, 'get')
|
||||||
|
},
|
||||||
|
// 给角色授权权限
|
||||||
|
roleGrantPermission(data) {
|
||||||
|
return request('grantPermission', data)
|
||||||
|
},
|
||||||
|
// 获取角色下的用户
|
||||||
|
roleOwnUser(data) {
|
||||||
|
return request('ownUser', data, 'get')
|
||||||
|
},
|
||||||
|
// 给角色授权用户
|
||||||
|
roleGrantUser(data) {
|
||||||
|
return request('grantUser', data)
|
||||||
|
},
|
||||||
|
// 获取机构树
|
||||||
|
roleOrgTreeSelector(data) {
|
||||||
|
return request('orgTreeSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取资源授权树
|
||||||
|
roleResourceTreeSelector(data) {
|
||||||
|
return request('resourceTreeSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取移动端菜单授权树
|
||||||
|
roleMobileMenuTreeSelector(data) {
|
||||||
|
return request('mobileMenuTreeSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取权限授权树
|
||||||
|
rolePermissionTreeSelector(data) {
|
||||||
|
return request('permissionTreeSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取角色选择器
|
||||||
|
roleRoleSelector(data) {
|
||||||
|
return request('roleSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取用户选择器
|
||||||
|
roleUserSelector(data) {
|
||||||
|
return request('userSelector', data, 'get')
|
||||||
|
}
|
||||||
|
}
|
||||||
111
src/api/sys/userApi.js
Normal file
111
src/api/sys/userApi.js
Normal file
@@ -0,0 +1,111 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/webapp/sys/user/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 用户接口api
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取用户分页
|
||||||
|
userPage(data) {
|
||||||
|
return request('page', data, 'get')
|
||||||
|
},
|
||||||
|
// 提交表单 edit为true时为编辑,默认为新增
|
||||||
|
submitForm(data, edit = false) {
|
||||||
|
return request(edit ? 'edit' : 'add', data)
|
||||||
|
},
|
||||||
|
// 删除用户
|
||||||
|
userDelete(data) {
|
||||||
|
return request('delete', data)
|
||||||
|
},
|
||||||
|
// 获取用户详情
|
||||||
|
userDetail(data) {
|
||||||
|
return request('detail', data, 'get')
|
||||||
|
},
|
||||||
|
// 禁用用户
|
||||||
|
userDisableUser(data) {
|
||||||
|
return request('disableUser', data)
|
||||||
|
},
|
||||||
|
// 启用用户
|
||||||
|
userEnableUser(data) {
|
||||||
|
return request('enableUser', data)
|
||||||
|
},
|
||||||
|
// 重置用户密码
|
||||||
|
userResetPassword(data) {
|
||||||
|
return request('resetPassword', data)
|
||||||
|
},
|
||||||
|
// 获取组织选择器
|
||||||
|
userOrgTreeSelector(data) {
|
||||||
|
return request('orgTreeSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取职位选择器
|
||||||
|
userPositionSelector(data) {
|
||||||
|
return request('positionSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取角色选择器
|
||||||
|
userRoleSelector(data) {
|
||||||
|
return request('roleSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取用户选择器
|
||||||
|
userSelector(data) {
|
||||||
|
return request('userSelector', data, 'get')
|
||||||
|
},
|
||||||
|
// 用户拥有角色
|
||||||
|
userOwnRole(data) {
|
||||||
|
return request('ownRole', data, 'get')
|
||||||
|
},
|
||||||
|
// 给用户授权角色
|
||||||
|
grantRole(data) {
|
||||||
|
return request('grantRole', data)
|
||||||
|
},
|
||||||
|
// 获取用户拥有资源
|
||||||
|
userOwnResource(data) {
|
||||||
|
return request('ownResource', data, 'get')
|
||||||
|
},
|
||||||
|
// 给用户授权资源
|
||||||
|
userGrantResource(data) {
|
||||||
|
return request('grantResource', data)
|
||||||
|
},
|
||||||
|
// 获取用户拥有权限
|
||||||
|
userOwnPermission(data) {
|
||||||
|
return request('ownPermission', data, 'get')
|
||||||
|
},
|
||||||
|
// 给用户授权权限
|
||||||
|
userGrantPermission(data) {
|
||||||
|
return request('grantPermission', data)
|
||||||
|
},
|
||||||
|
// 下载用户导入模板
|
||||||
|
userDownloadImportUserTemplate(data) {
|
||||||
|
return request('downloadImportUserTemplate', data, 'get', {
|
||||||
|
responseType: 'blob'
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// 用户导入
|
||||||
|
userImport(data) {
|
||||||
|
return request('import', data)
|
||||||
|
},
|
||||||
|
// 用户导出
|
||||||
|
userExport(data) {
|
||||||
|
return request('export', data, 'get', {
|
||||||
|
responseType: 'blob'
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// 导出用户个人信息
|
||||||
|
userExportUserInfo(data) {
|
||||||
|
return request('exportUserInfo', data, 'get', {
|
||||||
|
responseType: 'blob'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
101
src/api/sys/userCenterApi.js
Normal file
101
src/api/sys/userCenterApi.js
Normal file
@@ -0,0 +1,101 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { baseRequest } from '@/utils/request'
|
||||||
|
|
||||||
|
const request = (url, ...arg) => baseRequest(`/api/webapp/sys/userCenter/${url}`, ...arg)
|
||||||
|
/**
|
||||||
|
* 用户个人控制器
|
||||||
|
*
|
||||||
|
* @author yubaoshan
|
||||||
|
* @date 2022-09-22 22:33:20
|
||||||
|
*/
|
||||||
|
export default {
|
||||||
|
// 获取图片验证码
|
||||||
|
userGetPicCaptcha(data) {
|
||||||
|
return request('getPicCaptcha', data, 'get')
|
||||||
|
},
|
||||||
|
// 找回密码获取手机验证码
|
||||||
|
userFindPasswordGetPhoneValidCode(data) {
|
||||||
|
return request('findPasswordGetPhoneValidCode', data, 'get')
|
||||||
|
},
|
||||||
|
// 找回密码获取邮箱验证码
|
||||||
|
userFindPasswordGetEmailValidCode(data) {
|
||||||
|
return request('findPasswordGetEmailValidCode', data, 'get')
|
||||||
|
},
|
||||||
|
// 通过手机号找回用户密码
|
||||||
|
userFindPasswordByPhone(data) {
|
||||||
|
return request('findPasswordByPhone', data)
|
||||||
|
},
|
||||||
|
// 通过邮箱找回用户密码
|
||||||
|
userFindPasswordByEmail(data) {
|
||||||
|
return request('findPasswordByEmail', data)
|
||||||
|
},
|
||||||
|
// 修改用户密码
|
||||||
|
userUpdatePassword(data) {
|
||||||
|
return request('updatePassword', data)
|
||||||
|
},
|
||||||
|
// 修改用户头像
|
||||||
|
userUpdateAvatar(data) {
|
||||||
|
return request('updateAvatar', data)
|
||||||
|
},
|
||||||
|
// 修改用户签名图片
|
||||||
|
userUpdateSignature(data) {
|
||||||
|
return request('updateSignature', data)
|
||||||
|
},
|
||||||
|
// 获取登录用户的菜单
|
||||||
|
userLoginMenu(data) {
|
||||||
|
return request('loginMenu', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取登录用户组织树
|
||||||
|
userLoginOrgTree(data) {
|
||||||
|
return request('loginOrgTree', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取登录用户的职位信息
|
||||||
|
userLoginPositionInfo(data) {
|
||||||
|
return request('loginPositionInfo', data, 'get')
|
||||||
|
},
|
||||||
|
// 编辑个人信息
|
||||||
|
userUpdateUserInfo(data) {
|
||||||
|
return request('updateUserInfo', data)
|
||||||
|
},
|
||||||
|
// 编辑个人工作台
|
||||||
|
userUpdateUserWorkbench(data) {
|
||||||
|
return request('updateUserWorkbench', data)
|
||||||
|
},
|
||||||
|
// 获取登录用户的工作台
|
||||||
|
userLoginWorkbench(data) {
|
||||||
|
return request('loginWorkbench', data, 'get')
|
||||||
|
},
|
||||||
|
// 获取登录用户的站内信分页
|
||||||
|
userLoginUnreadMessagePage(data) {
|
||||||
|
return request('loginUnreadMessagePage', data, 'get')
|
||||||
|
},
|
||||||
|
// 读取登录用户站内信详情
|
||||||
|
userLoginUnreadMessageDetail(data) {
|
||||||
|
return request('loginUnreadMessageDetail', data, 'get')
|
||||||
|
},
|
||||||
|
// 根据id集合获取组织集合
|
||||||
|
userCenterGetOrgListByIdList(data) {
|
||||||
|
return request('getOrgListByIdList', data)
|
||||||
|
},
|
||||||
|
// 根据id集合获取用户集合
|
||||||
|
userCenterGetUserListByIdList(data) {
|
||||||
|
return request('getUserListByIdList', data)
|
||||||
|
},
|
||||||
|
// 根据id集合获取职位集合
|
||||||
|
userCenterGetPositionListByIdList(data) {
|
||||||
|
return request('getPositionListByIdList', data)
|
||||||
|
},
|
||||||
|
// 根据id集合获取角色集合
|
||||||
|
userCenterGetRoleListByIdList(data) {
|
||||||
|
return request('getRoleListByIdList', data)
|
||||||
|
}
|
||||||
|
}
|
||||||
173
src/assets/icons/mobile/filled/iconfont.css
Normal file
173
src/assets/icons/mobile/filled/iconfont.css
Normal file
@@ -0,0 +1,173 @@
|
|||||||
|
@font-face {
|
||||||
|
font-family: "snowy"; /* Project id 3880534 */
|
||||||
|
src: url('iconfont.ttf?t=1675528061732') format('truetype');
|
||||||
|
}
|
||||||
|
|
||||||
|
.snowy {
|
||||||
|
font-family: "snowy" !important;
|
||||||
|
font-size: 16px;
|
||||||
|
font-style: normal;
|
||||||
|
-webkit-font-smoothing: antialiased;
|
||||||
|
-moz-osx-font-smoothing: grayscale;
|
||||||
|
}
|
||||||
|
|
||||||
|
.arrow-up-filling:before {
|
||||||
|
content: "\e688";
|
||||||
|
}
|
||||||
|
|
||||||
|
.arrow-down-filling:before {
|
||||||
|
content: "\e689";
|
||||||
|
}
|
||||||
|
|
||||||
|
.arrow-left-filling:before {
|
||||||
|
content: "\e68a";
|
||||||
|
}
|
||||||
|
|
||||||
|
.arrow-right-filling:before {
|
||||||
|
content: "\e68b";
|
||||||
|
}
|
||||||
|
|
||||||
|
.caps-unlock-filling:before {
|
||||||
|
content: "\e68c";
|
||||||
|
}
|
||||||
|
|
||||||
|
.comment-filling:before {
|
||||||
|
content: "\e68d";
|
||||||
|
}
|
||||||
|
|
||||||
|
.check-item-filling:before {
|
||||||
|
content: "\e68e";
|
||||||
|
}
|
||||||
|
|
||||||
|
.clock-filling:before {
|
||||||
|
content: "\e68f";
|
||||||
|
}
|
||||||
|
|
||||||
|
.delete-filling:before {
|
||||||
|
content: "\e690";
|
||||||
|
}
|
||||||
|
|
||||||
|
.decline-filling:before {
|
||||||
|
content: "\e691";
|
||||||
|
}
|
||||||
|
|
||||||
|
.dynamic-filling:before {
|
||||||
|
content: "\e692";
|
||||||
|
}
|
||||||
|
|
||||||
|
.intermediate-filling:before {
|
||||||
|
content: "\e693";
|
||||||
|
}
|
||||||
|
|
||||||
|
.favorite-filling:before {
|
||||||
|
content: "\e694";
|
||||||
|
}
|
||||||
|
|
||||||
|
.layout-filling:before {
|
||||||
|
content: "\e695";
|
||||||
|
}
|
||||||
|
|
||||||
|
.help-filling:before {
|
||||||
|
content: "\e696";
|
||||||
|
}
|
||||||
|
|
||||||
|
.history-filling:before {
|
||||||
|
content: "\e697";
|
||||||
|
}
|
||||||
|
|
||||||
|
.filter-filling:before {
|
||||||
|
content: "\e698";
|
||||||
|
}
|
||||||
|
|
||||||
|
.file-common-filling:before {
|
||||||
|
content: "\e699";
|
||||||
|
}
|
||||||
|
|
||||||
|
.news-filling:before {
|
||||||
|
content: "\e69a";
|
||||||
|
}
|
||||||
|
|
||||||
|
.edit-filling:before {
|
||||||
|
content: "\e69b";
|
||||||
|
}
|
||||||
|
|
||||||
|
.fullscreen-expand-filling:before {
|
||||||
|
content: "\e69c";
|
||||||
|
}
|
||||||
|
|
||||||
|
.smile-filling:before {
|
||||||
|
content: "\e69d";
|
||||||
|
}
|
||||||
|
|
||||||
|
.rise-filling:before {
|
||||||
|
content: "\e69e";
|
||||||
|
}
|
||||||
|
|
||||||
|
.picture-filling:before {
|
||||||
|
content: "\e69f";
|
||||||
|
}
|
||||||
|
|
||||||
|
.notification-filling:before {
|
||||||
|
content: "\e6a0";
|
||||||
|
}
|
||||||
|
|
||||||
|
.user-filling:before {
|
||||||
|
content: "\e6a1";
|
||||||
|
}
|
||||||
|
|
||||||
|
.setting-filling:before {
|
||||||
|
content: "\e6a2";
|
||||||
|
}
|
||||||
|
|
||||||
|
.switch-filling:before {
|
||||||
|
content: "\e6a3";
|
||||||
|
}
|
||||||
|
|
||||||
|
.work-filling:before {
|
||||||
|
content: "\e6a4";
|
||||||
|
}
|
||||||
|
|
||||||
|
.task-filling:before {
|
||||||
|
content: "\e6a5";
|
||||||
|
}
|
||||||
|
|
||||||
|
.success-filling:before {
|
||||||
|
content: "\e6a6";
|
||||||
|
}
|
||||||
|
|
||||||
|
.warning-filling:before {
|
||||||
|
content: "\e6a7";
|
||||||
|
}
|
||||||
|
|
||||||
|
.folder-filling:before {
|
||||||
|
content: "\e6a8";
|
||||||
|
}
|
||||||
|
|
||||||
|
.map-filling:before {
|
||||||
|
content: "\e6a9";
|
||||||
|
}
|
||||||
|
|
||||||
|
.prompt-filling:before {
|
||||||
|
content: "\e6aa";
|
||||||
|
}
|
||||||
|
|
||||||
|
.meh-filling:before {
|
||||||
|
content: "\e6ab";
|
||||||
|
}
|
||||||
|
|
||||||
|
.cry-filling:before {
|
||||||
|
content: "\e6ac";
|
||||||
|
}
|
||||||
|
|
||||||
|
.top-filling:before {
|
||||||
|
content: "\e6ad";
|
||||||
|
}
|
||||||
|
|
||||||
|
.home-filling:before {
|
||||||
|
content: "\e6ae";
|
||||||
|
}
|
||||||
|
|
||||||
|
.sorting:before {
|
||||||
|
content: "\e6af";
|
||||||
|
}
|
||||||
|
|
||||||
289
src/assets/icons/mobile/filled/iconfont.json
Normal file
289
src/assets/icons/mobile/filled/iconfont.json
Normal file
@@ -0,0 +1,289 @@
|
|||||||
|
{
|
||||||
|
"id": "3880534",
|
||||||
|
"name": "snowy-app-filled",
|
||||||
|
"font_family": "snowy",
|
||||||
|
"css_prefix_text": "",
|
||||||
|
"description": "",
|
||||||
|
"glyphs": [
|
||||||
|
{
|
||||||
|
"icon_id": "15838581",
|
||||||
|
"name": "arrow-up-filling",
|
||||||
|
"font_class": "arrow-up-filling",
|
||||||
|
"unicode": "e688",
|
||||||
|
"unicode_decimal": 59016
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838582",
|
||||||
|
"name": "arrow-down-filling",
|
||||||
|
"font_class": "arrow-down-filling",
|
||||||
|
"unicode": "e689",
|
||||||
|
"unicode_decimal": 59017
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838583",
|
||||||
|
"name": "arrow-left-filling",
|
||||||
|
"font_class": "arrow-left-filling",
|
||||||
|
"unicode": "e68a",
|
||||||
|
"unicode_decimal": 59018
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838584",
|
||||||
|
"name": "arrow-right-filling",
|
||||||
|
"font_class": "arrow-right-filling",
|
||||||
|
"unicode": "e68b",
|
||||||
|
"unicode_decimal": 59019
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838585",
|
||||||
|
"name": "caps-unlock-filling",
|
||||||
|
"font_class": "caps-unlock-filling",
|
||||||
|
"unicode": "e68c",
|
||||||
|
"unicode_decimal": 59020
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838586",
|
||||||
|
"name": "comment-filling",
|
||||||
|
"font_class": "comment-filling",
|
||||||
|
"unicode": "e68d",
|
||||||
|
"unicode_decimal": 59021
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838587",
|
||||||
|
"name": "check-item-filling",
|
||||||
|
"font_class": "check-item-filling",
|
||||||
|
"unicode": "e68e",
|
||||||
|
"unicode_decimal": 59022
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838588",
|
||||||
|
"name": "clock-filling",
|
||||||
|
"font_class": "clock-filling",
|
||||||
|
"unicode": "e68f",
|
||||||
|
"unicode_decimal": 59023
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838589",
|
||||||
|
"name": "delete-filling",
|
||||||
|
"font_class": "delete-filling",
|
||||||
|
"unicode": "e690",
|
||||||
|
"unicode_decimal": 59024
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838590",
|
||||||
|
"name": "decline-filling",
|
||||||
|
"font_class": "decline-filling",
|
||||||
|
"unicode": "e691",
|
||||||
|
"unicode_decimal": 59025
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838591",
|
||||||
|
"name": "dynamic-filling",
|
||||||
|
"font_class": "dynamic-filling",
|
||||||
|
"unicode": "e692",
|
||||||
|
"unicode_decimal": 59026
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838592",
|
||||||
|
"name": "intermediate-filling",
|
||||||
|
"font_class": "intermediate-filling",
|
||||||
|
"unicode": "e693",
|
||||||
|
"unicode_decimal": 59027
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838593",
|
||||||
|
"name": "favorite-filling",
|
||||||
|
"font_class": "favorite-filling",
|
||||||
|
"unicode": "e694",
|
||||||
|
"unicode_decimal": 59028
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838594",
|
||||||
|
"name": "layout-filling",
|
||||||
|
"font_class": "layout-filling",
|
||||||
|
"unicode": "e695",
|
||||||
|
"unicode_decimal": 59029
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838595",
|
||||||
|
"name": "help-filling",
|
||||||
|
"font_class": "help-filling",
|
||||||
|
"unicode": "e696",
|
||||||
|
"unicode_decimal": 59030
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838596",
|
||||||
|
"name": "history-filling",
|
||||||
|
"font_class": "history-filling",
|
||||||
|
"unicode": "e697",
|
||||||
|
"unicode_decimal": 59031
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838597",
|
||||||
|
"name": "filter-filling",
|
||||||
|
"font_class": "filter-filling",
|
||||||
|
"unicode": "e698",
|
||||||
|
"unicode_decimal": 59032
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838598",
|
||||||
|
"name": "file-common-filling",
|
||||||
|
"font_class": "file-common-filling",
|
||||||
|
"unicode": "e699",
|
||||||
|
"unicode_decimal": 59033
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838599",
|
||||||
|
"name": "news-filling",
|
||||||
|
"font_class": "news-filling",
|
||||||
|
"unicode": "e69a",
|
||||||
|
"unicode_decimal": 59034
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838600",
|
||||||
|
"name": "edit-filling",
|
||||||
|
"font_class": "edit-filling",
|
||||||
|
"unicode": "e69b",
|
||||||
|
"unicode_decimal": 59035
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838601",
|
||||||
|
"name": "fullscreen-expand-filling",
|
||||||
|
"font_class": "fullscreen-expand-filling",
|
||||||
|
"unicode": "e69c",
|
||||||
|
"unicode_decimal": 59036
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838602",
|
||||||
|
"name": "smile-filling",
|
||||||
|
"font_class": "smile-filling",
|
||||||
|
"unicode": "e69d",
|
||||||
|
"unicode_decimal": 59037
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838603",
|
||||||
|
"name": "rise-filling",
|
||||||
|
"font_class": "rise-filling",
|
||||||
|
"unicode": "e69e",
|
||||||
|
"unicode_decimal": 59038
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838604",
|
||||||
|
"name": "picture-filling",
|
||||||
|
"font_class": "picture-filling",
|
||||||
|
"unicode": "e69f",
|
||||||
|
"unicode_decimal": 59039
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838605",
|
||||||
|
"name": "notification-filling",
|
||||||
|
"font_class": "notification-filling",
|
||||||
|
"unicode": "e6a0",
|
||||||
|
"unicode_decimal": 59040
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838606",
|
||||||
|
"name": "user-filling",
|
||||||
|
"font_class": "user-filling",
|
||||||
|
"unicode": "e6a1",
|
||||||
|
"unicode_decimal": 59041
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838607",
|
||||||
|
"name": "setting-filling",
|
||||||
|
"font_class": "setting-filling",
|
||||||
|
"unicode": "e6a2",
|
||||||
|
"unicode_decimal": 59042
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838608",
|
||||||
|
"name": "switch-filling",
|
||||||
|
"font_class": "switch-filling",
|
||||||
|
"unicode": "e6a3",
|
||||||
|
"unicode_decimal": 59043
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838609",
|
||||||
|
"name": "work-filling",
|
||||||
|
"font_class": "work-filling",
|
||||||
|
"unicode": "e6a4",
|
||||||
|
"unicode_decimal": 59044
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838610",
|
||||||
|
"name": "task-filling",
|
||||||
|
"font_class": "task-filling",
|
||||||
|
"unicode": "e6a5",
|
||||||
|
"unicode_decimal": 59045
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838611",
|
||||||
|
"name": "success-filling",
|
||||||
|
"font_class": "success-filling",
|
||||||
|
"unicode": "e6a6",
|
||||||
|
"unicode_decimal": 59046
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838612",
|
||||||
|
"name": "warning-filling",
|
||||||
|
"font_class": "warning-filling",
|
||||||
|
"unicode": "e6a7",
|
||||||
|
"unicode_decimal": 59047
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838613",
|
||||||
|
"name": "folder-filling",
|
||||||
|
"font_class": "folder-filling",
|
||||||
|
"unicode": "e6a8",
|
||||||
|
"unicode_decimal": 59048
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838614",
|
||||||
|
"name": "map-filling",
|
||||||
|
"font_class": "map-filling",
|
||||||
|
"unicode": "e6a9",
|
||||||
|
"unicode_decimal": 59049
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838615",
|
||||||
|
"name": "prompt-filling",
|
||||||
|
"font_class": "prompt-filling",
|
||||||
|
"unicode": "e6aa",
|
||||||
|
"unicode_decimal": 59050
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838616",
|
||||||
|
"name": "meh-filling",
|
||||||
|
"font_class": "meh-filling",
|
||||||
|
"unicode": "e6ab",
|
||||||
|
"unicode_decimal": 59051
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838617",
|
||||||
|
"name": "cry-filling",
|
||||||
|
"font_class": "cry-filling",
|
||||||
|
"unicode": "e6ac",
|
||||||
|
"unicode_decimal": 59052
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838618",
|
||||||
|
"name": "top-filling",
|
||||||
|
"font_class": "top-filling",
|
||||||
|
"unicode": "e6ad",
|
||||||
|
"unicode_decimal": 59053
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838619",
|
||||||
|
"name": "home-filling",
|
||||||
|
"font_class": "home-filling",
|
||||||
|
"unicode": "e6ae",
|
||||||
|
"unicode_decimal": 59054
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "15838620",
|
||||||
|
"name": "sorting",
|
||||||
|
"font_class": "sorting",
|
||||||
|
"unicode": "e6af",
|
||||||
|
"unicode_decimal": 59055
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
BIN
src/assets/icons/mobile/filled/iconfont.ttf
Normal file
BIN
src/assets/icons/mobile/filled/iconfont.ttf
Normal file
Binary file not shown.
36
src/assets/icons/mobile/index.js
Normal file
36
src/assets/icons/mobile/index.js
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import './line/iconfont.css'
|
||||||
|
import lineJsonData from './line/iconfont.json'
|
||||||
|
|
||||||
|
import './filled/iconfont.css'
|
||||||
|
import filledJsonData from './filled/iconfont.json'
|
||||||
|
|
||||||
|
export default {
|
||||||
|
icons: [
|
||||||
|
{
|
||||||
|
name: '基础',
|
||||||
|
key: 'default',
|
||||||
|
iconItem: [
|
||||||
|
{
|
||||||
|
name: '线框风格',
|
||||||
|
key: 'default',
|
||||||
|
item: lineJsonData.glyphs
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: '实底风格',
|
||||||
|
key: 'filled',
|
||||||
|
item: filledJsonData.glyphs
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
825
src/assets/icons/mobile/line/iconfont.css
Normal file
825
src/assets/icons/mobile/line/iconfont.css
Normal file
@@ -0,0 +1,825 @@
|
|||||||
|
@font-face {
|
||||||
|
font-family: "snowy"; /* Project id 3791763 */
|
||||||
|
src: url('iconfont.ttf?t=1675526220710') format('truetype');
|
||||||
|
}
|
||||||
|
|
||||||
|
.snowy {
|
||||||
|
font-family: "snowy" !important;
|
||||||
|
font-size: 16px;
|
||||||
|
font-style: normal;
|
||||||
|
-webkit-font-smoothing: antialiased;
|
||||||
|
-moz-osx-font-smoothing: grayscale;
|
||||||
|
}
|
||||||
|
|
||||||
|
.export-outlined:before {
|
||||||
|
content: "\e792";
|
||||||
|
}
|
||||||
|
|
||||||
|
.experiment-outlined:before {
|
||||||
|
content: "\e7c9";
|
||||||
|
}
|
||||||
|
|
||||||
|
.expand-outlined:before {
|
||||||
|
content: "\e915";
|
||||||
|
}
|
||||||
|
|
||||||
|
.expand-alt-outlined:before {
|
||||||
|
content: "\e7e9";
|
||||||
|
}
|
||||||
|
|
||||||
|
.exception-outlined:before {
|
||||||
|
content: "\e7bb";
|
||||||
|
}
|
||||||
|
|
||||||
|
.euro-outlined:before {
|
||||||
|
content: "\e78f";
|
||||||
|
}
|
||||||
|
|
||||||
|
.euro-circle-outlined:before {
|
||||||
|
content: "\eb62";
|
||||||
|
}
|
||||||
|
|
||||||
|
.environment-outlined:before {
|
||||||
|
content: "\e790";
|
||||||
|
}
|
||||||
|
|
||||||
|
.ellipsis-outlined:before {
|
||||||
|
content: "\e815";
|
||||||
|
}
|
||||||
|
|
||||||
|
.download-outlined:before {
|
||||||
|
content: "\e814";
|
||||||
|
}
|
||||||
|
|
||||||
|
.dollar-outlined:before {
|
||||||
|
content: "\e78d";
|
||||||
|
}
|
||||||
|
|
||||||
|
.dollar-circle-outlined:before {
|
||||||
|
content: "\eb61";
|
||||||
|
}
|
||||||
|
|
||||||
|
.dislike-outlined:before {
|
||||||
|
content: "\e7c8";
|
||||||
|
}
|
||||||
|
|
||||||
|
.disconnect-outlined:before {
|
||||||
|
content: "\e7e8";
|
||||||
|
}
|
||||||
|
|
||||||
|
.dingtalk-outlined:before {
|
||||||
|
content: "\e881";
|
||||||
|
}
|
||||||
|
|
||||||
|
.desktop-outlined:before {
|
||||||
|
content: "\e845";
|
||||||
|
}
|
||||||
|
|
||||||
|
.deployment-unit-outlined:before {
|
||||||
|
content: "\e7d2";
|
||||||
|
}
|
||||||
|
|
||||||
|
.delivered-procedure-outlined:before {
|
||||||
|
content: "\e911";
|
||||||
|
}
|
||||||
|
|
||||||
|
.delete-column-outlined:before {
|
||||||
|
content: "\e901";
|
||||||
|
}
|
||||||
|
|
||||||
|
.delete-row-outlined:before {
|
||||||
|
content: "\e902";
|
||||||
|
}
|
||||||
|
|
||||||
|
.database-outlined:before {
|
||||||
|
content: "\e7b9";
|
||||||
|
}
|
||||||
|
|
||||||
|
.dashboard-outlined:before {
|
||||||
|
content: "\e78b";
|
||||||
|
}
|
||||||
|
|
||||||
|
.customer-service-outlined:before {
|
||||||
|
content: "\e7ca";
|
||||||
|
}
|
||||||
|
|
||||||
|
.crown-outlined:before {
|
||||||
|
content: "\e844";
|
||||||
|
}
|
||||||
|
|
||||||
|
.credit-card-outlined:before {
|
||||||
|
content: "\e7e5";
|
||||||
|
}
|
||||||
|
|
||||||
|
.copyright-outlined:before {
|
||||||
|
content: "\e789";
|
||||||
|
}
|
||||||
|
|
||||||
|
.copyright-circle-outlined:before {
|
||||||
|
content: "\eb60";
|
||||||
|
}
|
||||||
|
|
||||||
|
.control-outlined:before {
|
||||||
|
content: "\e79c";
|
||||||
|
}
|
||||||
|
|
||||||
|
.container-outlined:before {
|
||||||
|
content: "\e7b8";
|
||||||
|
}
|
||||||
|
|
||||||
|
.contacts-outlined:before {
|
||||||
|
content: "\e7e4";
|
||||||
|
}
|
||||||
|
|
||||||
|
.console-sql-outlined:before {
|
||||||
|
content: "\e910";
|
||||||
|
}
|
||||||
|
|
||||||
|
.compress-outlined:before {
|
||||||
|
content: "\e914";
|
||||||
|
}
|
||||||
|
|
||||||
|
.compass-outlined:before {
|
||||||
|
content: "\e786";
|
||||||
|
}
|
||||||
|
|
||||||
|
.comment-outlined:before {
|
||||||
|
content: "\e8ea";
|
||||||
|
}
|
||||||
|
|
||||||
|
.coffee-outlined:before {
|
||||||
|
content: "\e6b5";
|
||||||
|
}
|
||||||
|
|
||||||
|
.code-outlined:before {
|
||||||
|
content: "\e79b";
|
||||||
|
}
|
||||||
|
|
||||||
|
.cloud-server-outlined:before {
|
||||||
|
content: "\e7db";
|
||||||
|
}
|
||||||
|
|
||||||
|
.cloud-upload-outlined:before {
|
||||||
|
content: "\e7dc";
|
||||||
|
}
|
||||||
|
|
||||||
|
.cloud-outlined:before {
|
||||||
|
content: "\e7dd";
|
||||||
|
}
|
||||||
|
|
||||||
|
.cloud-download-outlined:before {
|
||||||
|
content: "\e7de";
|
||||||
|
}
|
||||||
|
|
||||||
|
.cloud-sync-outlined:before {
|
||||||
|
content: "\e7e0";
|
||||||
|
}
|
||||||
|
|
||||||
|
.clear-outlined:before {
|
||||||
|
content: "\e900";
|
||||||
|
}
|
||||||
|
|
||||||
|
.ci-circle-outlined:before {
|
||||||
|
content: "\e77f";
|
||||||
|
}
|
||||||
|
|
||||||
|
.carry-out-outlined:before {
|
||||||
|
content: "\e7d6";
|
||||||
|
}
|
||||||
|
|
||||||
|
.car-outlined:before {
|
||||||
|
content: "\e7da";
|
||||||
|
}
|
||||||
|
|
||||||
|
.ci-outlined:before {
|
||||||
|
content: "\eb5f";
|
||||||
|
}
|
||||||
|
|
||||||
|
.camera-outlined:before {
|
||||||
|
content: "\e7d9";
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-outlined:before {
|
||||||
|
content: "\e7d4";
|
||||||
|
}
|
||||||
|
|
||||||
|
.calculator-outlined:before {
|
||||||
|
content: "\e79a";
|
||||||
|
}
|
||||||
|
|
||||||
|
.bulb-outlined:before {
|
||||||
|
content: "\e7c7";
|
||||||
|
}
|
||||||
|
|
||||||
|
.build-outlined:before {
|
||||||
|
content: "\e7d5";
|
||||||
|
}
|
||||||
|
|
||||||
|
.bug-outlined:before {
|
||||||
|
content: "\e8e9";
|
||||||
|
}
|
||||||
|
|
||||||
|
.branches-outlined:before {
|
||||||
|
content: "\e7e7";
|
||||||
|
}
|
||||||
|
|
||||||
|
.borderless-table-outlined:before {
|
||||||
|
content: "\e813";
|
||||||
|
}
|
||||||
|
|
||||||
|
.border-outlined:before {
|
||||||
|
content: "\e7b7";
|
||||||
|
}
|
||||||
|
|
||||||
|
.book-outlined:before {
|
||||||
|
content: "\e7b6";
|
||||||
|
}
|
||||||
|
|
||||||
|
.block-outlined:before {
|
||||||
|
content: "\e7df";
|
||||||
|
}
|
||||||
|
|
||||||
|
.bell-outlined:before {
|
||||||
|
content: "\e7c5";
|
||||||
|
}
|
||||||
|
|
||||||
|
.bars-outlined:before {
|
||||||
|
content: "\e71a";
|
||||||
|
}
|
||||||
|
|
||||||
|
.barcode-outlined:before {
|
||||||
|
content: "\e7d8";
|
||||||
|
}
|
||||||
|
|
||||||
|
.bank-outlined:before {
|
||||||
|
content: "\e7c6";
|
||||||
|
}
|
||||||
|
|
||||||
|
.audit-outlined:before {
|
||||||
|
content: "\e7c0";
|
||||||
|
}
|
||||||
|
|
||||||
|
.audio-outlined:before {
|
||||||
|
content: "\e89b";
|
||||||
|
}
|
||||||
|
|
||||||
|
.audio-muted-outlined:before {
|
||||||
|
content: "\e8e8";
|
||||||
|
}
|
||||||
|
|
||||||
|
.api-outlined:before {
|
||||||
|
content: "\e7e3";
|
||||||
|
}
|
||||||
|
|
||||||
|
.apartment-outlined:before {
|
||||||
|
content: "\e89a";
|
||||||
|
}
|
||||||
|
|
||||||
|
.alert-outlined:before {
|
||||||
|
content: "\e7c4";
|
||||||
|
}
|
||||||
|
|
||||||
|
.aim-outlined:before {
|
||||||
|
content: "\e913";
|
||||||
|
}
|
||||||
|
|
||||||
|
.account-book-outlined:before {
|
||||||
|
content: "\e7d3";
|
||||||
|
}
|
||||||
|
|
||||||
|
.column-height-outlined:before {
|
||||||
|
content: "\e811";
|
||||||
|
}
|
||||||
|
|
||||||
|
.column-width-outlined:before {
|
||||||
|
content: "\e812";
|
||||||
|
}
|
||||||
|
|
||||||
|
.radius-setting-outlined:before {
|
||||||
|
content: "\e7b5";
|
||||||
|
}
|
||||||
|
|
||||||
|
.unordered-list-outlined:before {
|
||||||
|
content: "\e80f";
|
||||||
|
}
|
||||||
|
|
||||||
|
.ordered-list-outlined:before {
|
||||||
|
content: "\e810";
|
||||||
|
}
|
||||||
|
|
||||||
|
.drag-outlined:before {
|
||||||
|
content: "\e843";
|
||||||
|
}
|
||||||
|
|
||||||
|
.sort-descending-outlined:before {
|
||||||
|
content: "\e80d";
|
||||||
|
}
|
||||||
|
|
||||||
|
.sort-ascending-outlined:before {
|
||||||
|
content: "\e80e";
|
||||||
|
}
|
||||||
|
|
||||||
|
.font-colors-outlined:before {
|
||||||
|
content: "\e808";
|
||||||
|
}
|
||||||
|
|
||||||
|
.font-size-outlined:before {
|
||||||
|
content: "\e809";
|
||||||
|
}
|
||||||
|
|
||||||
|
.line-height-outlined:before {
|
||||||
|
content: "\e80a";
|
||||||
|
}
|
||||||
|
|
||||||
|
.dash-outlined:before {
|
||||||
|
content: "\e80b";
|
||||||
|
}
|
||||||
|
|
||||||
|
.small-dash-outlined:before {
|
||||||
|
content: "\e80c";
|
||||||
|
}
|
||||||
|
|
||||||
|
.zoom-out-outlined:before {
|
||||||
|
content: "\e898";
|
||||||
|
}
|
||||||
|
|
||||||
|
.zoom-in-outlined:before {
|
||||||
|
content: "\e899";
|
||||||
|
}
|
||||||
|
|
||||||
|
.undo-outlined:before {
|
||||||
|
content: "\e787";
|
||||||
|
}
|
||||||
|
|
||||||
|
.redo-outlined:before {
|
||||||
|
content: "\e788";
|
||||||
|
}
|
||||||
|
|
||||||
|
.bold-outlined:before {
|
||||||
|
content: "\e804";
|
||||||
|
}
|
||||||
|
|
||||||
|
.strikethrough-outlined:before {
|
||||||
|
content: "\e805";
|
||||||
|
}
|
||||||
|
|
||||||
|
.underline-outlined:before {
|
||||||
|
content: "\e806";
|
||||||
|
}
|
||||||
|
|
||||||
|
.italic-outlined:before {
|
||||||
|
content: "\e807";
|
||||||
|
}
|
||||||
|
|
||||||
|
.bg-colors-outlined:before {
|
||||||
|
content: "\e803";
|
||||||
|
}
|
||||||
|
|
||||||
|
.align-right-outlined:before {
|
||||||
|
content: "\e7fb";
|
||||||
|
}
|
||||||
|
|
||||||
|
.align-left-outlined:before {
|
||||||
|
content: "\e802";
|
||||||
|
}
|
||||||
|
|
||||||
|
.align-center-outlined:before {
|
||||||
|
content: "\e7f5";
|
||||||
|
}
|
||||||
|
|
||||||
|
.highlight-outlined:before {
|
||||||
|
content: "\e7e2";
|
||||||
|
}
|
||||||
|
|
||||||
|
.diff-outlined:before {
|
||||||
|
content: "\e7bf";
|
||||||
|
}
|
||||||
|
|
||||||
|
.snippets-outlined:before {
|
||||||
|
content: "\e7bd";
|
||||||
|
}
|
||||||
|
|
||||||
|
.delete-outlined:before {
|
||||||
|
content: "\e7c3";
|
||||||
|
}
|
||||||
|
|
||||||
|
.scissor-outlined:before {
|
||||||
|
content: "\e7e6";
|
||||||
|
}
|
||||||
|
|
||||||
|
.copy-outlined:before {
|
||||||
|
content: "\e7bc";
|
||||||
|
}
|
||||||
|
|
||||||
|
.form-outlined:before {
|
||||||
|
content: "\e791";
|
||||||
|
}
|
||||||
|
|
||||||
|
.edit-outlined:before {
|
||||||
|
content: "\e7e1";
|
||||||
|
}
|
||||||
|
|
||||||
|
.stop-outlined:before {
|
||||||
|
content: "\e842";
|
||||||
|
}
|
||||||
|
|
||||||
|
.issues-close-outlined:before {
|
||||||
|
content: "\e68e";
|
||||||
|
}
|
||||||
|
|
||||||
|
.warning-outlined:before {
|
||||||
|
content: "\e682";
|
||||||
|
}
|
||||||
|
|
||||||
|
.clock-circle-outlined:before {
|
||||||
|
content: "\e784";
|
||||||
|
}
|
||||||
|
|
||||||
|
.check-circle-outlined:before {
|
||||||
|
content: "\e77d";
|
||||||
|
}
|
||||||
|
|
||||||
|
.check-square-outlined:before {
|
||||||
|
content: "\e794";
|
||||||
|
}
|
||||||
|
|
||||||
|
.check-outlined:before {
|
||||||
|
content: "\e7fc";
|
||||||
|
}
|
||||||
|
|
||||||
|
.exclamation-circle-outlined:before {
|
||||||
|
content: "\e785";
|
||||||
|
}
|
||||||
|
|
||||||
|
.exclamation-outlined:before {
|
||||||
|
content: "\e7fa";
|
||||||
|
}
|
||||||
|
|
||||||
|
.info-circle-outlined:before {
|
||||||
|
content: "\e77e";
|
||||||
|
}
|
||||||
|
|
||||||
|
.info-outlined:before {
|
||||||
|
content: "\e7f9";
|
||||||
|
}
|
||||||
|
|
||||||
|
.minus-square-outlined:before {
|
||||||
|
content: "\e796";
|
||||||
|
}
|
||||||
|
|
||||||
|
.plus-square-outlined:before {
|
||||||
|
content: "\e797";
|
||||||
|
}
|
||||||
|
|
||||||
|
.minus-circle-outlined:before {
|
||||||
|
content: "\e780";
|
||||||
|
}
|
||||||
|
|
||||||
|
.minus-outlined:before {
|
||||||
|
content: "\e801";
|
||||||
|
}
|
||||||
|
|
||||||
|
.pause-circle-outlined:before {
|
||||||
|
content: "\e783";
|
||||||
|
}
|
||||||
|
|
||||||
|
.pause-outlined:before {
|
||||||
|
content: "\e800";
|
||||||
|
}
|
||||||
|
|
||||||
|
.plus-circle-outlined:before {
|
||||||
|
content: "\e781";
|
||||||
|
}
|
||||||
|
|
||||||
|
.plus-outlined:before {
|
||||||
|
content: "\e8fe";
|
||||||
|
}
|
||||||
|
|
||||||
|
.question-circle-outlined:before {
|
||||||
|
content: "\e782";
|
||||||
|
}
|
||||||
|
|
||||||
|
.question-outlined:before {
|
||||||
|
content: "\e7ff";
|
||||||
|
}
|
||||||
|
|
||||||
|
.fullscreen-outlined:before {
|
||||||
|
content: "\e7ec";
|
||||||
|
}
|
||||||
|
|
||||||
|
.fullscreen-exit-outlined:before {
|
||||||
|
content: "\e7ed";
|
||||||
|
}
|
||||||
|
|
||||||
|
.radius-bottomleft-outlined:before {
|
||||||
|
content: "\e7b1";
|
||||||
|
}
|
||||||
|
|
||||||
|
.radius-bottomright-outlined:before {
|
||||||
|
content: "\e7b2";
|
||||||
|
}
|
||||||
|
|
||||||
|
.radius-upleft-outlined:before {
|
||||||
|
content: "\e7b3";
|
||||||
|
}
|
||||||
|
|
||||||
|
.radius-upright-outlined:before {
|
||||||
|
content: "\e7b4";
|
||||||
|
}
|
||||||
|
|
||||||
|
.pic-center-outlined:before {
|
||||||
|
content: "\e7f6";
|
||||||
|
}
|
||||||
|
|
||||||
|
.pic-right-outlined:before {
|
||||||
|
content: "\e7f7";
|
||||||
|
}
|
||||||
|
|
||||||
|
.pic-left-outlined:before {
|
||||||
|
content: "\e7f8";
|
||||||
|
}
|
||||||
|
|
||||||
|
.border-outer-outlined:before {
|
||||||
|
content: "\e7a9";
|
||||||
|
}
|
||||||
|
|
||||||
|
.border-top-outlined:before {
|
||||||
|
content: "\e7aa";
|
||||||
|
}
|
||||||
|
|
||||||
|
.border-bottom-outlined:before {
|
||||||
|
content: "\e7ab";
|
||||||
|
}
|
||||||
|
|
||||||
|
.border-left-outlined:before {
|
||||||
|
content: "\e7ac";
|
||||||
|
}
|
||||||
|
|
||||||
|
.border-right-outlined:before {
|
||||||
|
content: "\e7ad";
|
||||||
|
}
|
||||||
|
|
||||||
|
.border-inner-outlined:before {
|
||||||
|
content: "\e7ae";
|
||||||
|
}
|
||||||
|
|
||||||
|
.border-verticle-outlined:before {
|
||||||
|
content: "\e7af";
|
||||||
|
}
|
||||||
|
|
||||||
|
.border-horizontal-outlined:before {
|
||||||
|
content: "\e7b0";
|
||||||
|
}
|
||||||
|
|
||||||
|
.menu-unfold-outlined:before {
|
||||||
|
content: "\e7f3";
|
||||||
|
}
|
||||||
|
|
||||||
|
.menu-fold-outlined:before {
|
||||||
|
content: "\e7f4";
|
||||||
|
}
|
||||||
|
|
||||||
|
.logout-outlined:before {
|
||||||
|
content: "\e78c";
|
||||||
|
}
|
||||||
|
|
||||||
|
.login-outlined:before {
|
||||||
|
content: "\e8f4";
|
||||||
|
}
|
||||||
|
|
||||||
|
.cluster-outlined:before {
|
||||||
|
content: "\e7d7";
|
||||||
|
}
|
||||||
|
|
||||||
|
.down-square-outlined:before {
|
||||||
|
content: "\e793";
|
||||||
|
}
|
||||||
|
|
||||||
|
.left-square-outlined:before {
|
||||||
|
content: "\e795";
|
||||||
|
}
|
||||||
|
|
||||||
|
.right-square-outlined:before {
|
||||||
|
content: "\e798";
|
||||||
|
}
|
||||||
|
|
||||||
|
.up-Square-outlined:before {
|
||||||
|
content: "\e799";
|
||||||
|
}
|
||||||
|
|
||||||
|
.play-circle-outlined:before {
|
||||||
|
content: "\e67a";
|
||||||
|
}
|
||||||
|
|
||||||
|
.arrow-down-outlined:before {
|
||||||
|
content: "\e66d";
|
||||||
|
}
|
||||||
|
|
||||||
|
.arrow-right-outlined:before {
|
||||||
|
content: "\e66e";
|
||||||
|
}
|
||||||
|
|
||||||
|
.arrow-up-outlined:before {
|
||||||
|
content: "\e66f";
|
||||||
|
}
|
||||||
|
|
||||||
|
.arrow-left-outlined:before {
|
||||||
|
content: "\e670";
|
||||||
|
}
|
||||||
|
|
||||||
|
.swap-outlined:before {
|
||||||
|
content: "\e7f2";
|
||||||
|
}
|
||||||
|
|
||||||
|
.swap-right-outlined:before {
|
||||||
|
content: "\e8f2";
|
||||||
|
}
|
||||||
|
|
||||||
|
.swap-left-outlined:before {
|
||||||
|
content: "\e8f3";
|
||||||
|
}
|
||||||
|
|
||||||
|
.enter-outlined:before {
|
||||||
|
content: "\e7fd";
|
||||||
|
}
|
||||||
|
|
||||||
|
.rollback-outlined:before {
|
||||||
|
content: "\e7fe";
|
||||||
|
}
|
||||||
|
|
||||||
|
.retweet-outlined:before {
|
||||||
|
content: "\e8f1";
|
||||||
|
}
|
||||||
|
|
||||||
|
.fast-backward-outlined:before {
|
||||||
|
content: "\e8ed";
|
||||||
|
}
|
||||||
|
|
||||||
|
.fast-forward-outlined:before {
|
||||||
|
content: "\e8ee";
|
||||||
|
}
|
||||||
|
|
||||||
|
.vertical-align-bottom-outlined:before {
|
||||||
|
content: "\e7ef";
|
||||||
|
}
|
||||||
|
|
||||||
|
.vertical-align-middle-outlined:before {
|
||||||
|
content: "\e7f0";
|
||||||
|
}
|
||||||
|
|
||||||
|
.vertical-align-top-outlined:before {
|
||||||
|
content: "\e7f1";
|
||||||
|
}
|
||||||
|
|
||||||
|
.vertical-right-outlined:before {
|
||||||
|
content: "\e7ea";
|
||||||
|
}
|
||||||
|
|
||||||
|
.vertical-left-outlined:before {
|
||||||
|
content: "\e7eb";
|
||||||
|
}
|
||||||
|
|
||||||
|
.double-left-outlined:before {
|
||||||
|
content: "\e66b";
|
||||||
|
}
|
||||||
|
|
||||||
|
.double-right-outlined:before {
|
||||||
|
content: "\e66c";
|
||||||
|
}
|
||||||
|
|
||||||
|
.up-circle-outlined:before {
|
||||||
|
content: "\e666";
|
||||||
|
}
|
||||||
|
|
||||||
|
.right-circle-outlined:before {
|
||||||
|
content: "\e667";
|
||||||
|
}
|
||||||
|
|
||||||
|
.left-circle-outlined:before {
|
||||||
|
content: "\e66a";
|
||||||
|
}
|
||||||
|
|
||||||
|
.down-circle-outlined:before {
|
||||||
|
content: "\eb5e";
|
||||||
|
}
|
||||||
|
|
||||||
|
.caret-up-outlined:before {
|
||||||
|
content: "\e689";
|
||||||
|
}
|
||||||
|
|
||||||
|
.caret-down-outlined:before {
|
||||||
|
content: "\e68a";
|
||||||
|
}
|
||||||
|
|
||||||
|
.caret-left-outlined:before {
|
||||||
|
content: "\e68b";
|
||||||
|
}
|
||||||
|
|
||||||
|
.caret-right-outlined:before {
|
||||||
|
content: "\e68c";
|
||||||
|
}
|
||||||
|
|
||||||
|
.left-outlined:before {
|
||||||
|
content: "\e685";
|
||||||
|
}
|
||||||
|
|
||||||
|
.up-outlined:before {
|
||||||
|
content: "\e686";
|
||||||
|
}
|
||||||
|
|
||||||
|
.down-outlined:before {
|
||||||
|
content: "\e687";
|
||||||
|
}
|
||||||
|
|
||||||
|
.right-outlined:before {
|
||||||
|
content: "\e688";
|
||||||
|
}
|
||||||
|
|
||||||
|
.arrows-alt-outlined:before {
|
||||||
|
content: "\e665";
|
||||||
|
}
|
||||||
|
|
||||||
|
.shrink-outlined:before {
|
||||||
|
content: "\e68d";
|
||||||
|
}
|
||||||
|
|
||||||
|
.step-backward-outlined:before {
|
||||||
|
content: "\e8ef";
|
||||||
|
}
|
||||||
|
|
||||||
|
.step-forward-outlined:before {
|
||||||
|
content: "\e8f0";
|
||||||
|
}
|
||||||
|
|
||||||
|
.robot-outlined:before {
|
||||||
|
content: "\e897";
|
||||||
|
}
|
||||||
|
|
||||||
|
.file-word-outlined:before {
|
||||||
|
content: "\e7ba";
|
||||||
|
}
|
||||||
|
|
||||||
|
.usergroup-delete-outlined:before {
|
||||||
|
content: "\e760";
|
||||||
|
}
|
||||||
|
|
||||||
|
.field-time-outlined:before {
|
||||||
|
content: "\eb5d";
|
||||||
|
}
|
||||||
|
|
||||||
|
.setting-outlined:before {
|
||||||
|
content: "\e78e";
|
||||||
|
}
|
||||||
|
|
||||||
|
.file-search-outlined:before {
|
||||||
|
content: "\e730";
|
||||||
|
}
|
||||||
|
|
||||||
|
.team-outlined:before {
|
||||||
|
content: "\e67d";
|
||||||
|
}
|
||||||
|
|
||||||
|
.message-outlined:before {
|
||||||
|
content: "\e78a";
|
||||||
|
}
|
||||||
|
|
||||||
|
.mail-outlined:before {
|
||||||
|
content: "\e62e";
|
||||||
|
}
|
||||||
|
|
||||||
|
.send-outlined:before {
|
||||||
|
content: "\e622";
|
||||||
|
}
|
||||||
|
|
||||||
|
.appstore-add-outlined:before {
|
||||||
|
content: "\e8eb";
|
||||||
|
}
|
||||||
|
|
||||||
|
.user-outlined:before {
|
||||||
|
content: "\e641";
|
||||||
|
}
|
||||||
|
|
||||||
|
.project-outlined:before {
|
||||||
|
content: "\e746";
|
||||||
|
}
|
||||||
|
|
||||||
|
.hdd-outlined:before {
|
||||||
|
content: "\e734";
|
||||||
|
}
|
||||||
|
|
||||||
|
.tool-outlined:before {
|
||||||
|
content: "\e75b";
|
||||||
|
}
|
||||||
|
|
||||||
|
.user-switch-outlined:before {
|
||||||
|
content: "\ea3d";
|
||||||
|
}
|
||||||
|
|
||||||
|
.appstore-outlined:before {
|
||||||
|
content: "\e601";
|
||||||
|
}
|
||||||
|
|
||||||
|
.home-outlined:before {
|
||||||
|
content: "\e965";
|
||||||
|
}
|
||||||
|
|
||||||
1430
src/assets/icons/mobile/line/iconfont.json
Normal file
1430
src/assets/icons/mobile/line/iconfont.json
Normal file
File diff suppressed because it is too large
Load Diff
BIN
src/assets/icons/mobile/line/iconfont.ttf
Normal file
BIN
src/assets/icons/mobile/line/iconfont.ttf
Normal file
Binary file not shown.
43
src/components/ColorPicker/index.vue
Normal file
43
src/components/ColorPicker/index.vue
Normal file
@@ -0,0 +1,43 @@
|
|||||||
|
<template>
|
||||||
|
<div class="snowy-color-picker" @click="forceResize">
|
||||||
|
<color-picker v-bind="$attrs" format="hex" :pureColor="props.value" @update:pureColor="update" />
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup>
|
||||||
|
import { ColorPicker } from 'vue3-colorpicker'
|
||||||
|
import 'vue3-colorpicker/style.css'
|
||||||
|
|
||||||
|
const emit = defineEmits(['update:value'])
|
||||||
|
|
||||||
|
const props = defineProps({
|
||||||
|
value: {
|
||||||
|
type: String,
|
||||||
|
default: '#1890ff'
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
const forceResize = () => {
|
||||||
|
window.dispatchEvent(new Event('resize'))
|
||||||
|
}
|
||||||
|
|
||||||
|
const update = (val) => {
|
||||||
|
const currentColor = document.querySelector('.current-color')
|
||||||
|
if (currentColor) {
|
||||||
|
currentColor.textContent = val
|
||||||
|
}
|
||||||
|
emit('update:value', val)
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="less">
|
||||||
|
.snowy-color-picker {
|
||||||
|
.vc-color-wrap {
|
||||||
|
width: auto;
|
||||||
|
}
|
||||||
|
.current-color {
|
||||||
|
color: #fff;
|
||||||
|
padding: 0 10px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -1,398 +1,496 @@
|
|||||||
<template>
|
<template>
|
||||||
<a-modal
|
<el-dialog v-model="visible" title="机构选择" :align-center="true" width="90%" style="height: 600px">
|
||||||
v-model:visible="visible"
|
<!-- :mask-closable="false"
|
||||||
title="机构选择"
|
|
||||||
:width="1000"
|
|
||||||
:mask-closable="false"
|
|
||||||
:destroy-on-close="true"
|
:destroy-on-close="true"
|
||||||
@ok="handleOk"
|
@ok="handleOk"
|
||||||
@cancel="handleClose"
|
@cancel="handleClose" -->
|
||||||
>
|
<div class="drawer_body">
|
||||||
<a-row :gutter="10">
|
<el-row :gutter="10">
|
||||||
<a-col :span="7">
|
<el-col :span="7">
|
||||||
<a-card size="small" :loading="cardLoading" class="selectorTreeDiv">
|
<el-card size="small" :loading="cardLoading" class="selectorTreeDiv">
|
||||||
<a-tree
|
<el-tree
|
||||||
v-if="treeData"
|
v-if="treeData"
|
||||||
v-model:expandedKeys="defaultExpandedKeys"
|
v-model:expandedKeys="defaultExpandedKeys"
|
||||||
:tree-data="treeData"
|
:data="treeData"
|
||||||
:field-names="treeFieldNames"
|
:field-names="treeFieldNames"
|
||||||
@select="treeSelect"
|
:props="defaultProps"
|
||||||
>
|
accordion
|
||||||
</a-tree>
|
:default-expand-all="true"
|
||||||
</a-card>
|
@node-click="treeSelect"
|
||||||
</a-col>
|
></el-tree>
|
||||||
<a-col :span="11">
|
</el-card>
|
||||||
<div class="table-operator" style="margin-bottom: 10px">
|
</el-col>
|
||||||
<a-form ref="searchFormRef" name="advanced_search" class="ant-advanced-search-form" :model="searchFormState">
|
<el-col :span="11">
|
||||||
<a-row :gutter="24">
|
<div class="table-operator" style="margin-bottom: 10px">
|
||||||
<a-col :span="12">
|
<el-form
|
||||||
<a-form-item name="searchKey">
|
ref="searchFormRef"
|
||||||
<a-input v-model:value="searchFormState.searchKey" placeholder="请输入机构名" />
|
name="advanced_search"
|
||||||
</a-form-item>
|
class="ant-advanced-search-form"
|
||||||
</a-col>
|
:model="searchFormState"
|
||||||
<a-col :span="12">
|
>
|
||||||
<a-button type="primary" class="primarySele" @click="loadData()"> 查询 </a-button>
|
<el-row :gutter="24">
|
||||||
<a-button class="snowy-buttom-left" @click="() => reset()"> 重置 </a-button>
|
<el-col :span="12">
|
||||||
</a-col>
|
<el-form-item name="searchKey">
|
||||||
</a-row>
|
<el-input
|
||||||
</a-form>
|
v-model="searchFormState.searchKey"
|
||||||
</div>
|
placeholder="请输入机构名"
|
||||||
<div class="org-table">
|
/>
|
||||||
<a-table
|
</el-form-item>
|
||||||
ref="table"
|
</el-col>
|
||||||
size="small"
|
<el-col :span="12">
|
||||||
:columns="commons"
|
<el-button type="primary" class="primarySele" @click="loadData()">查询</el-button>
|
||||||
:data-source="tableData"
|
<el-button class="snowy-buttom-left" @click="() => reset()">重置</el-button>
|
||||||
:expand-row-by-click="true"
|
</el-col>
|
||||||
:loading="pageLoading"
|
</el-row>
|
||||||
bordered
|
</el-form>
|
||||||
:pagination="false"
|
</div>
|
||||||
>
|
<div class="org-table">
|
||||||
<template #title>
|
<div class="org_table_head">
|
||||||
<span>待选择列表 {{ tableRecordNum }} 条</span>
|
<p>待选择列表</p>
|
||||||
<div v-if="!radioModel" style="float: right">
|
<div class="org_table_head_add">
|
||||||
<a-button type="dashed" size="small" @click="addAllPageRecord">添加当前数据</a-button>
|
添加当前数据
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</div>
|
||||||
<template #bodyCell="{ column, record }">
|
<el-table
|
||||||
<template v-if="column.dataIndex === 'category'">
|
ref="table"
|
||||||
{{ $TOOL.dictTypeData('ORG_CATEGORY', record.category) }}
|
size="small"
|
||||||
</template>
|
:columns="commons"
|
||||||
<template v-if="column.dataIndex === 'action'">
|
:data="tableData"
|
||||||
<a-button type="dashed" size="small" @click="addRecord(record)">添加</a-button>
|
:expand-row-by-click="true"
|
||||||
</template>
|
:loading="pageLoading"
|
||||||
</template>
|
bordered
|
||||||
</a-table>
|
:pagination="false"
|
||||||
<div class="mt-2">
|
border
|
||||||
<a-pagination
|
stripe
|
||||||
v-if="!isEmpty(tableData)"
|
height="330"
|
||||||
v-model:current="current"
|
>
|
||||||
v-model:page-size="pageSize"
|
<template #title>
|
||||||
:total="total"
|
<span>待选择列表 {{ tableRecordNum }} 条</span>
|
||||||
size="small"
|
<div v-if="!radioModel" style="float: right">
|
||||||
showSizeChanger
|
<el-button type="dashed" size="small" @click="addAllPageRecord">
|
||||||
@change="paginationChange"
|
添加当前数据
|
||||||
/>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</template>
|
||||||
</a-col>
|
<template #bodyCell="{ column, record }">
|
||||||
<a-col :span="6">
|
<template v-if="column.dataIndex === 'category'">
|
||||||
<div class="org-table">
|
{{ $TOOL.dictTypeData('ORG_CATEGORY', record.category) }}
|
||||||
<a-table
|
</template>
|
||||||
ref="selectedTable"
|
<template v-if="column.dataIndex === 'action'">
|
||||||
size="small"
|
<el-button type="dashed" size="small" @click="addRecord(record)">添加</el-button>
|
||||||
:columns="selectedCommons"
|
</template>
|
||||||
:data-source="selectedData"
|
</template>
|
||||||
:expand-row-by-click="true"
|
<el-table-column prop="action" label="操作" width="80" align="center">
|
||||||
:loading="selectedTableListLoading"
|
<el-button type="dashed" size="small" @click="addRecord(record)">添加</el-button>
|
||||||
bordered
|
</el-table-column>
|
||||||
>
|
<el-table-column prop="name" label="机构名" />
|
||||||
<template #title>
|
<el-table-column prop="type" label="分类"></el-table-column>
|
||||||
<span>已选择: {{ selectedData.length }}</span>
|
</el-table>
|
||||||
<div v-if="!radioModel" style="float: right">
|
<div class="mt-2">
|
||||||
<a-button type="dashed" danger size="small" @click="delAllRecord">全部移除</a-button>
|
<el-pagination
|
||||||
|
v-if="!isEmpty(tableData)"
|
||||||
|
v-model:current="current"
|
||||||
|
v-model:page-size="pageSize"
|
||||||
|
:total="total"
|
||||||
|
size="small"
|
||||||
|
showSizeChanger
|
||||||
|
@change="paginationChange"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="6">
|
||||||
|
<div class="org-table">
|
||||||
|
<div class="org_table_heads">
|
||||||
|
<p>待选择列表</p>
|
||||||
|
<div class="org_table_head_delete">
|
||||||
|
全部移除
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</div>
|
||||||
<template #bodyCell="{ column, record }">
|
<el-table
|
||||||
<template v-if="column.dataIndex === 'action'">
|
ref="selectedTable"
|
||||||
<a-button type="dashed" danger size="small" @click="delRecord(record)">移除</a-button>
|
size="small"
|
||||||
</template>
|
:columns="selectedCommons"
|
||||||
</template>
|
:data="selectedData"
|
||||||
</a-table>
|
:expand-row-by-click="true"
|
||||||
</div>
|
:loading="selectedTableListLoading"
|
||||||
</a-col>
|
bordered
|
||||||
</a-row>
|
border
|
||||||
</a-modal>
|
>
|
||||||
|
<template #title>
|
||||||
|
<span>已选择: {{ selectedData.length }}</span>
|
||||||
|
<div v-if="!radioModel" style="float: right">
|
||||||
|
<el-button type="dashed" danger size="small" @click="delAllRecord">
|
||||||
|
全部移除
|
||||||
|
</el-button>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<template #bodyCell="{ column, record }">
|
||||||
|
<template v-if="column.dataIndex === 'action'">
|
||||||
|
<el-button type="dashed" danger size="small" @click="delRecord(record)">
|
||||||
|
移除
|
||||||
|
</el-button>
|
||||||
|
</template>
|
||||||
|
</template>
|
||||||
|
<el-table-column prop="action" label="操作" width="80" align="center">
|
||||||
|
<el-button type="dashed" size="small" @click="addRecord(record)">添加</el-button>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="name" label="机构名" />
|
||||||
|
</el-table>
|
||||||
|
</div>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</div>
|
||||||
|
<template #footer>
|
||||||
|
<div class="dialog-footer">
|
||||||
|
<el-button @click="visible = false">取消</el-button>
|
||||||
|
<el-button type="primary" @click="visible = false">确定</el-button>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
</el-dialog>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup name="orgSelectorPlus">
|
<script setup name="orgSelectorPlus">
|
||||||
import { ElMessage } from 'element-plus'
|
import { ElMessage } from 'element-plus'
|
||||||
import { remove, isEmpty } from 'lodash-es'
|
import { remove, isEmpty } from 'lodash-es'
|
||||||
import { ref } from 'vue'
|
import { ref } from 'vue'
|
||||||
// 弹窗是否打开
|
// 弹窗是否打开
|
||||||
const visible = ref(false)
|
const visible = ref(false)
|
||||||
// 主表格common
|
// 主表格common
|
||||||
const commons = [
|
const commons = [
|
||||||
{
|
{
|
||||||
title: '操作',
|
label: '操作',
|
||||||
dataIndex: 'action',
|
prop: 'action',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
width: 80
|
width: 80
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '机构名',
|
label: '机构名',
|
||||||
dataIndex: 'name',
|
prop: 'name',
|
||||||
ellipsis: true
|
ellipsis: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '分类',
|
label: '分类',
|
||||||
dataIndex: 'category'
|
prop: 'category'
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
// 选中表格的表格common
|
// 选中表格的表格common
|
||||||
const selectedCommons = [
|
const selectedCommons = [
|
||||||
{
|
{
|
||||||
title: '操作',
|
label: '操作',
|
||||||
dataIndex: 'action',
|
prop: 'action',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
width: 80
|
width: 80
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '机构名',
|
label: '机构名',
|
||||||
dataIndex: 'name',
|
prop: 'name',
|
||||||
ellipsis: true
|
ellipsis: true
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
// 主表格的ref 名称
|
|
||||||
const table = ref()
|
|
||||||
// 选中表格的ref 名称
|
|
||||||
const selectedTable = ref()
|
|
||||||
const tableRecordNum = ref()
|
|
||||||
const searchFormState = ref({})
|
|
||||||
const searchFormRef = ref()
|
|
||||||
const cardLoading = ref(true)
|
|
||||||
const pageLoading = ref(false)
|
|
||||||
const selectedTableListLoading = ref(false)
|
|
||||||
// 替换treeNode 中 title,key,children
|
|
||||||
const treeFieldNames = { children: 'children', title: 'name', key: 'id' }
|
|
||||||
// 获取机构树数据
|
|
||||||
const treeData = ref()
|
|
||||||
// 默认展开二级树的节点id
|
|
||||||
const defaultExpandedKeys = ref([])
|
|
||||||
const emit = defineEmits({ onBack: null })
|
|
||||||
const tableData = ref([])
|
|
||||||
const selectedData = ref([])
|
|
||||||
const recordIds = ref()
|
|
||||||
const props = defineProps(['orgPageApi', 'orgTreeApi', 'radioModel', 'dataIsConverterFlw', 'checkedOrgListApi'])
|
|
||||||
// 是否是单选
|
|
||||||
const radioModel = props.radioModel || false
|
|
||||||
// 数据是否转换成工作流格式
|
|
||||||
const dataIsConverterFlw = props.dataIsConverterFlw || false
|
|
||||||
// 分页相关
|
|
||||||
const current = ref(0) // 当前页数
|
|
||||||
const pageSize = ref(20) // 每页条数
|
|
||||||
const total = ref(0) // 数据总数
|
|
||||||
|
|
||||||
// 打开弹框
|
// 主表格的ref 名称
|
||||||
const showOrgPlusModal = (ids) => {
|
const table = ref()
|
||||||
visible.value = true
|
// 选中表格的ref 名称
|
||||||
if (dataIsConverterFlw) {
|
const selectedTable = ref()
|
||||||
ids = goDataConverter(ids)
|
const tableRecordNum = ref()
|
||||||
}
|
const searchFormState = ref({})
|
||||||
recordIds.value = ids
|
const searchFormRef = ref()
|
||||||
if (props.orgTreeApi) {
|
const cardLoading = ref(true)
|
||||||
// 获取机构树
|
const pageLoading = ref(false)
|
||||||
props.orgTreeApi().then((data) => {
|
const selectedTableListLoading = ref(false)
|
||||||
cardLoading.value = false
|
//树状图数据配置
|
||||||
if (data !== null) {
|
const defaultProps = {
|
||||||
treeData.value = data
|
children: 'children',
|
||||||
// 默认展开2级
|
label: 'name'
|
||||||
treeData.value.forEach((item) => {
|
}
|
||||||
// 因为0的顶级
|
// 替换treeNode 中 title,key,children
|
||||||
if (item.parentId === '0') {
|
const treeFieldNames = { children: 'children', title: 'name', key: 'id' }
|
||||||
defaultExpandedKeys.value.push(item.id)
|
// 获取机构树数据
|
||||||
// 取到下级ID
|
const treeData = ref()
|
||||||
if (item.children) {
|
// 默认展开二级树的节点id
|
||||||
item.children.forEach((items) => {
|
const defaultExpandedKeys = ref([])
|
||||||
defaultExpandedKeys.value.push(items.id)
|
const emit = defineEmits({ onBack: null })
|
||||||
})
|
const tableData = ref([])
|
||||||
}
|
const selectedData = ref([])
|
||||||
}
|
const recordIds = ref()
|
||||||
})
|
const props = defineProps(['orgPageApi', 'orgTreeApi', 'radioModel', 'dataIsConverterFlw', 'checkedOrgListApi'])
|
||||||
}
|
// 是否是单选
|
||||||
})
|
const radioModel = props.radioModel || false
|
||||||
}
|
// 数据是否转换成工作流格式
|
||||||
searchFormState.value.size = pageSize.value
|
const dataIsConverterFlw = props.dataIsConverterFlw || false
|
||||||
loadData()
|
// 分页相关
|
||||||
if (props.checkedOrgListApi) {
|
const current = ref(0) // 当前页数
|
||||||
if (isEmpty(recordIds.value)) {
|
const pageSize = ref(20) // 每页条数
|
||||||
return
|
const total = ref(0) // 数据总数
|
||||||
}
|
|
||||||
const param = {
|
|
||||||
idList: recordIds.value
|
|
||||||
}
|
|
||||||
selectedTableListLoading.value = true
|
|
||||||
props
|
|
||||||
.checkedOrgListApi(param)
|
|
||||||
.then((data) => {
|
|
||||||
selectedData.value = data
|
|
||||||
})
|
|
||||||
.finally(() => {
|
|
||||||
selectedTableListLoading.value = false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// 查询主表格数据
|
|
||||||
const loadData = () => {
|
|
||||||
pageLoading.value = true
|
|
||||||
props
|
|
||||||
.orgPageApi(searchFormState.value)
|
|
||||||
.then((data) => {
|
|
||||||
current.value = data.current
|
|
||||||
total.value = data.total
|
|
||||||
// 重置、赋值
|
|
||||||
tableData.value = []
|
|
||||||
tableRecordNum.value = 0
|
|
||||||
tableData.value = data.records
|
|
||||||
if (data.records) {
|
|
||||||
tableRecordNum.value = data.records.length
|
|
||||||
} else {
|
|
||||||
tableRecordNum.value = 0
|
|
||||||
}
|
|
||||||
})
|
|
||||||
.finally(() => {
|
|
||||||
pageLoading.value = false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
// pageSize改变回调分页事件
|
|
||||||
const paginationChange = (page, pageSize) => {
|
|
||||||
searchFormState.value.current = page
|
|
||||||
searchFormState.value.size = pageSize
|
|
||||||
loadData()
|
|
||||||
}
|
|
||||||
const judge = () => {
|
|
||||||
if (radioModel && selectedData.value.length > 0) {
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
// 添加记录
|
|
||||||
const addRecord = (record) => {
|
|
||||||
if (!judge()) {
|
|
||||||
message.warning('只可选择一条')
|
|
||||||
return
|
|
||||||
}
|
|
||||||
const selectedRecord = selectedData.value.filter((item) => item.id === record.id)
|
|
||||||
if (selectedRecord.length === 0) {
|
|
||||||
selectedData.value.push(record)
|
|
||||||
} else {
|
|
||||||
message.warning('该记录已存在')
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// 添加全部
|
|
||||||
const addAllPageRecord = () => {
|
|
||||||
let newArray = selectedData.value.concat(tableData.value)
|
|
||||||
let list = []
|
|
||||||
for (let item1 of newArray) {
|
|
||||||
let flag = true
|
|
||||||
for (let item2 of list) {
|
|
||||||
if (item1.id === item2.id) {
|
|
||||||
flag = false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (flag) {
|
|
||||||
list.push(item1)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
selectedData.value = list
|
|
||||||
}
|
|
||||||
// 删减记录
|
|
||||||
const delRecord = (record) => {
|
|
||||||
remove(selectedData.value, (item) => item.id === record.id)
|
|
||||||
}
|
|
||||||
// 删减记录
|
|
||||||
const delAllRecord = () => {
|
|
||||||
selectedData.value = []
|
|
||||||
}
|
|
||||||
// 点击树查询
|
|
||||||
const treeSelect = (selectedKeys) => {
|
|
||||||
searchFormState.value.current = 0
|
|
||||||
if (selectedKeys.length > 0) {
|
|
||||||
searchFormState.value.orgId = selectedKeys.toString()
|
|
||||||
} else {
|
|
||||||
delete searchFormState.value.orgId
|
|
||||||
}
|
|
||||||
loadData()
|
|
||||||
}
|
|
||||||
// 确定
|
|
||||||
const handleOk = () => {
|
|
||||||
const value = []
|
|
||||||
selectedData.value.forEach((item) => {
|
|
||||||
const obj = {
|
|
||||||
id: item.id,
|
|
||||||
name: item.name,
|
|
||||||
category: item.category
|
|
||||||
}
|
|
||||||
value.push(obj)
|
|
||||||
})
|
|
||||||
// 判断是否做数据的转换为工作流需要的
|
|
||||||
if (dataIsConverterFlw) {
|
|
||||||
emit('onBack', outDataConverter(value))
|
|
||||||
} else {
|
|
||||||
emit('onBack', value)
|
|
||||||
}
|
|
||||||
handleClose()
|
|
||||||
}
|
|
||||||
// 重置
|
|
||||||
const reset = () => {
|
|
||||||
delete searchFormState.value.searchKey
|
|
||||||
loadData()
|
|
||||||
}
|
|
||||||
const handleClose = () => {
|
|
||||||
searchFormState.value = {}
|
|
||||||
tableRecordNum.value = 0
|
|
||||||
tableData.value = []
|
|
||||||
current.value = 0
|
|
||||||
pageSize.value = 20
|
|
||||||
total.value = 0
|
|
||||||
selectedData.value = []
|
|
||||||
visible.value = false
|
|
||||||
}
|
|
||||||
|
|
||||||
// 数据进入后转换
|
// 打开弹框
|
||||||
const goDataConverter = (data) => {
|
const showOrgPlusModal = ids => {
|
||||||
const resultData = []
|
visible.value = true
|
||||||
if (data.length > 0) {
|
if (dataIsConverterFlw) {
|
||||||
const values = data[0].value.split(',')
|
ids = goDataConverter(ids)
|
||||||
if (JSON.stringify(values) !== '[""]') {
|
}
|
||||||
for (let i = 0; i < values.length; i++) {
|
recordIds.value = ids
|
||||||
resultData.push(values[i])
|
if (props.orgTreeApi) {
|
||||||
}
|
// 获取机构树
|
||||||
}
|
props.orgTreeApi().then(data => {
|
||||||
}
|
cardLoading.value = false
|
||||||
return resultData
|
if (data !== null) {
|
||||||
}
|
console.log(data, 'data,++++++++++++')
|
||||||
// 数据出口转换器
|
treeData.value = data.data
|
||||||
const outDataConverter = (data) => {
|
// 默认展开2级
|
||||||
const obj = {}
|
treeData.value.forEach(item => {
|
||||||
let label = ''
|
// 因为0的顶级
|
||||||
let value = ''
|
if (item.parentId === '0') {
|
||||||
for (let i = 0; i < data.length; i++) {
|
defaultExpandedKeys.value.push(item.id)
|
||||||
if (data.length === i + 1) {
|
// 取到下级ID
|
||||||
label = label + data[i].name
|
if (item.children) {
|
||||||
value = value + data[i].id
|
item.children.forEach(items => {
|
||||||
} else {
|
defaultExpandedKeys.value.push(items.id)
|
||||||
label = label + data[i].name + ','
|
})
|
||||||
value = value + data[i].id + ','
|
}
|
||||||
}
|
}
|
||||||
}
|
})
|
||||||
obj.key = 'ORG'
|
}
|
||||||
obj.label = label
|
})
|
||||||
obj.value = value
|
}
|
||||||
obj.extJson = ''
|
searchFormState.value.size = pageSize.value
|
||||||
return obj
|
loadData()
|
||||||
}
|
if (props.checkedOrgListApi) {
|
||||||
defineExpose({
|
if (isEmpty(recordIds.value)) {
|
||||||
showOrgPlusModal
|
return
|
||||||
})
|
}
|
||||||
|
const param = {
|
||||||
|
idList: recordIds.value
|
||||||
|
}
|
||||||
|
selectedTableListLoading.value = true
|
||||||
|
props
|
||||||
|
.checkedOrgListApi(param)
|
||||||
|
.then(data => {
|
||||||
|
selectedData.value = data
|
||||||
|
})
|
||||||
|
.finally(() => {
|
||||||
|
selectedTableListLoading.value = false
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 查询主表格数据
|
||||||
|
const loadData = () => {
|
||||||
|
pageLoading.value = true
|
||||||
|
props
|
||||||
|
.orgPageApi(searchFormState.value)
|
||||||
|
.then(data => {
|
||||||
|
current.value = data.current
|
||||||
|
total.value = data.total
|
||||||
|
// 重置、赋值
|
||||||
|
tableData.value = []
|
||||||
|
tableRecordNum.value = 0
|
||||||
|
console.log(data, '999999999999')
|
||||||
|
tableData.value = data.data.records
|
||||||
|
if (data.records) {
|
||||||
|
tableRecordNum.value = data.data.records.length
|
||||||
|
} else {
|
||||||
|
tableRecordNum.value = 0
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.finally(() => {
|
||||||
|
pageLoading.value = false
|
||||||
|
})
|
||||||
|
}
|
||||||
|
// pageSize改变回调分页事件
|
||||||
|
const paginationChange = (page, pageSize) => {
|
||||||
|
searchFormState.value.current = page
|
||||||
|
searchFormState.value.size = pageSize
|
||||||
|
loadData()
|
||||||
|
}
|
||||||
|
const judge = () => {
|
||||||
|
if (radioModel && selectedData.value.length > 0) {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
// 添加记录
|
||||||
|
const addRecord = record => {
|
||||||
|
if (!judge()) {
|
||||||
|
message.warning('只可选择一条')
|
||||||
|
return
|
||||||
|
}
|
||||||
|
const selectedRecord = selectedData.value.filter(item => item.id === record.id)
|
||||||
|
if (selectedRecord.length === 0) {
|
||||||
|
selectedData.value.push(record)
|
||||||
|
} else {
|
||||||
|
message.warning('该记录已存在')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 添加全部
|
||||||
|
const addAllPageRecord = () => {
|
||||||
|
let newArray = selectedData.value.concat(tableData.value)
|
||||||
|
let list = []
|
||||||
|
for (let item1 of newArray) {
|
||||||
|
let flag = true
|
||||||
|
for (let item2 of list) {
|
||||||
|
if (item1.id === item2.id) {
|
||||||
|
flag = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (flag) {
|
||||||
|
list.push(item1)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
selectedData.value = list
|
||||||
|
}
|
||||||
|
// 删减记录
|
||||||
|
const delRecord = record => {
|
||||||
|
remove(selectedData.value, item => item.id === record.id)
|
||||||
|
}
|
||||||
|
// 删减记录
|
||||||
|
const delAllRecord = () => {
|
||||||
|
selectedData.value = []
|
||||||
|
}
|
||||||
|
// 点击树查询
|
||||||
|
const treeSelect = selectedKeys => {
|
||||||
|
console.log(selectedKeys.id, '111112222333')
|
||||||
|
searchFormState.value.current = 0
|
||||||
|
if (selectedKeys.id) {
|
||||||
|
searchFormState.value.orgId = selectedKeys.id.toString()
|
||||||
|
} else {
|
||||||
|
// delete searchFormState.value.orgId
|
||||||
|
delete searchFormState.value.orgId
|
||||||
|
}
|
||||||
|
loadData()
|
||||||
|
}
|
||||||
|
// 确定
|
||||||
|
const handleOk = () => {
|
||||||
|
const value = []
|
||||||
|
selectedData.value.forEach(item => {
|
||||||
|
const obj = {
|
||||||
|
id: item.id,
|
||||||
|
name: item.name,
|
||||||
|
category: item.category
|
||||||
|
}
|
||||||
|
value.push(obj)
|
||||||
|
})
|
||||||
|
// 判断是否做数据的转换为工作流需要的
|
||||||
|
if (dataIsConverterFlw) {
|
||||||
|
emit('onBack', outDataConverter(value))
|
||||||
|
} else {
|
||||||
|
emit('onBack', value)
|
||||||
|
}
|
||||||
|
handleClose()
|
||||||
|
}
|
||||||
|
// 重置
|
||||||
|
const reset = () => {
|
||||||
|
delete searchFormState.value.searchKey
|
||||||
|
loadData()
|
||||||
|
}
|
||||||
|
const handleClose = () => {
|
||||||
|
searchFormState.value = {}
|
||||||
|
tableRecordNum.value = 0
|
||||||
|
tableData.value = []
|
||||||
|
current.value = 0
|
||||||
|
pageSize.value = 20
|
||||||
|
total.value = 0
|
||||||
|
selectedData.value = []
|
||||||
|
visible.value = false
|
||||||
|
}
|
||||||
|
|
||||||
|
// 数据进入后转换
|
||||||
|
const goDataConverter = data => {
|
||||||
|
const resultData = []
|
||||||
|
if (data.length > 0) {
|
||||||
|
const values = data[0].value.split(',')
|
||||||
|
if (JSON.stringify(values) !== '[""]') {
|
||||||
|
for (let i = 0; i < values.length; i++) {
|
||||||
|
resultData.push(values[i])
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return resultData
|
||||||
|
}
|
||||||
|
// 数据出口转换器
|
||||||
|
const outDataConverter = data => {
|
||||||
|
const obj = {}
|
||||||
|
let label = ''
|
||||||
|
let value = ''
|
||||||
|
for (let i = 0; i < data.length; i++) {
|
||||||
|
if (data.length === i + 1) {
|
||||||
|
label = label + data[i].name
|
||||||
|
value = value + data[i].id
|
||||||
|
} else {
|
||||||
|
label = label + data[i].name + ','
|
||||||
|
value = value + data[i].id + ','
|
||||||
|
}
|
||||||
|
}
|
||||||
|
obj.key = 'ORG'
|
||||||
|
obj.label = label
|
||||||
|
obj.value = value
|
||||||
|
obj.extJson = ''
|
||||||
|
return obj
|
||||||
|
}
|
||||||
|
defineExpose({
|
||||||
|
showOrgPlusModal
|
||||||
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="less" scoped>
|
<style lang="scss" scoped>
|
||||||
.selectorTreeDiv {
|
.selectorTreeDiv {
|
||||||
max-height: 500px;
|
height: 500px;
|
||||||
overflow: auto;
|
overflow: auto;
|
||||||
|
}
|
||||||
|
.cardTag {
|
||||||
|
margin-left: 10px;
|
||||||
|
}
|
||||||
|
.primarySele {
|
||||||
|
margin-right: 10px;
|
||||||
|
}
|
||||||
|
.ant-form-item {
|
||||||
|
margin-bottom: 0 !important;
|
||||||
|
}
|
||||||
|
.org-table {
|
||||||
|
overflow: auto;
|
||||||
|
max-height: 450px;
|
||||||
|
}
|
||||||
|
.drawer_body {
|
||||||
|
width: 100%;
|
||||||
|
height: 350px;
|
||||||
|
}
|
||||||
|
.dialog-footer{
|
||||||
|
position:absolute;
|
||||||
|
right:10px;
|
||||||
|
bottom:10px;
|
||||||
|
z-index:2005;
|
||||||
|
}
|
||||||
|
.org_table_head,.org_table_heads{
|
||||||
|
width:100%;
|
||||||
|
height: 40px;
|
||||||
|
border: 1px solid #F0F0F0;
|
||||||
|
display:flex;
|
||||||
|
align-items:center;
|
||||||
|
justify-content: space-between;
|
||||||
|
padding:0 10px;
|
||||||
|
p{
|
||||||
|
font-size: 12px;
|
||||||
}
|
}
|
||||||
.cardTag {
|
.org_table_head_add,.org_table_head_delete{
|
||||||
margin-left: 10px;
|
width:100px;
|
||||||
|
height:24px;
|
||||||
|
font-size: 12px;
|
||||||
|
border:2px dashed #F0F0F0;
|
||||||
|
border-radius:2px;
|
||||||
|
cursor:pointer;
|
||||||
|
display:flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
}
|
}
|
||||||
.primarySele {
|
.org_table_head_add:hover{
|
||||||
margin-right: 10px;
|
border:2px dashed #3FA9FF;
|
||||||
|
color:#3FA9FF;
|
||||||
}
|
}
|
||||||
.ant-form-item {
|
.org_table_head_delete{
|
||||||
margin-bottom: 0 !important;
|
width:72px;
|
||||||
}
|
height:24px;
|
||||||
.org-table {
|
border:2px dashed #FF4D4F;
|
||||||
overflow: auto;
|
color:#FF4D4F;
|
||||||
max-height: 450px;
|
|
||||||
}
|
}
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<a-modal
|
<el-dialog
|
||||||
v-model:visible="visible"
|
v-model="visible"
|
||||||
title="职位选择"
|
title="职位选择"
|
||||||
:width="1000"
|
:width="1000"
|
||||||
:mask-closable="false"
|
:mask-closable="false"
|
||||||
@@ -8,41 +8,41 @@
|
|||||||
@ok="handleOk"
|
@ok="handleOk"
|
||||||
@cancel="handleClose"
|
@cancel="handleClose"
|
||||||
>
|
>
|
||||||
<a-row :gutter="10">
|
<el-row :gutter="10">
|
||||||
<a-col :span="7">
|
<el-col :span="7">
|
||||||
<a-card size="small" :loading="cardLoading" class="selectorTreeDiv">
|
<el-card size="small" :loading="cardLoading" class="selectorTreeDiv">
|
||||||
<a-tree
|
<el-tree
|
||||||
v-if="treeData"
|
v-if="treeData"
|
||||||
v-model:expandedKeys="defaultExpandedKeys"
|
v-model:expandedKeys="defaultExpandedKeys"
|
||||||
:tree-data="treeData"
|
:tree-data="treeData"
|
||||||
:field-names="treeFieldNames"
|
:field-names="treeFieldNames"
|
||||||
@select="treeSelect"
|
@node-click="treeSelect"
|
||||||
>
|
>
|
||||||
</a-tree>
|
</el-tree>
|
||||||
</a-card>
|
</el-card>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="11">
|
<el-col :span="11">
|
||||||
<div class="table-operator" style="margin-bottom: 10px">
|
<div class="table-operator" style="margin-bottom: 10px">
|
||||||
<a-form ref="searchFormRef" name="advanced_search" class="ant-advanced-search-form" :model="searchFormState">
|
<el-form ref="searchFormRef" name="advanced_search" class="ant-advanced-search-form" :model="searchFormState">
|
||||||
<a-row :gutter="24">
|
<el-row :gutter="24">
|
||||||
<a-col :span="12">
|
<el-col :span="12">
|
||||||
<a-form-item name="searchKey">
|
<el-form-item name="searchKey">
|
||||||
<a-input v-model:value="searchFormState.searchKey" placeholder="请输入职位名" />
|
<el-input v-model:value="searchFormState.searchKey" placeholder="请输入职位名" />
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="12">
|
<el-col :span="12">
|
||||||
<a-button type="primary" class="primarySele" @click="loadData()"> 查询 </a-button>
|
<el-button type="primary" class="primarySele" @click="loadData()"> 查询 </el-button>
|
||||||
<a-button class="snowy-buttom-left" @click="() => reset()"> 重置 </a-button>
|
<el-button class="snowy-buttom-left" @click="() => reset()"> 重置 </el-button>
|
||||||
</a-col>
|
</el-col>
|
||||||
</a-row>
|
</el-row>
|
||||||
</a-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
<div class="pos-table">
|
<div class="pos-table">
|
||||||
<a-table
|
<el-table
|
||||||
ref="table"
|
ref="table"
|
||||||
size="small"
|
size="small"
|
||||||
:columns="commons"
|
:columns="commons"
|
||||||
:data-source="tableData"
|
:datel="tableData"
|
||||||
:expand-row-by-click="true"
|
:expand-row-by-click="true"
|
||||||
:loading="pageLoading"
|
:loading="pageLoading"
|
||||||
bordered
|
bordered
|
||||||
@@ -51,20 +51,20 @@
|
|||||||
<template #title>
|
<template #title>
|
||||||
<span>待选择列表 {{ tableRecordNum }} 条</span>
|
<span>待选择列表 {{ tableRecordNum }} 条</span>
|
||||||
<div v-if="!radioModel" style="float: right">
|
<div v-if="!radioModel" style="float: right">
|
||||||
<a-button type="dashed" size="small" @click="addAllPageRecord">添加当前数据</a-button>
|
<el-button type="dashed" size="small" @click="addAllPageRecord">添加当前数据</el-button>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template #bodyCell="{ column, record }">
|
<template #bodyCell="{ column, record }">
|
||||||
<template v-if="column.dataIndex === 'action'">
|
<template v-if="column.dataIndex === 'action'">
|
||||||
<a-button type="dashed" size="small" @click="addRecord(record)">添加</a-button>
|
<el-button type="dashed" size="small" @click="addRecord(record)">添加</el-button>
|
||||||
</template>
|
</template>
|
||||||
<template v-if="column.dataIndex === 'category'">
|
<template v-if="column.dataIndex === 'category'">
|
||||||
{{ $TOOL.dictTypeData('POSITION_CATEGORY', record.category) }}
|
{{ $TOOL.dictTypeData('POSITION_CATEGORY', record.category) }}
|
||||||
</template>
|
</template>
|
||||||
</template>
|
</template>
|
||||||
</a-table>
|
</el-table>
|
||||||
<div class="mt-2">
|
<div class="mt-2">
|
||||||
<a-pagination
|
<el-pagination
|
||||||
v-if="!isEmpty(tableData)"
|
v-if="!isEmpty(tableData)"
|
||||||
v-model:current="current"
|
v-model:current="current"
|
||||||
v-model:page-size="pageSize"
|
v-model:page-size="pageSize"
|
||||||
@@ -75,14 +75,14 @@
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="6">
|
<el-col :span="6">
|
||||||
<div class="pos-table">
|
<div class="pos-table">
|
||||||
<a-table
|
<el-table
|
||||||
ref="selectedTable"
|
ref="selectedTable"
|
||||||
size="small"
|
size="small"
|
||||||
:columns="selectedCommons"
|
:columns="selectedCommons"
|
||||||
:data-source="selectedData"
|
:datel-source="selectedData"
|
||||||
:expand-row-by-click="true"
|
:expand-row-by-click="true"
|
||||||
:loading="selectedTableListLoading"
|
:loading="selectedTableListLoading"
|
||||||
bordered
|
bordered
|
||||||
@@ -90,19 +90,19 @@
|
|||||||
<template #title>
|
<template #title>
|
||||||
<span>已选择: {{ selectedData.length }}</span>
|
<span>已选择: {{ selectedData.length }}</span>
|
||||||
<div v-if="!radioModel" style="float: right">
|
<div v-if="!radioModel" style="float: right">
|
||||||
<a-button type="dashed" danger size="small" @click="delAllRecord">全部移除</a-button>
|
<el-button type="dashed" danger size="small" @click="delAllRecord">全部移除</el-button>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template #bodyCell="{ column, record }">
|
<template #bodyCell="{ column, record }">
|
||||||
<template v-if="column.dataIndex === 'action'">
|
<template v-if="column.dataIndex === 'action'">
|
||||||
<a-button type="dashed" danger size="small" @click="delRecord(record)">移除</a-button>
|
<el-button type="dashed" danger size="small" @click="delRecord(record)">移除</el-button>
|
||||||
</template>
|
</template>
|
||||||
</template>
|
</template>
|
||||||
</a-table>
|
</el-table>
|
||||||
</div>
|
</div>
|
||||||
</a-col>
|
</el-col>
|
||||||
</a-row>
|
</el-row>
|
||||||
</a-modal>
|
</el-dialog>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup name="posSelectorPlus">
|
<script setup name="posSelectorPlus">
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<a-modal
|
<el-dialog
|
||||||
v-model:visible="visible"
|
v-model="visible"
|
||||||
title="角色选择"
|
title="角色选择"
|
||||||
:width="1000"
|
:width="1000"
|
||||||
:mask-closable="false"
|
:mask-closable="false"
|
||||||
@@ -8,41 +8,41 @@
|
|||||||
@ok="handleOk"
|
@ok="handleOk"
|
||||||
@cancel="handleClose"
|
@cancel="handleClose"
|
||||||
>
|
>
|
||||||
<a-row :gutter="10">
|
<el-row :gutter="10">
|
||||||
<a-col :span="7">
|
<el-col :span="7">
|
||||||
<a-card size="small" :loading="cardLoading" class="selectorTreeDiv">
|
<el-card size="small" :loading="cardLoading" class="selectorTreeDiv">
|
||||||
<a-tree
|
<el-tree
|
||||||
v-if="treeData"
|
v-if="treeData"
|
||||||
v-model:expandedKeys="defaultExpandedKeys"
|
v-model:expandedKeys="defaultExpandedKeys"
|
||||||
:tree-data="treeData"
|
:data="treeData"
|
||||||
:field-names="treeFieldNames"
|
:field-names="treeFieldNames"
|
||||||
@select="treeSelect"
|
@select="treeSelect"
|
||||||
>
|
>
|
||||||
</a-tree>
|
</el-tree>
|
||||||
</a-card>
|
</el-card>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="11">
|
<el-col :span="11">
|
||||||
<div class="table-operator" style="margin-bottom: 10px">
|
<div class="table-operator" style="margin-bottom: 10px">
|
||||||
<a-form ref="searchFormRef" name="advanced_search" class="ant-advanced-search-form" :model="searchFormState">
|
<el-form ref="searchFormRef" name="advanced_search" class="ant-advanced-search-form" :model="searchFormState">
|
||||||
<a-row :gutter="24">
|
<el-row :gutter="24">
|
||||||
<a-col :span="12">
|
<el-col :span="12">
|
||||||
<a-form-item name="searchKey">
|
<el-form-item name="searchKey">
|
||||||
<a-input v-model:value="searchFormState.searchKey" placeholder="请输入角色名" />
|
<el-input v-model:value="searchFormState.searchKey" placeholder="请输入角色名" />
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="12">
|
<el-col :span="12">
|
||||||
<a-button type="primary" class="primarySele" @click="loadData()"> 查询 </a-button>
|
<el-button type="primary" class="primarySele" @click="loadData()"> 查询 </el-button>
|
||||||
<a-button class="snowy-buttom-left" @click="() => reset()"> 重置 </a-button>
|
<el-button class="snowy-buttom-left" @click="() => reset()"> 重置 </el-button>
|
||||||
</a-col>
|
</el-col>
|
||||||
</a-row>
|
</el-row>
|
||||||
</a-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
<div class="role-table">
|
<div class="role-table">
|
||||||
<a-table
|
<el-table
|
||||||
ref="table"
|
ref="table"
|
||||||
size="small"
|
size="small"
|
||||||
:columns="commons"
|
:columns="commons"
|
||||||
:data-source="tableData"
|
:data="tableData"
|
||||||
:expand-row-by-click="true"
|
:expand-row-by-click="true"
|
||||||
:loading="pageLoading"
|
:loading="pageLoading"
|
||||||
bordered
|
bordered
|
||||||
@@ -51,20 +51,20 @@
|
|||||||
<template #title>
|
<template #title>
|
||||||
<span>待选择列表 {{ tableRecordNum }} 条</span>
|
<span>待选择列表 {{ tableRecordNum }} 条</span>
|
||||||
<div v-if="!radioModel" style="float: right">
|
<div v-if="!radioModel" style="float: right">
|
||||||
<a-button type="dashed" size="small" @click="addAllPageRecord">添加当前数据</a-button>
|
<el-button type="dashed" size="small" @click="addAllPageRecord">添加当前数据</el-button>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template #bodyCell="{ column, record }">
|
<template #bodyCell="{ column, record }">
|
||||||
<template v-if="column.dataIndex === 'action'">
|
<template v-if="column.dataIndex === 'action'">
|
||||||
<a-button type="dashed" size="small" @click="addRecord(record)">添加</a-button>
|
<el-button type="dashed" size="small" @click="addRecord(record)">添加</el-button>
|
||||||
</template>
|
</template>
|
||||||
<template v-if="column.dataIndex === 'category'">
|
<template v-if="column.dataIndex === 'category'">
|
||||||
{{ $TOOL.dictTypeData('ROLE_CATEGORY', record.category) }}
|
{{ $TOOL.dictTypeData('ROLE_CATEGORY', record.category) }}
|
||||||
</template>
|
</template>
|
||||||
</template>
|
</template>
|
||||||
</a-table>
|
</el-table>
|
||||||
<div class="mt-2">
|
<div class="mt-2">
|
||||||
<a-pagination
|
<el-pagination
|
||||||
v-if="!isEmpty(tableData)"
|
v-if="!isEmpty(tableData)"
|
||||||
v-model:current="current"
|
v-model:current="current"
|
||||||
v-model:page-size="pageSize"
|
v-model:page-size="pageSize"
|
||||||
@@ -75,10 +75,10 @@
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="6">
|
<el-col :span="6">
|
||||||
<div class="role-table">
|
<div class="role-table">
|
||||||
<a-table
|
<el-table
|
||||||
ref="selectedTable"
|
ref="selectedTable"
|
||||||
size="small"
|
size="small"
|
||||||
:columns="selectedCommons"
|
:columns="selectedCommons"
|
||||||
@@ -90,19 +90,19 @@
|
|||||||
<template #title>
|
<template #title>
|
||||||
<span>已选择: {{ selectedData.length }}</span>
|
<span>已选择: {{ selectedData.length }}</span>
|
||||||
<div v-if="!radioModel" style="float: right">
|
<div v-if="!radioModel" style="float: right">
|
||||||
<a-button type="dashed" danger size="small" @click="delAllRecord">全部移除</a-button>
|
<el-button type="dashed" danger size="small" @click="delAllRecord">全部移除</el-button>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template #bodyCell="{ column, record }">
|
<template #bodyCell="{ column, record }">
|
||||||
<template v-if="column.dataIndex === 'action'">
|
<template v-if="column.dataIndex === 'action'">
|
||||||
<a-button type="dashed" danger size="small" @click="delRecord(record)">移除</a-button>
|
<el-button type="dashed" danger size="small" @click="delRecord(record)">移除</el-button>
|
||||||
</template>
|
</template>
|
||||||
</template>
|
</template>
|
||||||
</a-table>
|
</el-table>
|
||||||
</div>
|
</div>
|
||||||
</a-col>
|
</el-col>
|
||||||
</a-row>
|
</el-row>
|
||||||
</a-modal>
|
</el-dialog>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup name="roleSelectorPlus">
|
<script setup name="roleSelectorPlus">
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<a-modal
|
<el-dialog
|
||||||
v-model:visible="visible"
|
v-model="visible"
|
||||||
title="用户选择"
|
title="用户选择"
|
||||||
:width="1000"
|
:width="1000"
|
||||||
:mask-closable="false"
|
:mask-closable="false"
|
||||||
@@ -8,37 +8,37 @@
|
|||||||
@ok="handleOk"
|
@ok="handleOk"
|
||||||
@cancel="handleClose"
|
@cancel="handleClose"
|
||||||
>
|
>
|
||||||
<a-row :gutter="10">
|
<el-row :gutter="10">
|
||||||
<a-col :span="7">
|
<el-col :span="7">
|
||||||
<a-card size="small" :loading="cardLoading" class="selectorTreeDiv">
|
<el-card size="small" :loading="cardLoading" class="selectorTreeDiv">
|
||||||
<a-tree
|
<el-tree
|
||||||
v-if="treeData"
|
v-if="treeData"
|
||||||
v-model:expandedKeys="defaultExpandedKeys"
|
v-model:expandedKeys="defaultExpandedKeys"
|
||||||
:tree-data="treeData"
|
:data="treeData"
|
||||||
:field-names="treeFieldNames"
|
:field-names="treeFieldNames"
|
||||||
@select="treeSelect"
|
@node-click="treeSelect"
|
||||||
>
|
>
|
||||||
</a-tree>
|
</el-tree>
|
||||||
</a-card>
|
</el-card>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="11">
|
<el-col :span="11">
|
||||||
<div class="table-operator" style="margin-bottom: 10px">
|
<div class="table-operator" style="margin-bottom: 10px">
|
||||||
<a-form ref="searchFormRef" name="advanced_search" class="ant-advanced-search-form" :model="searchFormState">
|
<el-form ref="searchFormRef" name="advanced_search" class="ant-advanced-search-form" :model="searchFormState">
|
||||||
<a-row :gutter="24">
|
<el-row :gutter="24">
|
||||||
<a-col :span="12">
|
<el-col :span="12">
|
||||||
<a-form-item name="searchKey">
|
<el-form-item name="searchKey">
|
||||||
<a-input v-model:value="searchFormState.searchKey" placeholder="请输入用户名" />
|
<el-input v-model:value="searchFormState.searchKey" placeholder="请输入用户名" />
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="12">
|
<el-col :span="12">
|
||||||
<a-button type="primary" class="primarySele" @click="loadData()"> 查询 </a-button>
|
<el-button type="primary" class="primarySele" @click="loadData()"> 查询 </el-button>
|
||||||
<a-button class="snowy-buttom-left" @click="reset()"> 重置 </a-button>
|
<el-button class="snowy-buttom-left" @click="reset()"> 重置 </el-button>
|
||||||
</a-col>
|
</el-col>
|
||||||
</a-row>
|
</el-row>
|
||||||
</a-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
<div class="user-table">
|
<div class="user-table">
|
||||||
<a-table
|
<el-table
|
||||||
ref="table"
|
ref="table"
|
||||||
size="small"
|
size="small"
|
||||||
:columns="commons"
|
:columns="commons"
|
||||||
@@ -51,20 +51,20 @@
|
|||||||
<template #title>
|
<template #title>
|
||||||
<span>待选择列表 {{ tableRecordNum }} 条</span>
|
<span>待选择列表 {{ tableRecordNum }} 条</span>
|
||||||
<div v-if="!radioModel" style="float: right">
|
<div v-if="!radioModel" style="float: right">
|
||||||
<a-button type="dashed" size="small" @click="addAllPageRecord">添加当前数据</a-button>
|
<el-button type="dashed" size="small" @click="addAllPageRecord">添加当前数据</el-button>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template #bodyCell="{ column, record }">
|
<template #bodyCell="{ column, record }">
|
||||||
<template v-if="column.dataIndex === 'action'">
|
<template v-if="column.dataIndex === 'action'">
|
||||||
<a-button type="dashed" size="small" @click="addRecord(record)">添加</a-button>
|
<el-button type="dashed" size="small" @click="addRecord(record)">添加</el-button>
|
||||||
</template>
|
</template>
|
||||||
<template v-if="column.dataIndex === 'category'">
|
<template v-if="column.dataIndex === 'category'">
|
||||||
{{ $TOOL.dictTypeData('ROLE_CATEGORY', record.category) }}
|
{{ $TOOL.dictTypeData('ROLE_CATEGORY', record.category) }}
|
||||||
</template>
|
</template>
|
||||||
</template>
|
</template>
|
||||||
</a-table>
|
</el-table>
|
||||||
<div class="mt-2">
|
<div class="mt-2">
|
||||||
<a-pagination
|
<el-pagination
|
||||||
v-if="!isEmpty(tableData)"
|
v-if="!isEmpty(tableData)"
|
||||||
v-model:current="current"
|
v-model:current="current"
|
||||||
v-model:page-size="pageSize"
|
v-model:page-size="pageSize"
|
||||||
@@ -75,10 +75,10 @@
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="6">
|
<el-col :span="6">
|
||||||
<div class="user-table">
|
<div class="user-table">
|
||||||
<a-table
|
<el-table
|
||||||
ref="selectedTable"
|
ref="selectedTable"
|
||||||
size="small"
|
size="small"
|
||||||
:columns="selectedCommons"
|
:columns="selectedCommons"
|
||||||
@@ -90,19 +90,19 @@
|
|||||||
<template #title>
|
<template #title>
|
||||||
<span>已选择: {{ selectedData.length }}</span>
|
<span>已选择: {{ selectedData.length }}</span>
|
||||||
<div v-if="!radioModel" style="float: right">
|
<div v-if="!radioModel" style="float: right">
|
||||||
<a-button type="dashed" danger size="small" @click="delAllRecord">全部移除</a-button>
|
<el-button type="dashed" danger size="small" @click="delAllRecord">全部移除</el-button>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template #bodyCell="{ column, record }">
|
<template #bodyCell="{ column, record }">
|
||||||
<template v-if="column.dataIndex === 'action'">
|
<template v-if="column.dataIndex === 'action'">
|
||||||
<a-button type="dashed" danger size="small" @click="delRecord(record)">移除</a-button>
|
<el-button type="dashed" danger size="small" @click="delRecord(record)">移除</el-button>
|
||||||
</template>
|
</template>
|
||||||
</template>
|
</template>
|
||||||
</a-table>
|
</el-table>
|
||||||
</div>
|
</div>
|
||||||
</a-col>
|
</el-col>
|
||||||
</a-row>
|
</el-row>
|
||||||
</a-modal>
|
</el-dialog>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup name="userSelectorPlus">
|
<script setup name="userSelectorPlus">
|
||||||
@@ -186,7 +186,7 @@
|
|||||||
props.orgTreeApi().then((data) => {
|
props.orgTreeApi().then((data) => {
|
||||||
cardLoading.value = false
|
cardLoading.value = false
|
||||||
if (data !== null) {
|
if (data !== null) {
|
||||||
treeData.value = data
|
treeData.value = data.data
|
||||||
// 默认展开2级
|
// 默认展开2级
|
||||||
treeData.value.forEach((item) => {
|
treeData.value.forEach((item) => {
|
||||||
// 因为0的顶级
|
// 因为0的顶级
|
||||||
|
|||||||
@@ -1,47 +0,0 @@
|
|||||||
<template>
|
|
||||||
<el-dialog v-if="isModal" :visible="visible" @cancel="cancel" v-bind="$attrs">
|
|
||||||
<template v-for="slotKey in slotKeys" #[slotKey]>
|
|
||||||
<slot :name="slotKey" />
|
|
||||||
</template>
|
|
||||||
</el-dialog>
|
|
||||||
<el-drawer v-else :visible="visible" v-bind="$attrs" :footer-style="{ textAlign: 'right' }">
|
|
||||||
<template v-for="slotKey in slotKeys" #[slotKey]>
|
|
||||||
<slot :name="slotKey" />
|
|
||||||
</template>
|
|
||||||
</el-drawer>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import { mapState } from 'pinia'
|
|
||||||
import { globalStore } from '@/store'
|
|
||||||
|
|
||||||
const FormContainerTypeEnum = {
|
|
||||||
DRAWER: 'drawer',
|
|
||||||
MODAL: 'modal'
|
|
||||||
}
|
|
||||||
export default {
|
|
||||||
name: 'XnFormContainer',
|
|
||||||
inheritAttrs: false,
|
|
||||||
props: {
|
|
||||||
visible: {
|
|
||||||
type: Boolean,
|
|
||||||
default: false,
|
|
||||||
required: true
|
|
||||||
}
|
|
||||||
},
|
|
||||||
computed: {
|
|
||||||
...mapState(globalStore, ['formStyle']),
|
|
||||||
slotKeys() {
|
|
||||||
return Object.keys(this.$slots)
|
|
||||||
},
|
|
||||||
isModal() {
|
|
||||||
return FormContainerTypeEnum.MODAL === this.formStyle
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
cancel() {
|
|
||||||
this.$emit('close')
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-dialog v-model="dialogFormVisible" title="新增" width="500">
|
<el-dialog v-model="dialogFormVisible" title="新增" width="500" :append-to-body="true">
|
||||||
<el-form ref="formRef" :model="formData" :rules="formRules" label-width="140px" label-position="top">
|
<el-form ref="formRef" :model="formData" :rules="formRules" label-width="140px" label-position="top">
|
||||||
<el-form-item label="监听类型:" prop="listenerType">
|
<el-form-item label="监听类型:" prop="listenerType">
|
||||||
<el-select v-model="formData.listenerType" placeholder="请选择类型">
|
<el-select v-model="formData.listenerType" placeholder="请选择类型">
|
||||||
@@ -40,7 +40,7 @@ const props = defineProps({
|
|||||||
default: false
|
default: false
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
const emit=defineEmits(['close','addWacth'])
|
const emit = defineEmits(['close', 'addWacth'])
|
||||||
watch(
|
watch(
|
||||||
() => props.addFlag,
|
() => props.addFlag,
|
||||||
(val, oldVal) => {
|
(val, oldVal) => {
|
||||||
@@ -99,13 +99,22 @@ const listenerValueArray = reactive([
|
|||||||
}
|
}
|
||||||
])
|
])
|
||||||
//关闭
|
//关闭
|
||||||
async function handleClose(){
|
async function handleClose() {
|
||||||
emit("close")
|
emit('close')
|
||||||
}
|
}
|
||||||
//提交
|
//提交
|
||||||
async function handleAdd(){
|
const formRef = ref(null)
|
||||||
emit("addWatch",formData);
|
async function handleAdd() {
|
||||||
emit("close");
|
formRef.value.validate(valid => {
|
||||||
|
if (valid) {
|
||||||
|
console.log(valid)
|
||||||
|
emit("addWatch",formData);
|
||||||
|
emit("close");
|
||||||
|
} else {
|
||||||
|
console.log('error submit!')
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
console.log()
|
console.log()
|
||||||
@@ -115,9 +124,9 @@ onMounted(() => {
|
|||||||
.dialog-footer {
|
.dialog-footer {
|
||||||
padding: 20px 15px !important;
|
padding: 20px 15px !important;
|
||||||
}
|
}
|
||||||
.el-form{
|
.el-form {
|
||||||
width:96%;
|
width: 96%;
|
||||||
margin:0 auto;
|
margin: 0 auto;
|
||||||
margin-top:20px;
|
margin-top: 20px;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -7,8 +7,8 @@
|
|||||||
<div class="watchs_info">
|
<div class="watchs_info">
|
||||||
<el-button type="primary" :icon="Plus" size="small" @click="handleAdd">新增</el-button>
|
<el-button type="primary" :icon="Plus" size="small" @click="handleAdd">新增</el-button>
|
||||||
<el-table :data="tableData" border style="width: 100%" height="400">
|
<el-table :data="tableData" border style="width: 100%" height="400">
|
||||||
<el-table-column align="left" prop="listenerType" label="名称" width="180" />
|
<el-table-column align="left" prop="listenerType" label="名称" width="120" />
|
||||||
<el-table-column align="left" prop="javaClass" label="JAVA监听器" width="180" />
|
<el-table-column align="left" prop="javaClass" label="JAVA监听器"/>
|
||||||
<el-table-column align="left" fixed="right" label="操作" width="120">
|
<el-table-column align="left" fixed="right" label="操作" width="120">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button link type="danger" size="small" @click="handleDelete(scope.$index, scope.row)">删除</el-button>
|
<el-button link type="danger" size="small" @click="handleDelete(scope.$index, scope.row)">删除</el-button>
|
||||||
|
|||||||
@@ -25,29 +25,34 @@
|
|||||||
<!-- </el-button>-->
|
<!-- </el-button>-->
|
||||||
<!-- </el-tooltip>-->
|
<!-- </el-tooltip>-->
|
||||||
|
|
||||||
<el-tooltip class="box-item" effect="dark" content="配置流程全局属性" placement="top">
|
<el-tooltip class="box-item" effect="dark" content="配置流程全局属性" placement="top-start">
|
||||||
<el-button :icon="Setting" @click="drawerVisibile=true">
|
<el-button :icon="Setting" @click="drawerVisibile=true">
|
||||||
全局配置
|
全局配置
|
||||||
<template #icon>
|
<!-- <template #icon>
|
||||||
<Setting />
|
<Setting />
|
||||||
</template>
|
</template> -->
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-tooltip>
|
</el-tooltip>
|
||||||
</div>
|
</div>
|
||||||
<div class="box-scale">
|
<div class="box-scale">
|
||||||
<node-wrap
|
<!-- 展示流程图组件 -->
|
||||||
v-if="childNode"
|
<!-- {{ childNode }}{{ modelValue }}444{{ childRecordData }}
|
||||||
v-model="childNode.childNode"
|
节点111{{ childNode }} -->
|
||||||
:form-field-list-value="childFormFieldListValue"
|
<!-- {{ childRecordData }} -->
|
||||||
:record-data="childRecordData"
|
<node-wrap
|
||||||
:process-config-info="childNode.properties.configInfo"
|
v-if="childNode"
|
||||||
:execution-listener-array="executionListenerArray"
|
v-model="childNode.childNode"
|
||||||
:task-listener-array="taskListenerArray"
|
:form-field-list-value="childFormFieldListValue"
|
||||||
:selector-api-function="selectorApiFunction"
|
:record-data="childRecordData"
|
||||||
/>
|
:process-config-info="childNode.properties.configInfo"
|
||||||
|
:execution-listener-array="executionListenerArray"
|
||||||
|
:task-listener-array="taskListenerArray"
|
||||||
|
:selector-api-function="selectorApiFunction"
|
||||||
|
/>
|
||||||
|
<!-- <nodeWrap v-if="childNode" v-model="childNode.childNode" :currentActivityId="currentActivityId" /> -->
|
||||||
<div class="end-node">
|
<div class="end-node">
|
||||||
<div class="end-node-circle"></div>
|
<div class="end-node-circle"></div>
|
||||||
<div class="end-node-text">流程结束</div>
|
<div class="end-node-text">流程结束111</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<process
|
<process
|
||||||
@@ -76,7 +81,13 @@ export default {
|
|||||||
computed: {
|
computed: {
|
||||||
Plus() {
|
Plus() {
|
||||||
return Plus
|
return Plus
|
||||||
}
|
},
|
||||||
|
Setting(){
|
||||||
|
return Setting
|
||||||
|
},
|
||||||
|
Setting(){
|
||||||
|
return Warning
|
||||||
|
}
|
||||||
},
|
},
|
||||||
components: {
|
components: {
|
||||||
nodeWrap,
|
nodeWrap,
|
||||||
@@ -105,8 +116,13 @@ export default {
|
|||||||
childRecordData: this.recordData
|
childRecordData: this.recordData
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
mounted(){
|
||||||
|
|
||||||
|
console.log(this);
|
||||||
|
},
|
||||||
watch: {
|
watch: {
|
||||||
modelValue(val) {
|
modelValue(val) {
|
||||||
|
console.log(val,"9999999");
|
||||||
this.childNode = val
|
this.childNode = val
|
||||||
},
|
},
|
||||||
// 监听字段列表传输的相关动静
|
// 监听字段列表传输的相关动静
|
||||||
@@ -137,4 +153,9 @@ export default {
|
|||||||
|
|
||||||
<style lang="less">
|
<style lang="less">
|
||||||
@import './flowIndex.less';
|
@import './flowIndex.less';
|
||||||
|
.box-scale{
|
||||||
|
width: 100%;
|
||||||
|
height: calc(100vh - 150px);
|
||||||
|
overflow-y: auto;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -85,47 +85,36 @@
|
|||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script setup>
|
||||||
import startEvent from './nodes/startEvent.vue'
|
import StartEvent from './nodes/startEvent.vue'
|
||||||
import startTask from './nodes/startTask.vue'
|
import StartTask from './nodes/startTask.vue'
|
||||||
import userTask from './nodes/userTask.vue'
|
import UserTask from './nodes/userTask.vue'
|
||||||
import exclusiveGateway from './nodes/exclusiveGateway.vue'
|
import ExclusiveGateway from './nodes/exclusiveGateway.vue'
|
||||||
import parallelGateway from './nodes/parallelGateway.vue'
|
import ParallelGateway from './nodes/parallelGateway.vue'
|
||||||
import serviceTask from './nodes/serviceTask.vue'
|
import ServiceTask from './nodes/serviceTask.vue'
|
||||||
|
import {ref,watch} from 'vue'
|
||||||
export default {
|
const props = defineProps({
|
||||||
components: {
|
modelValue: { type: Object, default: () => {} },
|
||||||
startEvent,
|
formFieldListValue: { type: Array, default: () => [] },
|
||||||
startTask,
|
recordData: { type: Object, default: () => {} },
|
||||||
userTask,
|
processConfigInfo: { type: Object, default: () => {} },
|
||||||
exclusiveGateway,
|
executionListenerArray: { type: Array, default: () => [] },
|
||||||
parallelGateway,
|
taskListenerArray: { type: Array, default: () => [] },
|
||||||
serviceTask
|
selectorApiFunction: { type: Object, default: () => {} }
|
||||||
|
})
|
||||||
|
const emit = defineEmits(['update:modelValue'])
|
||||||
|
// 创建响应式引用
|
||||||
|
const childNode = ref({})
|
||||||
|
// 监听 props.modelValue 的变化,并同步到 childNode.value
|
||||||
|
watch(
|
||||||
|
() => props.modelValue,
|
||||||
|
(newValue) => {
|
||||||
|
childNode.value = newValue
|
||||||
},
|
},
|
||||||
props: {
|
{ immediate: true } // 立即执行一次监听器
|
||||||
modelValue: { type: Object, default: () => {} },
|
)
|
||||||
formFieldListValue: { type: Array, default: () => [] },
|
// 监听 childNode.value 的变化,并发出自定义事件 update:modelValue
|
||||||
recordData: { type: Object, default: () => {} },
|
watch(childNode, (newValue) => {
|
||||||
processConfigInfo: { type: Object, default: () => {} },
|
emit('update:modelValue', newValue)
|
||||||
executionListenerArray: { type: Array, default: () => [] },
|
})
|
||||||
taskListenerArray: { type: Array, default: () => [] },
|
|
||||||
selectorApiFunction: { type: Object, default: () => {} }
|
|
||||||
},
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
childNode: {}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
watch: {
|
|
||||||
modelValue(val) {
|
|
||||||
this.childNode = val
|
|
||||||
},
|
|
||||||
childNode(val) {
|
|
||||||
this.$emit('update:modelValue', val)
|
|
||||||
}
|
|
||||||
},
|
|
||||||
mounted() {
|
|
||||||
this.childNode = this.modelValue
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -1,152 +1,273 @@
|
|||||||
|
<!-- 添加节点组件 -->
|
||||||
<template>
|
<template>
|
||||||
<div class="add-node-btn-box">
|
<div class="add-node-btn-box">
|
||||||
<div class="add-node-btn">
|
<div class="add-node-btn">
|
||||||
<a-popover v-model:visible="visible" placement="rightTop" trigger="click" :width="270">
|
<el-popover placement="right" :width="280" trigger="click">
|
||||||
<template #content>
|
<template #reference>
|
||||||
<div class="add-node-popover-body">
|
<el-button type="primary" circle @click="addNodeButton" :icon="Plus"></el-button>
|
||||||
<ul style="height: 80px">
|
</template>
|
||||||
<li>
|
<div class="button_info">
|
||||||
<a-button shape="circle" size="large" @click="addType('userTask')">
|
<ul style="height: 80px">
|
||||||
<template #icon>
|
<li>
|
||||||
<user-outlined style="color: #ff943e; font-size: 18px" />
|
<el-button
|
||||||
</template>
|
size="large"
|
||||||
</a-button>
|
type="primary"
|
||||||
<p>审批节点</p>
|
:icon="UserFilled"
|
||||||
</li>
|
circle
|
||||||
<li>
|
@click="addType('userTask')"
|
||||||
<a-button shape="circle" size="large" @click="addType('serviceTask')">
|
></el-button>
|
||||||
<template #icon>
|
<p>审批节点</p>
|
||||||
<send-outlined style="color: #3296fa; font-size: 18px" />
|
</li>
|
||||||
</template>
|
<li>
|
||||||
</a-button>
|
<el-button
|
||||||
<p>抄送节点</p>
|
size="large"
|
||||||
</li>
|
type="warning"
|
||||||
<li v-if="addExclusiveGateway">
|
:icon="Promotion"
|
||||||
<a-button shape="circle" size="large" @click="addType('exclusiveGateway')">
|
circle
|
||||||
<template #icon>
|
@click="addType('serviceTask')"
|
||||||
<share-alt-outlined style="color: #15bc83; font-size: 18px" />
|
></el-button>
|
||||||
</template>
|
<p>抄送节点</p>
|
||||||
</a-button>
|
</li>
|
||||||
<p>条件分支</p>
|
<li v-if="addExclusiveGateway">
|
||||||
</li>
|
<el-button
|
||||||
<li v-if="addParallelGateway">
|
size="large"
|
||||||
<a-button shape="circle" size="large" @click="addType('parallelGateway')">
|
type="danger"
|
||||||
<template #icon>
|
:icon="Share"
|
||||||
<partition-outlined :rotate="180" style="color: #ac28f5; font-size: 18px" />
|
circle
|
||||||
</template>
|
@click="addType('exclusiveGateway')"
|
||||||
</a-button>
|
></el-button>
|
||||||
<p>并行分支</p>
|
<p>条件分支</p>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
<li v-if="addParallelGateway">
|
||||||
</div>
|
<el-button
|
||||||
</template>
|
size="large"
|
||||||
<a-button type="primary" shape="circle">
|
type="success"
|
||||||
<!-- @click="addNodeButton" -->
|
:icon="Operation"
|
||||||
<template #icon><plus-outlined /></template>
|
circle
|
||||||
</a-button>
|
@click="addType('parallelGateway')"
|
||||||
</a-popover>
|
></el-button>
|
||||||
</div>
|
<p>并行分支</p>
|
||||||
</div>
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</el-popover>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
<!-- <script>
|
||||||
|
import { cloneDeep } from 'lodash-es'
|
||||||
|
import config from '@/components/XnWorkflow/nodes/config/config'
|
||||||
|
const NodeTitleMap = {
|
||||||
|
userTask: '审核人',
|
||||||
|
serviceTask: '抄送人',
|
||||||
|
exclusiveGateway: '条件路由',
|
||||||
|
parallelGateway: '并行路由'
|
||||||
|
}
|
||||||
|
export default {
|
||||||
|
props: {
|
||||||
|
modelValue: { type: Object, default: () => {} },
|
||||||
|
parentData: { type: Object, default: () => {} },
|
||||||
|
nodeItem: { type: Object, default: () => {} }
|
||||||
|
},
|
||||||
|
emits: ['update:modelValue'],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
visible: true,
|
||||||
|
addExclusiveGateway: true,
|
||||||
|
addParallelGateway: true
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted() {},
|
||||||
|
methods: {
|
||||||
|
addNodeButton() {
|
||||||
|
// 他的上级是条件分支或并行分支,将其不在添加 // 控制节点下面
|
||||||
|
if (!this.parentData) {
|
||||||
|
this.disabledChildren()
|
||||||
|
} else {
|
||||||
|
if (this.parentData.type === 'exclusiveGateway' || this.parentData.type === 'parallelGateway') {
|
||||||
|
this.addExclusiveGateway = false
|
||||||
|
this.addParallelGateway = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
disabledChildren() {
|
||||||
|
// 如果下级是条件分支或并行分支,将其不在添加 // 控制节点上面
|
||||||
|
if (this.modelValue && this.modelValue.type) {
|
||||||
|
if (this.modelValue.type === 'exclusiveGateway' || this.modelValue.type === 'parallelGateway') {
|
||||||
|
this.addExclusiveGateway = false
|
||||||
|
this.addParallelGateway = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 不管其他的,如果是条件分支的项,那么他的下面无法添加条件
|
||||||
|
if (this.nodeItem) {
|
||||||
|
this.addExclusiveGateway = false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
getBaseCondition(type, title) {
|
||||||
|
const condition = cloneDeep(config.nodeModel.node)
|
||||||
|
condition.id = this.$TOOL.snowyUuid()
|
||||||
|
condition.type = type
|
||||||
|
condition.title = title
|
||||||
|
return condition
|
||||||
|
},
|
||||||
|
addType(type) {
|
||||||
|
const nodeModel = this.getBaseCondition(type, NodeTitleMap[type]) || {}
|
||||||
|
nodeModel.childNode = this.modelValue
|
||||||
|
if (type === 'userTask') {
|
||||||
|
// 创建 configInfo
|
||||||
|
const configInfo = cloneDeep(config.nodeConfigInfo.userTaskConfigInfo)
|
||||||
|
nodeModel.properties.configInfo = configInfo
|
||||||
|
} else if (type === 'exclusiveGateway') {
|
||||||
|
nodeModel.dataLegal = true
|
||||||
|
// 创建分支节点1
|
||||||
|
const condition1 = this.getBaseCondition('sequenceFlow', '条件1')
|
||||||
|
// 创建分支节点1 configInfo
|
||||||
|
const condition1ConfigInfo1 = cloneDeep(config.nodeConfigInfo.conditionConfigInfo)
|
||||||
|
condition1ConfigInfo1.priorityLevel = 1
|
||||||
|
condition1.properties.configInfo = condition1ConfigInfo1
|
||||||
|
// 创建分支节点2
|
||||||
|
const condition2 = this.getBaseCondition('sequenceFlow', '条件2')
|
||||||
|
// 创建分支节点2 configInfo
|
||||||
|
const condition1ConfigInfo2 = cloneDeep(config.nodeConfigInfo.conditionConfigInfo)
|
||||||
|
condition1ConfigInfo2.priorityLevel = 2
|
||||||
|
condition2.properties.configInfo = condition1ConfigInfo2
|
||||||
|
// 装进去
|
||||||
|
nodeModel.conditionNodeList.push(condition1)
|
||||||
|
nodeModel.conditionNodeList.push(condition2)
|
||||||
|
} else if (type === 'parallelGateway') {
|
||||||
|
// 创建主节点
|
||||||
|
nodeModel.dataLegal = true
|
||||||
|
// 创建分支节点1
|
||||||
|
const condition1 = this.getBaseCondition('userTask', '审批人1')
|
||||||
|
condition1.properties.configInfo = cloneDeep(config.nodeConfigInfo.userTaskConfigInfo)
|
||||||
|
condition1.dataLegal = true
|
||||||
|
// 创建分支节点2
|
||||||
|
const condition2 = this.getBaseCondition('userTask', '审批人2')
|
||||||
|
condition2.properties.configInfo = cloneDeep(config.nodeConfigInfo.userTaskConfigInfo)
|
||||||
|
condition2.dataLegal = true
|
||||||
|
// 装进去
|
||||||
|
nodeModel.conditionNodeList.push(condition1)
|
||||||
|
nodeModel.conditionNodeList.push(condition2)
|
||||||
|
}
|
||||||
|
this.visible = true
|
||||||
|
this.$emit('update:modelValue', nodeModel)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
<script>
|
</script> -->
|
||||||
import { cloneDeep } from 'lodash-es'
|
|
||||||
|
<script setup>
|
||||||
|
import { Plus, UserFilled, Promotion, Share, Operation } from '@element-plus/icons-vue';
|
||||||
|
import {ref,nextTick} from 'vue'
|
||||||
|
import { cloneDeep } from 'lodash-es'
|
||||||
import config from '@/components/XnWorkflow/nodes/config/config'
|
import config from '@/components/XnWorkflow/nodes/config/config'
|
||||||
|
import tool from '@/utils/tool'
|
||||||
const NodeTitleMap = {
|
const NodeTitleMap = {
|
||||||
userTask: '审核人',
|
userTask: '审核人',
|
||||||
serviceTask: '抄送人',
|
serviceTask: '抄送人',
|
||||||
exclusiveGateway: '条件路由',
|
exclusiveGateway: '条件路由',
|
||||||
parallelGateway: '并行路由'
|
parallelGateway: '并行路由'
|
||||||
}
|
}
|
||||||
export default {
|
const props = defineProps({
|
||||||
props: {
|
modelValue: { type: Object, default: () => {} },
|
||||||
modelValue: { type: Object, default: () => {} },
|
parentData: { type: Object, default: () => {} },
|
||||||
parentData: { type: Object, default: () => {} },
|
nodeItem: { type: Object, default: () => {} }
|
||||||
nodeItem: { type: Object, default: () => {} }
|
})
|
||||||
},
|
const emit = defineEmits(['update:modelValue'])
|
||||||
emits: ['update:modelValue'],
|
const visible = ref(false)
|
||||||
data() {
|
const addExclusiveGateway = ref(true)
|
||||||
return {
|
const addParallelGateway = ref(true)
|
||||||
visible: false,
|
const addNodeButton = () => {
|
||||||
addExclusiveGateway: true,
|
// 他的上级是条件分支或并行分支,将其不在添加 // 控制节点下面
|
||||||
addParallelGateway: true
|
if (!props.parentData) {
|
||||||
}
|
disabledChildren()
|
||||||
},
|
} else {
|
||||||
mounted() {},
|
if (props.parentData.type === 'exclusiveGateway' || props.parentData.type === 'parallelGateway') {
|
||||||
methods: {
|
addExclusiveGateway.value = false
|
||||||
addNodeButton() {
|
addParallelGateway.value = false
|
||||||
// 他的上级是条件分支或并行分支,将其不在添加 // 控制节点下面
|
|
||||||
if (!this.parentData) {
|
|
||||||
this.disabledChildren()
|
|
||||||
} else {
|
|
||||||
if (this.parentData.type === 'exclusiveGateway' || this.parentData.type === 'parallelGateway') {
|
|
||||||
this.addExclusiveGateway = false
|
|
||||||
this.addParallelGateway = false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
disabledChildren() {
|
|
||||||
// 如果下级是条件分支或并行分支,将其不在添加 // 控制节点上面
|
|
||||||
if (this.modelValue && this.modelValue.type) {
|
|
||||||
if (this.modelValue.type === 'exclusiveGateway' || this.modelValue.type === 'parallelGateway') {
|
|
||||||
this.addExclusiveGateway = false
|
|
||||||
this.addParallelGateway = false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// 不管其他的,如果是条件分支的项,那么他的下面无法添加条件
|
|
||||||
if (this.nodeItem) {
|
|
||||||
this.addExclusiveGateway = false
|
|
||||||
}
|
|
||||||
},
|
|
||||||
getBaseCondition(type, title) {
|
|
||||||
const condition = cloneDeep(config.nodeModel.node)
|
|
||||||
condition.id = this.$TOOL.snowyUuid()
|
|
||||||
condition.type = type
|
|
||||||
condition.title = title
|
|
||||||
return condition
|
|
||||||
},
|
|
||||||
addType(type) {
|
|
||||||
const nodeModel = this.getBaseCondition(type, NodeTitleMap[type]) || {}
|
|
||||||
nodeModel.childNode = this.modelValue
|
|
||||||
if (type === 'userTask') {
|
|
||||||
// 创建 configInfo
|
|
||||||
const configInfo = cloneDeep(config.nodeConfigInfo.userTaskConfigInfo)
|
|
||||||
nodeModel.properties.configInfo = configInfo
|
|
||||||
} else if (type === 'exclusiveGateway') {
|
|
||||||
nodeModel.dataLegal = true
|
|
||||||
// 创建分支节点1
|
|
||||||
const condition1 = this.getBaseCondition('sequenceFlow', '条件1')
|
|
||||||
// 创建分支节点1 configInfo
|
|
||||||
const condition1ConfigInfo1 = cloneDeep(config.nodeConfigInfo.conditionConfigInfo)
|
|
||||||
condition1ConfigInfo1.priorityLevel = 1
|
|
||||||
condition1.properties.configInfo = condition1ConfigInfo1
|
|
||||||
// 创建分支节点2
|
|
||||||
const condition2 = this.getBaseCondition('sequenceFlow', '条件2')
|
|
||||||
// 创建分支节点2 configInfo
|
|
||||||
const condition1ConfigInfo2 = cloneDeep(config.nodeConfigInfo.conditionConfigInfo)
|
|
||||||
condition1ConfigInfo2.priorityLevel = 2
|
|
||||||
condition2.properties.configInfo = condition1ConfigInfo2
|
|
||||||
// 装进去
|
|
||||||
nodeModel.conditionNodeList.push(condition1)
|
|
||||||
nodeModel.conditionNodeList.push(condition2)
|
|
||||||
} else if (type === 'parallelGateway') {
|
|
||||||
// 创建主节点
|
|
||||||
nodeModel.dataLegal = true
|
|
||||||
// 创建分支节点1
|
|
||||||
const condition1 = this.getBaseCondition('userTask', '审批人1')
|
|
||||||
condition1.properties.configInfo = cloneDeep(config.nodeConfigInfo.userTaskConfigInfo)
|
|
||||||
condition1.dataLegal = true
|
|
||||||
// 创建分支节点2
|
|
||||||
const condition2 = this.getBaseCondition('userTask', '审批人2')
|
|
||||||
condition2.properties.configInfo = cloneDeep(config.nodeConfigInfo.userTaskConfigInfo)
|
|
||||||
condition2.dataLegal = true
|
|
||||||
// 装进去
|
|
||||||
nodeModel.conditionNodeList.push(condition1)
|
|
||||||
nodeModel.conditionNodeList.push(condition2)
|
|
||||||
}
|
|
||||||
this.visible = false
|
|
||||||
this.$emit('update:modelValue', nodeModel)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
const disabledChildren = () => {
|
||||||
|
// 如果下级是条件分支或并行分支,将其不在添加 // 控制节点上面
|
||||||
|
if (props.modelValue && props.modelValue.type) {
|
||||||
|
if (props.modelValue.type === 'exclusiveGateway' || props.modelValue.type === 'parallelGateway') {
|
||||||
|
addExclusiveGateway.value = false
|
||||||
|
addParallelGateway.value = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 不管其他的,如果是条件分支的项,那么他的下面无法添加条件
|
||||||
|
if (props.nodeItem) {
|
||||||
|
addExclusiveGateway.value = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
const getBaseCondition = (type, title) => {
|
||||||
|
const condition = cloneDeep(config.nodeModel.node)
|
||||||
|
condition.id = tool.snowyUuid()
|
||||||
|
condition.type = type
|
||||||
|
condition.title = title
|
||||||
|
return condition
|
||||||
|
}
|
||||||
|
const addType = (type) => {
|
||||||
|
const nodeModel = getBaseCondition(type, NodeTitleMap[type]) || {}
|
||||||
|
nodeModel.childNode = props.modelValue
|
||||||
|
if (type === 'userTask') {
|
||||||
|
// 创建 configInfo
|
||||||
|
nodeModel.properties.configInfo = cloneDeep(config.nodeConfigInfo.userTaskConfigInfo)
|
||||||
|
} else if (type === 'exclusiveGateway') {
|
||||||
|
nodeModel.dataLegal = true
|
||||||
|
// 创建分支节点1
|
||||||
|
const condition1 = getBaseCondition('sequenceFlow', '条件1')
|
||||||
|
// 创建分支节点1 configInfo
|
||||||
|
const condition1ConfigInfo1 = cloneDeep(config.nodeConfigInfo.conditionConfigInfo)
|
||||||
|
condition1ConfigInfo1.priorityLevel = 1
|
||||||
|
condition1.properties.configInfo = condition1ConfigInfo1
|
||||||
|
// 创建分支节点2
|
||||||
|
const condition2 = getBaseCondition('sequenceFlow', '条件2')
|
||||||
|
// 创建分支节点2 configInfo
|
||||||
|
const condition1ConfigInfo2 = cloneDeep(config.nodeConfigInfo.conditionConfigInfo)
|
||||||
|
condition1ConfigInfo2.priorityLevel = 2
|
||||||
|
condition2.properties.configInfo = condition1ConfigInfo2
|
||||||
|
// 装进去
|
||||||
|
nodeModel.conditionNodeList.push(condition1)
|
||||||
|
nodeModel.conditionNodeList.push(condition2)
|
||||||
|
} else if (type === 'parallelGateway') {
|
||||||
|
// 创建主节点
|
||||||
|
nodeModel.dataLegal = true
|
||||||
|
// 创建分支节点1
|
||||||
|
const condition1 = getBaseCondition('userTask', '审批人1')
|
||||||
|
condition1.properties.configInfo = cloneDeep(config.nodeConfigInfo.userTaskConfigInfo)
|
||||||
|
condition1.dataLegal = true
|
||||||
|
// 创建分支节点2
|
||||||
|
const condition2 = getBaseCondition('userTask', '审批人2')
|
||||||
|
condition2.properties.configInfo = cloneDeep(config.nodeConfigInfo.userTaskConfigInfo)
|
||||||
|
condition2.dataLegal = true
|
||||||
|
// 装进去
|
||||||
|
nodeModel.conditionNodeList.push(condition1)
|
||||||
|
nodeModel.conditionNodeList.push(condition2)
|
||||||
|
}
|
||||||
|
visible.value = false
|
||||||
|
emit('update:modelValue', nodeModel)
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.button_info{
|
||||||
|
width:100%;
|
||||||
|
ul{
|
||||||
|
width:100%;
|
||||||
|
display:flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
li{
|
||||||
|
list-style: none;
|
||||||
|
p{
|
||||||
|
font-size: 12px;
|
||||||
|
text-align: center;
|
||||||
|
margin-top: 10px;
|
||||||
|
font-weight: 800;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|||||||
@@ -1,42 +1,42 @@
|
|||||||
<template>
|
<template>
|
||||||
<a-modal
|
<el-dialog
|
||||||
title="预览"
|
title="预览"
|
||||||
:width="700"
|
:width="700"
|
||||||
:visible="visible"
|
v-model="visible"
|
||||||
:destroy-on-close="true"
|
:destroy-on-close="true"
|
||||||
:footer-style="{ textAlign: 'right' }"
|
:footer-style="{ textAlign: 'right' }"
|
||||||
:mask="false"
|
:mask="false"
|
||||||
:confirmLoading="confirmLoading"
|
:confirmLoading="confirmLoading"
|
||||||
@ok="onSubmit"
|
@ok="onSubmit"
|
||||||
@cancel="onClose"
|
@cancel="onClose"
|
||||||
>
|
>
|
||||||
<component ref="customFormRef" :is="customFormsLayouts" />
|
<component ref="customFormRef" :is="customFormsLayouts" />
|
||||||
</a-modal>
|
</el-dialog>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup name="previewCustomForm">
|
<script setup name="previewCustomForm">
|
||||||
import { ElMessage } from 'element-plus'
|
import { ElMessage } from 'element-plus'
|
||||||
import { loadComponent } from '../../customForm'
|
import { loadComponent } from '../../customForm'
|
||||||
import { ref } from 'vue'
|
import { ref } from 'vue'
|
||||||
const visible = ref(false)
|
const visible = ref(false)
|
||||||
const confirmLoading = ref(false)
|
const confirmLoading = ref(false)
|
||||||
const customFormRef = ref()
|
const customFormRef = ref()
|
||||||
const customFormsLayouts = ref()
|
const customFormsLayouts = ref()
|
||||||
const onOpen = (url) => {
|
const onOpen = url => {
|
||||||
if (url) {
|
if (url) {
|
||||||
visible.value = true
|
visible.value = true
|
||||||
customFormsLayouts.value = loadComponent(url)
|
customFormsLayouts.value = loadComponent(url)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
const onSubmit = () => {
|
const onSubmit = () => {
|
||||||
customFormRef.value.getData().then((value) => {
|
customFormRef.value.getData().then(value => {
|
||||||
message.info(JSON.stringify(value))
|
message.info(JSON.stringify(value))
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
const onClose = () => {
|
const onClose = () => {
|
||||||
visible.value = false
|
visible.value = false
|
||||||
}
|
}
|
||||||
defineExpose({
|
defineExpose({
|
||||||
onOpen
|
onOpen
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -1,189 +1,214 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="branch-wrap">
|
<div class="branch-wrap">
|
||||||
<div class="branch-box-wrap">
|
<div class="branch-box-wrap">
|
||||||
<div class="branch-box">
|
<div class="branch-box">
|
||||||
<a-button class="add-branch" type="primary" shape="round" @click="addTerm"> 添加条件 </a-button>
|
<el-button class="add-branch" type="primary" shape="round" @click="addTerm">添加条件</el-button>
|
||||||
<div v-for="(item, index) in childNode.conditionNodeList" :key="index" class="col-box">
|
<div v-for="(item, index) in childNode.conditionNodeList" :key="index" class="col-box">
|
||||||
<div class="condition-node">
|
<div class="condition-node">
|
||||||
<div class="condition-node-box">
|
<div class="condition-node-box">
|
||||||
<div class="auto-judge" @click="show(index)">
|
<div class="auto-judge" @click="show(index)">
|
||||||
<div v-if="index != 0" class="sort-left" @click.stop="arrTransfer(index, -1)">
|
<div v-if="index != 0" class="sort-left" @click.stop="arrTransfer(index, -1)">
|
||||||
<left-outlined />
|
<left-outlined />
|
||||||
</div>
|
</div>
|
||||||
<div class="title">
|
<div class="title">
|
||||||
<span class="node-title">{{ item.title }}</span>
|
<span class="node-title">{{ item.title }}</span>
|
||||||
<span class="priority-title">优先级{{ item.properties.configInfo.priorityLevel }}</span>
|
<span class="priority-title">
|
||||||
<close-outlined class="close" @click.stop="delTerm(index)" />
|
优先级{{ item.properties.configInfo.priorityLevel }}
|
||||||
</div>
|
</span>
|
||||||
<div class="content">
|
<close-outlined class="close" @click.stop="delTerm(index)" />
|
||||||
<span v-if="toText(childNode, index)">{{ toText(childNode, index) }}</span>
|
</div>
|
||||||
<span v-else class="placeholder">请设置条件</span>
|
<div class="content">
|
||||||
</div>
|
<span v-if="toText(childNode, index)">{{ toText(childNode, index) }}</span>
|
||||||
<div
|
<span v-else class="placeholder">请设置条件</span>
|
||||||
v-if="index !== childNode.conditionNodeList.length - 1"
|
</div>
|
||||||
class="sort-right"
|
<div
|
||||||
@click.stop="arrTransfer(index)"
|
v-if="index !== childNode.conditionNodeList.length - 1"
|
||||||
>
|
class="sort-right"
|
||||||
<right-outlined />
|
@click.stop="arrTransfer(index)"
|
||||||
</div>
|
>
|
||||||
</div>
|
<right-outlined />
|
||||||
<add-node v-model="item.childNode" :node-item="item" />
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
<add-node v-model="item.childNode" :node-item="item" />
|
||||||
<slot v-if="item.childNode" :node="item" />
|
</div>
|
||||||
<div v-if="index === 0" class="top-left-cover-line" />
|
</div>
|
||||||
<div v-if="index === 0" class="bottom-left-cover-line" />
|
<slot v-if="item.childNode" :node="item" />
|
||||||
<div v-if="index === childNode.conditionNodeList.length - 1" class="top-right-cover-line" />
|
<div v-if="index === 0" class="top-left-cover-line" />
|
||||||
<div v-if="index === childNode.conditionNodeList.length - 1" class="bottom-right-cover-line" />
|
<div v-if="index === 0" class="bottom-left-cover-line" />
|
||||||
</div>
|
<div v-if="index === childNode.conditionNodeList.length - 1" class="top-right-cover-line" />
|
||||||
</div>
|
<div v-if="index === childNode.conditionNodeList.length - 1" class="bottom-right-cover-line" />
|
||||||
<add-node v-model="childNode.childNode" :parent-data="childNode" />
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<add-node v-model="childNode.childNode" :parent-data="childNode" />
|
||||||
|
</div>
|
||||||
|
|
||||||
<xn-form-container
|
<xn-form-container
|
||||||
v-model:visible="drawer"
|
v-model:visible="drawer"
|
||||||
:destroy-on-close="true"
|
:destroy-on-close="true"
|
||||||
:width="700"
|
:width="700"
|
||||||
:body-style="{ 'padding-top': '0px' }"
|
:body-style="{ 'padding-top': '0px' }"
|
||||||
>
|
>
|
||||||
<template #title>
|
<template #title>
|
||||||
<div class="node-wrap-drawer__title">
|
<div class="node-wrap-drawer__title">
|
||||||
<label v-if="!isEditTitle" @click="editTitle">
|
<label v-if="!isEditTitle" @click="editTitle">
|
||||||
{{ form.title }}
|
{{ form.title }}
|
||||||
<edit-outlined class="node-wrap-drawer-title-edit" />
|
<edit-outlined class="node-wrap-drawer-title-edit" />
|
||||||
</label>
|
</label>
|
||||||
<a-input
|
<el-input
|
||||||
v-if="isEditTitle"
|
v-if="isEditTitle"
|
||||||
ref="nodeTitle"
|
ref="nodeTitle"
|
||||||
v-model:value="form.title"
|
v-model="form.title"
|
||||||
allow-clear
|
allow-clear
|
||||||
@blur="saveTitle"
|
@blur="saveTitle"
|
||||||
@keyup.enter="saveTitle"
|
@keyup.enter="saveTitle"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<a-layout-content>
|
<el-layout-content>
|
||||||
<a-tabs v-model:activeKey="activeKey">
|
<el-tabs v-model="activeKey">
|
||||||
<a-tab-pane key="1" tab="条件配置" force-render>
|
<el-tab-pane name="1" label="条件配置" lazy>
|
||||||
<a-form layout="vertical">
|
<el-form layout="vertical">
|
||||||
<div v-show="!isNodeLegal(form)" style="margin-bottom: 10px">
|
<div v-show="!isNodeLegal(form)" style="margin-bottom: 10px">
|
||||||
<a-alert message="请填写完成所有项!" type="error" />
|
<el-alert message="请填写完成所有项!" type="error" />
|
||||||
</div>
|
</div>
|
||||||
<div class="mb-2">
|
<div class="mb-2">
|
||||||
<span class="left-span-label">配置要执行的条件</span>
|
<span class="left-span-label">配置要执行的条件</span>
|
||||||
</div>
|
</div>
|
||||||
<p style="margin-bottom: 2px">
|
<p style="margin-bottom: 2px">
|
||||||
<a-button type="primary" round @click="addDynamicValidateForm" size="small">
|
<el-button type="primary" round @click="addDynamicValidateForm" size="small">
|
||||||
<plus-outlined />
|
<plus-outlined />
|
||||||
增加条件组
|
增加条件组
|
||||||
</a-button>
|
</el-button>
|
||||||
</p>
|
</p>
|
||||||
<a-form-item v-for="(domain, index) in dynamicValidateForm" :key="index">
|
<el-form-item v-for="(domain, index) in dynamicValidateForm" :key="index">
|
||||||
<a-divider style="margin: 10px 0" />
|
<el-divider style="margin: 10px 0" />
|
||||||
<a-row>
|
<el-row>
|
||||||
<a-col :span="22">
|
<el-col :span="22">
|
||||||
<a-table :data-source="domain" size="small" :pagination="false">
|
<el-table :datel-source="domain" size="small" :pagination="false">
|
||||||
<a-table-column data-index="field" title="条件字段" width="130">
|
<el-table-column datel-index="field" title="条件字段" width="130">
|
||||||
<template #default="{ record }">
|
<template #default="{ record }">
|
||||||
<a-select
|
<el-select
|
||||||
v-model:value="record.field"
|
v-model:value="record.field"
|
||||||
placeholder="请选择"
|
placeholder="请选择"
|
||||||
v-if="recordData.formType === 'DESIGN'"
|
v-if="recordData.formType === 'DESIGN'"
|
||||||
>
|
>
|
||||||
<a-select-option
|
<el-select-option
|
||||||
v-for="formField in fieldList"
|
v-for="formField in fieldList"
|
||||||
:key="formField.model"
|
:key="formField.model"
|
||||||
:value="formField.model"
|
:value="formField.model"
|
||||||
@click="record.label = formField.label"
|
@click="record.label = formField.label"
|
||||||
>{{ formField.label }}</a-select-option
|
>
|
||||||
>
|
{{ formField.label }}
|
||||||
</a-select>
|
</el-select-option>
|
||||||
<a-input v-model:value="record.field" placeholder="条件" v-else />
|
</el-select>
|
||||||
</template>
|
<el-input v-model:value="record.field" placeholder="条件" v-else />
|
||||||
</a-table-column>
|
</template>
|
||||||
<a-table-column data-index="label" title="描述">
|
</el-table-column>
|
||||||
<template #default="{ record }">
|
<el-table-column datel-index="label" title="描述">
|
||||||
<a-input v-model:value="record.label" placeholder="描述" />
|
<template #default="{ record }">
|
||||||
</template>
|
<el-input v-model:value="record.label" placeholder="描述" />
|
||||||
</a-table-column>
|
</template>
|
||||||
<a-table-column data-index="operator" width="140">
|
</el-table-column>
|
||||||
<template #title>
|
<el-table-column datel-index="operator" width="140">
|
||||||
<a-tooltip>
|
<template #title>
|
||||||
<template #title
|
<el-tooltip>
|
||||||
>注:自定义表单模式下条件选择完全放开,中文字段不可以使用大于、大于等于、小于、小于等于!</template
|
<template #title>
|
||||||
>
|
注:自定义表单模式下条件选择完全放开,中文字段不可以使用大于、大于等于、小于、小于等于!
|
||||||
<question-circle-outlined />
|
</template>
|
||||||
运算符
|
<question-circle-outlined />
|
||||||
</a-tooltip>
|
运算符
|
||||||
</template>
|
</el-tooltip>
|
||||||
<template #default="{ record }">
|
</template>
|
||||||
<a-select v-model:value="record.operator" placeholder="请选择">
|
<template #default="{ record }">
|
||||||
<a-select-option value="==">等于</a-select-option>
|
<el-select v-model:value="record.operator" placeholder="请选择">
|
||||||
<a-select-option value="!=">不等于</a-select-option>
|
<el-select-option value="==">等于</el-select-option>
|
||||||
<a-select-option value=">" v-if="isSelectOption(record)">大于</a-select-option>
|
<el-select-option value="!=">不等于</el-select-option>
|
||||||
<a-select-option value=">=" v-if="isSelectOption(record)">大于等于</a-select-option>
|
<el-select-option value=">" v-if="isSelectOption(record)">
|
||||||
<a-select-option value="<" v-if="isSelectOption(record)">小于</a-select-option>
|
大于
|
||||||
<a-select-option value="<=" v-if="isSelectOption(record)">小于等于</a-select-option>
|
</el-select-option>
|
||||||
<a-select-option value="include" v-if="!isSelectOption(record, 'include')"
|
<el-select-option value=">=" v-if="isSelectOption(record)">
|
||||||
>包含</a-select-option
|
大于等于
|
||||||
>
|
</el-select-option>
|
||||||
<a-select-option value="notInclude" v-if="!isSelectOption(record, 'notInclude')"
|
<el-select-option value="<" v-if="isSelectOption(record)">
|
||||||
>不包含</a-select-option
|
小于
|
||||||
>
|
</el-select-option>
|
||||||
</a-select>
|
<el-select-option value="<=" v-if="isSelectOption(record)">
|
||||||
</template>
|
小于等于
|
||||||
</a-table-column>
|
</el-select-option>
|
||||||
<a-table-column data-index="value" width="100">
|
<el-select-option
|
||||||
<template #title>
|
value="include"
|
||||||
<a-tooltip>
|
v-if="!isSelectOption(record, 'include')"
|
||||||
<template #title>中文字段需判断等于,值必须加入英文双引号</template>
|
>
|
||||||
<question-circle-outlined />
|
包含
|
||||||
值
|
</el-select-option>
|
||||||
</a-tooltip>
|
<el-select-option
|
||||||
</template>
|
value="notInclude"
|
||||||
<template #default="{ record }">
|
v-if="!isSelectOption(record, 'notInclude')"
|
||||||
<a-input v-model:value="record.value" placeholder="值" />
|
>
|
||||||
</template>
|
不包含
|
||||||
</a-table-column>
|
</el-select-option>
|
||||||
<a-table-column data-index="value" title="移除" width="55">
|
</el-select>
|
||||||
<template #default="{ index }">
|
</template>
|
||||||
<a-button size="small" type="primary" danger ghost @click="deleteConditionList(index, domain)"
|
</el-table-column>
|
||||||
>移除</a-button
|
<el-table-column datel-index="value" width="100">
|
||||||
>
|
<template #title>
|
||||||
</template>
|
<el-tooltip>
|
||||||
</a-table-column>
|
<template #title>
|
||||||
</a-table>
|
中文字段需判断等于,值必须加入英文双引号
|
||||||
<a-button type="dashed" class="dashedButton" @click="addConditionList(index)">
|
</template>
|
||||||
<PlusOutlined />
|
<question-circle-outlined />
|
||||||
增加条件
|
值
|
||||||
</a-button>
|
</el-tooltip>
|
||||||
</a-col>
|
</template>
|
||||||
<a-col :span="2" class="deleteIcon">
|
<template #default="{ record }">
|
||||||
<minus-circle-two-tone class="minusCircle" @click="delDomains(index)" />
|
<el-input v-model:value="record.value" placeholder="值" />
|
||||||
</a-col>
|
</template>
|
||||||
</a-row>
|
</el-table-column>
|
||||||
</a-form-item>
|
<el-table-column datel-index="value" title="移除" width="55">
|
||||||
</a-form>
|
<template #default="{ index }">
|
||||||
</a-tab-pane>
|
<el-button
|
||||||
<a-tab-pane key="2" tab="执行监听" force-render>
|
size="small"
|
||||||
<prop-listener-info
|
type="primary"
|
||||||
ref="propExecutionListenerInfoRef"
|
danger
|
||||||
:listenerValue="form.properties.executionListenerInfo"
|
ghost
|
||||||
:defaultListenerList="executionListenerInfo"
|
@click="deleteConditionList(index, domain)"
|
||||||
:listener-value-array="executionListenerArray"
|
>
|
||||||
/>
|
移除
|
||||||
</a-tab-pane>
|
</el-button>
|
||||||
</a-tabs>
|
</template>
|
||||||
</a-layout-content>
|
</el-table-column>
|
||||||
<template #footer>
|
</el-table>
|
||||||
<a-button type="primary" style="margin-right: 8px" @click="save">保存</a-button>
|
<el-button type="dashed" class="dashedButton" @click="addConditionList(index)">
|
||||||
<a-button @click="drawer = false">取消</a-button>
|
<PlusOutlined />
|
||||||
</template>
|
增加条件
|
||||||
</xn-form-container>
|
</el-button>
|
||||||
</div>
|
</el-col>
|
||||||
|
<el-col :span="2" class="deleteIcon">
|
||||||
|
<minus-circle-two-tone class="minusCircle" @click="delDomains(index)" />
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</el-tab-pane>
|
||||||
|
<el-tab-pane name="2" label="执行监听" lazy>
|
||||||
|
<prop-listener-info
|
||||||
|
ref="propExecutionListenerInfoRef"
|
||||||
|
:listenerValue="form.properties.executionListenerInfo"
|
||||||
|
:defaultListenerList="executionListenerInfo"
|
||||||
|
:listener-value-array="executionListenerArray"
|
||||||
|
/>
|
||||||
|
</el-tab-pane>
|
||||||
|
</el-tabs>
|
||||||
|
</el-layout-content>
|
||||||
|
<template #footer>
|
||||||
|
<el-button type="primary" style="margin-right: 8px" @click="save">保存</el-button>
|
||||||
|
<el-button @click="drawer = false">取消</el-button>
|
||||||
|
</template>
|
||||||
|
</xn-form-container>
|
||||||
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<!-- <script>
|
||||||
import { cloneDeep, isEmpty } from 'lodash-es'
|
import { cloneDeep, isEmpty } from 'lodash-es'
|
||||||
import addNode from './addNode.vue'
|
import addNode from './addNode.vue'
|
||||||
import config from '@/components/XnWorkflow/nodes/config/config'
|
import config from '@/components/XnWorkflow/nodes/config/config'
|
||||||
@@ -281,9 +306,9 @@
|
|||||||
},
|
},
|
||||||
// 校验此条件是否通过
|
// 校验此条件是否通过
|
||||||
isNodeLegal(data) {
|
isNodeLegal(data) {
|
||||||
const priorityLevel = data.properties.configInfo.priorityLevel
|
const priorityLevel = data&&data.propertie&&data.properties.configInfo&&data.properties.configInfo.priorityLevel?data.properties.configInfo.priorityLevel:{};
|
||||||
const len = this.childNode.conditionNodeList.length
|
const len = this.childNode&&this.childNode.conditionNodeList&&this.childNode.conditionNodeList.length?this.childNode.conditionNodeList.length:0;
|
||||||
const priorityLevelMax = this.childNode.conditionNodeList[len - 1].properties.configInfo.priorityLevel
|
const priorityLevelMax = len!=0?this.childNode.conditionNodeList[len - 1].properties.configInfo.priorityLevel:0;
|
||||||
// 如果往其他条件的分支中增加,那我们一视同仁
|
// 如果往其他条件的分支中增加,那我们一视同仁
|
||||||
if (priorityLevelMax === priorityLevel) {
|
if (priorityLevelMax === priorityLevel) {
|
||||||
if (this.dynamicValidateForm.length > 0) {
|
if (this.dynamicValidateForm.length > 0) {
|
||||||
@@ -469,19 +494,299 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
</script> -->
|
||||||
|
<script setup>
|
||||||
|
import { cloneDeep, isEmpty } from 'lodash-es'
|
||||||
|
import config from '@/components/XnWorkflow/nodes/config/config'
|
||||||
|
import workFlowUtils from '@/components/XnWorkflow/nodes/utils/index'
|
||||||
|
import tool from '@/utils/tool'
|
||||||
|
import AddNode from './addNode.vue'
|
||||||
|
import { ref, watch, onMounted } from 'vue'
|
||||||
|
import PropListenerInfo from './prop/propListenerInfo.vue'
|
||||||
|
const props = defineProps({
|
||||||
|
modelValue: { type: Object, default: () => {} },
|
||||||
|
formFieldListValue: { type: Array, default: () => [] },
|
||||||
|
recordData: { type: Object, default: () => {} },
|
||||||
|
executionListenerArray: { type: Array, default: () => [] },
|
||||||
|
taskListenerArray: { type: Array, default: () => [] }
|
||||||
|
})
|
||||||
|
const emit = defineEmits(['update:modelValue'])
|
||||||
|
const nodeTitleRef = ref()
|
||||||
|
const propExecutionListenerInfoRef = ref()
|
||||||
|
const childNode = ref({})
|
||||||
|
const drawer = ref(false)
|
||||||
|
const isEditTitle = ref(false)
|
||||||
|
const index = ref(0)
|
||||||
|
const form = ref({})
|
||||||
|
const dynamicValidateForm = ref([])
|
||||||
|
const fieldList = ref([])
|
||||||
|
const activeKey = ref('1')
|
||||||
|
const executionListenerInfo = cloneDeep(config.listener.exclusiveGatewayExecutionListenerInfo)
|
||||||
|
const operatorList = cloneDeep(config.exclusiveGatewayConfig.operatorList)
|
||||||
|
watch(props, newValue => {
|
||||||
|
if (newValue.modelValue) {
|
||||||
|
childNode.value = newValue.modelValue
|
||||||
|
}
|
||||||
|
})
|
||||||
|
onMounted(() => {
|
||||||
|
childNode.value = props.modelValue
|
||||||
|
// 把字段给掏出来
|
||||||
|
fieldList.value = workFlowUtils.getListField(props.formFieldListValue).map(m => {
|
||||||
|
let type = m.type //slider rate number
|
||||||
|
if (type === 'slider' || type === 'rate' || type === 'number') {
|
||||||
|
m.type = 'number'
|
||||||
|
}
|
||||||
|
return {
|
||||||
|
label: m.label,
|
||||||
|
model: m.selectTable + '.' + m.model,
|
||||||
|
type: m.type
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
|
const show = value => {
|
||||||
|
index.value = value
|
||||||
|
form.value = {}
|
||||||
|
form.value = cloneDeep(childNode.value.conditionNodeList[value])
|
||||||
|
drawer.value = true
|
||||||
|
dynamicValidateForm.value = form.value.properties.conditionInfo
|
||||||
|
}
|
||||||
|
const editTitle = () => {
|
||||||
|
isEditTitle.value = true
|
||||||
|
nextTick(() => {
|
||||||
|
nodeTitleRef.value.focus()
|
||||||
|
})
|
||||||
|
}
|
||||||
|
const saveTitle = () => {
|
||||||
|
isEditTitle.value = false
|
||||||
|
}
|
||||||
|
const save = () => {
|
||||||
|
form.value.properties.conditionInfo = dynamicValidateForm.value
|
||||||
|
form.value.properties.executionListenerInfo = propExecutionListenerInfoRef.value.selectedListenerList()
|
||||||
|
if (isNodeLegal(form.value)) {
|
||||||
|
form.value.dataLegal = true
|
||||||
|
childNode.value.conditionNodeList[index.value] = form.value
|
||||||
|
setCalibration()
|
||||||
|
emit('update:modelValue', childNode)
|
||||||
|
drawer.value = false
|
||||||
|
} else {
|
||||||
|
form.value.dataLegal = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
const isSelectOption = (record, value) => {
|
||||||
|
if (props.recordData.formType === 'DESIGN') {
|
||||||
|
if (record.field) {
|
||||||
|
return fieldList.value.find(f => f.model === record.field).type === 'number'
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if (value === 'include' || value === 'notInclude') {
|
||||||
|
return false
|
||||||
|
} else {
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 校验此条件是否通过
|
||||||
|
const isNodeLegal = data => {
|
||||||
|
const priorityLevel =
|
||||||
|
data && data.properties && data.properties.configInfo && data.properties.configInfo.priorityLevel
|
||||||
|
? data.properties.configInfo.priorityLevel
|
||||||
|
: ''
|
||||||
|
const len =
|
||||||
|
childNode.value && childNode.value.conditionNodeList && childNode.value.conditionNodeList.length
|
||||||
|
? childNode.value.conditionNodeList.length
|
||||||
|
: 0
|
||||||
|
const priorityLevelMax =
|
||||||
|
len != 0 ? childNode.value.conditionNodeList[len - 1].properties.configInfo.priorityLevel : 0
|
||||||
|
// 如果往其他条件的分支中增加,那我们一视同仁
|
||||||
|
if (priorityLevelMax === priorityLevel) {
|
||||||
|
if (dynamicValidateForm.value.length > 0) {
|
||||||
|
for (let i = 0; i < dynamicValidateForm.value.length; i++) {
|
||||||
|
const obj = dynamicValidateForm.value[i]
|
||||||
|
if (obj.length > 0) {
|
||||||
|
return isNodeLegalItem()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
return isNodeLegalItem()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 设置校验
|
||||||
|
const setCalibration = () => {
|
||||||
|
// 在数据返回更新之前,我要顺手吧优先级最后的条件校验设置为 true,管他设没设
|
||||||
|
for (let i = 0; i < childNode.value.conditionNodeList.length; i++) {
|
||||||
|
let conditionNode = childNode.value.conditionNodeList[i]
|
||||||
|
// 取到优先级
|
||||||
|
const priorityLevel = conditionNode.properties.configInfo.priorityLevel
|
||||||
|
// 如果是最高的
|
||||||
|
if (priorityLevel === childNode.value.conditionNodeList.length) {
|
||||||
|
// 给成通过,不管他的条件,本身优先级最后的就是其他条件进入,一般也不设
|
||||||
|
conditionNode.dataLegal = true
|
||||||
|
} else {
|
||||||
|
// 其他地方的,判断是否有条件,无条件的统统给 false
|
||||||
|
if (conditionNode.properties.conditionInfo.length === 0) {
|
||||||
|
conditionNode.dataLegal = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
const isNodeLegalItem = () => {
|
||||||
|
let objNum = 0
|
||||||
|
let successNum = 0
|
||||||
|
if (dynamicValidateForm.value.length > 0) {
|
||||||
|
for (let i = 0; i < dynamicValidateForm.value.length; i++) {
|
||||||
|
const obj = dynamicValidateForm.value[i]
|
||||||
|
let objNumItem = 0
|
||||||
|
if (!isEmpty(obj)) {
|
||||||
|
for (let a = 0; a < obj.length; a++) {
|
||||||
|
objNumItem++
|
||||||
|
if (isObjLegal(obj[a])) {
|
||||||
|
successNum++
|
||||||
|
}
|
||||||
|
}
|
||||||
|
objNum = objNum + objNumItem
|
||||||
|
} else {
|
||||||
|
objNum++
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (successNum !== 0) {
|
||||||
|
if (objNum === successNum) {
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
// 校验对象中是否有空值
|
||||||
|
const isObjLegal = obj => {
|
||||||
|
let a = 0
|
||||||
|
for (let b in obj) {
|
||||||
|
if (!obj[b]) {
|
||||||
|
a++
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return a === 1
|
||||||
|
}
|
||||||
|
// 增加条件组
|
||||||
|
const addDynamicValidateForm = () => {
|
||||||
|
dynamicValidateForm.value.push([])
|
||||||
|
}
|
||||||
|
// 删除条件组
|
||||||
|
const delDomains = index => {
|
||||||
|
dynamicValidateForm.value.splice(index, 1)
|
||||||
|
}
|
||||||
|
const addTerm = () => {
|
||||||
|
const len = childNode.value.conditionNodeList.length
|
||||||
|
const priorityLevel = childNode.value.conditionNodeList[len - 1].properties.configInfo.priorityLevel
|
||||||
|
// 创建分支节点 n
|
||||||
|
const condition = cloneDeep(config.nodeModel.node)
|
||||||
|
condition.id = tool.snowyUuid()
|
||||||
|
condition.type = 'sequenceFlow'
|
||||||
|
condition.title = `条件${priorityLevel + 1}`
|
||||||
|
// 创建分支节点2 configInfo
|
||||||
|
const condition1ConfigInfo = cloneDeep(config.nodeConfigInfo.conditionConfigInfo)
|
||||||
|
condition1ConfigInfo.priorityLevel = priorityLevel + 1
|
||||||
|
condition.properties.configInfo = condition1ConfigInfo
|
||||||
|
childNode.value.conditionNodeList.push(condition)
|
||||||
|
}
|
||||||
|
const delTerm = index => {
|
||||||
|
childNode.value.conditionNodeList.splice(index, 1)
|
||||||
|
if (childNode.value.conditionNodeList.length === 1) {
|
||||||
|
if (childNode.value.childNode) {
|
||||||
|
// 如果有子项
|
||||||
|
if (!isEmpty(childNode.value.conditionNodeList[0].childNode)) {
|
||||||
|
reData(childNode.value.conditionNodeList[0].childNode, childNode.value.childNode)
|
||||||
|
} else {
|
||||||
|
childNode.value.conditionNodeList[0].childNode = childNode.value.childNode
|
||||||
|
}
|
||||||
|
}
|
||||||
|
emit('update:modelValue', childNode.value.conditionNodeList[0].childNode)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
const reData = (data, addData) => {
|
||||||
|
if (!isEmpty(data)) {
|
||||||
|
data.childNode = addData
|
||||||
|
} else {
|
||||||
|
reData(data.childNode, addData)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
const arrTransfer = (index, type = 1) => {
|
||||||
|
childNode.value.conditionNodeList[index] = childNode.value.conditionNodeList.splice(
|
||||||
|
index + type,
|
||||||
|
1,
|
||||||
|
childNode.value.conditionNodeList[index]
|
||||||
|
)[0]
|
||||||
|
childNode.value.conditionNodeList.map((item, index) => {
|
||||||
|
item.properties.configInfo.priorityLevel = index + 1
|
||||||
|
})
|
||||||
|
setCalibration()
|
||||||
|
emit('update:modelValue', childNode.value)
|
||||||
|
}
|
||||||
|
const addConditionList = index => {
|
||||||
|
const domainsObj = {
|
||||||
|
label: '',
|
||||||
|
key: '',
|
||||||
|
operator: '==',
|
||||||
|
value: ''
|
||||||
|
}
|
||||||
|
dynamicValidateForm.value[index].push(domainsObj)
|
||||||
|
}
|
||||||
|
const deleteConditionList = (index, domain) => {
|
||||||
|
domain.splice(index, 1)
|
||||||
|
}
|
||||||
|
const toText = (childNode, index) => {
|
||||||
|
const conditionList = childNode.conditionNodeList[index].properties.conditionInfo
|
||||||
|
const priorityLevel = childNode.conditionNodeList[index].properties.configInfo.priorityLevel
|
||||||
|
const len = childNode.conditionNodeList.length
|
||||||
|
const priorityLevelMax = childNode.conditionNodeList[len - 1].properties.configInfo.priorityLevel
|
||||||
|
if (JSON.stringify(conditionList) !== undefined && conditionList.length > 0) {
|
||||||
|
let text = ''
|
||||||
|
for (let i = 0; i < conditionList.length; i++) {
|
||||||
|
for (let j = 0; j < conditionList[i].length; j++) {
|
||||||
|
if (j + 1 !== conditionList[i].length) {
|
||||||
|
text =
|
||||||
|
text +
|
||||||
|
conditionList[i][j].label +
|
||||||
|
getOperatorLabel(conditionList[i][j].operator) +
|
||||||
|
conditionList[i][j].value +
|
||||||
|
' 且 '
|
||||||
|
} else {
|
||||||
|
text =
|
||||||
|
text +
|
||||||
|
conditionList[i][j].label +
|
||||||
|
getOperatorLabel(conditionList[i][j].operator) +
|
||||||
|
conditionList[i][j].value
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (i + 1 !== conditionList.length) {
|
||||||
|
text = text + ' 或 '
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return text
|
||||||
|
} else if (conditionList.length === 0 && priorityLevel < priorityLevelMax) {
|
||||||
|
return false
|
||||||
|
} else {
|
||||||
|
return '其他条件进入此流程'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 通过value 获取界面显示的label汉字
|
||||||
|
const getOperatorLabel = value => {
|
||||||
|
return operatorList.find(item => item.value === value).label
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped lang="less">
|
<style scoped lang="less">
|
||||||
.deleteIcon {
|
.deleteIcon {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
.minusCircle {
|
.minusCircle {
|
||||||
font-size: 25px;
|
font-size: 25px;
|
||||||
}
|
}
|
||||||
.dashedButton {
|
.dashedButton {
|
||||||
margin-top: 10px;
|
margin-top: 10px;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -30,7 +30,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<!-- <script>
|
||||||
import { cloneDeep } from 'lodash-es'
|
import { cloneDeep } from 'lodash-es'
|
||||||
import addNode from './addNode.vue'
|
import addNode from './addNode.vue'
|
||||||
import userTask from './userTask.vue'
|
import userTask from './userTask.vue'
|
||||||
@@ -107,4 +107,69 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
</script> -->
|
||||||
|
<script setup>
|
||||||
|
import { cloneDeep } from 'lodash-es'
|
||||||
|
import config from '@/components/XnWorkflow/nodes/config/config'
|
||||||
|
import tool from '@/utils/tool'
|
||||||
|
import AddNode from './addNode.vue'
|
||||||
|
import UserTask from './userTask.vue'
|
||||||
|
import {ref,watch,onMounted} from 'vue';
|
||||||
|
const props = defineProps({
|
||||||
|
modelValue: { type: Object, default: () => {} },
|
||||||
|
formFieldListValue: { type: Array, default: () => [] },
|
||||||
|
recordData: { type: Object, default: () => {} },
|
||||||
|
processConfigInfo: { type: Object, default: () => {} },
|
||||||
|
executionListenerArray: { type: Array, default: () => [] },
|
||||||
|
taskListenerArray: { type: Array, default: () => [] },
|
||||||
|
selectorApiFunction: { type: Object, default: () => {} }
|
||||||
|
})
|
||||||
|
const emit = defineEmits(['update:modelValue'])
|
||||||
|
const childNode = ref({})
|
||||||
|
const drawer = ref(false)
|
||||||
|
const index = ref(0)
|
||||||
|
const form = ref({})
|
||||||
|
watch(props, (newValue) => {
|
||||||
|
if (props.modelValue) {
|
||||||
|
childNode.value = newValue.modelValue
|
||||||
|
}
|
||||||
|
})
|
||||||
|
onMounted(() => {
|
||||||
|
childNode.value = props.modelValue
|
||||||
|
})
|
||||||
|
const addTerm = () => {
|
||||||
|
const len = childNode.value.conditionNodeList.length + 1
|
||||||
|
// 创建主节点
|
||||||
|
const nodeModel = cloneDeep(config.nodeModel.node)
|
||||||
|
nodeModel.id = tool.snowyUuid()
|
||||||
|
nodeModel.type = 'userTask'
|
||||||
|
;(nodeModel.title = `审批人${len}`),
|
||||||
|
(nodeModel.priorityLevel = len),
|
||||||
|
(nodeModel.conditionNodeList = []),
|
||||||
|
(nodeModel.childNode = {})
|
||||||
|
// 创建 configInfo
|
||||||
|
nodeModel.properties.configInfo = cloneDeep(config.nodeConfigInfo.userTaskConfigInfo)
|
||||||
|
childNode.value.conditionNodeList.push(nodeModel)
|
||||||
|
}
|
||||||
|
const delTerm = (index) => {
|
||||||
|
childNode.value.conditionNodeList.splice(index, 1)
|
||||||
|
if (childNode.value.conditionNodeList.length === 1) {
|
||||||
|
if (childNode.value.childNode) {
|
||||||
|
// 这是{}
|
||||||
|
if (JSON.stringify(childNode.value.conditionNodeList[0].childNode) !== '{}') {
|
||||||
|
reData(childNode.value.conditionNodeList[0].childNode, childNode.value.childNode)
|
||||||
|
} else {
|
||||||
|
childNode.value.conditionNodeList[0].childNode = childNode.value.childNode
|
||||||
|
}
|
||||||
|
}
|
||||||
|
emit('update:modelValue', childNode.value.conditionNodeList[0].childNode)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
const reData = (data, addData) => {
|
||||||
|
if (JSON.stringify(data) !== '{}') {
|
||||||
|
data.childNode = addData
|
||||||
|
} else {
|
||||||
|
reData(data.childNode, addData)
|
||||||
|
}
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<a-modal
|
<el-dialog
|
||||||
v-model:visible="visible"
|
v-model="visible"
|
||||||
title="表单人员选择"
|
title="表单人员选择"
|
||||||
:mask-closable="false"
|
:mask-closable="false"
|
||||||
:destroy-on-close="true"
|
:destroy-on-close="true"
|
||||||
@@ -9,10 +9,10 @@
|
|||||||
@cancel="handleCancel"
|
@cancel="handleCancel"
|
||||||
>
|
>
|
||||||
<div class="form-user-table">
|
<div class="form-user-table">
|
||||||
<a-table
|
<el-table
|
||||||
ref="table"
|
ref="table"
|
||||||
:columns="columns"
|
:columns="columns"
|
||||||
:data-source="dataSource"
|
:datel-source="dataSource"
|
||||||
:row-key="(record) => record.model"
|
:row-key="(record) => record.model"
|
||||||
:expand-row-by-click="true"
|
:expand-row-by-click="true"
|
||||||
:row-selection="{ selectedRowKeys: state.selectedRowKeys, onChange: onSelectChange, type: 'radio' }"
|
:row-selection="{ selectedRowKeys: state.selectedRowKeys, onChange: onSelectChange, type: 'radio' }"
|
||||||
@@ -21,12 +21,13 @@
|
|||||||
bordered
|
bordered
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</a-modal>
|
</el-dialog>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup name="formUserSelector">
|
<script setup name="formUserSelector">
|
||||||
import workFlowUtils from '@/components/XnWorkflow/nodes/utils/index'
|
import workFlowUtils from '@/components/XnWorkflow/nodes/utils/index'
|
||||||
import { ElMessage } from 'element-plus'
|
import { ElMessage } from 'element-plus'
|
||||||
|
import {ref,reactive} from 'vue'
|
||||||
const visible = ref(false)
|
const visible = ref(false)
|
||||||
|
|
||||||
const columns = [
|
const columns = [
|
||||||
|
|||||||
@@ -1,157 +1,171 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="mb-2">
|
<div class="mb-2">
|
||||||
<span class="left-span-label">参与者可以看见或操作哪些按钮</span>
|
<span class="left-span-label">参与者可以看见或操作哪些按钮</span>
|
||||||
</div>
|
</div>
|
||||||
<a-table
|
<el-table
|
||||||
ref="table"
|
ref="table"
|
||||||
:columns="columns"
|
:columns="columns"
|
||||||
:data-source="dataSource"
|
:datel-source="dataSource"
|
||||||
:row-key="(record) => record.key"
|
:row-key="record => record.key"
|
||||||
:expand-row-by-click="true"
|
:expand-row-by-click="true"
|
||||||
:row-selection="{
|
:row-selection="{
|
||||||
selectedRowKeys: state.selectedRowKeys,
|
selectedRowKeys: state.selectedRowKeys,
|
||||||
onChange: onSelectChange,
|
onChange: onSelectChange,
|
||||||
getCheckboxProps: checkboxProps
|
getCheckboxProps: checkboxProps
|
||||||
}"
|
}"
|
||||||
:pagination="false"
|
:pagination="false"
|
||||||
:show-header="false"
|
:show-header="false"
|
||||||
size="small"
|
size="small"
|
||||||
>
|
>
|
||||||
<template #bodyCell="{ column, record }">
|
<template #bodyCell="{ column, record }">
|
||||||
<template v-if="column.dataIndex === 'label'">
|
<template v-if="column.dataIndex === 'label'">
|
||||||
<a-popover trigger="hover" placement="left">
|
<el-popover trigger="hover" placement="left">
|
||||||
<template #content>
|
<template #content>
|
||||||
<a-button :type="record.type" size="small">
|
<el-button :type="record.type" size="small">
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<component :is="record.icon" />
|
<component :is="record.icon" />
|
||||||
</template>
|
</template>
|
||||||
{{ record.label }}
|
{{ record.label }}
|
||||||
</a-button>
|
</el-button>
|
||||||
<div v-if="record.key === 'SAVE'" style="width: 300px">
|
<div v-if="record.key === 'SAVE'" style="width: 300px">
|
||||||
”保存“按钮作用为发起节点保存操作,审批节点下无保存操作。
|
”保存“按钮作用为发起节点保存操作,审批节点下无保存操作。
|
||||||
</div>
|
</div>
|
||||||
<div v-if="record.key === 'SUBMIT'" style="width: 300px">
|
<div v-if="record.key === 'SUBMIT'" style="width: 300px">
|
||||||
”提交“按钮作用为发起节点填写完申请单,提交流程到下一步。
|
”提交“按钮作用为发起节点填写完申请单,提交流程到下一步。
|
||||||
</div>
|
</div>
|
||||||
<div v-if="record.key === 'REVOKE'" style="width: 300px">”撤回“按钮作用为发起节点发错内容,将其撤回。</div>
|
<div v-if="record.key === 'REVOKE'" style="width: 300px">
|
||||||
<div v-if="record.key === 'PASS'" style="width: 300px">按钮作用为审批节点同意该审核之操作。</div>
|
”撤回“按钮作用为发起节点发错内容,将其撤回。
|
||||||
<div v-if="record.key === 'REJECT'" style="width: 300px">按钮作用为审批节点进行拒绝之操作。</div>
|
</div>
|
||||||
<div v-if="record.key === 'BACK'" style="width: 300px">按钮作用为审批节点退回操作,可退回至任意节点。</div>
|
<div v-if="record.key === 'PASS'" style="width: 300px">
|
||||||
<div v-if="record.key === 'ADD_SIGN'" style="width: 300px">按钮作用为审批节点加签操作。</div>
|
按钮作用为审批节点同意该审核之操作。
|
||||||
<div v-if="record.key === 'TURN'" style="width: 300px">按钮作用为审批节点转给他人办理操作。</div>
|
</div>
|
||||||
<div v-if="record.key === 'JUMP'" style="width: 300px">按钮作用为审批节点可跳转至任意节点操作。</div>
|
<div v-if="record.key === 'REJECT'" style="width: 300px">
|
||||||
<div v-if="record.key === 'PRINT'" style="width: 300px">
|
按钮作用为审批节点进行拒绝之操作。
|
||||||
按钮配置后,操作人到该节点可以进行管理员配置的全局打印模板,进行打印此流程进展的内容。
|
</div>
|
||||||
</div>
|
<div v-if="record.key === 'BACK'" style="width: 300px">
|
||||||
</template>
|
按钮作用为审批节点退回操作,可退回至任意节点。
|
||||||
<a-button size="small" :type="record.type">
|
</div>
|
||||||
<template #icon>
|
<div v-if="record.key === 'ADD_SIGN'" style="width: 300px">按钮作用为审批节点加签操作。</div>
|
||||||
<component :is="record.icon" />
|
<div v-if="record.key === 'TURN'" style="width: 300px">
|
||||||
</template>
|
按钮作用为审批节点转给他人办理操作。
|
||||||
{{ record.label }}
|
</div>
|
||||||
</a-button>
|
<div v-if="record.key === 'JUMP'" style="width: 300px">
|
||||||
</a-popover>
|
按钮作用为审批节点可跳转至任意节点操作。
|
||||||
</template>
|
</div>
|
||||||
<template v-if="column.dataIndex === 'newLabel'">
|
<div v-if="record.key === 'PRINT'" style="width: 300px">
|
||||||
<a-input v-model:value="record.newLabel" show-count :maxlength="10" />
|
按钮配置后,操作人到该节点可以进行管理员配置的全局打印模板,进行打印此流程进展的内容。
|
||||||
</template>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</a-table>
|
<el-button size="small" :type="record.type">
|
||||||
|
<template #icon>
|
||||||
|
<component :is="record.icon" />
|
||||||
|
</template>
|
||||||
|
{{ record.label }}
|
||||||
|
</el-button>
|
||||||
|
</el-popover>
|
||||||
|
</template>
|
||||||
|
<template v-if="column.dataIndex === 'newLabel'">
|
||||||
|
<el-input v-model:value="record.newLabel" show-count :maxlength="10" />
|
||||||
|
</template>
|
||||||
|
</template>
|
||||||
|
</el-table>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup name="propButtonInfo">
|
<script setup name="propButtonInfo">
|
||||||
import config from '@/components/XnWorkflow/nodes/config/config'
|
import config from '@/components/XnWorkflow/nodes/config/config'
|
||||||
import { cloneDeep } from 'lodash-es'
|
import { cloneDeep } from 'lodash-es'
|
||||||
|
import { ref, reactive } from 'vue'
|
||||||
|
|
||||||
const columns = [
|
const columns = [
|
||||||
{
|
{
|
||||||
title: '',
|
title: '',
|
||||||
dataIndex: 'label',
|
dataIndex: 'label',
|
||||||
align: 'center'
|
align: 'center'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '',
|
title: '',
|
||||||
dataIndex: 'newLabel'
|
dataIndex: 'newLabel'
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
const buttonInfo = cloneDeep(config.nodeModel.buttonInfo)
|
const buttonInfo = cloneDeep(config.nodeModel.buttonInfo)
|
||||||
|
|
||||||
const props = defineProps(['buttonInfo', 'showButton', 'noChecked'])
|
const props = defineProps(['buttonInfo', 'showButton', 'noChecked'])
|
||||||
|
|
||||||
const dataSource = ref([])
|
const dataSource = ref([])
|
||||||
const selectedRowKeys = ref([])
|
const selectedRowKeys = ref([])
|
||||||
// 将其回传的跟本组件的关联性切断
|
// 将其回传的跟本组件的关联性切断
|
||||||
selectedRowKeys.value = cloneDeep(props.showButton)
|
selectedRowKeys.value = cloneDeep(props.showButton)
|
||||||
|
|
||||||
// 设置按钮选中及显示的
|
// 设置按钮选中及显示的
|
||||||
const buttonInfoData = () => {
|
const buttonInfoData = () => {
|
||||||
buttonInfo.forEach((button) => {
|
buttonInfo.forEach(button => {
|
||||||
if (props.buttonInfo.length > 0) {
|
if (props.buttonInfo.length > 0) {
|
||||||
props.buttonInfo.forEach((item) => {
|
props.buttonInfo.forEach(item => {
|
||||||
if (button.key === item.key) {
|
if (button.key === item.key) {
|
||||||
button.newLabel = item.label
|
button.newLabel = item.label
|
||||||
button.value = item.value
|
button.value = item.value
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
button.newLabel = button.label
|
button.newLabel = button.label
|
||||||
}
|
}
|
||||||
// 匹配选中的
|
// 匹配选中的
|
||||||
if (selectedRowKeys.value.length > 0) {
|
if (selectedRowKeys.value.length > 0) {
|
||||||
selectedRowKeys.value.forEach((selectedRowKey) => {
|
selectedRowKeys.value.forEach(selectedRowKey => {
|
||||||
if (button.value === 'SHOW') {
|
if (button.value === 'SHOW') {
|
||||||
// 已有的里面如果不包含这个已经被选中的
|
// 已有的里面如果不包含这个已经被选中的
|
||||||
if (selectedRowKeys.value.indexOf(button.key) === -1) {
|
if (selectedRowKeys.value.indexOf(button.key) === -1) {
|
||||||
selectedRowKeys.value.push(button.key)
|
selectedRowKeys.value.push(button.key)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (selectedRowKey === button.key) {
|
if (selectedRowKey === button.key) {
|
||||||
button.value = 'SHOW'
|
button.value = 'SHOW'
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
} else if (button.value === 'SHOW') {
|
} else if (button.value === 'SHOW') {
|
||||||
if (selectedRowKeys.value.indexOf(button.key) === -1) {
|
if (selectedRowKeys.value.indexOf(button.key) === -1) {
|
||||||
selectedRowKeys.value.push(button.key)
|
selectedRowKeys.value.push(button.key)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
return buttonInfo
|
return buttonInfo
|
||||||
}
|
}
|
||||||
|
|
||||||
dataSource.value = buttonInfoData()
|
dataSource.value = buttonInfoData()
|
||||||
|
|
||||||
// 设置默认选中的
|
// 设置默认选中的
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
selectedRowKeys: selectedRowKeys.value,
|
selectedRowKeys: selectedRowKeys.value,
|
||||||
loading: false
|
loading: false
|
||||||
})
|
})
|
||||||
// 点击复选框回调
|
// 点击复选框回调
|
||||||
const onSelectChange = (selectedRowKeys) => {
|
const onSelectChange = selectedRowKeys => {
|
||||||
state.selectedRowKeys = selectedRowKeys
|
state.selectedRowKeys = selectedRowKeys
|
||||||
}
|
}
|
||||||
// 设置选择框的默认属性配置,将其设置成不可取消,不可选中
|
// 设置选择框的默认属性配置,将其设置成不可取消,不可选中
|
||||||
const checkboxProps = (record) => ({
|
const checkboxProps = record => ({
|
||||||
disabled:
|
disabled:
|
||||||
(record.value === 'SHOW' && props.showButton.indexOf(record.key) > -1) || props.noChecked.indexOf(record.key) > -1
|
(record.value === 'SHOW' && props.showButton.indexOf(record.key) > -1) ||
|
||||||
})
|
props.noChecked.indexOf(record.key) > -1
|
||||||
// 父界面需要调用获取参数
|
})
|
||||||
const selectedButtonKeyList = () => {
|
// 父界面需要调用获取参数
|
||||||
let resultData = cloneDeep(dataSource.value)
|
const selectedButtonKeyList = () => {
|
||||||
resultData.forEach((dataItem) => {
|
let resultData = cloneDeep(dataSource.value)
|
||||||
if (state.selectedRowKeys.indexOf(dataItem.key) > -1) {
|
resultData.forEach(dataItem => {
|
||||||
dataItem.value = 'SHOW'
|
if (state.selectedRowKeys.indexOf(dataItem.key) > -1) {
|
||||||
} else {
|
dataItem.value = 'SHOW'
|
||||||
dataItem.value = 'HIDE'
|
} else {
|
||||||
}
|
dataItem.value = 'HIDE'
|
||||||
if (dataItem.newLabel !== '') {
|
}
|
||||||
dataItem.label = dataItem.newLabel
|
if (dataItem.newLabel !== '') {
|
||||||
}
|
dataItem.label = dataItem.newLabel
|
||||||
delete dataItem.newLabel
|
}
|
||||||
})
|
delete dataItem.newLabel
|
||||||
return resultData
|
})
|
||||||
}
|
return resultData
|
||||||
// 抛出方法,让上个界面使用
|
}
|
||||||
defineExpose({
|
// 抛出方法,让上个界面使用
|
||||||
selectedButtonKeyList
|
defineExpose({
|
||||||
})
|
selectedButtonKeyList
|
||||||
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -2,10 +2,10 @@
|
|||||||
<div class="mb-2">
|
<div class="mb-2">
|
||||||
<span class="left-span-label">参与者可以看见或操作哪些字段</span>
|
<span class="left-span-label">参与者可以看见或操作哪些字段</span>
|
||||||
</div>
|
</div>
|
||||||
<a-table
|
<el-table
|
||||||
ref="table"
|
ref="table"
|
||||||
:columns="columns"
|
:columns="columns"
|
||||||
:data-source="dataSource"
|
:datel-source="dataSource"
|
||||||
:row-key="(record) => record.key"
|
:row-key="(record) => record.key"
|
||||||
:expand-row-by-click="true"
|
:expand-row-by-click="true"
|
||||||
:pagination="false"
|
:pagination="false"
|
||||||
@@ -19,16 +19,17 @@
|
|||||||
{{ record.label }}
|
{{ record.label }}
|
||||||
</template>
|
</template>
|
||||||
<template v-if="column.dataIndex === 'value'">
|
<template v-if="column.dataIndex === 'value'">
|
||||||
<a-radio-group v-model:value="record.value" :disabled="record.disabled">
|
<el-radio-group v-model:value="record.value" :disabled="record.disabled">
|
||||||
<a-radio :key="radio.value" v-for="radio in fieldRadioList" :value="radio.value">{{ radio.label }}</a-radio>
|
<el-radio :key="radio.value" v-for="radio in fieldRadioList" :value="radio.value">{{ radio.label }}</el-radio>
|
||||||
</a-radio-group>
|
</el-radio-group>
|
||||||
</template>
|
</template>
|
||||||
</template>
|
</template>
|
||||||
</a-table>
|
</el-table>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup name="propFieldInfo">
|
<script setup name="propFieldInfo">
|
||||||
import config from '@/components/XnWorkflow/nodes/config/config'
|
import config from '@/components/XnWorkflow/nodes/config/config'
|
||||||
|
import {ref} from 'vue'
|
||||||
const columns = [
|
const columns = [
|
||||||
{
|
{
|
||||||
title: '表单字段',
|
title: '表单字段',
|
||||||
|
|||||||
@@ -2,16 +2,16 @@
|
|||||||
<div class="mb-2">
|
<div class="mb-2">
|
||||||
<span class="left-span-label">配置要执行的监听</span>
|
<span class="left-span-label">配置要执行的监听</span>
|
||||||
</div>
|
</div>
|
||||||
<a-button type="primary" size="small" @click="addEditListener" class="mb-2">
|
<el-button type="primary" size="small" @click="addEditListener" class="mb-2">
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<plus-outlined />
|
<!-- <plus-outlined/> -->
|
||||||
</template>
|
</template>
|
||||||
新增
|
新增
|
||||||
</a-button>
|
</el-button>
|
||||||
<a-table
|
<el-table
|
||||||
ref="table"
|
ref="table"
|
||||||
:columns="columns"
|
:columns="columns"
|
||||||
:data-source="dataSource"
|
:datel-source="dataSource"
|
||||||
:row-key="(record) => record.id"
|
:row-key="(record) => record.id"
|
||||||
bordered
|
bordered
|
||||||
:expand-row-by-click="true"
|
:expand-row-by-click="true"
|
||||||
@@ -23,22 +23,22 @@
|
|||||||
{{ listenerlabel(record.listenerType) }}
|
{{ listenerlabel(record.listenerType) }}
|
||||||
</template>
|
</template>
|
||||||
<template v-if="column.dataIndex === 'action'">
|
<template v-if="column.dataIndex === 'action'">
|
||||||
<a-popconfirm title="确定要删除此监听吗?" @confirm="deleteListener(record)" placement="topRight">
|
<el-popconfirm title="确定要删除此监听吗?" @confirm="deleteListener(record)" placement="topRight">
|
||||||
<a-button type="link" danger size="small">删除</a-button>
|
<el-button type="link" danger size="small">删除</el-button>
|
||||||
</a-popconfirm>
|
</el-popconfirm>
|
||||||
</template>
|
</template>
|
||||||
</template>
|
</template>
|
||||||
</a-table>
|
</el-table>
|
||||||
<a-modal v-model:visible="modalVisible" title="新增" @ok="handleOk" @cancel="handleCancel">
|
<el-dialog v-model="modalVisible" title="新增" @ok="handleOk" @cancel="handleCancel">
|
||||||
<a-form ref="formRef" :model="formData" :rules="formRules" layout="vertical">
|
<el-form ref="formRef" :model="formData" :rules="formRules" layout="vertical">
|
||||||
<a-form-item label="监听类型:" name="listenerType">
|
<el-form-item label="监听类型:" name="listenerType">
|
||||||
<a-select v-model:value="formData.listenerType" placeholder="请选择类型" :options="listenerTypeOptions" @change="listenerType" />
|
<el-select v-model:value="formData.listenerType" placeholder="请选择类型" :options="listenerTypeOptions" @change="listenerType" />
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
<a-form-item label="JAVA监听器:" name="javaClass">
|
<el-form-item label="JAVA监听器:" name="javaClass">
|
||||||
<a-select v-model:value="formData.javaClass" placeholder="请选择JAVA监听器" :options="listenerValueArray" />
|
<el-select v-model:value="formData.javaClass" placeholder="请选择JAVA监听器" :options="listenerValueArray" />
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
</a-form>
|
</el-form>
|
||||||
</a-modal>
|
</el-dialog>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup name="PropListenerInfo">
|
<script setup name="PropListenerInfo">
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<a-tag v-for="tag in tagList()">{{ tag }}</a-tag
|
<el-tag v-for="tag in tagList()">{{ tag }}</el-tag
|
||||||
><!-- 花里胡哨的颜色先去掉,用的时候拿到旁边就行 :color="randomColor()"-->
|
><!-- 花里胡哨的颜色先去掉,用的时候拿到旁边就行 :color="randomColor()"-->
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,8 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<a-textarea
|
<el-input
|
||||||
ref="smsInput"
|
ref="smsInput"
|
||||||
|
type="textarea"
|
||||||
v-model:value="smsContent"
|
v-model:value="smsContent"
|
||||||
:auto-size="{ minRows: 3, maxRows: 6 }"
|
:auto-size="{ minRows: 3, maxRows: 6 }"
|
||||||
placeholder="请输入内容"
|
placeholder="请输入内容"
|
||||||
@@ -11,25 +12,25 @@
|
|||||||
@click.native="focusHandler"
|
@click.native="focusHandler"
|
||||||
@keydown.up.down.left.right.native="focusHandler"
|
@keydown.up.down.left.right.native="focusHandler"
|
||||||
@select.native="selectHandler"
|
@select.native="selectHandler"
|
||||||
></a-textarea>
|
></el-input>
|
||||||
<a-dropdown>
|
<el-dropdown>
|
||||||
<template #overlay>
|
<template #overlay>
|
||||||
<a-menu>
|
<el-menu>
|
||||||
<a-menu-item
|
<el-menu-item
|
||||||
v-for="fields in fieldInfoLisNew"
|
v-for="fields in fieldInfoLisNew"
|
||||||
:key="fields.value"
|
:key="fields.value"
|
||||||
:value="fields.value"
|
:value="fields.value"
|
||||||
:disabled="fields.value === 'disabled'"
|
:disabled="fields.value === 'disabled'"
|
||||||
@click="insertFields(fields)"
|
@click="insertFields(fields)"
|
||||||
>{{ fields.label }}</a-menu-item
|
>{{ fields.label }}</el-menu-item
|
||||||
>
|
>
|
||||||
</a-menu>
|
</el-menu>
|
||||||
</template>
|
</template>
|
||||||
<a-button size="small" type="primary" style="float: right; margin-top: -35px; margin-right: 10px">
|
<el-button size="small" type="primary" style="float: right; margin-top: -35px; margin-right: 10px">
|
||||||
置入字段
|
置入字段
|
||||||
<DownOutlined />
|
<!-- <DownOutlined /> -->
|
||||||
</a-button>
|
</el-button>
|
||||||
</a-dropdown>
|
</el-dropdown>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
|||||||
@@ -23,7 +23,7 @@
|
|||||||
<label v-if="!isEditTitle" @click="editTitle"
|
<label v-if="!isEditTitle" @click="editTitle"
|
||||||
>{{ form.title }}<edit-outlined class="node-wrap-drawer-title-edit" />
|
>{{ form.title }}<edit-outlined class="node-wrap-drawer-title-edit" />
|
||||||
</label>
|
</label>
|
||||||
<a-input
|
<el-input
|
||||||
v-if="isEditTitle"
|
v-if="isEditTitle"
|
||||||
ref="nodeTitle"
|
ref="nodeTitle"
|
||||||
v-model:value="form.title"
|
v-model:value="form.title"
|
||||||
@@ -33,43 +33,43 @@
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<a-layout-content>
|
<el-container>
|
||||||
<a-tabs v-model:activeKey="activeKey">
|
<el-tabs v-model="activeKey">
|
||||||
<a-tab-pane key="1" tab="抄送配置" force-render>
|
<el-tab-pane name="1" label="抄送配置" lazy>
|
||||||
<a-form layout="vertical" :model="userTypeForm">
|
<el-form layout="vertical" :model="userTypeForm">
|
||||||
<div v-show="nodeLegal" style="margin-bottom: 10px">
|
<div v-show="nodeLegal" style="margin-bottom: 10px">
|
||||||
<a-alert message="请选择抄送人员!" type="error" />
|
<el-alert message="请选择抄送人员!" type="error" />
|
||||||
</div>
|
</div>
|
||||||
<div class="mb-2">
|
<div class="mb-2">
|
||||||
<span class="left-span-label">选择要抄送的人员</span>
|
<span class="left-span-label">选择要抄送的人员</span>
|
||||||
</div>
|
</div>
|
||||||
<a-radio-group v-model:value="userSelectionType" style="width: 100%">
|
<el-radio-group v-model:value="userSelectionType" style="width: 100%">
|
||||||
<a-row style="padding-bottom: 10px">
|
<el-row style="padding-bottom: 10px">
|
||||||
<a-col :span="8" v-for="userSelectionType in userSelectionTypeList" :key="userSelectionType.value">
|
<el-col :span="8" v-for="userSelectionType in userSelectionTypeList" :key="userSelectionType.value">
|
||||||
<a-radio :value="userSelectionType.value" @click="selectionClick(userSelectionType.value)">
|
<el-radio :value="userSelectionType.value" @click="selectionClick(userSelectionType.value)">
|
||||||
{{ userSelectionType.label }}
|
{{ userSelectionType.label }}
|
||||||
</a-radio>
|
</el-radio>
|
||||||
</a-col>
|
</el-col>
|
||||||
</a-row>
|
</el-row>
|
||||||
</a-radio-group>
|
</el-radio-group>
|
||||||
<a-form-item v-if="userSelectionType === 'USER'">
|
<el-form-item v-if="userSelectionType === 'USER'">
|
||||||
<a-button class="mt-2" type="primary" size="small" round @click="openSelector">
|
<el-button class="mt-2" type="primary" size="small" round @click="openSelector">
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<search-outlined />
|
<search-outlined />
|
||||||
</template>
|
</template>
|
||||||
选择
|
选择
|
||||||
</a-button>
|
</el-button>
|
||||||
<p />
|
<p />
|
||||||
<prop-tag :tag-list="getTagList('USER')" />
|
<prop-tag :tag-list="getTagList('USER')" />
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
<a-form-item v-if="recordData.formType === 'DESIGN' && userSelectionType === 'FORM_USER'">
|
<el-form-item v-if="recordData.formType === 'DESIGN' && userSelectionType === 'FORM_USER'">
|
||||||
<div class="mt-2">
|
<div class="mt-2">
|
||||||
<a-button type="primary" @click="openSelector" size="small">
|
<el-button type="primary" @click="openSelector" size="small">
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<search-outlined />
|
<search-outlined />
|
||||||
</template>
|
</template>
|
||||||
选择
|
选择
|
||||||
</a-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
<div class="mt-2">
|
<div class="mt-2">
|
||||||
<prop-tag
|
<prop-tag
|
||||||
@@ -77,21 +77,21 @@
|
|||||||
:tag-list="form.properties.participateInfo[0]"
|
:tag-list="form.properties.participateInfo[0]"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
<a-form-item
|
<el-form-item
|
||||||
class="mt-2"
|
class="mt-2"
|
||||||
v-if="recordData.formType === 'DEFINE' && userSelectionType === 'FORM_USER'"
|
v-if="recordData.formType === 'DEFINE' && userSelectionType === 'FORM_USER'"
|
||||||
name="formUser"
|
name="formUser"
|
||||||
:rules="[{ required: true, message: '请输入人员变量' }]"
|
:rules="[{ required: true, message: '请输入人员变量' }]"
|
||||||
>
|
>
|
||||||
<template #label>
|
<template #label>
|
||||||
<a-tooltip>
|
<el-tooltip>
|
||||||
<template #title>单个字段可以采用:字段名,多个采用:字段名1,字段名2,字段名3</template>
|
<template #title>单个字段可以采用:字段名,多个采用:字段名1,字段名2,字段名3</template>
|
||||||
<question-circle-outlined />
|
<question-circle-outlined />
|
||||||
人员变量:
|
人员变量:
|
||||||
</a-tooltip>
|
</el-tooltip>
|
||||||
</template>
|
</template>
|
||||||
<a-input
|
<el-input
|
||||||
style="width: 50%"
|
style="width: 50%"
|
||||||
v-model:value="userTypeForm.formUser"
|
v-model:value="userTypeForm.formUser"
|
||||||
allow-clear
|
allow-clear
|
||||||
@@ -99,22 +99,23 @@
|
|||||||
@keyup.enter="customFormUser"
|
@keyup.enter="customFormUser"
|
||||||
placeholder="请输入人员变量"
|
placeholder="请输入人员变量"
|
||||||
/>
|
/>
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
</a-form>
|
</el-form>
|
||||||
</a-tab-pane>
|
</el-tab-pane>
|
||||||
<a-tab-pane key="2" tab="执行监听" force-render>
|
<el-tab-pane name="2" label="执行监听" lazy>
|
||||||
<prop-listener-info
|
<prop-listener-info
|
||||||
ref="propExecutionListenerInfoRef"
|
ref="propExecutionListenerInfoRef"
|
||||||
|
v-if="form&&form.properties&&form.properties.executionListenerInfo"
|
||||||
:listener-value="form.properties.executionListenerInfo"
|
:listener-value="form.properties.executionListenerInfo"
|
||||||
:default-listener-list="executionListenerInfo"
|
:default-listener-list="executionListenerInfo"
|
||||||
:listener-value-array="executionListenerArray"
|
:listener-value-array="executionListenerArray"
|
||||||
/>
|
/>
|
||||||
</a-tab-pane>
|
</el-tab-pane>
|
||||||
</a-tabs>
|
</el-tabs>
|
||||||
</a-layout-content>
|
</el-container>
|
||||||
<template #footer>
|
<template #footer>
|
||||||
<a-button type="primary" style="margin-right: 8px" @click="save">保存</a-button>
|
<el-button type="primary" style="margin-right: 8px" @click="save">保存</el-button>
|
||||||
<a-button @click="drawer = false">取消</a-button>
|
<el-button @click="drawer = false">取消</el-button>
|
||||||
</template>
|
</template>
|
||||||
</xn-form-container>
|
</xn-form-container>
|
||||||
<form-user-selector ref="formUserSelectorRef" :form-field-list="formFieldListValue" @click="userCallBack" />
|
<form-user-selector ref="formUserSelectorRef" :form-field-list="formFieldListValue" @click="userCallBack" />
|
||||||
@@ -123,7 +124,7 @@
|
|||||||
:org-tree-api="selectorApiFunction.orgTreeApi"
|
:org-tree-api="selectorApiFunction.orgTreeApi"
|
||||||
:user-page-api="selectorApiFunction.userPageApi"
|
:user-page-api="selectorApiFunction.userPageApi"
|
||||||
:checked-user-list-api="selectorApiFunction.checkedUserListApi"
|
:checked-user-list-api="selectorApiFunction.checkedUserListApi"
|
||||||
:data-is-converter-flw="true"
|
:datel-is-converter-flw="true"
|
||||||
@onBack="userCallBack"
|
@onBack="userCallBack"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -1,241 +1,251 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="node-wrap">
|
<div class="node-wrap">
|
||||||
<div class="node-wrap-box start-node" @click="show">
|
<div class="node-wrap-box start-node" @click="show">
|
||||||
<div class="title" style="background: #576a95">
|
<div class="title" style="background: #576a95">
|
||||||
<user-outlined class="icon" />
|
<!-- <user-outlined class="icon" /> -->
|
||||||
<span>{{ childNode.title }}</span>
|
<span>{{ childNode.title }}777111</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="content">
|
<div class="content">
|
||||||
<span v-if="toText(childNode)">{{ toText(childNode) }}</span>
|
<span v-if="toText(childNode)">{{ toText(childNode) }}</span>
|
||||||
<span v-else class="placeholder">请配置字段与按钮</span>
|
<span v-else class="placeholder">请配置字段与按钮</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<add-node v-model="childNode.childNode" />
|
<!-- 添加节点 -->
|
||||||
<xn-form-container
|
<addNode v-model="childNode.childNode" />
|
||||||
v-model:visible="drawer"
|
<form_container v-model="drawer" :destroy-on-close="true" :width="700" :body-style="{ 'padding-top': '0px' }">
|
||||||
:destroy-on-close="true"
|
<template #title>
|
||||||
:width="700"
|
<div class="node-wrap-drawer__title">
|
||||||
:body-style="{ 'padding-top': '0px' }"
|
<label v-if="!isEditTitle" @click="editTitle">
|
||||||
>
|
{{ form.title }}
|
||||||
<template #title>
|
<!-- <edit-outlined class="node-wrap-drawer-title-edit" /> -->
|
||||||
<div class="node-wrap-drawer__title">
|
</label>
|
||||||
<label v-if="!isEditTitle" @click="editTitle">
|
<el-input
|
||||||
{{ form.title }}
|
v-if="isEditTitle"
|
||||||
<edit-outlined class="node-wrap-drawer-title-edit" />
|
ref="nodeTitle"
|
||||||
</label>
|
v-model:value="form.title"
|
||||||
<a-input
|
allow-clear
|
||||||
v-if="isEditTitle"
|
@blur="saveTitle"
|
||||||
ref="nodeTitle"
|
@keyup.enter="saveTitle"
|
||||||
v-model:value="form.title"
|
/>
|
||||||
allow-clear
|
</div>
|
||||||
@blur="saveTitle"
|
</template>
|
||||||
@keyup.enter="saveTitle"
|
<el-container>
|
||||||
/>
|
<el-tabs v-model:activeKey="activeKey">
|
||||||
</div>
|
<el-tab-pane name="1" label="按钮配置" lazy>
|
||||||
</template>
|
<prop-button-info
|
||||||
<a-layout-content>
|
ref="propButtonInfo"
|
||||||
<a-tabs v-model:activeKey="activeKey">
|
:button-info="selectedButtonInfo"
|
||||||
<a-tab-pane key="1" tab="按钮配置" force-render>
|
:show-button="startTaskDefaultButtonkey"
|
||||||
<prop-button-info
|
:no-checked="startTaskNoCheckedButtonkey"
|
||||||
ref="propButtonInfo"
|
/>
|
||||||
:button-info="selectedButtonInfo"
|
</el-tab-pane>
|
||||||
:show-button="startTaskDefaultButtonkey"
|
<el-tab-pane name="2" label="字段配置" lazy v-if="recordData.formType === 'DESIGN'">
|
||||||
:no-checked="startTaskNoCheckedButtonkey"
|
<prop-field-info
|
||||||
/>
|
ref="propFieldInfo"
|
||||||
</a-tab-pane>
|
:field-info="fieldInfo"
|
||||||
<a-tab-pane key="2" tab="字段配置" force-render v-if="recordData.formType === 'DESIGN'">
|
:form-field-list-value="formFieldListValue"
|
||||||
<prop-field-info ref="propFieldInfo" :field-info="fieldInfo" :form-field-list-value="formFieldListValue" />
|
/>
|
||||||
</a-tab-pane>
|
</el-tab-pane>
|
||||||
<a-tab-pane key="3" tab="表单配置" force-render v-else>
|
<el-tab-pane name="3" label="表单配置" lazy v-else>
|
||||||
<div class="mb-2">
|
<div class="mb-2">
|
||||||
<span class="left-span-label">参与者可以填写的表单</span>
|
<span class="left-span-label">参与者可以填写的表单</span>
|
||||||
</div>
|
</div>
|
||||||
<a-form ref="startTaskFormRef" :model="formData" layout="vertical">
|
<el-form ref="startTaskFormRef" :model="formData" layout="vertical">
|
||||||
<a-form-item
|
<el-form-item
|
||||||
label="节点表单"
|
label="节点表单"
|
||||||
name="FORM_URL"
|
name="FORM_URL"
|
||||||
:rules="[{ required: true, message: '请输入节点表单组件地址' }]"
|
:rules="[{ required: true, message: '请输入节点表单组件地址' }]"
|
||||||
>
|
>
|
||||||
<a-input
|
<el-input
|
||||||
v-model:value="formData.FORM_URL"
|
v-model:value="formData.FORM_URL"
|
||||||
addon-before="src/views/flw/customform/"
|
addon-before="src/views/flw/customform/"
|
||||||
addon-after=".vue"
|
addon-after=".vue"
|
||||||
placeholder="请输入节点表单组件地址"
|
placeholder="请输入节点表单组件地址"
|
||||||
allow-clear
|
allow-clear
|
||||||
>
|
>
|
||||||
<template #suffix>
|
<template #suffix>
|
||||||
<a-button
|
<el-button
|
||||||
v-if="formData.FORM_URL"
|
v-if="formData.FORM_URL"
|
||||||
type="primary"
|
type="primary"
|
||||||
size="small"
|
size="small"
|
||||||
@click="$refs.previewCustomFormRef.onOpen(formData.FORM_URL)"
|
@click="$refs.previewCustomFormRef.onOpen(formData.FORM_URL)"
|
||||||
>
|
>
|
||||||
预览
|
预览
|
||||||
</a-button>
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
</a-input>
|
</el-input>
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
<a-form-item
|
<el-form-item
|
||||||
label="移动端节点表单"
|
label="移动端节点表单"
|
||||||
name="MOBILE_FORM_URL"
|
name="MOBILE_FORM_URL"
|
||||||
:rules="[{ required: true, message: '请输入移动端节点表单组件地址' }]"
|
:rules="[{ required: true, message: '请输入移动端节点表单组件地址' }]"
|
||||||
>
|
>
|
||||||
<a-input
|
<el-input
|
||||||
v-model:value="formData.MOBILE_FORM_URL"
|
v-model:value="formData.MOBILE_FORM_URL"
|
||||||
addon-before="pages/flw/customform/"
|
addon-before="pages/flw/customform/"
|
||||||
addon-after=".vue"
|
addon-after=".vue"
|
||||||
placeholder="请输入移动端节点表单组件地址"
|
placeholder="请输入移动端节点表单组件地址"
|
||||||
allow-clear
|
allow-clear
|
||||||
/>
|
/>
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
</a-form>
|
</el-form>
|
||||||
</a-tab-pane>
|
</el-tab-pane>
|
||||||
<a-tab-pane key="4" tab="执行监听" force-render>
|
<el-tab-pane name="4" label="执行监听" lazy>
|
||||||
<prop-listener-info
|
<prop-listener-info
|
||||||
ref="propExecutionListenerInfoRef"
|
v-if="form.properties && form.properties.executionListenerInfo"
|
||||||
:listener-value="form.properties.executionListenerInfo"
|
ref="propExecutionListenerInfoRef"
|
||||||
:default-listener-list="executionListenerInfo"
|
:listener-value="form.properties.executionListenerInfo"
|
||||||
:listener-value-array="executionListenerArray"
|
:default-listener-list="executionListenerInfo"
|
||||||
/>
|
:listener-value-array="executionListenerArray"
|
||||||
</a-tab-pane>
|
/>
|
||||||
<a-tab-pane key="5" tab="节点监听" force-render>
|
</el-tab-pane>
|
||||||
<prop-listener-info
|
<el-tab-pane name="5" label="节点监听" lazy>
|
||||||
ref="propTaskListenerInfoRef"
|
<prop-listener-info
|
||||||
:listener-value="form.properties.taskListenerInfo"
|
ref="propTaskListenerInfoRef"
|
||||||
:default-listener-list="taskListenerInfo"
|
v-if="form.properties && form.properties.taskListenerInfo"
|
||||||
:listener-value-array="taskListenerArray"
|
:listener-value="form.properties.taskListenerInfo"
|
||||||
/>
|
:default-listener-list="taskListenerInfo"
|
||||||
</a-tab-pane>
|
:listener-value-array="taskListenerArray"
|
||||||
</a-tabs>
|
/>
|
||||||
</a-layout-content>
|
</el-tab-pane>
|
||||||
<template #footer>
|
</el-tabs>
|
||||||
<a-button type="primary" style="margin-right: 8px" @click="save">保存</a-button>
|
</el-container>
|
||||||
<a-button @click="drawer = false">取消</a-button>
|
<template #footer>
|
||||||
</template>
|
<el-button type="primary" style="margin-right: 8px" @click="save">保存</el-button>
|
||||||
</xn-form-container>
|
<el-button @click="drawer = false">取消111</el-button>
|
||||||
<preview-custom-form ref="previewCustomFormRef" />
|
</template>
|
||||||
</div>
|
</form_container>
|
||||||
|
<preview-custom-form ref="previewCustomFormRef" />
|
||||||
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { cloneDeep } from 'lodash-es'
|
import { cloneDeep } from 'lodash-es'
|
||||||
import config from '@/components/XnWorkflow/nodes/config/config'
|
import config from '@/components/XnWorkflow/nodes/config/config'
|
||||||
import addNode from './addNode.vue'
|
import form_container from '../../../components/formContainer/index.vue'
|
||||||
import propButtonInfo from './prop/propButtonInfo.vue'
|
import addNode from './addNode.vue'
|
||||||
import propFieldInfo from './prop/propFieldInfo.vue'
|
import propButtonInfo from './prop/propButtonInfo.vue'
|
||||||
import propListenerInfo from './prop/propListenerInfo.vue'
|
import propFieldInfo from './prop/propFieldInfo.vue'
|
||||||
import PreviewCustomForm from '@/components/XnWorkflow/nodes/common/previewCustomForm.vue'
|
import propListenerInfo from './prop/propListenerInfo.vue'
|
||||||
|
import PreviewCustomForm from '@/components/XnWorkflow/nodes/common/previewCustomForm.vue'
|
||||||
export default {
|
import { add } from 'xe-utils'
|
||||||
components: {
|
export default {
|
||||||
addNode,
|
components: {
|
||||||
propButtonInfo,
|
addNode,
|
||||||
propFieldInfo,
|
propButtonInfo,
|
||||||
propListenerInfo,
|
propFieldInfo,
|
||||||
PreviewCustomForm
|
propListenerInfo,
|
||||||
},
|
PreviewCustomForm,
|
||||||
props: {
|
form_container
|
||||||
modelValue: { type: Object, default: () => {} },
|
},
|
||||||
formFieldListValue: { type: Array, default: () => [] },
|
props: {
|
||||||
recordData: { type: Object, default: () => {} },
|
modelValue: { type: Object, default: () => {} },
|
||||||
processConfigInfo: { type: Object, default: () => {} },
|
formFieldListValue: { type: Array, default: () => [] },
|
||||||
executionListenerArray: { type: Array, default: () => [] },
|
recordData: { type: Object, default: () => {} },
|
||||||
taskListenerArray: { type: Array, default: () => [] }
|
processConfigInfo: { type: Object, default: () => {} },
|
||||||
},
|
executionListenerArray: { type: Array, default: () => [] },
|
||||||
data() {
|
taskListenerArray: { type: Array, default: () => [] }
|
||||||
return {
|
},
|
||||||
childNode: {},
|
data() {
|
||||||
drawer: false,
|
return {
|
||||||
isEditTitle: false,
|
childNode: {},
|
||||||
form: {},
|
drawer: false,
|
||||||
activeKey: '1',
|
isEditTitle: false,
|
||||||
selectedButtonInfo: [],
|
form: {},
|
||||||
executionListenerInfo: cloneDeep(config.listener.startTaskExecutionListenerInfo),
|
activeKey: '1',
|
||||||
taskListenerInfo: cloneDeep(config.listener.userTaskTaskListenerInfo),
|
selectedButtonInfo: [],
|
||||||
startTaskDefaultButtonkey: cloneDeep(config.button.startTaskDefaultButtonkey),
|
executionListenerInfo: cloneDeep(config.listener.startTaskExecutionListenerInfo),
|
||||||
startTaskNoCheckedButtonkey: cloneDeep(config.button.startTaskNoCheckedButtonkey),
|
taskListenerInfo: cloneDeep(config.listener.userTaskTaskListenerInfo),
|
||||||
fieldInfo: [],
|
startTaskDefaultButtonkey: cloneDeep(config.button.startTaskDefaultButtonkey),
|
||||||
formData: {}
|
startTaskNoCheckedButtonkey: cloneDeep(config.button.startTaskNoCheckedButtonkey),
|
||||||
}
|
fieldInfo: [],
|
||||||
},
|
formData: {}
|
||||||
watch: {
|
}
|
||||||
modelValue() {
|
},
|
||||||
this.childNode = this.modelValue
|
watch: {
|
||||||
}
|
modelValue() {
|
||||||
},
|
this.childNode = this.modelValue
|
||||||
mounted() {
|
}
|
||||||
this.childNode = this.modelValue
|
},
|
||||||
},
|
mounted() {
|
||||||
methods: {
|
this.childNode = this.modelValue
|
||||||
show() {
|
},
|
||||||
this.form = cloneDeep(this.childNode)
|
methods: {
|
||||||
this.isEditTitle = false
|
show() {
|
||||||
this.drawer = true
|
this.form = cloneDeep(this.childNode)
|
||||||
this.selectedButtonInfo = this.form.properties.buttonInfo
|
this.isEditTitle = false
|
||||||
this.fieldInfo = this.form.properties.fieldInfo
|
this.drawer = true
|
||||||
// 初始化自定义表单字段值
|
this.selectedButtonInfo =
|
||||||
this.initFormInfo()
|
this.form && this.form.propertie && this.form.properties.buttonInfo
|
||||||
},
|
? this.form.properties.buttonInfo
|
||||||
initFormInfo() {
|
: {}
|
||||||
const processConfigInfo = cloneDeep(this.processConfigInfo)
|
this.fieldInfo = this.form.properties.fieldInfo
|
||||||
if (!this.form.properties.formInfo.find((f) => f.key === 'FORM_URL')) {
|
// 初始化自定义表单字段值
|
||||||
this.formData.FORM_URL = processConfigInfo.processStartTaskFormUrl
|
this.initFormInfo()
|
||||||
} else {
|
},
|
||||||
this.formData.FORM_URL = this.form.properties.formInfo.find((f) => f.key === 'FORM_URL').value
|
initFormInfo() {
|
||||||
}
|
const processConfigInfo = cloneDeep(this.processConfigInfo)
|
||||||
if (!this.form.properties.formInfo.find((f) => f.key === 'MOBILE_FORM_URL')) {
|
if (!this.form.properties.formInfo.find(f => f.key === 'FORM_URL')) {
|
||||||
this.formData.MOBILE_FORM_URL = processConfigInfo.processStartTaskMobileFormUrl
|
this.formData.FORM_URL = processConfigInfo.processStartTaskFormUrl
|
||||||
} else {
|
} else {
|
||||||
this.formData.MOBILE_FORM_URL = this.form.properties.formInfo.find((f) => f.key === 'MOBILE_FORM_URL').value
|
this.formData.FORM_URL = this.form.properties.formInfo.find(f => f.key === 'FORM_URL').value
|
||||||
}
|
}
|
||||||
},
|
if (!this.form.properties.formInfo.find(f => f.key === 'MOBILE_FORM_URL')) {
|
||||||
editTitle() {
|
this.formData.MOBILE_FORM_URL = processConfigInfo.processStartTaskMobileFormUrl
|
||||||
this.isEditTitle = true
|
} else {
|
||||||
this.$nextTick(() => {
|
this.formData.MOBILE_FORM_URL = this.form.properties.formInfo.find(
|
||||||
this.$refs.nodeTitle.focus()
|
f => f.key === 'MOBILE_FORM_URL'
|
||||||
})
|
).value
|
||||||
},
|
}
|
||||||
saveTitle() {
|
},
|
||||||
this.isEditTitle = false
|
editTitle() {
|
||||||
},
|
this.isEditTitle = true
|
||||||
save() {
|
this.$nextTick(() => {
|
||||||
this.form.id = this.$TOOL.snowyUuid()
|
this.$refs.nodeTitle.focus()
|
||||||
this.form.properties.buttonInfo = this.$refs.propButtonInfo.selectedButtonKeyList()
|
})
|
||||||
this.form.properties.executionListenerInfo = this.$refs.propExecutionListenerInfoRef.selectedListenerList()
|
},
|
||||||
this.form.properties.taskListenerInfo = this.$refs.propTaskListenerInfoRef.selectedListenerList()
|
saveTitle() {
|
||||||
if (this.recordData.formType === 'DESIGN') {
|
this.isEditTitle = false
|
||||||
this.form.properties.fieldInfo = this.$refs.propFieldInfo.selectedFieldList()
|
},
|
||||||
this.form.dataLegal = true
|
save() {
|
||||||
this.$emit('update:modelValue', this.form)
|
this.form.id = this.$TOOL.snowyUuid()
|
||||||
this.drawer = false
|
this.form.properties.buttonInfo = this.$refs.propButtonInfo.selectedButtonKeyList()
|
||||||
} else {
|
this.form.properties.executionListenerInfo = this.$refs.propExecutionListenerInfoRef.selectedListenerList()
|
||||||
this.$refs.startTaskFormRef
|
this.form.properties.taskListenerInfo = this.$refs.propTaskListenerInfoRef.selectedListenerList()
|
||||||
.validate()
|
if (this.recordData.formType === 'DESIGN') {
|
||||||
.then((values) => {
|
this.form.properties.fieldInfo = this.$refs.propFieldInfo.selectedFieldList()
|
||||||
this.form.dataLegal = true
|
this.form.dataLegal = true
|
||||||
this.form.properties.formInfo = cloneDeep(config.nodeModel.formInfo)
|
this.$emit('update:modelValue', this.form)
|
||||||
this.form.properties.formInfo.find((f) => f.key === 'FORM_URL').value = values.FORM_URL
|
this.drawer = false
|
||||||
this.form.properties.formInfo.find((f) => f.key === 'MOBILE_FORM_URL').value = values.MOBILE_FORM_URL
|
} else {
|
||||||
this.$emit('update:modelValue', this.form)
|
this.$refs.startTaskFormRef
|
||||||
this.drawer = false
|
.validate()
|
||||||
})
|
.then(values => {
|
||||||
.catch((err) => {})
|
this.form.dataLegal = true
|
||||||
}
|
this.form.properties.formInfo = cloneDeep(config.nodeModel.formInfo)
|
||||||
},
|
this.form.properties.formInfo.find(f => f.key === 'FORM_URL').value = values.FORM_URL
|
||||||
// eslint-disable-next-line no-unused-vars
|
this.form.properties.formInfo.find(f => f.key === 'MOBILE_FORM_URL').value =
|
||||||
toText(childNode) {
|
values.MOBILE_FORM_URL
|
||||||
if (childNode.dataLegal) {
|
this.$emit('update:modelValue', this.form)
|
||||||
return '系统自动配置参与人'
|
this.drawer = false
|
||||||
} else {
|
})
|
||||||
return false
|
.catch(err => {})
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
}
|
// eslint-disable-next-line no-unused-vars
|
||||||
}
|
toText(childNode) {
|
||||||
|
if (childNode.dataLegal) {
|
||||||
|
return '系统自动配置参与人'
|
||||||
|
} else {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
.font-span {
|
.font-span {
|
||||||
padding-bottom: 8px;
|
padding-bottom: 8px;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -11,10 +11,10 @@
|
|||||||
<span v-else class="placeholder">请选择</span>
|
<span v-else class="placeholder">请选择</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<add-node v-model="childNode.childNode" />
|
<addNode v-model="childNode.childNode" />
|
||||||
|
|
||||||
<!-- 抽屉 -->
|
<!-- 抽屉 -->
|
||||||
<xn-form-container
|
<formContainer
|
||||||
v-model:visible="drawer"
|
v-model:visible="drawer"
|
||||||
:destroy-on-close="true"
|
:destroy-on-close="true"
|
||||||
:width="700"
|
:width="700"
|
||||||
@@ -25,79 +25,80 @@
|
|||||||
<label v-if="!isEditTitle" @click="editTitle"
|
<label v-if="!isEditTitle" @click="editTitle"
|
||||||
>{{ form.title }}<edit-outlined class="node-wrap-drawer-title-edit"
|
>{{ form.title }}<edit-outlined class="node-wrap-drawer-title-edit"
|
||||||
/></label>
|
/></label>
|
||||||
<a-input
|
<el-input
|
||||||
v-if="isEditTitle"
|
v-if="isEditTitle"
|
||||||
ref="nodeTitle"
|
ref="nodeTitle"
|
||||||
v-model:value="form.title"
|
v-model="form.title"
|
||||||
allow-clear
|
allow-clear
|
||||||
@blur="saveTitle"
|
@blur="saveTitle"
|
||||||
@keyup.enter="saveTitle"
|
@keyup.enter="saveTitle"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<a-layout-content>
|
<el-container>
|
||||||
<a-tabs v-model:activeKey="activeKey">
|
{{ activeKey }}
|
||||||
<a-tab-pane key="1" tab="人员配置" force-render>
|
<el-tabs v-model="activeKey">
|
||||||
|
<el-tab-pane name="1" label="人员配置" lazy>
|
||||||
<div v-show="!nodeLegal" style="margin-bottom: 10px">
|
<div v-show="!nodeLegal" style="margin-bottom: 10px">
|
||||||
<a-alert message="请配置节点相关人员!" type="error" />
|
<el-alert message="请配置节点相关人员!" type="error" />
|
||||||
</div>
|
</div>
|
||||||
<a-form layout="vertical" :model="userTypeForm" ref="userTypeFormRef">
|
<el-form layout="vertical" :model="userTypeForm" ref="userTypeFormRef">
|
||||||
<div class="mb-3">
|
<div class="mb-3">
|
||||||
<span class="left-span-label">选择审批人员类型</span>
|
<span class="left-span-label">选择审批人员类型</span>
|
||||||
</div>
|
</div>
|
||||||
<a-radio-group v-model:value="userSelectionType" style="width: 100%">
|
<el-radio-group v-model:value="userSelectionType" style="width: 100%">
|
||||||
<a-row style="padding-bottom: 10px">
|
<el-row style="padding-bottom: 10px">
|
||||||
<a-col :span="8">
|
<el-col :span="8">
|
||||||
<a-radio value="ORG" @click="selectionClick('ORG')">机构</a-radio>
|
<el-radio value="ORG" @click="selectionClick('ORG')">机构</el-radio>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="8">
|
<el-col :span="8">
|
||||||
<a-radio value="ROLE" @click="selectionClick('ROLE')">角色</a-radio>
|
<el-radio value="ROLE" @click="selectionClick('ROLE')">角色</el-radio>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="8">
|
<el-col :span="8">
|
||||||
<a-radio value="POSITION" @click="selectionClick('POSITION')">职位</a-radio>
|
<el-radio value="POSITION" @click="selectionClick('POSITION')">职位</el-radio>
|
||||||
</a-col>
|
</el-col>
|
||||||
</a-row>
|
</el-row>
|
||||||
<a-row style="padding-bottom: 10px">
|
<el-row style="padding-bottom: 10px">
|
||||||
<a-col :span="8">
|
<el-col :span="8">
|
||||||
<a-radio value="ORG_LEADER" @click="selectionClick('ORG_LEADER')">部门主管</a-radio>
|
<el-radio value="ORG_LEADER" @click="selectionClick('ORG_LEADER')">部门主管</el-radio>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="8">
|
<el-col :span="8">
|
||||||
<a-radio value="SUPERVISOR" @click="selectionClick('SUPERVISOR')">上级主管</a-radio>
|
<el-radio value="SUPERVISOR" @click="selectionClick('SUPERVISOR')">上级主管</el-radio>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="8">
|
<el-col :span="8">
|
||||||
<a-radio value="MUL_LEVEL_SUPERVISOR" @click="selectionClick('MUL_LEVEL_SUPERVISOR')"
|
<el-radio value="MUL_LEVEL_SUPERVISOR" @click="selectionClick('MUL_LEVEL_SUPERVISOR')"
|
||||||
>连续多级主管</a-radio
|
>连续多级主管</el-radio
|
||||||
>
|
>
|
||||||
</a-col>
|
</el-col>
|
||||||
</a-row>
|
</el-row>
|
||||||
<a-row style="padding-bottom: 10px">
|
<el-row style="padding-bottom: 10px">
|
||||||
<a-col :span="8">
|
<el-col :span="8">
|
||||||
<a-radio value="USER" @click="selectionClick('USER')">用户</a-radio>
|
<el-radio value="USER" @click="selectionClick('USER')">用户</el-radio>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="8">
|
<el-col :span="8">
|
||||||
<a-radio value="FORM_USER" @click="selectionClick('FORM_USER')">表单内的人</a-radio>
|
<el-radio value="FORM_USER" @click="selectionClick('FORM_USER')">表单内的人</el-radio>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="8">
|
<el-col :span="8">
|
||||||
<a-radio value="FORM_USER_SUPERVISOR" @click="selectionClick('FORM_USER_SUPERVISOR')"
|
<el-radio value="FORM_USER_SUPERVISOR" @click="selectionClick('FORM_USER_SUPERVISOR')"
|
||||||
>表单内的人上级主管</a-radio
|
>表单内的人上级主管</el-radio
|
||||||
>
|
>
|
||||||
</a-col>
|
</el-col>
|
||||||
</a-row>
|
</el-row>
|
||||||
<a-row style="padding-bottom: 10px">
|
<el-row style="padding-bottom: 10px">
|
||||||
<a-col :span="8">
|
<el-col :span="8">
|
||||||
<a-radio
|
<el-radio
|
||||||
value="FORM_USER_MUL_LEVEL_SUPERVISOR"
|
value="FORM_USER_MUL_LEVEL_SUPERVISOR"
|
||||||
@click="selectionClick('FORM_USER_MUL_LEVEL_SUPERVISOR')"
|
@click="selectionClick('FORM_USER_MUL_LEVEL_SUPERVISOR')"
|
||||||
>表单内的人连续多级主管</a-radio
|
>表单内的人连续多级主管</el-radio
|
||||||
>
|
>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="8">
|
<el-col :span="8">
|
||||||
<a-radio value="INITIATOR" @click="selectionClick('INITIATOR')">发起人</a-radio>
|
<el-radio value="INITIATOR" @click="selectionClick('INITIATOR')">发起人</el-radio>
|
||||||
</a-col>
|
</el-col>
|
||||||
<a-col :span="8" />
|
<el-col :span="8" />
|
||||||
</a-row>
|
</el-row>
|
||||||
</a-radio-group>
|
</el-radio-group>
|
||||||
<a-form-item
|
<el-form-item
|
||||||
class="mt-2"
|
class="mt-2"
|
||||||
v-if="
|
v-if="
|
||||||
recordData.formType === 'DEFINE' &&
|
recordData.formType === 'DEFINE' &&
|
||||||
@@ -109,13 +110,13 @@
|
|||||||
:rules="[{ required: true, message: '请输入人员变量' }]"
|
:rules="[{ required: true, message: '请输入人员变量' }]"
|
||||||
>
|
>
|
||||||
<template #label>
|
<template #label>
|
||||||
<a-tooltip>
|
<el-tooltip>
|
||||||
<template #title>单个字段可以采用:字段名,多个采用:字段名1,字段名2,字段名3</template>
|
<template #title>单个字段可以采用:字段名,多个采用:字段名1,字段名2,字段名3</template>
|
||||||
<question-circle-outlined />
|
<question-circle-outlined />
|
||||||
人员变量:
|
人员变量:
|
||||||
</a-tooltip>
|
</el-tooltip>
|
||||||
</template>
|
</template>
|
||||||
<a-input
|
<el-input
|
||||||
style="width: 50%"
|
style="width: 50%"
|
||||||
v-model:value="userTypeForm.formUser"
|
v-model:value="userTypeForm.formUser"
|
||||||
allow-clear
|
allow-clear
|
||||||
@@ -123,22 +124,22 @@
|
|||||||
@keyup.enter="customFormUser"
|
@keyup.enter="customFormUser"
|
||||||
placeholder="请输入人员变量"
|
placeholder="请输入人员变量"
|
||||||
/>
|
/>
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
<div v-if="seleType" class="mt-2">
|
<div v-if="seleType" class="mt-2">
|
||||||
<a-button type="primary" @click="openSelector" size="small">
|
<el-button type="primary" @click="openSelector" size="small">
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<search-outlined />
|
<search-outlined />
|
||||||
</template>
|
</template>
|
||||||
选择
|
选择
|
||||||
</a-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
<div class="mt-2">
|
<div class="mt-2">
|
||||||
<prop-tag
|
<prop-tag
|
||||||
v-if="form.properties.participateInfo.length > 0 && form.properties.participateInfo[0].value !== ''"
|
v-if="form.properties&&form.properties.participateInfo&&form.properties.participateInfo.length > 0 && form.properties.participateInfo[0].value !== ''"
|
||||||
:tag-list="form.properties.participateInfo[0]"
|
:tag-list="form.properties.participateInfo[0]"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<a-form-item
|
<el-form-item
|
||||||
class="mt-2"
|
class="mt-2"
|
||||||
v-if="
|
v-if="
|
||||||
userSelectionType === 'SUPERVISOR' ||
|
userSelectionType === 'SUPERVISOR' ||
|
||||||
@@ -154,108 +155,108 @@
|
|||||||
name="levelSupervisor"
|
name="levelSupervisor"
|
||||||
:rules="[{ required: true, message: '请选择主管级别' }]"
|
:rules="[{ required: true, message: '请选择主管级别' }]"
|
||||||
>
|
>
|
||||||
<a-select
|
<el-select
|
||||||
style="width: 50%"
|
style="width: 50%"
|
||||||
v-model:value="userTypeForm.levelSupervisor"
|
v-model:value="userTypeForm.levelSupervisor"
|
||||||
placeholder="请选择主管级别"
|
placeholder="请选择主管级别"
|
||||||
@change="levelSupervisorChange"
|
@change="levelSupervisorChange"
|
||||||
:options="levelSupervisorList"
|
:options="levelSupervisorList"
|
||||||
/>
|
/>
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
</a-form>
|
</el-form>
|
||||||
</a-tab-pane>
|
</el-tab-pane>
|
||||||
<a-tab-pane key="2" tab="审批配置" force-render>
|
<el-tab-pane name="2" label="审批配置" lazy>
|
||||||
<span class="left-span-label">配置审批方式</span>
|
<span class="left-span-label">配置审批方式</span>
|
||||||
<a-form label-position="top" layout="vertical" class="mt-2">
|
<el-form label-position="top" layout="vertical" class="mt-2">
|
||||||
<div v-show="!nodeLegal" style="margin-bottom: 10px">
|
<div v-show="!nodeLegal" style="margin-bottom: 10px">
|
||||||
<a-alert message="请配置节点相关人员!" type="error" />
|
<el-alert message="请配置节点相关人员!" type="error" />
|
||||||
</div>
|
</div>
|
||||||
<a-form-item label="任务节点类型">
|
<el-form-item label="任务节点类型">
|
||||||
<a-radio-group v-model:value="form.properties.configInfo.userTaskType">
|
<el-radio-group v-model:value="form.properties.configInfo.userTaskType">
|
||||||
<a-radio
|
<el-radio
|
||||||
v-for="userTaskType in userTaskTypeList"
|
v-for="userTaskType in userTaskTypeList"
|
||||||
:key="userTaskType.value"
|
:key="userTaskType.value"
|
||||||
:value="userTaskType.value"
|
:value="userTaskType.value"
|
||||||
>{{ userTaskType.label }}</a-radio
|
>{{ userTaskType.label }}</el-radio
|
||||||
>
|
>
|
||||||
</a-radio-group>
|
</el-radio-group>
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
<a-form-item label="审批退回类型">
|
<el-form-item label="审批退回类型">
|
||||||
<a-radio-group v-model:value="form.properties.configInfo.userTaskRejectType">
|
<el-radio-group v-model:value="form.properties.configInfo.userTaskRejectType">
|
||||||
<a-radio
|
<el-radio
|
||||||
v-for="userTaskRejectType in userTaskRejectTypeList"
|
v-for="userTaskRejectType in userTaskRejectTypeList"
|
||||||
:key="userTaskRejectType.value"
|
:key="userTaskRejectType.value"
|
||||||
:value="userTaskRejectType.value"
|
:value="userTaskRejectType.value"
|
||||||
>{{ userTaskRejectType.label }}
|
>{{ userTaskRejectType.label }}
|
||||||
</a-radio>
|
</el-radio>
|
||||||
<br />
|
<br />
|
||||||
</a-radio-group>
|
</el-radio-group>
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
<a-form-item label="多人审批类型">
|
<el-form-item label="多人审批类型">
|
||||||
<a-radio-group v-model:value="form.properties.configInfo.userTaskMulApproveType">
|
<el-radio-group v-model:value="form.properties.configInfo.userTaskMulApproveType">
|
||||||
<a-radio
|
<el-radio
|
||||||
v-for="userTaskMulApproveType in userTaskMulApproveTypeList"
|
v-for="userTaskMulApproveType in userTaskMulApproveTypeList"
|
||||||
:key="userTaskMulApproveType.value"
|
:key="userTaskMulApproveType.value"
|
||||||
:value="userTaskMulApproveType.value"
|
:value="userTaskMulApproveType.value"
|
||||||
>{{ userTaskMulApproveType.label }}
|
>{{ userTaskMulApproveType.label }}
|
||||||
</a-radio>
|
</el-radio>
|
||||||
<br />
|
<br />
|
||||||
</a-radio-group>
|
</el-radio-group>
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
<a-form-item label="审批人员为空时">
|
<el-form-item label="审批人员为空时">
|
||||||
<a-radio-group v-model:value="form.properties.configInfo.userTaskEmptyApproveType">
|
<el-radio-group v-model:value="form.properties.configInfo.userTaskEmptyApproveType">
|
||||||
<a-radio
|
<el-radio
|
||||||
v-for="userTaskEmptyApproveType in userTaskEmptyApproveTypeList"
|
v-for="userTaskEmptyApproveType in userTaskEmptyApproveTypeList"
|
||||||
:key="userTaskEmptyApproveType.value"
|
:key="userTaskEmptyApproveType.value"
|
||||||
:value="userTaskEmptyApproveType.value"
|
:value="userTaskEmptyApproveType.value"
|
||||||
@change="userTaskEmptyApproveTypeChange"
|
@change="userTaskEmptyApproveTypeChange"
|
||||||
>{{ userTaskEmptyApproveType.label }}
|
>{{ userTaskEmptyApproveType.label }}
|
||||||
</a-radio>
|
</el-radio>
|
||||||
</a-radio-group>
|
</el-radio-group>
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
<a-form-item
|
<el-form-item
|
||||||
v-if="form.properties.configInfo.userTaskEmptyApproveType === 'AUTO_TURN'"
|
v-if="form.properties.configInfo.userTaskEmptyApproveType === 'AUTO_TURN'"
|
||||||
label="审批人为空时转交人"
|
label="审批人为空时转交人"
|
||||||
>
|
>
|
||||||
<p><a-button type="primary" size="small" @click="seleApproveUser">选择人员</a-button></p>
|
<p><el-button type="primary" size="small" @click="seleApproveUser">选择人员</el-button></p>
|
||||||
<a-tag
|
<el-tag
|
||||||
v-if="form.properties.configInfo.userTaskEmptyApproveUserArray.length > 0"
|
v-if="form.properties.configInfo.userTaskEmptyApproveUserArray.length > 0"
|
||||||
color="orange"
|
color="orange"
|
||||||
closable
|
closable
|
||||||
@close="closeApproveUserTag"
|
@close="closeApproveUserTag"
|
||||||
>
|
>
|
||||||
{{ form.properties.configInfo.userTaskEmptyApproveUserArray[0].name }}</a-tag
|
{{ form.properties.configInfo.userTaskEmptyApproveUserArray[0].name }}</el-tag
|
||||||
>
|
>
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
</a-form>
|
</el-form>
|
||||||
</a-tab-pane>
|
</el-tab-pane>
|
||||||
<a-tab-pane key="3" tab="按钮配置" force-render>
|
<el-tab-pane name="3" label="按钮配置" lazy>
|
||||||
<prop-button-info
|
<prop-button-info
|
||||||
ref="propButtonInfo"
|
ref="propButtonInfo"
|
||||||
:button-info="selectedButtonInfo"
|
:button-info="selectedButtonInfo"
|
||||||
:show-button="defaultButtonkey"
|
:show-button="defaultButtonkey"
|
||||||
:no-checked="userTaskNoCheckedButtonkey"
|
:no-checked="userTaskNoCheckedButtonkey"
|
||||||
/>
|
/>
|
||||||
</a-tab-pane>
|
</el-tab-pane>
|
||||||
<a-tab-pane key="4" tab="字段配置" force-render v-if="recordData.formType === 'DESIGN'">
|
<el-tab-pane name="4" label="字段配置" lazy v-if="recordData.formType === 'DESIGN'">
|
||||||
<prop-field-info
|
<prop-field-info
|
||||||
ref="propFieldInfo"
|
ref="propFieldInfo"
|
||||||
:field-info="fieldInfo"
|
:field-info="fieldInfo"
|
||||||
:default-field-model="defaultFieldModel"
|
:default-field-model="defaultFieldModel"
|
||||||
:form-field-list-value="formFieldListValue"
|
:form-field-list-value="formFieldListValue"
|
||||||
/>
|
/>
|
||||||
</a-tab-pane>
|
</el-tab-pane>
|
||||||
<a-tab-pane key="5" tab="表单配置" force-render v-else>
|
<el-tab-pane name="5" label="表单配置" lazy v-else>
|
||||||
<div class="mb-2">
|
<div class="mb-2">
|
||||||
<span class="left-span-label">参与者可以使用的表单</span>
|
<span class="left-span-label">参与者可以使用的表单</span>
|
||||||
</div>
|
</div>
|
||||||
<a-form ref="userTaskFormRef" :model="formData" layout="vertical">
|
<el-form ref="userTaskFormRef" :model="formData" layout="vertical">
|
||||||
<a-form-item
|
<el-form-item
|
||||||
label="节点表单"
|
label="节点表单"
|
||||||
name="FORM_URL"
|
name="FORM_URL"
|
||||||
:rules="[{ required: true, message: '请输入节点表单组件地址' }]"
|
:rules="[{ required: true, message: '请输入节点表单组件地址' }]"
|
||||||
>
|
>
|
||||||
<a-input
|
<el-input
|
||||||
v-model:value="formData.FORM_URL"
|
v-model:value="formData.FORM_URL"
|
||||||
addon-before="src/views/flw/customform/"
|
addon-before="src/views/flw/customform/"
|
||||||
addon-after=".vue"
|
addon-after=".vue"
|
||||||
@@ -263,61 +264,61 @@
|
|||||||
allow-clear
|
allow-clear
|
||||||
>
|
>
|
||||||
<template #suffix>
|
<template #suffix>
|
||||||
<a-button
|
<el-button
|
||||||
v-if="formData.FORM_URL"
|
v-if="formData.FORM_URL"
|
||||||
type="primary"
|
type="primary"
|
||||||
size="small"
|
size="small"
|
||||||
@click="$refs.previewCustomFormRef.onOpen(formData.FORM_URL)"
|
@click="$refs.previewCustomFormRef.onOpen(formData.FORM_URL)"
|
||||||
>
|
>
|
||||||
预览
|
预览
|
||||||
</a-button>
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
</a-input>
|
</el-input>
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
<a-form-item
|
<el-form-item
|
||||||
label="移动端节点表单"
|
label="移动端节点表单"
|
||||||
name="MOBILE_FORM_URL"
|
name="MOBILE_FORM_URL"
|
||||||
:rules="[{ required: true, message: '请输入移动端节点表单组件地址' }]"
|
:rules="[{ required: true, message: '请输入移动端节点表单组件地址' }]"
|
||||||
>
|
>
|
||||||
<a-input
|
<el-input
|
||||||
v-model:value="formData.MOBILE_FORM_URL"
|
v-model:value="formData.MOBILE_FORM_URL"
|
||||||
addon-before="pages/flw/customform/"
|
addon-before="pages/flw/customform/"
|
||||||
addon-after=".vue"
|
addon-after=".vue"
|
||||||
placeholder="请输入移动端节点表单组件地址"
|
placeholder="请输入移动端节点表单组件地址"
|
||||||
allow-clear
|
allow-clear
|
||||||
/>
|
/>
|
||||||
</a-form-item>
|
</el-form-item>
|
||||||
</a-form>
|
</el-form>
|
||||||
</a-tab-pane>
|
</el-tab-pane>
|
||||||
<a-tab-pane key="6" tab="执行监听" force-render>
|
<el-tab-pane name="6" label="执行监听" lazy>
|
||||||
<prop-listener-info
|
<prop-listener-info
|
||||||
ref="propExecutionListenerInfoRef"
|
ref="propExecutionListenerInfoRef"
|
||||||
:listener-value="form.properties.executionListenerInfo"
|
:listener-value="form.properties.executionListenerInfo"
|
||||||
:default-listener-list="executionListenerInfo"
|
:default-listener-list="executionListenerInfo"
|
||||||
:listener-value-array="executionListenerArray"
|
:listener-value-array="executionListenerArray"
|
||||||
/>
|
/>
|
||||||
</a-tab-pane>
|
</el-tab-pane>
|
||||||
<a-tab-pane key="7" tab="节点监听" force-render>
|
<el-tab-pane name="7" label="节点监听" lazy>
|
||||||
<prop-listener-info
|
<prop-listener-info
|
||||||
ref="propTaskListenerInfoRef"
|
ref="propTaskListenerInfoRef"
|
||||||
:listener-value="form.properties.taskListenerInfo"
|
:listener-value="form.properties.taskListenerInfo"
|
||||||
:default-listener-list="taskListenerInfo"
|
:default-listener-list="taskListenerInfo"
|
||||||
:listener-value-array="taskListenerArray"
|
:listener-value-array="taskListenerArray"
|
||||||
/>
|
/>
|
||||||
</a-tab-pane>
|
</el-tab-pane>
|
||||||
</a-tabs>
|
</el-tabs>
|
||||||
</a-layout-content>
|
</el-container>
|
||||||
<template #footer>
|
<template #footer>
|
||||||
<a-button type="primary" style="margin-right: 8px" @click="save">保存</a-button>
|
<el-button type="primary" style="margin-right: 8px" @click="save">保存</el-button>
|
||||||
<a-button @click="drawer = false">取消</a-button>
|
<el-button @click="drawer = false">取消</el-button>
|
||||||
</template>
|
</template>
|
||||||
</xn-form-container>
|
</formContainer>
|
||||||
<role-selector-plus
|
<role-selector-plus
|
||||||
ref="roleselectorPlus"
|
ref="roleselectorPlus"
|
||||||
:org-tree-api="selectorApiFunction.orgTreeApi"
|
:org-tree-api="selectorApiFunction.orgTreeApi"
|
||||||
:role-page-api="selectorApiFunction.rolePageApi"
|
:role-page-api="selectorApiFunction.rolePageApi"
|
||||||
:checked-role-list-api="selectorApiFunction.checkedRoleListApi"
|
:checked-role-list-api="selectorApiFunction.checkedRoleListApi"
|
||||||
:data-is-converter-flw="true"
|
:datel-is-converter-flw="true"
|
||||||
@onBack="callBack"
|
@onBack="callBack"
|
||||||
/>
|
/>
|
||||||
<user-selector-plus
|
<user-selector-plus
|
||||||
@@ -325,7 +326,7 @@
|
|||||||
:org-tree-api="selectorApiFunction.orgTreeApi"
|
:org-tree-api="selectorApiFunction.orgTreeApi"
|
||||||
:user-page-api="selectorApiFunction.userPageApi"
|
:user-page-api="selectorApiFunction.userPageApi"
|
||||||
:checked-user-list-api="selectorApiFunction.checkedUserListApi"
|
:checked-user-list-api="selectorApiFunction.checkedUserListApi"
|
||||||
:data-is-converter-flw="true"
|
:datel-is-converter-flw="true"
|
||||||
@onBack="callBack"
|
@onBack="callBack"
|
||||||
/>
|
/>
|
||||||
<pos-selector-plus
|
<pos-selector-plus
|
||||||
@@ -333,7 +334,7 @@
|
|||||||
:org-tree-api="selectorApiFunction.orgTreeApi"
|
:org-tree-api="selectorApiFunction.orgTreeApi"
|
||||||
:pos-page-api="selectorApiFunction.posPageApi"
|
:pos-page-api="selectorApiFunction.posPageApi"
|
||||||
:checked-pos-list-api="selectorApiFunction.checkedPosListApi"
|
:checked-pos-list-api="selectorApiFunction.checkedPosListApi"
|
||||||
:data-is-converter-flw="true"
|
:datel-is-converter-flw="true"
|
||||||
@onBack="callBack"
|
@onBack="callBack"
|
||||||
/>
|
/>
|
||||||
<org-selector-plus
|
<org-selector-plus
|
||||||
@@ -341,7 +342,7 @@
|
|||||||
:org-tree-api="selectorApiFunction.orgTreeApi"
|
:org-tree-api="selectorApiFunction.orgTreeApi"
|
||||||
:org-page-api="selectorApiFunction.orgPageApi"
|
:org-page-api="selectorApiFunction.orgPageApi"
|
||||||
:checked-org-list-api="selectorApiFunction.checkedOrgListApi"
|
:checked-org-list-api="selectorApiFunction.checkedOrgListApi"
|
||||||
:data-is-converter-flw="true"
|
:datel-is-converter-flw="true"
|
||||||
@onBack="callBack"
|
@onBack="callBack"
|
||||||
/>
|
/>
|
||||||
<form-user-selector ref="formuserselector" :form-field-list="formFieldListValue" @click="formuserClick" />
|
<form-user-selector ref="formuserselector" :form-field-list="formFieldListValue" @click="formuserClick" />
|
||||||
@@ -371,7 +372,7 @@
|
|||||||
import orgSelectorPlus from '@/components/Selector/orgSelectorPlus.vue'
|
import orgSelectorPlus from '@/components/Selector/orgSelectorPlus.vue'
|
||||||
import propTag from './prop/propTag.vue'
|
import propTag from './prop/propTag.vue'
|
||||||
import PreviewCustomForm from '@/components/XnWorkflow/nodes/common/previewCustomForm.vue'
|
import PreviewCustomForm from '@/components/XnWorkflow/nodes/common/previewCustomForm.vue'
|
||||||
|
import formContainer from '@/components/formContainer/index.vue';
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
addNode,
|
addNode,
|
||||||
@@ -384,7 +385,8 @@
|
|||||||
posSelectorPlus,
|
posSelectorPlus,
|
||||||
orgSelectorPlus,
|
orgSelectorPlus,
|
||||||
propTag,
|
propTag,
|
||||||
PreviewCustomForm
|
PreviewCustomForm,
|
||||||
|
formContainer
|
||||||
},
|
},
|
||||||
// inject: ['select'],
|
// inject: ['select'],
|
||||||
props: {
|
props: {
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<xn-form-container
|
<formContainer
|
||||||
v-model:visible="drawer"
|
v-model:visible="drawer"
|
||||||
:destroy-on-close="true"
|
:destroy-on-close="true"
|
||||||
:title="modelTitle"
|
:title="modelTitle"
|
||||||
@@ -18,29 +18,28 @@
|
|||||||
<div class="mb-2">
|
<div class="mb-2">
|
||||||
<span class="left-span-label">配置使用该流程的人员</span>
|
<span class="left-span-label">配置使用该流程的人员</span>
|
||||||
</div>
|
</div>
|
||||||
<el-button type="primary" round @click="selectionParticipants('ORG')" size="small">
|
<el-button type="primary" :icon="Plus" round @click="selectionParticipants('ORG')" size="small">
|
||||||
<Plus/>
|
|
||||||
选择机构
|
选择机构
|
||||||
</el-button>
|
</el-button>
|
||||||
<p />
|
<p />
|
||||||
<prop-tag :tagList="getTagList('ORG')" />
|
<prop-tag :tagList="getTagList('ORG')" />
|
||||||
<el-divider />
|
<el-divider />
|
||||||
<el-button type="primary" round @click="selectionParticipants('ROLE')" size="small">
|
<el-button type="primary" round @click="selectionParticipants('ROLE')" size="small">
|
||||||
<plus-outlined />
|
<!-- <plus-outlined /> -->
|
||||||
选择角色
|
选择角色
|
||||||
</el-button>
|
</el-button>
|
||||||
<p />
|
<p />
|
||||||
<prop-tag :tagList="getTagList('ROLE')" />
|
<prop-tag :tagList="getTagList('ROLE')" />
|
||||||
<el-divider />
|
<el-divider />
|
||||||
<el-button type="primary" round @click="selectionParticipants('POSITION')" size="small">
|
<el-button type="primary" round @click="selectionParticipants('POSITION')" size="small">
|
||||||
<plus-outlined />
|
<!-- <plus-outlined /> -->
|
||||||
选择职位
|
选择职位
|
||||||
</el-button>
|
</el-button>
|
||||||
<p />
|
<p />
|
||||||
<prop-tag :tagList="getTagList('POSITION')" />
|
<prop-tag :tagList="getTagList('POSITION')" />
|
||||||
<el-divider />
|
<el-divider />
|
||||||
<el-button type="primary" round @click="selectionParticipants('USER')" size="small">
|
<el-button type="primary" round @click="selectionParticipants('USER')" size="small">
|
||||||
<plus-outlined />
|
<!-- <plus-outlined /> -->
|
||||||
选择用户
|
选择用户
|
||||||
</el-button>
|
</el-button>
|
||||||
<p />
|
<p />
|
||||||
@@ -59,7 +58,7 @@
|
|||||||
:rules="[{ required: true, message: '请选择流水号' }]"
|
:rules="[{ required: true, message: '请选择流水号' }]"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-select
|
||||||
v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processSnTemplateId"
|
v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processSnTemplateId"
|
||||||
v-model:value="form.properties.configInfo.processSnTemplateId"
|
v-model:value="form.properties.configInfo.processSnTemplateId"
|
||||||
placeholder="请选择流水号"
|
placeholder="请选择流水号"
|
||||||
:options="snTemplateArray"
|
:options="snTemplateArray"
|
||||||
@@ -75,6 +74,7 @@
|
|||||||
:rules="[{ required: true, message: '请选择打印模板' }]"
|
:rules="[{ required: true, message: '请选择打印模板' }]"
|
||||||
>
|
>
|
||||||
<el-select
|
<el-select
|
||||||
|
v-if="form&&form.properties&&form.properties.configInfo.processPrintTemplateId"
|
||||||
v-model:value="form.properties.configInfo.processPrintTemplateId"
|
v-model:value="form.properties.configInfo.processPrintTemplateId"
|
||||||
placeholder="请选择打印模板"
|
placeholder="请选择打印模板"
|
||||||
:options="printTemplateArray"
|
:options="printTemplateArray"
|
||||||
@@ -93,7 +93,7 @@
|
|||||||
>
|
>
|
||||||
<template-generator
|
<template-generator
|
||||||
ref="processTitleGenerator"
|
ref="processTitleGenerator"
|
||||||
v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processTitleTemplate"
|
v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processTitleTemplate"
|
||||||
v-model:inputValue="form.properties.configInfo.processTitleTemplate"
|
v-model:inputValue="form.properties.configInfo.processTitleTemplate"
|
||||||
:fieldInfoLis="fieldInfoLis"
|
:fieldInfoLis="fieldInfoLis"
|
||||||
/>
|
/>
|
||||||
@@ -105,16 +105,16 @@
|
|||||||
>
|
>
|
||||||
<template-generator
|
<template-generator
|
||||||
ref="processAbstractGenerator"
|
ref="processAbstractGenerator"
|
||||||
v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processAbstractTemplate"
|
v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processAbstractTemplate"
|
||||||
v-model:inputValue="form.properties.configInfo.processAbstractTemplate"
|
v-model:inputValue="form.properties.configInfo.processAbstractTemplate"
|
||||||
:fieldInfoLis="fieldInfoLis"
|
:fieldInfoLis="fieldInfoLis"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item label="开启自动去重" name="processEnableAutoDistinct">
|
<el-form-item label="开启自动去重" name="processEnableAutoDistinct">
|
||||||
<el-switch v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableAutoDistinct" v-model:checked="form.properties.configInfo.processEnableAutoDistinct" />
|
<el-switch v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableAutoDistinct" v-model:checked="form.properties.configInfo.processEnableAutoDistinct" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableAutoDistinct" name="processAutoDistinctType">
|
<el-form-item v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableAutoDistinct" name="processAutoDistinctType">
|
||||||
<el-radio-group v-model:value="form.properties.configInfo.processAutoDistinctType">
|
<el-radio-group v-model:value="form.properties.configInfo.processAutoDistinctType">
|
||||||
<el-radio
|
<el-radio
|
||||||
v-for="autoDistinctType in processAutoDistinctTypeList"
|
v-for="autoDistinctType in processAutoDistinctTypeList"
|
||||||
@@ -127,12 +127,12 @@
|
|||||||
<el-row :gutter="[10, 0]">
|
<el-row :gutter="[10, 0]">
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="开启审批撤销" name="processEnableRevoke">
|
<el-form-item label="开启审批撤销" name="processEnableRevoke">
|
||||||
<el-switch v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableRevoke" v-model:checked="form.properties.configInfo.processEnableRevoke" />
|
<el-switch v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableRevoke" v-model:checked="form.properties.configInfo.processEnableRevoke" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="开启意见必填" name="processEnableCommentRequired">
|
<el-form-item label="开启意见必填" name="processEnableCommentRequired">
|
||||||
<el-switch v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableCommentRequired" v-model:checked="form.properties.configInfo.processEnableCommentRequired" />
|
<el-switch v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableCommentRequired" v-model:checked="form.properties.configInfo.processEnableCommentRequired" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
@@ -166,88 +166,88 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item label="开启待办通知" name="processEnableTodoNotice">
|
<el-form-item label="开启待办通知" name="processEnableTodoNotice">
|
||||||
<el-switch v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableTodoNotice" v-model:checked="form.properties.configInfo.processEnableTodoNotice" />
|
<el-switch v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableTodoNotice" v-model:checked="form.properties.configInfo.processEnableTodoNotice" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="待办通知方式"
|
label="待办通知方式"
|
||||||
v-show="form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableTodoNotice"
|
v-show="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableTodoNotice"
|
||||||
name="processTodoNoticeChannel"
|
name="processTodoNoticeChannel"
|
||||||
:rules="[{ required: formData.processEnableTodoNotice, message: '请选择通知方式' }]"
|
:rules="[{ required: formData.processEnableTodoNotice, message: '请选择通知方式' }]"
|
||||||
>
|
>
|
||||||
<el-checkbox-group
|
<el-checkbox-group
|
||||||
v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processTodoNoticeChannel"
|
v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processTodoNoticeChannel"
|
||||||
v-model:value="form.properties.configInfo.processTodoNoticeChannel"
|
v-model:value="form.properties.configInfo.processTodoNoticeChannel"
|
||||||
:options="noticeInfoList"
|
:options="noticeInfoList"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="待办通知模板"
|
label="待办通知模板"
|
||||||
v-show="form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableTodoNotice"
|
v-show="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableTodoNotice"
|
||||||
name="processTodoNoticeTemplate"
|
name="processTodoNoticeTemplate"
|
||||||
:rules="[{ required: formData.processEnableTodoNotice, message: '请创造通知模板' }]"
|
:rules="[{ required: formData.processEnableTodoNotice, message: '请创造通知模板' }]"
|
||||||
>
|
>
|
||||||
<template-generator
|
<template-generator
|
||||||
ref="todoNoticeChannelRef"
|
ref="todoNoticeChannelRef"
|
||||||
:fieldInfoLis="fieldInfoLis"
|
:fieldInfoLis="fieldInfoLis"
|
||||||
v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processTodoNoticeTemplate"
|
v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processTodoNoticeTemplate"
|
||||||
v-model:inputValue="form.properties.configInfo.processTodoNoticeTemplate"
|
v-model:inputValue="form.properties.configInfo.processTodoNoticeTemplate"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item label="开启抄送通知" name="processEnableCopyNotice">
|
<el-form-item label="开启抄送通知" name="processEnableCopyNotice">
|
||||||
<el-switch v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableCopyNotice" v-model:checked="form.properties.configInfo.processEnableCopyNotice" />
|
<el-switch v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableCopyNotice" v-model:checked="form.properties.configInfo.processEnableCopyNotice" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="抄送通知方式"
|
label="抄送通知方式"
|
||||||
v-show="form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableCopyNotice"
|
v-show="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableCopyNotice"
|
||||||
name="processCopyNoticeChannel"
|
name="processCopyNoticeChannel"
|
||||||
:rules="[{ required: formData.processEnableCopyNotice, message: '请选择通知方式' }]"
|
:rules="[{ required: formData.processEnableCopyNotice, message: '请选择通知方式' }]"
|
||||||
>
|
>
|
||||||
<el-checkbox-group
|
<el-checkbox-group
|
||||||
v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processCopyNoticeChannel"
|
v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processCopyNoticeChannel"
|
||||||
v-model:value="form.properties.configInfo.processCopyNoticeChannel"
|
v-model:value="form.properties.configInfo.processCopyNoticeChannel"
|
||||||
:options="noticeInfoList"
|
:options="noticeInfoList"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="抄送通知模板"
|
label="抄送通知模板"
|
||||||
v-show="form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableCopyNotice"
|
v-show="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableCopyNotice"
|
||||||
name="processCopyNoticeTemplate"
|
name="processCopyNoticeTemplate"
|
||||||
:rules="[{ required: formData.processEnableCopyNotice, message: '请创造通知模板' }]"
|
:rules="[{ required: formData.processEnableCopyNotice, message: '请创造通知模板' }]"
|
||||||
>
|
>
|
||||||
<template-generator
|
<template-generator
|
||||||
ref="enableCopyNoticeRef"
|
ref="enableCopyNoticeRef"
|
||||||
:fieldInfoLis="fieldInfoLis"
|
:fieldInfoLis="fieldInfoLis"
|
||||||
v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processCopyNoticeTemplate"
|
v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processCopyNoticeTemplate"
|
||||||
v-model:inputValue="form.properties.configInfo.processCopyNoticeTemplate"
|
v-model:inputValue="form.properties.configInfo.processCopyNoticeTemplate"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item label="开启完成通知" name="processEnableCompleteNotice">
|
<el-form-item label="开启完成通知" name="processEnableCompleteNotice">
|
||||||
<el-switch v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableCompleteNotice" v-model:checked="form.properties.configInfo.processEnableCompleteNotice" />
|
<el-switch v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableCompleteNotice" v-model:checked="form.properties.configInfo.processEnableCompleteNotice" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="完成通知方式"
|
label="完成通知方式"
|
||||||
v-show="form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableCompleteNotice"
|
v-show="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableCompleteNotice"
|
||||||
name="processCompleteNoticeChannel"
|
name="processCompleteNoticeChannel"
|
||||||
:rules="[{ required: formData.processEnableCompleteNotice, message: '请选择通知方式' }]"
|
:rules="[{ required: formData.processEnableCompleteNotice, message: '请选择通知方式' }]"
|
||||||
>
|
>
|
||||||
<el-checkbox-group
|
<el-checkbox-group
|
||||||
v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processCompleteNoticeChannel"
|
v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processCompleteNoticeChannel"
|
||||||
v-model:value="form.properties.configInfo.processCompleteNoticeChannel"
|
v-model:value="form.properties.configInfo.processCompleteNoticeChannel"
|
||||||
:options="noticeInfoList"
|
:options="noticeInfoList"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item
|
<el-form-item
|
||||||
label="完成通知模板"
|
label="完成通知模板"
|
||||||
v-show="form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableCompleteNotice"
|
v-show="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processEnableCompleteNotice"
|
||||||
name="processCompleteNoticeTemplate"
|
name="processCompleteNoticeTemplate"
|
||||||
:rules="[{ required: formData.processEnableCompleteNotice, message: '请创造通知模板' }]"
|
:rules="[{ required: formData.processEnableCompleteNotice, message: '请创造通知模板' }]"
|
||||||
>
|
>
|
||||||
<template-generator
|
<template-generator
|
||||||
ref="enableCompleteNoticeRef"
|
ref="enableCompleteNoticeRef"
|
||||||
:fieldInfoLis="fieldInfoLis"
|
:fieldInfoLis="fieldInfoLis"
|
||||||
v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processCompleteNoticeTemplate"
|
v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processCompleteNoticeTemplate"
|
||||||
v-model:inputValue="form.properties.configInfo.processCompleteNoticeTemplate"
|
v-model:inputValue="form.properties.configInfo.processCompleteNoticeTemplate"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
@@ -262,7 +262,7 @@
|
|||||||
:rules="[{ required: true, message: '请输入开始节点表单' }]"
|
:rules="[{ required: true, message: '请输入开始节点表单' }]"
|
||||||
>
|
>
|
||||||
<el-input
|
<el-input
|
||||||
v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processStartTaskFormUrl"
|
v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processStartTaskFormUrl"
|
||||||
v-model:value="form.properties.configInfo.processStartTaskFormUrl"
|
v-model:value="form.properties.configInfo.processStartTaskFormUrl"
|
||||||
addon-before="src/views/flw/customform/"
|
addon-before="src/views/flw/customform/"
|
||||||
addon-after=".vue"
|
addon-after=".vue"
|
||||||
@@ -271,7 +271,7 @@
|
|||||||
>
|
>
|
||||||
<template #suffix>
|
<template #suffix>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processStartTaskFormUrl"
|
v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processStartTaskFormUrl"
|
||||||
type="primary"
|
type="primary"
|
||||||
size="small"
|
size="small"
|
||||||
@click="$refs.previewCustomFormRef.onOpen(form.properties.configInfo.processStartTaskFormUrl)"
|
@click="$refs.previewCustomFormRef.onOpen(form.properties.configInfo.processStartTaskFormUrl)"
|
||||||
@@ -287,7 +287,7 @@
|
|||||||
:rules="[{ required: true, message: '请输入移动端开始节点表单' }]"
|
:rules="[{ required: true, message: '请输入移动端开始节点表单' }]"
|
||||||
>
|
>
|
||||||
<el-input
|
<el-input
|
||||||
v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processStartTaskMobileFormUrl"
|
v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processStartTaskMobileFormUrl"
|
||||||
v-model:value="form.properties.configInfo.processStartTaskMobileFormUrl"
|
v-model:value="form.properties.configInfo.processStartTaskMobileFormUrl"
|
||||||
addon-before="pages/flw/customform/"
|
addon-before="pages/flw/customform/"
|
||||||
addon-after=".vue"
|
addon-after=".vue"
|
||||||
@@ -301,7 +301,7 @@
|
|||||||
:rules="[{ required: true, message: '请输入人员节点表单' }]"
|
:rules="[{ required: true, message: '请输入人员节点表单' }]"
|
||||||
>
|
>
|
||||||
<el-input
|
<el-input
|
||||||
v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processUserTaskFormUrl"
|
v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processUserTaskFormUrl"
|
||||||
v-model:value="form.properties.configInfo.processUserTaskFormUrl"
|
v-model:value="form.properties.configInfo.processUserTaskFormUrl"
|
||||||
addon-before="src/views/flw/customform/"
|
addon-before="src/views/flw/customform/"
|
||||||
addon-after=".vue"
|
addon-after=".vue"
|
||||||
@@ -310,7 +310,7 @@
|
|||||||
>
|
>
|
||||||
<template #suffix>
|
<template #suffix>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="form.properties.configInfo.processUserTaskFormUrl"
|
v-if="form&&form.properties.configInfo.processUserTaskFormUrl"
|
||||||
type="primary"
|
type="primary"
|
||||||
size="small"
|
size="small"
|
||||||
@click="$refs.previewCustomFormRef.onOpen(form.properties.configInfo.processUserTaskFormUrl)"
|
@click="$refs.previewCustomFormRef.onOpen(form.properties.configInfo.processUserTaskFormUrl)"
|
||||||
@@ -326,7 +326,7 @@
|
|||||||
:rules="[{ required: true, message: '请输入移动端人员节点表单' }]"
|
:rules="[{ required: true, message: '请输入移动端人员节点表单' }]"
|
||||||
>
|
>
|
||||||
<el-input
|
<el-input
|
||||||
v-if="form.properties&&form.properties.configInfo&&form.properties.configInfo.processUserTaskMobileFormUrl"
|
v-if="form&&form.properties&&form.properties.configInfo&&form.properties.configInfo.processUserTaskMobileFormUrl"
|
||||||
v-model:value="form.properties.configInfo.processUserTaskMobileFormUrl"
|
v-model:value="form.properties.configInfo.processUserTaskMobileFormUrl"
|
||||||
addon-before="pages/flw/customform/"
|
addon-before="pages/flw/customform/"
|
||||||
addon-after=".vue"
|
addon-after=".vue"
|
||||||
@@ -338,7 +338,7 @@
|
|||||||
<el-tab-pane key="5" tab="执行监听" force-render>
|
<el-tab-pane key="5" tab="执行监听" force-render>
|
||||||
<prop-listener-info
|
<prop-listener-info
|
||||||
ref="propListenerInfoRef"
|
ref="propListenerInfoRef"
|
||||||
:listenerValue="form.properties?.executionListenerInfo"
|
:listenerValue="form&&form.properties?.executionListenerInfo"
|
||||||
:defaultListenerList="executionListenerInfo"
|
:defaultListenerList="executionListenerInfo"
|
||||||
:listener-value-array="executionListenerArray"
|
:listener-value-array="executionListenerArray"
|
||||||
listener-type="global"
|
listener-type="global"
|
||||||
@@ -386,7 +386,7 @@
|
|||||||
@onBack="callBack"
|
@onBack="callBack"
|
||||||
/>
|
/>
|
||||||
<preview-custom-form ref="previewCustomFormRef" />
|
<preview-custom-form ref="previewCustomFormRef" />
|
||||||
</xn-form-container>
|
</formContainer>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
@@ -400,7 +400,8 @@
|
|||||||
import propTag from './nodes/prop/propTag.vue'
|
import propTag from './nodes/prop/propTag.vue'
|
||||||
import PropListenerInfo from '@/components/XnWorkflow/nodes/prop/propListenerInfo.vue'
|
import PropListenerInfo from '@/components/XnWorkflow/nodes/prop/propListenerInfo.vue'
|
||||||
import PreviewCustomForm from '@/components/XnWorkflow/nodes/common/previewCustomForm.vue'
|
import PreviewCustomForm from '@/components/XnWorkflow/nodes/common/previewCustomForm.vue'
|
||||||
|
import { Plus } from '@element-plus/icons-vue'
|
||||||
|
import formContainer from '@/components/formContainer/index.vue'
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
PropListenerInfo,
|
PropListenerInfo,
|
||||||
@@ -410,7 +411,9 @@
|
|||||||
posSelectorPlus,
|
posSelectorPlus,
|
||||||
orgSelectorPlus,
|
orgSelectorPlus,
|
||||||
propTag,
|
propTag,
|
||||||
PreviewCustomForm
|
PreviewCustomForm,
|
||||||
|
formContainer,
|
||||||
|
Plus
|
||||||
},
|
},
|
||||||
props: {
|
props: {
|
||||||
modelValue: { type: Object, default: () => {} },
|
modelValue: { type: Object, default: () => {} },
|
||||||
@@ -453,7 +456,7 @@
|
|||||||
computed: {
|
computed: {
|
||||||
// 监听内部数组,选了人员相关,我们就不提示
|
// 监听内部数组,选了人员相关,我们就不提示
|
||||||
alertShow() {
|
alertShow() {
|
||||||
if(this.form.properties&&this.form.properties.participateInfo){
|
if(this.form&&this.form.properties&&this.form.properties.participateInfo){
|
||||||
return this.form.properties.participateInfo.length <= 0
|
return this.form.properties.participateInfo.length <= 0
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -493,15 +496,16 @@
|
|||||||
methods: {
|
methods: {
|
||||||
showDrawer() {
|
showDrawer() {
|
||||||
this.form = {}
|
this.form = {}
|
||||||
|
console.log(this.childNode,"hahhahahahah28992392399293");
|
||||||
this.form = cloneDeep(this.childNode)
|
this.form = cloneDeep(this.childNode)
|
||||||
this.formData = this.form.properties.configInfo
|
this.formData = this.form&&this.form.properties&&this.form.properties.configInfo?this.form.properties.configInfo:{}
|
||||||
this.drawer = true
|
this.drawer = true
|
||||||
// 制作默认的摘要字段
|
// 制作默认的摘要字段
|
||||||
this.makeAbstractTemp()
|
this.makeAbstractTemp()
|
||||||
},
|
},
|
||||||
// 制作默认显示的摘要信息
|
// 制作默认显示的摘要信息
|
||||||
makeAbstractTemp() {
|
makeAbstractTemp() {
|
||||||
let temp = this.form.properties.configInfo.processAbstractTemplate
|
let temp = this.form&&this.form.properties&&this.form.properties.configInfo.processAbstractTemplate?this.form.properties.configInfo.processAbstractTemplate:''
|
||||||
if (temp === '') {
|
if (temp === '') {
|
||||||
if (this.fieldInfoLis.length > 0) {
|
if (this.fieldInfoLis.length > 0) {
|
||||||
let fieldInfoTemp = ''
|
let fieldInfoTemp = ''
|
||||||
@@ -544,8 +548,10 @@
|
|||||||
},
|
},
|
||||||
// 选择参与人
|
// 选择参与人
|
||||||
selectionParticipants(type) {
|
selectionParticipants(type) {
|
||||||
let participateInfo = this.form.properties.participateInfo
|
console.log(type,"type=====----2--1-2-2-12-");
|
||||||
|
let participateInfo = this.form&&this.form.properties&&this.form.properties.participateInfo?this.form.properties.participateInfo:[]
|
||||||
let data = []
|
let data = []
|
||||||
|
console.log(this.form,"999992929232");
|
||||||
if (participateInfo.length > 0) {
|
if (participateInfo.length > 0) {
|
||||||
participateInfo.forEach((item) => {
|
participateInfo.forEach((item) => {
|
||||||
if (item.key === type) {
|
if (item.key === type) {
|
||||||
@@ -590,7 +596,7 @@
|
|||||||
},
|
},
|
||||||
// 获取tag标签的内容
|
// 获取tag标签的内容
|
||||||
getTagList(type) {
|
getTagList(type) {
|
||||||
const participateInfo = this.form.properties&&this.form.properties.participateInfo?this.form.properties.participateInfo:[]
|
const participateInfo = this.form&&this.form.properties&&this.form.properties.participateInfo?this.form.properties.participateInfo:[]
|
||||||
if (participateInfo.length < 0) {
|
if (participateInfo.length < 0) {
|
||||||
return undefined
|
return undefined
|
||||||
} else {
|
} else {
|
||||||
@@ -635,6 +641,9 @@
|
|||||||
traverse(data)
|
traverse(data)
|
||||||
return result
|
return result
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
mounted(){
|
||||||
|
this.showDrawer()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
54
src/components/formContainer/index.vue
Normal file
54
src/components/formContainer/index.vue
Normal file
@@ -0,0 +1,54 @@
|
|||||||
|
<template>
|
||||||
|
<el-dialog v-if="isModal" v-model="visibles" @cancel="cancel" v-bind="$attrs">
|
||||||
|
<template v-for="slotKey in slotKeys" #[slotKey]>
|
||||||
|
<slot :name="slotKey" />
|
||||||
|
</template>
|
||||||
|
</el-dialog>
|
||||||
|
<el-drawer v-else v-model="visibles" v-bind="$attrs" :footer-style="{ textAlign: 'right' }">
|
||||||
|
<template v-for="slotKey in slotKeys" #[slotKey]>
|
||||||
|
<slot :name="slotKey" />
|
||||||
|
</template>
|
||||||
|
</el-drawer>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import { mapState } from 'pinia'
|
||||||
|
import { globalStore } from '@/store'
|
||||||
|
|
||||||
|
const FormContainerTypeEnum = {
|
||||||
|
DRAWER: 'drawer',
|
||||||
|
MODAL: 'modal'
|
||||||
|
}
|
||||||
|
export default {
|
||||||
|
inheritAttrs: false,
|
||||||
|
props: {
|
||||||
|
visible: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false,
|
||||||
|
required: true
|
||||||
|
}
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
...mapState(globalStore, ['formStyle']),
|
||||||
|
slotKeys() {
|
||||||
|
return Object.keys(this.$slots)
|
||||||
|
},
|
||||||
|
isModal() {
|
||||||
|
return FormContainerTypeEnum.MODAL === this.formStyle
|
||||||
|
}
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
visibles: ''
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
cancel() {
|
||||||
|
this.$emit('close')
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
this.visibles = this.visible
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
827
src/config/iconSelect.js
Normal file
827
src/config/iconSelect.js
Normal file
@@ -0,0 +1,827 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
/**
|
||||||
|
* 图标选择器基础数据
|
||||||
|
* 推荐前往https://icones.js.org下载图标的Vue文件,然后放在src/assets/icons文件夹里面
|
||||||
|
* 这个网址有118个图标集,包括antd、font awesome、bootstrap、eleme等累计140456个图标
|
||||||
|
*/
|
||||||
|
const uiwIconComponentMap = import.meta.glob('../assets/icons/uiw/*.vue') // 异步方式
|
||||||
|
|
||||||
|
const uiwIcons = Object.keys(uiwIconComponentMap).map((key) => {
|
||||||
|
return key.slice(key.lastIndexOf('/') + 1, key.lastIndexOf('.'))
|
||||||
|
})
|
||||||
|
|
||||||
|
export default {
|
||||||
|
icons: [
|
||||||
|
{
|
||||||
|
name: '基础',
|
||||||
|
key: 'default',
|
||||||
|
iconItem: [
|
||||||
|
{
|
||||||
|
name: '线框风格',
|
||||||
|
key: 'default',
|
||||||
|
item: [
|
||||||
|
'step-backward-outlined',
|
||||||
|
'step-forward-outlined',
|
||||||
|
'fast-backward-outlined',
|
||||||
|
'fast-forward-outlined',
|
||||||
|
'shrink-outlined',
|
||||||
|
'arrows-alt-outlined',
|
||||||
|
'down-outlined',
|
||||||
|
'up-outlined',
|
||||||
|
'left-outlined',
|
||||||
|
'right-outlined',
|
||||||
|
'caret-up-outlined',
|
||||||
|
'caret-down-outlined',
|
||||||
|
'caret-left-outlined',
|
||||||
|
'caret-right-outlined',
|
||||||
|
'up-circle-outlined',
|
||||||
|
'down-circle-outlined',
|
||||||
|
'left-circle-outlined',
|
||||||
|
'right-circle-outlined',
|
||||||
|
'double-right-outlined',
|
||||||
|
'double-left-outlined',
|
||||||
|
'vertical-left-outlined',
|
||||||
|
'vertical-right-outlined',
|
||||||
|
'vertical-align-top-outlined',
|
||||||
|
'vertical-align-middle-outlined',
|
||||||
|
'vertical-align-bottom-outlined',
|
||||||
|
'forward-outlined',
|
||||||
|
'backward-outlined',
|
||||||
|
'rollback-outlined',
|
||||||
|
'enter-outlined',
|
||||||
|
'retweet-outlined',
|
||||||
|
'swap-outlined',
|
||||||
|
'swap-left-outlined',
|
||||||
|
'swap-right-outlined',
|
||||||
|
'arrow-up-outlined',
|
||||||
|
'arrow-down-outlined',
|
||||||
|
'arrow-left-outlined',
|
||||||
|
'arrow-right-outlined',
|
||||||
|
'play-circle-outlined',
|
||||||
|
'up-Square-outlined',
|
||||||
|
'down-square-outlined',
|
||||||
|
'left-square-outlined',
|
||||||
|
'right-square-outlined',
|
||||||
|
'login-outlined',
|
||||||
|
'logout-outlined',
|
||||||
|
'menu-fold-outlined',
|
||||||
|
'menu-unfold-outlined',
|
||||||
|
'border-bottom-outlined',
|
||||||
|
'border-horizontal-outlined',
|
||||||
|
'border-inner-outlined',
|
||||||
|
'border-outer-outlined',
|
||||||
|
'border-left-outlined',
|
||||||
|
'border-right-outlined',
|
||||||
|
'border-top-outlined',
|
||||||
|
'border-verticle-outlined',
|
||||||
|
'pic-center-outlined',
|
||||||
|
'pic-left-outlined',
|
||||||
|
'pic-right-outlined',
|
||||||
|
'radius-bottomleft-outlined',
|
||||||
|
'radius-bottomright-outlined',
|
||||||
|
'radius-upleft-outlined',
|
||||||
|
'radius-upright-outlined',
|
||||||
|
'fullscreen-outlined',
|
||||||
|
'fullscreen-exit-outlined',
|
||||||
|
'question-outlined',
|
||||||
|
'question-circle-outlined',
|
||||||
|
'plus-outlined',
|
||||||
|
'plus-circle-outlined',
|
||||||
|
'pause-outlined',
|
||||||
|
'pause-circle-outlined',
|
||||||
|
'minus-outlined',
|
||||||
|
'minus-circle-outlined',
|
||||||
|
'plus-square-outlined',
|
||||||
|
'minus-square-outlined',
|
||||||
|
'info-outlined',
|
||||||
|
'info-circle-outlined',
|
||||||
|
'exclamation-outlined',
|
||||||
|
'exclamation-circle-outlined',
|
||||||
|
'close-outlined',
|
||||||
|
'close-circle-outlined',
|
||||||
|
'close-square-outlined',
|
||||||
|
'check-outlined',
|
||||||
|
'check-circle-outlined',
|
||||||
|
'check-square-outlined',
|
||||||
|
'clock-circle-outlined',
|
||||||
|
'warning-outlined',
|
||||||
|
'issues-close-outlined',
|
||||||
|
'stop-outlined',
|
||||||
|
'edit-outlined',
|
||||||
|
'form-outlined',
|
||||||
|
'copy-outlined',
|
||||||
|
'scissor-outlined',
|
||||||
|
'delete-outlined',
|
||||||
|
'snippets-outlined',
|
||||||
|
'diff-outlined',
|
||||||
|
'highlight-outlined',
|
||||||
|
'align-center-outlined',
|
||||||
|
'align-left-outlined',
|
||||||
|
'align-right-outlined',
|
||||||
|
'bg-colors-outlined',
|
||||||
|
'bold-outlined',
|
||||||
|
'italic-outlined',
|
||||||
|
'underline-outlined',
|
||||||
|
'strikethrough-outlined',
|
||||||
|
'redo-outlined',
|
||||||
|
'undo-outlined',
|
||||||
|
'zoom-in-outlined',
|
||||||
|
'zoom-out-outlined',
|
||||||
|
'font-colors-outlined',
|
||||||
|
'font-size-outlined',
|
||||||
|
'line-height-outlined',
|
||||||
|
'dash-outlined',
|
||||||
|
'small-dash-outlined',
|
||||||
|
'sort-ascending-outlined',
|
||||||
|
'sort-descending-outlined',
|
||||||
|
'drag-outlined',
|
||||||
|
'ordered-list-outlined',
|
||||||
|
'unordered-list-outlined',
|
||||||
|
'radius-setting-outlined',
|
||||||
|
'column-width-outlined',
|
||||||
|
'column-height-outlined',
|
||||||
|
'account-book-outlined',
|
||||||
|
'aim-outlined',
|
||||||
|
'alert-outlined',
|
||||||
|
'apartment-outlined',
|
||||||
|
'api-outlined',
|
||||||
|
'appstore-add-outlined',
|
||||||
|
'appstore-outlined',
|
||||||
|
'audio-outlined',
|
||||||
|
'audio-muted-outlined',
|
||||||
|
'audit-outlined',
|
||||||
|
'bank-outlined',
|
||||||
|
'barcode-outlined',
|
||||||
|
'bars-outlined',
|
||||||
|
'bell-outlined',
|
||||||
|
'block-outlined',
|
||||||
|
'book-outlined',
|
||||||
|
'border-outlined',
|
||||||
|
'borderless-table-outlined',
|
||||||
|
'branches-outlined',
|
||||||
|
'bug-outlined',
|
||||||
|
'build-outlined',
|
||||||
|
'bulb-outlined',
|
||||||
|
'calculator-outlined',
|
||||||
|
'calendar-outlined',
|
||||||
|
'camera-outlined',
|
||||||
|
'car-outlined',
|
||||||
|
'carry-out-outlined',
|
||||||
|
'ci-circle-outlined',
|
||||||
|
'ci-outlined',
|
||||||
|
'clear-outlined',
|
||||||
|
'cloud-download-outlined',
|
||||||
|
'cloud-outlined',
|
||||||
|
'cloud-server-outlined',
|
||||||
|
'cloud-sync-outlined',
|
||||||
|
'cloud-upload-outlined',
|
||||||
|
'cluster-outlined',
|
||||||
|
'code-outlined',
|
||||||
|
'coffee-outlined',
|
||||||
|
'comment-outlined',
|
||||||
|
'compass-outlined',
|
||||||
|
'compress-outlined',
|
||||||
|
'console-sql-outlined',
|
||||||
|
'contacts-outlined',
|
||||||
|
'container-outlined',
|
||||||
|
'control-outlined',
|
||||||
|
'copyright-circle-outlined',
|
||||||
|
'copyright-outlined',
|
||||||
|
'credit-card-outlined',
|
||||||
|
'crown-outlined',
|
||||||
|
'customer-service-outlined',
|
||||||
|
'dashboard-outlined',
|
||||||
|
'database-outlined',
|
||||||
|
'delete-column-outlined',
|
||||||
|
'delete-row-outlined',
|
||||||
|
'delivered-procedure-outlined',
|
||||||
|
'deployment-unit-outlined',
|
||||||
|
'desktop-outlined',
|
||||||
|
'dingtalk-outlined',
|
||||||
|
'disconnect-outlined',
|
||||||
|
'dislike-outlined',
|
||||||
|
'dollar-circle-outlined',
|
||||||
|
'dollar-outlined',
|
||||||
|
'download-outlined',
|
||||||
|
'ellipsis-outlined',
|
||||||
|
'environment-outlined',
|
||||||
|
'euro-circle-outlined',
|
||||||
|
'euro-outlined',
|
||||||
|
'exception-outlined',
|
||||||
|
'expand-alt-outlined',
|
||||||
|
'expand-outlined',
|
||||||
|
'experiment-outlined',
|
||||||
|
'export-outlined',
|
||||||
|
'eye-outlined',
|
||||||
|
'eye-invisible-outlined',
|
||||||
|
'field-binary-outlined',
|
||||||
|
'field-number-outlined',
|
||||||
|
'field-string-outlined',
|
||||||
|
'field-time-outlined',
|
||||||
|
'file-add-outlined',
|
||||||
|
'file-done-outlined',
|
||||||
|
'file-excel-outlined',
|
||||||
|
'file-exclamation-outlined',
|
||||||
|
'file-outlined',
|
||||||
|
'file-gif-outlined',
|
||||||
|
'file-image-outlined',
|
||||||
|
'file-jpg-outlined',
|
||||||
|
'file-markdown-outlined',
|
||||||
|
'file-pdf-outlined',
|
||||||
|
'file-ppt-outlined',
|
||||||
|
'file-protect-outlined',
|
||||||
|
'file-search-outlined',
|
||||||
|
'file-sync-outlined',
|
||||||
|
'file-text-outlined',
|
||||||
|
'file-unknown-outlined',
|
||||||
|
'file-word-outlined',
|
||||||
|
'file-zip-outlined',
|
||||||
|
'filter-outlined',
|
||||||
|
'fire-outlined',
|
||||||
|
'flag-outlined',
|
||||||
|
'folder-add-outlined',
|
||||||
|
'folder-outlined',
|
||||||
|
'folder-open-outlined',
|
||||||
|
'folder-view-outlined',
|
||||||
|
'fork-outlined',
|
||||||
|
'format-painter-outlined',
|
||||||
|
'frown-outlined',
|
||||||
|
'function-outlined',
|
||||||
|
'fund-projection-screen-outlined',
|
||||||
|
'fund-view-outlined',
|
||||||
|
'funnel-plot-outlined',
|
||||||
|
'gateway-outlined',
|
||||||
|
'gif-outlined',
|
||||||
|
'gift-outlined',
|
||||||
|
'global-outlined',
|
||||||
|
'gold-outlined',
|
||||||
|
'group-outlined',
|
||||||
|
'hdd-outlined',
|
||||||
|
'heart-outlined',
|
||||||
|
'history-outlined',
|
||||||
|
'holder-outlined',
|
||||||
|
'home-outlined',
|
||||||
|
'hourglass-outlined',
|
||||||
|
'idcard-outlined',
|
||||||
|
'import-outlined',
|
||||||
|
'inbox-outlined',
|
||||||
|
'insert-row-above-outlined',
|
||||||
|
'insert-row-below-outlined',
|
||||||
|
'insert-row-left-outlined',
|
||||||
|
'insert-row-right-outlined',
|
||||||
|
'insurance-outlined',
|
||||||
|
'interaction-outlined',
|
||||||
|
'key-outlined',
|
||||||
|
'laptop-outlined',
|
||||||
|
'layout-outlined',
|
||||||
|
'like-outlined',
|
||||||
|
'line-outlined',
|
||||||
|
'link-outlined',
|
||||||
|
'loading3-quarters-outlined',
|
||||||
|
'loading-outlined',
|
||||||
|
'lock-outlined',
|
||||||
|
'mac-command-outlined',
|
||||||
|
'mail-outlined',
|
||||||
|
'man-outlined',
|
||||||
|
'medicine-box-outlined',
|
||||||
|
'meh-outlined',
|
||||||
|
'menu-outlined',
|
||||||
|
'merge-cells-outlined',
|
||||||
|
'message-outlined',
|
||||||
|
'mobile-outlined',
|
||||||
|
'money-collect-outlined',
|
||||||
|
'monitor-outlined',
|
||||||
|
'more-outlined',
|
||||||
|
'node-collapse-outlined',
|
||||||
|
'node-expand-outlined',
|
||||||
|
'node-index-outlined',
|
||||||
|
'notification-outlined',
|
||||||
|
'number-outlined',
|
||||||
|
'one-to-one-outlined',
|
||||||
|
'paper-clip-outlined',
|
||||||
|
'partition-outlined',
|
||||||
|
'pay-circle-outlined',
|
||||||
|
'percentage-outlined',
|
||||||
|
'phone-outlined',
|
||||||
|
'picture-outlined',
|
||||||
|
'play-square-outlined',
|
||||||
|
'pound-circle-outlined',
|
||||||
|
'pound-outlined',
|
||||||
|
'poweroff-outlined',
|
||||||
|
'printer-outlined',
|
||||||
|
'profile-outlined',
|
||||||
|
'project-outlined',
|
||||||
|
'property-safety-outlined',
|
||||||
|
'pull-request-outlined',
|
||||||
|
'pushpin-outlined',
|
||||||
|
'qrcode-outlined',
|
||||||
|
'read-outlined',
|
||||||
|
'reconciliation-outlined',
|
||||||
|
'red-envelope-outlined',
|
||||||
|
'reload-outlined',
|
||||||
|
'rest-outlined',
|
||||||
|
'robot-outlined',
|
||||||
|
'rocket-outlined',
|
||||||
|
'rotate-left-outlined',
|
||||||
|
'rotate-right-outlined',
|
||||||
|
'safety-certificate-outlined',
|
||||||
|
'safety-outlined',
|
||||||
|
'save-outlined',
|
||||||
|
'scan-outlined',
|
||||||
|
'schedule-outlined',
|
||||||
|
'search-outlined',
|
||||||
|
'security-scan-outlined',
|
||||||
|
'select-outlined',
|
||||||
|
'send-outlined',
|
||||||
|
'setting-outlined',
|
||||||
|
'shake-outlined',
|
||||||
|
'share-alt-outlined',
|
||||||
|
'shop-outlined',
|
||||||
|
'shopping-cart-outlined',
|
||||||
|
'shopping-outlined',
|
||||||
|
'sisternode-outlined',
|
||||||
|
'skin-outlined',
|
||||||
|
'smile-outlined',
|
||||||
|
'solution-outlined',
|
||||||
|
'sound-outlined',
|
||||||
|
'split-cells-outlined',
|
||||||
|
'star-outlined',
|
||||||
|
'subnode-outlined',
|
||||||
|
'switcher-outlined',
|
||||||
|
'sync-outlined',
|
||||||
|
'table-outlined',
|
||||||
|
'tablet-outlined',
|
||||||
|
'tag-outlined',
|
||||||
|
'tags-outlined',
|
||||||
|
'team-outlined',
|
||||||
|
'thunderbolt-outlined',
|
||||||
|
'to-top-outlined',
|
||||||
|
'tool-outlined',
|
||||||
|
'trademark-circle-outlined',
|
||||||
|
'trademark-outlined',
|
||||||
|
'transaction-outlined',
|
||||||
|
'translation-outlined',
|
||||||
|
'trophy-outlined',
|
||||||
|
'ungroup-outlined',
|
||||||
|
'unlock-outlined',
|
||||||
|
'upload-outlined',
|
||||||
|
'usb-outlined',
|
||||||
|
'user-add-outlined',
|
||||||
|
'user-delete-outlined',
|
||||||
|
'user-outlined',
|
||||||
|
'user-switch-outlined',
|
||||||
|
'usergroup-add-outlined',
|
||||||
|
'usergroup-delete-outlined',
|
||||||
|
'verified-outlined',
|
||||||
|
'video-camera-add-outlined',
|
||||||
|
'video-camera-outlined',
|
||||||
|
'wallet-outlined',
|
||||||
|
'whats-app-outlined',
|
||||||
|
'wifi-outlined',
|
||||||
|
'woman-outlined'
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: '实底风格',
|
||||||
|
key: 'filled',
|
||||||
|
item: [
|
||||||
|
'step-backward-filled',
|
||||||
|
'step-forward-filled',
|
||||||
|
'fast-backward-filled',
|
||||||
|
'fast-forward-filled',
|
||||||
|
'caret-up-filled',
|
||||||
|
'caret-down-filled',
|
||||||
|
'caret-left-filled',
|
||||||
|
'caret-right-filled',
|
||||||
|
'up-circle-filled',
|
||||||
|
'down-circle-filled',
|
||||||
|
'left-circle-filled',
|
||||||
|
'right-circle-filled',
|
||||||
|
'forward-filled',
|
||||||
|
'backward-filled',
|
||||||
|
'play-circle-filled',
|
||||||
|
'up-square-filled',
|
||||||
|
'down-square-filled',
|
||||||
|
'left-square-filled',
|
||||||
|
'right-square-filled',
|
||||||
|
'question-circle-filled',
|
||||||
|
'plus-circle-filled',
|
||||||
|
'pause-circle-filled',
|
||||||
|
'minus-circle-filled',
|
||||||
|
'plus-square-filled',
|
||||||
|
'minus-square-filled',
|
||||||
|
'info-circle-filled',
|
||||||
|
'exclamation-circle-filled',
|
||||||
|
'close-circle-filled',
|
||||||
|
'close-square-filled',
|
||||||
|
'check-circle-filled',
|
||||||
|
'check-square-filled',
|
||||||
|
'clock-circle-filled',
|
||||||
|
'warning-filled',
|
||||||
|
'stop-filled',
|
||||||
|
'edit-filled',
|
||||||
|
'copy-filled',
|
||||||
|
'delete-filled',
|
||||||
|
'snippets-filled',
|
||||||
|
'diff-filled',
|
||||||
|
'highlight-filled',
|
||||||
|
'pie-chart-filled',
|
||||||
|
'box-plot-filled',
|
||||||
|
'fund-filled',
|
||||||
|
'sliders-filled',
|
||||||
|
'android-filled',
|
||||||
|
'apple-filled',
|
||||||
|
'windows-filled',
|
||||||
|
'chrome-filled',
|
||||||
|
'github-filled',
|
||||||
|
'aliwangwang-filled',
|
||||||
|
'weibo-square-filled',
|
||||||
|
'weibo-circle-filled',
|
||||||
|
'taobao-circle-filled',
|
||||||
|
'html5-filled',
|
||||||
|
'wechat-filled',
|
||||||
|
'youtube-filled',
|
||||||
|
'alipay-circle-filled',
|
||||||
|
'skype-filled',
|
||||||
|
'gitlab-filled',
|
||||||
|
'linkedin-filled',
|
||||||
|
'facebook-filled',
|
||||||
|
'code-sandbox-circle-filled',
|
||||||
|
'codepen-circle-filled',
|
||||||
|
'slack-square-filled',
|
||||||
|
'behance-square-filled',
|
||||||
|
'dribbble-square-filled',
|
||||||
|
'instagram-filled',
|
||||||
|
'yuque-filled',
|
||||||
|
'yahoo-filled',
|
||||||
|
'account-book-filled',
|
||||||
|
'alert-filled',
|
||||||
|
'alipay-square-filled',
|
||||||
|
'amazon-circle-filled',
|
||||||
|
'amazon-square-filled',
|
||||||
|
'api-filled',
|
||||||
|
'appstore-filled',
|
||||||
|
'audio-filled',
|
||||||
|
'bank-filled',
|
||||||
|
'behance-circle-filled',
|
||||||
|
'bell-filled',
|
||||||
|
'book-filled',
|
||||||
|
'bug-filled',
|
||||||
|
'build-filled',
|
||||||
|
'bulb-filled',
|
||||||
|
'calculator-filled',
|
||||||
|
'calendar-filled',
|
||||||
|
'camera-filled',
|
||||||
|
'car-filled',
|
||||||
|
'carry-out-filled',
|
||||||
|
'ci-circle-filled',
|
||||||
|
'cloud-filled',
|
||||||
|
'code-filled',
|
||||||
|
'code-sandbox-square-filled',
|
||||||
|
'codepen-square-filled',
|
||||||
|
'compass-filled',
|
||||||
|
'contacts-filled',
|
||||||
|
'container-filled',
|
||||||
|
'control-filled',
|
||||||
|
'copyright-circle-filled',
|
||||||
|
'credit-card-filled',
|
||||||
|
'crown-filled',
|
||||||
|
'customer-service-filled',
|
||||||
|
'dashboard-filled',
|
||||||
|
'database-filled',
|
||||||
|
'dingtalk-circle-filled',
|
||||||
|
'dingtalk-square-filled',
|
||||||
|
'dislike-filled',
|
||||||
|
'dollar-circle-filled',
|
||||||
|
'dribbble-circle-filled',
|
||||||
|
'dropbox-circle-filled',
|
||||||
|
'dropbox-square-filled',
|
||||||
|
'environment-filled',
|
||||||
|
'euro-circle-filled',
|
||||||
|
'experiment-filled',
|
||||||
|
'eye-filled',
|
||||||
|
'eye-invisible-filled',
|
||||||
|
'file-add-filled',
|
||||||
|
'file-excel-filled',
|
||||||
|
'file-exclamation-filled',
|
||||||
|
'file-filled',
|
||||||
|
'file-image-filled',
|
||||||
|
'file-markdown-filled',
|
||||||
|
'file-pdf-filled',
|
||||||
|
'file-ppt-filled',
|
||||||
|
'file-text-filled',
|
||||||
|
'file-unknown-filled',
|
||||||
|
'file-word-filled',
|
||||||
|
'file-zip-filled',
|
||||||
|
'filter-filled',
|
||||||
|
'fire-filled',
|
||||||
|
'flag-filled',
|
||||||
|
'folder-add-filled',
|
||||||
|
'folder-filled',
|
||||||
|
'folder-open-filled',
|
||||||
|
'format-painter-filled',
|
||||||
|
'frown-filled',
|
||||||
|
'funnel-plot-filled',
|
||||||
|
'gift-filled',
|
||||||
|
'gold-filled',
|
||||||
|
'golden-filled',
|
||||||
|
'google-circle-filled',
|
||||||
|
'google-plus-circle-filled',
|
||||||
|
'google-plus-square-filled',
|
||||||
|
'google-square-filled',
|
||||||
|
'hdd-filled',
|
||||||
|
'heart-filled',
|
||||||
|
'home-filled',
|
||||||
|
'hourglass-filled',
|
||||||
|
'idcard-filled',
|
||||||
|
'ie-circle-filled',
|
||||||
|
'ie-square-filled',
|
||||||
|
'insurance-filled',
|
||||||
|
'interaction-filled',
|
||||||
|
'layout-filled',
|
||||||
|
'like-filled',
|
||||||
|
'lock-filled',
|
||||||
|
'mac-command-filled',
|
||||||
|
'mail-filled',
|
||||||
|
'medicine-box-filled',
|
||||||
|
'medium-circle-filled',
|
||||||
|
'medium-square-filled',
|
||||||
|
'meh-filled',
|
||||||
|
'message-filled',
|
||||||
|
'mobile-filled',
|
||||||
|
'money-collect-filled',
|
||||||
|
'notification-filled',
|
||||||
|
'pay-circle-filled',
|
||||||
|
'phone-filled',
|
||||||
|
'picture-filled',
|
||||||
|
'play-square-filled',
|
||||||
|
'pound-circle-filled',
|
||||||
|
'printer-filled',
|
||||||
|
'profile-filled',
|
||||||
|
'project-filled',
|
||||||
|
'property-safety-filled',
|
||||||
|
'pushpin-filled',
|
||||||
|
'qq-circle-filled',
|
||||||
|
'qq-square-filled',
|
||||||
|
'read-filled',
|
||||||
|
'reconciliation-filled',
|
||||||
|
'red-envelope-filled',
|
||||||
|
'reddit-circle-filled',
|
||||||
|
'reddit-square-filled',
|
||||||
|
'rest-filled',
|
||||||
|
'robot-filled',
|
||||||
|
'rocket-filled',
|
||||||
|
'safety-certificate-filled',
|
||||||
|
'save-filled',
|
||||||
|
'schedule-filled',
|
||||||
|
'security-scan-filled',
|
||||||
|
'setting-filled',
|
||||||
|
'shop-filled',
|
||||||
|
'shopping-filled',
|
||||||
|
'signal-filled',
|
||||||
|
'sketch-circle-filled',
|
||||||
|
'sketch-square-filled',
|
||||||
|
'skin-filled',
|
||||||
|
'slack-circle-filled',
|
||||||
|
'smile-filled',
|
||||||
|
'sound-filled',
|
||||||
|
'star-filled',
|
||||||
|
'switcher-filled',
|
||||||
|
'tablet-filled',
|
||||||
|
'tag-filled',
|
||||||
|
'tags-filled',
|
||||||
|
'taobao-square-filled',
|
||||||
|
'thunderbolt-filled',
|
||||||
|
'tool-filled',
|
||||||
|
'trademark-circle-filled',
|
||||||
|
'trophy-filled',
|
||||||
|
'twitter-circle-filled',
|
||||||
|
'twitter-square-filled',
|
||||||
|
'unlock-filled',
|
||||||
|
'usb-filled',
|
||||||
|
'video-camera-filled',
|
||||||
|
'wallet-filled',
|
||||||
|
'zhihu-circle-filled',
|
||||||
|
'zhihu-square-filled'
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: '双色风格',
|
||||||
|
key: 'twotone',
|
||||||
|
item: [
|
||||||
|
'up-circle-two-tone',
|
||||||
|
'down-circle-two-tone',
|
||||||
|
'left-circle-two-tone',
|
||||||
|
'right-circle-two-tone',
|
||||||
|
'play-circle-two-tone',
|
||||||
|
'up-square-two-tone',
|
||||||
|
'down-square-two-tone',
|
||||||
|
'left-square-two-tone',
|
||||||
|
'right-square-two-tone',
|
||||||
|
'question-circle-two-tone',
|
||||||
|
'plus-circle-two-tone',
|
||||||
|
'pause-circle-two-tone',
|
||||||
|
'minus-circle-two-tone',
|
||||||
|
'plus-square-two-tone',
|
||||||
|
'minus-square-two-tone',
|
||||||
|
'info-circle-two-tone',
|
||||||
|
'exclamation-circle-two-tone',
|
||||||
|
'close-circle-two-tone',
|
||||||
|
'close-square-two-tone',
|
||||||
|
'check-circle-two-tone',
|
||||||
|
'check-square-two-tone',
|
||||||
|
'clock-circle-two-tone',
|
||||||
|
'warning-two-tone',
|
||||||
|
'stop-two-tone',
|
||||||
|
'edit-two-tone',
|
||||||
|
'copy-two-tone',
|
||||||
|
'delete-two-tone',
|
||||||
|
'snippets-two-tone',
|
||||||
|
'diff-two-tone',
|
||||||
|
'highlight-two-tone',
|
||||||
|
'pie-chart-two-tone',
|
||||||
|
'box-plot-two-tone',
|
||||||
|
'fund-two-tone',
|
||||||
|
'sliders-two-tone',
|
||||||
|
'account-book-two-tone',
|
||||||
|
'alert-two-tone',
|
||||||
|
'api-two-tone',
|
||||||
|
'appstore-two-tone',
|
||||||
|
'audio-two-tone',
|
||||||
|
'bank-two-tone',
|
||||||
|
'bell-two-tone',
|
||||||
|
'book-two-tone',
|
||||||
|
'bug-two-tone',
|
||||||
|
'build-two-tone',
|
||||||
|
'bulb-two-tone',
|
||||||
|
'calculator-two-tone',
|
||||||
|
'calendar-two-tone',
|
||||||
|
'camera-two-tone',
|
||||||
|
'car-two-tone',
|
||||||
|
'carry-out-two-tone',
|
||||||
|
'ci-circle-two-tone',
|
||||||
|
'ci-two-tone',
|
||||||
|
'cloud-two-tone',
|
||||||
|
'code-two-tone',
|
||||||
|
'compass-two-tone',
|
||||||
|
'contacts-two-tone',
|
||||||
|
'container-two-tone',
|
||||||
|
'control-two-tone',
|
||||||
|
'copyright-circle-two-tone',
|
||||||
|
'copyright-two-tone',
|
||||||
|
'credit-card-two-tone',
|
||||||
|
'crown-two-tone',
|
||||||
|
'customer-service-two-tone',
|
||||||
|
'dashboard-two-tone',
|
||||||
|
'database-two-tone',
|
||||||
|
'dislike-two-tone',
|
||||||
|
'dollar-circle-two-tone',
|
||||||
|
'dollar-two-tone',
|
||||||
|
'environment-two-tone',
|
||||||
|
'euro-circle-two-tone',
|
||||||
|
'account-book-two-tone',
|
||||||
|
'alert-two-tone',
|
||||||
|
'api-two-tone',
|
||||||
|
'appstore-two-tone',
|
||||||
|
'audio-two-tone',
|
||||||
|
'bank-two-tone',
|
||||||
|
'bell-two-tone',
|
||||||
|
'book-two-tone',
|
||||||
|
'bug-two-tone',
|
||||||
|
'build-two-tone',
|
||||||
|
'bulb-two-tone',
|
||||||
|
'calculator-two-tone',
|
||||||
|
'calendar-two-tone',
|
||||||
|
'camera-two-tone',
|
||||||
|
'car-two-tone',
|
||||||
|
'carry-out-two-tone',
|
||||||
|
'ci-circle-two-tone',
|
||||||
|
'ci-two-tone',
|
||||||
|
'cloud-two-tone',
|
||||||
|
'code-two-tone',
|
||||||
|
'compass-two-tone',
|
||||||
|
'contacts-two-tone',
|
||||||
|
'container-two-tone',
|
||||||
|
'control-two-tone',
|
||||||
|
'copyright-circle-two-tone',
|
||||||
|
'copyright-two-tone',
|
||||||
|
'credit-card-two-tone',
|
||||||
|
'crown-two-tone',
|
||||||
|
'customer-service-two-tone',
|
||||||
|
'dashboard-two-tone',
|
||||||
|
'database-two-tone',
|
||||||
|
'dislike-two-tone',
|
||||||
|
'dollar-circle-two-tone',
|
||||||
|
'dollar-two-tone',
|
||||||
|
'environment-two-tone',
|
||||||
|
'euro-circle-two-tone',
|
||||||
|
'euro-two-tone',
|
||||||
|
'experiment-two-tone',
|
||||||
|
'eye-two-tone',
|
||||||
|
'eye-invisible-two-tone',
|
||||||
|
'file-add-two-tone',
|
||||||
|
'file-excel-two-tone',
|
||||||
|
'file-exclamation-two-tone',
|
||||||
|
'file-two-tone',
|
||||||
|
'file-image-two-tone',
|
||||||
|
'file-markdown-two-tone',
|
||||||
|
'file-pdf-two-tone',
|
||||||
|
'file-ppt-two-tone',
|
||||||
|
'file-text-two-tone',
|
||||||
|
'file-unknown-two-tone',
|
||||||
|
'file-word-two-tone',
|
||||||
|
'file-zip-two-tone',
|
||||||
|
'filter-two-tone',
|
||||||
|
'fire-two-tone',
|
||||||
|
'flag-two-tone',
|
||||||
|
'folder-add-two-tone',
|
||||||
|
'folder-two-tone',
|
||||||
|
'folder-open-two-tone',
|
||||||
|
'frown-two-tone',
|
||||||
|
'funnel-plot-two-tone',
|
||||||
|
'gift-two-tone',
|
||||||
|
'gold-two-tone',
|
||||||
|
'hdd-two-tone',
|
||||||
|
'heart-two-tone',
|
||||||
|
'home-two-tone',
|
||||||
|
'hourglass-two-tone',
|
||||||
|
'idcard-two-tone',
|
||||||
|
'insurance-two-tone',
|
||||||
|
'interaction-two-tone',
|
||||||
|
'layout-two-tone',
|
||||||
|
'like-two-tone',
|
||||||
|
'lock-two-tone',
|
||||||
|
'mail-two-tone',
|
||||||
|
'medicine-box-two-tone',
|
||||||
|
'meh-two-tone',
|
||||||
|
'message-two-tone',
|
||||||
|
'mobile-two-tone',
|
||||||
|
'money-collect-two-tone',
|
||||||
|
'notification-two-tone',
|
||||||
|
'phone-two-tone',
|
||||||
|
'picture-two-tone',
|
||||||
|
'play-square-two-tone',
|
||||||
|
'pound-circle-two-tone',
|
||||||
|
'printer-two-tone',
|
||||||
|
'profile-two-tone',
|
||||||
|
'project-two-tone',
|
||||||
|
'property-safety-two-tone',
|
||||||
|
'pushpin-two-tone',
|
||||||
|
'reconciliation-two-tone',
|
||||||
|
'red-envelope-two-tone',
|
||||||
|
'rest-two-tone',
|
||||||
|
'rocket-two-tone',
|
||||||
|
'safety-certificate-two-tone',
|
||||||
|
'save-two-tone',
|
||||||
|
'schedule-two-tone',
|
||||||
|
'security-scan-two-tone',
|
||||||
|
'setting-two-tone',
|
||||||
|
'shop-two-tone',
|
||||||
|
'shopping-two-tone',
|
||||||
|
'skin-two-tone',
|
||||||
|
'smile-two-tone',
|
||||||
|
'sound-two-tone',
|
||||||
|
'star-two-tone',
|
||||||
|
'switcher-two-tone',
|
||||||
|
'tablet-two-tone',
|
||||||
|
'tag-two-tone',
|
||||||
|
'tags-two-tone',
|
||||||
|
'thunderbolt-two-tone',
|
||||||
|
'tool-two-tone',
|
||||||
|
'trademark-circle-two-tone',
|
||||||
|
'trophy-two-tone',
|
||||||
|
'unlock-two-tone',
|
||||||
|
'usb-two-tone',
|
||||||
|
'video-camera-two-tone',
|
||||||
|
'wallet-two-tone'
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: '扩展',
|
||||||
|
key: 'extend',
|
||||||
|
iconItem: [
|
||||||
|
{
|
||||||
|
name: '常用',
|
||||||
|
key: 'default',
|
||||||
|
item: uiwIcons
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: '其他',
|
||||||
|
key: 'other',
|
||||||
|
item: ['GiteeIcon']
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
101
src/config/index.js
Normal file
101
src/config/index.js
Normal file
@@ -0,0 +1,101 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
const DEFAULT_CONFIG = {
|
||||||
|
// 首页地址
|
||||||
|
DASHBOARD_URL: '/index',
|
||||||
|
|
||||||
|
// 接口地址
|
||||||
|
API_URL: import.meta.env.VITE_API_BASEURL,
|
||||||
|
|
||||||
|
// 请求超时
|
||||||
|
TIMEOUT: 60000,
|
||||||
|
|
||||||
|
// TokenName // Authorization
|
||||||
|
TOKEN_NAME: 'token',
|
||||||
|
|
||||||
|
// Token前缀,注意最后有个空格,如不需要需设置空字符串 // Bearer
|
||||||
|
TOKEN_PREFIX: '',
|
||||||
|
|
||||||
|
// 追加其他头
|
||||||
|
HEADERS: {},
|
||||||
|
|
||||||
|
// 请求是否开启缓存
|
||||||
|
REQUEST_CACHE: false,
|
||||||
|
|
||||||
|
// 布局 经典:classical,双排菜单:doublerow
|
||||||
|
SNOWY_LAYOUT: 'doublerow',
|
||||||
|
|
||||||
|
// 菜单是否折叠
|
||||||
|
SNOWY_MENU_COLLAPSE: false,
|
||||||
|
|
||||||
|
// 模块坞
|
||||||
|
SNOWY_MODULE_UNFOLD_OPEN: true,
|
||||||
|
|
||||||
|
// 是否开启多标签
|
||||||
|
SNOWY_LAYOUT_TAGS_OPEN: true,
|
||||||
|
|
||||||
|
// 是否开启展示面包屑
|
||||||
|
SNOWY_BREADCRUMD_OPEN: false,
|
||||||
|
|
||||||
|
// 顶栏是否应用主题色
|
||||||
|
SNOWY_TOP_HEADER_THEME_COLOR_OPEN: false,
|
||||||
|
|
||||||
|
// 顶栏主题色通栏
|
||||||
|
SNOWY_TOP_HEADER_THEME_COLOR_SPREAD: false,
|
||||||
|
|
||||||
|
// 侧边菜单是否排他展开
|
||||||
|
SNOWY_SIDE_UNIQUE_OPEN: true,
|
||||||
|
|
||||||
|
// 语言
|
||||||
|
LANG: 'zh-cn',
|
||||||
|
|
||||||
|
// 主题颜色
|
||||||
|
COLOR: '#1890FF',
|
||||||
|
|
||||||
|
// 默认整体主题
|
||||||
|
SNOWY_THEME: 'dark',
|
||||||
|
|
||||||
|
// 整体表单风格
|
||||||
|
SNOWY_FORM_STYLE: 'drawer',
|
||||||
|
|
||||||
|
// 成功色
|
||||||
|
success: '#52c41a',
|
||||||
|
|
||||||
|
// 警告色
|
||||||
|
warning: '#faad14',
|
||||||
|
|
||||||
|
// 错误色
|
||||||
|
error: '#f5222f',
|
||||||
|
|
||||||
|
// 系统基础配置,这些是数据库中保存起来的
|
||||||
|
SYS_BASE_CONFIG: {
|
||||||
|
// 默认logo
|
||||||
|
SNOWY_SYS_LOGO: '/img/logo.png',
|
||||||
|
// 背景图
|
||||||
|
SNOWY_SYS_BACK_IMAGE: '',
|
||||||
|
// 系统名称
|
||||||
|
SNOWY_SYS_NAME: 'Snowy',
|
||||||
|
// 版本
|
||||||
|
SNOWY_SYS_VERSION: '2.0',
|
||||||
|
// 版权
|
||||||
|
SNOWY_SYS_COPYRIGHT: 'Snowy ©2022 Created by xiaonuo.vip',
|
||||||
|
// 版权跳转URL
|
||||||
|
SNOWY_SYS_COPYRIGHT_URL: 'https://www.xiaonuo.vip',
|
||||||
|
// 默认文件存储
|
||||||
|
SNOWY_SYS_DEFAULT_FILE_ENGINE: 'LOCAL',
|
||||||
|
// 是否开启验证码
|
||||||
|
SNOWY_SYS_DEFAULT_CAPTCHA_OPEN: 'false',
|
||||||
|
// 默认重置密码
|
||||||
|
SNOWY_SYS_DEFAULT_PASSWORD: '123456'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default DEFAULT_CONFIG
|
||||||
44
src/config/route.js
Normal file
44
src/config/route.js
Normal file
@@ -0,0 +1,44 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
// 静态路由配置
|
||||||
|
const routes = {
|
||||||
|
// 默认模块,仅限于后端未添加任何单页配置,用此路由
|
||||||
|
module: [
|
||||||
|
{
|
||||||
|
id: '01',
|
||||||
|
name: 'homeModule',
|
||||||
|
path: '/homeModule',
|
||||||
|
component: '',
|
||||||
|
meta: {
|
||||||
|
title: '默认',
|
||||||
|
type: 'module',
|
||||||
|
icon: 'bank-outlined'
|
||||||
|
},
|
||||||
|
children: []
|
||||||
|
}
|
||||||
|
],
|
||||||
|
// 默认谁都有个人中心
|
||||||
|
menu: [
|
||||||
|
{
|
||||||
|
id: '001',
|
||||||
|
name: 'usercenter',
|
||||||
|
path: '/usercenter',
|
||||||
|
component: 'sys/user/userCenter',
|
||||||
|
meta: {
|
||||||
|
title: '个人中心',
|
||||||
|
type: 'menu',
|
||||||
|
hidden: true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
|
export default routes
|
||||||
64
src/config/settingConfig.js
Normal file
64
src/config/settingConfig.js
Normal file
@@ -0,0 +1,64 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
const colorList = [
|
||||||
|
{
|
||||||
|
key: '薄暮',
|
||||||
|
color: '#F5222D'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: '火山',
|
||||||
|
color: '#FA541C'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: '胭脂粉',
|
||||||
|
color: '#EB2F96'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: '日暮',
|
||||||
|
color: '#FAAD14'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: '明青',
|
||||||
|
color: '#13C2C2'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: '极光绿',
|
||||||
|
color: '#52C41A'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: '深绿',
|
||||||
|
color: '#009688'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: '拂晓蓝(默认)',
|
||||||
|
color: '#1890FF'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: '极客蓝',
|
||||||
|
color: '#2F54EB'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: '酱紫',
|
||||||
|
color: '#722ED1'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: '主题黑',
|
||||||
|
color: '#001529'
|
||||||
|
}
|
||||||
|
]
|
||||||
|
|
||||||
|
const updateColorWeak = (colorWeak) => {
|
||||||
|
// document.body.className = colorWeak ? 'colorWeak' : '';
|
||||||
|
const app = document.body.querySelector('#app')
|
||||||
|
colorWeak ? app.classList.add('colorWeak') : app.classList.remove('colorWeak')
|
||||||
|
}
|
||||||
|
|
||||||
|
export { colorList, updateColorWeak }
|
||||||
10
src/config/themeColor.js
Normal file
10
src/config/themeColor.js
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
162
src/store/global.js
Normal file
162
src/store/global.js
Normal file
@@ -0,0 +1,162 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { defineStore } from 'pinia'
|
||||||
|
import { changeColor } from '@/utils/themeUtil'
|
||||||
|
import config from '@/config'
|
||||||
|
import { message } from 'ant-design-vue'
|
||||||
|
import tool from '@/utils/tool'
|
||||||
|
import { ref } from 'vue'
|
||||||
|
const toolDataGet = (key) => {
|
||||||
|
return tool.data.get(key)
|
||||||
|
}
|
||||||
|
|
||||||
|
// 获取缓存中的,如果取不到那就用配置的
|
||||||
|
const getCacheConfig = (value) => {
|
||||||
|
const data = toolDataGet(value)
|
||||||
|
if (data === null) {
|
||||||
|
return config[value]
|
||||||
|
}
|
||||||
|
return data
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* deprecated 请使用 useGlobalStore
|
||||||
|
*/
|
||||||
|
export const globalStore = defineStore('global', () => {
|
||||||
|
// 利用Vue3组合式API,ref()定义state的属性
|
||||||
|
// function() 定义actions
|
||||||
|
// computed 定义getters
|
||||||
|
|
||||||
|
// 定义state
|
||||||
|
// 移动端布局
|
||||||
|
const isMobile = ref(false)
|
||||||
|
// 布局
|
||||||
|
const layout = ref(getCacheConfig('SNOWY_LAYOUT'))
|
||||||
|
|
||||||
|
// 菜单是否折叠 toggle
|
||||||
|
const menuIsCollapse = ref(getCacheConfig('SNOWY_MENU_COLLAPSE'))
|
||||||
|
// 侧边菜单是否排他展开
|
||||||
|
const sideUniqueOpen = ref(getCacheConfig('SNOWY_SIDE_UNIQUE_OPEN'))
|
||||||
|
// 多标签栏
|
||||||
|
const layoutTagsOpen = ref(getCacheConfig('SNOWY_LAYOUT_TAGS_OPEN'))
|
||||||
|
// 是否展示面包屑
|
||||||
|
const breadcrumbOpen = ref(getCacheConfig('SNOWY_BREADCRUMD_OPEN'))
|
||||||
|
// 顶栏是否应用主题色
|
||||||
|
const topHeaderThemeColorOpen = ref(getCacheConfig('SNOWY_TOP_HEADER_THEME_COLOR_OPEN'))
|
||||||
|
// 顶栏主题色通栏
|
||||||
|
const topHeaderThemeColorSpread = ref(getCacheConfig('SNOWY_TOP_HEADER_THEME_COLOR_SPREAD'))
|
||||||
|
// 模块坞
|
||||||
|
const moduleUnfoldOpen = ref(getCacheConfig('SNOWY_MODULE_UNFOLD_OPEN'))
|
||||||
|
|
||||||
|
// 主题
|
||||||
|
const theme = ref(getCacheConfig('SNOWY_THEME'))
|
||||||
|
// 主题颜色
|
||||||
|
const themeColor = ref(toolDataGet('SNOWY_THEME_COLOR') || config.COLOR)
|
||||||
|
// 整体表单风格
|
||||||
|
const formStyle = ref(getCacheConfig('SNOWY_FORM_STYLE'))
|
||||||
|
// 用户信息
|
||||||
|
const userInfo = ref(toolDataGet('USER_INFO') || {})
|
||||||
|
// 系统配置
|
||||||
|
const sysBaseConfig = ref(toolDataGet('SNOWY_SYS_BASE_CONFIG') || config.SYS_BASE_CONFIG)
|
||||||
|
// 默认应用
|
||||||
|
const module = ref(getCacheConfig('SNOWY_MENU_MODULE_ID'))
|
||||||
|
|
||||||
|
// 定义action
|
||||||
|
const setIsMobile = (key) => {
|
||||||
|
isMobile.value = key
|
||||||
|
}
|
||||||
|
const setLayout = (key) => {
|
||||||
|
layout.value = key
|
||||||
|
}
|
||||||
|
const setTheme = (key) => {
|
||||||
|
theme.value = key
|
||||||
|
const closeMessage = message.loading(`加载中...`)
|
||||||
|
changeColor(themeColor.value, key).then(closeMessage)
|
||||||
|
}
|
||||||
|
const setThemeColor = (key) => {
|
||||||
|
themeColor.value = key
|
||||||
|
const closeMessage = message.loading(`加载中...`)
|
||||||
|
changeColor(key, theme.value).then(closeMessage)
|
||||||
|
}
|
||||||
|
const initTheme = () => {
|
||||||
|
const closeMessage = message.loading(`加载中...`)
|
||||||
|
changeColor(themeColor.value, theme.value).then(closeMessage)
|
||||||
|
}
|
||||||
|
const toggleConfig = (key) => {
|
||||||
|
switch (key) {
|
||||||
|
case 'menuIsCollapse':
|
||||||
|
menuIsCollapse.value = !menuIsCollapse.value
|
||||||
|
break
|
||||||
|
case 'topHeaderThemeColorSpread':
|
||||||
|
topHeaderThemeColorSpread.value = !topHeaderThemeColorSpread.value
|
||||||
|
break
|
||||||
|
case 'sideUniqueOpen':
|
||||||
|
sideUniqueOpen.value = !sideUniqueOpen.value
|
||||||
|
break
|
||||||
|
case 'layoutTagsOpen':
|
||||||
|
layoutTagsOpen.value = !layoutTagsOpen.value
|
||||||
|
break
|
||||||
|
case 'breadcrumbOpen':
|
||||||
|
breadcrumbOpen.value = !breadcrumbOpen.value
|
||||||
|
break
|
||||||
|
case 'topHeaderThemeColorOpen':
|
||||||
|
topHeaderThemeColorOpen.value = !topHeaderThemeColorOpen.value
|
||||||
|
topHeaderThemeColorSpread.value = topHeaderThemeColorOpen.value
|
||||||
|
? topHeaderThemeColorSpread.value
|
||||||
|
: topHeaderThemeColorOpen.value
|
||||||
|
break
|
||||||
|
case 'moduleUnfoldOpen':
|
||||||
|
moduleUnfoldOpen.value = !moduleUnfoldOpen.value
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
const setFormStyle = (key) => {
|
||||||
|
formStyle.value = key
|
||||||
|
}
|
||||||
|
const setUserInfo = (key) => {
|
||||||
|
userInfo.value = key
|
||||||
|
}
|
||||||
|
const setSysBaseConfig = (key) => {
|
||||||
|
sysBaseConfig.value = key
|
||||||
|
}
|
||||||
|
const setModule = (key) => {
|
||||||
|
module.value = key
|
||||||
|
}
|
||||||
|
return {
|
||||||
|
isMobile,
|
||||||
|
layout,
|
||||||
|
menuIsCollapse,
|
||||||
|
sideUniqueOpen,
|
||||||
|
layoutTagsOpen,
|
||||||
|
breadcrumbOpen,
|
||||||
|
topHeaderThemeColorOpen,
|
||||||
|
topHeaderThemeColorSpread,
|
||||||
|
moduleUnfoldOpen,
|
||||||
|
theme,
|
||||||
|
themeColor,
|
||||||
|
formStyle,
|
||||||
|
userInfo,
|
||||||
|
sysBaseConfig,
|
||||||
|
module,
|
||||||
|
setIsMobile,
|
||||||
|
setLayout,
|
||||||
|
setTheme,
|
||||||
|
setThemeColor,
|
||||||
|
initTheme,
|
||||||
|
toggleConfig,
|
||||||
|
setFormStyle,
|
||||||
|
setUserInfo,
|
||||||
|
setSysBaseConfig,
|
||||||
|
setModule
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
export const useGlobalStore = globalStore
|
||||||
58
src/store/iframe.js
Normal file
58
src/store/iframe.js
Normal file
@@ -0,0 +1,58 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { defineStore } from 'pinia'
|
||||||
|
|
||||||
|
export const iframeStore = defineStore('iframe', () => {
|
||||||
|
// 定义state
|
||||||
|
const iframeList = ref([])
|
||||||
|
const setIframeList = (route) => {
|
||||||
|
iframeList.value = []
|
||||||
|
iframeList.value.push(route)
|
||||||
|
}
|
||||||
|
|
||||||
|
// 定义action
|
||||||
|
const pushIframeList = (route) => {
|
||||||
|
const target = iframeList.value.find((item) => item.path === route.path)
|
||||||
|
if (!target) {
|
||||||
|
iframeList.value.push(route)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
const removeIframeList = (route) => {
|
||||||
|
iframeList.value.forEach((item, index) => {
|
||||||
|
if (item.path === route.path) {
|
||||||
|
iframeList.value.splice(index, 1)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
const refreshIframe = (route) => {
|
||||||
|
iframeList.value.forEach((item) => {
|
||||||
|
if (item.path === route.path) {
|
||||||
|
const url = route.meta.url
|
||||||
|
item.meta.url = ''
|
||||||
|
setTimeout(() => {
|
||||||
|
item.meta.url = url
|
||||||
|
}, 200)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
const clearIframeList = () => {
|
||||||
|
iframeList.value = []
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
iframeList,
|
||||||
|
setIframeList,
|
||||||
|
pushIframeList,
|
||||||
|
removeIframeList,
|
||||||
|
refreshIframe,
|
||||||
|
clearIframeList
|
||||||
|
}
|
||||||
|
})
|
||||||
5
src/store/index.js
Normal file
5
src/store/index.js
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
export * from './global'
|
||||||
|
export * from './search'
|
||||||
|
export * from './iframe'
|
||||||
|
export * from './keepAlive'
|
||||||
|
export * from './viewTags'
|
||||||
55
src/store/keepAlive.js
Normal file
55
src/store/keepAlive.js
Normal file
@@ -0,0 +1,55 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { defineStore } from 'pinia'
|
||||||
|
|
||||||
|
export const keepAliveStore = defineStore('keepAlive', () => {
|
||||||
|
// 定义state
|
||||||
|
const keepLiveRoute = ref([])
|
||||||
|
const routeKey = ref(null)
|
||||||
|
const routeShow = ref(true)
|
||||||
|
|
||||||
|
// 定义action
|
||||||
|
const pushKeepLive = (component) => {
|
||||||
|
if (!keepLiveRoute.value.includes(component)) {
|
||||||
|
keepLiveRoute.value.push(component)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
const removeKeepLive = (component) => {
|
||||||
|
const index = keepLiveRoute.value.indexOf(component)
|
||||||
|
if (index !== -1) {
|
||||||
|
keepLiveRoute.value.splice(index, 1)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
const clearKeepLive = () => {
|
||||||
|
keepLiveRoute.value = []
|
||||||
|
}
|
||||||
|
const setRouteKey = (key) => {
|
||||||
|
routeKey.value = key
|
||||||
|
}
|
||||||
|
const setRouteShow = (key) => {
|
||||||
|
routeShow.value = key
|
||||||
|
}
|
||||||
|
const setRouteKeyAction = (key) => {
|
||||||
|
setRouteKey(key)
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
keepLiveRoute,
|
||||||
|
routeKey,
|
||||||
|
routeShow,
|
||||||
|
pushKeepLive,
|
||||||
|
removeKeepLive,
|
||||||
|
clearKeepLive,
|
||||||
|
setRouteKey,
|
||||||
|
setRouteShow,
|
||||||
|
setRouteKeyAction
|
||||||
|
}
|
||||||
|
})
|
||||||
63
src/store/search.js
Normal file
63
src/store/search.js
Normal file
@@ -0,0 +1,63 @@
|
|||||||
|
import '@/utils/objects'
|
||||||
|
import { defineStore } from 'pinia'
|
||||||
|
|
||||||
|
export const searchStore = defineStore('search', () => {
|
||||||
|
// 定义state
|
||||||
|
const pool = ref([])
|
||||||
|
const hotkey = ref({
|
||||||
|
open: 's',
|
||||||
|
close: 'esc'
|
||||||
|
})
|
||||||
|
const active = ref(false)
|
||||||
|
|
||||||
|
// 定义action
|
||||||
|
const toggleActive = () => {
|
||||||
|
active.value = !active.value
|
||||||
|
}
|
||||||
|
const setActive = (val) => {
|
||||||
|
active.value = val
|
||||||
|
}
|
||||||
|
const init = (menu) => {
|
||||||
|
const poolList = []
|
||||||
|
const getFullName = function (meta) {
|
||||||
|
if (meta.breadcrumb) {
|
||||||
|
let list = []
|
||||||
|
meta.breadcrumb.forEach((item) => {
|
||||||
|
list.push(item.meta.title)
|
||||||
|
})
|
||||||
|
return list.join(' / ')
|
||||||
|
}
|
||||||
|
return meta.title
|
||||||
|
}
|
||||||
|
const push = function (menu) {
|
||||||
|
menu.forEach((m) => {
|
||||||
|
if ('menu' === m.meta.type) {
|
||||||
|
if (m.children) {
|
||||||
|
push(m.children)
|
||||||
|
} else if (m.children === null) {
|
||||||
|
poolList.push({
|
||||||
|
icon: m.meta.icon,
|
||||||
|
path: m.path,
|
||||||
|
fullPath: m.path,
|
||||||
|
name: m.meta.title,
|
||||||
|
fullName: getFullName(m.meta),
|
||||||
|
namePinyin: m.meta.title.toPinyin(),
|
||||||
|
namePinyinFirst: m.meta.title.toPinyin(true)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
push(menu)
|
||||||
|
pool.value = poolList
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
pool,
|
||||||
|
hotkey,
|
||||||
|
active,
|
||||||
|
toggleActive,
|
||||||
|
setActive,
|
||||||
|
init
|
||||||
|
}
|
||||||
|
})
|
||||||
40
src/store/sysBaseConfig.js
Normal file
40
src/store/sysBaseConfig.js
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import configApi from '@/api/dev/configApi'
|
||||||
|
import { message } from 'ant-design-vue'
|
||||||
|
|
||||||
|
const formData = ref({
|
||||||
|
SNOWY_SYS_LOGO: '',
|
||||||
|
SNOWY_SYS_BACK_IMAGE: '',
|
||||||
|
SNOWY_SYS_NAME: '',
|
||||||
|
SNOWY_SYS_VERSION: '',
|
||||||
|
SNOWY_SYS_COPYRIGHT: '',
|
||||||
|
SNOWY_SYS_COPYRIGHT_URL: '',
|
||||||
|
SNOWY_SYS_DEFAULT_FILE_ENGINE: 'LOCAL',
|
||||||
|
SNOWY_SYS_DEFAULT_CAPTCHA_OPEN: false,
|
||||||
|
SNOWY_SYS_DEFAULT_PASSWORD: ''
|
||||||
|
})
|
||||||
|
|
||||||
|
const param = {
|
||||||
|
category: 'SYS_BASE'
|
||||||
|
}
|
||||||
|
|
||||||
|
const getSysBaseConfig = () => {
|
||||||
|
configApi.configList(param).then((data) => {
|
||||||
|
if (data) {
|
||||||
|
data.forEach((item) => {
|
||||||
|
formData.value[item.configKey] = item.configValue ? '' : item.configValue
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
message.warning('表单项不存在,请初始化数据库')
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
68
src/store/viewTags.js
Normal file
68
src/store/viewTags.js
Normal file
@@ -0,0 +1,68 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { defineStore } from 'pinia'
|
||||||
|
|
||||||
|
export const viewTagsStore = defineStore('viewTags', () => {
|
||||||
|
// 定义state
|
||||||
|
const viewTags = ref([])
|
||||||
|
|
||||||
|
// 定义action
|
||||||
|
const pushViewTags = (route) => {
|
||||||
|
const target = viewTags.value.find((item) => item.path === route.path)
|
||||||
|
const isName = route.name
|
||||||
|
if (!target && isName) {
|
||||||
|
viewTags.value.push(route)
|
||||||
|
}
|
||||||
|
if (target) {
|
||||||
|
viewTags.value.forEach((item, index) => {
|
||||||
|
if (item.path === route.path) {
|
||||||
|
viewTags.value[index] = { ...route, ...item }
|
||||||
|
// Object.assign(item, route)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
const removeViewTags = (route) => {
|
||||||
|
viewTags.value.forEach((item, index) => {
|
||||||
|
if (item.fullPath === route.fullPath) {
|
||||||
|
viewTags.value.splice(index, 1)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
const updateViewTags = (route) => {
|
||||||
|
viewTags.value.forEach((item, index) => {
|
||||||
|
if (item.fullPath === route.fullPath) {
|
||||||
|
viewTags.value[index] = { ...route, ...item }
|
||||||
|
// Object.assign(item, route)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
const updateViewTagsTitle = (title = '') => {
|
||||||
|
const nowFullPath = location.hash.substring(1)
|
||||||
|
viewTags.value.forEach((item) => {
|
||||||
|
if (item.fullPath === nowFullPath) {
|
||||||
|
item.meta.title = title
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
const clearViewTags = () => {
|
||||||
|
viewTags.value = []
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
viewTags,
|
||||||
|
pushViewTags,
|
||||||
|
removeViewTags,
|
||||||
|
updateViewTags,
|
||||||
|
updateViewTagsTitle,
|
||||||
|
clearViewTags
|
||||||
|
}
|
||||||
|
})
|
||||||
15
src/utils/enum.js
Normal file
15
src/utils/enum.js
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
export const ThemeModeEnum = {
|
||||||
|
LIGHT: 'light',
|
||||||
|
DARK: 'dark',
|
||||||
|
REAL_DARK: 'realDark'
|
||||||
|
}
|
||||||
39
src/utils/objects.js
Normal file
39
src/utils/objects.js
Normal file
@@ -0,0 +1,39 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import pinyin from 'js-pinyin'
|
||||||
|
|
||||||
|
// 中文转拼音 传入仅首字母
|
||||||
|
Object.defineProperty(String.prototype, 'toPinyin', {
|
||||||
|
writable: false,
|
||||||
|
enumerable: false,
|
||||||
|
configurable: true,
|
||||||
|
value: function (first) {
|
||||||
|
let str = this
|
||||||
|
if (first) {
|
||||||
|
return pinyin.getCamelChars(str).replace(/\uD83C[\uDF00-\uDFFF]|\uD83D[\uDC00-\uDE4F]/g, '')
|
||||||
|
}
|
||||||
|
return pinyin.getFullChars(str).replace(/\uD83C[\uDF00-\uDFFF]|\uD83D[\uDC00-\uDE4F]/g, '')
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
// 字符检索 传入检索值
|
||||||
|
Object.defineProperty(String.prototype, 'filter', {
|
||||||
|
writable: false,
|
||||||
|
enumerable: false,
|
||||||
|
configurable: true,
|
||||||
|
value: function (input) {
|
||||||
|
let str = this
|
||||||
|
let en = str.toLowerCase().includes(input.toLowerCase())
|
||||||
|
let zhFull = str.toPinyin().toLowerCase().includes(input.toLowerCase())
|
||||||
|
let zhFirst = str.toPinyin(true).toLowerCase().includes(input.toLowerCase())
|
||||||
|
return en || zhFull || zhFirst
|
||||||
|
}
|
||||||
|
})
|
||||||
@@ -96,7 +96,7 @@ function createAxios<Data = any, T = ApiPromise<Data>>(
|
|||||||
response.data.code === 'A0000' ||
|
response.data.code === 'A0000' ||
|
||||||
response.data.type === 'application/json' ||
|
response.data.type === 'application/json' ||
|
||||||
Array.isArray(response.data) ||
|
Array.isArray(response.data) ||
|
||||||
response.data.size
|
response.data.size
|
||||||
// ||
|
// ||
|
||||||
// response.data.type === 'application/octet-stream' ||
|
// response.data.type === 'application/octet-stream' ||
|
||||||
// response.data.type === 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'
|
// response.data.type === 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'
|
||||||
@@ -228,6 +228,37 @@ export function requestPayload(method: Method, data: anyObj) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// 适配器, 用于适配不同的请求方式
|
||||||
|
export function baseRequest(url, value = {}, method = 'post', options = {}) {
|
||||||
|
url = sysConfig.API_URL + url
|
||||||
|
if (method === 'post') {
|
||||||
|
return service.post(url, value, options)
|
||||||
|
} else if (method === 'get') {
|
||||||
|
return service.get(url, { params: value, ...options })
|
||||||
|
} else if (method === 'formdata') {
|
||||||
|
// form-data表单提交的方式
|
||||||
|
return service.post(url, qs.stringify(value), {
|
||||||
|
headers: {
|
||||||
|
'Content-Type': 'multipart/form-data'
|
||||||
|
},
|
||||||
|
...options
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
// 其他请求方式,例如:put、delete
|
||||||
|
return service({
|
||||||
|
method: method,
|
||||||
|
url: url,
|
||||||
|
data: value,
|
||||||
|
...options
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 模块内的请求, 会自动加上模块的前缀
|
||||||
|
export const moduleRequest =
|
||||||
|
(moduleUrl) =>
|
||||||
|
(url, ...arg) => {
|
||||||
|
return baseRequest(moduleUrl + url, ...arg)
|
||||||
|
}
|
||||||
|
|
||||||
interface LoadingInstance {
|
interface LoadingInstance {
|
||||||
target: any
|
target: any
|
||||||
|
|||||||
81
src/utils/themeUtil.js
Normal file
81
src/utils/themeUtil.js
Normal file
@@ -0,0 +1,81 @@
|
|||||||
|
/**
|
||||||
|
* Copyright [2022] [https://www.xiaonuo.vip]
|
||||||
|
* Snowy采用APACHE LICENSE 2.0开源协议,您在使用过程中,需要注意以下几点:
|
||||||
|
* 1.请不要删除和修改根目录下的LICENSE文件。
|
||||||
|
* 2.请不要删除和修改Snowy源码头部的版权声明。
|
||||||
|
* 3.本项目代码可免费商业使用,商业使用请保留源码和相关描述文件的项目出处,作者声明等。
|
||||||
|
* 4.分发源码时候,请注明软件出处 https://www.xiaonuo.vip
|
||||||
|
* 5.不可二次分发开源参与同类竞品,如有想法可联系团队xiaonuobase@qq.com商议合作。
|
||||||
|
* 6.若您的项目无法满足以上几点,需要更多功能代码,获取Snowy商业授权许可,请在官网购买授权,地址为 https://www.xiaonuo.vip
|
||||||
|
*/
|
||||||
|
import { generate } from '@ant-design/colors'
|
||||||
|
import tool from '../utils/tool'
|
||||||
|
import config from '../config'
|
||||||
|
import { ThemeModeEnum } from './enum'
|
||||||
|
|
||||||
|
const changeColor = (newPrimaryColor, theme, darkClass = 'snowy-theme-dark') => {
|
||||||
|
return new Promise((resolve) => {
|
||||||
|
const themeEleId = 'snowy-theme-var'
|
||||||
|
const themeEle = document.querySelector(`#${themeEleId}`)
|
||||||
|
if (themeEle && themeEle.parentNode) {
|
||||||
|
themeEle.parentNode.removeChild(themeEle)
|
||||||
|
}
|
||||||
|
const isRealDark = theme === ThemeModeEnum.REAL_DARK
|
||||||
|
if (newPrimaryColor) {
|
||||||
|
const colors = generate(newPrimaryColor, isRealDark ? { theme: 'dark' } : {})
|
||||||
|
const rootClass = isRealDark ? `.${darkClass}` : ':root'
|
||||||
|
const styleElement = document.createElement('style')
|
||||||
|
styleElement.id = themeEleId
|
||||||
|
styleElement.setAttribute('type', 'text/css')
|
||||||
|
styleElement.innerHTML = `${rootClass}{${colors
|
||||||
|
.map((c, i) => {
|
||||||
|
return `--primary-${i + 1}:${c};`
|
||||||
|
})
|
||||||
|
.concat([`--primary-color:${newPrimaryColor};`])
|
||||||
|
.join('')}}`
|
||||||
|
document.head.appendChild(styleElement)
|
||||||
|
} else {
|
||||||
|
document.body.removeAttribute('snowy-theme')
|
||||||
|
}
|
||||||
|
if (isRealDark) {
|
||||||
|
document.body.classList.add(darkClass)
|
||||||
|
} else {
|
||||||
|
document.body.classList.remove(darkClass)
|
||||||
|
}
|
||||||
|
resolve()
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
const loadLocalTheme = (localSetting) => {
|
||||||
|
if (localSetting) {
|
||||||
|
let { theme, themeColor } = localSetting
|
||||||
|
themeColor = themeColor || config.COLOR
|
||||||
|
theme = theme || config.THEME
|
||||||
|
changeColor(themeColor, theme)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取本地保存的配置
|
||||||
|
* @param loadTheme {boolean} 是否加载配置中的主题
|
||||||
|
* @returns {Object}
|
||||||
|
*/
|
||||||
|
const getLocalSetting = (loadTheme) => {
|
||||||
|
let localSetting = {}
|
||||||
|
try {
|
||||||
|
const theme = tool.data.get('SNOWY_THEME')
|
||||||
|
const themeColor = tool.data.get('SNOWY_THEME_COLOR')
|
||||||
|
localSetting = {
|
||||||
|
theme,
|
||||||
|
themeColor
|
||||||
|
}
|
||||||
|
} catch (e) {
|
||||||
|
console.error(e)
|
||||||
|
}
|
||||||
|
if (loadTheme) {
|
||||||
|
loadLocalTheme(localSetting)
|
||||||
|
}
|
||||||
|
return localSetting
|
||||||
|
}
|
||||||
|
|
||||||
|
export { loadLocalTheme, getLocalSetting, changeColor }
|
||||||
@@ -1,43 +1,47 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<el-card class='steps-card' :bordered='false'>
|
<el-card class="steps-card" :bordered="false">
|
||||||
<el-row class='xn-row'>
|
<el-row class="xn-row">
|
||||||
<el-col :span='6'></el-col>
|
<!-- <el-col :span="6"></el-col> -->
|
||||||
<el-col :span='12'>
|
<el-col :span="16">
|
||||||
<el-steps :current='current'>
|
<el-steps :current="current">
|
||||||
<el-step v-for='item in steps' :key='item.title' :title='item.title'>
|
<el-step v-for="item in steps" :key="item.title" :title="item.title">
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<el-icon color='#409efc' class='no-inherit' v-if="item.title === '表单设计'">
|
<el-icon color="#409efc" class="no-inherit" v-if="item.title === '表单设计'">
|
||||||
<SetUp />
|
<SetUp />
|
||||||
</el-icon>
|
</el-icon>
|
||||||
|
|
||||||
<el-icon color='#409efc' class='no-inherit' v-if="item.title === '模型设计'">
|
<el-icon color="#409efc" class="no-inherit" v-if="item.title === '模型设计'">
|
||||||
<PieChart />
|
<PieChart />
|
||||||
</el-icon>
|
</el-icon>
|
||||||
|
|
||||||
<el-icon color='#409efc' class='no-inherit' v-if="item.title === '完成'">
|
<el-icon color="#409efc" class="no-inherit" v-if="item.title === '完成'">
|
||||||
<Select />
|
<Select />
|
||||||
</el-icon>
|
</el-icon>
|
||||||
</template>
|
</template>
|
||||||
</el-step>
|
</el-step>
|
||||||
</el-steps>
|
</el-steps>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='6'>
|
<el-col :span="8">
|
||||||
<div style='float: right'>
|
<div style="float: right; padding-top: 10px">
|
||||||
<el-button :disabled='current !== 1' style='margin-left: 8px' @click='prev'>
|
<el-button :disabled="current !== 1" style="margin-left: 8px" @click="prev">
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<Back />
|
<Back />
|
||||||
</template>
|
</template>
|
||||||
后退
|
后退
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button :disabled="recordData.formType === 'DESIGN' ? current === 2 : current === 1"
|
<el-button
|
||||||
type='primary' style='margin-left: 8px' @click='next'>
|
:disabled="recordData.formType === 'DESIGN' ? current === 2 : current === 1"
|
||||||
|
type="primary"
|
||||||
|
style="margin-left: 8px"
|
||||||
|
@click="next"
|
||||||
|
>
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<Right />
|
<Right />
|
||||||
</template>
|
</template>
|
||||||
继续
|
继续
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button type='primary' danger ghost style='margin-left: 8px' @click="emit('previousPage')">
|
<el-button type="primary" danger ghost style="margin-left: 8px" @click="emit('previousPage')">
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<Close />
|
<Close />
|
||||||
</template>
|
</template>
|
||||||
@@ -47,28 +51,32 @@
|
|||||||
</el-row>
|
</el-row>
|
||||||
</el-card>
|
</el-card>
|
||||||
|
|
||||||
<div v-if='current === 0'>
|
<div v-if="current === 0">
|
||||||
<!-- <form-design ref="formDesign" v-if="recordData.formType === 'DESIGN'" :form-value="workFlowParame.formValue" />-->
|
<form-design
|
||||||
|
ref="formDesign"
|
||||||
|
v-if="recordData.formType === 'DESIGN'"
|
||||||
|
:form-value="workFlowParame.formValue"
|
||||||
|
/>
|
||||||
<!-- <model-design ref="modelDesign" v-else />-->
|
<!-- <model-design ref="modelDesign" v-else />-->
|
||||||
<model-design ref='modelDesign' />
|
<model-design ref="modelDesign" />
|
||||||
</div>
|
</div>
|
||||||
<div v-if='current === 1'>
|
<div v-if="current === 1">
|
||||||
<model-design ref='modelDesign' v-if="recordData.formType === 'DESIGN'" />
|
<model-design ref="modelDesign" v-if="recordData.formType === 'DESIGN'" />
|
||||||
<el-card v-else>
|
<el-card v-else>
|
||||||
<el-result status='success' title='操作成功' sub-title='此时您可以一键部署此流程啦'>
|
<el-result status="success" title="操作成功" sub-title="此时您可以一键部署此流程啦">
|
||||||
<template #extra>
|
<template #extra>
|
||||||
<el-space size='middle'>
|
<el-space size="middle">
|
||||||
<el-button v-if='current > 0' style='margin-left: 8px' @click='prev'>
|
<el-button v-if="current > 0" style="margin-left: 8px" @click="prev">
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<Back />
|
<Back />
|
||||||
</template>
|
</template>
|
||||||
后退
|
后退
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if='current == steps.length - 1'
|
v-if="current == steps.length - 1"
|
||||||
type='primary'
|
type="primary"
|
||||||
:loading='submitLoading'
|
:loading="submitLoading"
|
||||||
@click='seveDeployment'
|
@click="seveDeployment"
|
||||||
>
|
>
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<Tools />
|
<Tools />
|
||||||
@@ -80,22 +88,22 @@
|
|||||||
</el-result>
|
</el-result>
|
||||||
</el-card>
|
</el-card>
|
||||||
</div>
|
</div>
|
||||||
<div v-if='current === 2'>
|
<div v-if="current === 2">
|
||||||
<el-card>
|
<el-card>
|
||||||
<el-result status='success' title='操作成功' sub-title='此时您可以一键部署此流程啦'>
|
<el-result status="success" title="操作成功" sub-title="此时您可以一键部署此流程啦">
|
||||||
<template #extra>
|
<template #extra>
|
||||||
<el-space size='middle'>
|
<el-space size="middle">
|
||||||
<el-button v-if='current > 0' style='margin-left: 8px' @click='prev'>
|
<el-button v-if="current > 0" style="margin-left: 8px" @click="prev">
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<Back />
|
<Back />
|
||||||
</template>
|
</template>
|
||||||
后退
|
后退
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if='current == steps.length - 1'
|
v-if="current == steps.length - 1"
|
||||||
type='primary'
|
type="primary"
|
||||||
:loading='submitLoading'
|
:loading="submitLoading"
|
||||||
@click='seveDeployment'
|
@click="seveDeployment"
|
||||||
>
|
>
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<Tools />
|
<Tools />
|
||||||
@@ -114,14 +122,16 @@ import { ElMessage } from 'element-plus'
|
|||||||
import { Plus, SetUp, Select, PieChart, Back, Right, Close, Tools } from '@element-plus/icons-vue'
|
import { Plus, SetUp, Select, PieChart, Back, Right, Close, Tools } from '@element-plus/icons-vue'
|
||||||
import { defineComponent, nextTick, ref } from 'vue'
|
import { defineComponent, nextTick, ref } from 'vue'
|
||||||
import ModelDesign from './modelDesign.vue'
|
import ModelDesign from './modelDesign.vue'
|
||||||
// import FormDesign from './formDesign.vue'
|
import tool from '@/utils/tool'
|
||||||
|
import modelApi from '@/api/flw/modelApi'
|
||||||
|
import FormDesign from './formDesign.vue'
|
||||||
import config from '@/components/XnWorkflow/nodes/config/config'
|
import config from '@/components/XnWorkflow/nodes/config/config'
|
||||||
import { cloneDeep } from 'lodash-es'
|
import { cloneDeep } from 'lodash-es'
|
||||||
|
|
||||||
const emit = defineEmits({ previousPage: null })
|
const emit = defineEmits({ previousPage: null })
|
||||||
|
|
||||||
const current = ref(0)
|
const current = ref(0)
|
||||||
// const formDesign = ref(null)
|
const formDesign = ref(null)
|
||||||
const modelDesign = ref(null)
|
const modelDesign = ref(null)
|
||||||
|
|
||||||
const recordData = ref({})
|
const recordData = ref({})
|
||||||
@@ -144,9 +154,10 @@ const workFlowParame = {
|
|||||||
modelValue: cloneDeep(config.nodeModel.node)
|
modelValue: cloneDeep(config.nodeModel.node)
|
||||||
}
|
}
|
||||||
// 打开这个界面
|
// 打开这个界面
|
||||||
const configSteps = (record) => {
|
const configSteps = record => {
|
||||||
// 全局赋值
|
// 全局赋值
|
||||||
recordData.value = record
|
recordData.value = record
|
||||||
|
console.log(record, '------')
|
||||||
workFlowParame.formValue = record.formJson == null ? false : JSON.parse(record.formJson)
|
workFlowParame.formValue = record.formJson == null ? false : JSON.parse(record.formJson)
|
||||||
if (record.processJson == null) {
|
if (record.processJson == null) {
|
||||||
// 给模型设计器基础外壳给值
|
// 给模型设计器基础外壳给值
|
||||||
@@ -174,26 +185,34 @@ const configSteps = (record) => {
|
|||||||
|
|
||||||
// 装回全局模型中
|
// 装回全局模型中
|
||||||
workFlowParame.modelValue.childNode = startEventNode
|
workFlowParame.modelValue.childNode = startEventNode
|
||||||
|
//这里是流程需要的数据
|
||||||
|
console.log(workFlowParame.modelValue.childNode.childNode, '打印组装数据')
|
||||||
} else {
|
} else {
|
||||||
workFlowParame.modelValue = JSON.parse(record.processJson)
|
workFlowParame.modelValue = JSON.parse(record.processJson)
|
||||||
}
|
}
|
||||||
|
console.log('给流程设计器给值' + 22222)
|
||||||
// 判断表单类型
|
// 判断表单类型
|
||||||
if (record.formType === 'DESIGN') {
|
console.log(record.formType, '打印表单类型')
|
||||||
// 判断如果是设计表单,那么第一步加入表单设计器
|
// if (record.formType === 'DESIGN') {
|
||||||
steps.value.unshift({
|
// // 判断如果是设计表单,那么第一步加入表单设计器
|
||||||
title: '表单设计',
|
// steps.value.unshift({
|
||||||
content: '表单设计'
|
// title: '表单设计',
|
||||||
})
|
// content: '表单设计'
|
||||||
nextTick(() => {
|
// })
|
||||||
// 给表单设计器给值,表单value,table数据结构
|
// console.log('给流程设计器给值'+333333);
|
||||||
// formDesign.value.setValue(workFlowParame.formValue, JSON.parse(recordData.value.tableJson))
|
// nextTick(() => {
|
||||||
})
|
// // 给表单设计器给值,表单value,table数据结构
|
||||||
} else {
|
// formDesign.value.setValue(workFlowParame.formValue, JSON.parse(recordData.value.tableJson))
|
||||||
// 给流程设计器给值
|
// })
|
||||||
nextTick(() => {
|
// } else {
|
||||||
modelDesign.value.setValue(workFlowParame, recordData.value)
|
// 给流程设计器给值
|
||||||
})
|
console.log('给流程设计器给值' + 22222)
|
||||||
}
|
nextTick(() => {
|
||||||
|
// modelDesign.value.setValue(workFlowParame, recordData.value)
|
||||||
|
console.log( recordData.value,"9999999999打印recordData");
|
||||||
|
modelDesign.value.setValue(workFlowParame, recordData.value)
|
||||||
|
})
|
||||||
|
// }
|
||||||
}
|
}
|
||||||
// 下一步
|
// 下一步
|
||||||
const next = () => {
|
const next = () => {
|
||||||
@@ -201,7 +220,7 @@ const next = () => {
|
|||||||
// 判断是哪一步
|
// 判断是哪一步
|
||||||
if (current.value === 1) {
|
if (current.value === 1) {
|
||||||
if (recordData.value.formType === 'DESIGN') {
|
if (recordData.value.formType === 'DESIGN') {
|
||||||
// formDesignNext()
|
formDesignNext()
|
||||||
} else {
|
} else {
|
||||||
modelDesignNext()
|
modelDesignNext()
|
||||||
}
|
}
|
||||||
@@ -210,19 +229,19 @@ const next = () => {
|
|||||||
modelDesignNext()
|
modelDesignNext()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// const formDesignNext = () => {
|
const formDesignNext = () => {
|
||||||
// const formValue = formDesign.value.getValue()
|
const formValue = formDesign.value.getValue()
|
||||||
// if (!formDataVerification(formValue)) {
|
if (!formDataVerification(formValue)) {
|
||||||
// current.value--
|
current.value--
|
||||||
// return
|
return
|
||||||
// }
|
}
|
||||||
// workFlowParame.formValue = formValue
|
workFlowParame.formValue = formValue
|
||||||
// nextTick(() => {
|
nextTick(() => {
|
||||||
// modelDesign.value.setValue(workFlowParame, recordData.value)
|
modelDesign.value.setValue(workFlowParame, recordData.value)
|
||||||
// // 给流程设计器表单的字段
|
// 给流程设计器表单的字段
|
||||||
// modelDesign.value.setFormFieldListValue(workFlowParame.formValue.list)
|
modelDesign.value.setFormFieldListValue(workFlowParame.formValue.list)
|
||||||
// })
|
})
|
||||||
// }
|
}
|
||||||
const modelDesignNext = () => {
|
const modelDesignNext = () => {
|
||||||
workFlowParame.modelValue = modelDesign.value.getValue()
|
workFlowParame.modelValue = modelDesign.value.getValue()
|
||||||
// 这里完成之后,需要调用保存接口,传给后端
|
// 这里完成之后,需要调用保存接口,传给后端
|
||||||
@@ -234,8 +253,7 @@ const modelDesignNext = () => {
|
|||||||
}
|
}
|
||||||
recordData.value.processJson = JSON.stringify(workFlowParame.modelValue)
|
recordData.value.processJson = JSON.stringify(workFlowParame.modelValue)
|
||||||
// 保存进去
|
// 保存进去
|
||||||
modelApi.submitForm(recordData.value, recordData.value.id).then(() => {
|
modelApi.submitForm(recordData.value, recordData.value.id).then(() => {})
|
||||||
})
|
|
||||||
}
|
}
|
||||||
// 上一步
|
// 上一步
|
||||||
const prev = () => {
|
const prev = () => {
|
||||||
@@ -243,7 +261,7 @@ const prev = () => {
|
|||||||
if (current.value === 0) {
|
if (current.value === 0) {
|
||||||
nextTick(() => {
|
nextTick(() => {
|
||||||
if (recordData.value.formType === 'DESIGN') {
|
if (recordData.value.formType === 'DESIGN') {
|
||||||
// formDesign.value.setValue(workFlowParame.formValue, JSON.parse(recordData.value.tableJson))
|
formDesign.value.setValue(workFlowParame.formValue, JSON.parse(recordData.value.tableJson))
|
||||||
} else {
|
} else {
|
||||||
modelDesign.value.setValue(workFlowParame, recordData.value)
|
modelDesign.value.setValue(workFlowParame, recordData.value)
|
||||||
modelDesign.value.setFormFieldListValue(workFlowParame.formValue.list)
|
modelDesign.value.setFormFieldListValue(workFlowParame.formValue.list)
|
||||||
@@ -278,10 +296,10 @@ const seveDeployment = () => {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
// 表单设计器选择好的内容校验
|
// 表单设计器选择好的内容校验
|
||||||
const formDataVerification = (formValue) => {
|
const formDataVerification = formValue => {
|
||||||
let error = 0
|
let error = 0
|
||||||
// 判断是否包含动态表格batch
|
// 判断是否包含动态表格batch
|
||||||
if (formValue.list.length > 0) {
|
if (formValue && formValue.list && formValue.list.length > 0) {
|
||||||
for (let i = 0; i < formValue.list.length; i++) {
|
for (let i = 0; i < formValue.list.length; i++) {
|
||||||
const items = formValue.list[i]
|
const items = formValue.list[i]
|
||||||
// 处理判断动态表格中
|
// 处理判断动态表格中
|
||||||
@@ -328,7 +346,7 @@ const formDataVerification = (formValue) => {
|
|||||||
return error === 0
|
return error === 0
|
||||||
}
|
}
|
||||||
// 模型整体校验
|
// 模型整体校验
|
||||||
const modelDataVerification = (modelValue) => {
|
const modelDataVerification = modelValue => {
|
||||||
if (JSON.stringify(modelValue).indexOf('dataLegal":false') !== -1) {
|
if (JSON.stringify(modelValue).indexOf('dataLegal":false') !== -1) {
|
||||||
ElMessage.warning('流程未配置完成')
|
ElMessage.warning('流程未配置完成')
|
||||||
return false
|
return false
|
||||||
@@ -345,11 +363,12 @@ defineComponent({
|
|||||||
</script>
|
</script>
|
||||||
<style scoped>
|
<style scoped>
|
||||||
.steps-card {
|
.steps-card {
|
||||||
margin-top: -12px;
|
/* margin-top: -12px;
|
||||||
margin-left: -12px;
|
margin-left: -12px;
|
||||||
margin-right: -12px;
|
margin-right: -12px;
|
||||||
margin-bottom: 10px;
|
margin-bottom: 10px;
|
||||||
padding-top: -10px;
|
padding-top: -10px; */
|
||||||
|
/* width: 100%; */
|
||||||
}
|
}
|
||||||
|
|
||||||
.steps-action {
|
.steps-action {
|
||||||
|
|||||||
92
src/views/system/workflow/model/formDesign.vue
Normal file
92
src/views/system/workflow/model/formDesign.vue
Normal file
@@ -0,0 +1,92 @@
|
|||||||
|
<template>
|
||||||
|
<el-card :bordered="false">
|
||||||
|
<SnowyFormDesign
|
||||||
|
ref="formDesign"
|
||||||
|
:show-head="false"
|
||||||
|
:toolbars="['preview', 'reset', 'importJson', 'exportJson']"
|
||||||
|
show-toolbars-text
|
||||||
|
:database-config="formTableValue"
|
||||||
|
:fields="formDesignFields"
|
||||||
|
:dictData="dictData"
|
||||||
|
/>
|
||||||
|
</el-card>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup>
|
||||||
|
import tool from '@/utils/tool'
|
||||||
|
// import { nextTick } from 'process'
|
||||||
|
// import modelApi from '@/api/flw/modelApi'
|
||||||
|
import { nextTick } from 'vue'
|
||||||
|
import SnowyFormDesignCom from 'snowy-form-design'
|
||||||
|
const dictData = tool.data.get('DICT_TYPE_TREE_DATA')
|
||||||
|
import { ref } from 'vue'
|
||||||
|
const token = tool.data.get('TOKEN')
|
||||||
|
// const apiUrl = tool.data.get('SNOWY_SYS_BASE_CONFIG').SNOWY_SYS_API_URL + '/api/webapp/dev/file/uploadDynamicReturnUrl'
|
||||||
|
|
||||||
|
const formDesign = ref()
|
||||||
|
const formTableValue = ref([])
|
||||||
|
// 表单设计器可以拖的组件
|
||||||
|
const formDesignFields = [
|
||||||
|
'input',
|
||||||
|
'textarea',
|
||||||
|
'number',
|
||||||
|
'select',
|
||||||
|
'checkbox',
|
||||||
|
'radio',
|
||||||
|
'date',
|
||||||
|
'time',
|
||||||
|
'rate',
|
||||||
|
'slider',
|
||||||
|
'uploadFile',
|
||||||
|
'uploadImg',
|
||||||
|
'treeSelect',
|
||||||
|
'batch',
|
||||||
|
'editor',
|
||||||
|
'switch',
|
||||||
|
'alert',
|
||||||
|
'text',
|
||||||
|
'html',
|
||||||
|
'divider',
|
||||||
|
'card',
|
||||||
|
'grid',
|
||||||
|
'table',
|
||||||
|
'xnUserSelector',
|
||||||
|
'xnInput'
|
||||||
|
]
|
||||||
|
// SnowyFormDesignCom.setConfig({
|
||||||
|
// uploadFile: apiUrl, // 上传文件地址
|
||||||
|
// uploadImage: apiUrl, //apiUrl, // 上传图片地址
|
||||||
|
// uploadFileName: 'file', // 上传文件name
|
||||||
|
// uploadImageName: 'file', // 上传图片name
|
||||||
|
// uploadFileData: { data: 'snowy' }, // 上传文件额外参数
|
||||||
|
// uploadImageData: { data: 'snowy' }, // 上传图片额外参数
|
||||||
|
// uploadFileHeaders: { data: 'snowy' }, // 上传文件请求头部
|
||||||
|
// getOrgTree: (param) => {
|
||||||
|
// return modelApi.modelOrgTreeSelector(param).then((data) => {
|
||||||
|
// return Promise.resolve(data)
|
||||||
|
// })
|
||||||
|
// },
|
||||||
|
// getUserPage: (param) => {
|
||||||
|
// return modelApi.modelUserSelector(param).then((data) => {
|
||||||
|
// return Promise.resolve(data)
|
||||||
|
// })
|
||||||
|
// }
|
||||||
|
// })
|
||||||
|
const setValue = (value, tableValue) => {
|
||||||
|
formTableValue.value = tableValue
|
||||||
|
console.log(formTableValue.value,"888777783288382382");
|
||||||
|
// formDesign.value.handleSetData(value)
|
||||||
|
}
|
||||||
|
const getValue = () => {
|
||||||
|
console.log(formDesign.value);
|
||||||
|
if(formDesign.value){
|
||||||
|
nextTick(()=>{
|
||||||
|
return formDesign.value.getValue()
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
defineExpose({
|
||||||
|
getValue,
|
||||||
|
setValue
|
||||||
|
})
|
||||||
|
</script>
|
||||||
@@ -1,36 +1,28 @@
|
|||||||
<!--流程模型表单页面-->
|
<!--流程模型表单页面-->
|
||||||
<template>
|
<template>
|
||||||
<div class='default-main'>
|
<div class="default-main">
|
||||||
<TableHeader>
|
<TableHeader v-if="showTable">
|
||||||
<template v-slot:select>
|
<template v-slot:select>
|
||||||
<el-form-item label='模型名称'>
|
<el-form-item label="模型名称">
|
||||||
<el-input
|
<el-input v-model="tableStore.table.params.searchKey" clearable />
|
||||||
v-model='tableStore.table.params.searchKey'
|
</el-form-item>
|
||||||
clearable
|
<el-form-item label="流程类别">
|
||||||
/>
|
<el-select v-model="tableStore.table.params.category" clearable>
|
||||||
</el-form-item>
|
<el-option v-for="item in categoryList" :key="item.id" :label="item.name" :value="item.code" />
|
||||||
<el-form-item label='流程类别'>
|
</el-select>
|
||||||
<el-select v-model='tableStore.table.params.category' clearable>
|
</el-form-item>
|
||||||
<el-option
|
</template>
|
||||||
v-for='item in categoryList'
|
<template v-slot:operation>
|
||||||
:key='item.id'
|
<el-button type="primary" class="ml10" :icon="Plus" @click="add">新增</el-button>
|
||||||
:label='item.name'
|
</template>
|
||||||
:value='item.code'
|
</TableHeader>
|
||||||
/>
|
<!--表格-->
|
||||||
</el-select>
|
<Table v-if="showTable" ref="tableRef" isGroup></Table>
|
||||||
</el-form-item>
|
<model-popup ref="modelPopup" />
|
||||||
</template>
|
<ConfigSteps v-if="!showTable" ref="configStepsRef" @previousPage="previousPage" />
|
||||||
<template v-slot:operation>
|
</div>
|
||||||
<el-button type='primary' class='ml10' :icon='Plus' @click='add'>新增</el-button>
|
|
||||||
</template>
|
|
||||||
</TableHeader>
|
|
||||||
<!--表格-->
|
|
||||||
<Table ref='tableRef' isGroup></Table>
|
|
||||||
<model-popup ref='modelPopup' />
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
<script lang='ts' setup>
|
<script lang="ts" setup>
|
||||||
import { Plus } from '@element-plus/icons-vue'
|
import { Plus } from '@element-plus/icons-vue'
|
||||||
import TableHeader from '@/components/table/header/index.vue'
|
import TableHeader from '@/components/table/header/index.vue'
|
||||||
import Table from '@/components/table/index.vue'
|
import Table from '@/components/table/index.vue'
|
||||||
@@ -41,151 +33,170 @@ import { ElMessage } from 'element-plus'
|
|||||||
import { useDictData } from '@/stores/dictData'
|
import { useDictData } from '@/stores/dictData'
|
||||||
import { useRouter } from 'vue-router'
|
import { useRouter } from 'vue-router'
|
||||||
import ModelPopup from '@/views/system/workflow/model/modelPopup.vue'
|
import ModelPopup from '@/views/system/workflow/model/modelPopup.vue'
|
||||||
|
import ConfigSteps from './configSteps.vue'
|
||||||
|
const configStepsRef = ref(null)
|
||||||
|
const showTable = ref(true)
|
||||||
const { push } = useRouter()
|
const { push } = useRouter()
|
||||||
const dictData = useDictData()
|
const dictData = useDictData()
|
||||||
const categoryList = dictData.getBasicData('flow_category')
|
const categoryList = dictData.getBasicData('flow_category')
|
||||||
const modelPopup = ref()
|
const modelPopup = ref()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
const tableStore = new TableStore({
|
const tableStore = new TableStore({
|
||||||
url: '/workflow-boot/flw/model/page',
|
url: '/workflow-boot/flw/model/page',
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
column: [
|
column: [
|
||||||
{ title: '序号', type: 'seq', width: 80 },
|
{ title: '序号', type: 'seq', width: 80 },
|
||||||
{ title: '流程名称', minWidth: '160', field: 'name' },
|
{ title: '流程名称', minWidth: '160', field: 'name' },
|
||||||
{
|
{
|
||||||
title: '流程分类', minWidth: '160', field: 'category',
|
title: '流程分类',
|
||||||
formatter: (row: any) => {
|
minWidth: '160',
|
||||||
return categoryList.filter(item => item.code === row.cellValue)[0].name
|
field: 'category',
|
||||||
}
|
formatter: (row: any) => {
|
||||||
},
|
return categoryList.filter(item => item.code === row.cellValue)[0].name
|
||||||
{
|
}
|
||||||
title: '模型版本', minWidth: '120', field: 'versionCode', type: 'html',
|
},
|
||||||
formatter: (obj: any) => {
|
{
|
||||||
const val = obj.row.versionCode
|
title: '模型版本',
|
||||||
if (val) {
|
minWidth: '120',
|
||||||
return `<a href='javascript:void(0);' style='color: #409EFF;text-decoration: none'>V${val}</a>`
|
field: 'versionCode',
|
||||||
} else {
|
type: 'html',
|
||||||
return ''
|
formatter: (obj: any) => {
|
||||||
|
const val = obj.row.versionCode
|
||||||
|
if (val) {
|
||||||
|
return `<a href='javascript:void(0);' style='color: #409EFF;text-decoration: none'>V${val}</a>`
|
||||||
|
} else {
|
||||||
|
return ''
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '表单类型',
|
||||||
|
minWidth: '160',
|
||||||
|
field: 'formType',
|
||||||
|
formatter: (obj: any) => {
|
||||||
|
const val = obj.row.formType
|
||||||
|
if (val == 'DESIGN') {
|
||||||
|
return '系统表单'
|
||||||
|
} else {
|
||||||
|
return ''
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{ title: '排序码', minWidth: '160', field: 'sortCode' },
|
||||||
|
{ title: '状态', minWidth: '160', field: 'modelStatus' },
|
||||||
|
{
|
||||||
|
title: '操作',
|
||||||
|
align: 'center',
|
||||||
|
render: 'buttons',
|
||||||
|
minWidth: '230',
|
||||||
|
fixed: 'right',
|
||||||
|
buttons: [
|
||||||
|
{
|
||||||
|
name: 'view',
|
||||||
|
title: '编辑',
|
||||||
|
type: 'primary',
|
||||||
|
icon: 'el-icon-EditPen',
|
||||||
|
render: 'basicButton',
|
||||||
|
click: row => {
|
||||||
|
modelPopup.value.open('修改模型', row)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'update',
|
||||||
|
title: '设计',
|
||||||
|
type: 'primary',
|
||||||
|
icon: 'el-icon-EditPen',
|
||||||
|
render: 'basicButton',
|
||||||
|
click: row => {
|
||||||
|
go(row)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'deploy',
|
||||||
|
title: '部署',
|
||||||
|
type: 'primary',
|
||||||
|
icon: 'el-icon-EditPen',
|
||||||
|
render: 'basicButton',
|
||||||
|
click: row => {
|
||||||
|
push(`/admin/form/formDesigner?id=${row.id}`)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'deploy',
|
||||||
|
title: '预览流程',
|
||||||
|
type: 'primary',
|
||||||
|
icon: 'el-icon-EditPen',
|
||||||
|
render: 'basicButton',
|
||||||
|
click: row => {
|
||||||
|
push(`/admin/form/formDesigner?id=${row.id}`)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'deploy',
|
||||||
|
title: '历史版本',
|
||||||
|
type: 'primary',
|
||||||
|
icon: 'el-icon-EditPen',
|
||||||
|
render: 'basicButton',
|
||||||
|
click: row => {
|
||||||
|
push(`/admin/form/formDesigner?id=${row.id}`)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'update',
|
||||||
|
title: '删除',
|
||||||
|
type: 'danger',
|
||||||
|
icon: 'el-icon-Delete',
|
||||||
|
render: 'confirmButton',
|
||||||
|
popconfirm: {
|
||||||
|
confirmButtonText: '确认',
|
||||||
|
cancelButtonText: '取消',
|
||||||
|
confirmButtonType: 'danger',
|
||||||
|
title: '确定删除吗?'
|
||||||
|
},
|
||||||
|
click: row => {
|
||||||
|
deleteWFForm(row.id).then(res => {
|
||||||
|
ElMessage.success('删除成功')
|
||||||
|
tableStore.index()
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
}
|
],
|
||||||
},
|
beforeSearchFun: () => {
|
||||||
{
|
for (let key in tableStore.table.params) {
|
||||||
title: '表单类型', minWidth: '160', field: 'formType',
|
if (tableStore.table.params[key] === '') {
|
||||||
formatter: (obj: any) => {
|
delete tableStore.table.params[key]
|
||||||
const val = obj.row.formType
|
}
|
||||||
if (val == 'DESIGN') {
|
|
||||||
return '系统表单'
|
|
||||||
} else {
|
|
||||||
return ''
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
},
|
|
||||||
{ title: '排序码', minWidth: '160', field: 'sortCode' },
|
|
||||||
{ title: '状态', minWidth: '160', field: 'modelStatus' },
|
|
||||||
{
|
|
||||||
title: '操作',
|
|
||||||
align: 'center',
|
|
||||||
render: 'buttons',
|
|
||||||
minWidth: '230',
|
|
||||||
fixed: 'right',
|
|
||||||
buttons: [
|
|
||||||
{
|
|
||||||
name: 'view',
|
|
||||||
title: '编辑',
|
|
||||||
type: 'primary',
|
|
||||||
icon: 'el-icon-EditPen',
|
|
||||||
render: 'basicButton',
|
|
||||||
click: row => {
|
|
||||||
modelPopup.value.open('修改模型', row)
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: 'update',
|
|
||||||
title: '设计',
|
|
||||||
type: 'primary',
|
|
||||||
icon: 'el-icon-EditPen',
|
|
||||||
render: 'basicButton',
|
|
||||||
click: row => {
|
|
||||||
push(`/admin/model/configSteps?id=${row.id}`)
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: 'deploy',
|
|
||||||
title: '部署',
|
|
||||||
type: 'primary',
|
|
||||||
icon: 'el-icon-EditPen',
|
|
||||||
render: 'basicButton',
|
|
||||||
click: row => {
|
|
||||||
push(`/admin/form/formDesigner?id=${row.id}`)
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: 'deploy',
|
|
||||||
title: '预览流程',
|
|
||||||
type: 'primary',
|
|
||||||
icon: 'el-icon-EditPen',
|
|
||||||
render: 'basicButton',
|
|
||||||
click: row => {
|
|
||||||
push(`/admin/form/formDesigner?id=${row.id}`)
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: 'deploy',
|
|
||||||
title: '历史版本',
|
|
||||||
type: 'primary',
|
|
||||||
icon: 'el-icon-EditPen',
|
|
||||||
render: 'basicButton',
|
|
||||||
click: row => {
|
|
||||||
push(`/admin/form/formDesigner?id=${row.id}`)
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: 'update',
|
|
||||||
title: '删除',
|
|
||||||
type: 'danger',
|
|
||||||
icon: 'el-icon-Delete',
|
|
||||||
render: 'confirmButton',
|
|
||||||
popconfirm: {
|
|
||||||
confirmButtonText: '确认',
|
|
||||||
cancelButtonText: '取消',
|
|
||||||
confirmButtonType: 'danger',
|
|
||||||
title: '确定删除吗?'
|
|
||||||
},
|
|
||||||
click: row => {
|
|
||||||
deleteWFForm(row.id).then(res => {
|
|
||||||
ElMessage.success('删除成功')
|
|
||||||
tableStore.index()
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
],
|
|
||||||
beforeSearchFun: () => {
|
|
||||||
for (let key in tableStore.table.params) {
|
|
||||||
if (tableStore.table.params[key] === '') {
|
|
||||||
delete tableStore.table.params[key]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
//新增表单
|
//新增表单
|
||||||
const add = () => {
|
const add = () => {
|
||||||
modelPopup.value.open('新增模型')
|
modelPopup.value.open('新增模型')
|
||||||
|
}
|
||||||
|
const tableRef = ref(null)
|
||||||
|
// config配置界面回调
|
||||||
|
const previousPage = () => {
|
||||||
|
showTable.value = true
|
||||||
|
// nextTick(() => {
|
||||||
|
// tableRef.value.refresh()
|
||||||
|
// })
|
||||||
|
}
|
||||||
|
const go = (row: TableRow) => {
|
||||||
|
showTable.value = false
|
||||||
|
nextTick(() => {
|
||||||
|
configStepsRef.value.configSteps(row)
|
||||||
|
console.log(row, '90999999')
|
||||||
|
})
|
||||||
|
// push(`/admin/model/configSteps?id=${row.id}`)
|
||||||
}
|
}
|
||||||
|
|
||||||
tableStore.table.params.searchKey = ''
|
tableStore.table.params.searchKey = ''
|
||||||
tableStore.table.params.category = ''
|
tableStore.table.params.category = ''
|
||||||
provide('tableStore', tableStore)
|
provide('tableStore', tableStore)
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
// 加载数据
|
// 加载数据
|
||||||
tableStore.index()
|
tableStore.index()
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
<style scoped>
|
<style scoped></style>
|
||||||
|
|
||||||
</style>
|
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-card>
|
<el-card>
|
||||||
|
<!-- 引入workflow组件的位置{{ modelDesignData }}222 -->
|
||||||
|
<!-- {{ modelDesignData.modelValue }} -->
|
||||||
<Workflow
|
<Workflow
|
||||||
v-model="modelDesignData.modelValue"
|
v-model="modelDesignData.modelValue"
|
||||||
:form-field-list-value="formFieldListValue"
|
:form-field-list-value="formFieldListValue"
|
||||||
@@ -16,6 +18,7 @@
|
|||||||
<script setup name="modelDesign">
|
<script setup name="modelDesign">
|
||||||
import Workflow from '@/components/XnWorkflow/index.vue'
|
import Workflow from '@/components/XnWorkflow/index.vue'
|
||||||
import { ref } from 'vue'
|
import { ref } from 'vue'
|
||||||
|
//选择机构角色职位用户
|
||||||
// import modelApi from '@/api/flw/modelApi'
|
// import modelApi from '@/api/flw/modelApi'
|
||||||
// import userCenterApi from '@/api/sys/userCenterApi'
|
// import userCenterApi from '@/api/sys/userCenterApi'
|
||||||
// import templatePrintApi from '@/api/flw/templatePrintApi'
|
// import templatePrintApi from '@/api/flw/templatePrintApi'
|
||||||
@@ -53,7 +56,8 @@
|
|||||||
|
|
||||||
// 回显值
|
// 回显值
|
||||||
const setValue = (value, record) => {
|
const setValue = (value, record) => {
|
||||||
modelDesignData.value = value
|
console.log('获取回显值'+value,record,"+++++++++++--------");
|
||||||
|
modelDesignData.value = JSON.parse(JSON.stringify(value))?JSON.parse(JSON.stringify(value)):{};
|
||||||
recordData.value = record
|
recordData.value = record
|
||||||
// 获取序列号列表
|
// 获取序列号列表
|
||||||
flwTemplateSnSelector().then((data) => {
|
flwTemplateSnSelector().then((data) => {
|
||||||
@@ -76,7 +80,7 @@
|
|||||||
})
|
})
|
||||||
// 获取执行监听器数据
|
// 获取执行监听器数据
|
||||||
executionListenerSelector().then((data) => {
|
executionListenerSelector().then((data) => {
|
||||||
executionListenerArray.value = data.map((item) => {
|
executionListenerArray.value = data.data.map((item) => {
|
||||||
return {
|
return {
|
||||||
label: item,
|
label: item,
|
||||||
value: item
|
value: item
|
||||||
@@ -85,7 +89,8 @@
|
|||||||
})
|
})
|
||||||
// 获取自定义事件执行监听器选择器
|
// 获取自定义事件执行监听器选择器
|
||||||
executionListenerSelectorForCustomEvent().then((data) => {
|
executionListenerSelectorForCustomEvent().then((data) => {
|
||||||
executionListenerSelectorForCustomEventArray.value = data.map((item) => {
|
console.log(data,"00000000000");
|
||||||
|
executionListenerSelectorForCustomEventArray.value = data.data.map((item) => {
|
||||||
return {
|
return {
|
||||||
label: item,
|
label: item,
|
||||||
value: item
|
value: item
|
||||||
@@ -94,7 +99,7 @@
|
|||||||
})
|
})
|
||||||
// 获取任务监听器数据
|
// 获取任务监听器数据
|
||||||
taskListenerSelector().then((data) => {
|
taskListenerSelector().then((data) => {
|
||||||
taskListenerArray.value = data.map((item) => {
|
taskListenerArray.value = data.data.map((item) => {
|
||||||
return {
|
return {
|
||||||
label: item,
|
label: item,
|
||||||
value: item
|
value: item
|
||||||
@@ -156,6 +161,7 @@
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 抛出钩子
|
// 抛出钩子
|
||||||
defineExpose({
|
defineExpose({
|
||||||
getValue,
|
getValue,
|
||||||
|
|||||||
Reference in New Issue
Block a user