Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
datax-cloud
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
黄营
datax-cloud
Commits
cde6371f
Commit
cde6371f
authored
Sep 17, 2020
by
yuwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
项目初始化
parent
c039e7e6
Hide whitespace changes
Inline
Side-by-side
Showing
29 changed files
with
138 additions
and
57 deletions
+138
-57
DataFlowBaseEntity.java
...rc/main/java/cn/datax/common/base/DataFlowBaseEntity.java
+24
-0
DictAop.java
...n/java/cn/datax/common/dictionary/annotation/DictAop.java
+1
-1
DictAnalysis.java
.../java/cn/datax/common/dictionary/config/DictAnalysis.java
+1
-1
DataMetaObjectHandler.java
...cn/datax/common/mybatis/config/DataMetaObjectHandler.java
+1
-0
ConfigVo.java
...rc/main/java/cn/datax/service/system/api/vo/ConfigVo.java
+0
-2
DeptVo.java
.../src/main/java/cn/datax/service/system/api/vo/DeptVo.java
+0
-2
DictItemVo.java
.../main/java/cn/datax/service/system/api/vo/DictItemVo.java
+0
-2
DictVo.java
.../src/main/java/cn/datax/service/system/api/vo/DictVo.java
+0
-2
MenuVo.java
.../src/main/java/cn/datax/service/system/api/vo/MenuVo.java
+0
-3
PostVo.java
.../src/main/java/cn/datax/service/system/api/vo/PostVo.java
+0
-2
RoleVo.java
.../src/main/java/cn/datax/service/system/api/vo/RoleVo.java
+0
-3
UserVo.java
.../src/main/java/cn/datax/service/system/api/vo/UserVo.java
+0
-2
pom.xml
datax-modules/system-service-parent/system-service/pom.xml
+0
-5
ConfigController.java
.../cn/datax/service/system/controller/ConfigController.java
+2
-3
DictController.java
...va/cn/datax/service/system/controller/DictController.java
+9
-3
ConfigService.java
...n/java/cn/datax/service/system/service/ConfigService.java
+2
-0
DictService.java
...ain/java/cn/datax/service/system/service/DictService.java
+3
-0
ConfigServiceImpl.java
.../datax/service/system/service/impl/ConfigServiceImpl.java
+7
-0
DictServiceImpl.java
...cn/datax/service/system/service/impl/DictServiceImpl.java
+12
-0
InitialAuditCompleteTaskListener.java
...e/workflow/flowable/InitialAuditCompleteTaskListener.java
+2
-1
SubmitCompleteTaskListener.java
...service/workflow/flowable/SubmitCompleteTaskListener.java
+1
-0
FlowInstanceServiceImpl.java
...ervice/workflow/service/impl/FlowInstanceServiceImpl.java
+1
-1
FlowTaskServiceImpl.java
...ax/service/workflow/service/impl/FlowTaskServiceImpl.java
+1
-1
ConfigList.vue
datax-ui/src/views/system/config/ConfigList.vue
+11
-4
DictList.vue
datax-ui/src/views/system/dict/DictList.vue
+11
-4
DictItemList.vue
datax-ui/src/views/system/dict/item/DictItemList.vue
+11
-4
PostList.vue
datax-ui/src/views/system/post/PostList.vue
+9
-2
RoleList.vue
datax-ui/src/views/system/role/RoleList.vue
+18
-5
UserList.vue
datax-ui/src/views/system/user/UserList.vue
+11
-4
No files found.
datax-common/datax-common-core/src/main/java/cn/datax/common/base/DataFlowBaseEntity.java
0 → 100644
View file @
cde6371f
package
cn
.
datax
.
common
.
base
;
import
com.baomidou.mybatisplus.annotation.FieldFill
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
@Data
@EqualsAndHashCode
(
callSuper
=
true
)
public
abstract
class
DataFlowBaseEntity
extends
DataScopeBaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 工作流状态
*/
@TableField
(
value
=
"flow_status"
,
fill
=
FieldFill
.
INSERT
)
private
String
flowStatus
;
/**
* 流程实例ID
*/
private
String
processInstanceId
;
}
datax-common/datax-common-
core/src/main/java/cn/datax/common
/annotation/DictAop.java
→
datax-common/datax-common-
dictionary/src/main/java/cn/datax/common/dictionary
/annotation/DictAop.java
View file @
cde6371f
package
cn
.
datax
.
common
.
annotation
;
package
cn
.
datax
.
common
.
dictionary
.
annotation
;
import
java.lang.annotation.*
;
import
java.lang.annotation.*
;
...
...
datax-common/datax-common-dictionary/src/main/java/cn/datax/common/dictionary/config/DictAnalysis.java
View file @
cde6371f
package
cn
.
datax
.
common
.
dictionary
.
config
;
package
cn
.
datax
.
common
.
dictionary
.
config
;
import
cn.datax.common.annotation.DictAop
;
import
cn.datax.common.core.JsonPage
;
import
cn.datax.common.core.JsonPage
;
import
cn.datax.common.core.R
;
import
cn.datax.common.core.R
;
import
cn.datax.common.dictionary.annotation.DictAop
;
import
cn.datax.common.dictionary.utils.DictUtil
;
import
cn.datax.common.dictionary.utils.DictUtil
;
import
com.alibaba.fastjson.JSON
;
import
com.alibaba.fastjson.JSON
;
import
com.alibaba.fastjson.JSONObject
;
import
com.alibaba.fastjson.JSONObject
;
...
...
datax-common/datax-common-mybatis/src/main/java/cn/datax/common/mybatis/config/DataMetaObjectHandler.java
View file @
cde6371f
...
@@ -24,6 +24,7 @@ public class DataMetaObjectHandler implements MetaObjectHandler {
...
@@ -24,6 +24,7 @@ public class DataMetaObjectHandler implements MetaObjectHandler {
if
(
bolCreateDept
)
{
if
(
bolCreateDept
)
{
this
.
strictInsertFill
(
metaObject
,
"createDept"
,
String
.
class
,
getUserDeptId
());
this
.
strictInsertFill
(
metaObject
,
"createDept"
,
String
.
class
,
getUserDeptId
());
}
}
this
.
strictInsertFill
(
metaObject
,
"flowStatus"
,
String
.
class
,
DataConstant
.
AuditState
.
WAIT
);
}
}
@Override
@Override
...
...
datax-modules/system-service-parent/system-service-api/src/main/java/cn/datax/service/system/api/vo/ConfigVo.java
View file @
cde6371f
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
import
cn.datax.common.annotation.DictAop
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
lombok.Data
;
import
lombok.Data
;
...
@@ -21,7 +20,6 @@ public class ConfigVo implements Serializable {
...
@@ -21,7 +20,6 @@ public class ConfigVo implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
private
String
id
;
private
String
id
;
@DictAop
(
code
=
"sys_common_status"
)
private
String
status
;
private
String
status
;
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
private
LocalDateTime
createTime
;
private
LocalDateTime
createTime
;
...
...
datax-modules/system-service-parent/system-service-api/src/main/java/cn/datax/service/system/api/vo/DeptVo.java
View file @
cde6371f
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
import
cn.datax.common.annotation.DictAop
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
lombok.Data
;
import
lombok.Data
;
...
@@ -14,7 +13,6 @@ public class DeptVo implements Serializable {
...
@@ -14,7 +13,6 @@ public class DeptVo implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
private
String
id
;
private
String
id
;
@DictAop
(
code
=
"sys_common_status"
)
private
String
status
;
private
String
status
;
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
private
LocalDateTime
createTime
;
private
LocalDateTime
createTime
;
...
...
datax-modules/system-service-parent/system-service-api/src/main/java/cn/datax/service/system/api/vo/DictItemVo.java
View file @
cde6371f
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
import
cn.datax.common.annotation.DictAop
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
lombok.Data
;
import
lombok.Data
;
...
@@ -21,7 +20,6 @@ public class DictItemVo implements Serializable {
...
@@ -21,7 +20,6 @@ public class DictItemVo implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
private
String
id
;
private
String
id
;
@DictAop
(
code
=
"sys_common_status"
)
private
String
status
;
private
String
status
;
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
private
LocalDateTime
createTime
;
private
LocalDateTime
createTime
;
...
...
datax-modules/system-service-parent/system-service-api/src/main/java/cn/datax/service/system/api/vo/DictVo.java
View file @
cde6371f
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
import
cn.datax.common.annotation.DictAop
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
lombok.Data
;
import
lombok.Data
;
...
@@ -21,7 +20,6 @@ public class DictVo implements Serializable {
...
@@ -21,7 +20,6 @@ public class DictVo implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
private
String
id
;
private
String
id
;
@DictAop
(
code
=
"sys_common_status"
)
private
String
status
;
private
String
status
;
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
private
LocalDateTime
createTime
;
private
LocalDateTime
createTime
;
...
...
datax-modules/system-service-parent/system-service-api/src/main/java/cn/datax/service/system/api/vo/MenuVo.java
View file @
cde6371f
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
import
cn.datax.common.annotation.DictAop
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
lombok.Data
;
import
lombok.Data
;
...
@@ -13,7 +12,6 @@ public class MenuVo implements Serializable {
...
@@ -13,7 +12,6 @@ public class MenuVo implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
private
String
id
;
private
String
id
;
@DictAop
(
code
=
"sys_common_status"
)
private
String
status
;
private
String
status
;
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
private
LocalDateTime
createTime
;
private
LocalDateTime
createTime
;
...
@@ -25,7 +23,6 @@ public class MenuVo implements Serializable {
...
@@ -25,7 +23,6 @@ public class MenuVo implements Serializable {
private
String
menuRedirect
;
private
String
menuRedirect
;
private
String
menuPerms
;
private
String
menuPerms
;
private
String
menuIcon
;
private
String
menuIcon
;
@DictAop
(
code
=
"sys_menu_type"
)
private
String
menuType
;
private
String
menuType
;
private
String
menuCode
;
private
String
menuCode
;
private
Integer
menuHidden
;
private
Integer
menuHidden
;
...
...
datax-modules/system-service-parent/system-service-api/src/main/java/cn/datax/service/system/api/vo/PostVo.java
View file @
cde6371f
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
import
cn.datax.common.annotation.DictAop
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
lombok.Data
;
import
lombok.Data
;
...
@@ -13,7 +12,6 @@ public class PostVo implements Serializable {
...
@@ -13,7 +12,6 @@ public class PostVo implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
private
String
id
;
private
String
id
;
@DictAop
(
code
=
"sys_common_status"
)
private
String
status
;
private
String
status
;
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
private
LocalDateTime
createTime
;
private
LocalDateTime
createTime
;
...
...
datax-modules/system-service-parent/system-service-api/src/main/java/cn/datax/service/system/api/vo/RoleVo.java
View file @
cde6371f
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
import
cn.datax.common.annotation.DictAop
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
lombok.Data
;
import
lombok.Data
;
...
@@ -14,14 +13,12 @@ public class RoleVo implements Serializable {
...
@@ -14,14 +13,12 @@ public class RoleVo implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
private
String
id
;
private
String
id
;
@DictAop
(
code
=
"sys_common_status"
)
private
String
status
;
private
String
status
;
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
private
LocalDateTime
createTime
;
private
LocalDateTime
createTime
;
private
String
remark
;
private
String
remark
;
private
String
roleName
;
private
String
roleName
;
private
String
roleCode
;
private
String
roleCode
;
@DictAop
(
code
=
"sys_data_scope"
)
private
String
dataScope
;
private
String
dataScope
;
private
List
<
MenuVo
>
menus
;
private
List
<
MenuVo
>
menus
;
private
List
<
DeptVo
>
depts
;
private
List
<
DeptVo
>
depts
;
...
...
datax-modules/system-service-parent/system-service-api/src/main/java/cn/datax/service/system/api/vo/UserVo.java
View file @
cde6371f
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
package
cn
.
datax
.
service
.
system
.
api
.
vo
;
import
cn.datax.common.annotation.DictAop
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
lombok.Data
;
import
lombok.Data
;
...
@@ -15,7 +14,6 @@ public class UserVo implements Serializable {
...
@@ -15,7 +14,6 @@ public class UserVo implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
private
String
id
;
private
String
id
;
@DictAop
(
code
=
"sys_common_status"
)
private
String
status
;
private
String
status
;
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
private
LocalDateTime
createTime
;
private
LocalDateTime
createTime
;
...
...
datax-modules/system-service-parent/system-service/pom.xml
View file @
cde6371f
...
@@ -79,11 +79,6 @@
...
@@ -79,11 +79,6 @@
<artifactId>
datax-common-jasperreport
</artifactId>
<artifactId>
datax-common-jasperreport
</artifactId>
<version>
2.0.0
</version>
<version>
2.0.0
</version>
</dependency>
</dependency>
<dependency>
<groupId>
cn.datax
</groupId>
<artifactId>
datax-common-dictionary
</artifactId>
<version>
2.0.0
</version>
</dependency>
</dependencies>
</dependencies>
<build>
<build>
...
...
datax-modules/system-service-parent/system-service/src/main/java/cn/datax/service/system/controller/ConfigController.java
View file @
cde6371f
...
@@ -2,7 +2,6 @@ package cn.datax.service.system.controller;
...
@@ -2,7 +2,6 @@ package cn.datax.service.system.controller;
import
cn.datax.common.core.JsonPage
;
import
cn.datax.common.core.JsonPage
;
import
cn.datax.common.core.R
;
import
cn.datax.common.core.R
;
import
cn.datax.common.dictionary.utils.ConfigUtil
;
import
cn.datax.common.validate.ValidationGroups
;
import
cn.datax.common.validate.ValidationGroups
;
import
cn.datax.service.system.api.dto.ConfigDto
;
import
cn.datax.service.system.api.dto.ConfigDto
;
import
cn.datax.service.system.api.entity.ConfigEntity
;
import
cn.datax.service.system.api.entity.ConfigEntity
;
...
@@ -135,8 +134,8 @@ public class ConfigController extends BaseController {
...
@@ -135,8 +134,8 @@ public class ConfigController extends BaseController {
*/
*/
@GetMapping
(
"/key/{key}"
)
@GetMapping
(
"/key/{key}"
)
public
R
getConfig
(
@PathVariable
String
key
)
{
public
R
getConfig
(
@PathVariable
String
key
)
{
Object
obj
=
ConfigUtil
.
getInstance
()
.
getConfig
(
key
);
String
val
=
configService
.
getConfig
(
key
);
return
R
.
ok
().
setData
(
obj
);
return
R
.
ok
().
setData
(
val
);
}
}
/**
/**
...
...
datax-modules/system-service-parent/system-service/src/main/java/cn/datax/service/system/controller/DictController.java
View file @
cde6371f
...
@@ -2,12 +2,14 @@ package cn.datax.service.system.controller;
...
@@ -2,12 +2,14 @@ package cn.datax.service.system.controller;
import
cn.datax.common.core.JsonPage
;
import
cn.datax.common.core.JsonPage
;
import
cn.datax.common.core.R
;
import
cn.datax.common.core.R
;
import
cn.datax.common.dictionary.utils.DictUtil
;
import
cn.datax.common.validate.ValidationGroups
;
import
cn.datax.common.validate.ValidationGroups
;
import
cn.datax.service.system.api.dto.DictDto
;
import
cn.datax.service.system.api.dto.DictDto
;
import
cn.datax.service.system.api.entity.DictEntity
;
import
cn.datax.service.system.api.entity.DictEntity
;
import
cn.datax.service.system.api.entity.DictItemEntity
;
import
cn.datax.service.system.api.vo.DictItemVo
;
import
cn.datax.service.system.api.vo.DictVo
;
import
cn.datax.service.system.api.vo.DictVo
;
import
cn.datax.service.system.api.query.DictQuery
;
import
cn.datax.service.system.api.query.DictQuery
;
import
cn.datax.service.system.mapstruct.DictItemMapper
;
import
cn.datax.service.system.mapstruct.DictMapper
;
import
cn.datax.service.system.mapstruct.DictMapper
;
import
cn.datax.service.system.service.DictService
;
import
cn.datax.service.system.service.DictService
;
import
cn.hutool.core.util.StrUtil
;
import
cn.hutool.core.util.StrUtil
;
...
@@ -46,6 +48,9 @@ public class DictController extends BaseController {
...
@@ -46,6 +48,9 @@ public class DictController extends BaseController {
@Autowired
@Autowired
private
DictMapper
dictMapper
;
private
DictMapper
dictMapper
;
@Autowired
private
DictItemMapper
dictItemMapper
;
/**
/**
* 通过ID查询信息
* 通过ID查询信息
*
*
...
@@ -138,8 +143,9 @@ public class DictController extends BaseController {
...
@@ -138,8 +143,9 @@ public class DictController extends BaseController {
*/
*/
@GetMapping
(
"/code/{code}"
)
@GetMapping
(
"/code/{code}"
)
public
R
getDictItems
(
@PathVariable
String
code
)
{
public
R
getDictItems
(
@PathVariable
String
code
)
{
Object
list
=
DictUtil
.
getInstance
().
getDictItemList
(
code
);
List
<
DictItemEntity
>
list
=
dictService
.
getDictItems
(
code
);
return
R
.
ok
().
setData
(
list
);
List
<
DictItemVo
>
collect
=
list
.
stream
().
map
(
dictItemMapper:
:
toVO
).
collect
(
Collectors
.
toList
());
return
R
.
ok
().
setData
(
collect
);
}
}
/**
/**
...
...
datax-modules/system-service-parent/system-service/src/main/java/cn/datax/service/system/service/ConfigService.java
View file @
cde6371f
...
@@ -26,5 +26,7 @@ public interface ConfigService extends BaseService<ConfigEntity> {
...
@@ -26,5 +26,7 @@ public interface ConfigService extends BaseService<ConfigEntity> {
void
deleteConfigBatch
(
List
<
String
>
ids
);
void
deleteConfigBatch
(
List
<
String
>
ids
);
String
getConfig
(
String
key
);
void
refreshConfig
();
void
refreshConfig
();
}
}
datax-modules/system-service-parent/system-service/src/main/java/cn/datax/service/system/service/DictService.java
View file @
cde6371f
...
@@ -3,6 +3,7 @@ package cn.datax.service.system.service;
...
@@ -3,6 +3,7 @@ package cn.datax.service.system.service;
import
cn.datax.service.system.api.entity.DictEntity
;
import
cn.datax.service.system.api.entity.DictEntity
;
import
cn.datax.service.system.api.dto.DictDto
;
import
cn.datax.service.system.api.dto.DictDto
;
import
cn.datax.common.base.BaseService
;
import
cn.datax.common.base.BaseService
;
import
cn.datax.service.system.api.entity.DictItemEntity
;
import
java.util.List
;
import
java.util.List
;
...
@@ -24,5 +25,7 @@ public interface DictService extends BaseService<DictEntity> {
...
@@ -24,5 +25,7 @@ public interface DictService extends BaseService<DictEntity> {
void
deleteDictBatch
(
List
<
String
>
ids
);
void
deleteDictBatch
(
List
<
String
>
ids
);
List
<
DictItemEntity
>
getDictItems
(
String
code
);
void
refreshDict
();
void
refreshDict
();
}
}
datax-modules/system-service-parent/system-service/src/main/java/cn/datax/service/system/service/impl/ConfigServiceImpl.java
View file @
cde6371f
...
@@ -16,6 +16,7 @@ import org.springframework.transaction.annotation.Transactional;
...
@@ -16,6 +16,7 @@ import org.springframework.transaction.annotation.Transactional;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.Map
;
import
java.util.Optional
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
/**
/**
...
@@ -74,6 +75,12 @@ public class ConfigServiceImpl extends BaseServiceImpl<ConfigDao, ConfigEntity>
...
@@ -74,6 +75,12 @@ public class ConfigServiceImpl extends BaseServiceImpl<ConfigDao, ConfigEntity>
}
}
@Override
@Override
public
String
getConfig
(
String
key
)
{
Object
o
=
redisService
.
hget
(
RedisConstant
.
SYSTEM_CONFIG_KEY
,
key
);
return
(
String
)
Optional
.
ofNullable
(
o
).
orElse
(
""
);
}
@Override
public
void
refreshConfig
()
{
public
void
refreshConfig
()
{
String
key
=
RedisConstant
.
SYSTEM_CONFIG_KEY
;
String
key
=
RedisConstant
.
SYSTEM_CONFIG_KEY
;
Boolean
hasKey
=
redisService
.
hasKey
(
key
);
Boolean
hasKey
=
redisService
.
hasKey
(
key
);
...
...
datax-modules/system-service-parent/system-service/src/main/java/cn/datax/service/system/service/impl/DictServiceImpl.java
View file @
cde6371f
...
@@ -6,6 +6,7 @@ import cn.datax.common.exception.DataException;
...
@@ -6,6 +6,7 @@ import cn.datax.common.exception.DataException;
import
cn.datax.common.redis.service.RedisService
;
import
cn.datax.common.redis.service.RedisService
;
import
cn.datax.service.system.api.entity.DictEntity
;
import
cn.datax.service.system.api.entity.DictEntity
;
import
cn.datax.service.system.api.dto.DictDto
;
import
cn.datax.service.system.api.dto.DictDto
;
import
cn.datax.service.system.api.entity.DictItemEntity
;
import
cn.datax.service.system.service.DictService
;
import
cn.datax.service.system.service.DictService
;
import
cn.datax.service.system.mapstruct.DictMapper
;
import
cn.datax.service.system.mapstruct.DictMapper
;
import
cn.datax.service.system.dao.DictDao
;
import
cn.datax.service.system.dao.DictDao
;
...
@@ -17,6 +18,7 @@ import org.springframework.transaction.annotation.Propagation;
...
@@ -17,6 +18,7 @@ import org.springframework.transaction.annotation.Propagation;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.transaction.annotation.Transactional
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Optional
;
/**
/**
* <p>
* <p>
...
@@ -72,6 +74,16 @@ public class DictServiceImpl extends BaseServiceImpl<DictDao, DictEntity> implem
...
@@ -72,6 +74,16 @@ public class DictServiceImpl extends BaseServiceImpl<DictDao, DictEntity> implem
}
}
@Override
@Override
public
List
<
DictItemEntity
>
getDictItems
(
String
code
)
{
List
<
DictEntity
>
dictEntityList
=
(
List
<
DictEntity
>)
redisService
.
get
(
RedisConstant
.
SYSTEM_DICT_KEY
);
Optional
<
DictEntity
>
dictEntityOptional
=
dictEntityList
.
stream
().
filter
(
s
->
code
.
equals
(
s
.
getDictCode
())).
findFirst
();
if
(
dictEntityOptional
.
isPresent
())
{
return
dictEntityOptional
.
get
().
getItems
();
}
return
null
;
}
@Override
public
void
refreshDict
()
{
public
void
refreshDict
()
{
String
key
=
RedisConstant
.
SYSTEM_DICT_KEY
;
String
key
=
RedisConstant
.
SYSTEM_DICT_KEY
;
Boolean
hasKey
=
redisService
.
hasKey
(
key
);
Boolean
hasKey
=
redisService
.
hasKey
(
key
);
...
...
datax-modules/workflow-service-parent/workflow-service/src/main/java/cn/datax/service/workflow/flowable/InitialAuditCompleteTaskListener.java
View file @
cde6371f
...
@@ -20,7 +20,8 @@ public class InitialAuditCompleteTaskListener implements TaskListener {
...
@@ -20,7 +20,8 @@ public class InitialAuditCompleteTaskListener implements TaskListener {
log
.
info
(
"任务执行人:{}"
,
delegateTask
.
getAssignee
());
log
.
info
(
"任务执行人:{}"
,
delegateTask
.
getAssignee
());
log
.
info
(
"任务配置ID: {}"
,
delegateTask
.
getTaskDefinitionKey
());
log
.
info
(
"任务配置ID: {}"
,
delegateTask
.
getTaskDefinitionKey
());
Map
<
String
,
Object
>
variables
=
delegateTask
.
getVariables
();
Map
<
String
,
Object
>
variables
=
delegateTask
.
getVariables
();
Boolean
approved
=
(
Boolean
)
Optional
.
ofNullable
(
variables
).
map
(
s
->
s
.
get
(
VariablesEnum
.
approved
)).
orElse
(
true
);
log
.
info
(
"获取Variables:{}"
,
variables
);
Boolean
approved
=
(
Boolean
)
Optional
.
ofNullable
(
variables
).
map
(
s
->
s
.
get
(
VariablesEnum
.
approved
.
toString
())).
orElse
(
true
);
log
.
info
(
"审核结果: {}"
,
approved
);
log
.
info
(
"审核结果: {}"
,
approved
);
// 退回操作
// 退回操作
if
(!
approved
)
{
if
(!
approved
)
{
...
...
datax-modules/workflow-service-parent/workflow-service/src/main/java/cn/datax/service/workflow/flowable/SubmitCompleteTaskListener.java
View file @
cde6371f
...
@@ -22,6 +22,7 @@ public class SubmitCompleteTaskListener implements TaskListener {
...
@@ -22,6 +22,7 @@ public class SubmitCompleteTaskListener implements TaskListener {
// 发送消息队列
// 发送消息队列
String
businessKey
=
(
String
)
variables
.
get
(
VariablesEnum
.
businessKey
.
toString
());
String
businessKey
=
(
String
)
variables
.
get
(
VariablesEnum
.
businessKey
.
toString
());
String
businessCode
=
(
String
)
variables
.
get
(
VariablesEnum
.
businessCode
.
toString
());
String
businessCode
=
(
String
)
variables
.
get
(
VariablesEnum
.
businessCode
.
toString
());
// 删除审核参数
log
.
info
(
"业务审核中:{},{}"
,
businessKey
,
businessCode
);
log
.
info
(
"业务审核中:{},{}"
,
businessKey
,
businessCode
);
log
.
info
(
"业务审核中状态:{}"
,
DataConstant
.
AuditState
.
AUDIT
.
getKey
());
log
.
info
(
"业务审核中状态:{}"
,
DataConstant
.
AuditState
.
AUDIT
.
getKey
());
log
.
info
(
"退出提交节点用户任务完成监听器"
);
log
.
info
(
"退出提交节点用户任务完成监听器"
);
...
...
datax-modules/workflow-service-parent/workflow-service/src/main/java/cn/datax/service/workflow/service/impl/FlowInstanceServiceImpl.java
View file @
cde6371f
...
@@ -129,7 +129,7 @@ public class FlowInstanceServiceImpl implements FlowInstanceService {
...
@@ -129,7 +129,7 @@ public class FlowInstanceServiceImpl implements FlowInstanceService {
private
void
completeFirstTask
(
String
submitter
,
String
processInstanceId
){
private
void
completeFirstTask
(
String
submitter
,
String
processInstanceId
){
Task
task
=
taskService
.
createTaskQuery
().
taskAssignee
(
submitter
).
processInstanceId
(
processInstanceId
).
active
().
singleResult
();
Task
task
=
taskService
.
createTaskQuery
().
taskAssignee
(
submitter
).
processInstanceId
(
processInstanceId
).
active
().
singleResult
();
if
(
task
!=
null
)
{
if
(
task
!=
null
)
{
log
.
info
(
"自动完成
第一个
任务,任务ID:{}"
,
task
.
getId
());
log
.
info
(
"自动完成
提交
任务,任务ID:{}"
,
task
.
getId
());
Comment
comment
=
taskService
.
addComment
(
task
.
getId
(),
processInstanceId
,
"任务提交"
);
Comment
comment
=
taskService
.
addComment
(
task
.
getId
(),
processInstanceId
,
"任务提交"
);
comment
.
setUserId
(
submitter
);
comment
.
setUserId
(
submitter
);
taskService
.
saveComment
(
comment
);
taskService
.
saveComment
(
comment
);
...
...
datax-modules/workflow-service-parent/workflow-service/src/main/java/cn/datax/service/workflow/service/impl/FlowTaskServiceImpl.java
View file @
cde6371f
...
@@ -149,7 +149,7 @@ public class FlowTaskServiceImpl implements FlowTaskService {
...
@@ -149,7 +149,7 @@ public class FlowTaskServiceImpl implements FlowTaskService {
private
void
completeTask
(
String
taskId
,
Map
<
String
,
Object
>
variables
,
String
processInstanceId
,
String
message
)
{
private
void
completeTask
(
String
taskId
,
Map
<
String
,
Object
>
variables
,
String
processInstanceId
,
String
message
)
{
log
.
info
(
"完成任务ID:{}"
,
taskId
);
log
.
info
(
"完成任务ID:{}"
,
taskId
);
Boolean
approved
=
(
Boolean
)
Optional
.
ofNullable
(
variables
).
map
(
s
->
s
.
get
(
VariablesEnum
.
approved
)).
orElse
(
true
);
Boolean
approved
=
(
Boolean
)
Optional
.
ofNullable
(
variables
).
map
(
s
->
s
.
get
(
VariablesEnum
.
approved
.
toString
()
)).
orElse
(
true
);
this
.
addComment
(
ActionEnum
.
COMPLETE
,
taskId
,
processInstanceId
,
StrUtil
.
isBlank
(
message
)
?
(
approved
?
"默认同意"
:
"默认不同意"
)
:
message
);
this
.
addComment
(
ActionEnum
.
COMPLETE
,
taskId
,
processInstanceId
,
StrUtil
.
isBlank
(
message
)
?
(
approved
?
"默认同意"
:
"默认不同意"
)
:
message
);
taskService
.
complete
(
taskId
,
variables
);
taskService
.
complete
(
taskId
,
variables
);
}
}
...
...
datax-ui/src/views/system/config/ConfigList.vue
View file @
cde6371f
...
@@ -219,10 +219,17 @@ export default {
...
@@ -219,10 +219,17 @@ export default {
pageNum
:
1
,
pageNum
:
1
,
pageSize
:
20
,
pageSize
:
20
,
configName
:
''
configName
:
''
}
},
// 状态数据字典
statusOptions
:
[]
}
}
},
},
created
()
{
created
()
{
this
.
getDicts
(
'sys_common_status'
).
then
(
response
=>
{
if
(
response
.
success
)
{
this
.
statusOptions
=
response
.
data
}
})
this
.
getList
()
this
.
getList
()
},
},
mounted
()
{
mounted
()
{
...
@@ -351,11 +358,11 @@ export default {
...
@@ -351,11 +358,11 @@ export default {
this
.
getList
()
this
.
getList
()
},
},
statusFormatter
(
row
,
column
,
cellValue
,
index
)
{
statusFormatter
(
row
,
column
,
cellValue
,
index
)
{
const
dict
Text
=
row
.
status_dictText
const
dict
Label
=
this
.
selectDictLabel
(
this
.
statusOptions
,
cellValue
)
if
(
cellValue
===
'1'
)
{
if
(
cellValue
===
'1'
)
{
return
<
el
-
tag
type
=
'success'
>
{
dict
Text
}
<
/el-tag
>
return
<
el
-
tag
type
=
'success'
>
{
dict
Label
}
<
/el-tag
>
}
else
{
}
else
{
return
<
el
-
tag
type
=
'warning'
>
{
dict
Text
}
<
/el-tag
>
return
<
el
-
tag
type
=
'warning'
>
{
dict
Label
}
<
/el-tag
>
}
}
}
}
}
}
...
...
datax-ui/src/views/system/dict/DictList.vue
View file @
cde6371f
...
@@ -236,10 +236,17 @@ export default {
...
@@ -236,10 +236,17 @@ export default {
pageSize
:
20
,
pageSize
:
20
,
dictName
:
''
,
dictName
:
''
,
dictCode
:
''
dictCode
:
''
}
},
// 状态数据字典
statusOptions
:
[]
}
}
},
},
created
()
{
created
()
{
this
.
getDicts
(
'sys_common_status'
).
then
(
response
=>
{
if
(
response
.
success
)
{
this
.
statusOptions
=
response
.
data
}
})
this
.
getList
()
this
.
getList
()
},
},
mounted
()
{
mounted
()
{
...
@@ -394,11 +401,11 @@ export default {
...
@@ -394,11 +401,11 @@ export default {
this
.
getList
()
this
.
getList
()
},
},
statusFormatter
(
row
,
column
,
cellValue
,
index
)
{
statusFormatter
(
row
,
column
,
cellValue
,
index
)
{
const
dict
Text
=
row
.
status_dictText
const
dict
Label
=
this
.
selectDictLabel
(
this
.
statusOptions
,
cellValue
)
if
(
cellValue
===
'1'
)
{
if
(
cellValue
===
'1'
)
{
return
<
el
-
tag
type
=
'success'
>
{
dict
Text
}
<
/el-tag
>
return
<
el
-
tag
type
=
'success'
>
{
dict
Label
}
<
/el-tag
>
}
else
{
}
else
{
return
<
el
-
tag
type
=
'warning'
>
{
dict
Text
}
<
/el-tag
>
return
<
el
-
tag
type
=
'warning'
>
{
dict
Label
}
<
/el-tag
>
}
}
}
}
}
}
...
...
datax-ui/src/views/system/dict/item/DictItemList.vue
View file @
cde6371f
...
@@ -227,12 +227,19 @@ export default {
...
@@ -227,12 +227,19 @@ export default {
dictId
:
''
,
dictId
:
''
,
itemText
:
''
,
itemText
:
''
,
itemValue
:
''
itemValue
:
''
}
},
// 状态数据字典
statusOptions
:
[]
}
}
},
},
created
()
{
created
()
{
console
.
log
(
'data:'
+
JSON
.
stringify
(
this
.
data
))
console
.
log
(
'data:'
+
JSON
.
stringify
(
this
.
data
))
this
.
queryParams
.
dictId
=
this
.
data
.
dictId
this
.
queryParams
.
dictId
=
this
.
data
.
dictId
this
.
getDicts
(
'sys_common_status'
).
then
(
response
=>
{
if
(
response
.
success
)
{
this
.
statusOptions
=
response
.
data
}
})
this
.
getList
()
this
.
getList
()
},
},
mounted
()
{
mounted
()
{
...
@@ -367,11 +374,11 @@ export default {
...
@@ -367,11 +374,11 @@ export default {
this
.
getList
()
this
.
getList
()
},
},
statusFormatter
(
row
,
column
,
cellValue
,
index
)
{
statusFormatter
(
row
,
column
,
cellValue
,
index
)
{
const
dict
Text
=
row
.
status_dictText
const
dict
Label
=
this
.
selectDictLabel
(
this
.
statusOptions
,
cellValue
)
if
(
cellValue
===
'1'
)
{
if
(
cellValue
===
'1'
)
{
return
<
el
-
tag
type
=
'success'
>
{
dict
Text
}
<
/el-tag
>
return
<
el
-
tag
type
=
'success'
>
{
dict
Label
}
<
/el-tag
>
}
else
{
}
else
{
return
<
el
-
tag
type
=
'warning'
>
{
dict
Text
}
<
/el-tag
>
return
<
el
-
tag
type
=
'warning'
>
{
dict
Label
}
<
/el-tag
>
}
}
}
}
}
}
...
...
datax-ui/src/views/system/post/PostList.vue
View file @
cde6371f
...
@@ -210,10 +210,17 @@ export default {
...
@@ -210,10 +210,17 @@ export default {
pageNum
:
1
,
pageNum
:
1
,
pageSize
:
20
,
pageSize
:
20
,
postName
:
''
postName
:
''
}
},
// 状态数据字典
statusOptions
:
[]
}
}
},
},
created
()
{
created
()
{
this
.
getDicts
(
'sys_common_status'
).
then
(
response
=>
{
if
(
response
.
success
)
{
this
.
statusOptions
=
response
.
data
}
})
this
.
getList
()
this
.
getList
()
},
},
mounted
()
{
mounted
()
{
...
@@ -332,7 +339,7 @@ export default {
...
@@ -332,7 +339,7 @@ export default {
this
.
getList
()
this
.
getList
()
},
},
statusFormatter
(
row
,
column
,
cellValue
,
index
)
{
statusFormatter
(
row
,
column
,
cellValue
,
index
)
{
const
dictText
=
row
.
status_dictText
const
dictText
=
this
.
selectDictLabel
(
this
.
statusOptions
,
cellValue
)
if
(
cellValue
===
'1'
)
{
if
(
cellValue
===
'1'
)
{
return
<
el
-
tag
type
=
'success'
>
{
dictText
}
<
/el-tag
>
return
<
el
-
tag
type
=
'success'
>
{
dictText
}
<
/el-tag
>
}
else
{
}
else
{
...
...
datax-ui/src/views/system/role/RoleList.vue
View file @
cde6371f
...
@@ -217,10 +217,24 @@ export default {
...
@@ -217,10 +217,24 @@ export default {
pageNum
:
1
,
pageNum
:
1
,
pageSize
:
20
,
pageSize
:
20
,
roleName
:
''
roleName
:
''
}
},
// 状态数据字典
statusOptions
:
[],
// 数据范围数据字典
dataScopeOptions
:
[]
}
}
},
},
created
()
{
created
()
{
this
.
getDicts
(
'sys_common_status'
).
then
(
response
=>
{
if
(
response
.
success
)
{
this
.
statusOptions
=
response
.
data
}
})
this
.
getDicts
(
'sys_data_scope'
).
then
(
response
=>
{
if
(
response
.
success
)
{
this
.
dataScopeOptions
=
response
.
data
}
})
this
.
getList
()
this
.
getList
()
},
},
mounted
()
{
mounted
()
{
...
@@ -339,12 +353,11 @@ export default {
...
@@ -339,12 +353,11 @@ export default {
this
.
getList
()
this
.
getList
()
},
},
dataScopeFormatter
(
row
,
column
,
cellValue
,
index
)
{
dataScopeFormatter
(
row
,
column
,
cellValue
,
index
)
{
const
dataScope
=
row
.
dataScope
const
dictText
=
this
.
selectDictLabel
(
this
.
dataScopeOptions
,
cellValue
)
const
dataScope_dictText
=
row
.
dataScope_dictText
return
dictText
return
dataScope_dictText
},
},
statusFormatter
(
row
,
column
,
cellValue
,
index
)
{
statusFormatter
(
row
,
column
,
cellValue
,
index
)
{
const
dictText
=
row
.
status_dictText
const
dictText
=
this
.
selectDictLabel
(
this
.
statusOptions
,
cellValue
)
if
(
cellValue
===
'1'
)
{
if
(
cellValue
===
'1'
)
{
return
<
el
-
tag
type
=
'success'
>
{
dictText
}
<
/el-tag
>
return
<
el
-
tag
type
=
'success'
>
{
dictText
}
<
/el-tag
>
}
else
{
}
else
{
...
...
datax-ui/src/views/system/user/UserList.vue
View file @
cde6371f
...
@@ -280,10 +280,17 @@ export default {
...
@@ -280,10 +280,17 @@ export default {
defaultProps
:
{
defaultProps
:
{
children
:
'children'
,
children
:
'children'
,
label
:
'deptName'
label
:
'deptName'
}
},
// 状态数据字典
statusOptions
:
[]
}
}
},
},
created
()
{
created
()
{
this
.
getDicts
(
'sys_common_status'
).
then
(
response
=>
{
if
(
response
.
success
)
{
this
.
statusOptions
=
response
.
data
}
})
this
.
getList
()
this
.
getList
()
this
.
getDeptTree
()
this
.
getDeptTree
()
},
},
...
@@ -433,11 +440,11 @@ export default {
...
@@ -433,11 +440,11 @@ export default {
return
row
.
posts
.
map
(
item
=>
item
.
postName
).
join
(
','
)
return
row
.
posts
.
map
(
item
=>
item
.
postName
).
join
(
','
)
},
},
statusFormatter
(
row
,
column
,
cellValue
,
index
)
{
statusFormatter
(
row
,
column
,
cellValue
,
index
)
{
const
dictText
=
row
.
status_dictText
const
dictText
=
this
.
selectDictLabel
(
this
.
statusOptions
,
cellValue
)
if
(
cellValue
===
'1'
)
{
if
(
cellValue
===
'1'
)
{
return
<
el
-
tag
type
=
"success"
>
{
dictText
}
<
/el-tag
>
return
<
el
-
tag
type
=
'success'
>
{
dictText
}
<
/el-tag
>
}
else
{
}
else
{
return
<
el
-
tag
type
=
"warning"
>
{
dictText
}
<
/el-tag
>
return
<
el
-
tag
type
=
'warning'
>
{
dictText
}
<
/el-tag
>
}
}
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment