Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
I
ibzrt
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
ibiz4jteam
ibzrt
提交
71ffc6c5
提交
71ffc6c5
编写于
5月 27, 2020
作者:
ibizdev
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
lab_qyk 发布系统代码
上级
f4919721
变更
95
隐藏空白字符变更
内嵌
并排
正在显示
95 个修改的文件
包含
2959 行增加
和
4104 行删除
+2959
-4104
router.ts
app_Web/src/pages/rt/index/router.ts
+0
-460
state.ts
app_Web/src/store/modules/view-action/state.ts
+0
-346
config.xml
config.xml
+0
-5
Dockerfile
ibzrt-app/ibzrt-app-web/src/main/docker/Dockerfile
+1
-1
ibzrt-app-web.yaml
ibzrt-app/ibzrt-app-web/src/main/docker/ibzrt-app-web.yaml
+1
-13
application-web-prod.yml
...ibzrt-app-web/src/main/resources/application-web-prod.yml
+8
-8
application-dev.yml
ibzrt-boot/src/main/resources/application-dev.yml
+60
-8
IBZDictFallback.java
...ain/java/cn/ibizlab/core/dict/client/IBZDictFallback.java
+76
-0
IBZDictFeignClient.java
.../java/cn/ibizlab/core/dict/client/IBZDictFeignClient.java
+71
-0
IBZDictItemFallback.java
...java/cn/ibizlab/core/dict/client/IBZDictItemFallback.java
+76
-0
IBZDictItemFeignClient.java
...a/cn/ibizlab/core/dict/client/IBZDictItemFeignClient.java
+71
-0
IBZDict.java
...re/src/main/java/cn/ibizlab/core/dict/domain/IBZDict.java
+13
-20
IBZDictItem.java
...rc/main/java/cn/ibizlab/core/dict/domain/IBZDictItem.java
+19
-41
IBZDictItemSearchContext.java
...cn/ibizlab/core/dict/filter/IBZDictItemSearchContext.java
+6
-35
IBZDictSearchContext.java
...ava/cn/ibizlab/core/dict/filter/IBZDictSearchContext.java
+6
-30
IIBZDictItemService.java
...ava/cn/ibizlab/core/dict/service/IIBZDictItemService.java
+2
-20
IIBZDictService.java
...in/java/cn/ibizlab/core/dict/service/IIBZDictService.java
+2
-20
IBZDictItemServiceImpl.java
...bizlab/core/dict/service/impl/IBZDictItemServiceImpl.java
+43
-107
IBZDictServiceImpl.java
...cn/ibizlab/core/dict/service/impl/IBZDictServiceImpl.java
+32
-108
IBZDepartmentFallback.java
...java/cn/ibizlab/core/ou/client/IBZDepartmentFallback.java
+81
-0
IBZDepartmentFeignClient.java
...a/cn/ibizlab/core/ou/client/IBZDepartmentFeignClient.java
+76
-0
IBZDeptMemberFallback.java
...java/cn/ibizlab/core/ou/client/IBZDeptMemberFallback.java
+76
-0
IBZDeptMemberFeignClient.java
...a/cn/ibizlab/core/ou/client/IBZDeptMemberFeignClient.java
+71
-0
IBZEmployeeFallback.java
...n/java/cn/ibizlab/core/ou/client/IBZEmployeeFallback.java
+80
-0
IBZEmployeeFeignClient.java
...ava/cn/ibizlab/core/ou/client/IBZEmployeeFeignClient.java
+75
-0
IBZOrganizationFallback.java
...va/cn/ibizlab/core/ou/client/IBZOrganizationFallback.java
+86
-0
IBZOrganizationFeignClient.java
...cn/ibizlab/core/ou/client/IBZOrganizationFeignClient.java
+81
-0
IBZDepartment.java
...rc/main/java/cn/ibizlab/core/ou/domain/IBZDepartment.java
+24
-32
IBZDeptMember.java
...rc/main/java/cn/ibizlab/core/ou/domain/IBZDeptMember.java
+13
-36
IBZEmployee.java
.../src/main/java/cn/ibizlab/core/ou/domain/IBZEmployee.java
+44
-52
IBZOrganization.java
.../main/java/cn/ibizlab/core/ou/domain/IBZOrganization.java
+19
-27
IBZDepartmentSearchContext.java
...cn/ibizlab/core/ou/filter/IBZDepartmentSearchContext.java
+13
-72
IBZDeptMemberSearchContext.java
...cn/ibizlab/core/ou/filter/IBZDeptMemberSearchContext.java
+9
-53
IBZEmployeeSearchContext.java
...a/cn/ibizlab/core/ou/filter/IBZEmployeeSearchContext.java
+12
-66
IBZOrganizationSearchContext.java
.../ibizlab/core/ou/filter/IBZOrganizationSearchContext.java
+13
-72
IIBZDepartmentService.java
...ava/cn/ibizlab/core/ou/service/IIBZDepartmentService.java
+2
-20
IIBZDeptMemberService.java
...ava/cn/ibizlab/core/ou/service/IIBZDeptMemberService.java
+2
-18
IIBZEmployeeService.java
.../java/cn/ibizlab/core/ou/service/IIBZEmployeeService.java
+2
-20
IIBZOrganizationService.java
...a/cn/ibizlab/core/ou/service/IIBZOrganizationService.java
+2
-20
IBZDepartmentServiceImpl.java
...bizlab/core/ou/service/impl/IBZDepartmentServiceImpl.java
+55
-152
IBZDeptMemberServiceImpl.java
...bizlab/core/ou/service/impl/IBZDeptMemberServiceImpl.java
+53
-126
IBZEmployeeServiceImpl.java
.../ibizlab/core/ou/service/impl/IBZEmployeeServiceImpl.java
+53
-154
IBZOrganizationServiceImpl.java
...zlab/core/ou/service/impl/IBZOrganizationServiceImpl.java
+47
-143
SysAuthLogFallback.java
...n/java/cn/ibizlab/core/uaa/client/SysAuthLogFallback.java
+76
-0
SysAuthLogFeignClient.java
...ava/cn/ibizlab/core/uaa/client/SysAuthLogFeignClient.java
+71
-0
SysPSSystemFallback.java
.../java/cn/ibizlab/core/uaa/client/SysPSSystemFallback.java
+76
-0
SysPSSystemFeignClient.java
...va/cn/ibizlab/core/uaa/client/SysPSSystemFeignClient.java
+71
-0
SysPermissionFallback.java
...ava/cn/ibizlab/core/uaa/client/SysPermissionFallback.java
+76
-0
SysPermissionFeignClient.java
.../cn/ibizlab/core/uaa/client/SysPermissionFeignClient.java
+71
-0
SysRoleFallback.java
...main/java/cn/ibizlab/core/uaa/client/SysRoleFallback.java
+76
-0
SysRoleFeignClient.java
...n/java/cn/ibizlab/core/uaa/client/SysRoleFeignClient.java
+71
-0
SysRolePermissionFallback.java
...cn/ibizlab/core/uaa/client/SysRolePermissionFallback.java
+76
-0
SysRolePermissionFeignClient.java
...ibizlab/core/uaa/client/SysRolePermissionFeignClient.java
+71
-0
SysUserFallback.java
...main/java/cn/ibizlab/core/uaa/client/SysUserFallback.java
+76
-0
SysUserFeignClient.java
...n/java/cn/ibizlab/core/uaa/client/SysUserFeignClient.java
+71
-0
SysUserRoleFallback.java
.../java/cn/ibizlab/core/uaa/client/SysUserRoleFallback.java
+76
-0
SysUserRoleFeignClient.java
...va/cn/ibizlab/core/uaa/client/SysUserRoleFeignClient.java
+71
-0
SysAuthLog.java
.../src/main/java/cn/ibizlab/core/uaa/domain/SysAuthLog.java
+13
-18
SysPSSystem.java
...src/main/java/cn/ibizlab/core/uaa/domain/SysPSSystem.java
+7
-12
SysPermission.java
...c/main/java/cn/ibizlab/core/uaa/domain/SysPermission.java
+11
-17
SysRole.java
...ore/src/main/java/cn/ibizlab/core/uaa/domain/SysRole.java
+9
-14
SysRolePermission.java
...in/java/cn/ibizlab/core/uaa/domain/SysRolePermission.java
+17
-40
SysUser.java
...ore/src/main/java/cn/ibizlab/core/uaa/domain/SysUser.java
+8
-13
SysUserRole.java
...src/main/java/cn/ibizlab/core/uaa/domain/SysUserRole.java
+15
-38
SysAuthLogSearchContext.java
...a/cn/ibizlab/core/uaa/filter/SysAuthLogSearchContext.java
+11
-60
SysPSSystemSearchContext.java
.../cn/ibizlab/core/uaa/filter/SysPSSystemSearchContext.java
+5
-24
SysPermissionSearchContext.java
...n/ibizlab/core/uaa/filter/SysPermissionSearchContext.java
+7
-41
SysRolePermissionSearchContext.java
...izlab/core/uaa/filter/SysRolePermissionSearchContext.java
+9
-53
SysRoleSearchContext.java
...java/cn/ibizlab/core/uaa/filter/SysRoleSearchContext.java
+6
-39
SysUserRoleSearchContext.java
.../cn/ibizlab/core/uaa/filter/SysUserRoleSearchContext.java
+7
-41
SysUserSearchContext.java
...java/cn/ibizlab/core/uaa/filter/SysUserSearchContext.java
+6
-30
ISysAuthLogService.java
.../java/cn/ibizlab/core/uaa/service/ISysAuthLogService.java
+2
-18
ISysPSSystemService.java
...java/cn/ibizlab/core/uaa/service/ISysPSSystemService.java
+2
-18
ISysPermissionService.java
...va/cn/ibizlab/core/uaa/service/ISysPermissionService.java
+2
-18
ISysRolePermissionService.java
...n/ibizlab/core/uaa/service/ISysRolePermissionService.java
+2
-18
ISysRoleService.java
...ain/java/cn/ibizlab/core/uaa/service/ISysRoleService.java
+2
-18
ISysUserRoleService.java
...java/cn/ibizlab/core/uaa/service/ISysUserRoleService.java
+2
-18
ISysUserService.java
...ain/java/cn/ibizlab/core/uaa/service/ISysUserService.java
+2
-18
SysAuthLogServiceImpl.java
.../ibizlab/core/uaa/service/impl/SysAuthLogServiceImpl.java
+34
-84
SysPSSystemServiceImpl.java
...ibizlab/core/uaa/service/impl/SysPSSystemServiceImpl.java
+33
-83
SysPermissionServiceImpl.java
...izlab/core/uaa/service/impl/SysPermissionServiceImpl.java
+33
-86
SysRolePermissionServiceImpl.java
...b/core/uaa/service/impl/SysRolePermissionServiceImpl.java
+53
-128
SysRoleServiceImpl.java
.../cn/ibizlab/core/uaa/service/impl/SysRoleServiceImpl.java
+32
-88
SysUserRoleServiceImpl.java
...ibizlab/core/uaa/service/impl/SysUserRoleServiceImpl.java
+53
-126
SysUserServiceImpl.java
.../cn/ibizlab/core/uaa/service/impl/SysUserServiceImpl.java
+33
-86
h2_table.xml
ibzrt-core/src/main/resources/liquibase/h2_table.xml
+3
-442
IBZEmployeesaveDeptMemberRuleFlow.bpmn
...in/resources/rules/IBZEmployeesaveDeptMemberRuleFlow.bpmn
+2
-2
IBZDepartmentResource.java
.../main/java/cn/ibizlab/api/rest/IBZDepartmentResource.java
+4
-17
IBZDeptMemberResource.java
.../main/java/cn/ibizlab/api/rest/IBZDeptMemberResource.java
+4
-15
IBZEmployeeResource.java
...rc/main/java/cn/ibizlab/api/rest/IBZEmployeeResource.java
+5
-17
IBZOrganizationResource.java
...ain/java/cn/ibizlab/api/rest/IBZOrganizationResource.java
+4
-19
SysRolePermissionResource.java
...n/java/cn/ibizlab/api/rest/SysRolePermissionResource.java
+4
-15
SysRoleResource.java
...pi/src/main/java/cn/ibizlab/api/rest/SysRoleResource.java
+4
-15
SysUserResource.java
...pi/src/main/java/cn/ibizlab/api/rest/SysUserResource.java
+4
-15
SysUserRoleResource.java
...rc/main/java/cn/ibizlab/api/rest/SysUserRoleResource.java
+4
-15
未找到文件。
app_Web/src/pages/rt/index/router.ts
浏览文件 @
71ffc6c5
...
...
@@ -535,466 +535,6 @@ const router = new Router({
...
indexRoutes
,
],
},
{
path
:
'/ibzdepartments/:ibzdepartment?/pickupview/:pickupview?'
,
meta
:
{
caption
:
'entities.ibzdepartment.views.pickupview.caption'
,
parameters
:
[
{
pathName
:
'ibzdepartments'
,
parameterName
:
'ibzdepartment'
},
{
pathName
:
'pickupview'
,
parameterName
:
'pickupview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzdepartment-pickup-view/ibzdepartment-pickup-view.vue'
),
},
{
path
:
'/ibzemployees/:ibzemployee?/editview/:editview?'
,
meta
:
{
caption
:
'entities.ibzemployee.views.editview.caption'
,
parameters
:
[
{
pathName
:
'ibzemployees'
,
parameterName
:
'ibzemployee'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzemployee-edit-view/ibzemployee-edit-view.vue'
),
},
{
path
:
'/wfusers/:wfuser?/wfmembers/:wfmember?/gridview/:gridview?'
,
meta
:
{
caption
:
'entities.wfmember.views.gridview.caption'
,
parameters
:
[
{
pathName
:
'wfusers'
,
parameterName
:
'wfuser'
},
{
pathName
:
'wfmembers'
,
parameterName
:
'wfmember'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/workflow/wfmember-grid-view/wfmember-grid-view.vue'
),
},
{
path
:
'/wfgroups/:wfgroup?/wfmembers/:wfmember?/gridview/:gridview?'
,
meta
:
{
caption
:
'entities.wfmember.views.gridview.caption'
,
parameters
:
[
{
pathName
:
'wfgroups'
,
parameterName
:
'wfgroup'
},
{
pathName
:
'wfmembers'
,
parameterName
:
'wfmember'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/workflow/wfmember-grid-view/wfmember-grid-view.vue'
),
},
{
path
:
'/wfmembers/:wfmember?/gridview/:gridview?'
,
meta
:
{
caption
:
'entities.wfmember.views.gridview.caption'
,
parameters
:
[
{
pathName
:
'wfmembers'
,
parameterName
:
'wfmember'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/workflow/wfmember-grid-view/wfmember-grid-view.vue'
),
},
{
path
:
'/sysroles/:sysrole?/gridview/:gridview?'
,
meta
:
{
caption
:
'entities.sysrole.views.gridview.caption'
,
parameters
:
[
{
pathName
:
'sysroles'
,
parameterName
:
'sysrole'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/uaa/sys-rolegrid-view/sys-rolegrid-view.vue'
),
},
{
path
:
'/sysroles/:sysrole?/pickupview/:pickupview?'
,
meta
:
{
caption
:
'entities.sysrole.views.pickupview.caption'
,
parameters
:
[
{
pathName
:
'sysroles'
,
parameterName
:
'sysrole'
},
{
pathName
:
'pickupview'
,
parameterName
:
'pickupview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/uaa/sys-role-pickup-view/sys-role-pickup-view.vue'
),
},
{
path
:
'/ibzorganizations/:ibzorganization?/optionview/:optionview?'
,
meta
:
{
caption
:
'entities.ibzorganization.views.optionview.caption'
,
parameters
:
[
{
pathName
:
'ibzorganizations'
,
parameterName
:
'ibzorganization'
},
{
pathName
:
'optionview'
,
parameterName
:
'optionview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzorganization-option-view/ibzorganization-option-view.vue'
),
},
{
path
:
'/sysusers/:sysuser?/pickupview/:pickupview?'
,
meta
:
{
caption
:
'entities.sysuser.views.pickupview.caption'
,
parameters
:
[
{
pathName
:
'sysusers'
,
parameterName
:
'sysuser'
},
{
pathName
:
'pickupview'
,
parameterName
:
'pickupview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/uaa/sys-user-pickup-view/sys-user-pickup-view.vue'
),
},
{
path
:
'/ibzemployees/:ibzemployee?/gridview/:gridview?'
,
meta
:
{
caption
:
'entities.ibzemployee.views.gridview.caption'
,
parameters
:
[
{
pathName
:
'ibzemployees'
,
parameterName
:
'ibzemployee'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzemployee-grid-view/ibzemployee-grid-view.vue'
),
},
{
path
:
'/ibzdeptmembers/:ibzdeptmember?/gridview/:gridview?'
,
meta
:
{
caption
:
'entities.ibzdeptmember.views.gridview.caption'
,
parameters
:
[
{
pathName
:
'ibzdeptmembers'
,
parameterName
:
'ibzdeptmember'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzdept-member-grid-view/ibzdept-member-grid-view.vue'
),
},
{
path
:
'/wfusers/:wfuser?/pickupview/:pickupview?'
,
meta
:
{
caption
:
'entities.wfuser.views.pickupview.caption'
,
parameters
:
[
{
pathName
:
'wfusers'
,
parameterName
:
'wfuser'
},
{
pathName
:
'pickupview'
,
parameterName
:
'pickupview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/workflow/wfuser-pickup-view/wfuser-pickup-view.vue'
),
},
{
path
:
'/ibzorganizations/:ibzorganization?/treeexpview/:treeexpview?'
,
meta
:
{
caption
:
'entities.ibzorganization.views.treeexpview.caption'
,
parameters
:
[
{
pathName
:
'ibzorganizations'
,
parameterName
:
'ibzorganization'
},
{
pathName
:
'treeexpview'
,
parameterName
:
'treeexpview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzorganization-tree-exp-view/ibzorganization-tree-exp-view.vue'
),
},
{
path
:
'/sysuserroles/:sysuserrole?/gridview/:gridview?'
,
meta
:
{
caption
:
'entities.sysuserrole.views.gridview.caption'
,
parameters
:
[
{
pathName
:
'sysuserroles'
,
parameterName
:
'sysuserrole'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/uaa/sys-user-role-grid-view/sys-user-role-grid-view.vue'
),
},
{
path
:
'/sysusers/:sysuser?/pickupgridview/:pickupgridview?'
,
meta
:
{
caption
:
'entities.sysuser.views.pickupgridview.caption'
,
parameters
:
[
{
pathName
:
'sysusers'
,
parameterName
:
'sysuser'
},
{
pathName
:
'pickupgridview'
,
parameterName
:
'pickupgridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/uaa/sys-user-pickup-grid-view/sys-user-pickup-grid-view.vue'
),
},
{
path
:
'/sysroles/:sysrole?/editview/:editview?'
,
meta
:
{
caption
:
'entities.sysrole.views.editview.caption'
,
parameters
:
[
{
pathName
:
'sysroles'
,
parameterName
:
'sysrole'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/uaa/sys-role-edit-view/sys-role-edit-view.vue'
),
},
{
path
:
'/wfusers/:wfuser?/wfmembers/:wfmember?/editview/:editview?'
,
meta
:
{
caption
:
'entities.wfmember.views.editview.caption'
,
parameters
:
[
{
pathName
:
'wfusers'
,
parameterName
:
'wfuser'
},
{
pathName
:
'wfmembers'
,
parameterName
:
'wfmember'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/workflow/wfmember-edit-view/wfmember-edit-view.vue'
),
},
{
path
:
'/wfgroups/:wfgroup?/wfmembers/:wfmember?/editview/:editview?'
,
meta
:
{
caption
:
'entities.wfmember.views.editview.caption'
,
parameters
:
[
{
pathName
:
'wfgroups'
,
parameterName
:
'wfgroup'
},
{
pathName
:
'wfmembers'
,
parameterName
:
'wfmember'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/workflow/wfmember-edit-view/wfmember-edit-view.vue'
),
},
{
path
:
'/wfmembers/:wfmember?/editview/:editview?'
,
meta
:
{
caption
:
'entities.wfmember.views.editview.caption'
,
parameters
:
[
{
pathName
:
'wfmembers'
,
parameterName
:
'wfmember'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/workflow/wfmember-edit-view/wfmember-edit-view.vue'
),
},
{
path
:
'/ibzdepartments/:ibzdepartment?/gridview/:gridview?'
,
meta
:
{
caption
:
'entities.ibzdepartment.views.gridview.caption'
,
parameters
:
[
{
pathName
:
'ibzdepartments'
,
parameterName
:
'ibzdepartment'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzdepartment-grid-view/ibzdepartment-grid-view.vue'
),
},
{
path
:
'/sysroles/:sysrole?/pickupgridview/:pickupgridview?'
,
meta
:
{
caption
:
'entities.sysrole.views.pickupgridview.caption'
,
parameters
:
[
{
pathName
:
'sysroles'
,
parameterName
:
'sysrole'
},
{
pathName
:
'pickupgridview'
,
parameterName
:
'pickupgridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/uaa/sys-role-pickup-grid-view/sys-role-pickup-grid-view.vue'
),
},
{
path
:
'/ibzdepartments/:ibzdepartment?/editview/:editview?'
,
meta
:
{
caption
:
'entities.ibzdepartment.views.editview.caption'
,
parameters
:
[
{
pathName
:
'ibzdepartments'
,
parameterName
:
'ibzdepartment'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzdepartment-edit-view/ibzdepartment-edit-view.vue'
),
},
{
path
:
'/ibzorganizations/:ibzorganization?/editview/:editview?'
,
meta
:
{
caption
:
'entities.ibzorganization.views.editview.caption'
,
parameters
:
[
{
pathName
:
'ibzorganizations'
,
parameterName
:
'ibzorganization'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzorganization-edit-view/ibzorganization-edit-view.vue'
),
},
{
path
:
'/sysrolepermissions/:sysrolepermission?/customview/:customview?'
,
meta
:
{
caption
:
'entities.sysrolepermission.views.customview.caption'
,
parameters
:
[
{
pathName
:
'sysrolepermissions'
,
parameterName
:
'sysrolepermission'
},
{
pathName
:
'customview'
,
parameterName
:
'customview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/uaa/sys-role-permission-custom-view/sys-role-permission-custom-view.vue'
),
},
{
path
:
'/ibzdepartments/:ibzdepartment?/optionview/:optionview?'
,
meta
:
{
caption
:
'entities.ibzdepartment.views.optionview.caption'
,
parameters
:
[
{
pathName
:
'ibzdepartments'
,
parameterName
:
'ibzdepartment'
},
{
pathName
:
'optionview'
,
parameterName
:
'optionview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzdepartment-option-view/ibzdepartment-option-view.vue'
),
},
{
path
:
'/ibzemployees/:ibzemployee?/optionview/:optionview?'
,
meta
:
{
caption
:
'entities.ibzemployee.views.optionview.caption'
,
parameters
:
[
{
pathName
:
'ibzemployees'
,
parameterName
:
'ibzemployee'
},
{
pathName
:
'optionview'
,
parameterName
:
'optionview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzemployee-option-view/ibzemployee-option-view.vue'
),
},
{
path
:
'/ibzemployees/:ibzemployee?/pickupview/:pickupview?'
,
meta
:
{
caption
:
'entities.ibzemployee.views.pickupview.caption'
,
parameters
:
[
{
pathName
:
'ibzemployees'
,
parameterName
:
'ibzemployee'
},
{
pathName
:
'pickupview'
,
parameterName
:
'pickupview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzemployee-pickup-view/ibzemployee-pickup-view.vue'
),
},
{
path
:
'/wfgroups/:wfgroup?/editview/:editview?'
,
meta
:
{
caption
:
'entities.wfgroup.views.editview.caption'
,
parameters
:
[
{
pathName
:
'wfgroups'
,
parameterName
:
'wfgroup'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/workflow/wfgroup-edit-view/wfgroup-edit-view.vue'
),
},
{
path
:
'/ibzdeptmembers/:ibzdeptmember?/editview/:editview?'
,
meta
:
{
caption
:
'entities.ibzdeptmember.views.editview.caption'
,
parameters
:
[
{
pathName
:
'ibzdeptmembers'
,
parameterName
:
'ibzdeptmember'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzdept-member-edit-view/ibzdept-member-edit-view.vue'
),
},
{
path
:
'/ibzdepartments/:ibzdepartment?/treeexpview/:treeexpview?'
,
meta
:
{
caption
:
'entities.ibzdepartment.views.treeexpview.caption'
,
parameters
:
[
{
pathName
:
'ibzdepartments'
,
parameterName
:
'ibzdepartment'
},
{
pathName
:
'treeexpview'
,
parameterName
:
'treeexpview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzdepartment-tree-exp-view/ibzdepartment-tree-exp-view.vue'
),
},
{
path
:
'/ibzorganizations/:ibzorganization?/gridview/:gridview?'
,
meta
:
{
caption
:
'entities.ibzorganization.views.gridview.caption'
,
parameters
:
[
{
pathName
:
'ibzorganizations'
,
parameterName
:
'ibzorganization'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzorganization-grid-view/ibzorganization-grid-view.vue'
),
},
{
path
:
'/ibzemployees/:ibzemployee?/pickupgridview/:pickupgridview?'
,
meta
:
{
caption
:
'entities.ibzemployee.views.pickupgridview.caption'
,
parameters
:
[
{
pathName
:
'ibzemployees'
,
parameterName
:
'ibzemployee'
},
{
pathName
:
'pickupgridview'
,
parameterName
:
'pickupgridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzemployee-pickup-grid-view/ibzemployee-pickup-grid-view.vue'
),
},
{
path
:
'/wfusers/:wfuser?/pickupgridview/:pickupgridview?'
,
meta
:
{
caption
:
'entities.wfuser.views.pickupgridview.caption'
,
parameters
:
[
{
pathName
:
'wfusers'
,
parameterName
:
'wfuser'
},
{
pathName
:
'pickupgridview'
,
parameterName
:
'pickupgridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/workflow/wfuser-pickup-grid-view/wfuser-pickup-grid-view.vue'
),
},
{
path
:
'/ibzorganizations/:ibzorganization?/pickupview/:pickupview?'
,
meta
:
{
caption
:
'entities.ibzorganization.views.pickupview.caption'
,
parameters
:
[
{
pathName
:
'ibzorganizations'
,
parameterName
:
'ibzorganization'
},
{
pathName
:
'pickupview'
,
parameterName
:
'pickupview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzorganization-pickup-view/ibzorganization-pickup-view.vue'
),
},
{
path
:
'/ibzorganizations/:ibzorganization?/pickupgridview/:pickupgridview?'
,
meta
:
{
caption
:
'entities.ibzorganization.views.pickupgridview.caption'
,
parameters
:
[
{
pathName
:
'ibzorganizations'
,
parameterName
:
'ibzorganization'
},
{
pathName
:
'pickupgridview'
,
parameterName
:
'pickupgridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzorganization-pickup-grid-view/ibzorganization-pickup-grid-view.vue'
),
},
{
path
:
'/ibzdepartments/:ibzdepartment?/pickupgridview/:pickupgridview?'
,
meta
:
{
caption
:
'entities.ibzdepartment.views.pickupgridview.caption'
,
parameters
:
[
{
pathName
:
'ibzdepartments'
,
parameterName
:
'ibzdepartment'
},
{
pathName
:
'pickupgridview'
,
parameterName
:
'pickupgridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/ou/ibzdepartment-pickup-grid-view/ibzdepartment-pickup-grid-view.vue'
),
},
{
path
:
'/sysuserroles/:sysuserrole?/editview/:editview?'
,
meta
:
{
caption
:
'entities.sysuserrole.views.editview.caption'
,
parameters
:
[
{
pathName
:
'sysuserroles'
,
parameterName
:
'sysuserrole'
},
{
pathName
:
'editview'
,
parameterName
:
'editview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/uaa/sys-user-role-edit-view/sys-user-role-edit-view.vue'
),
},
{
path
:
'/wfgroups/:wfgroup?/gridview/:gridview?'
,
meta
:
{
caption
:
'entities.wfgroup.views.gridview.caption'
,
parameters
:
[
{
pathName
:
'wfgroups'
,
parameterName
:
'wfgroup'
},
{
pathName
:
'gridview'
,
parameterName
:
'gridview'
},
],
requireAuth
:
true
,
},
component
:
()
=>
import
(
'@pages/workflow/wfgroup-grid-view/wfgroup-grid-view.vue'
),
},
...
globalRoutes
,
{
path
:
'/login/:login?'
,
...
...
app_Web/src/store/modules/view-action/state.ts
浏览文件 @
71ffc6c5
...
...
@@ -3,251 +3,6 @@
*/
export
const
viewstate
:
any
=
{
appviews
:
[
{
viewtag
:
'10dd7f45f36233049c4af9ca417089f5'
,
viewmodule
:
'ou'
,
viewname
:
'IBZDepartmentPickupView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'e3284e895913f7d38d1bcbe898bda0b7'
,
],
},
{
viewtag
:
'119fe650e7efd26bd14bd413cae37ded'
,
viewmodule
:
'ou'
,
viewname
:
'IBZEmployeeEditView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'61541167ccebbc3f174242ce73e436dd'
,
'10dd7f45f36233049c4af9ca417089f5'
,
'ccff36439eacae953f85ff636c9dac74'
,
],
},
{
viewtag
:
'135872676ba63d430b2f20bd20364286'
,
viewmodule
:
'workflow'
,
viewname
:
'WFMemberGridView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'6e1b35989dd6470b5c890369ab87b545'
,
],
},
{
viewtag
:
'13c174556f45e9b10b66dc51834a6ab5'
,
viewmodule
:
'uaa'
,
viewname
:
'SYS_ROLEGridView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'6bd0981f6dd67a59f211b5cf97ac8f30'
,
],
},
{
viewtag
:
'26cc2d5c69f1525eaa415b7de1a0d4a6'
,
viewmodule
:
'uaa'
,
viewname
:
'SysRolePickupView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'7c25865f5864a734477c7cb987632f4f'
,
],
},
{
viewtag
:
'2ed85bebb69b8d23388420b95163228a'
,
viewmodule
:
'ou'
,
viewname
:
'IBZOrganizationOptionView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'ccff36439eacae953f85ff636c9dac74'
,
],
},
{
viewtag
:
'32fe9ab4a9e1b8d62b9ee802e4746965'
,
viewmodule
:
'uaa'
,
viewname
:
'SysUserPickupView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'6869875c7409bd1dddd3d0fc62c502db'
,
],
},
{
viewtag
:
'40fe6b28b9f7902341da46bb74a02d59'
,
viewmodule
:
'ou'
,
viewname
:
'IBZEmployeeGridView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'119fe650e7efd26bd14bd413cae37ded'
,
'9cf7a70099bff83a10f6ae65c4d54692'
,
],
},
{
viewtag
:
'61541167ccebbc3f174242ce73e436dd'
,
viewmodule
:
'ou'
,
viewname
:
'IBZDeptMemberGridView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'bf5e850471bab461fbb6739578e510c5'
,
],
},
{
viewtag
:
'61c5bff70bcf56e1dc0bb0900df9c98c'
,
viewmodule
:
'workflow'
,
viewname
:
'WFUserPickupView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'c9c73c8d2e61bd29a304622f3d39b522'
,
],
},
{
viewtag
:
'6435e95f9bd03acceda6b7fd610873db'
,
viewmodule
:
'ou'
,
viewname
:
'IBZOrganizationTreeExpView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'7362390ee25dac238b23fa9ab05ea4ac'
,
],
},
{
viewtag
:
'6736591aca71edc23df760e278378566'
,
viewmodule
:
'uaa'
,
viewname
:
'SysUserRoleGridView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'edde313015e1db7c366028307d88d20c'
,
],
},
{
viewtag
:
'6869875c7409bd1dddd3d0fc62c502db'
,
viewmodule
:
'uaa'
,
viewname
:
'SysUserPickupGridView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
],
},
{
viewtag
:
'6bd0981f6dd67a59f211b5cf97ac8f30'
,
viewmodule
:
'uaa'
,
viewname
:
'SysRoleEditView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'6736591aca71edc23df760e278378566'
,
'983f3ae1533a5cd62619dedb79bb4b28'
,
],
},
{
viewtag
:
'6e1b35989dd6470b5c890369ab87b545'
,
viewmodule
:
'workflow'
,
viewname
:
'WFMemberEditView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'61c5bff70bcf56e1dc0bb0900df9c98c'
,
],
},
{
viewtag
:
'7362390ee25dac238b23fa9ab05ea4ac'
,
viewmodule
:
'ou'
,
viewname
:
'IBZDepartmentGridView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'90c0ced2720b85d5e051e7935a93d3c5'
,
'9cdad5e2bed51cdcd90b4b7fb3104a5a'
,
],
},
{
viewtag
:
'7c25865f5864a734477c7cb987632f4f'
,
viewmodule
:
'uaa'
,
viewname
:
'SysRolePickupGridView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
],
},
{
viewtag
:
'90c0ced2720b85d5e051e7935a93d3c5'
,
viewmodule
:
'ou'
,
viewname
:
'IBZDepartmentEditView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'10dd7f45f36233049c4af9ca417089f5'
,
'ccff36439eacae953f85ff636c9dac74'
,
],
},
{
viewtag
:
'95e33ff2469ba40d3e0c00f5c3f61501'
,
viewmodule
:
'ou'
,
viewname
:
'IBZOrganizationEditView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'ccff36439eacae953f85ff636c9dac74'
,
],
},
{
viewtag
:
'983f3ae1533a5cd62619dedb79bb4b28'
,
viewmodule
:
'uaa'
,
viewname
:
'SysRolePermissionCustomView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
],
},
{
viewtag
:
'9cdad5e2bed51cdcd90b4b7fb3104a5a'
,
viewmodule
:
'ou'
,
viewname
:
'IBZDepartmentOptionView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'10dd7f45f36233049c4af9ca417089f5'
,
'ccff36439eacae953f85ff636c9dac74'
,
],
},
{
viewtag
:
'9cf7a70099bff83a10f6ae65c4d54692'
,
viewmodule
:
'ou'
,
viewname
:
'IBZEmployeeOptionView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'10dd7f45f36233049c4af9ca417089f5'
,
'ccff36439eacae953f85ff636c9dac74'
,
],
},
{
viewtag
:
'9ffa35efe3d70cf4b9fa4e83dd1979c6'
,
viewmodule
:
'ou'
,
viewname
:
'IBZEmployeePickupView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'c84df2684f29705ac6c5dec67df9f217'
,
],
},
{
viewtag
:
'b23a721ca159ac2490b768d795e85d17'
,
viewmodule
:
'workflow'
,
viewname
:
'WFGroupEditView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'135872676ba63d430b2f20bd20364286'
,
],
},
{
viewtag
:
'b50d665e5fb8a9da01406754e0ab5f15'
,
viewmodule
:
'rt'
,
...
...
@@ -262,107 +17,6 @@ export const viewstate: any = {
'f498dfb24e88df7c70a5c09ecb587647'
,
],
},
{
viewtag
:
'bf5e850471bab461fbb6739578e510c5'
,
viewmodule
:
'ou'
,
viewname
:
'IBZDeptMemberEditView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'9ffa35efe3d70cf4b9fa4e83dd1979c6'
,
'10dd7f45f36233049c4af9ca417089f5'
,
],
},
{
viewtag
:
'c0cdac5d5b5691ae8a326f5972aec67f'
,
viewmodule
:
'ou'
,
viewname
:
'IBZDepartmentTreeExpView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'40fe6b28b9f7902341da46bb74a02d59'
,
],
},
{
viewtag
:
'c42bc30741bd6add20b00494231dfa24'
,
viewmodule
:
'ou'
,
viewname
:
'IBZOrganizationGridView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'2ed85bebb69b8d23388420b95163228a'
,
'95e33ff2469ba40d3e0c00f5c3f61501'
,
'ccff36439eacae953f85ff636c9dac74'
,
],
},
{
viewtag
:
'c84df2684f29705ac6c5dec67df9f217'
,
viewmodule
:
'ou'
,
viewname
:
'IBZEmployeePickupGridView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
],
},
{
viewtag
:
'c9c73c8d2e61bd29a304622f3d39b522'
,
viewmodule
:
'workflow'
,
viewname
:
'WFUserPickupGridView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
],
},
{
viewtag
:
'ccff36439eacae953f85ff636c9dac74'
,
viewmodule
:
'ou'
,
viewname
:
'IBZOrganizationPickupView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'cf8e6d455f8e88e66bbbe1bdb4c84274'
,
],
},
{
viewtag
:
'cf8e6d455f8e88e66bbbe1bdb4c84274'
,
viewmodule
:
'ou'
,
viewname
:
'IBZOrganizationPickupGridView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'ccff36439eacae953f85ff636c9dac74'
,
],
},
{
viewtag
:
'e3284e895913f7d38d1bcbe898bda0b7'
,
viewmodule
:
'ou'
,
viewname
:
'IBZDepartmentPickupGridView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
],
},
{
viewtag
:
'edde313015e1db7c366028307d88d20c'
,
viewmodule
:
'uaa'
,
viewname
:
'SysUserRoleEditView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'26cc2d5c69f1525eaa415b7de1a0d4a6'
,
'32fe9ab4a9e1b8d62b9ee802e4746965'
,
],
},
{
viewtag
:
'f498dfb24e88df7c70a5c09ecb587647'
,
viewmodule
:
'workflow'
,
viewname
:
'WFGroupGridView'
,
viewaction
:
''
,
viewdatachange
:
false
,
refviews
:
[
'b23a721ca159ac2490b768d795e85d17'
,
],
},
],
createdviews
:
[],
}
\ No newline at end of file
config.xml
浏览文件 @
71ffc6c5
...
...
@@ -37,11 +37,6 @@
git clone -b master $para2 ibzrt/
export NODE_OPTIONS=--max-old-space-size=4096
cd ibzrt/
mvn clean package -Pweb
cd ibzrt-app/ibzrt-app-web
mvn -Pweb docker:build
mvn -Pweb docker:push
docker -H $para1 stack deploy --compose-file=src/main/docker/ibzrt-app-web.yaml ibzlab-rt --with-registry-auth
</command>
</hudson.tasks.Shell>
</builders>
...
...
ibzrt-app/ibzrt-app-web/src/main/docker/Dockerfile
浏览文件 @
71ffc6c5
...
...
@@ -9,6 +9,6 @@ CMD echo "The application will start in ${IBZ_SLEEP}s..." && \
sleep ${IBZ_SLEEP} && \
java ${JAVA_OPTS} -Djava.security.egd=file:/dev/./urandom -jar /ibzrt-app-web.jar
EXPOSE
3000
0
EXPOSE
808
0
ADD
ibzrt-app-web.jar /ibzrt-app-web.jar
ibzrt-app/ibzrt-app-web/src/main/docker/ibzrt-app-web.yaml
浏览文件 @
71ffc6c5
...
...
@@ -3,21 +3,9 @@ services:
ibzrt-app-web
:
image
:
registry.cn-shanghai.aliyuncs.com/ibizsys/ibzrt-app-web:latest
ports
:
-
"
30000:3000
0"
-
"
8080:808
0"
networks
:
-
agent_network
environment
:
-
SPRING_CLOUD_NACOS_DISCOVERY_IP=172.16.180.237
-
SERVER_PORT=30000
-
SPRING_CLOUD_NACOS_DISCOVERY_SERVER-ADDR=172.16.102.211:8848
-
SPRING_REDIS_HOST=172.16.100.243
-
SPRING_REDIS_PORT=6379
-
SPRING_REDIS_DATABASE=0
-
SPRING_DATASOURCE_USERNAME=a_A_5d9d78509
-
SPRING_DATASOURCE_PASSWORD=@6dEfb3@
-
SPRING_DATASOURCE_URL=jdbc:mysql://172.16.180.232:3306/a_A_5d9d78509?autoReconnect=true&useUnicode=true&characterEncoding=UTF-8&useOldAliasMetadataBehavior=true
-
SPRING_DATASOURCE_DRIVER-CLASS-NAME=com.mysql.jdbc.Driver
-
SPRING_DATASOURCE_DEFAULTSCHEMA=a_A_5d9d78509
deploy
:
mode
:
replicated
replicas
:
1
...
...
ibzrt-app/ibzrt-app-web/src/main/resources/application-web-prod.yml
浏览文件 @
71ffc6c5
...
...
@@ -5,11 +5,11 @@ zuul:
routes
:
sys_role_permission
:
path
:
/sysrolepermissions/**
serviceId
:
ibz
rt
-api
serviceId
:
ibz
uaa
-api
stripPrefix
:
false
sys_user
:
path
:
/sysusers/**
serviceId
:
ibz
rt
-api
serviceId
:
ibz
uaa
-api
stripPrefix
:
false
wf_group_member
:
path
:
/wfmembers/**
...
...
@@ -21,7 +21,7 @@ zuul:
stripPrefix
:
false
ibzorg
:
path
:
/ibzorganizations/**
serviceId
:
ibz
rt
-api
serviceId
:
ibz
ou
-api
stripPrefix
:
false
wf_group
:
path
:
/wfgroups/**
...
...
@@ -29,23 +29,23 @@ zuul:
stripPrefix
:
false
sys_user_role
:
path
:
/sysuserroles/**
serviceId
:
ibz
rt
-api
serviceId
:
ibz
uaa
-api
stripPrefix
:
false
sys_role
:
path
:
/sysroles/**
serviceId
:
ibz
rt
-api
serviceId
:
ibz
uaa
-api
stripPrefix
:
false
ibzdeptmember
:
path
:
/ibzdeptmembers/**
serviceId
:
ibz
rt
-api
serviceId
:
ibz
ou
-api
stripPrefix
:
false
ibzdept
:
path
:
/ibzdepartments/**
serviceId
:
ibz
rt
-api
serviceId
:
ibz
ou
-api
stripPrefix
:
false
ibzemp
:
path
:
/ibzemployees/**
serviceId
:
ibz
rt
-api
serviceId
:
ibz
ou
-api
stripPrefix
:
false
loginv7
:
path
:
/v7/login
...
...
ibzrt-boot/src/main/resources/application-dev.yml
浏览文件 @
71ffc6c5
...
...
@@ -4,6 +4,14 @@ server:
#zuul网关路由设置
zuul
:
routes
:
wf_pssystem
:
path
:
/wf_pssystems/**
serviceId
:
ibzwf-api
stripPrefix
:
false
ibzorg
:
path
:
/ibzorgs/**
serviceId
:
ibzou-api
stripPrefix
:
false
wf_instance
:
path
:
/wf_instances/**
serviceId
:
ibzwf-api
...
...
@@ -12,30 +20,74 @@ zuul:
path
:
/wf_models/**
serviceId
:
ibzwf-api
stripPrefix
:
false
wf_group_member
:
path
:
/wf_group_members/**
ibzdictitem
:
path
:
/ibzdictitems/**
serviceId
:
ibzdict-api
stripPrefix
:
false
wf_task_way
:
path
:
/wf_task_ways/**
serviceId
:
ibzwf-api
stripPrefix
:
false
wf_task
:
path
:
/wf_tasks/**
serviceId
:
ibzwf-api
stripPrefix
:
false
wf_group_member
:
path
:
/wf_group_members/**
serviceId
:
ibzwf-api
stripPrefix
:
false
sys_authlog
:
path
:
/sys_authlogs/**
serviceId
:
ibzuaa-api
stripPrefix
:
false
wf_definition_node
:
path
:
/wf_definition_nodes/**
serviceId
:
ibzwf-api
stripPrefix
:
false
wf_pssystem
:
path
:
/
wf_pssystem
s/**
serviceId
:
ibz
wf
-api
sys_role_permission
:
path
:
/
sys_role_permission
s/**
serviceId
:
ibz
uaa
-api
stripPrefix
:
false
wf_task_way
:
path
:
/wf_task_ways/**
serviceId
:
ibzwf-api
sys_user
:
path
:
/sys_users/**
serviceId
:
ibzuaa-api
stripPrefix
:
false
ibzdict
:
path
:
/ibzdicts/**
serviceId
:
ibzdict-api
stripPrefix
:
false
ibzemp
:
path
:
/ibzemps/**
serviceId
:
ibzou-api
stripPrefix
:
false
sys_user_role
:
path
:
/sys_user_roles/**
serviceId
:
ibzuaa-api
stripPrefix
:
false
wf_definition
:
path
:
/wf_definitions/**
serviceId
:
ibzwf-api
stripPrefix
:
false
sys_role
:
path
:
/sys_roles/**
serviceId
:
ibzuaa-api
stripPrefix
:
false
ibzdeptmember
:
path
:
/ibzdeptmembers/**
serviceId
:
ibzou-api
stripPrefix
:
false
sys_pssystem
:
path
:
/sys_pssystems/**
serviceId
:
ibzuaa-api
stripPrefix
:
false
sys_permission
:
path
:
/sys_permissions/**
serviceId
:
ibzuaa-api
stripPrefix
:
false
ibzdept
:
path
:
/ibzdepts/**
serviceId
:
ibzou-api
stripPrefix
:
false
loginv7
:
path
:
/v7/login
serviceId
:
ibzuaa-api
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/dict/client/IBZDictFallback.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
dict
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.dict.domain.IBZDict
;
import
cn.ibizlab.core.dict.filter.IBZDictSearchContext
;
import
org.springframework.stereotype.Component
;
/**
* 实体[IBZDict] 服务对象接口
*/
@Component
public
class
IBZDictFallback
implements
IBZDictFeignClient
{
public
Page
<
IBZDict
>
select
(){
return
null
;
}
public
IBZDict
create
(
IBZDict
ibzdict
){
return
null
;
}
public
Boolean
createBatch
(
List
<
IBZDict
>
ibzdicts
){
return
false
;
}
public
Boolean
remove
(
String
dictid
){
return
false
;
}
public
Boolean
removeBatch
(
Collection
<
String
>
idList
){
return
false
;
}
public
IBZDict
update
(
String
dictid
,
IBZDict
ibzdict
){
return
null
;
}
public
Boolean
updateBatch
(
List
<
IBZDict
>
ibzdicts
){
return
false
;
}
public
IBZDict
getDraft
(){
return
null
;
}
public
Boolean
save
(
IBZDict
ibzdict
){
return
false
;
}
public
Boolean
saveBatch
(
List
<
IBZDict
>
ibzdicts
){
return
false
;
}
public
IBZDict
get
(
String
dictid
){
return
null
;
}
public
Boolean
checkKey
(
IBZDict
ibzdict
){
return
false
;
}
public
Page
<
IBZDict
>
searchDefault
(
IBZDictSearchContext
context
){
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/dict/client/IBZDictFeignClient.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
dict
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.dict.domain.IBZDict
;
import
cn.ibizlab.core.dict.filter.IBZDictSearchContext
;
import
org.springframework.cloud.openfeign.FeignClient
;
/**
* 实体[IBZDict] 服务对象接口
*/
@FeignClient
(
value
=
"ibzdict-api"
,
contextId
=
"IBZDict"
,
fallback
=
IBZDictFallback
.
class
)
public
interface
IBZDictFeignClient
{
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdicts/select"
)
Page
<
IBZDict
>
select
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdicts"
)
IBZDict
create
(
@RequestBody
IBZDict
ibzdict
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdicts/batch"
)
Boolean
createBatch
(
@RequestBody
List
<
IBZDict
>
ibzdicts
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdicts/{dictid}"
)
Boolean
remove
(
@PathVariable
(
"dictid"
)
String
dictid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdicts/batch}"
)
Boolean
removeBatch
(
@RequestBody
Collection
<
String
>
idList
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdicts/{dictid}"
)
IBZDict
update
(
@PathVariable
(
"dictid"
)
String
dictid
,
@RequestBody
IBZDict
ibzdict
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdicts/batch"
)
Boolean
updateBatch
(
@RequestBody
List
<
IBZDict
>
ibzdicts
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdicts/getdraft"
)
IBZDict
getDraft
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdicts/save"
)
Boolean
save
(
@RequestBody
IBZDict
ibzdict
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdicts/save"
)
Boolean
saveBatch
(
@RequestBody
List
<
IBZDict
>
ibzdicts
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdicts/{dictid}"
)
IBZDict
get
(
@PathVariable
(
"dictid"
)
String
dictid
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdicts/checkkey"
)
Boolean
checkKey
(
@RequestBody
IBZDict
ibzdict
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdicts/searchdefault"
)
Page
<
IBZDict
>
searchDefault
(
@RequestBody
IBZDictSearchContext
context
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/dict/client/IBZDictItemFallback.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
dict
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.dict.domain.IBZDictItem
;
import
cn.ibizlab.core.dict.filter.IBZDictItemSearchContext
;
import
org.springframework.stereotype.Component
;
/**
* 实体[IBZDictItem] 服务对象接口
*/
@Component
public
class
IBZDictItemFallback
implements
IBZDictItemFeignClient
{
public
Page
<
IBZDictItem
>
select
(){
return
null
;
}
public
IBZDictItem
update
(
String
itemid
,
IBZDictItem
ibzdictitem
){
return
null
;
}
public
Boolean
updateBatch
(
List
<
IBZDictItem
>
ibzdictitems
){
return
false
;
}
public
Boolean
checkKey
(
IBZDictItem
ibzdictitem
){
return
false
;
}
public
Boolean
save
(
IBZDictItem
ibzdictitem
){
return
false
;
}
public
Boolean
saveBatch
(
List
<
IBZDictItem
>
ibzdictitems
){
return
false
;
}
public
Boolean
remove
(
String
itemid
){
return
false
;
}
public
Boolean
removeBatch
(
Collection
<
String
>
idList
){
return
false
;
}
public
IBZDictItem
get
(
String
itemid
){
return
null
;
}
public
IBZDictItem
create
(
IBZDictItem
ibzdictitem
){
return
null
;
}
public
Boolean
createBatch
(
List
<
IBZDictItem
>
ibzdictitems
){
return
false
;
}
public
IBZDictItem
getDraft
(){
return
null
;
}
public
Page
<
IBZDictItem
>
searchDefault
(
IBZDictItemSearchContext
context
){
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/dict/client/IBZDictItemFeignClient.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
dict
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.dict.domain.IBZDictItem
;
import
cn.ibizlab.core.dict.filter.IBZDictItemSearchContext
;
import
org.springframework.cloud.openfeign.FeignClient
;
/**
* 实体[IBZDictItem] 服务对象接口
*/
@FeignClient
(
value
=
"ibzdict-api"
,
contextId
=
"IBZDictItem"
,
fallback
=
IBZDictItemFallback
.
class
)
public
interface
IBZDictItemFeignClient
{
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdictitems/select"
)
Page
<
IBZDictItem
>
select
();
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdictitems/{itemid}"
)
IBZDictItem
update
(
@PathVariable
(
"itemid"
)
String
itemid
,
@RequestBody
IBZDictItem
ibzdictitem
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdictitems/batch"
)
Boolean
updateBatch
(
@RequestBody
List
<
IBZDictItem
>
ibzdictitems
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdictitems/checkkey"
)
Boolean
checkKey
(
@RequestBody
IBZDictItem
ibzdictitem
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdictitems/save"
)
Boolean
save
(
@RequestBody
IBZDictItem
ibzdictitem
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdictitems/save"
)
Boolean
saveBatch
(
@RequestBody
List
<
IBZDictItem
>
ibzdictitems
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdictitems/{itemid}"
)
Boolean
remove
(
@PathVariable
(
"itemid"
)
String
itemid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdictitems/batch}"
)
Boolean
removeBatch
(
@RequestBody
Collection
<
String
>
idList
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdictitems/{itemid}"
)
IBZDictItem
get
(
@PathVariable
(
"itemid"
)
String
itemid
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdictitems"
)
IBZDictItem
create
(
@RequestBody
IBZDictItem
ibzdictitem
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdictitems/batch"
)
Boolean
createBatch
(
@RequestBody
List
<
IBZDictItem
>
ibzdictitems
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdictitems/getdraft"
)
IBZDictItem
getDraft
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdictitems/searchdefault"
)
Page
<
IBZDictItem
>
searchDefault
(
@RequestBody
IBZDictItemSearchContext
context
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/dict/domain/IBZDict.java
浏览文件 @
71ffc6c5
...
...
@@ -21,90 +21,83 @@ import java.io.Serializable;
import
lombok.Data
;
import
org.springframework.data.annotation.Transient
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.util.domain.EntityMP
;
import
cn.ibizlab.util.domain.EntityClient
;
/**
*
实体[数据字典]
*
ServiceApi [数据字典] 对象
*/
@Data
@TableName
(
value
=
"IBZDICT"
,
resultMap
=
"IBZDictResultMap"
)
public
class
IBZDict
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
public
class
IBZDict
extends
EntityClient
implements
Serializable
{
/**
* 字典标识
*/
@DEField
(
name
=
"ibzdictid"
,
isKeyField
=
true
)
@TableId
(
value
=
"ibzdictid"
,
type
=
IdType
.
UUID
)
@JSONField
(
name
=
"dictid"
)
@JsonProperty
(
"dictid"
)
private
String
dictid
;
/**
* 字典名称
*/
@DEField
(
name
=
"ibzdictname"
)
@TableField
(
value
=
"ibzdictname"
)
@JSONField
(
name
=
"dictname"
)
@JsonProperty
(
"dictname"
)
private
String
dictname
;
/**
* 逻辑有效标志
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
LOGICVALID
,
logicval
=
"1"
,
logicdelval
=
"0"
)
@TableLogic
(
value
=
"1"
,
delval
=
"0"
)
@TableField
(
value
=
"enable"
)
@JSONField
(
name
=
"enable"
)
@JsonProperty
(
"enable"
)
private
Integer
enable
;
/**
* 建立时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@TableField
(
value
=
"createdate"
,
fill
=
FieldFill
.
INSERT
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"createdate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"createdate"
)
private
Timestamp
createdate
;
/**
* 更新时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEDATE
)
@TableField
(
value
=
"updatedate"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"updatedate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"updatedate"
)
private
Timestamp
updatedate
;
/**
* 建立人
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEMAN
)
@TableField
(
value
=
"createman"
,
fill
=
FieldFill
.
INSERT
)
@JSONField
(
name
=
"createman"
)
@JsonProperty
(
"createman"
)
private
String
createman
;
/**
* 更新人
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEMAN
)
@TableField
(
value
=
"updateman"
)
@JSONField
(
name
=
"updateman"
)
@JsonProperty
(
"updateman"
)
private
String
updateman
;
/**
* 字典项目
*/
@JsonIgnore
@JSONField
(
serialize
=
false
)
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"items"
)
@JsonProperty
(
"items"
)
private
List
<
cn
.
ibizlab
.
core
.
dict
.
domain
.
IBZDictItem
>
items
;
/**
* 设置 [字典名称]
*/
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/dict/domain/IBZDictItem.java
浏览文件 @
71ffc6c5
...
...
@@ -21,133 +21,127 @@ import java.io.Serializable;
import
lombok.Data
;
import
org.springframework.data.annotation.Transient
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.util.domain.EntityMP
;
import
cn.ibizlab.util.domain.EntityClient
;
/**
*
实体[字典项目]
*
ServiceApi [字典项目] 对象
*/
@Data
@TableName
(
value
=
"IBZDICTITEM"
,
resultMap
=
"IBZDictItemResultMap"
)
public
class
IBZDictItem
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
public
class
IBZDictItem
extends
EntityClient
implements
Serializable
{
/**
* 字典项目标识
*/
@DEField
(
name
=
"ibzdictitemid"
,
isKeyField
=
true
)
@TableId
(
value
=
"ibzdictitemid"
,
type
=
IdType
.
UUID
)
@JSONField
(
name
=
"itemid"
)
@JsonProperty
(
"itemid"
)
private
String
itemid
;
/**
* 栏目显示值
*/
@DEField
(
name
=
"ibzdictitemname"
)
@TableField
(
value
=
"ibzdictitemname"
)
@JSONField
(
name
=
"itemname"
)
@JsonProperty
(
"itemname"
)
private
String
itemname
;
/**
* 栏目值
*/
@DEField
(
name
=
"dictitemval"
)
@TableField
(
value
=
"dictitemval"
)
@JSONField
(
name
=
"itemval"
)
@JsonProperty
(
"itemval"
)
private
String
itemval
;
/**
* 字典标识
*/
@TableField
(
value
=
"dictid"
)
@JSONField
(
name
=
"dictid"
)
@JsonProperty
(
"dictid"
)
private
String
dictid
;
/**
* 父栏目值
*/
@TableField
(
value
=
"pitemval"
)
@JSONField
(
name
=
"pitemval"
)
@JsonProperty
(
"pitemval"
)
private
String
pitemval
;
/**
* 过滤项
*/
@TableField
(
value
=
"itemfilter"
)
@JSONField
(
name
=
"itemfilter"
)
@JsonProperty
(
"itemfilter"
)
private
String
itemfilter
;
/**
* 栏目样式
*/
@DEField
(
defaultValue
=
"itemcls"
,
defaultValueType
=
DEFieldDefaultValueType
.
PARAM
)
@TableField
(
value
=
"itemcls"
)
@JSONField
(
name
=
"itemcls"
)
@JsonProperty
(
"itemcls"
)
private
String
itemcls
;
/**
* 图标
*/
@DEField
(
defaultValue
=
"no,png"
)
@TableField
(
value
=
"itemicon"
)
@JSONField
(
name
=
"itemicon"
)
@JsonProperty
(
"itemicon"
)
private
String
itemicon
;
/**
* 排序
*/
@TableField
(
value
=
"showorder"
)
@JSONField
(
name
=
"showorder"
)
@JsonProperty
(
"showorder"
)
private
Integer
showorder
;
/**
* 建立时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@TableField
(
value
=
"createdate"
,
fill
=
FieldFill
.
INSERT
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"createdate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"createdate"
)
private
Timestamp
createdate
;
/**
* 更新时间
*/
@DEField
(
defaultValueType
=
DEFieldDefaultValueType
.
CURTIME
,
preType
=
DEPredefinedFieldType
.
UPDATEDATE
)
@TableField
(
value
=
"updatedate"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"updatedate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"updatedate"
)
private
Timestamp
updatedate
;
/**
* 更新人
*/
@DEField
(
defaultValue
=
"SRFPERSONID"
,
defaultValueType
=
DEFieldDefaultValueType
.
SESSION
,
preType
=
DEPredefinedFieldType
.
UPDATEMAN
)
@TableField
(
value
=
"updateman"
)
@JSONField
(
name
=
"updateman"
)
@JsonProperty
(
"updateman"
)
private
String
updateman
;
/**
* 建立人
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEMAN
)
@TableField
(
value
=
"createman"
,
fill
=
FieldFill
.
INSERT
)
@JSONField
(
name
=
"createman"
)
@JsonProperty
(
"createman"
)
private
String
createman
;
/**
* 字典
*/
@JsonIgnore
@JSONField
(
serialize
=
false
)
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"dict"
)
@JsonProperty
(
"dict"
)
private
cn
.
ibizlab
.
core
.
dict
.
domain
.
IBZDict
dict
;
/**
* 设置 [栏目显示值]
*/
...
...
@@ -205,22 +199,6 @@ public class IBZDictItem extends EntityMP implements Serializable {
this
.
modify
(
"showorder"
,
showorder
);
}
/**
* 获取 [字典项目标识]
*/
public
String
getItemid
(){
if
(
ObjectUtils
.
isEmpty
(
itemid
)){
itemid
=(
String
)
getDefaultKey
(
true
);
}
return
itemid
;
}
@Override
public
Serializable
getDefaultKey
(
boolean
gen
)
{
if
((!
ObjectUtils
.
isEmpty
(
this
.
getDictid
()))&&(!
ObjectUtils
.
isEmpty
(
this
.
getItemval
())))
return
DigestUtils
.
md5DigestAsHex
(
String
.
format
(
"%s||%s"
,
this
.
getDictid
(),
this
.
getItemval
()).
getBytes
());
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/dict/filter/IBZDictItemSearchContext.java
浏览文件 @
71ffc6c5
...
...
@@ -17,50 +17,21 @@ import org.springframework.util.ObjectUtils;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.core.dict.domain.IBZDictItem
;
import
cn.ibizlab.util.filter.SearchContextBase
;
/**
*
关系型
数据实体[IBZDictItem] 查询条件对象
*
ServiceApi
数据实体[IBZDictItem] 查询条件对象
*/
@Slf4j
@Data
public
class
IBZDictItemSearchContext
extends
QueryWrapperContext
<
IBZDictItem
>
{
public
class
IBZDictItemSearchContext
extends
SearchContextBase
{
private
String
n_ibzdictitemname_like
;
//[栏目显示值]
public
void
setN_ibzdictitemname_like
(
String
n_ibzdictitemname_like
)
{
this
.
n_ibzdictitemname_like
=
n_ibzdictitemname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_ibzdictitemname_like
)){
this
.
getSelectCond
().
like
(
"ibzdictitemname"
,
n_ibzdictitemname_like
);
}
}
private
String
n_dictitemval_like
;
//[栏目值]
public
void
setN_dictitemval_like
(
String
n_dictitemval_like
)
{
this
.
n_dictitemval_like
=
n_dictitemval_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_dictitemval_like
)){
this
.
getSelectCond
().
like
(
"dictitemval"
,
n_dictitemval_like
);
}
}
private
String
n_dictid_eq
;
//[字典标识]
public
void
setN_dictid_eq
(
String
n_dictid_eq
)
{
this
.
n_dictid_eq
=
n_dictid_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_dictid_eq
)){
this
.
getSelectCond
().
eq
(
"dictid"
,
n_dictid_eq
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSelectCond
().
or
().
like
(
"ibzdictitemname"
,
query
);
}
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/dict/filter/IBZDictSearchContext.java
浏览文件 @
71ffc6c5
...
...
@@ -17,43 +17,19 @@ import org.springframework.util.ObjectUtils;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.core.dict.domain.IBZDict
;
import
cn.ibizlab.util.filter.SearchContextBase
;
/**
*
关系型
数据实体[IBZDict] 查询条件对象
*
ServiceApi
数据实体[IBZDict] 查询条件对象
*/
@Slf4j
@Data
public
class
IBZDictSearchContext
extends
QueryWrapperContext
<
IBZDict
>
{
public
class
IBZDictSearchContext
extends
SearchContextBase
{
private
String
n_ibzdictid_like
;
//[字典标识]
public
void
setN_ibzdictid_like
(
String
n_ibzdictid_like
)
{
this
.
n_ibzdictid_like
=
n_ibzdictid_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_ibzdictid_like
)){
this
.
getSelectCond
().
like
(
"ibzdictid"
,
n_ibzdictid_like
);
}
}
private
String
n_ibzdictname_like
;
//[字典名称]
public
void
setN_ibzdictname_like
(
String
n_ibzdictname_like
)
{
this
.
n_ibzdictname_like
=
n_ibzdictname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_ibzdictname_like
)){
this
.
getSelectCond
().
like
(
"ibzdictname"
,
n_ibzdictname_like
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSelectCond
().
or
().
like
(
"ibzdictname"
,
query
);
}
}
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/dict/service/IIBZDictItemService.java
浏览文件 @
71ffc6c5
...
...
@@ -18,12 +18,10 @@ import cn.ibizlab.core.dict.domain.IBZDictItem;
import
cn.ibizlab.core.dict.filter.IBZDictItemSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[IBZDictItem] 服务对象接口
*/
public
interface
IIBZDictItemService
extends
IService
<
IBZDictItem
>
{
public
interface
IIBZDictItemService
{
boolean
update
(
IBZDictItem
et
)
;
void
updateBatch
(
List
<
IBZDictItem
>
list
)
;
...
...
@@ -40,24 +38,8 @@ public interface IIBZDictItemService extends IService<IBZDictItem>{
List
<
IBZDictItem
>
selectByDictid
(
String
dictid
)
;
void
removeByDictid
(
String
dictid
)
;
void
saveByDictid
(
String
dictid
,
List
<
IBZDictItem
>
list
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
List
<
IBZDictItem
>
getIbzdictitemByIds
(
List
<
String
>
ids
)
;
List
<
IBZDictItem
>
getIbzdictitemByEntities
(
List
<
IBZDictItem
>
entities
)
;
}
ibzrt-core/src/main/java/cn/ibizlab/core/dict/service/IIBZDictService.java
浏览文件 @
71ffc6c5
...
...
@@ -18,12 +18,10 @@ import cn.ibizlab.core.dict.domain.IBZDict;
import
cn.ibizlab.core.dict.filter.IBZDictSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[IBZDict] 服务对象接口
*/
public
interface
IIBZDictService
extends
IService
<
IBZDict
>
{
public
interface
IIBZDictService
{
boolean
create
(
IBZDict
et
)
;
void
createBatch
(
List
<
IBZDict
>
list
)
;
...
...
@@ -37,24 +35,8 @@ public interface IIBZDictService extends IService<IBZDict>{
IBZDict
get
(
String
key
)
;
boolean
checkKey
(
IBZDict
et
)
;
Page
<
IBZDict
>
searchDefault
(
IBZDictSearchContext
context
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
List
<
IBZDict
>
getIbzdictByIds
(
List
<
String
>
ids
)
;
List
<
IBZDict
>
getIbzdictByEntities
(
List
<
IBZDict
>
entities
)
;
}
ibzrt-core/src/main/java/cn/ibizlab/core/dict/service/impl/IBZDictItemServiceImpl.java
浏览文件 @
71ffc6c5
...
...
@@ -30,129 +30,110 @@ import cn.ibizlab.core.dict.service.IIBZDictItemService;
import
cn.ibizlab.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.core.dict.mapper.IBZDictItemMapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.core.dict.client.IBZDictItemFeignClient
;
/**
* 实体[字典项目] 服务对象接口实现
*/
@Slf4j
@Service
(
"IBZDictItemServiceImpl"
)
public
class
IBZDictItemServiceImpl
extends
ServiceImpl
<
IBZDictItemMapper
,
IBZDictItem
>
implements
IIBZDictItemService
{
@Service
public
class
IBZDictItemServiceImpl
implements
IIBZDictItemService
{
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
dict
.
service
.
IIBZDictService
ibzdictService
;
IBZDictItemFeignClient
iBZDictItemFeignClient
;
private
int
batchSize
=
500
;
@Override
@Transactional
public
boolean
update
(
IBZDictItem
et
)
{
if
(!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"ibzdictitemid"
,
et
.
getItemid
())))
IBZDictItem
rt
=
iBZDictItemFeignClient
.
update
(
et
.
getItemid
(),
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getItemid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
IBZDictItem
>
list
)
{
updateBatchById
(
list
,
batchSize
);
public
void
updateBatch
(
List
<
IBZDictItem
>
list
){
iBZDictItemFeignClient
.
updateBatch
(
list
)
;
}
@Override
public
boolean
checkKey
(
IBZDictItem
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getItemid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getItemid
()))
);
return
iBZDictItemFeignClient
.
checkKey
(
et
);
}
@Override
@Transactional
public
boolean
save
(
IBZDictItem
et
)
{
if
(!
saveOrUpdate
(
et
))
if
(
et
.
getItemid
()==
null
)
et
.
setItemid
((
String
)
et
.
getDefaultKey
(
true
));
if
(!
iBZDictItemFeignClient
.
save
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
IBZDictItem
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
}
@Override
public
boolean
saveBatch
(
Collection
<
IBZDictItem
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
IBZDictItem
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
)
;
iBZDictItemFeignClient
.
saveBatch
(
list
)
;
}
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
return
result
;
public
boolean
remove
(
String
itemid
)
{
boolean
result
=
iBZDictItemFeignClient
.
remove
(
itemid
)
;
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
public
void
removeBatch
(
Collection
<
String
>
idList
){
iBZDictItemFeignClient
.
removeBatch
(
idList
);
}
@Override
@Transactional
public
IBZDictItem
get
(
String
key
)
{
IBZDictItem
et
=
getById
(
key
);
public
IBZDictItem
get
(
String
itemid
)
{
IBZDictItem
et
=
iBZDictItemFeignClient
.
get
(
itemid
);
if
(
et
==
null
){
et
=
new
IBZDictItem
();
et
.
setItemid
(
key
);
et
.
setItemid
(
itemid
);
}
else
{
}
return
et
;
return
et
;
}
@Override
@Transactional
public
boolean
create
(
IBZDictItem
et
)
{
if
(!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
)))
IBZDictItem
rt
=
iBZDictItemFeignClient
.
create
(
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getItemid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
IBZDictItem
>
list
)
{
this
.
saveOrUpdateBatch
(
list
,
batchSize
);
public
void
createBatch
(
List
<
IBZDictItem
>
list
){
iBZDictItemFeignClient
.
createBatch
(
list
)
;
}
@Override
public
IBZDictItem
getDraft
(
IBZDictItem
et
)
{
et
=
iBZDictItemFeignClient
.
getDraft
();
return
et
;
}
@Override
public
List
<
IBZDictItem
>
selectByDictid
(
String
dictid
)
{
return
baseMapper
.
selectByDictid
(
dictid
);
IBZDictItemSearchContext
context
=
new
IBZDictItemSearchContext
();
context
.
setSize
(
Integer
.
MAX_VALUE
);
context
.
setN_dictid_eq
(
dictid
);
return
iBZDictItemFeignClient
.
searchDefault
(
context
).
getContent
();
}
@Override
public
void
removeByDictid
(
String
dictid
)
{
this
.
remove
(
new
QueryWrapper
<
IBZDictItem
>().
eq
(
"dictid"
,
dictid
));
Set
<
String
>
delIds
=
new
HashSet
<
String
>();
for
(
IBZDictItem
before:
selectByDictid
(
dictid
)){
delIds
.
add
(
before
.
getItemid
());
}
if
(
delIds
.
size
()>
0
)
this
.
removeBatch
(
delIds
);
}
@Override
...
...
@@ -185,62 +166,17 @@ public class IBZDictItemServiceImpl extends ServiceImpl<IBZDictItemMapper, IBZDi
}
/**
* 查询集合 DEFAULT
*/
@Override
public
Page
<
IBZDictItem
>
searchDefault
(
IBZDictItemSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
IBZDictItem
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
()
);
return
new
PageImpl
<
IBZDictItem
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
())
;
Page
<
IBZDictItem
>
iBZDictItems
=
iBZDictItemFeignClient
.
searchDefault
(
context
);
return
iBZDictItems
;
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
}
@Override
public
List
<
IBZDictItem
>
getIbzdictitemByIds
(
List
<
String
>
ids
)
{
return
this
.
listByIds
(
ids
);
}
@Override
public
List
<
IBZDictItem
>
getIbzdictitemByEntities
(
List
<
IBZDictItem
>
entities
)
{
List
ids
=
new
ArrayList
();
for
(
IBZDictItem
entity
:
entities
){
Serializable
id
=
entity
.
getItemid
();
if
(!
ObjectUtils
.
isEmpty
(
id
)){
ids
.
add
(
id
);
}
}
if
(
ids
.
size
()>
0
)
return
this
.
listByIds
(
ids
);
else
return
entities
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/dict/service/impl/IBZDictServiceImpl.java
浏览文件 @
71ffc6c5
...
...
@@ -30,182 +30,106 @@ import cn.ibizlab.core.dict.service.IIBZDictService;
import
cn.ibizlab.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.core.dict.mapper.IBZDictMapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.core.dict.client.IBZDictFeignClient
;
/**
* 实体[数据字典] 服务对象接口实现
*/
@Slf4j
@Service
(
"IBZDictServiceImpl"
)
public
class
IBZDictServiceImpl
extends
ServiceImpl
<
IBZDictMapper
,
IBZDict
>
implements
IIBZDictService
{
@Service
public
class
IBZDictServiceImpl
implements
IIBZDictService
{
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
dict
.
service
.
IIBZDictItemService
ibzdictitemService
;
IBZDictFeignClient
iBZDictFeignClient
;
private
int
batchSize
=
500
;
@Override
@Transactional
public
boolean
create
(
IBZDict
et
)
{
if
(!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
)))
IBZDict
rt
=
iBZDictFeignClient
.
create
(
et
);
if
(
rt
==
null
)
return
false
;
ibzdictitemService
.
saveByDictid
(
et
.
getDictid
(),
et
.
getItems
());
CachedBeanCopier
.
copy
(
get
(
et
.
getDictid
()),
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
IBZDict
>
list
)
{
this
.
saveBatch
(
list
,
batchSize
);
public
void
createBatch
(
List
<
IBZDict
>
list
){
iBZDictFeignClient
.
createBatch
(
list
)
;
}
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
ibzdictitemService
.
removeByDictid
(
key
)
;
boolean
result
=
removeById
(
key
);
return
result
;
public
boolean
remove
(
String
dictid
)
{
boolean
result
=
iBZDictFeignClient
.
remove
(
dictid
)
;
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
public
void
removeBatch
(
Collection
<
String
>
idList
){
iBZDictFeignClient
.
removeBatch
(
idList
);
}
@Override
@Transactional
public
boolean
update
(
IBZDict
et
)
{
if
(!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"ibzdictid"
,
et
.
getDictid
())))
IBZDict
rt
=
iBZDictFeignClient
.
update
(
et
.
getDictid
(),
et
);
if
(
rt
==
null
)
return
false
;
ibzdictitemService
.
saveByDictid
(
et
.
getDictid
(),
et
.
getItems
());
CachedBeanCopier
.
copy
(
get
(
et
.
getDictid
()),
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
IBZDict
>
list
)
{
updateBatchById
(
list
,
batchSize
);
public
void
updateBatch
(
List
<
IBZDict
>
list
){
iBZDictFeignClient
.
updateBatch
(
list
)
;
}
@Override
public
IBZDict
getDraft
(
IBZDict
et
)
{
et
=
iBZDictFeignClient
.
getDraft
();
return
et
;
}
@Override
@Transactional
public
boolean
save
(
IBZDict
et
)
{
if
(!
saveOrUpdate
(
et
))
if
(
et
.
getDictid
()==
null
)
et
.
setDictid
((
String
)
et
.
getDefaultKey
(
true
));
if
(!
iBZDictFeignClient
.
save
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
IBZDict
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
}
@Override
public
boolean
saveBatch
(
Collection
<
IBZDict
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
IBZDict
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
)
;
iBZDictFeignClient
.
saveBatch
(
list
)
;
}
@Override
@Transactional
public
IBZDict
get
(
String
key
)
{
IBZDict
et
=
getById
(
key
);
public
IBZDict
get
(
String
dictid
)
{
IBZDict
et
=
iBZDictFeignClient
.
get
(
dictid
);
if
(
et
==
null
){
et
=
new
IBZDict
();
et
.
setDictid
(
key
);
et
.
setDictid
(
dictid
);
}
else
{
et
.
setItems
(
ibzdictitemService
.
selectByDictid
(
key
));
}
return
et
;
return
et
;
}
@Override
public
boolean
checkKey
(
IBZDict
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getDictid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getDictid
()))
);
return
iBZDictFeignClient
.
checkKey
(
et
);
}
/**
* 查询集合 DEFAULT
*/
@Override
public
Page
<
IBZDict
>
searchDefault
(
IBZDictSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
IBZDict
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
()
);
return
new
PageImpl
<
IBZDict
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
())
;
Page
<
IBZDict
>
iBZDicts
=
iBZDictFeignClient
.
searchDefault
(
context
);
return
iBZDicts
;
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
}
@Override
public
List
<
IBZDict
>
getIbzdictByIds
(
List
<
String
>
ids
)
{
return
this
.
listByIds
(
ids
);
}
@Override
public
List
<
IBZDict
>
getIbzdictByEntities
(
List
<
IBZDict
>
entities
)
{
List
ids
=
new
ArrayList
();
for
(
IBZDict
entity
:
entities
){
Serializable
id
=
entity
.
getDictid
();
if
(!
ObjectUtils
.
isEmpty
(
id
)){
ids
.
add
(
id
);
}
}
if
(
ids
.
size
()>
0
)
return
this
.
listByIds
(
ids
);
else
return
entities
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/client/IBZDepartmentFallback.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
ou
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.ou.domain.IBZDepartment
;
import
cn.ibizlab.core.ou.filter.IBZDepartmentSearchContext
;
import
org.springframework.stereotype.Component
;
/**
* 实体[IBZDepartment] 服务对象接口
*/
@Component
public
class
IBZDepartmentFallback
implements
IBZDepartmentFeignClient
{
public
Page
<
IBZDepartment
>
select
(){
return
null
;
}
public
Boolean
save
(
IBZDepartment
ibzdepartment
){
return
false
;
}
public
Boolean
saveBatch
(
List
<
IBZDepartment
>
ibzdepartments
){
return
false
;
}
public
IBZDepartment
get
(
String
deptid
){
return
null
;
}
public
Boolean
remove
(
String
deptid
){
return
false
;
}
public
Boolean
removeBatch
(
Collection
<
String
>
idList
){
return
false
;
}
public
Boolean
checkKey
(
IBZDepartment
ibzdepartment
){
return
false
;
}
public
IBZDepartment
update
(
String
deptid
,
IBZDepartment
ibzdepartment
){
return
null
;
}
public
Boolean
updateBatch
(
List
<
IBZDepartment
>
ibzdepartments
){
return
false
;
}
public
IBZDepartment
create
(
IBZDepartment
ibzdepartment
){
return
null
;
}
public
Boolean
createBatch
(
List
<
IBZDepartment
>
ibzdepartments
){
return
false
;
}
public
IBZDepartment
getDraft
(){
return
null
;
}
public
Page
<
IBZDepartment
>
searchCurDept
(
IBZDepartmentSearchContext
context
){
return
null
;
}
public
Page
<
IBZDepartment
>
searchDefault
(
IBZDepartmentSearchContext
context
){
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/client/IBZDepartmentFeignClient.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
ou
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.ou.domain.IBZDepartment
;
import
cn.ibizlab.core.ou.filter.IBZDepartmentSearchContext
;
import
org.springframework.cloud.openfeign.FeignClient
;
/**
* 实体[IBZDepartment] 服务对象接口
*/
@FeignClient
(
value
=
"ibzou-api"
,
contextId
=
"IBZDepartment"
,
fallback
=
IBZDepartmentFallback
.
class
)
public
interface
IBZDepartmentFeignClient
{
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdepartments/select"
)
Page
<
IBZDepartment
>
select
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/save"
)
Boolean
save
(
@RequestBody
IBZDepartment
ibzdepartment
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/save"
)
Boolean
saveBatch
(
@RequestBody
List
<
IBZDepartment
>
ibzdepartments
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdepartments/{deptid}"
)
IBZDepartment
get
(
@PathVariable
(
"deptid"
)
String
deptid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdepartments/{deptid}"
)
Boolean
remove
(
@PathVariable
(
"deptid"
)
String
deptid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdepartments/batch}"
)
Boolean
removeBatch
(
@RequestBody
Collection
<
String
>
idList
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/checkkey"
)
Boolean
checkKey
(
@RequestBody
IBZDepartment
ibzdepartment
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdepartments/{deptid}"
)
IBZDepartment
update
(
@PathVariable
(
"deptid"
)
String
deptid
,
@RequestBody
IBZDepartment
ibzdepartment
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdepartments/batch"
)
Boolean
updateBatch
(
@RequestBody
List
<
IBZDepartment
>
ibzdepartments
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments"
)
IBZDepartment
create
(
@RequestBody
IBZDepartment
ibzdepartment
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/batch"
)
Boolean
createBatch
(
@RequestBody
List
<
IBZDepartment
>
ibzdepartments
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdepartments/getdraft"
)
IBZDepartment
getDraft
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/searchcurdept"
)
Page
<
IBZDepartment
>
searchCurDept
(
@RequestBody
IBZDepartmentSearchContext
context
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/searchdefault"
)
Page
<
IBZDepartment
>
searchDefault
(
@RequestBody
IBZDepartmentSearchContext
context
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/client/IBZDeptMemberFallback.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
ou
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.ou.domain.IBZDeptMember
;
import
cn.ibizlab.core.ou.filter.IBZDeptMemberSearchContext
;
import
org.springframework.stereotype.Component
;
/**
* 实体[IBZDeptMember] 服务对象接口
*/
@Component
public
class
IBZDeptMemberFallback
implements
IBZDeptMemberFeignClient
{
public
Page
<
IBZDeptMember
>
select
(){
return
null
;
}
public
IBZDeptMember
update
(
String
memberid
,
IBZDeptMember
ibzdeptmember
){
return
null
;
}
public
Boolean
updateBatch
(
List
<
IBZDeptMember
>
ibzdeptmembers
){
return
false
;
}
public
IBZDeptMember
get
(
String
memberid
){
return
null
;
}
public
Boolean
checkKey
(
IBZDeptMember
ibzdeptmember
){
return
false
;
}
public
Boolean
remove
(
String
memberid
){
return
false
;
}
public
Boolean
removeBatch
(
Collection
<
String
>
idList
){
return
false
;
}
public
IBZDeptMember
create
(
IBZDeptMember
ibzdeptmember
){
return
null
;
}
public
Boolean
createBatch
(
List
<
IBZDeptMember
>
ibzdeptmembers
){
return
false
;
}
public
IBZDeptMember
getDraft
(){
return
null
;
}
public
Boolean
save
(
IBZDeptMember
ibzdeptmember
){
return
false
;
}
public
Boolean
saveBatch
(
List
<
IBZDeptMember
>
ibzdeptmembers
){
return
false
;
}
public
Page
<
IBZDeptMember
>
searchDefault
(
IBZDeptMemberSearchContext
context
){
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/client/IBZDeptMemberFeignClient.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
ou
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.ou.domain.IBZDeptMember
;
import
cn.ibizlab.core.ou.filter.IBZDeptMemberSearchContext
;
import
org.springframework.cloud.openfeign.FeignClient
;
/**
* 实体[IBZDeptMember] 服务对象接口
*/
@FeignClient
(
value
=
"ibzou-api"
,
contextId
=
"IBZDeptMember"
,
fallback
=
IBZDeptMemberFallback
.
class
)
public
interface
IBZDeptMemberFeignClient
{
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdeptmembers/select"
)
Page
<
IBZDeptMember
>
select
();
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdeptmembers/{memberid}"
)
IBZDeptMember
update
(
@PathVariable
(
"memberid"
)
String
memberid
,
@RequestBody
IBZDeptMember
ibzdeptmember
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdeptmembers/batch"
)
Boolean
updateBatch
(
@RequestBody
List
<
IBZDeptMember
>
ibzdeptmembers
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdeptmembers/{memberid}"
)
IBZDeptMember
get
(
@PathVariable
(
"memberid"
)
String
memberid
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdeptmembers/checkkey"
)
Boolean
checkKey
(
@RequestBody
IBZDeptMember
ibzdeptmember
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdeptmembers/{memberid}"
)
Boolean
remove
(
@PathVariable
(
"memberid"
)
String
memberid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdeptmembers/batch}"
)
Boolean
removeBatch
(
@RequestBody
Collection
<
String
>
idList
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdeptmembers"
)
IBZDeptMember
create
(
@RequestBody
IBZDeptMember
ibzdeptmember
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdeptmembers/batch"
)
Boolean
createBatch
(
@RequestBody
List
<
IBZDeptMember
>
ibzdeptmembers
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdeptmembers/getdraft"
)
IBZDeptMember
getDraft
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdeptmembers/save"
)
Boolean
save
(
@RequestBody
IBZDeptMember
ibzdeptmember
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdeptmembers/save"
)
Boolean
saveBatch
(
@RequestBody
List
<
IBZDeptMember
>
ibzdeptmembers
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdeptmembers/searchdefault"
)
Page
<
IBZDeptMember
>
searchDefault
(
@RequestBody
IBZDeptMemberSearchContext
context
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/client/IBZEmployeeFallback.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
ou
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.ou.domain.IBZEmployee
;
import
cn.ibizlab.core.ou.filter.IBZEmployeeSearchContext
;
import
org.springframework.stereotype.Component
;
/**
* 实体[IBZEmployee] 服务对象接口
*/
@Component
public
class
IBZEmployeeFallback
implements
IBZEmployeeFeignClient
{
public
Page
<
IBZEmployee
>
select
(){
return
null
;
}
public
Boolean
remove
(
String
userid
){
return
false
;
}
public
Boolean
removeBatch
(
Collection
<
String
>
idList
){
return
false
;
}
public
IBZEmployee
update
(
String
userid
,
IBZEmployee
ibzemployee
){
return
null
;
}
public
Boolean
updateBatch
(
List
<
IBZEmployee
>
ibzemployees
){
return
false
;
}
public
Boolean
checkKey
(
IBZEmployee
ibzemployee
){
return
false
;
}
public
IBZEmployee
get
(
String
userid
){
return
null
;
}
public
Boolean
save
(
IBZEmployee
ibzemployee
){
return
false
;
}
public
Boolean
saveBatch
(
List
<
IBZEmployee
>
ibzemployees
){
return
false
;
}
public
IBZEmployee
initPwd
(
String
userid
,
IBZEmployee
ibzemployee
){
return
null
;
}
public
IBZEmployee
getDraft
(){
return
null
;
}
public
IBZEmployee
create
(
IBZEmployee
ibzemployee
){
return
null
;
}
public
Boolean
createBatch
(
List
<
IBZEmployee
>
ibzemployees
){
return
false
;
}
public
Page
<
IBZEmployee
>
searchDefault
(
IBZEmployeeSearchContext
context
){
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/client/IBZEmployeeFeignClient.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
ou
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.ou.domain.IBZEmployee
;
import
cn.ibizlab.core.ou.filter.IBZEmployeeSearchContext
;
import
org.springframework.cloud.openfeign.FeignClient
;
/**
* 实体[IBZEmployee] 服务对象接口
*/
@FeignClient
(
value
=
"ibzou-api"
,
contextId
=
"IBZEmployee"
,
fallback
=
IBZEmployeeFallback
.
class
)
public
interface
IBZEmployeeFeignClient
{
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzemployees/select"
)
Page
<
IBZEmployee
>
select
();
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzemployees/{userid}"
)
Boolean
remove
(
@PathVariable
(
"userid"
)
String
userid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzemployees/batch}"
)
Boolean
removeBatch
(
@RequestBody
Collection
<
String
>
idList
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzemployees/{userid}"
)
IBZEmployee
update
(
@PathVariable
(
"userid"
)
String
userid
,
@RequestBody
IBZEmployee
ibzemployee
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzemployees/batch"
)
Boolean
updateBatch
(
@RequestBody
List
<
IBZEmployee
>
ibzemployees
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/checkkey"
)
Boolean
checkKey
(
@RequestBody
IBZEmployee
ibzemployee
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzemployees/{userid}"
)
IBZEmployee
get
(
@PathVariable
(
"userid"
)
String
userid
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/save"
)
Boolean
save
(
@RequestBody
IBZEmployee
ibzemployee
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/save"
)
Boolean
saveBatch
(
@RequestBody
List
<
IBZEmployee
>
ibzemployees
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/{userid}/initpwd"
)
IBZEmployee
initPwd
(
@PathVariable
(
"userid"
)
String
userid
,
@RequestBody
IBZEmployee
ibzemployee
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzemployees/getdraft"
)
IBZEmployee
getDraft
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees"
)
IBZEmployee
create
(
@RequestBody
IBZEmployee
ibzemployee
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/batch"
)
Boolean
createBatch
(
@RequestBody
List
<
IBZEmployee
>
ibzemployees
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/searchdefault"
)
Page
<
IBZEmployee
>
searchDefault
(
@RequestBody
IBZEmployeeSearchContext
context
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/client/IBZOrganizationFallback.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
ou
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.ou.domain.IBZOrganization
;
import
cn.ibizlab.core.ou.filter.IBZOrganizationSearchContext
;
import
org.springframework.stereotype.Component
;
/**
* 实体[IBZOrganization] 服务对象接口
*/
@Component
public
class
IBZOrganizationFallback
implements
IBZOrganizationFeignClient
{
public
Page
<
IBZOrganization
>
select
(){
return
null
;
}
public
Boolean
save
(
IBZOrganization
ibzorganization
){
return
false
;
}
public
Boolean
saveBatch
(
List
<
IBZOrganization
>
ibzorganizations
){
return
false
;
}
public
Boolean
checkKey
(
IBZOrganization
ibzorganization
){
return
false
;
}
public
IBZOrganization
get
(
String
orgid
){
return
null
;
}
public
IBZOrganization
create
(
IBZOrganization
ibzorganization
){
return
null
;
}
public
Boolean
createBatch
(
List
<
IBZOrganization
>
ibzorganizations
){
return
false
;
}
public
Boolean
remove
(
String
orgid
){
return
false
;
}
public
Boolean
removeBatch
(
Collection
<
String
>
idList
){
return
false
;
}
public
IBZOrganization
getDraft
(){
return
null
;
}
public
IBZOrganization
update
(
String
orgid
,
IBZOrganization
ibzorganization
){
return
null
;
}
public
Boolean
updateBatch
(
List
<
IBZOrganization
>
ibzorganizations
){
return
false
;
}
public
Page
<
IBZOrganization
>
searchDefault
(
IBZOrganizationSearchContext
context
){
return
null
;
}
public
Page
<
IBZOrganization
>
searchSelectPOrg
(
IBZOrganizationSearchContext
context
){
return
null
;
}
public
Page
<
IBZOrganization
>
searchSelectSOrg
(
IBZOrganizationSearchContext
context
){
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/client/IBZOrganizationFeignClient.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
ou
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.ou.domain.IBZOrganization
;
import
cn.ibizlab.core.ou.filter.IBZOrganizationSearchContext
;
import
org.springframework.cloud.openfeign.FeignClient
;
/**
* 实体[IBZOrganization] 服务对象接口
*/
@FeignClient
(
value
=
"ibzou-api"
,
contextId
=
"IBZOrganization"
,
fallback
=
IBZOrganizationFallback
.
class
)
public
interface
IBZOrganizationFeignClient
{
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzorganizations/select"
)
Page
<
IBZOrganization
>
select
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/save"
)
Boolean
save
(
@RequestBody
IBZOrganization
ibzorganization
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/save"
)
Boolean
saveBatch
(
@RequestBody
List
<
IBZOrganization
>
ibzorganizations
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/checkkey"
)
Boolean
checkKey
(
@RequestBody
IBZOrganization
ibzorganization
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzorganizations/{orgid}"
)
IBZOrganization
get
(
@PathVariable
(
"orgid"
)
String
orgid
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations"
)
IBZOrganization
create
(
@RequestBody
IBZOrganization
ibzorganization
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/batch"
)
Boolean
createBatch
(
@RequestBody
List
<
IBZOrganization
>
ibzorganizations
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzorganizations/{orgid}"
)
Boolean
remove
(
@PathVariable
(
"orgid"
)
String
orgid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzorganizations/batch}"
)
Boolean
removeBatch
(
@RequestBody
Collection
<
String
>
idList
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzorganizations/getdraft"
)
IBZOrganization
getDraft
();
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzorganizations/{orgid}"
)
IBZOrganization
update
(
@PathVariable
(
"orgid"
)
String
orgid
,
@RequestBody
IBZOrganization
ibzorganization
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzorganizations/batch"
)
Boolean
updateBatch
(
@RequestBody
List
<
IBZOrganization
>
ibzorganizations
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/searchdefault"
)
Page
<
IBZOrganization
>
searchDefault
(
@RequestBody
IBZOrganizationSearchContext
context
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/searchselectporg"
)
Page
<
IBZOrganization
>
searchSelectPOrg
(
@RequestBody
IBZOrganizationSearchContext
context
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/searchselectsorg"
)
Page
<
IBZOrganization
>
searchSelectSOrg
(
@RequestBody
IBZOrganizationSearchContext
context
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/domain/IBZDepartment.java
浏览文件 @
71ffc6c5
...
...
@@ -21,160 +21,152 @@ import java.io.Serializable;
import
lombok.Data
;
import
org.springframework.data.annotation.Transient
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.util.domain.EntityMP
;
import
cn.ibizlab.util.domain.EntityClient
;
/**
*
实体[部门]
*
ServiceApi [部门] 对象
*/
@Data
@TableName
(
value
=
"IBZDEPT"
,
resultMap
=
"IBZDepartmentResultMap"
)
public
class
IBZDepartment
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
public
class
IBZDepartment
extends
EntityClient
implements
Serializable
{
/**
* 部门标识
*/
@DEField
(
isKeyField
=
true
)
@TableId
(
value
=
"deptid"
,
type
=
IdType
.
UUID
)
@JSONField
(
name
=
"deptid"
)
@JsonProperty
(
"deptid"
)
private
String
deptid
;
/**
* 部门代码
*/
@TableField
(
value
=
"deptcode"
)
@JSONField
(
name
=
"deptcode"
)
@JsonProperty
(
"deptcode"
)
private
String
deptcode
;
/**
* 部门名称
*/
@TableField
(
value
=
"deptname"
)
@JSONField
(
name
=
"deptname"
)
@JsonProperty
(
"deptname"
)
private
String
deptname
;
/**
* 单位
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
ORGID
)
@TableField
(
value
=
"orgid"
)
@JSONField
(
name
=
"orgid"
)
@JsonProperty
(
"orgid"
)
private
String
orgid
;
/**
* 上级部门
*/
@DEField
(
name
=
"pdeptid"
)
@TableField
(
value
=
"pdeptid"
)
@JSONField
(
name
=
"parentdeptid"
)
@JsonProperty
(
"parentdeptid"
)
private
String
parentdeptid
;
/**
* 部门简称
*/
@TableField
(
value
=
"shortname"
)
@JSONField
(
name
=
"shortname"
)
@JsonProperty
(
"shortname"
)
private
String
shortname
;
/**
* 部门级别
*/
@TableField
(
value
=
"deptlevel"
)
@JSONField
(
name
=
"deptlevel"
)
@JsonProperty
(
"deptlevel"
)
private
Integer
deptlevel
;
/**
* 排序
*/
@TableField
(
value
=
"showorder"
)
@JSONField
(
name
=
"showorder"
)
@JsonProperty
(
"showorder"
)
private
Integer
showorder
;
/**
* 业务编码
*/
@TableField
(
value
=
"bcode"
)
@JSONField
(
name
=
"bcode"
)
@JsonProperty
(
"bcode"
)
private
String
bcode
;
/**
* 分管领导标识
*/
@TableField
(
value
=
"leaderid"
)
@JSONField
(
name
=
"leaderid"
)
@JsonProperty
(
"leaderid"
)
private
String
leaderid
;
/**
* 分管领导
*/
@TableField
(
value
=
"leadername"
)
@JSONField
(
name
=
"leadername"
)
@JsonProperty
(
"leadername"
)
private
String
leadername
;
/**
* 逻辑有效
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
LOGICVALID
,
logicval
=
"1"
,
logicdelval
=
"0"
)
@TableLogic
(
value
=
"1"
,
delval
=
"0"
)
@TableField
(
value
=
"enable"
)
@JSONField
(
name
=
"enable"
)
@JsonProperty
(
"enable"
)
private
Integer
enable
;
/**
* 单位
*/
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"orgname"
)
@JsonProperty
(
"orgname"
)
private
String
orgname
;
/**
* 上级部门
*/
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"parentdeptname"
)
@JsonProperty
(
"parentdeptname"
)
private
String
parentdeptname
;
/**
* 创建时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@TableField
(
value
=
"createdate"
,
fill
=
FieldFill
.
INSERT
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"createdate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"createdate"
)
private
Timestamp
createdate
;
/**
* 最后修改时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEDATE
)
@TableField
(
value
=
"updatedate"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"updatedate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"updatedate"
)
private
Timestamp
updatedate
;
/**
*
*/
@JsonIgnore
@JSONField
(
serialize
=
false
)
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"parentdept"
)
@JsonProperty
(
"parentdept"
)
private
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZDepartment
parentdept
;
/**
* 单位
*/
@JsonIgnore
@JSONField
(
serialize
=
false
)
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"org"
)
@JsonProperty
(
"org"
)
private
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZOrganization
org
;
/**
* 设置 [部门代码]
*/
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/ou/domain/IBZDeptMember.java
浏览文件 @
71ffc6c5
...
...
@@ -21,75 +21,68 @@ import java.io.Serializable;
import
lombok.Data
;
import
org.springframework.data.annotation.Transient
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.util.domain.EntityMP
;
import
cn.ibizlab.util.domain.EntityClient
;
/**
*
实体[部门成员]
*
ServiceApi [部门成员] 对象
*/
@Data
@TableName
(
value
=
"IBZDEPTMEMBER"
,
resultMap
=
"IBZDeptMemberResultMap"
)
public
class
IBZDeptMember
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
public
class
IBZDeptMember
extends
EntityClient
implements
Serializable
{
/**
* 标识
*/
@DEField
(
isKeyField
=
true
)
@TableId
(
value
=
"memberid"
,
type
=
IdType
.
UUID
)
@JSONField
(
name
=
"memberid"
)
@JsonProperty
(
"memberid"
)
private
String
memberid
;
/**
* 部门标识
*/
@TableField
(
value
=
"deptid"
)
@JSONField
(
name
=
"deptid"
)
@JsonProperty
(
"deptid"
)
private
String
deptid
;
/**
* 部门名称
*/
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"deptname"
)
@JsonProperty
(
"deptname"
)
private
String
deptname
;
/**
* 用户标识
*/
@TableField
(
value
=
"userid"
)
@JSONField
(
name
=
"userid"
)
@JsonProperty
(
"userid"
)
private
String
userid
;
/**
* 成员
*/
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"personname"
)
@JsonProperty
(
"personname"
)
private
String
personname
;
/**
* 部门
*/
@JsonIgnore
@JSONField
(
serialize
=
false
)
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"dept"
)
@JsonProperty
(
"dept"
)
private
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZDepartment
dept
;
/**
* 人员
*/
@JsonIgnore
@JSONField
(
serialize
=
false
)
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"emp"
)
@JsonProperty
(
"emp"
)
private
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZEmployee
emp
;
/**
* 设置 [部门标识]
*/
...
...
@@ -105,22 +98,6 @@ public class IBZDeptMember extends EntityMP implements Serializable {
this
.
modify
(
"userid"
,
userid
);
}
/**
* 获取 [标识]
*/
public
String
getMemberid
(){
if
(
ObjectUtils
.
isEmpty
(
memberid
)){
memberid
=(
String
)
getDefaultKey
(
true
);
}
return
memberid
;
}
@Override
public
Serializable
getDefaultKey
(
boolean
gen
)
{
if
((!
ObjectUtils
.
isEmpty
(
this
.
getDeptid
()))&&(!
ObjectUtils
.
isEmpty
(
this
.
getUserid
())))
return
DigestUtils
.
md5DigestAsHex
(
String
.
format
(
"%s||%s"
,
this
.
getDeptid
(),
this
.
getUserid
()).
getBytes
());
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/domain/IBZEmployee.java
浏览文件 @
71ffc6c5
...
...
@@ -21,301 +21,293 @@ import java.io.Serializable;
import
lombok.Data
;
import
org.springframework.data.annotation.Transient
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.util.domain.EntityMP
;
import
cn.ibizlab.util.domain.EntityClient
;
/**
*
实体[人员]
*
ServiceApi [人员] 对象
*/
@Data
@TableName
(
value
=
"IBZEMP"
,
resultMap
=
"IBZEmployeeResultMap"
)
public
class
IBZEmployee
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
public
class
IBZEmployee
extends
EntityClient
implements
Serializable
{
/**
* 用户标识
*/
@DEField
(
isKeyField
=
true
)
@TableId
(
value
=
"userid"
,
type
=
IdType
.
UUID
)
@JSONField
(
name
=
"userid"
)
@JsonProperty
(
"userid"
)
private
String
userid
;
/**
* 用户全局名
*/
@TableField
(
value
=
"username"
)
@JSONField
(
name
=
"username"
)
@JsonProperty
(
"username"
)
private
String
username
;
/**
* 姓名
*/
@TableField
(
value
=
"personname"
)
@JSONField
(
name
=
"personname"
)
@JsonProperty
(
"personname"
)
private
String
personname
;
/**
* 用户工号
*/
@TableField
(
value
=
"usercode"
)
@JSONField
(
name
=
"usercode"
)
@JsonProperty
(
"usercode"
)
private
String
usercode
;
/**
* 登录名
*/
@TableField
(
value
=
"loginname"
)
@JSONField
(
name
=
"loginname"
)
@JsonProperty
(
"loginname"
)
private
String
loginname
;
/**
* 密码
*/
@TableField
(
value
=
"password"
)
@JSONField
(
name
=
"password"
)
@JsonProperty
(
"password"
)
private
String
password
;
/**
* 区属
*/
@TableField
(
value
=
"domains"
)
@JSONField
(
name
=
"domains"
)
@JsonProperty
(
"domains"
)
private
String
domains
;
/**
* 主部门
*/
@TableField
(
value
=
"mdeptid"
)
@JSONField
(
name
=
"mdeptid"
)
@JsonProperty
(
"mdeptid"
)
private
String
mdeptid
;
/**
* 主部门代码
*/
@TableField
(
value
=
"mdeptcode"
)
@JSONField
(
name
=
"mdeptcode"
)
@JsonProperty
(
"mdeptcode"
)
private
String
mdeptcode
;
/**
* 主部门名称
*/
@TableField
(
value
=
"mdeptname"
)
@JSONField
(
name
=
"mdeptname"
)
@JsonProperty
(
"mdeptname"
)
private
String
mdeptname
;
/**
* 业务编码
*/
@TableField
(
value
=
"bcode"
)
@JSONField
(
name
=
"bcode"
)
@JsonProperty
(
"bcode"
)
private
String
bcode
;
/**
* 岗位
*/
@TableField
(
value
=
"postid"
)
@JSONField
(
name
=
"postid"
)
@JsonProperty
(
"postid"
)
private
String
postid
;
/**
* 岗位代码
*/
@TableField
(
value
=
"postcode"
)
@JSONField
(
name
=
"postcode"
)
@JsonProperty
(
"postcode"
)
private
String
postcode
;
/**
* 岗位名称
*/
@TableField
(
value
=
"postname"
)
@JSONField
(
name
=
"postname"
)
@JsonProperty
(
"postname"
)
private
String
postname
;
/**
* 单位
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
ORGID
)
@TableField
(
value
=
"orgid"
)
@JSONField
(
name
=
"orgid"
)
@JsonProperty
(
"orgid"
)
private
String
orgid
;
/**
* 单位代码
*/
@TableField
(
value
=
"orgcode"
)
@JSONField
(
name
=
"orgcode"
)
@JsonProperty
(
"orgcode"
)
private
String
orgcode
;
/**
* 单位名称
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
ORGNAME
)
@TableField
(
value
=
"orgname"
)
@JSONField
(
name
=
"orgname"
)
@JsonProperty
(
"orgname"
)
private
String
orgname
;
/**
* 昵称别名
*/
@TableField
(
value
=
"nickname"
)
@JSONField
(
name
=
"nickname"
)
@JsonProperty
(
"nickname"
)
private
String
nickname
;
/**
* 性别
*/
@TableField
(
value
=
"sex"
)
@JSONField
(
name
=
"sex"
)
@JsonProperty
(
"sex"
)
private
String
sex
;
/**
* 证件号码
*/
@TableField
(
value
=
"certcode"
)
@JSONField
(
name
=
"certcode"
)
@JsonProperty
(
"certcode"
)
private
String
certcode
;
/**
* 联系方式
*/
@TableField
(
value
=
"phone"
)
@JSONField
(
name
=
"phone"
)
@JsonProperty
(
"phone"
)
private
String
phone
;
/**
* 出生日期
*/
@TableField
(
value
=
"birthday"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"birthday"
,
format
=
"yyyy-MM-dd"
)
@JsonProperty
(
"birthday"
)
private
Timestamp
birthday
;
/**
* 邮件
*/
@TableField
(
value
=
"email"
)
@JSONField
(
name
=
"email"
)
@JsonProperty
(
"email"
)
private
String
email
;
/**
* 社交账号
*/
@TableField
(
value
=
"avatar"
)
@JSONField
(
name
=
"avatar"
)
@JsonProperty
(
"avatar"
)
private
String
avatar
;
/**
* 地址
*/
@TableField
(
value
=
"addr"
)
@JSONField
(
name
=
"addr"
)
@JsonProperty
(
"addr"
)
private
String
addr
;
/**
* 照片
*/
@TableField
(
value
=
"usericon"
)
@JSONField
(
name
=
"usericon"
)
@JsonProperty
(
"usericon"
)
private
String
usericon
;
/**
* ip地址
*/
@TableField
(
value
=
"ipaddr"
)
@JSONField
(
name
=
"ipaddr"
)
@JsonProperty
(
"ipaddr"
)
private
String
ipaddr
;
/**
* 样式
*/
@TableField
(
value
=
"theme"
)
@JSONField
(
name
=
"theme"
)
@JsonProperty
(
"theme"
)
private
String
theme
;
/**
* 语言
*/
@TableField
(
value
=
"lang"
)
@JSONField
(
name
=
"lang"
)
@JsonProperty
(
"lang"
)
private
String
lang
;
/**
* 字号
*/
@TableField
(
value
=
"fontsize"
)
@JSONField
(
name
=
"fontsize"
)
@JsonProperty
(
"fontsize"
)
private
String
fontsize
;
/**
* 备注
*/
@TableField
(
value
=
"memo"
)
@JSONField
(
name
=
"memo"
)
@JsonProperty
(
"memo"
)
private
String
memo
;
/**
* 保留
*/
@TableField
(
value
=
"reserver"
)
@JSONField
(
name
=
"reserver"
)
@JsonProperty
(
"reserver"
)
private
String
reserver
;
/**
* 排序
*/
@TableField
(
value
=
"showorder"
)
@JSONField
(
name
=
"showorder"
)
@JsonProperty
(
"showorder"
)
private
Integer
showorder
;
/**
* 逻辑有效
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
LOGICVALID
,
logicval
=
"1"
,
logicdelval
=
"0"
)
@TableLogic
(
value
=
"1"
,
delval
=
"0"
)
@TableField
(
value
=
"enable"
)
@JSONField
(
name
=
"enable"
)
@JsonProperty
(
"enable"
)
private
Integer
enable
;
/**
* 创建时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@TableField
(
value
=
"createdate"
,
fill
=
FieldFill
.
INSERT
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"createdate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"createdate"
)
private
Timestamp
createdate
;
/**
* 最后修改时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEDATE
)
@TableField
(
value
=
"updatedate"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"updatedate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"updatedate"
)
private
Timestamp
updatedate
;
/**
*
*/
@JsonIgnore
@JSONField
(
serialize
=
false
)
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"maindept"
)
@JsonProperty
(
"maindept"
)
private
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZDepartment
maindept
;
/**
*
*/
@JsonIgnore
@JSONField
(
serialize
=
false
)
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"org"
)
@JsonProperty
(
"org"
)
private
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZOrganization
org
;
/**
* 设置 [用户全局名]
*/
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/ou/domain/IBZOrganization.java
浏览文件 @
71ffc6c5
...
...
@@ -21,125 +21,117 @@ import java.io.Serializable;
import
lombok.Data
;
import
org.springframework.data.annotation.Transient
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.util.domain.EntityMP
;
import
cn.ibizlab.util.domain.EntityClient
;
/**
*
实体[单位机构]
*
ServiceApi [单位机构] 对象
*/
@Data
@TableName
(
value
=
"IBZORG"
,
resultMap
=
"IBZOrganizationResultMap"
)
public
class
IBZOrganization
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
public
class
IBZOrganization
extends
EntityClient
implements
Serializable
{
/**
* 单位标识
*/
@DEField
(
defaultValue
=
"orgcode"
,
defaultValueType
=
DEFieldDefaultValueType
.
PARAM
,
isKeyField
=
true
)
@TableId
(
value
=
"orgid"
,
type
=
IdType
.
UUID
)
@JSONField
(
name
=
"orgid"
)
@JsonProperty
(
"orgid"
)
private
String
orgid
;
/**
* 单位代码
*/
@TableField
(
value
=
"orgcode"
)
@JSONField
(
name
=
"orgcode"
)
@JsonProperty
(
"orgcode"
)
private
String
orgcode
;
/**
* 名称
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
ORGNAME
)
@TableField
(
value
=
"orgname"
)
@JSONField
(
name
=
"orgname"
)
@JsonProperty
(
"orgname"
)
private
String
orgname
;
/**
* 上级单位
*/
@DEField
(
name
=
"porgid"
)
@TableField
(
value
=
"porgid"
)
@JSONField
(
name
=
"parentorgid"
)
@JsonProperty
(
"parentorgid"
)
private
String
parentorgid
;
/**
* 单位简称
*/
@TableField
(
value
=
"shortname"
)
@JSONField
(
name
=
"shortname"
)
@JsonProperty
(
"shortname"
)
private
String
shortname
;
/**
* 单位级别
*/
@TableField
(
value
=
"orglevel"
)
@JSONField
(
name
=
"orglevel"
)
@JsonProperty
(
"orglevel"
)
private
Integer
orglevel
;
/**
* 排序
*/
@TableField
(
value
=
"showorder"
)
@JSONField
(
name
=
"showorder"
)
@JsonProperty
(
"showorder"
)
private
Integer
showorder
;
/**
* 上级单位
*/
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"parentorgname"
)
@JsonProperty
(
"parentorgname"
)
private
String
parentorgname
;
/**
* 逻辑有效
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
LOGICVALID
,
logicval
=
"1"
,
logicdelval
=
"0"
)
@TableLogic
(
value
=
"1"
,
delval
=
"0"
)
@TableField
(
value
=
"enable"
)
@JSONField
(
name
=
"enable"
)
@JsonProperty
(
"enable"
)
private
Integer
enable
;
/**
* 创建时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@TableField
(
value
=
"createdate"
,
fill
=
FieldFill
.
INSERT
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"createdate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"createdate"
)
private
Timestamp
createdate
;
/**
* 最后修改时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEDATE
)
@TableField
(
value
=
"updatedate"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"updatedate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"updatedate"
)
private
Timestamp
updatedate
;
/**
*
*/
@JsonIgnore
@JSONField
(
serialize
=
false
)
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"parentorg"
)
@JsonProperty
(
"parentorg"
)
private
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZOrganization
parentorg
;
/**
* 部门
*/
@JsonIgnore
@JSONField
(
serialize
=
false
)
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"depts"
)
@JsonProperty
(
"depts"
)
private
List
<
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZDepartment
>
depts
;
/**
* 设置 [单位代码]
*/
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/ou/filter/IBZDepartmentSearchContext.java
浏览文件 @
71ffc6c5
...
...
@@ -17,92 +17,33 @@ import org.springframework.util.ObjectUtils;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.core.ou.domain.IBZDepartment
;
import
cn.ibizlab.util.filter.SearchContextBase
;
/**
*
关系型
数据实体[IBZDepartment] 查询条件对象
*
ServiceApi
数据实体[IBZDepartment] 查询条件对象
*/
@Slf4j
@Data
public
class
IBZDepartmentSearchContext
extends
QueryWrapperContext
<
IBZDepartment
>
{
public
class
IBZDepartmentSearchContext
extends
SearchContextBase
{
private
String
n_deptcode_like
;
//[部门代码]
public
void
setN_deptcode_like
(
String
n_deptcode_like
)
{
this
.
n_deptcode_like
=
n_deptcode_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_deptcode_like
)){
this
.
getSelectCond
().
like
(
"deptcode"
,
n_deptcode_like
);
}
}
private
String
n_deptname_like
;
//[部门名称]
public
void
setN_deptname_like
(
String
n_deptname_like
)
{
this
.
n_deptname_like
=
n_deptname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_deptname_like
)){
this
.
getSelectCond
().
like
(
"deptname"
,
n_deptname_like
);
}
}
private
String
n_orgid_eq
;
//[单位]
public
void
setN_orgid_eq
(
String
n_orgid_eq
)
{
this
.
n_orgid_eq
=
n_orgid_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_orgid_eq
)){
this
.
getSelectCond
().
eq
(
"orgid"
,
n_orgid_eq
);
}
}
private
String
n_pdeptid_eq
;
//[上级部门]
public
void
setN_pdeptid_eq
(
String
n_pdeptid_eq
)
{
this
.
n_pdeptid_eq
=
n_pdeptid_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_pdeptid_eq
)){
this
.
getSelectCond
().
eq
(
"pdeptid"
,
n_pdeptid_eq
);
}
}
private
String
n_bcode_like
;
//[业务编码]
public
void
setN_bcode_like
(
String
n_bcode_like
)
{
this
.
n_bcode_like
=
n_bcode_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_bcode_like
)){
this
.
getSelectCond
().
like
(
"bcode"
,
n_bcode_like
);
}
}
private
String
n_orgname_eq
;
//[单位]
public
void
setN_orgname_eq
(
String
n_orgname_eq
)
{
this
.
n_orgname_eq
=
n_orgname_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_orgname_eq
)){
this
.
getSelectCond
().
eq
(
"orgname"
,
n_orgname_eq
);
}
}
private
String
n_orgname_like
;
//[单位]
public
void
setN_orgname_like
(
String
n_orgname_like
)
{
this
.
n_orgname_like
=
n_orgname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_orgname_like
)){
this
.
getSelectCond
().
like
(
"orgname"
,
n_orgname_like
);
}
}
private
String
n_pdeptname_eq
;
//[上级部门]
public
void
setN_pdeptname_eq
(
String
n_pdeptname_eq
)
{
this
.
n_pdeptname_eq
=
n_pdeptname_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_pdeptname_eq
)){
this
.
getSelectCond
().
eq
(
"pdeptname"
,
n_pdeptname_eq
);
}
}
private
String
n_pdeptname_like
;
//[上级部门]
public
void
setN_pdeptname_like
(
String
n_pdeptname_like
)
{
this
.
n_pdeptname_like
=
n_pdeptname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_pdeptname_like
)){
this
.
getSelectCond
().
like
(
"pdeptname"
,
n_pdeptname_like
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSelectCond
().
or
().
like
(
"deptname"
,
query
);
}
}
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/filter/IBZDeptMemberSearchContext.java
浏览文件 @
71ffc6c5
...
...
@@ -17,71 +17,27 @@ import org.springframework.util.ObjectUtils;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.core.ou.domain.IBZDeptMember
;
import
cn.ibizlab.util.filter.SearchContextBase
;
/**
*
关系型
数据实体[IBZDeptMember] 查询条件对象
*
ServiceApi
数据实体[IBZDeptMember] 查询条件对象
*/
@Slf4j
@Data
public
class
IBZDeptMemberSearchContext
extends
QueryWrapperContext
<
IBZDeptMember
>
{
public
class
IBZDeptMemberSearchContext
extends
SearchContextBase
{
private
String
n_deptid_eq
;
//[部门标识]
public
void
setN_deptid_eq
(
String
n_deptid_eq
)
{
this
.
n_deptid_eq
=
n_deptid_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_deptid_eq
)){
this
.
getSelectCond
().
eq
(
"deptid"
,
n_deptid_eq
);
}
}
private
String
n_deptname_eq
;
//[部门名称]
public
void
setN_deptname_eq
(
String
n_deptname_eq
)
{
this
.
n_deptname_eq
=
n_deptname_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_deptname_eq
)){
this
.
getSelectCond
().
eq
(
"deptname"
,
n_deptname_eq
);
}
}
private
String
n_deptname_like
;
//[部门名称]
public
void
setN_deptname_like
(
String
n_deptname_like
)
{
this
.
n_deptname_like
=
n_deptname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_deptname_like
)){
this
.
getSelectCond
().
like
(
"deptname"
,
n_deptname_like
);
}
}
private
String
n_userid_eq
;
//[用户标识]
public
void
setN_userid_eq
(
String
n_userid_eq
)
{
this
.
n_userid_eq
=
n_userid_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_userid_eq
)){
this
.
getSelectCond
().
eq
(
"userid"
,
n_userid_eq
);
}
}
private
String
n_personname_eq
;
//[成员]
public
void
setN_personname_eq
(
String
n_personname_eq
)
{
this
.
n_personname_eq
=
n_personname_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_personname_eq
)){
this
.
getSelectCond
().
eq
(
"personname"
,
n_personname_eq
);
}
}
private
String
n_personname_like
;
//[成员]
public
void
setN_personname_like
(
String
n_personname_like
)
{
this
.
n_personname_like
=
n_personname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_personname_like
)){
this
.
getSelectCond
().
like
(
"personname"
,
n_personname_like
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSelectCond
().
or
().
like
(
"personname"
,
query
);
}
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/filter/IBZEmployeeSearchContext.java
浏览文件 @
71ffc6c5
...
...
@@ -17,85 +17,31 @@ import org.springframework.util.ObjectUtils;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.core.ou.domain.IBZEmployee
;
import
cn.ibizlab.util.filter.SearchContextBase
;
/**
*
关系型
数据实体[IBZEmployee] 查询条件对象
*
ServiceApi
数据实体[IBZEmployee] 查询条件对象
*/
@Slf4j
@Data
public
class
IBZEmployeeSearchContext
extends
QueryWrapperContext
<
IBZEmployee
>
{
public
class
IBZEmployeeSearchContext
extends
SearchContextBase
{
private
String
n_personname_like
;
//[姓名]
public
void
setN_personname_like
(
String
n_personname_like
)
{
this
.
n_personname_like
=
n_personname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_personname_like
)){
this
.
getSelectCond
().
like
(
"personname"
,
n_personname_like
);
}
}
private
String
n_usercode_like
;
//[用户工号]
public
void
setN_usercode_like
(
String
n_usercode_like
)
{
this
.
n_usercode_like
=
n_usercode_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_usercode_like
)){
this
.
getSelectCond
().
like
(
"usercode"
,
n_usercode_like
);
}
}
private
String
n_mdeptid_eq
;
//[主部门]
public
void
setN_mdeptid_eq
(
String
n_mdeptid_eq
)
{
this
.
n_mdeptid_eq
=
n_mdeptid_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_mdeptid_eq
)){
this
.
getSelectCond
().
eq
(
"mdeptid"
,
n_mdeptid_eq
);
}
}
private
String
n_mdeptname_like
;
//[主部门名称]
public
void
setN_mdeptname_like
(
String
n_mdeptname_like
)
{
this
.
n_mdeptname_like
=
n_mdeptname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_mdeptname_like
)){
this
.
getSelectCond
().
like
(
"mdeptname"
,
n_mdeptname_like
);
}
}
private
String
n_bcode_like
;
//[业务编码]
public
void
setN_bcode_like
(
String
n_bcode_like
)
{
this
.
n_bcode_like
=
n_bcode_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_bcode_like
)){
this
.
getSelectCond
().
like
(
"bcode"
,
n_bcode_like
);
}
}
private
String
n_orgid_eq
;
//[单位]
public
void
setN_orgid_eq
(
String
n_orgid_eq
)
{
this
.
n_orgid_eq
=
n_orgid_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_orgid_eq
)){
this
.
getSelectCond
().
eq
(
"orgid"
,
n_orgid_eq
);
}
}
private
String
n_orgcode_leftlike
;
//[单位代码]
public
void
setN_orgcode_leftlike
(
String
n_orgcode_leftlike
)
{
this
.
n_orgcode_leftlike
=
n_orgcode_leftlike
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_orgcode_leftlike
)){
this
.
getSelectCond
().
likeRight
(
"orgcode"
,
n_orgcode_leftlike
);
}
}
private
String
n_sex_eq
;
//[性别]
public
void
setN_sex_eq
(
String
n_sex_eq
)
{
this
.
n_sex_eq
=
n_sex_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sex_eq
)){
this
.
getSelectCond
().
eq
(
"sex"
,
n_sex_eq
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSelectCond
().
or
().
like
(
"personname"
,
query
);
}
}
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/filter/IBZOrganizationSearchContext.java
浏览文件 @
71ffc6c5
...
...
@@ -17,92 +17,33 @@ import org.springframework.util.ObjectUtils;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.core.ou.domain.IBZOrganization
;
import
cn.ibizlab.util.filter.SearchContextBase
;
/**
*
关系型
数据实体[IBZOrganization] 查询条件对象
*
ServiceApi
数据实体[IBZOrganization] 查询条件对象
*/
@Slf4j
@Data
public
class
IBZOrganizationSearchContext
extends
QueryWrapperContext
<
IBZOrganization
>
{
public
class
IBZOrganizationSearchContext
extends
SearchContextBase
{
private
String
n_orgid_like
;
//[单位标识]
public
void
setN_orgid_like
(
String
n_orgid_like
)
{
this
.
n_orgid_like
=
n_orgid_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_orgid_like
)){
this
.
getSelectCond
().
like
(
"orgid"
,
n_orgid_like
);
}
}
private
String
n_orgcode_leftlike
;
//[单位代码]
public
void
setN_orgcode_leftlike
(
String
n_orgcode_leftlike
)
{
this
.
n_orgcode_leftlike
=
n_orgcode_leftlike
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_orgcode_leftlike
)){
this
.
getSelectCond
().
likeRight
(
"orgcode"
,
n_orgcode_leftlike
);
}
}
private
String
n_orgname_like
;
//[名称]
public
void
setN_orgname_like
(
String
n_orgname_like
)
{
this
.
n_orgname_like
=
n_orgname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_orgname_like
)){
this
.
getSelectCond
().
like
(
"orgname"
,
n_orgname_like
);
}
}
private
String
n_porgid_eq
;
//[上级单位]
public
void
setN_porgid_eq
(
String
n_porgid_eq
)
{
this
.
n_porgid_eq
=
n_porgid_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_porgid_eq
)){
this
.
getSelectCond
().
eq
(
"porgid"
,
n_porgid_eq
);
}
}
private
String
n_shortname_like
;
//[单位简称]
public
void
setN_shortname_like
(
String
n_shortname_like
)
{
this
.
n_shortname_like
=
n_shortname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_shortname_like
)){
this
.
getSelectCond
().
like
(
"shortname"
,
n_shortname_like
);
}
}
private
Integer
n_orglevel_gtandeq
;
//[单位级别]
public
void
setN_orglevel_gtandeq
(
Integer
n_orglevel_gtandeq
)
{
this
.
n_orglevel_gtandeq
=
n_orglevel_gtandeq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_orglevel_gtandeq
)){
this
.
getSelectCond
().
ge
(
"orglevel"
,
n_orglevel_gtandeq
);
}
}
private
Integer
n_orglevel_ltandeq
;
//[单位级别]
public
void
setN_orglevel_ltandeq
(
Integer
n_orglevel_ltandeq
)
{
this
.
n_orglevel_ltandeq
=
n_orglevel_ltandeq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_orglevel_ltandeq
)){
this
.
getSelectCond
().
le
(
"orglevel"
,
n_orglevel_ltandeq
);
}
}
private
String
n_porgname_eq
;
//[上级单位]
public
void
setN_porgname_eq
(
String
n_porgname_eq
)
{
this
.
n_porgname_eq
=
n_porgname_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_porgname_eq
)){
this
.
getSelectCond
().
eq
(
"porgname"
,
n_porgname_eq
);
}
}
private
String
n_porgname_like
;
//[上级单位]
public
void
setN_porgname_like
(
String
n_porgname_like
)
{
this
.
n_porgname_like
=
n_porgname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_porgname_like
)){
this
.
getSelectCond
().
like
(
"porgname"
,
n_porgname_like
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSelectCond
().
or
().
like
(
"orgname"
,
query
);
}
}
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/service/IIBZDepartmentService.java
浏览文件 @
71ffc6c5
...
...
@@ -18,12 +18,10 @@ import cn.ibizlab.core.ou.domain.IBZDepartment;
import
cn.ibizlab.core.ou.filter.IBZDepartmentSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[IBZDepartment] 服务对象接口
*/
public
interface
IIBZDepartmentService
extends
IService
<
IBZDepartment
>
{
public
interface
IIBZDepartmentService
{
boolean
save
(
IBZDepartment
et
)
;
@CacheEvict
(
value
=
"ibzdepartment"
,
allEntries
=
true
)
...
...
@@ -50,24 +48,8 @@ public interface IIBZDepartmentService extends IService<IBZDepartment>{
void
removeByOrgid
(
String
orgid
)
;
@CacheEvict
(
value
=
"ibzdepartment"
,
allEntries
=
true
)
void
saveByOrgid
(
String
orgid
,
List
<
IBZDepartment
>
list
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
List
<
IBZDepartment
>
getIbzdepartmentByIds
(
List
<
String
>
ids
)
;
List
<
IBZDepartment
>
getIbzdepartmentByEntities
(
List
<
IBZDepartment
>
entities
)
;
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/service/IIBZDeptMemberService.java
浏览文件 @
71ffc6c5
...
...
@@ -18,12 +18,10 @@ import cn.ibizlab.core.ou.domain.IBZDeptMember;
import
cn.ibizlab.core.ou.filter.IBZDeptMemberSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[IBZDeptMember] 服务对象接口
*/
public
interface
IIBZDeptMemberService
extends
IService
<
IBZDeptMember
>
{
public
interface
IIBZDeptMemberService
{
boolean
update
(
IBZDeptMember
et
)
;
void
updateBatch
(
List
<
IBZDeptMember
>
list
)
;
...
...
@@ -41,22 +39,8 @@ public interface IIBZDeptMemberService extends IService<IBZDeptMember>{
void
removeByDeptid
(
String
deptid
)
;
List
<
IBZDeptMember
>
selectByUserid
(
String
userid
)
;
void
removeByUserid
(
String
userid
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/service/IIBZEmployeeService.java
浏览文件 @
71ffc6c5
...
...
@@ -18,12 +18,10 @@ import cn.ibizlab.core.ou.domain.IBZEmployee;
import
cn.ibizlab.core.ou.filter.IBZEmployeeSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[IBZEmployee] 服务对象接口
*/
public
interface
IIBZEmployeeService
extends
IService
<
IBZEmployee
>
{
public
interface
IIBZEmployeeService
{
boolean
remove
(
String
key
)
;
@CacheEvict
(
value
=
"ibzemployee"
,
allEntries
=
true
)
...
...
@@ -48,24 +46,8 @@ public interface IIBZEmployeeService extends IService<IBZEmployee>{
List
<
IBZEmployee
>
selectByOrgid
(
String
orgid
)
;
@CacheEvict
(
value
=
"ibzemployee"
,
allEntries
=
true
)
void
removeByOrgid
(
String
orgid
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
List
<
IBZEmployee
>
getIbzemployeeByIds
(
List
<
String
>
ids
)
;
List
<
IBZEmployee
>
getIbzemployeeByEntities
(
List
<
IBZEmployee
>
entities
)
;
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/service/IIBZOrganizationService.java
浏览文件 @
71ffc6c5
...
...
@@ -18,12 +18,10 @@ import cn.ibizlab.core.ou.domain.IBZOrganization;
import
cn.ibizlab.core.ou.filter.IBZOrganizationSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[IBZOrganization] 服务对象接口
*/
public
interface
IIBZOrganizationService
extends
IService
<
IBZOrganization
>
{
public
interface
IIBZOrganizationService
{
boolean
save
(
IBZOrganization
et
)
;
@CacheEvict
(
value
=
"ibzorganization"
,
allEntries
=
true
)
...
...
@@ -46,24 +44,8 @@ public interface IIBZOrganizationService extends IService<IBZOrganization>{
List
<
IBZOrganization
>
selectByParentorgid
(
String
orgid
)
;
@CacheEvict
(
value
=
"ibzorganization"
,
allEntries
=
true
)
void
removeByParentorgid
(
String
orgid
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
List
<
IBZOrganization
>
getIbzorganizationByIds
(
List
<
String
>
ids
)
;
List
<
IBZOrganization
>
getIbzorganizationByEntities
(
List
<
IBZOrganization
>
entities
)
;
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/service/impl/IBZDepartmentServiceImpl.java
浏览文件 @
71ffc6c5
...
...
@@ -30,154 +30,128 @@ import cn.ibizlab.core.ou.service.IIBZDepartmentService;
import
cn.ibizlab.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.core.ou.mapper.IBZDepartmentMapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.core.ou.client.IBZDepartmentFeignClient
;
/**
* 实体[部门] 服务对象接口实现
*/
@Slf4j
@Service
(
"IBZDepartmentServiceImpl"
)
public
class
IBZDepartmentServiceImpl
extends
ServiceImpl
<
IBZDepartmentMapper
,
IBZDepartment
>
implements
IIBZDepartmentService
{
@Service
public
class
IBZDepartmentServiceImpl
implements
IIBZDepartmentService
{
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZDeptMemberService
ibzdeptmemberService
;
IBZDepartmentFeignClient
iBZDepartmentFeignClient
;
private
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZDepartmentService
ibzdepartmentService
=
this
;
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZEmployeeService
ibzemployeeService
;
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZOrganizationService
ibzorganizationService
;
private
int
batchSize
=
500
;
@Override
@Transactional
public
boolean
save
(
IBZDepartment
et
)
{
if
(!
saveOrUpdate
(
et
))
if
(
et
.
getDeptid
()==
null
)
et
.
setDeptid
((
String
)
et
.
getDefaultKey
(
true
));
if
(!
iBZDepartmentFeignClient
.
save
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
IBZDepartment
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
}
@Override
public
boolean
saveBatch
(
Collection
<
IBZDepartment
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
IBZDepartment
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
saveOrUpdateBatch
(
list
,
batchSize
);
iBZDepartmentFeignClient
.
saveBatch
(
list
)
;
}
@Override
@Transactional
public
IBZDepartment
get
(
String
key
)
{
IBZDepartment
et
=
getById
(
key
);
public
IBZDepartment
get
(
String
deptid
)
{
IBZDepartment
et
=
iBZDepartmentFeignClient
.
get
(
deptid
);
if
(
et
==
null
){
et
=
new
IBZDepartment
();
et
.
setDeptid
(
key
);
et
.
setDeptid
(
deptid
);
}
else
{
}
return
et
;
return
et
;
}
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
return
result
;
public
boolean
remove
(
String
deptid
)
{
boolean
result
=
iBZDepartmentFeignClient
.
remove
(
deptid
)
;
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
public
void
removeBatch
(
Collection
<
String
>
idList
){
iBZDepartmentFeignClient
.
removeBatch
(
idList
);
}
@Override
public
boolean
checkKey
(
IBZDepartment
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getDeptid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getDeptid
()))
);
return
iBZDepartmentFeignClient
.
checkKey
(
et
);
}
@Override
@Transactional
public
boolean
update
(
IBZDepartment
et
)
{
fillParentData
(
et
);
if
(
!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"deptid"
,
et
.
getDeptid
()))
)
IBZDepartment
rt
=
iBZDepartmentFeignClient
.
update
(
et
.
getDeptid
(),
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getDeptid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
IBZDepartment
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
updateBatchById
(
list
,
batchSize
);
public
void
updateBatch
(
List
<
IBZDepartment
>
list
){
iBZDepartmentFeignClient
.
updateBatch
(
list
)
;
}
@Override
@Transactional
public
boolean
create
(
IBZDepartment
et
)
{
fillParentData
(
et
);
if
(
!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
))
)
IBZDepartment
rt
=
iBZDepartmentFeignClient
.
create
(
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getDeptid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
IBZDepartment
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
this
.
saveBatch
(
list
,
batchSize
);
public
void
createBatch
(
List
<
IBZDepartment
>
list
){
iBZDepartmentFeignClient
.
createBatch
(
list
)
;
}
@Override
public
IBZDepartment
getDraft
(
IBZDepartment
et
)
{
fillParentData
(
et
);
et
=
iBZDepartmentFeignClient
.
getDraft
(
);
return
et
;
}
@Override
public
List
<
IBZDepartment
>
selectByParentdeptid
(
String
deptid
)
{
return
baseMapper
.
selectByParentdeptid
(
deptid
);
IBZDepartmentSearchContext
context
=
new
IBZDepartmentSearchContext
();
context
.
setSize
(
Integer
.
MAX_VALUE
);
context
.
setN_pdeptid_eq
(
deptid
);
return
iBZDepartmentFeignClient
.
searchDefault
(
context
).
getContent
();
}
@Override
public
void
removeByParentdeptid
(
String
deptid
)
{
this
.
remove
(
new
QueryWrapper
<
IBZDepartment
>().
eq
(
"pdeptid"
,
deptid
));
Set
<
String
>
delIds
=
new
HashSet
<
String
>();
for
(
IBZDepartment
before:
selectByParentdeptid
(
deptid
)){
delIds
.
add
(
before
.
getDeptid
());
}
if
(
delIds
.
size
()>
0
)
this
.
removeBatch
(
delIds
);
}
@Override
public
List
<
IBZDepartment
>
selectByOrgid
(
String
orgid
)
{
return
baseMapper
.
selectByOrgid
(
orgid
);
IBZDepartmentSearchContext
context
=
new
IBZDepartmentSearchContext
();
context
.
setSize
(
Integer
.
MAX_VALUE
);
context
.
setN_orgid_eq
(
orgid
);
return
iBZDepartmentFeignClient
.
searchDefault
(
context
).
getContent
();
}
@Override
public
void
removeByOrgid
(
String
orgid
)
{
this
.
remove
(
new
QueryWrapper
<
IBZDepartment
>().
eq
(
"orgid"
,
orgid
));
Set
<
String
>
delIds
=
new
HashSet
<
String
>();
for
(
IBZDepartment
before:
selectByOrgid
(
orgid
)){
delIds
.
add
(
before
.
getDeptid
());
}
if
(
delIds
.
size
()>
0
)
this
.
removeBatch
(
delIds
);
}
@Override
...
...
@@ -210,13 +184,14 @@ public class IBZDepartmentServiceImpl extends ServiceImpl<IBZDepartmentMapper, I
}
/**
* 查询集合 CurDept
*/
@Override
public
Page
<
IBZDepartment
>
searchCurDept
(
IBZDepartmentSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
IBZDepartment
>
pages
=
baseMapper
.
searchCurDept
(
context
.
getPages
(),
context
,
context
.
getSelectCond
()
);
return
new
PageImpl
<
IBZDepartment
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
())
;
Page
<
IBZDepartment
>
iBZDepartments
=
iBZDepartmentFeignClient
.
searchCurDept
(
context
);
return
iBZDepartments
;
}
/**
...
...
@@ -224,82 +199,10 @@ public class IBZDepartmentServiceImpl extends ServiceImpl<IBZDepartmentMapper, I
*/
@Override
public
Page
<
IBZDepartment
>
searchDefault
(
IBZDepartmentSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
IBZDepartment
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
());
return
new
PageImpl
<
IBZDepartment
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
());
}
/**
* 为当前实体填充父数据(外键值文本、外键值附加数据)
* @param et
*/
private
void
fillParentData
(
IBZDepartment
et
){
//实体关系[DER1N_IBZDEPT_IBZDEPT_PDEPTID]
if
(!
ObjectUtils
.
isEmpty
(
et
.
getParentdeptid
())){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZDepartment
parentdept
=
et
.
getParentdept
();
if
(
ObjectUtils
.
isEmpty
(
parentdept
)){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZDepartment
majorEntity
=
ibzdepartmentService
.
get
(
et
.
getParentdeptid
());
et
.
setParentdept
(
majorEntity
);
parentdept
=
majorEntity
;
}
et
.
setParentdeptname
(
parentdept
.
getDeptname
());
}
//实体关系[DER1N_IBZDEPT_IBZORG_ORGID]
if
(!
ObjectUtils
.
isEmpty
(
et
.
getOrgid
())){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZOrganization
org
=
et
.
getOrg
();
if
(
ObjectUtils
.
isEmpty
(
org
)){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZOrganization
majorEntity
=
ibzorganizationService
.
get
(
et
.
getOrgid
());
et
.
setOrg
(
majorEntity
);
org
=
majorEntity
;
}
et
.
setOrgname
(
org
.
getOrgname
());
}
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
}
@Override
public
List
<
IBZDepartment
>
getIbzdepartmentByIds
(
List
<
String
>
ids
)
{
return
this
.
listByIds
(
ids
);
Page
<
IBZDepartment
>
iBZDepartments
=
iBZDepartmentFeignClient
.
searchDefault
(
context
);
return
iBZDepartments
;
}
@Override
public
List
<
IBZDepartment
>
getIbzdepartmentByEntities
(
List
<
IBZDepartment
>
entities
)
{
List
ids
=
new
ArrayList
();
for
(
IBZDepartment
entity
:
entities
){
Serializable
id
=
entity
.
getDeptid
();
if
(!
ObjectUtils
.
isEmpty
(
id
)){
ids
.
add
(
id
);
}
}
if
(
ids
.
size
()>
0
)
return
this
.
listByIds
(
ids
);
else
return
entities
;
}
}
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/ou/service/impl/IBZDeptMemberServiceImpl.java
浏览文件 @
71ffc6c5
...
...
@@ -30,212 +30,139 @@ import cn.ibizlab.core.ou.service.IIBZDeptMemberService;
import
cn.ibizlab.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.core.ou.mapper.IBZDeptMemberMapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.core.ou.client.IBZDeptMemberFeignClient
;
/**
* 实体[部门成员] 服务对象接口实现
*/
@Slf4j
@Service
(
"IBZDeptMemberServiceImpl"
)
public
class
IBZDeptMemberServiceImpl
extends
ServiceImpl
<
IBZDeptMemberMapper
,
IBZDeptMember
>
implements
IIBZDeptMemberService
{
@Service
public
class
IBZDeptMemberServiceImpl
implements
IIBZDeptMemberService
{
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZDepartmentService
ibzdepartmentService
;
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZEmployeeService
ibzemployeeService
;
IBZDeptMemberFeignClient
iBZDeptMemberFeignClient
;
private
int
batchSize
=
500
;
@Override
@Transactional
public
boolean
update
(
IBZDeptMember
et
)
{
fillParentData
(
et
);
if
(
!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"memberid"
,
et
.
getMemberid
()))
)
IBZDeptMember
rt
=
iBZDeptMemberFeignClient
.
update
(
et
.
getMemberid
(),
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getMemberid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
IBZDeptMember
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
updateBatchById
(
list
,
batchSize
);
public
void
updateBatch
(
List
<
IBZDeptMember
>
list
){
iBZDeptMemberFeignClient
.
updateBatch
(
list
)
;
}
@Override
@Transactional
public
IBZDeptMember
get
(
String
key
)
{
IBZDeptMember
et
=
getById
(
key
);
public
IBZDeptMember
get
(
String
memberid
)
{
IBZDeptMember
et
=
iBZDeptMemberFeignClient
.
get
(
memberid
);
if
(
et
==
null
){
et
=
new
IBZDeptMember
();
et
.
setMemberid
(
key
);
et
.
setMemberid
(
memberid
);
}
else
{
}
return
et
;
return
et
;
}
@Override
public
boolean
checkKey
(
IBZDeptMember
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getMemberid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getMemberid
()))
);
return
iBZDeptMemberFeignClient
.
checkKey
(
et
);
}
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
return
result
;
public
boolean
remove
(
String
memberid
)
{
boolean
result
=
iBZDeptMemberFeignClient
.
remove
(
memberid
)
;
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
public
void
removeBatch
(
Collection
<
String
>
idList
){
iBZDeptMemberFeignClient
.
removeBatch
(
idList
);
}
@Override
@Transactional
public
boolean
create
(
IBZDeptMember
et
)
{
fillParentData
(
et
);
if
(
!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
))
)
IBZDeptMember
rt
=
iBZDeptMemberFeignClient
.
create
(
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getMemberid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
IBZDeptMember
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
this
.
saveOrUpdateBatch
(
list
,
batchSize
);
public
void
createBatch
(
List
<
IBZDeptMember
>
list
){
iBZDeptMemberFeignClient
.
createBatch
(
list
)
;
}
@Override
public
IBZDeptMember
getDraft
(
IBZDeptMember
et
)
{
fillParentData
(
et
);
et
=
iBZDeptMemberFeignClient
.
getDraft
(
);
return
et
;
}
@Override
@Transactional
public
boolean
save
(
IBZDeptMember
et
)
{
if
(!
saveOrUpdate
(
et
))
if
(
et
.
getMemberid
()==
null
)
et
.
setMemberid
((
String
)
et
.
getDefaultKey
(
true
));
if
(!
iBZDeptMemberFeignClient
.
save
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
IBZDeptMember
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
}
@Override
public
boolean
saveBatch
(
Collection
<
IBZDeptMember
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
IBZDeptMember
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
saveOrUpdateBatch
(
list
,
batchSize
);
iBZDeptMemberFeignClient
.
saveBatch
(
list
)
;
}
@Override
public
List
<
IBZDeptMember
>
selectByDeptid
(
String
deptid
)
{
return
baseMapper
.
selectByDeptid
(
deptid
);
IBZDeptMemberSearchContext
context
=
new
IBZDeptMemberSearchContext
();
context
.
setSize
(
Integer
.
MAX_VALUE
);
context
.
setN_deptid_eq
(
deptid
);
return
iBZDeptMemberFeignClient
.
searchDefault
(
context
).
getContent
();
}
@Override
public
void
removeByDeptid
(
String
deptid
)
{
this
.
remove
(
new
QueryWrapper
<
IBZDeptMember
>().
eq
(
"deptid"
,
deptid
));
Set
<
String
>
delIds
=
new
HashSet
<
String
>();
for
(
IBZDeptMember
before:
selectByDeptid
(
deptid
)){
delIds
.
add
(
before
.
getMemberid
());
}
if
(
delIds
.
size
()>
0
)
this
.
removeBatch
(
delIds
);
}
@Override
public
List
<
IBZDeptMember
>
selectByUserid
(
String
userid
)
{
return
baseMapper
.
selectByUserid
(
userid
);
IBZDeptMemberSearchContext
context
=
new
IBZDeptMemberSearchContext
();
context
.
setSize
(
Integer
.
MAX_VALUE
);
context
.
setN_userid_eq
(
userid
);
return
iBZDeptMemberFeignClient
.
searchDefault
(
context
).
getContent
();
}
@Override
public
void
removeByUserid
(
String
userid
)
{
this
.
remove
(
new
QueryWrapper
<
IBZDeptMember
>().
eq
(
"userid"
,
userid
));
Set
<
String
>
delIds
=
new
HashSet
<
String
>();
for
(
IBZDeptMember
before:
selectByUserid
(
userid
)){
delIds
.
add
(
before
.
getMemberid
());
}
if
(
delIds
.
size
()>
0
)
this
.
removeBatch
(
delIds
);
}
/**
* 查询集合 DEFAULT
*/
@Override
public
Page
<
IBZDeptMember
>
searchDefault
(
IBZDeptMemberSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
IBZDeptMember
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
());
return
new
PageImpl
<
IBZDeptMember
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
());
}
/**
* 为当前实体填充父数据(外键值文本、外键值附加数据)
* @param et
*/
private
void
fillParentData
(
IBZDeptMember
et
){
//实体关系[DER1N_IBZDEPTMEMBER_IBZDEPT_DEPTID]
if
(!
ObjectUtils
.
isEmpty
(
et
.
getDeptid
())){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZDepartment
dept
=
et
.
getDept
();
if
(
ObjectUtils
.
isEmpty
(
dept
)){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZDepartment
majorEntity
=
ibzdepartmentService
.
get
(
et
.
getDeptid
());
et
.
setDept
(
majorEntity
);
dept
=
majorEntity
;
}
et
.
setDeptname
(
dept
.
getDeptname
());
}
//实体关系[DER1N_IBZDEPTMEMBER_IBZEMP_USERID]
if
(!
ObjectUtils
.
isEmpty
(
et
.
getUserid
())){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZEmployee
emp
=
et
.
getEmp
();
if
(
ObjectUtils
.
isEmpty
(
emp
)){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZEmployee
majorEntity
=
ibzemployeeService
.
get
(
et
.
getUserid
());
et
.
setEmp
(
majorEntity
);
emp
=
majorEntity
;
}
et
.
setPersonname
(
emp
.
getPersonname
());
}
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
Page
<
IBZDeptMember
>
iBZDeptMembers
=
iBZDeptMemberFeignClient
.
searchDefault
(
context
);
return
iBZDeptMembers
;
}
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/ou/service/impl/IBZEmployeeServiceImpl.java
浏览文件 @
71ffc6c5
...
...
@@ -30,114 +30,72 @@ import cn.ibizlab.core.ou.service.IIBZEmployeeService;
import
cn.ibizlab.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.core.ou.mapper.IBZEmployeeMapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.core.ou.client.IBZEmployeeFeignClient
;
/**
* 实体[人员] 服务对象接口实现
*/
@Slf4j
@Service
(
"IBZEmployeeServiceImpl"
)
public
class
IBZEmployeeServiceImpl
extends
ServiceImpl
<
IBZEmployeeMapper
,
IBZEmployee
>
implements
IIBZEmployeeService
{
@Service
public
class
IBZEmployeeServiceImpl
implements
IIBZEmployeeService
{
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZDeptMemberService
ibzdeptmemberService
;
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZDepartmentService
ibzdepartmentService
;
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZOrganizationService
ibzorganizationService
;
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
ou
.
service
.
logic
.
IIBZEmployeesaveDeptMemberLogic
savedeptmemberLogic
;
IBZEmployeeFeignClient
iBZEmployeeFeignClient
;
private
int
batchSize
=
500
;
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
return
result
;
public
boolean
remove
(
String
userid
)
{
boolean
result
=
iBZEmployeeFeignClient
.
remove
(
userid
)
;
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
public
void
removeBatch
(
Collection
<
String
>
idList
){
iBZEmployeeFeignClient
.
removeBatch
(
idList
);
}
@Override
@Transactional
public
boolean
update
(
IBZEmployee
et
)
{
fillParentData
(
et
);
if
(
!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"userid"
,
et
.
getUserid
()))
)
IBZEmployee
rt
=
iBZEmployeeFeignClient
.
update
(
et
.
getUserid
(),
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getUserid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
savedeptmemberLogic
.
execute
(
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
IBZEmployee
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
updateBatchById
(
list
,
batchSize
);
public
void
updateBatch
(
List
<
IBZEmployee
>
list
){
iBZEmployeeFeignClient
.
updateBatch
(
list
)
;
}
@Override
public
boolean
checkKey
(
IBZEmployee
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getUserid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getUserid
()))
);
return
iBZEmployeeFeignClient
.
checkKey
(
et
);
}
@Override
@Transactional
public
IBZEmployee
get
(
String
key
)
{
IBZEmployee
et
=
getById
(
key
);
public
IBZEmployee
get
(
String
userid
)
{
IBZEmployee
et
=
iBZEmployeeFeignClient
.
get
(
userid
);
if
(
et
==
null
){
et
=
new
IBZEmployee
();
et
.
setUserid
(
key
);
et
.
setUserid
(
userid
);
}
else
{
}
return
et
;
return
et
;
}
@Override
@Transactional
public
boolean
save
(
IBZEmployee
et
)
{
if
(!
saveOrUpdate
(
et
))
if
(
et
.
getUserid
()==
null
)
et
.
setUserid
((
String
)
et
.
getDefaultKey
(
true
));
if
(!
iBZEmployeeFeignClient
.
save
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
IBZEmployee
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
}
@Override
public
boolean
saveBatch
(
Collection
<
IBZEmployee
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
IBZEmployee
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
saveOrUpdateBatch
(
list
,
batchSize
);
iBZEmployeeFeignClient
.
saveBatch
(
list
)
;
}
@Override
...
...
@@ -149,133 +107,74 @@ public class IBZEmployeeServiceImpl extends ServiceImpl<IBZEmployeeMapper, IBZEm
@Override
public
IBZEmployee
getDraft
(
IBZEmployee
et
)
{
fillParentData
(
et
);
et
=
iBZEmployeeFeignClient
.
getDraft
(
);
return
et
;
}
@Override
@Transactional
public
boolean
create
(
IBZEmployee
et
)
{
fillParentData
(
et
);
if
(
!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
))
)
IBZEmployee
rt
=
iBZEmployeeFeignClient
.
create
(
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getUserid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
savedeptmemberLogic
.
execute
(
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
IBZEmployee
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
this
.
saveBatch
(
list
,
batchSize
);
public
void
createBatch
(
List
<
IBZEmployee
>
list
){
iBZEmployeeFeignClient
.
createBatch
(
list
)
;
}
@Override
public
List
<
IBZEmployee
>
selectByMdeptid
(
String
deptid
)
{
return
baseMapper
.
selectByMdeptid
(
deptid
);
IBZEmployeeSearchContext
context
=
new
IBZEmployeeSearchContext
();
context
.
setSize
(
Integer
.
MAX_VALUE
);
context
.
setN_mdeptid_eq
(
deptid
);
return
iBZEmployeeFeignClient
.
searchDefault
(
context
).
getContent
();
}
@Override
public
void
removeByMdeptid
(
String
deptid
)
{
this
.
remove
(
new
QueryWrapper
<
IBZEmployee
>().
eq
(
"mdeptid"
,
deptid
));
Set
<
String
>
delIds
=
new
HashSet
<
String
>();
for
(
IBZEmployee
before:
selectByMdeptid
(
deptid
)){
delIds
.
add
(
before
.
getUserid
());
}
if
(
delIds
.
size
()>
0
)
this
.
removeBatch
(
delIds
);
}
@Override
public
List
<
IBZEmployee
>
selectByOrgid
(
String
orgid
)
{
return
baseMapper
.
selectByOrgid
(
orgid
);
IBZEmployeeSearchContext
context
=
new
IBZEmployeeSearchContext
();
context
.
setSize
(
Integer
.
MAX_VALUE
);
context
.
setN_orgid_eq
(
orgid
);
return
iBZEmployeeFeignClient
.
searchDefault
(
context
).
getContent
();
}
@Override
public
void
removeByOrgid
(
String
orgid
)
{
this
.
remove
(
new
QueryWrapper
<
IBZEmployee
>().
eq
(
"orgid"
,
orgid
));
Set
<
String
>
delIds
=
new
HashSet
<
String
>();
for
(
IBZEmployee
before:
selectByOrgid
(
orgid
)){
delIds
.
add
(
before
.
getUserid
());
}
if
(
delIds
.
size
()>
0
)
this
.
removeBatch
(
delIds
);
}
/**
* 查询集合 DEFAULT
*/
@Override
public
Page
<
IBZEmployee
>
searchDefault
(
IBZEmployeeSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
IBZEmployee
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
()
);
return
new
PageImpl
<
IBZEmployee
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
())
;
Page
<
IBZEmployee
>
iBZEmployees
=
iBZEmployeeFeignClient
.
searchDefault
(
context
);
return
iBZEmployees
;
}
/**
* 为当前实体填充父数据(外键值文本、外键值附加数据)
* @param et
*/
private
void
fillParentData
(
IBZEmployee
et
){
//实体关系[DER1N_IBZEMP_IBZDEPT_MDEPTID]
if
(!
ObjectUtils
.
isEmpty
(
et
.
getMdeptid
())){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZDepartment
maindept
=
et
.
getMaindept
();
if
(
ObjectUtils
.
isEmpty
(
maindept
)){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZDepartment
majorEntity
=
ibzdepartmentService
.
get
(
et
.
getMdeptid
());
et
.
setMaindept
(
majorEntity
);
maindept
=
majorEntity
;
}
et
.
setMdeptcode
(
maindept
.
getDeptcode
());
et
.
setMdeptname
(
maindept
.
getDeptname
());
}
//实体关系[DER1N_IBZEMP_IBZORG_ORGID]
if
(!
ObjectUtils
.
isEmpty
(
et
.
getOrgid
())){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZOrganization
org
=
et
.
getOrg
();
if
(
ObjectUtils
.
isEmpty
(
org
)){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZOrganization
majorEntity
=
ibzorganizationService
.
get
(
et
.
getOrgid
());
et
.
setOrg
(
majorEntity
);
org
=
majorEntity
;
}
et
.
setOrgcode
(
org
.
getOrgcode
());
et
.
setOrgname
(
org
.
getOrgname
());
}
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
}
@Override
public
List
<
IBZEmployee
>
getIbzemployeeByIds
(
List
<
String
>
ids
)
{
return
this
.
listByIds
(
ids
);
}
@Override
public
List
<
IBZEmployee
>
getIbzemployeeByEntities
(
List
<
IBZEmployee
>
entities
)
{
List
ids
=
new
ArrayList
();
for
(
IBZEmployee
entity
:
entities
){
Serializable
id
=
entity
.
getUserid
();
if
(!
ObjectUtils
.
isEmpty
(
id
)){
ids
.
add
(
id
);
}
}
if
(
ids
.
size
()>
0
)
return
this
.
listByIds
(
ids
);
else
return
entities
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/service/impl/IBZOrganizationServiceImpl.java
浏览文件 @
71ffc6c5
...
...
@@ -30,155 +30,121 @@ import cn.ibizlab.core.ou.service.IIBZOrganizationService;
import
cn.ibizlab.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.core.ou.mapper.IBZOrganizationMapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.core.ou.client.IBZOrganizationFeignClient
;
/**
* 实体[单位机构] 服务对象接口实现
*/
@Slf4j
@Service
(
"IBZOrganizationServiceImpl"
)
public
class
IBZOrganizationServiceImpl
extends
ServiceImpl
<
IBZOrganizationMapper
,
IBZOrganization
>
implements
IIBZOrganizationService
{
@Service
public
class
IBZOrganizationServiceImpl
implements
IIBZOrganizationService
{
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZDepartmentService
ibzdepartmentService
;
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZEmployeeService
ibzemployeeService
;
private
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZOrganizationService
ibzorganizationService
=
this
;
IBZOrganizationFeignClient
iBZOrganizationFeignClient
;
private
int
batchSize
=
500
;
@Override
@Transactional
public
boolean
save
(
IBZOrganization
et
)
{
if
(!
saveOrUpdate
(
et
))
if
(
et
.
getOrgid
()==
null
)
et
.
setOrgid
((
String
)
et
.
getDefaultKey
(
true
));
if
(!
iBZOrganizationFeignClient
.
save
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
IBZOrganization
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
}
@Override
public
boolean
saveBatch
(
Collection
<
IBZOrganization
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
IBZOrganization
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
saveOrUpdateBatch
(
list
,
batchSize
);
iBZOrganizationFeignClient
.
saveBatch
(
list
)
;
}
@Override
public
boolean
checkKey
(
IBZOrganization
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getOrgid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getOrgid
()))
);
return
iBZOrganizationFeignClient
.
checkKey
(
et
);
}
@Override
@Transactional
public
IBZOrganization
get
(
String
key
)
{
IBZOrganization
et
=
getById
(
key
);
public
IBZOrganization
get
(
String
orgid
)
{
IBZOrganization
et
=
iBZOrganizationFeignClient
.
get
(
orgid
);
if
(
et
==
null
){
et
=
new
IBZOrganization
();
et
.
setOrgid
(
key
);
et
.
setOrgid
(
orgid
);
}
else
{
et
.
setDepts
(
ibzdepartmentService
.
selectByOrgid
(
key
));
}
return
et
;
return
et
;
}
@Override
@Transactional
public
boolean
create
(
IBZOrganization
et
)
{
fillParentData
(
et
);
if
(
!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
))
)
IBZOrganization
rt
=
iBZOrganizationFeignClient
.
create
(
et
);
if
(
rt
==
null
)
return
false
;
ibzdepartmentService
.
saveByOrgid
(
et
.
getOrgid
(),
et
.
getDepts
());
CachedBeanCopier
.
copy
(
get
(
et
.
getOrgid
()),
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
IBZOrganization
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
this
.
saveBatch
(
list
,
batchSize
);
public
void
createBatch
(
List
<
IBZOrganization
>
list
){
iBZOrganizationFeignClient
.
createBatch
(
list
)
;
}
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
ibzdepartmentService
.
removeByOrgid
(
key
)
;
boolean
result
=
removeById
(
key
);
return
result
;
public
boolean
remove
(
String
orgid
)
{
boolean
result
=
iBZOrganizationFeignClient
.
remove
(
orgid
)
;
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
public
void
removeBatch
(
Collection
<
String
>
idList
){
iBZOrganizationFeignClient
.
removeBatch
(
idList
);
}
@Override
public
IBZOrganization
getDraft
(
IBZOrganization
et
)
{
fillParentData
(
et
);
et
=
iBZOrganizationFeignClient
.
getDraft
(
);
return
et
;
}
@Override
@Transactional
public
boolean
update
(
IBZOrganization
et
)
{
fillParentData
(
et
);
if
(
!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"orgid"
,
et
.
getOrgid
()))
)
IBZOrganization
rt
=
iBZOrganizationFeignClient
.
update
(
et
.
getOrgid
(),
et
);
if
(
rt
==
null
)
return
false
;
ibzdepartmentService
.
saveByOrgid
(
et
.
getOrgid
(),
et
.
getDepts
());
CachedBeanCopier
.
copy
(
get
(
et
.
getOrgid
()),
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
IBZOrganization
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
updateBatchById
(
list
,
batchSize
);
public
void
updateBatch
(
List
<
IBZOrganization
>
list
){
iBZOrganizationFeignClient
.
updateBatch
(
list
)
;
}
@Override
public
List
<
IBZOrganization
>
selectByParentorgid
(
String
orgid
)
{
return
baseMapper
.
selectByParentorgid
(
orgid
);
IBZOrganizationSearchContext
context
=
new
IBZOrganizationSearchContext
();
context
.
setSize
(
Integer
.
MAX_VALUE
);
context
.
setN_porgid_eq
(
orgid
);
return
iBZOrganizationFeignClient
.
searchDefault
(
context
).
getContent
();
}
@Override
public
void
removeByParentorgid
(
String
orgid
)
{
this
.
remove
(
new
QueryWrapper
<
IBZOrganization
>().
eq
(
"porgid"
,
orgid
));
Set
<
String
>
delIds
=
new
HashSet
<
String
>();
for
(
IBZOrganization
before:
selectByParentorgid
(
orgid
)){
delIds
.
add
(
before
.
getOrgid
());
}
if
(
delIds
.
size
()>
0
)
this
.
removeBatch
(
delIds
);
}
/**
* 查询集合 DEFAULT
*/
@Override
public
Page
<
IBZOrganization
>
searchDefault
(
IBZOrganizationSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
IBZOrganization
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
()
);
return
new
PageImpl
<
IBZOrganization
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
())
;
Page
<
IBZOrganization
>
iBZOrganizations
=
iBZOrganizationFeignClient
.
searchDefault
(
context
);
return
iBZOrganizations
;
}
/**
...
...
@@ -186,8 +152,8 @@ public class IBZOrganizationServiceImpl extends ServiceImpl<IBZOrganizationMappe
*/
@Override
public
Page
<
IBZOrganization
>
searchSelectPOrg
(
IBZOrganizationSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
IBZOrganization
>
pages
=
baseMapper
.
searchSelectPOrg
(
context
.
getPages
(),
context
,
context
.
getSelectCond
()
);
return
new
PageImpl
<
IBZOrganization
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
())
;
Page
<
IBZOrganization
>
iBZOrganizations
=
iBZOrganizationFeignClient
.
searchSelectPOrg
(
context
);
return
iBZOrganizations
;
}
/**
...
...
@@ -195,72 +161,10 @@ public class IBZOrganizationServiceImpl extends ServiceImpl<IBZOrganizationMappe
*/
@Override
public
Page
<
IBZOrganization
>
searchSelectSOrg
(
IBZOrganizationSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
IBZOrganization
>
pages
=
baseMapper
.
searchSelectSOrg
(
context
.
getPages
(),
context
,
context
.
getSelectCond
());
return
new
PageImpl
<
IBZOrganization
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
());
}
/**
* 为当前实体填充父数据(外键值文本、外键值附加数据)
* @param et
*/
private
void
fillParentData
(
IBZOrganization
et
){
//实体关系[DER1N_IBZORG_IBZORG_PORGID]
if
(!
ObjectUtils
.
isEmpty
(
et
.
getParentorgid
())){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZOrganization
parentorg
=
et
.
getParentorg
();
if
(
ObjectUtils
.
isEmpty
(
parentorg
)){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZOrganization
majorEntity
=
ibzorganizationService
.
get
(
et
.
getParentorgid
());
et
.
setParentorg
(
majorEntity
);
parentorg
=
majorEntity
;
}
et
.
setParentorgname
(
parentorg
.
getOrgname
());
}
Page
<
IBZOrganization
>
iBZOrganizations
=
iBZOrganizationFeignClient
.
searchSelectSOrg
(
context
);
return
iBZOrganizations
;
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
}
@Override
public
List
<
IBZOrganization
>
getIbzorganizationByIds
(
List
<
String
>
ids
)
{
return
this
.
listByIds
(
ids
);
}
@Override
public
List
<
IBZOrganization
>
getIbzorganizationByEntities
(
List
<
IBZOrganization
>
entities
)
{
List
ids
=
new
ArrayList
();
for
(
IBZOrganization
entity
:
entities
){
Serializable
id
=
entity
.
getOrgid
();
if
(!
ObjectUtils
.
isEmpty
(
id
)){
ids
.
add
(
id
);
}
}
if
(
ids
.
size
()>
0
)
return
this
.
listByIds
(
ids
);
else
return
entities
;
}
}
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/client/SysAuthLogFallback.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
uaa
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.uaa.domain.SysAuthLog
;
import
cn.ibizlab.core.uaa.filter.SysAuthLogSearchContext
;
import
org.springframework.stereotype.Component
;
/**
* 实体[SysAuthLog] 服务对象接口
*/
@Component
public
class
SysAuthLogFallback
implements
SysAuthLogFeignClient
{
public
Page
<
SysAuthLog
>
select
(){
return
null
;
}
public
Boolean
checkKey
(
SysAuthLog
sysauthlog
){
return
false
;
}
public
Boolean
remove
(
String
logid
){
return
false
;
}
public
Boolean
removeBatch
(
Collection
<
String
>
idList
){
return
false
;
}
public
SysAuthLog
getDraft
(){
return
null
;
}
public
SysAuthLog
update
(
String
logid
,
SysAuthLog
sysauthlog
){
return
null
;
}
public
Boolean
updateBatch
(
List
<
SysAuthLog
>
sysauthlogs
){
return
false
;
}
public
Boolean
save
(
SysAuthLog
sysauthlog
){
return
false
;
}
public
Boolean
saveBatch
(
List
<
SysAuthLog
>
sysauthlogs
){
return
false
;
}
public
SysAuthLog
create
(
SysAuthLog
sysauthlog
){
return
null
;
}
public
Boolean
createBatch
(
List
<
SysAuthLog
>
sysauthlogs
){
return
false
;
}
public
SysAuthLog
get
(
String
logid
){
return
null
;
}
public
Page
<
SysAuthLog
>
searchDefault
(
SysAuthLogSearchContext
context
){
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/client/SysAuthLogFeignClient.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
uaa
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.uaa.domain.SysAuthLog
;
import
cn.ibizlab.core.uaa.filter.SysAuthLogSearchContext
;
import
org.springframework.cloud.openfeign.FeignClient
;
/**
* 实体[SysAuthLog] 服务对象接口
*/
@FeignClient
(
value
=
"ibzuaa-api"
,
contextId
=
"SysAuthLog"
,
fallback
=
SysAuthLogFallback
.
class
)
public
interface
SysAuthLogFeignClient
{
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysauthlogs/select"
)
Page
<
SysAuthLog
>
select
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysauthlogs/checkkey"
)
Boolean
checkKey
(
@RequestBody
SysAuthLog
sysauthlog
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysauthlogs/{logid}"
)
Boolean
remove
(
@PathVariable
(
"logid"
)
String
logid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysauthlogs/batch}"
)
Boolean
removeBatch
(
@RequestBody
Collection
<
String
>
idList
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysauthlogs/getdraft"
)
SysAuthLog
getDraft
();
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysauthlogs/{logid}"
)
SysAuthLog
update
(
@PathVariable
(
"logid"
)
String
logid
,
@RequestBody
SysAuthLog
sysauthlog
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysauthlogs/batch"
)
Boolean
updateBatch
(
@RequestBody
List
<
SysAuthLog
>
sysauthlogs
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysauthlogs/save"
)
Boolean
save
(
@RequestBody
SysAuthLog
sysauthlog
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysauthlogs/save"
)
Boolean
saveBatch
(
@RequestBody
List
<
SysAuthLog
>
sysauthlogs
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysauthlogs"
)
SysAuthLog
create
(
@RequestBody
SysAuthLog
sysauthlog
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysauthlogs/batch"
)
Boolean
createBatch
(
@RequestBody
List
<
SysAuthLog
>
sysauthlogs
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysauthlogs/{logid}"
)
SysAuthLog
get
(
@PathVariable
(
"logid"
)
String
logid
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysauthlogs/searchdefault"
)
Page
<
SysAuthLog
>
searchDefault
(
@RequestBody
SysAuthLogSearchContext
context
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/client/SysPSSystemFallback.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
uaa
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.uaa.domain.SysPSSystem
;
import
cn.ibizlab.core.uaa.filter.SysPSSystemSearchContext
;
import
org.springframework.stereotype.Component
;
/**
* 实体[SysPSSystem] 服务对象接口
*/
@Component
public
class
SysPSSystemFallback
implements
SysPSSystemFeignClient
{
public
Page
<
SysPSSystem
>
select
(){
return
null
;
}
public
SysPSSystem
get
(
String
pssystemid
){
return
null
;
}
public
SysPSSystem
update
(
String
pssystemid
,
SysPSSystem
syspssystem
){
return
null
;
}
public
Boolean
updateBatch
(
List
<
SysPSSystem
>
syspssystems
){
return
false
;
}
public
Boolean
checkKey
(
SysPSSystem
syspssystem
){
return
false
;
}
public
Boolean
remove
(
String
pssystemid
){
return
false
;
}
public
Boolean
removeBatch
(
Collection
<
String
>
idList
){
return
false
;
}
public
SysPSSystem
create
(
SysPSSystem
syspssystem
){
return
null
;
}
public
Boolean
createBatch
(
List
<
SysPSSystem
>
syspssystems
){
return
false
;
}
public
SysPSSystem
getDraft
(){
return
null
;
}
public
Boolean
save
(
SysPSSystem
syspssystem
){
return
false
;
}
public
Boolean
saveBatch
(
List
<
SysPSSystem
>
syspssystems
){
return
false
;
}
public
Page
<
SysPSSystem
>
searchDefault
(
SysPSSystemSearchContext
context
){
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/client/SysPSSystemFeignClient.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
uaa
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.uaa.domain.SysPSSystem
;
import
cn.ibizlab.core.uaa.filter.SysPSSystemSearchContext
;
import
org.springframework.cloud.openfeign.FeignClient
;
/**
* 实体[SysPSSystem] 服务对象接口
*/
@FeignClient
(
value
=
"ibzuaa-api"
,
contextId
=
"SysPSSystem"
,
fallback
=
SysPSSystemFallback
.
class
)
public
interface
SysPSSystemFeignClient
{
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/syspssystems/select"
)
Page
<
SysPSSystem
>
select
();
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/syspssystems/{pssystemid}"
)
SysPSSystem
get
(
@PathVariable
(
"pssystemid"
)
String
pssystemid
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/syspssystems/{pssystemid}"
)
SysPSSystem
update
(
@PathVariable
(
"pssystemid"
)
String
pssystemid
,
@RequestBody
SysPSSystem
syspssystem
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/syspssystems/batch"
)
Boolean
updateBatch
(
@RequestBody
List
<
SysPSSystem
>
syspssystems
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/syspssystems/checkkey"
)
Boolean
checkKey
(
@RequestBody
SysPSSystem
syspssystem
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/syspssystems/{pssystemid}"
)
Boolean
remove
(
@PathVariable
(
"pssystemid"
)
String
pssystemid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/syspssystems/batch}"
)
Boolean
removeBatch
(
@RequestBody
Collection
<
String
>
idList
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/syspssystems"
)
SysPSSystem
create
(
@RequestBody
SysPSSystem
syspssystem
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/syspssystems/batch"
)
Boolean
createBatch
(
@RequestBody
List
<
SysPSSystem
>
syspssystems
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/syspssystems/getdraft"
)
SysPSSystem
getDraft
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/syspssystems/save"
)
Boolean
save
(
@RequestBody
SysPSSystem
syspssystem
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/syspssystems/save"
)
Boolean
saveBatch
(
@RequestBody
List
<
SysPSSystem
>
syspssystems
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/syspssystems/searchdefault"
)
Page
<
SysPSSystem
>
searchDefault
(
@RequestBody
SysPSSystemSearchContext
context
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/client/SysPermissionFallback.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
uaa
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.uaa.domain.SysPermission
;
import
cn.ibizlab.core.uaa.filter.SysPermissionSearchContext
;
import
org.springframework.stereotype.Component
;
/**
* 实体[SysPermission] 服务对象接口
*/
@Component
public
class
SysPermissionFallback
implements
SysPermissionFeignClient
{
public
Page
<
SysPermission
>
select
(){
return
null
;
}
public
Boolean
save
(
SysPermission
syspermission
){
return
false
;
}
public
Boolean
saveBatch
(
List
<
SysPermission
>
syspermissions
){
return
false
;
}
public
SysPermission
getDraft
(){
return
null
;
}
public
Boolean
remove
(
String
permissionid
){
return
false
;
}
public
Boolean
removeBatch
(
Collection
<
String
>
idList
){
return
false
;
}
public
SysPermission
update
(
String
permissionid
,
SysPermission
syspermission
){
return
null
;
}
public
Boolean
updateBatch
(
List
<
SysPermission
>
syspermissions
){
return
false
;
}
public
SysPermission
create
(
SysPermission
syspermission
){
return
null
;
}
public
Boolean
createBatch
(
List
<
SysPermission
>
syspermissions
){
return
false
;
}
public
Boolean
checkKey
(
SysPermission
syspermission
){
return
false
;
}
public
SysPermission
get
(
String
permissionid
){
return
null
;
}
public
Page
<
SysPermission
>
searchDefault
(
SysPermissionSearchContext
context
){
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/client/SysPermissionFeignClient.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
uaa
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.uaa.domain.SysPermission
;
import
cn.ibizlab.core.uaa.filter.SysPermissionSearchContext
;
import
org.springframework.cloud.openfeign.FeignClient
;
/**
* 实体[SysPermission] 服务对象接口
*/
@FeignClient
(
value
=
"ibzuaa-api"
,
contextId
=
"SysPermission"
,
fallback
=
SysPermissionFallback
.
class
)
public
interface
SysPermissionFeignClient
{
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/syspermissions/select"
)
Page
<
SysPermission
>
select
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/syspermissions/save"
)
Boolean
save
(
@RequestBody
SysPermission
syspermission
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/syspermissions/save"
)
Boolean
saveBatch
(
@RequestBody
List
<
SysPermission
>
syspermissions
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/syspermissions/getdraft"
)
SysPermission
getDraft
();
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/syspermissions/{permissionid}"
)
Boolean
remove
(
@PathVariable
(
"permissionid"
)
String
permissionid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/syspermissions/batch}"
)
Boolean
removeBatch
(
@RequestBody
Collection
<
String
>
idList
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/syspermissions/{permissionid}"
)
SysPermission
update
(
@PathVariable
(
"permissionid"
)
String
permissionid
,
@RequestBody
SysPermission
syspermission
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/syspermissions/batch"
)
Boolean
updateBatch
(
@RequestBody
List
<
SysPermission
>
syspermissions
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/syspermissions"
)
SysPermission
create
(
@RequestBody
SysPermission
syspermission
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/syspermissions/batch"
)
Boolean
createBatch
(
@RequestBody
List
<
SysPermission
>
syspermissions
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/syspermissions/checkkey"
)
Boolean
checkKey
(
@RequestBody
SysPermission
syspermission
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/syspermissions/{permissionid}"
)
SysPermission
get
(
@PathVariable
(
"permissionid"
)
String
permissionid
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/syspermissions/searchdefault"
)
Page
<
SysPermission
>
searchDefault
(
@RequestBody
SysPermissionSearchContext
context
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/client/SysRoleFallback.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
uaa
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.uaa.domain.SysRole
;
import
cn.ibizlab.core.uaa.filter.SysRoleSearchContext
;
import
org.springframework.stereotype.Component
;
/**
* 实体[SysRole] 服务对象接口
*/
@Component
public
class
SysRoleFallback
implements
SysRoleFeignClient
{
public
Page
<
SysRole
>
select
(){
return
null
;
}
public
Boolean
save
(
SysRole
sysrole
){
return
false
;
}
public
Boolean
saveBatch
(
List
<
SysRole
>
sysroles
){
return
false
;
}
public
SysRole
update
(
String
roleid
,
SysRole
sysrole
){
return
null
;
}
public
Boolean
updateBatch
(
List
<
SysRole
>
sysroles
){
return
false
;
}
public
SysRole
create
(
SysRole
sysrole
){
return
null
;
}
public
Boolean
createBatch
(
List
<
SysRole
>
sysroles
){
return
false
;
}
public
SysRole
get
(
String
roleid
){
return
null
;
}
public
Boolean
remove
(
String
roleid
){
return
false
;
}
public
Boolean
removeBatch
(
Collection
<
String
>
idList
){
return
false
;
}
public
SysRole
getDraft
(){
return
null
;
}
public
Boolean
checkKey
(
SysRole
sysrole
){
return
false
;
}
public
Page
<
SysRole
>
searchDefault
(
SysRoleSearchContext
context
){
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/client/SysRoleFeignClient.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
uaa
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.uaa.domain.SysRole
;
import
cn.ibizlab.core.uaa.filter.SysRoleSearchContext
;
import
org.springframework.cloud.openfeign.FeignClient
;
/**
* 实体[SysRole] 服务对象接口
*/
@FeignClient
(
value
=
"ibzuaa-api"
,
contextId
=
"SysRole"
,
fallback
=
SysRoleFallback
.
class
)
public
interface
SysRoleFeignClient
{
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysroles/select"
)
Page
<
SysRole
>
select
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysroles/save"
)
Boolean
save
(
@RequestBody
SysRole
sysrole
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysroles/save"
)
Boolean
saveBatch
(
@RequestBody
List
<
SysRole
>
sysroles
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysroles/{roleid}"
)
SysRole
update
(
@PathVariable
(
"roleid"
)
String
roleid
,
@RequestBody
SysRole
sysrole
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysroles/batch"
)
Boolean
updateBatch
(
@RequestBody
List
<
SysRole
>
sysroles
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysroles"
)
SysRole
create
(
@RequestBody
SysRole
sysrole
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysroles/batch"
)
Boolean
createBatch
(
@RequestBody
List
<
SysRole
>
sysroles
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysroles/{roleid}"
)
SysRole
get
(
@PathVariable
(
"roleid"
)
String
roleid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysroles/{roleid}"
)
Boolean
remove
(
@PathVariable
(
"roleid"
)
String
roleid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysroles/batch}"
)
Boolean
removeBatch
(
@RequestBody
Collection
<
String
>
idList
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysroles/getdraft"
)
SysRole
getDraft
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysroles/checkkey"
)
Boolean
checkKey
(
@RequestBody
SysRole
sysrole
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysroles/searchdefault"
)
Page
<
SysRole
>
searchDefault
(
@RequestBody
SysRoleSearchContext
context
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/client/SysRolePermissionFallback.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
uaa
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.uaa.domain.SysRolePermission
;
import
cn.ibizlab.core.uaa.filter.SysRolePermissionSearchContext
;
import
org.springframework.stereotype.Component
;
/**
* 实体[SysRolePermission] 服务对象接口
*/
@Component
public
class
SysRolePermissionFallback
implements
SysRolePermissionFeignClient
{
public
Page
<
SysRolePermission
>
select
(){
return
null
;
}
public
SysRolePermission
get
(
String
rolepermissionid
){
return
null
;
}
public
Boolean
remove
(
String
rolepermissionid
){
return
false
;
}
public
Boolean
removeBatch
(
Collection
<
String
>
idList
){
return
false
;
}
public
SysRolePermission
getDraft
(){
return
null
;
}
public
SysRolePermission
create
(
SysRolePermission
sysrolepermission
){
return
null
;
}
public
Boolean
createBatch
(
List
<
SysRolePermission
>
sysrolepermissions
){
return
false
;
}
public
Boolean
checkKey
(
SysRolePermission
sysrolepermission
){
return
false
;
}
public
Boolean
save
(
SysRolePermission
sysrolepermission
){
return
false
;
}
public
Boolean
saveBatch
(
List
<
SysRolePermission
>
sysrolepermissions
){
return
false
;
}
public
SysRolePermission
update
(
String
rolepermissionid
,
SysRolePermission
sysrolepermission
){
return
null
;
}
public
Boolean
updateBatch
(
List
<
SysRolePermission
>
sysrolepermissions
){
return
false
;
}
public
Page
<
SysRolePermission
>
searchDefault
(
SysRolePermissionSearchContext
context
){
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/client/SysRolePermissionFeignClient.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
uaa
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.uaa.domain.SysRolePermission
;
import
cn.ibizlab.core.uaa.filter.SysRolePermissionSearchContext
;
import
org.springframework.cloud.openfeign.FeignClient
;
/**
* 实体[SysRolePermission] 服务对象接口
*/
@FeignClient
(
value
=
"ibzuaa-api"
,
contextId
=
"SysRolePermission"
,
fallback
=
SysRolePermissionFallback
.
class
)
public
interface
SysRolePermissionFeignClient
{
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysrolepermissions/select"
)
Page
<
SysRolePermission
>
select
();
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysrolepermissions/{rolepermissionid}"
)
SysRolePermission
get
(
@PathVariable
(
"rolepermissionid"
)
String
rolepermissionid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysrolepermissions/{rolepermissionid}"
)
Boolean
remove
(
@PathVariable
(
"rolepermissionid"
)
String
rolepermissionid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysrolepermissions/batch}"
)
Boolean
removeBatch
(
@RequestBody
Collection
<
String
>
idList
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysrolepermissions/getdraft"
)
SysRolePermission
getDraft
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysrolepermissions"
)
SysRolePermission
create
(
@RequestBody
SysRolePermission
sysrolepermission
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysrolepermissions/batch"
)
Boolean
createBatch
(
@RequestBody
List
<
SysRolePermission
>
sysrolepermissions
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysrolepermissions/checkkey"
)
Boolean
checkKey
(
@RequestBody
SysRolePermission
sysrolepermission
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysrolepermissions/save"
)
Boolean
save
(
@RequestBody
SysRolePermission
sysrolepermission
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysrolepermissions/save"
)
Boolean
saveBatch
(
@RequestBody
List
<
SysRolePermission
>
sysrolepermissions
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysrolepermissions/{rolepermissionid}"
)
SysRolePermission
update
(
@PathVariable
(
"rolepermissionid"
)
String
rolepermissionid
,
@RequestBody
SysRolePermission
sysrolepermission
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysrolepermissions/batch"
)
Boolean
updateBatch
(
@RequestBody
List
<
SysRolePermission
>
sysrolepermissions
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysrolepermissions/searchdefault"
)
Page
<
SysRolePermission
>
searchDefault
(
@RequestBody
SysRolePermissionSearchContext
context
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/client/SysUserFallback.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
uaa
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.uaa.domain.SysUser
;
import
cn.ibizlab.core.uaa.filter.SysUserSearchContext
;
import
org.springframework.stereotype.Component
;
/**
* 实体[SysUser] 服务对象接口
*/
@Component
public
class
SysUserFallback
implements
SysUserFeignClient
{
public
Page
<
SysUser
>
select
(){
return
null
;
}
public
Boolean
remove
(
String
userid
){
return
false
;
}
public
Boolean
removeBatch
(
Collection
<
String
>
idList
){
return
false
;
}
public
SysUser
update
(
String
userid
,
SysUser
sysuser
){
return
null
;
}
public
Boolean
updateBatch
(
List
<
SysUser
>
sysusers
){
return
false
;
}
public
Boolean
checkKey
(
SysUser
sysuser
){
return
false
;
}
public
SysUser
get
(
String
userid
){
return
null
;
}
public
Boolean
save
(
SysUser
sysuser
){
return
false
;
}
public
Boolean
saveBatch
(
List
<
SysUser
>
sysusers
){
return
false
;
}
public
SysUser
getDraft
(){
return
null
;
}
public
SysUser
create
(
SysUser
sysuser
){
return
null
;
}
public
Boolean
createBatch
(
List
<
SysUser
>
sysusers
){
return
false
;
}
public
Page
<
SysUser
>
searchDefault
(
SysUserSearchContext
context
){
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/client/SysUserFeignClient.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
uaa
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.uaa.domain.SysUser
;
import
cn.ibizlab.core.uaa.filter.SysUserSearchContext
;
import
org.springframework.cloud.openfeign.FeignClient
;
/**
* 实体[SysUser] 服务对象接口
*/
@FeignClient
(
value
=
"ibzuaa-api"
,
contextId
=
"SysUser"
,
fallback
=
SysUserFallback
.
class
)
public
interface
SysUserFeignClient
{
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysusers/select"
)
Page
<
SysUser
>
select
();
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysusers/{userid}"
)
Boolean
remove
(
@PathVariable
(
"userid"
)
String
userid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysusers/batch}"
)
Boolean
removeBatch
(
@RequestBody
Collection
<
String
>
idList
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysusers/{userid}"
)
SysUser
update
(
@PathVariable
(
"userid"
)
String
userid
,
@RequestBody
SysUser
sysuser
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysusers/batch"
)
Boolean
updateBatch
(
@RequestBody
List
<
SysUser
>
sysusers
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysusers/checkkey"
)
Boolean
checkKey
(
@RequestBody
SysUser
sysuser
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysusers/{userid}"
)
SysUser
get
(
@PathVariable
(
"userid"
)
String
userid
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysusers/save"
)
Boolean
save
(
@RequestBody
SysUser
sysuser
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysusers/save"
)
Boolean
saveBatch
(
@RequestBody
List
<
SysUser
>
sysusers
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysusers/getdraft"
)
SysUser
getDraft
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysusers"
)
SysUser
create
(
@RequestBody
SysUser
sysuser
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysusers/batch"
)
Boolean
createBatch
(
@RequestBody
List
<
SysUser
>
sysusers
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysusers/searchdefault"
)
Page
<
SysUser
>
searchDefault
(
@RequestBody
SysUserSearchContext
context
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/client/SysUserRoleFallback.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
uaa
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.uaa.domain.SysUserRole
;
import
cn.ibizlab.core.uaa.filter.SysUserRoleSearchContext
;
import
org.springframework.stereotype.Component
;
/**
* 实体[SysUserRole] 服务对象接口
*/
@Component
public
class
SysUserRoleFallback
implements
SysUserRoleFeignClient
{
public
Page
<
SysUserRole
>
select
(){
return
null
;
}
public
Boolean
checkKey
(
SysUserRole
sysuserrole
){
return
false
;
}
public
SysUserRole
getDraft
(){
return
null
;
}
public
SysUserRole
update
(
String
userroleid
,
SysUserRole
sysuserrole
){
return
null
;
}
public
Boolean
updateBatch
(
List
<
SysUserRole
>
sysuserroles
){
return
false
;
}
public
Boolean
remove
(
String
userroleid
){
return
false
;
}
public
Boolean
removeBatch
(
Collection
<
String
>
idList
){
return
false
;
}
public
SysUserRole
create
(
SysUserRole
sysuserrole
){
return
null
;
}
public
Boolean
createBatch
(
List
<
SysUserRole
>
sysuserroles
){
return
false
;
}
public
SysUserRole
get
(
String
userroleid
){
return
null
;
}
public
Boolean
save
(
SysUserRole
sysuserrole
){
return
false
;
}
public
Boolean
saveBatch
(
List
<
SysUserRole
>
sysuserroles
){
return
false
;
}
public
Page
<
SysUserRole
>
searchDefault
(
SysUserRoleSearchContext
context
){
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/client/SysUserRoleFeignClient.java
0 → 100644
浏览文件 @
71ffc6c5
package
cn
.
ibizlab
.
core
.
uaa
.
client
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.web.bind.annotation.*
;
import
cn.ibizlab.core.uaa.domain.SysUserRole
;
import
cn.ibizlab.core.uaa.filter.SysUserRoleSearchContext
;
import
org.springframework.cloud.openfeign.FeignClient
;
/**
* 实体[SysUserRole] 服务对象接口
*/
@FeignClient
(
value
=
"ibzuaa-api"
,
contextId
=
"SysUserRole"
,
fallback
=
SysUserRoleFallback
.
class
)
public
interface
SysUserRoleFeignClient
{
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysuserroles/select"
)
Page
<
SysUserRole
>
select
();
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysuserroles/checkkey"
)
Boolean
checkKey
(
@RequestBody
SysUserRole
sysuserrole
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysuserroles/getdraft"
)
SysUserRole
getDraft
();
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysuserroles/{userroleid}"
)
SysUserRole
update
(
@PathVariable
(
"userroleid"
)
String
userroleid
,
@RequestBody
SysUserRole
sysuserrole
);
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysuserroles/batch"
)
Boolean
updateBatch
(
@RequestBody
List
<
SysUserRole
>
sysuserroles
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysuserroles/{userroleid}"
)
Boolean
remove
(
@PathVariable
(
"userroleid"
)
String
userroleid
);
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysuserroles/batch}"
)
Boolean
removeBatch
(
@RequestBody
Collection
<
String
>
idList
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysuserroles"
)
SysUserRole
create
(
@RequestBody
SysUserRole
sysuserrole
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysuserroles/batch"
)
Boolean
createBatch
(
@RequestBody
List
<
SysUserRole
>
sysuserroles
);
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysuserroles/{userroleid}"
)
SysUserRole
get
(
@PathVariable
(
"userroleid"
)
String
userroleid
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysuserroles/save"
)
Boolean
save
(
@RequestBody
SysUserRole
sysuserrole
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysuserroles/save"
)
Boolean
saveBatch
(
@RequestBody
List
<
SysUserRole
>
sysuserroles
);
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysuserroles/searchdefault"
)
Page
<
SysUserRole
>
searchDefault
(
@RequestBody
SysUserRoleSearchContext
context
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/domain/SysAuthLog.java
浏览文件 @
71ffc6c5
...
...
@@ -21,89 +21,84 @@ import java.io.Serializable;
import
lombok.Data
;
import
org.springframework.data.annotation.Transient
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.util.domain.EntityMP
;
import
cn.ibizlab.util.domain.EntityClient
;
/**
*
实体[认证日志]
*
ServiceApi [认证日志] 对象
*/
@Data
@TableName
(
value
=
"IBZAUTHLOG"
,
resultMap
=
"SysAuthLogResultMap"
)
public
class
SysAuthLog
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
public
class
SysAuthLog
extends
EntityClient
implements
Serializable
{
/**
* 标识
*/
@DEField
(
isKeyField
=
true
)
@TableId
(
value
=
"logid"
,
type
=
IdType
.
UUID
)
@JSONField
(
name
=
"logid"
)
@JsonProperty
(
"logid"
)
private
String
logid
;
/**
* 用户全局名
*/
@TableField
(
value
=
"username"
)
@JSONField
(
name
=
"username"
)
@JsonProperty
(
"username"
)
private
String
username
;
/**
* 用户名称
*/
@TableField
(
value
=
"personname"
)
@JSONField
(
name
=
"personname"
)
@JsonProperty
(
"personname"
)
private
String
personname
;
/**
* 域
*/
@TableField
(
value
=
"domain"
)
@JSONField
(
name
=
"domain"
)
@JsonProperty
(
"domain"
)
private
String
domain
;
/**
* 认证时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@TableField
(
value
=
"authtime"
,
fill
=
FieldFill
.
INSERT
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"authtime"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"authtime"
)
private
Timestamp
authtime
;
/**
* IP地址
*/
@TableField
(
value
=
"ipaddr"
)
@JSONField
(
name
=
"ipaddr"
)
@JsonProperty
(
"ipaddr"
)
private
String
ipaddr
;
/**
* MAC地址
*/
@TableField
(
value
=
"macaddr"
)
@JSONField
(
name
=
"macaddr"
)
@JsonProperty
(
"macaddr"
)
private
String
macaddr
;
/**
* 客户端
*/
@TableField
(
value
=
"useragent"
)
@JSONField
(
name
=
"useragent"
)
@JsonProperty
(
"useragent"
)
private
String
useragent
;
/**
* 认证结果
*/
@TableField
(
value
=
"authcode"
)
@JSONField
(
name
=
"authcode"
)
@JsonProperty
(
"authcode"
)
private
String
authcode
;
/**
* 设置 [用户全局名]
*/
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/domain/SysPSSystem.java
浏览文件 @
71ffc6c5
...
...
@@ -21,45 +21,40 @@ import java.io.Serializable;
import
lombok.Data
;
import
org.springframework.data.annotation.Transient
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.util.domain.EntityMP
;
import
cn.ibizlab.util.domain.EntityClient
;
/**
*
实体[实体]
*
ServiceApi [实体] 对象
*/
@Data
@TableName
(
value
=
"IBZPSSYSTEM"
,
resultMap
=
"SysPSSystemResultMap"
)
public
class
SysPSSystem
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
public
class
SysPSSystem
extends
EntityClient
implements
Serializable
{
/**
* 系统标识
*/
@DEField
(
isKeyField
=
true
)
@TableId
(
value
=
"pssystemid"
,
type
=
IdType
.
UUID
)
@JSONField
(
name
=
"pssystemid"
)
@JsonProperty
(
"pssystemid"
)
private
String
pssystemid
;
/**
* 系统名称
*/
@TableField
(
value
=
"pssystemname"
)
@JSONField
(
name
=
"pssystemname"
)
@JsonProperty
(
"pssystemname"
)
private
String
pssystemname
;
/**
* 结构
*/
@TableField
(
value
=
"sysstructure"
)
@JSONField
(
name
=
"sysstructure"
)
@JsonProperty
(
"sysstructure"
)
private
String
sysstructure
;
/**
* 设置 [系统名称]
*/
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/domain/SysPermission.java
浏览文件 @
71ffc6c5
...
...
@@ -21,73 +21,65 @@ import java.io.Serializable;
import
lombok.Data
;
import
org.springframework.data.annotation.Transient
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.util.domain.EntityMP
;
import
cn.ibizlab.util.domain.EntityClient
;
/**
*
实体[权限/资源]
*
ServiceApi [权限/资源] 对象
*/
@Data
@TableName
(
value
=
"IBZPERMISSION"
,
resultMap
=
"SysPermissionResultMap"
)
public
class
SysPermission
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
public
class
SysPermission
extends
EntityClient
implements
Serializable
{
/**
* 资源标识
*/
@DEField
(
name
=
"sys_permissionid"
,
isKeyField
=
true
)
@TableId
(
value
=
"sys_permissionid"
,
type
=
IdType
.
UUID
)
@JSONField
(
name
=
"permissionid"
)
@JsonProperty
(
"permissionid"
)
private
String
permissionid
;
/**
* 资源名称
*/
@DEField
(
name
=
"sys_permissionname"
)
@TableField
(
value
=
"sys_permissionname"
)
@JSONField
(
name
=
"permissionname"
)
@JsonProperty
(
"permissionname"
)
private
String
permissionname
;
/**
* 资源类别
*/
@TableField
(
value
=
"permissiontype"
)
@JSONField
(
name
=
"permissiontype"
)
@JsonProperty
(
"permissiontype"
)
private
String
permissiontype
;
/**
* 系统
*/
@TableField
(
value
=
"pssystemid"
)
@JSONField
(
name
=
"pssystemid"
)
@JsonProperty
(
"pssystemid"
)
private
String
pssystemid
;
/**
* 逻辑有效
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
LOGICVALID
,
logicval
=
"1"
,
logicdelval
=
"0"
)
@TableLogic
(
value
=
"1"
,
delval
=
"0"
)
@TableField
(
value
=
"enable"
)
@JSONField
(
name
=
"enable"
)
@JsonProperty
(
"enable"
)
private
Integer
enable
;
/**
* 建立时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@TableField
(
value
=
"createdate"
,
fill
=
FieldFill
.
INSERT
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"createdate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"createdate"
)
private
Timestamp
createdate
;
/**
* 更新时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEDATE
)
@TableField
(
value
=
"updatedate"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"updatedate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"updatedate"
)
...
...
@@ -95,6 +87,8 @@ public class SysPermission extends EntityMP implements Serializable {
/**
* 设置 [资源名称]
*/
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/domain/SysRole.java
浏览文件 @
71ffc6c5
...
...
@@ -21,57 +21,50 @@ import java.io.Serializable;
import
lombok.Data
;
import
org.springframework.data.annotation.Transient
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.util.domain.EntityMP
;
import
cn.ibizlab.util.domain.EntityClient
;
/**
*
实体[系统角色]
*
ServiceApi [系统角色] 对象
*/
@Data
@TableName
(
value
=
"IBZROLE"
,
resultMap
=
"SysRoleResultMap"
)
public
class
SysRole
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
public
class
SysRole
extends
EntityClient
implements
Serializable
{
/**
* 角色表标识
*/
@DEField
(
name
=
"sys_roleid"
,
isKeyField
=
true
)
@TableId
(
value
=
"sys_roleid"
,
type
=
IdType
.
UUID
)
@JSONField
(
name
=
"roleid"
)
@JsonProperty
(
"roleid"
)
private
String
roleid
;
/**
* 角色表名称
*/
@DEField
(
name
=
"sys_rolename"
)
@TableField
(
value
=
"sys_rolename"
)
@JSONField
(
name
=
"rolename"
)
@JsonProperty
(
"rolename"
)
private
String
rolename
;
/**
* 备注
*/
@TableField
(
value
=
"memo"
)
@JSONField
(
name
=
"memo"
)
@JsonProperty
(
"memo"
)
private
String
memo
;
/**
* 建立时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@TableField
(
value
=
"createdate"
,
fill
=
FieldFill
.
INSERT
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"createdate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"createdate"
)
private
Timestamp
createdate
;
/**
* 更新时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEDATE
)
@TableField
(
value
=
"updatedate"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"updatedate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"updatedate"
)
...
...
@@ -79,6 +72,8 @@ public class SysRole extends EntityMP implements Serializable {
/**
* 设置 [角色表名称]
*/
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/domain/SysRolePermission.java
浏览文件 @
71ffc6c5
...
...
@@ -21,109 +21,102 @@ import java.io.Serializable;
import
lombok.Data
;
import
org.springframework.data.annotation.Transient
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.util.domain.EntityMP
;
import
cn.ibizlab.util.domain.EntityClient
;
/**
*
实体[角色权限关系]
*
ServiceApi [角色权限关系] 对象
*/
@Data
@TableName
(
value
=
"IBZROLE_PERMISSION"
,
resultMap
=
"SysRolePermissionResultMap"
)
public
class
SysRolePermission
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
public
class
SysRolePermission
extends
EntityClient
implements
Serializable
{
/**
* 角色权限关系表标识
*/
@DEField
(
name
=
"sys_role_permissionid"
,
isKeyField
=
true
)
@TableId
(
value
=
"sys_role_permissionid"
,
type
=
IdType
.
UUID
)
@JSONField
(
name
=
"rolepermissionid"
)
@JsonProperty
(
"rolepermissionid"
)
private
String
rolepermissionid
;
/**
* 角色表标识
*/
@DEField
(
name
=
"sys_roleid"
)
@TableField
(
value
=
"sys_roleid"
)
@JSONField
(
name
=
"roleid"
)
@JsonProperty
(
"roleid"
)
private
String
roleid
;
/**
* 角色名称
*/
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"rolename"
)
@JsonProperty
(
"rolename"
)
private
String
rolename
;
/**
* 权限表标识
*/
@DEField
(
name
=
"sys_permissionid"
)
@TableField
(
value
=
"sys_permissionid"
)
@JSONField
(
name
=
"permissionid"
)
@JsonProperty
(
"permissionid"
)
private
String
permissionid
;
/**
* 权限名称
*/
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"permissionname"
)
@JsonProperty
(
"permissionname"
)
private
String
permissionname
;
/**
* 权限类型
*/
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"permissiontype"
)
@JsonProperty
(
"permissiontype"
)
private
String
permissiontype
;
/**
* 权限类型
*/
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"permissionenable"
)
@JsonProperty
(
"permissionenable"
)
private
Integer
permissionenable
;
/**
* 建立时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@TableField
(
value
=
"createdate"
,
fill
=
FieldFill
.
INSERT
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"createdate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"createdate"
)
private
Timestamp
createdate
;
/**
* 更新时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEDATE
)
@TableField
(
value
=
"updatedate"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"updatedate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"updatedate"
)
private
Timestamp
updatedate
;
/**
* 资源
*/
@JsonIgnore
@JSONField
(
serialize
=
false
)
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"permission"
)
@JsonProperty
(
"permission"
)
private
cn
.
ibizlab
.
core
.
uaa
.
domain
.
SysPermission
permission
;
/**
* 角色
*/
@JsonIgnore
@JSONField
(
serialize
=
false
)
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"role"
)
@JsonProperty
(
"role"
)
private
cn
.
ibizlab
.
core
.
uaa
.
domain
.
SysRole
role
;
/**
* 设置 [角色表标识]
*/
...
...
@@ -139,22 +132,6 @@ public class SysRolePermission extends EntityMP implements Serializable {
this
.
modify
(
"sys_permissionid"
,
permissionid
);
}
/**
* 获取 [角色权限关系表标识]
*/
public
String
getRolepermissionid
(){
if
(
ObjectUtils
.
isEmpty
(
rolepermissionid
)){
rolepermissionid
=(
String
)
getDefaultKey
(
true
);
}
return
rolepermissionid
;
}
@Override
public
Serializable
getDefaultKey
(
boolean
gen
)
{
if
((!
ObjectUtils
.
isEmpty
(
this
.
getRoleid
()))&&(!
ObjectUtils
.
isEmpty
(
this
.
getPermissionid
())))
return
DigestUtils
.
md5DigestAsHex
(
String
.
format
(
"%s||%s"
,
this
.
getRoleid
(),
this
.
getPermissionid
()).
getBytes
());
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/domain/SysUser.java
浏览文件 @
71ffc6c5
...
...
@@ -21,52 +21,47 @@ import java.io.Serializable;
import
lombok.Data
;
import
org.springframework.data.annotation.Transient
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.util.domain.EntityMP
;
import
cn.ibizlab.util.domain.EntityClient
;
/**
*
实体[系统用户]
*
ServiceApi [系统用户] 对象
*/
@Data
@TableName
(
value
=
"IBZUSER"
,
resultMap
=
"SysUserResultMap"
)
public
class
SysUser
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
public
class
SysUser
extends
EntityClient
implements
Serializable
{
/**
* 用户标识
*/
@DEField
(
isKeyField
=
true
)
@TableId
(
value
=
"userid"
,
type
=
IdType
.
UUID
)
@JSONField
(
name
=
"userid"
)
@JsonProperty
(
"userid"
)
private
String
userid
;
/**
* 用户全局名
*/
@TableField
(
value
=
"username"
)
@JSONField
(
name
=
"username"
)
@JsonProperty
(
"username"
)
private
String
username
;
/**
* 用户姓名
*/
@TableField
(
value
=
"personname"
)
@JSONField
(
name
=
"personname"
)
@JsonProperty
(
"personname"
)
private
String
personname
;
/**
* 密码
*/
@TableField
(
value
=
"password"
)
@JSONField
(
name
=
"password"
)
@JsonProperty
(
"password"
)
private
String
password
;
/**
* 设置 [用户全局名]
*/
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/domain/SysUserRole.java
浏览文件 @
71ffc6c5
...
...
@@ -21,95 +21,88 @@ import java.io.Serializable;
import
lombok.Data
;
import
org.springframework.data.annotation.Transient
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.util.domain.EntityMP
;
import
cn.ibizlab.util.domain.EntityClient
;
/**
*
实体[用户角色关系]
*
ServiceApi [用户角色关系] 对象
*/
@Data
@TableName
(
value
=
"IBZUSER_ROLE"
,
resultMap
=
"SysUserRoleResultMap"
)
public
class
SysUserRole
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
public
class
SysUserRole
extends
EntityClient
implements
Serializable
{
/**
* 用户角色关系表标识
*/
@DEField
(
name
=
"sys_user_roleid"
,
isKeyField
=
true
)
@TableId
(
value
=
"sys_user_roleid"
,
type
=
IdType
.
UUID
)
@JSONField
(
name
=
"userroleid"
)
@JsonProperty
(
"userroleid"
)
private
String
userroleid
;
/**
* 角色表标识
*/
@DEField
(
name
=
"sys_roleid"
)
@TableField
(
value
=
"sys_roleid"
)
@JSONField
(
name
=
"roleid"
)
@JsonProperty
(
"roleid"
)
private
String
roleid
;
/**
* 角色名称
*/
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"rolename"
)
@JsonProperty
(
"rolename"
)
private
String
rolename
;
/**
* 用户标识
*/
@DEField
(
name
=
"sys_userid"
)
@TableField
(
value
=
"sys_userid"
)
@JSONField
(
name
=
"userid"
)
@JsonProperty
(
"userid"
)
private
String
userid
;
/**
* 用户名称
*/
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"personname"
)
@JsonProperty
(
"personname"
)
private
String
personname
;
/**
* 建立时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@TableField
(
value
=
"createdate"
,
fill
=
FieldFill
.
INSERT
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"createdate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"createdate"
)
private
Timestamp
createdate
;
/**
* 更新时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEDATE
)
@TableField
(
value
=
"updatedate"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"updatedate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"updatedate"
)
private
Timestamp
updatedate
;
/**
* 角色
*/
@JsonIgnore
@JSONField
(
serialize
=
false
)
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"role"
)
@JsonProperty
(
"role"
)
private
cn
.
ibizlab
.
core
.
uaa
.
domain
.
SysRole
role
;
/**
* 用户
*/
@JsonIgnore
@JSONField
(
serialize
=
false
)
@TableField
(
exist
=
false
)
@JSONField
(
name
=
"user"
)
@JsonProperty
(
"user"
)
private
cn
.
ibizlab
.
core
.
uaa
.
domain
.
SysUser
user
;
/**
* 设置 [角色表标识]
*/
...
...
@@ -125,22 +118,6 @@ public class SysUserRole extends EntityMP implements Serializable {
this
.
modify
(
"sys_userid"
,
userid
);
}
/**
* 获取 [用户角色关系表标识]
*/
public
String
getUserroleid
(){
if
(
ObjectUtils
.
isEmpty
(
userroleid
)){
userroleid
=(
String
)
getDefaultKey
(
true
);
}
return
userroleid
;
}
@Override
public
Serializable
getDefaultKey
(
boolean
gen
)
{
if
((!
ObjectUtils
.
isEmpty
(
this
.
getRoleid
()))&&(!
ObjectUtils
.
isEmpty
(
this
.
getUserid
())))
return
DigestUtils
.
md5DigestAsHex
(
String
.
format
(
"%s||%s"
,
this
.
getRoleid
(),
this
.
getUserid
()).
getBytes
());
return
null
;
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/filter/SysAuthLogSearchContext.java
浏览文件 @
71ffc6c5
...
...
@@ -17,82 +17,33 @@ import org.springframework.util.ObjectUtils;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.core.uaa.domain.SysAuthLog
;
import
cn.ibizlab.util.filter.SearchContextBase
;
/**
*
关系型
数据实体[SysAuthLog] 查询条件对象
*
ServiceApi
数据实体[SysAuthLog] 查询条件对象
*/
@Slf4j
@Data
public
class
SysAuthLogSearchContext
extends
QueryWrapperContext
<
SysAuthLog
>
{
public
class
SysAuthLogSearchContext
extends
SearchContextBase
{
private
String
n_username_like
;
//[用户全局名]
public
void
setN_username_like
(
String
n_username_like
)
{
this
.
n_username_like
=
n_username_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_username_like
)){
this
.
getSelectCond
().
like
(
"username"
,
n_username_like
);
}
}
private
String
n_personname_like
;
//[用户名称]
public
void
setN_personname_like
(
String
n_personname_like
)
{
this
.
n_personname_like
=
n_personname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_personname_like
)){
this
.
getSelectCond
().
like
(
"personname"
,
n_personname_like
);
}
}
private
String
n_domain_like
;
//[域]
public
void
setN_domain_like
(
String
n_domain_like
)
{
this
.
n_domain_like
=
n_domain_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_domain_like
)){
this
.
getSelectCond
().
like
(
"domain"
,
n_domain_like
);
}
}
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
@JSONField
(
format
=
"yyyy-MM-dd HH:mm:ss"
)
private
Timestamp
n_authtime_gtandeq
;
//[认证时间]
public
void
setN_authtime_gtandeq
(
Timestamp
n_authtime_gtandeq
)
{
this
.
n_authtime_gtandeq
=
n_authtime_gtandeq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_authtime_gtandeq
)){
this
.
getSelectCond
().
ge
(
"authtime"
,
n_authtime_gtandeq
);
}
}
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
@JSONField
(
format
=
"yyyy-MM-dd HH:mm:ss"
)
private
Timestamp
n_authtime_ltandeq
;
//[认证时间]
public
void
setN_authtime_ltandeq
(
Timestamp
n_authtime_ltandeq
)
{
this
.
n_authtime_ltandeq
=
n_authtime_ltandeq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_authtime_ltandeq
)){
this
.
getSelectCond
().
le
(
"authtime"
,
n_authtime_ltandeq
);
}
}
private
String
n_ipaddr_like
;
//[IP地址]
public
void
setN_ipaddr_like
(
String
n_ipaddr_like
)
{
this
.
n_ipaddr_like
=
n_ipaddr_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_ipaddr_like
)){
this
.
getSelectCond
().
like
(
"ipaddr"
,
n_ipaddr_like
);
}
}
private
String
n_authcode_eq
;
//[认证结果]
public
void
setN_authcode_eq
(
String
n_authcode_eq
)
{
this
.
n_authcode_eq
=
n_authcode_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_authcode_eq
)){
this
.
getSelectCond
().
eq
(
"authcode"
,
n_authcode_eq
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSelectCond
().
or
().
like
(
"username"
,
query
);
}
}
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/filter/SysPSSystemSearchContext.java
浏览文件 @
71ffc6c5
...
...
@@ -17,36 +17,17 @@ import org.springframework.util.ObjectUtils;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.core.uaa.domain.SysPSSystem
;
import
cn.ibizlab.util.filter.SearchContextBase
;
/**
*
关系型
数据实体[SysPSSystem] 查询条件对象
*
ServiceApi
数据实体[SysPSSystem] 查询条件对象
*/
@Slf4j
@Data
public
class
SysPSSystemSearchContext
extends
QueryWrapperContext
<
SysPSSystem
>
{
public
class
SysPSSystemSearchContext
extends
SearchContextBase
{
private
String
n_pssystemname_like
;
//[系统名称]
public
void
setN_pssystemname_like
(
String
n_pssystemname_like
)
{
this
.
n_pssystemname_like
=
n_pssystemname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_pssystemname_like
)){
this
.
getSelectCond
().
like
(
"pssystemname"
,
n_pssystemname_like
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSelectCond
().
or
().
like
(
"pssystemname"
,
query
);
}
}
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/filter/SysPermissionSearchContext.java
浏览文件 @
71ffc6c5
...
...
@@ -17,57 +17,23 @@ import org.springframework.util.ObjectUtils;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.core.uaa.domain.SysPermission
;
import
cn.ibizlab.util.filter.SearchContextBase
;
/**
*
关系型
数据实体[SysPermission] 查询条件对象
*
ServiceApi
数据实体[SysPermission] 查询条件对象
*/
@Slf4j
@Data
public
class
SysPermissionSearchContext
extends
QueryWrapperContext
<
SysPermission
>
{
public
class
SysPermissionSearchContext
extends
SearchContextBase
{
private
String
n_sys_permissionid_like
;
//[资源标识]
public
void
setN_sys_permissionid_like
(
String
n_sys_permissionid_like
)
{
this
.
n_sys_permissionid_like
=
n_sys_permissionid_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sys_permissionid_like
)){
this
.
getSelectCond
().
like
(
"sys_permissionid"
,
n_sys_permissionid_like
);
}
}
private
String
n_sys_permissionname_like
;
//[资源名称]
public
void
setN_sys_permissionname_like
(
String
n_sys_permissionname_like
)
{
this
.
n_sys_permissionname_like
=
n_sys_permissionname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sys_permissionname_like
)){
this
.
getSelectCond
().
like
(
"sys_permissionname"
,
n_sys_permissionname_like
);
}
}
private
String
n_permissiontype_eq
;
//[资源类别]
public
void
setN_permissiontype_eq
(
String
n_permissiontype_eq
)
{
this
.
n_permissiontype_eq
=
n_permissiontype_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_permissiontype_eq
)){
this
.
getSelectCond
().
eq
(
"permissiontype"
,
n_permissiontype_eq
);
}
}
private
Integer
n_enable_eq
;
//[逻辑有效]
public
void
setN_enable_eq
(
Integer
n_enable_eq
)
{
this
.
n_enable_eq
=
n_enable_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_enable_eq
)){
this
.
getSelectCond
().
eq
(
"enable"
,
n_enable_eq
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSelectCond
().
or
().
like
(
"sys_permissionname"
,
query
);
}
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/filter/SysRolePermissionSearchContext.java
浏览文件 @
71ffc6c5
...
...
@@ -17,71 +17,27 @@ import org.springframework.util.ObjectUtils;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.core.uaa.domain.SysRolePermission
;
import
cn.ibizlab.util.filter.SearchContextBase
;
/**
*
关系型
数据实体[SysRolePermission] 查询条件对象
*
ServiceApi
数据实体[SysRolePermission] 查询条件对象
*/
@Slf4j
@Data
public
class
SysRolePermissionSearchContext
extends
QueryWrapperContext
<
SysRolePermission
>
{
public
class
SysRolePermissionSearchContext
extends
SearchContextBase
{
private
String
n_sys_roleid_eq
;
//[角色表标识]
public
void
setN_sys_roleid_eq
(
String
n_sys_roleid_eq
)
{
this
.
n_sys_roleid_eq
=
n_sys_roleid_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sys_roleid_eq
)){
this
.
getSelectCond
().
eq
(
"sys_roleid"
,
n_sys_roleid_eq
);
}
}
private
String
n_sys_rolename_eq
;
//[角色名称]
public
void
setN_sys_rolename_eq
(
String
n_sys_rolename_eq
)
{
this
.
n_sys_rolename_eq
=
n_sys_rolename_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sys_rolename_eq
)){
this
.
getSelectCond
().
eq
(
"sys_rolename"
,
n_sys_rolename_eq
);
}
}
private
String
n_sys_rolename_like
;
//[角色名称]
public
void
setN_sys_rolename_like
(
String
n_sys_rolename_like
)
{
this
.
n_sys_rolename_like
=
n_sys_rolename_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sys_rolename_like
)){
this
.
getSelectCond
().
like
(
"sys_rolename"
,
n_sys_rolename_like
);
}
}
private
String
n_sys_permissionid_eq
;
//[权限表标识]
public
void
setN_sys_permissionid_eq
(
String
n_sys_permissionid_eq
)
{
this
.
n_sys_permissionid_eq
=
n_sys_permissionid_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sys_permissionid_eq
)){
this
.
getSelectCond
().
eq
(
"sys_permissionid"
,
n_sys_permissionid_eq
);
}
}
private
String
n_sys_permissionname_eq
;
//[权限名称]
public
void
setN_sys_permissionname_eq
(
String
n_sys_permissionname_eq
)
{
this
.
n_sys_permissionname_eq
=
n_sys_permissionname_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sys_permissionname_eq
)){
this
.
getSelectCond
().
eq
(
"sys_permissionname"
,
n_sys_permissionname_eq
);
}
}
private
String
n_sys_permissionname_like
;
//[权限名称]
public
void
setN_sys_permissionname_like
(
String
n_sys_permissionname_like
)
{
this
.
n_sys_permissionname_like
=
n_sys_permissionname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sys_permissionname_like
)){
this
.
getSelectCond
().
like
(
"sys_permissionname"
,
n_sys_permissionname_like
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSelectCond
().
or
().
like
(
"sys_permissionid"
,
query
);
}
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/filter/SysRoleSearchContext.java
浏览文件 @
71ffc6c5
...
...
@@ -17,54 +17,21 @@ import org.springframework.util.ObjectUtils;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.core.uaa.domain.SysRole
;
import
cn.ibizlab.util.filter.SearchContextBase
;
/**
*
关系型
数据实体[SysRole] 查询条件对象
*
ServiceApi
数据实体[SysRole] 查询条件对象
*/
@Slf4j
@Data
public
class
SysRoleSearchContext
extends
QueryWrapperContext
<
SysRole
>
{
public
class
SysRoleSearchContext
extends
SearchContextBase
{
private
String
n_sys_rolename_isnotnull
;
//[角色表名称]
public
void
setN_sys_rolename_isnotnull
(
String
n_sys_rolename_isnotnull
)
{
this
.
n_sys_rolename_isnotnull
=
n_sys_rolename_isnotnull
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sys_rolename_isnotnull
)){
if
(
this
.
n_sys_rolename_isnotnull
.
toString
().
equals
(
"1"
)){
this
.
getSelectCond
().
isNotNull
(
"sys_rolename"
);
}
}
}
private
String
n_sys_rolename_isnull
;
//[角色表名称]
public
void
setN_sys_rolename_isnull
(
String
n_sys_rolename_isnull
)
{
this
.
n_sys_rolename_isnull
=
n_sys_rolename_isnull
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sys_rolename_isnull
)){
if
(
this
.
n_sys_rolename_isnull
.
toString
().
equals
(
"1"
)){
this
.
getSelectCond
().
isNull
(
"sys_rolename"
);
}
}
}
private
String
n_sys_rolename_like
;
//[角色表名称]
public
void
setN_sys_rolename_like
(
String
n_sys_rolename_like
)
{
this
.
n_sys_rolename_like
=
n_sys_rolename_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sys_rolename_like
)){
this
.
getSelectCond
().
like
(
"sys_rolename"
,
n_sys_rolename_like
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSelectCond
().
or
().
like
(
"sys_rolename"
,
query
);
}
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/filter/SysUserRoleSearchContext.java
浏览文件 @
71ffc6c5
...
...
@@ -17,57 +17,23 @@ import org.springframework.util.ObjectUtils;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.core.uaa.domain.SysUserRole
;
import
cn.ibizlab.util.filter.SearchContextBase
;
/**
*
关系型
数据实体[SysUserRole] 查询条件对象
*
ServiceApi
数据实体[SysUserRole] 查询条件对象
*/
@Slf4j
@Data
public
class
SysUserRoleSearchContext
extends
QueryWrapperContext
<
SysUserRole
>
{
public
class
SysUserRoleSearchContext
extends
SearchContextBase
{
private
String
n_sys_roleid_eq
;
//[角色表标识]
public
void
setN_sys_roleid_eq
(
String
n_sys_roleid_eq
)
{
this
.
n_sys_roleid_eq
=
n_sys_roleid_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sys_roleid_eq
)){
this
.
getSelectCond
().
eq
(
"sys_roleid"
,
n_sys_roleid_eq
);
}
}
private
String
n_sys_userid_eq
;
//[用户标识]
public
void
setN_sys_userid_eq
(
String
n_sys_userid_eq
)
{
this
.
n_sys_userid_eq
=
n_sys_userid_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sys_userid_eq
)){
this
.
getSelectCond
().
eq
(
"sys_userid"
,
n_sys_userid_eq
);
}
}
private
String
n_sys_username_eq
;
//[用户名称]
public
void
setN_sys_username_eq
(
String
n_sys_username_eq
)
{
this
.
n_sys_username_eq
=
n_sys_username_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sys_username_eq
)){
this
.
getSelectCond
().
eq
(
"sys_username"
,
n_sys_username_eq
);
}
}
private
String
n_sys_username_like
;
//[用户名称]
public
void
setN_sys_username_like
(
String
n_sys_username_like
)
{
this
.
n_sys_username_like
=
n_sys_username_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_sys_username_like
)){
this
.
getSelectCond
().
like
(
"sys_username"
,
n_sys_username_like
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSelectCond
().
or
().
like
(
"sys_userid"
,
query
);
}
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/filter/SysUserSearchContext.java
浏览文件 @
71ffc6c5
...
...
@@ -17,43 +17,19 @@ import org.springframework.util.ObjectUtils;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.core.uaa.domain.SysUser
;
import
cn.ibizlab.util.filter.SearchContextBase
;
/**
*
关系型
数据实体[SysUser] 查询条件对象
*
ServiceApi
数据实体[SysUser] 查询条件对象
*/
@Slf4j
@Data
public
class
SysUserSearchContext
extends
QueryWrapperContext
<
SysUser
>
{
public
class
SysUserSearchContext
extends
SearchContextBase
{
private
String
n_username_like
;
//[用户全局名]
public
void
setN_username_like
(
String
n_username_like
)
{
this
.
n_username_like
=
n_username_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_username_like
)){
this
.
getSelectCond
().
like
(
"username"
,
n_username_like
);
}
}
private
String
n_personname_like
;
//[用户姓名]
public
void
setN_personname_like
(
String
n_personname_like
)
{
this
.
n_personname_like
=
n_personname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_personname_like
)){
this
.
getSelectCond
().
like
(
"personname"
,
n_personname_like
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSelectCond
().
or
().
like
(
"personname"
,
query
);
}
}
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/service/ISysAuthLogService.java
浏览文件 @
71ffc6c5
...
...
@@ -18,12 +18,10 @@ import cn.ibizlab.core.uaa.domain.SysAuthLog;
import
cn.ibizlab.core.uaa.filter.SysAuthLogSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[SysAuthLog] 服务对象接口
*/
public
interface
ISysAuthLogService
extends
IService
<
SysAuthLog
>
{
public
interface
ISysAuthLogService
{
boolean
checkKey
(
SysAuthLog
et
)
;
boolean
remove
(
String
key
)
;
...
...
@@ -37,22 +35,8 @@ public interface ISysAuthLogService extends IService<SysAuthLog>{
void
createBatch
(
List
<
SysAuthLog
>
list
)
;
SysAuthLog
get
(
String
key
)
;
Page
<
SysAuthLog
>
searchDefault
(
SysAuthLogSearchContext
context
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/service/ISysPSSystemService.java
浏览文件 @
71ffc6c5
...
...
@@ -18,12 +18,10 @@ import cn.ibizlab.core.uaa.domain.SysPSSystem;
import
cn.ibizlab.core.uaa.filter.SysPSSystemSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[SysPSSystem] 服务对象接口
*/
public
interface
ISysPSSystemService
extends
IService
<
SysPSSystem
>
{
public
interface
ISysPSSystemService
{
SysPSSystem
get
(
String
key
)
;
boolean
update
(
SysPSSystem
et
)
;
...
...
@@ -37,22 +35,8 @@ public interface ISysPSSystemService extends IService<SysPSSystem>{
boolean
save
(
SysPSSystem
et
)
;
void
saveBatch
(
List
<
SysPSSystem
>
list
)
;
Page
<
SysPSSystem
>
searchDefault
(
SysPSSystemSearchContext
context
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/service/ISysPermissionService.java
浏览文件 @
71ffc6c5
...
...
@@ -18,12 +18,10 @@ import cn.ibizlab.core.uaa.domain.SysPermission;
import
cn.ibizlab.core.uaa.filter.SysPermissionSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[SysPermission] 服务对象接口
*/
public
interface
ISysPermissionService
extends
IService
<
SysPermission
>
{
public
interface
ISysPermissionService
{
boolean
save
(
SysPermission
et
)
;
void
saveBatch
(
List
<
SysPermission
>
list
)
;
...
...
@@ -37,22 +35,8 @@ public interface ISysPermissionService extends IService<SysPermission>{
boolean
checkKey
(
SysPermission
et
)
;
SysPermission
get
(
String
key
)
;
Page
<
SysPermission
>
searchDefault
(
SysPermissionSearchContext
context
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/service/ISysRolePermissionService.java
浏览文件 @
71ffc6c5
...
...
@@ -18,12 +18,10 @@ import cn.ibizlab.core.uaa.domain.SysRolePermission;
import
cn.ibizlab.core.uaa.filter.SysRolePermissionSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[SysRolePermission] 服务对象接口
*/
public
interface
ISysRolePermissionService
extends
IService
<
SysRolePermission
>
{
public
interface
ISysRolePermissionService
{
SysRolePermission
get
(
String
key
)
;
boolean
remove
(
String
key
)
;
...
...
@@ -41,22 +39,8 @@ public interface ISysRolePermissionService extends IService<SysRolePermission>{
void
removeByPermissionid
(
String
permissionid
)
;
List
<
SysRolePermission
>
selectByRoleid
(
String
roleid
)
;
void
removeByRoleid
(
String
roleid
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/service/ISysRoleService.java
浏览文件 @
71ffc6c5
...
...
@@ -18,12 +18,10 @@ import cn.ibizlab.core.uaa.domain.SysRole;
import
cn.ibizlab.core.uaa.filter.SysRoleSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[SysRole] 服务对象接口
*/
public
interface
ISysRoleService
extends
IService
<
SysRole
>
{
public
interface
ISysRoleService
{
boolean
save
(
SysRole
et
)
;
@CacheEvict
(
value
=
"sysrole"
,
allEntries
=
true
)
...
...
@@ -41,22 +39,8 @@ public interface ISysRoleService extends IService<SysRole>{
SysRole
getDraft
(
SysRole
et
)
;
boolean
checkKey
(
SysRole
et
)
;
Page
<
SysRole
>
searchDefault
(
SysRoleSearchContext
context
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/service/ISysUserRoleService.java
浏览文件 @
71ffc6c5
...
...
@@ -18,12 +18,10 @@ import cn.ibizlab.core.uaa.domain.SysUserRole;
import
cn.ibizlab.core.uaa.filter.SysUserRoleSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[SysUserRole] 服务对象接口
*/
public
interface
ISysUserRoleService
extends
IService
<
SysUserRole
>
{
public
interface
ISysUserRoleService
{
boolean
checkKey
(
SysUserRole
et
)
;
SysUserRole
getDraft
(
SysUserRole
et
)
;
...
...
@@ -41,22 +39,8 @@ public interface ISysUserRoleService extends IService<SysUserRole>{
void
removeByRoleid
(
String
roleid
)
;
List
<
SysUserRole
>
selectByUserid
(
String
userid
)
;
void
removeByUserid
(
String
userid
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/service/ISysUserService.java
浏览文件 @
71ffc6c5
...
...
@@ -18,12 +18,10 @@ import cn.ibizlab.core.uaa.domain.SysUser;
import
cn.ibizlab.core.uaa.filter.SysUserSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[SysUser] 服务对象接口
*/
public
interface
ISysUserService
extends
IService
<
SysUser
>
{
public
interface
ISysUserService
{
boolean
remove
(
String
key
)
;
@CacheEvict
(
value
=
"sysuser"
,
allEntries
=
true
)
...
...
@@ -41,22 +39,8 @@ public interface ISysUserService extends IService<SysUser>{
@CacheEvict
(
value
=
"sysuser"
,
allEntries
=
true
)
void
createBatch
(
List
<
SysUser
>
list
)
;
Page
<
SysUser
>
searchDefault
(
SysUserSearchContext
context
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
}
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/service/impl/SysAuthLogServiceImpl.java
浏览文件 @
71ffc6c5
...
...
@@ -30,153 +30,103 @@ import cn.ibizlab.core.uaa.service.ISysAuthLogService;
import
cn.ibizlab.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.core.uaa.mapper.SysAuthLogMapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.core.uaa.client.SysAuthLogFeignClient
;
/**
* 实体[认证日志] 服务对象接口实现
*/
@Slf4j
@Service
(
"SysAuthLogServiceImpl"
)
public
class
SysAuthLogServiceImpl
extends
ServiceImpl
<
SysAuthLogMapper
,
SysAuthLog
>
implements
ISysAuthLogService
{
@Service
public
class
SysAuthLogServiceImpl
implements
ISysAuthLogService
{
@Autowired
SysAuthLogFeignClient
sysAuthLogFeignClient
;
private
int
batchSize
=
500
;
@Override
public
boolean
checkKey
(
SysAuthLog
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getLogid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getLogid
()))
);
return
sysAuthLogFeignClient
.
checkKey
(
et
);
}
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
return
result
;
public
boolean
remove
(
String
logid
)
{
boolean
result
=
sysAuthLogFeignClient
.
remove
(
logid
)
;
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
public
void
removeBatch
(
Collection
<
String
>
idList
){
sysAuthLogFeignClient
.
removeBatch
(
idList
);
}
@Override
public
SysAuthLog
getDraft
(
SysAuthLog
et
)
{
et
=
sysAuthLogFeignClient
.
getDraft
();
return
et
;
}
@Override
@Transactional
public
boolean
update
(
SysAuthLog
et
)
{
if
(!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"logid"
,
et
.
getLogid
())))
SysAuthLog
rt
=
sysAuthLogFeignClient
.
update
(
et
.
getLogid
(),
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getLogid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
SysAuthLog
>
list
)
{
updateBatchById
(
list
,
batchSize
);
public
void
updateBatch
(
List
<
SysAuthLog
>
list
){
sysAuthLogFeignClient
.
updateBatch
(
list
)
;
}
@Override
@Transactional
public
boolean
save
(
SysAuthLog
et
)
{
if
(!
saveOrUpdate
(
et
))
if
(
et
.
getLogid
()==
null
)
et
.
setLogid
((
String
)
et
.
getDefaultKey
(
true
));
if
(!
sysAuthLogFeignClient
.
save
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
SysAuthLog
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
}
@Override
public
boolean
saveBatch
(
Collection
<
SysAuthLog
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
SysAuthLog
>
list
)
{
s
aveOrUpdateBatch
(
list
,
batchSize
)
;
s
ysAuthLogFeignClient
.
saveBatch
(
list
)
;
}
@Override
@Transactional
public
boolean
create
(
SysAuthLog
et
)
{
if
(!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
)))
SysAuthLog
rt
=
sysAuthLogFeignClient
.
create
(
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getLogid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
SysAuthLog
>
list
)
{
this
.
saveBatch
(
list
,
batchSize
);
public
void
createBatch
(
List
<
SysAuthLog
>
list
){
sysAuthLogFeignClient
.
createBatch
(
list
)
;
}
@Override
@Transactional
public
SysAuthLog
get
(
String
key
)
{
SysAuthLog
et
=
getById
(
key
);
public
SysAuthLog
get
(
String
logid
)
{
SysAuthLog
et
=
sysAuthLogFeignClient
.
get
(
logid
);
if
(
et
==
null
){
et
=
new
SysAuthLog
();
et
.
setLogid
(
key
);
et
.
setLogid
(
logid
);
}
else
{
}
return
et
;
return
et
;
}
/**
* 查询集合 DEFAULT
*/
@Override
public
Page
<
SysAuthLog
>
searchDefault
(
SysAuthLogSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
SysAuthLog
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
());
return
new
PageImpl
<
SysAuthLog
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
());
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
Page
<
SysAuthLog
>
sysAuthLogs
=
sysAuthLogFeignClient
.
searchDefault
(
context
);
return
sysAuthLogs
;
}
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/service/impl/SysPSSystemServiceImpl.java
浏览文件 @
71ffc6c5
...
...
@@ -30,116 +30,93 @@ import cn.ibizlab.core.uaa.service.ISysPSSystemService;
import
cn.ibizlab.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.core.uaa.mapper.SysPSSystemMapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.core.uaa.client.SysPSSystemFeignClient
;
/**
* 实体[实体] 服务对象接口实现
*/
@Slf4j
@Service
(
"SysPSSystemServiceImpl"
)
public
class
SysPSSystemServiceImpl
extends
ServiceImpl
<
SysPSSystemMapper
,
SysPSSystem
>
implements
ISysPSSystemService
{
@Service
public
class
SysPSSystemServiceImpl
implements
ISysPSSystemService
{
@Autowired
SysPSSystemFeignClient
sysPSSystemFeignClient
;
private
int
batchSize
=
500
;
@Override
@Transactional
public
SysPSSystem
get
(
String
key
)
{
SysPSSystem
et
=
getById
(
key
);
public
SysPSSystem
get
(
String
pssystemid
)
{
SysPSSystem
et
=
sysPSSystemFeignClient
.
get
(
pssystemid
);
if
(
et
==
null
){
et
=
new
SysPSSystem
();
et
.
setPssystemid
(
key
);
et
.
setPssystemid
(
pssystemid
);
}
else
{
}
return
et
;
return
et
;
}
@Override
@Transactional
public
boolean
update
(
SysPSSystem
et
)
{
if
(!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"pssystemid"
,
et
.
getPssystemid
())))
SysPSSystem
rt
=
sysPSSystemFeignClient
.
update
(
et
.
getPssystemid
(),
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getPssystemid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
SysPSSystem
>
list
)
{
updateBatchById
(
list
,
batchSize
);
public
void
updateBatch
(
List
<
SysPSSystem
>
list
){
sysPSSystemFeignClient
.
updateBatch
(
list
)
;
}
@Override
public
boolean
checkKey
(
SysPSSystem
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getPssystemid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getPssystemid
()))
);
return
sysPSSystemFeignClient
.
checkKey
(
et
);
}
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
return
result
;
public
boolean
remove
(
String
pssystemid
)
{
boolean
result
=
sysPSSystemFeignClient
.
remove
(
pssystemid
)
;
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
public
void
removeBatch
(
Collection
<
String
>
idList
){
sysPSSystemFeignClient
.
removeBatch
(
idList
);
}
@Override
@Transactional
public
boolean
create
(
SysPSSystem
et
)
{
if
(!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
)))
SysPSSystem
rt
=
sysPSSystemFeignClient
.
create
(
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getPssystemid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
SysPSSystem
>
list
)
{
this
.
saveBatch
(
list
,
batchSize
);
public
void
createBatch
(
List
<
SysPSSystem
>
list
){
sysPSSystemFeignClient
.
createBatch
(
list
)
;
}
@Override
public
SysPSSystem
getDraft
(
SysPSSystem
et
)
{
et
=
sysPSSystemFeignClient
.
getDraft
();
return
et
;
}
@Override
@Transactional
public
boolean
save
(
SysPSSystem
et
)
{
if
(!
saveOrUpdate
(
et
))
if
(
et
.
getPssystemid
()==
null
)
et
.
setPssystemid
((
String
)
et
.
getDefaultKey
(
true
));
if
(!
sysPSSystemFeignClient
.
save
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
SysPSSystem
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
public
void
saveBatch
(
List
<
SysPSSystem
>
list
)
{
sysPSSystemFeignClient
.
saveBatch
(
list
)
;
}
@Override
public
boolean
saveBatch
(
Collection
<
SysPSSystem
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
SysPSSystem
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
);
}
...
...
@@ -148,35 +125,8 @@ public class SysPSSystemServiceImpl extends ServiceImpl<SysPSSystemMapper, SysPS
*/
@Override
public
Page
<
SysPSSystem
>
searchDefault
(
SysPSSystemSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
SysPSSystem
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
());
return
new
PageImpl
<
SysPSSystem
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
());
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
Page
<
SysPSSystem
>
sysPSSystems
=
sysPSSystemFeignClient
.
searchDefault
(
context
);
return
sysPSSystems
;
}
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/service/impl/SysPermissionServiceImpl.java
浏览文件 @
71ffc6c5
...
...
@@ -30,156 +30,103 @@ import cn.ibizlab.core.uaa.service.ISysPermissionService;
import
cn.ibizlab.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.core.uaa.mapper.SysPermissionMapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.core.uaa.client.SysPermissionFeignClient
;
/**
* 实体[权限/资源] 服务对象接口实现
*/
@Slf4j
@Service
(
"SysPermissionServiceImpl"
)
public
class
SysPermissionServiceImpl
extends
ServiceImpl
<
SysPermissionMapper
,
SysPermission
>
implements
ISysPermissionService
{
@Service
public
class
SysPermissionServiceImpl
implements
ISysPermissionService
{
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
uaa
.
service
.
ISysRolePermissionService
sysrolepermissionService
;
SysPermissionFeignClient
sysPermissionFeignClient
;
private
int
batchSize
=
500
;
@Override
@Transactional
public
boolean
save
(
SysPermission
et
)
{
if
(!
saveOrUpdate
(
et
))
if
(
et
.
getPermissionid
()==
null
)
et
.
setPermissionid
((
String
)
et
.
getDefaultKey
(
true
));
if
(!
sysPermissionFeignClient
.
save
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
SysPermission
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
}
@Override
public
boolean
saveBatch
(
Collection
<
SysPermission
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
SysPermission
>
list
)
{
s
aveOrUpdateBatch
(
list
,
batchSize
)
;
s
ysPermissionFeignClient
.
saveBatch
(
list
)
;
}
@Override
public
SysPermission
getDraft
(
SysPermission
et
)
{
et
=
sysPermissionFeignClient
.
getDraft
();
return
et
;
}
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
return
result
;
public
boolean
remove
(
String
permissionid
)
{
boolean
result
=
sysPermissionFeignClient
.
remove
(
permissionid
)
;
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
public
void
removeBatch
(
Collection
<
String
>
idList
){
sysPermissionFeignClient
.
removeBatch
(
idList
);
}
@Override
@Transactional
public
boolean
update
(
SysPermission
et
)
{
if
(!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"sys_permissionid"
,
et
.
getPermissionid
())))
SysPermission
rt
=
sysPermissionFeignClient
.
update
(
et
.
getPermissionid
(),
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getPermissionid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
SysPermission
>
list
)
{
updateBatchById
(
list
,
batchSize
);
public
void
updateBatch
(
List
<
SysPermission
>
list
){
sysPermissionFeignClient
.
updateBatch
(
list
)
;
}
@Override
@Transactional
public
boolean
create
(
SysPermission
et
)
{
if
(!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
)))
SysPermission
rt
=
sysPermissionFeignClient
.
create
(
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getPermissionid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
SysPermission
>
list
)
{
this
.
saveBatch
(
list
,
batchSize
);
public
void
createBatch
(
List
<
SysPermission
>
list
){
sysPermissionFeignClient
.
createBatch
(
list
)
;
}
@Override
public
boolean
checkKey
(
SysPermission
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getPermissionid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getPermissionid
()))
);
return
sysPermissionFeignClient
.
checkKey
(
et
);
}
@Override
@Transactional
public
SysPermission
get
(
String
key
)
{
SysPermission
et
=
getById
(
key
);
public
SysPermission
get
(
String
permissionid
)
{
SysPermission
et
=
sysPermissionFeignClient
.
get
(
permissionid
);
if
(
et
==
null
){
et
=
new
SysPermission
();
et
.
setPermissionid
(
key
);
et
.
setPermissionid
(
permissionid
);
}
else
{
}
return
et
;
return
et
;
}
/**
* 查询集合 DEFAULT
*/
@Override
public
Page
<
SysPermission
>
searchDefault
(
SysPermissionSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
SysPermission
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
());
return
new
PageImpl
<
SysPermission
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
());
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
Page
<
SysPermission
>
sysPermissions
=
sysPermissionFeignClient
.
searchDefault
(
context
);
return
sysPermissions
;
}
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/service/impl/SysRolePermissionServiceImpl.java
浏览文件 @
71ffc6c5
...
...
@@ -30,214 +30,139 @@ import cn.ibizlab.core.uaa.service.ISysRolePermissionService;
import
cn.ibizlab.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.core.uaa.mapper.SysRolePermissionMapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.core.uaa.client.SysRolePermissionFeignClient
;
/**
* 实体[角色权限关系] 服务对象接口实现
*/
@Slf4j
@Service
(
"SysRolePermissionServiceImpl"
)
public
class
SysRolePermissionServiceImpl
extends
ServiceImpl
<
SysRolePermissionMapper
,
SysRolePermission
>
implements
ISysRolePermissionService
{
@Service
public
class
SysRolePermissionServiceImpl
implements
ISysRolePermissionService
{
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
uaa
.
service
.
ISysPermissionService
syspermissionService
;
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
uaa
.
service
.
ISysRoleService
sysroleService
;
SysRolePermissionFeignClient
sysRolePermissionFeignClient
;
private
int
batchSize
=
500
;
@Override
@Transactional
public
SysRolePermission
get
(
String
key
)
{
SysRolePermission
et
=
getById
(
key
);
public
SysRolePermission
get
(
String
rolepermissionid
)
{
SysRolePermission
et
=
sysRolePermissionFeignClient
.
get
(
rolepermissionid
);
if
(
et
==
null
){
et
=
new
SysRolePermission
();
et
.
setRolepermissionid
(
key
);
et
.
setRolepermissionid
(
rolepermissionid
);
}
else
{
}
return
et
;
return
et
;
}
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
return
result
;
public
boolean
remove
(
String
rolepermissionid
)
{
boolean
result
=
sysRolePermissionFeignClient
.
remove
(
rolepermissionid
)
;
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
public
void
removeBatch
(
Collection
<
String
>
idList
){
sysRolePermissionFeignClient
.
removeBatch
(
idList
);
}
@Override
public
SysRolePermission
getDraft
(
SysRolePermission
et
)
{
fillParentData
(
et
);
et
=
sysRolePermissionFeignClient
.
getDraft
(
);
return
et
;
}
@Override
@Transactional
public
boolean
create
(
SysRolePermission
et
)
{
fillParentData
(
et
);
if
(
!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
))
)
SysRolePermission
rt
=
sysRolePermissionFeignClient
.
create
(
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getRolepermissionid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
SysRolePermission
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
this
.
saveOrUpdateBatch
(
list
,
batchSize
);
public
void
createBatch
(
List
<
SysRolePermission
>
list
){
sysRolePermissionFeignClient
.
createBatch
(
list
)
;
}
@Override
public
boolean
checkKey
(
SysRolePermission
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getRolepermissionid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getRolepermissionid
()))
);
return
sysRolePermissionFeignClient
.
checkKey
(
et
);
}
@Override
@Transactional
public
boolean
save
(
SysRolePermission
et
)
{
if
(!
saveOrUpdate
(
et
))
if
(
et
.
getRolepermissionid
()==
null
)
et
.
setRolepermissionid
((
String
)
et
.
getDefaultKey
(
true
));
if
(!
sysRolePermissionFeignClient
.
save
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
SysRolePermission
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
}
@Override
public
boolean
saveBatch
(
Collection
<
SysRolePermission
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
SysRolePermission
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
saveOrUpdateBatch
(
list
,
batchSize
);
sysRolePermissionFeignClient
.
saveBatch
(
list
)
;
}
@Override
@Transactional
public
boolean
update
(
SysRolePermission
et
)
{
fillParentData
(
et
);
if
(
!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"sys_role_permissionid"
,
et
.
getRolepermissionid
()))
)
SysRolePermission
rt
=
sysRolePermissionFeignClient
.
update
(
et
.
getRolepermissionid
(),
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getRolepermissionid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
SysRolePermission
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
updateBatchById
(
list
,
batchSize
);
public
void
updateBatch
(
List
<
SysRolePermission
>
list
){
sysRolePermissionFeignClient
.
updateBatch
(
list
)
;
}
@Override
public
List
<
SysRolePermission
>
selectByPermissionid
(
String
permissionid
)
{
return
baseMapper
.
selectByPermissionid
(
permissionid
);
SysRolePermissionSearchContext
context
=
new
SysRolePermissionSearchContext
();
context
.
setSize
(
Integer
.
MAX_VALUE
);
context
.
setN_sys_permissionid_eq
(
permissionid
);
return
sysRolePermissionFeignClient
.
searchDefault
(
context
).
getContent
();
}
@Override
public
void
removeByPermissionid
(
String
permissionid
)
{
this
.
remove
(
new
QueryWrapper
<
SysRolePermission
>().
eq
(
"sys_permissionid"
,
permissionid
));
Set
<
String
>
delIds
=
new
HashSet
<
String
>();
for
(
SysRolePermission
before:
selectByPermissionid
(
permissionid
)){
delIds
.
add
(
before
.
getRolepermissionid
());
}
if
(
delIds
.
size
()>
0
)
this
.
removeBatch
(
delIds
);
}
@Override
public
List
<
SysRolePermission
>
selectByRoleid
(
String
roleid
)
{
return
baseMapper
.
selectByRoleid
(
roleid
);
SysRolePermissionSearchContext
context
=
new
SysRolePermissionSearchContext
();
context
.
setSize
(
Integer
.
MAX_VALUE
);
context
.
setN_sys_roleid_eq
(
roleid
);
return
sysRolePermissionFeignClient
.
searchDefault
(
context
).
getContent
();
}
@Override
public
void
removeByRoleid
(
String
roleid
)
{
this
.
remove
(
new
QueryWrapper
<
SysRolePermission
>().
eq
(
"sys_roleid"
,
roleid
));
Set
<
String
>
delIds
=
new
HashSet
<
String
>();
for
(
SysRolePermission
before:
selectByRoleid
(
roleid
)){
delIds
.
add
(
before
.
getRolepermissionid
());
}
if
(
delIds
.
size
()>
0
)
this
.
removeBatch
(
delIds
);
}
/**
* 查询集合 DEFAULT
*/
@Override
public
Page
<
SysRolePermission
>
searchDefault
(
SysRolePermissionSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
SysRolePermission
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
());
return
new
PageImpl
<
SysRolePermission
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
());
}
/**
* 为当前实体填充父数据(外键值文本、外键值附加数据)
* @param et
*/
private
void
fillParentData
(
SysRolePermission
et
){
//实体关系[DER1N_SYS_ROLE_PERMISSION_SYS_PERMISSION_SYS_PERMISSIONID]
if
(!
ObjectUtils
.
isEmpty
(
et
.
getPermissionid
())){
cn
.
ibizlab
.
core
.
uaa
.
domain
.
SysPermission
permission
=
et
.
getPermission
();
if
(
ObjectUtils
.
isEmpty
(
permission
)){
cn
.
ibizlab
.
core
.
uaa
.
domain
.
SysPermission
majorEntity
=
syspermissionService
.
get
(
et
.
getPermissionid
());
et
.
setPermission
(
majorEntity
);
permission
=
majorEntity
;
}
et
.
setPermissionname
(
permission
.
getPermissionname
());
et
.
setPermissiontype
(
permission
.
getPermissiontype
());
et
.
setPermissionenable
(
permission
.
getEnable
());
}
//实体关系[DER1N_SYS_ROLE_PERMISSION_SYS_ROLE_SYS_ROLEID]
if
(!
ObjectUtils
.
isEmpty
(
et
.
getRoleid
())){
cn
.
ibizlab
.
core
.
uaa
.
domain
.
SysRole
role
=
et
.
getRole
();
if
(
ObjectUtils
.
isEmpty
(
role
)){
cn
.
ibizlab
.
core
.
uaa
.
domain
.
SysRole
majorEntity
=
sysroleService
.
get
(
et
.
getRoleid
());
et
.
setRole
(
majorEntity
);
role
=
majorEntity
;
}
et
.
setRolename
(
role
.
getRolename
());
}
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
Page
<
SysRolePermission
>
sysRolePermissions
=
sysRolePermissionFeignClient
.
searchDefault
(
context
);
return
sysRolePermissions
;
}
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/service/impl/SysRoleServiceImpl.java
浏览文件 @
71ffc6c5
...
...
@@ -30,159 +30,103 @@ import cn.ibizlab.core.uaa.service.ISysRoleService;
import
cn.ibizlab.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.core.uaa.mapper.SysRoleMapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.core.uaa.client.SysRoleFeignClient
;
/**
* 实体[系统角色] 服务对象接口实现
*/
@Slf4j
@Service
(
"SysRoleServiceImpl"
)
public
class
SysRoleServiceImpl
extends
ServiceImpl
<
SysRoleMapper
,
SysRole
>
implements
ISysRoleService
{
@Service
public
class
SysRoleServiceImpl
implements
ISysRoleService
{
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
uaa
.
service
.
ISysRolePermissionService
sysrolepermissionService
;
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
uaa
.
service
.
ISysUserRoleService
sysuserroleService
;
SysRoleFeignClient
sysRoleFeignClient
;
private
int
batchSize
=
500
;
@Override
@Transactional
public
boolean
save
(
SysRole
et
)
{
if
(!
saveOrUpdate
(
et
))
if
(
et
.
getRoleid
()==
null
)
et
.
setRoleid
((
String
)
et
.
getDefaultKey
(
true
));
if
(!
sysRoleFeignClient
.
save
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
SysRole
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
}
@Override
public
boolean
saveBatch
(
Collection
<
SysRole
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
SysRole
>
list
)
{
s
aveOrUpdateBatch
(
list
,
batchSize
)
;
s
ysRoleFeignClient
.
saveBatch
(
list
)
;
}
@Override
@Transactional
public
boolean
update
(
SysRole
et
)
{
if
(!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"sys_roleid"
,
et
.
getRoleid
())))
SysRole
rt
=
sysRoleFeignClient
.
update
(
et
.
getRoleid
(),
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getRoleid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
SysRole
>
list
)
{
updateBatchById
(
list
,
batchSize
);
public
void
updateBatch
(
List
<
SysRole
>
list
){
sysRoleFeignClient
.
updateBatch
(
list
)
;
}
@Override
@Transactional
public
boolean
create
(
SysRole
et
)
{
if
(!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
)))
SysRole
rt
=
sysRoleFeignClient
.
create
(
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getRoleid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
SysRole
>
list
)
{
this
.
saveBatch
(
list
,
batchSize
);
public
void
createBatch
(
List
<
SysRole
>
list
){
sysRoleFeignClient
.
createBatch
(
list
)
;
}
@Override
@Transactional
public
SysRole
get
(
String
key
)
{
SysRole
et
=
getById
(
key
);
public
SysRole
get
(
String
roleid
)
{
SysRole
et
=
sysRoleFeignClient
.
get
(
roleid
);
if
(
et
==
null
){
et
=
new
SysRole
();
et
.
setRoleid
(
key
);
et
.
setRoleid
(
roleid
);
}
else
{
}
return
et
;
return
et
;
}
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
return
result
;
public
boolean
remove
(
String
roleid
)
{
boolean
result
=
sysRoleFeignClient
.
remove
(
roleid
)
;
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
public
void
removeBatch
(
Collection
<
String
>
idList
){
sysRoleFeignClient
.
removeBatch
(
idList
);
}
@Override
public
SysRole
getDraft
(
SysRole
et
)
{
et
=
sysRoleFeignClient
.
getDraft
();
return
et
;
}
@Override
public
boolean
checkKey
(
SysRole
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getRoleid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getRoleid
()))
);
return
sysRoleFeignClient
.
checkKey
(
et
);
}
/**
* 查询集合 DEFAULT
*/
@Override
public
Page
<
SysRole
>
searchDefault
(
SysRoleSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
SysRole
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
());
return
new
PageImpl
<
SysRole
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
());
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
Page
<
SysRole
>
sysRoles
=
sysRoleFeignClient
.
searchDefault
(
context
);
return
sysRoles
;
}
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/service/impl/SysUserRoleServiceImpl.java
浏览文件 @
71ffc6c5
...
...
@@ -30,212 +30,139 @@ import cn.ibizlab.core.uaa.service.ISysUserRoleService;
import
cn.ibizlab.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.core.uaa.mapper.SysUserRoleMapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.core.uaa.client.SysUserRoleFeignClient
;
/**
* 实体[用户角色关系] 服务对象接口实现
*/
@Slf4j
@Service
(
"SysUserRoleServiceImpl"
)
public
class
SysUserRoleServiceImpl
extends
ServiceImpl
<
SysUserRoleMapper
,
SysUserRole
>
implements
ISysUserRoleService
{
@Service
public
class
SysUserRoleServiceImpl
implements
ISysUserRoleService
{
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
uaa
.
service
.
ISysRoleService
sysroleService
;
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
uaa
.
service
.
ISysUserService
sysuserService
;
SysUserRoleFeignClient
sysUserRoleFeignClient
;
private
int
batchSize
=
500
;
@Override
public
boolean
checkKey
(
SysUserRole
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getUserroleid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getUserroleid
()))
);
return
sysUserRoleFeignClient
.
checkKey
(
et
);
}
@Override
public
SysUserRole
getDraft
(
SysUserRole
et
)
{
fillParentData
(
et
);
et
=
sysUserRoleFeignClient
.
getDraft
(
);
return
et
;
}
@Override
@Transactional
public
boolean
update
(
SysUserRole
et
)
{
fillParentData
(
et
);
if
(
!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"sys_user_roleid"
,
et
.
getUserroleid
()))
)
SysUserRole
rt
=
sysUserRoleFeignClient
.
update
(
et
.
getUserroleid
(),
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getUserroleid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
SysUserRole
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
updateBatchById
(
list
,
batchSize
);
public
void
updateBatch
(
List
<
SysUserRole
>
list
){
sysUserRoleFeignClient
.
updateBatch
(
list
)
;
}
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
return
result
;
public
boolean
remove
(
String
userroleid
)
{
boolean
result
=
sysUserRoleFeignClient
.
remove
(
userroleid
)
;
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
public
void
removeBatch
(
Collection
<
String
>
idList
){
sysUserRoleFeignClient
.
removeBatch
(
idList
);
}
@Override
@Transactional
public
boolean
create
(
SysUserRole
et
)
{
fillParentData
(
et
);
if
(
!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
))
)
SysUserRole
rt
=
sysUserRoleFeignClient
.
create
(
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getUserroleid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
SysUserRole
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
this
.
saveOrUpdateBatch
(
list
,
batchSize
);
public
void
createBatch
(
List
<
SysUserRole
>
list
){
sysUserRoleFeignClient
.
createBatch
(
list
)
;
}
@Override
@Transactional
public
SysUserRole
get
(
String
key
)
{
SysUserRole
et
=
getById
(
key
);
public
SysUserRole
get
(
String
userroleid
)
{
SysUserRole
et
=
sysUserRoleFeignClient
.
get
(
userroleid
);
if
(
et
==
null
){
et
=
new
SysUserRole
();
et
.
setUserroleid
(
key
);
et
.
setUserroleid
(
userroleid
);
}
else
{
}
return
et
;
return
et
;
}
@Override
@Transactional
public
boolean
save
(
SysUserRole
et
)
{
if
(!
saveOrUpdate
(
et
))
if
(
et
.
getUserroleid
()==
null
)
et
.
setUserroleid
((
String
)
et
.
getDefaultKey
(
true
));
if
(!
sysUserRoleFeignClient
.
save
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
SysUserRole
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
}
@Override
public
boolean
saveBatch
(
Collection
<
SysUserRole
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
SysUserRole
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
saveOrUpdateBatch
(
list
,
batchSize
);
sysUserRoleFeignClient
.
saveBatch
(
list
)
;
}
@Override
public
List
<
SysUserRole
>
selectByRoleid
(
String
roleid
)
{
return
baseMapper
.
selectByRoleid
(
roleid
);
SysUserRoleSearchContext
context
=
new
SysUserRoleSearchContext
();
context
.
setSize
(
Integer
.
MAX_VALUE
);
context
.
setN_sys_roleid_eq
(
roleid
);
return
sysUserRoleFeignClient
.
searchDefault
(
context
).
getContent
();
}
@Override
public
void
removeByRoleid
(
String
roleid
)
{
this
.
remove
(
new
QueryWrapper
<
SysUserRole
>().
eq
(
"sys_roleid"
,
roleid
));
Set
<
String
>
delIds
=
new
HashSet
<
String
>();
for
(
SysUserRole
before:
selectByRoleid
(
roleid
)){
delIds
.
add
(
before
.
getUserroleid
());
}
if
(
delIds
.
size
()>
0
)
this
.
removeBatch
(
delIds
);
}
@Override
public
List
<
SysUserRole
>
selectByUserid
(
String
userid
)
{
return
baseMapper
.
selectByUserid
(
userid
);
SysUserRoleSearchContext
context
=
new
SysUserRoleSearchContext
();
context
.
setSize
(
Integer
.
MAX_VALUE
);
context
.
setN_sys_userid_eq
(
userid
);
return
sysUserRoleFeignClient
.
searchDefault
(
context
).
getContent
();
}
@Override
public
void
removeByUserid
(
String
userid
)
{
this
.
remove
(
new
QueryWrapper
<
SysUserRole
>().
eq
(
"sys_userid"
,
userid
));
Set
<
String
>
delIds
=
new
HashSet
<
String
>();
for
(
SysUserRole
before:
selectByUserid
(
userid
)){
delIds
.
add
(
before
.
getUserroleid
());
}
if
(
delIds
.
size
()>
0
)
this
.
removeBatch
(
delIds
);
}
/**
* 查询集合 DEFAULT
*/
@Override
public
Page
<
SysUserRole
>
searchDefault
(
SysUserRoleSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
SysUserRole
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
());
return
new
PageImpl
<
SysUserRole
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
());
}
/**
* 为当前实体填充父数据(外键值文本、外键值附加数据)
* @param et
*/
private
void
fillParentData
(
SysUserRole
et
){
//实体关系[DER1N_SYS_USER_ROLE_SYS_ROLE_SYS_ROLEID]
if
(!
ObjectUtils
.
isEmpty
(
et
.
getRoleid
())){
cn
.
ibizlab
.
core
.
uaa
.
domain
.
SysRole
role
=
et
.
getRole
();
if
(
ObjectUtils
.
isEmpty
(
role
)){
cn
.
ibizlab
.
core
.
uaa
.
domain
.
SysRole
majorEntity
=
sysroleService
.
get
(
et
.
getRoleid
());
et
.
setRole
(
majorEntity
);
role
=
majorEntity
;
}
et
.
setRolename
(
role
.
getRolename
());
}
//实体关系[DER1N_SYS_USER_ROLE_SYS_USER_SYS_USERID]
if
(!
ObjectUtils
.
isEmpty
(
et
.
getUserid
())){
cn
.
ibizlab
.
core
.
uaa
.
domain
.
SysUser
user
=
et
.
getUser
();
if
(
ObjectUtils
.
isEmpty
(
user
)){
cn
.
ibizlab
.
core
.
uaa
.
domain
.
SysUser
majorEntity
=
sysuserService
.
get
(
et
.
getUserid
());
et
.
setUser
(
majorEntity
);
user
=
majorEntity
;
}
et
.
setPersonname
(
user
.
getPersonname
());
}
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
Page
<
SysUserRole
>
sysUserRoles
=
sysUserRoleFeignClient
.
searchDefault
(
context
);
return
sysUserRoles
;
}
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/uaa/service/impl/SysUserServiceImpl.java
浏览文件 @
71ffc6c5
...
...
@@ -30,156 +30,103 @@ import cn.ibizlab.core.uaa.service.ISysUserService;
import
cn.ibizlab.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.core.uaa.mapper.SysUserMapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.core.uaa.client.SysUserFeignClient
;
/**
* 实体[系统用户] 服务对象接口实现
*/
@Slf4j
@Service
(
"SysUserServiceImpl"
)
public
class
SysUserServiceImpl
extends
ServiceImpl
<
SysUserMapper
,
SysUser
>
implements
ISysUserService
{
@Service
public
class
SysUserServiceImpl
implements
ISysUserService
{
@Autowired
@Lazy
private
cn
.
ibizlab
.
core
.
uaa
.
service
.
ISysUserRoleService
sysuserroleService
;
SysUserFeignClient
sysUserFeignClient
;
private
int
batchSize
=
500
;
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
return
result
;
public
boolean
remove
(
String
userid
)
{
boolean
result
=
sysUserFeignClient
.
remove
(
userid
)
;
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
public
void
removeBatch
(
Collection
<
String
>
idList
){
sysUserFeignClient
.
removeBatch
(
idList
);
}
@Override
@Transactional
public
boolean
update
(
SysUser
et
)
{
if
(!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"userid"
,
et
.
getUserid
())))
SysUser
rt
=
sysUserFeignClient
.
update
(
et
.
getUserid
(),
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getUserid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
SysUser
>
list
)
{
updateBatchById
(
list
,
batchSize
);
public
void
updateBatch
(
List
<
SysUser
>
list
){
sysUserFeignClient
.
updateBatch
(
list
)
;
}
@Override
public
boolean
checkKey
(
SysUser
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getUserid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getUserid
()))
);
return
sysUserFeignClient
.
checkKey
(
et
);
}
@Override
@Transactional
public
SysUser
get
(
String
key
)
{
SysUser
et
=
getById
(
key
);
public
SysUser
get
(
String
userid
)
{
SysUser
et
=
sysUserFeignClient
.
get
(
userid
);
if
(
et
==
null
){
et
=
new
SysUser
();
et
.
setUserid
(
key
);
et
.
setUserid
(
userid
);
}
else
{
}
return
et
;
return
et
;
}
@Override
@Transactional
public
boolean
save
(
SysUser
et
)
{
if
(!
saveOrUpdate
(
et
))
if
(
et
.
getUserid
()==
null
)
et
.
setUserid
((
String
)
et
.
getDefaultKey
(
true
));
if
(!
sysUserFeignClient
.
save
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
SysUser
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
}
@Override
public
boolean
saveBatch
(
Collection
<
SysUser
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
SysUser
>
list
)
{
s
aveOrUpdateBatch
(
list
,
batchSize
)
;
s
ysUserFeignClient
.
saveBatch
(
list
)
;
}
@Override
public
SysUser
getDraft
(
SysUser
et
)
{
et
=
sysUserFeignClient
.
getDraft
();
return
et
;
}
@Override
@Transactional
public
boolean
create
(
SysUser
et
)
{
if
(!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
)))
SysUser
rt
=
sysUserFeignClient
.
create
(
et
);
if
(
rt
==
null
)
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getUserid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
SysUser
>
list
)
{
this
.
saveBatch
(
list
,
batchSize
);
public
void
createBatch
(
List
<
SysUser
>
list
){
sysUserFeignClient
.
createBatch
(
list
)
;
}
/**
* 查询集合 DEFAULT
*/
@Override
public
Page
<
SysUser
>
searchDefault
(
SysUserSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
SysUser
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
());
return
new
PageImpl
<
SysUser
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
());
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
Page
<
SysUser
>
sysUsers
=
sysUserFeignClient
.
searchDefault
(
context
);
return
sysUsers
;
}
...
...
ibzrt-core/src/main/resources/liquibase/h2_table.xml
浏览文件 @
71ffc6c5
...
...
@@ -3,88 +3,10 @@
<!--输出实体[SYS_PSDEOPPRIV]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-sys_psdeoppriv-1-1"
>
<createTable
tableName=
"IBZPSDEOPPRIV"
>
<column
name=
"SYS_PSDEOPPRIVID"
remarks=
""
type=
"VARCHAR(200)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_SYS_PSDEOPPRIV_SYS_PSDEOPPR"
/>
</column>
<column
name=
"SYS_PSDEOPPRIVNAME"
remarks=
""
type=
"VARCHAR(200)"
>
</column>
<column
name=
"PSDATAENTITYID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSDATAENTITYNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSDEDATARANGEID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSDEDATARANGENAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSSYSMODULEID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSSYSMODULENAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSSOURCETYPE"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSSOURCEID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSSOURCENAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSSYSTEMID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"CREATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"UPDATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
</createTable>
</changeSet>
<!--输出实体[IBZORG]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-ibzorg-5-2"
>
<createTable
tableName=
"IBZORG"
>
<column
name=
"ORGID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_IBZORG_ORGID"
/>
</column>
<column
name=
"ORGCODE"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"ORGNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PORGID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"SHORTNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"ORGLEVEL"
remarks=
""
type=
"INT"
>
</column>
<column
name=
"SHOWORDER"
remarks=
""
type=
"INT"
>
</column>
<column
name=
"ENABLE"
remarks=
""
type=
"INT"
>
</column>
<column
name=
"CREATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"UPDATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_PSSYSUNIRES]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-sys_pssysunires-1-3"
>
<createTable
tableName=
"IBZPSSYSUNIRES"
>
<column
name=
"SYS_PSSYSUNIRESID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_SYS_PSSYSUNIRES_SYS_PSSYSUN"
/>
</column>
<column
name=
"SYS_PSSYSUNIRESNAME"
remarks=
""
type=
"VARCHAR(200)"
>
</column>
<column
name=
"UNIRESCODE"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSSYSTEMID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"CREATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"UPDATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
</createTable>
</changeSet>
...
...
@@ -95,92 +17,20 @@
<!--输出实体[SYS_PSAPPMENUITEM]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-sys_psappmenuitem-1-4"
>
<createTable
tableName=
"IBZPSAPPMENUITEM"
>
<column
name=
"SYS_PSAPPMENUITEMID"
remarks=
""
type=
"VARCHAR(200)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_SYS_PSAPPMENUITEM_SYS_PSAPP"
/>
</column>
<column
name=
"SYS_PSAPPMENUITEMNAME"
remarks=
""
type=
"VARCHAR(200)"
>
</column>
<column
name=
"PSAPPID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSAPPNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSAPPMENUID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSAPPMENUNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSAPPMENUITEMID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSAPPPMENUITEMID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PSSYSTEMID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"CREATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"UPDATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_AUTHLOG]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-sys_authlog-1-5"
>
<createTable
tableName=
"IBZAUTHLOG"
>
<column
name=
"LOGID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_SYS_AUTHLOG_LOGID"
/>
</column>
<column
name=
"USERNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PERSONNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"DOMAIN"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"AUTHTIME"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"IPADDR"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"MACADDR"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"USERAGENT"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"AUTHCODE"
remarks=
""
type=
"VARCHAR(15)"
>
</column>
</createTable>
</changeSet>
<!--输出实体[IBZDICT]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-ibzdict-1-6"
>
<createTable
tableName=
"IBZDICT"
>
<column
name=
"IBZDICTID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_IBZDICT_IBZDICTID"
/>
</column>
<column
name=
"IBZDICTNAME"
remarks=
""
type=
"VARCHAR(200)"
>
</column>
<column
name=
"ENABLE"
remarks=
""
type=
"INT"
>
</column>
<column
name=
"CREATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"UPDATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"CREATEMAN"
remarks=
""
type=
"VARCHAR(60)"
>
</column>
<column
name=
"UPDATEMAN"
remarks=
""
type=
"VARCHAR(60)"
>
</column>
<column
name=
"CFG"
remarks=
""
type=
"TEXT(1048576)"
>
</column>
</createTable>
</changeSet>
<!--输出实体[WF_GROUP]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-wf_group-2-
7
"
>
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-wf_group-2-
1
"
>
<createTable
tableName=
"IBZWFGROUP"
>
<column
name=
"GROUPID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_WF_GROUP_GROUPID"
/>
...
...
@@ -193,312 +43,23 @@
</changeSet>
<!--输出实体[IBZEMP]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-ibzemp-5-8"
>
<createTable
tableName=
"IBZEMP"
>
<column
name=
"USERID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_IBZEMP_USERID"
/>
</column>
<column
name=
"USERNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PERSONNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"USERCODE"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"LOGINNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PASSWORD"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"DOMAINS"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"MDEPTID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"MDEPTCODE"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"MDEPTNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"BCODE"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"POSTID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"POSTCODE"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"POSTNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"ORGID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"ORGCODE"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"ORGNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"NICKNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"SEX"
remarks=
""
type=
"VARCHAR(20)"
>
</column>
<column
name=
"CERTCODE"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PHONE"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"BIRTHDAY"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"EMAIL"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"AVATAR"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"ADDR"
remarks=
""
type=
"VARCHAR(255)"
>
</column>
<column
name=
"USERICON"
remarks=
""
type=
"VARCHAR(255)"
>
</column>
<column
name=
"IPADDR"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"THEME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"LANG"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"FONTSIZE"
remarks=
""
type=
"VARCHAR(10)"
>
</column>
<column
name=
"MEMO"
remarks=
""
type=
"VARCHAR(255)"
>
</column>
<column
name=
"RESERVER"
remarks=
""
type=
"VARCHAR(255)"
>
</column>
<column
name=
"SHOWORDER"
remarks=
""
type=
"INT"
>
</column>
<column
name=
"ENABLE"
remarks=
""
type=
"INT"
>
</column>
<column
name=
"CREATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"UPDATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_PSSYSTEM]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-sys_pssystem-1-9"
>
<createTable
tableName=
"IBZPSSYSTEM"
>
<column
name=
"PSSYSTEMID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_SYS_PSSYSTEM_PSSYSTEMID"
/>
</column>
<column
name=
"PSSYSTEMNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"SYSSTRUCTURE"
remarks=
""
type=
"TEXT(1048576)"
>
</column>
</createTable>
</changeSet>
<!--输出实体[IBZDEPTMEMBER]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-ibzdeptmember-4-10"
>
<createTable
tableName=
"IBZDEPTMEMBER"
>
<column
name=
"MEMBERID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_IBZDEPTMEMBER_MEMBERID"
/>
</column>
<column
name=
"DEPTID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"USERID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_ROLE]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-sys_role-4-11"
>
<createTable
tableName=
"IBZROLE"
>
<column
name=
"SYS_ROLEID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_SYS_ROLE_SYS_ROLEID"
/>
</column>
<column
name=
"SYS_ROLENAME"
remarks=
""
type=
"VARCHAR(200)"
>
</column>
<column
name=
"MEMO"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"CREATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"UPDATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
</createTable>
</changeSet>
<!--输出实体[IBZDEPT]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-ibzdept-5-12"
>
<createTable
tableName=
"IBZDEPT"
>
<column
name=
"DEPTID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_IBZDEPT_DEPTID"
/>
</column>
<column
name=
"DEPTCODE"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"DEPTNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"ORGID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PDEPTID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"SHORTNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"DEPTLEVEL"
remarks=
""
type=
"INT"
>
</column>
<column
name=
"SHOWORDER"
remarks=
""
type=
"INT"
>
</column>
<column
name=
"BCODE"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"LEADERID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"LEADERNAME"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"ENABLE"
remarks=
""
type=
"INT"
>
</column>
<column
name=
"CREATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"UPDATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
</createTable>
</changeSet>
<!--输出实体[IBZDICTITEM]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-ibzdictitem-1-13"
>
<createTable
tableName=
"IBZDICTITEM"
>
<column
name=
"IBZDICTITEMID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_IBZDICTITEM_IBZDICTITEMID"
/>
</column>
<column
name=
"IBZDICTITEMNAME"
remarks=
""
type=
"VARCHAR(200)"
>
</column>
<column
name=
"DICTITEMVAL"
remarks=
""
type=
"VARCHAR(30)"
>
</column>
<column
name=
"DICTID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"PITEMVAL"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"ITEMFILTER"
remarks=
""
type=
"VARCHAR(500)"
>
</column>
<column
name=
"ITEMCLS"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"ITEMICON"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"SHOWORDER"
remarks=
""
type=
"INT"
>
</column>
<column
name=
"CREATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"UPDATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"UPDATEMAN"
remarks=
""
type=
"VARCHAR(60)"
>
</column>
<column
name=
"CREATEMAN"
remarks=
""
type=
"VARCHAR(60)"
>
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_ROLE_PERMISSION]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-sys_role_permission-3-14"
>
<createTable
tableName=
"IBZROLE_PERMISSION"
>
<column
name=
"SYS_ROLE_PERMISSIONID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_SYS_ROLE_PERMISSION_SYS_ROL"
/>
</column>
<column
name=
"SYS_ROLEID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"SYS_PERMISSIONID"
remarks=
""
type=
"VARCHAR(200)"
>
</column>
<column
name=
"CREATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"UPDATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_USER_ROLE]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-sys_user_role-4-15"
>
<createTable
tableName=
"IBZUSER_ROLE"
>
<column
name=
"SYS_USER_ROLEID"
remarks=
""
type=
"VARCHAR(100)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_SYS_USER_ROLE_SYS_USER_ROLE"
/>
</column>
<column
name=
"SYS_ROLEID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"SYS_USERID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"CREATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"UPDATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_PERMISSION]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-sys_permission-1-16"
>
<createTable
tableName=
"IBZPERMISSION"
>
<column
name=
"SYS_PERMISSIONID"
remarks=
""
type=
"VARCHAR(200)"
>
<constraints
primaryKey=
"true"
primaryKeyName=
"PK_SYS_PERMISSION_SYS_PERMISSI"
/>
</column>
<column
name=
"SYS_PERMISSIONNAME"
remarks=
""
type=
"VARCHAR(200)"
>
</column>
<column
name=
"PERMISSIONTYPE"
remarks=
""
type=
"VARCHAR(60)"
>
</column>
<column
name=
"PSSYSTEMID"
remarks=
""
type=
"VARCHAR(100)"
>
</column>
<column
name=
"ENABLE"
remarks=
""
type=
"INT"
>
</column>
<column
name=
"CREATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
<column
name=
"UPDATEDATE"
remarks=
""
type=
"DATETIME"
>
</column>
</createTable>
</changeSet>
<!--输出实体[SYS_PSDEOPPRIV]外键关系 -->
<!--输出实体[IBZORG]外键关系 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"fk-ibzorg-5-17"
>
<addForeignKeyConstraint
baseColumnNames=
"PORGID"
baseTableName=
"IBZORG"
constraintName=
"DER1N_IBZORG_IBZORG_PORGID"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"ORGID"
referencedTableName=
"IBZORG"
validate=
"true"
/>
</changeSet>
<!--输出实体[SYS_PSSYSUNIRES]外键关系 -->
<!--输出实体[SYS_PSAPPMENUITEM]外键关系 -->
<!--输出实体[SYS_AUTHLOG]外键关系 -->
<!--输出实体[IBZDICT]外键关系 -->
<!--输出实体[WF_GROUP]外键关系 -->
<!--输出实体[IBZEMP]外键关系 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"fk-ibzemp-5-18"
>
<addForeignKeyConstraint
baseColumnNames=
"MDEPTID"
baseTableName=
"IBZEMP"
constraintName=
"DER1N_IBZEMP_IBZDEPT_MDEPTID"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"DEPTID"
referencedTableName=
"IBZDEPT"
validate=
"true"
/>
</changeSet>
<changeSet
author=
"a_A_5d9d78509"
id=
"fk-ibzemp-5-19"
>
<addForeignKeyConstraint
baseColumnNames=
"ORGID"
baseTableName=
"IBZEMP"
constraintName=
"DER1N_IBZEMP_IBZORG_ORGID"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"ORGID"
referencedTableName=
"IBZORG"
validate=
"true"
/>
</changeSet>
<!--输出实体[SYS_PSSYSTEM]外键关系 -->
<!--输出实体[IBZDEPTMEMBER]外键关系 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"fk-ibzdeptmember-4-20"
>
<addForeignKeyConstraint
baseColumnNames=
"DEPTID"
baseTableName=
"IBZDEPTMEMBER"
constraintName=
"DER1N_IBZDEPTMEMBER_IBZDEPT_DE"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"DEPTID"
referencedTableName=
"IBZDEPT"
validate=
"true"
/>
</changeSet>
<changeSet
author=
"a_A_5d9d78509"
id=
"fk-ibzdeptmember-4-21"
>
<addForeignKeyConstraint
baseColumnNames=
"USERID"
baseTableName=
"IBZDEPTMEMBER"
constraintName=
"DER1N_IBZDEPTMEMBER_IBZEMP_USE"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"USERID"
referencedTableName=
"IBZEMP"
validate=
"true"
/>
</changeSet>
<!--输出实体[SYS_ROLE]外键关系 -->
<!--输出实体[IBZDEPT]外键关系 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"fk-ibzdept-5-22"
>
<addForeignKeyConstraint
baseColumnNames=
"PDEPTID"
baseTableName=
"IBZDEPT"
constraintName=
"DER1N_IBZDEPT_IBZDEPT_PDEPTID"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"DEPTID"
referencedTableName=
"IBZDEPT"
validate=
"true"
/>
</changeSet>
<changeSet
author=
"a_A_5d9d78509"
id=
"fk-ibzdept-5-23"
>
<addForeignKeyConstraint
baseColumnNames=
"ORGID"
baseTableName=
"IBZDEPT"
constraintName=
"DER1N_IBZDEPT_IBZORG_ORGID"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"ORGID"
referencedTableName=
"IBZORG"
validate=
"true"
/>
</changeSet>
<!--输出实体[IBZDICTITEM]外键关系 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"fk-ibzdictitem-1-24"
>
<addForeignKeyConstraint
baseColumnNames=
"DICTID"
baseTableName=
"IBZDICTITEM"
constraintName=
"DER1N_IBZDICTITEM_IBZDICT_DICT"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"IBZDICTID"
referencedTableName=
"IBZDICT"
validate=
"true"
/>
</changeSet>
<!--输出实体[SYS_ROLE_PERMISSION]外键关系 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"fk-sys_role_permission-3-25"
>
<addForeignKeyConstraint
baseColumnNames=
"SYS_PERMISSIONID"
baseTableName=
"IBZROLE_PERMISSION"
constraintName=
"DER1N_SYS_ROLE_PERMISSION_SYS_"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"SYS_PERMISSIONID"
referencedTableName=
"IBZPERMISSION"
validate=
"true"
/>
</changeSet>
<!--输出实体[SYS_USER_ROLE]外键关系 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"fk-sys_user_role-4-27"
>
<addForeignKeyConstraint
baseColumnNames=
"SYS_ROLEID"
baseTableName=
"IBZUSER_ROLE"
constraintName=
"DER1N_SYS_USER_ROLE_SYS_ROLE_S"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"SYS_ROLEID"
referencedTableName=
"IBZROLE"
validate=
"true"
/>
</changeSet>
<!--输出实体[SYS_PERMISSION]外键关系 -->
</databaseChangeLog>
ibzrt-core/src/main/resources/rules/IBZEmployeesaveDeptMemberRuleFlow.bpmn
浏览文件 @
71ffc6c5
...
...
@@ -13,9 +13,9 @@
<businessRuleTask
activiti:exclusive=
"true"
g:ruleFlowGroup=
"ibzemployeesavedeptmemberdeaction1"
id=
"9c1c19bacf602767e76375b11255b4ec"
implementation=
"http://www.jboss.org/drools/rule"
name=
"保存成员"
/>
<endEvent
id=
"9c1c19bacf602767e76375b11255b4ec_End"
name=
"End"
/>
<sequenceFlow
id=
"9c1c19bacf602767e76375b11255b4ec_End_Line"
sourceRef=
"9c1c19bacf602767e76375b11255b4ec"
targetRef=
"9c1c19bacf602767e76375b11255b4ec_End"
/>
<sequenceFlow
id=
"
0b057ff7e1abde2175b8c51ec4c2ac4a
"
sourceRef=
"185d3d9e0375d4a0bc23e2b5e0c5d6b0"
targetRef=
"4ce2ddabe497161f1eafae705330da51"
>
<sequenceFlow
id=
"
971ab2847fdbdbdc4db12c939a1b971f
"
sourceRef=
"185d3d9e0375d4a0bc23e2b5e0c5d6b0"
targetRef=
"4ce2ddabe497161f1eafae705330da51"
>
</sequenceFlow>
<sequenceFlow
id=
"
f6db416cc2fdd6c6dfe512fac95e5a88
"
sourceRef=
"4ce2ddabe497161f1eafae705330da51"
targetRef=
"9c1c19bacf602767e76375b11255b4ec"
>
<sequenceFlow
id=
"
ae783381200010e818d657ead98d3a00
"
sourceRef=
"4ce2ddabe497161f1eafae705330da51"
targetRef=
"9c1c19bacf602767e76375b11255b4ec"
>
</sequenceFlow>
</process>
</definitions>
...
...
ibzrt-provider/ibzrt-provider-api/src/main/java/cn/ibizlab/api/rest/IBZDepartmentResource.java
浏览文件 @
71ffc6c5
...
...
@@ -11,7 +11,7 @@ import com.alibaba.fastjson.JSONObject;
import
javax.servlet.ServletRequest
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cglib.beans.BeanCopier
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.http.HttpStatus
;
...
...
@@ -46,14 +46,12 @@ public class IBZDepartmentResource {
@Lazy
public
IBZDepartmentMapping
ibzdepartmentMapping
;
@PreAuthorize
(
"hasPermission(this.ibzdepartmentMapping.toDomain(#ibzdepartmentdto),'ibzrt-IBZDepartment-Save')"
)
@ApiOperation
(
value
=
"Save"
,
tags
=
{
"IBZDepartment"
},
notes
=
"Save"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/save"
)
public
ResponseEntity
<
Boolean
>
save
(
@RequestBody
IBZDepartmentDTO
ibzdepartmentdto
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzdepartmentService
.
save
(
ibzdepartmentMapping
.
toDomain
(
ibzdepartmentdto
)));
}
@PreAuthorize
(
"hasPermission(this.ibzdepartmentMapping.toDomain(#ibzdepartmentdtos),'ibzrt-IBZDepartment-Save')"
)
@ApiOperation
(
value
=
"SaveBatch"
,
tags
=
{
"IBZDepartment"
},
notes
=
"SaveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/savebatch"
)
public
ResponseEntity
<
Boolean
>
saveBatch
(
@RequestBody
List
<
IBZDepartmentDTO
>
ibzdepartmentdtos
)
{
...
...
@@ -61,7 +59,6 @@ public class IBZDepartmentResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PostAuthorize
(
"hasPermission(this.ibzdepartmentMapping.toDomain(returnObject.body),'ibzrt-IBZDepartment-Get')"
)
@ApiOperation
(
value
=
"Get"
,
tags
=
{
"IBZDepartment"
},
notes
=
"Get"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdepartments/{ibzdepartment_id}"
)
public
ResponseEntity
<
IBZDepartmentDTO
>
get
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
)
{
...
...
@@ -70,15 +67,13 @@ public class IBZDepartmentResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasPermission(this.ibzdepartmentService.get(#ibzdepartment_id),'ibzrt-IBZDepartment-Remove')"
)
@ApiOperation
(
value
=
"Remove"
,
tags
=
{
"IBZDepartment"
},
notes
=
"Remove"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdepartments/{ibzdepartment_id}"
)
@Transactional
public
ResponseEntity
<
Boolean
>
remove
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzdepartmentService
.
remove
(
ibzdepartment_id
));
}
@PreAuthorize
(
"hasPermission(this.ibzdepartmentService.getIbzdepartmentByIds(#ids),'ibzrt-IBZDepartment-Remove')"
)
@ApiOperation
(
value
=
"RemoveBatch"
,
tags
=
{
"IBZDepartment"
},
notes
=
"RemoveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdepartments/batch"
)
public
ResponseEntity
<
Boolean
>
removeBatch
(
@RequestBody
List
<
String
>
ids
)
{
...
...
@@ -92,10 +87,9 @@ public class IBZDepartmentResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzdepartmentService
.
checkKey
(
ibzdepartmentMapping
.
toDomain
(
ibzdepartmentdto
)));
}
@PreAuthorize
(
"hasPermission(this.ibzdepartmentService.get(#ibzdepartment_id),'ibzrt-IBZDepartment-Update')"
)
@ApiOperation
(
value
=
"Update"
,
tags
=
{
"IBZDepartment"
},
notes
=
"Update"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdepartments/{ibzdepartment_id}"
)
@Transactional
public
ResponseEntity
<
IBZDepartmentDTO
>
update
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
IBZDepartmentDTO
ibzdepartmentdto
)
{
IBZDepartment
domain
=
ibzdepartmentMapping
.
toDomain
(
ibzdepartmentdto
);
domain
.
setDeptid
(
ibzdepartment_id
);
...
...
@@ -104,7 +98,6 @@ public class IBZDepartmentResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasPermission(this.ibzdepartmentService.getIbzdepartmentByEntities(this.ibzdepartmentMapping.toDomain(#ibzdepartmentdtos)),'ibzrt-IBZDepartment-Update')"
)
@ApiOperation
(
value
=
"UpdateBatch"
,
tags
=
{
"IBZDepartment"
},
notes
=
"UpdateBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdepartments/batch"
)
public
ResponseEntity
<
Boolean
>
updateBatch
(
@RequestBody
List
<
IBZDepartmentDTO
>
ibzdepartmentdtos
)
{
...
...
@@ -112,10 +105,9 @@ public class IBZDepartmentResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasPermission(this.ibzdepartmentMapping.toDomain(#ibzdepartmentdto),'ibzrt-IBZDepartment-Create')"
)
@ApiOperation
(
value
=
"Create"
,
tags
=
{
"IBZDepartment"
},
notes
=
"Create"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments"
)
@Transactional
public
ResponseEntity
<
IBZDepartmentDTO
>
create
(
@RequestBody
IBZDepartmentDTO
ibzdepartmentdto
)
{
IBZDepartment
domain
=
ibzdepartmentMapping
.
toDomain
(
ibzdepartmentdto
);
ibzdepartmentService
.
create
(
domain
);
...
...
@@ -123,7 +115,6 @@ public class IBZDepartmentResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasPermission(this.ibzdepartmentMapping.toDomain(#ibzdepartmentdtos),'ibzrt-IBZDepartment-Create')"
)
@ApiOperation
(
value
=
"createBatch"
,
tags
=
{
"IBZDepartment"
},
notes
=
"createBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/batch"
)
public
ResponseEntity
<
Boolean
>
createBatch
(
@RequestBody
List
<
IBZDepartmentDTO
>
ibzdepartmentdtos
)
{
...
...
@@ -137,7 +128,6 @@ public class IBZDepartmentResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzdepartmentMapping
.
toDto
(
ibzdepartmentService
.
getDraft
(
new
IBZDepartment
())));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZDepartment-CurDept-all')"
)
@ApiOperation
(
value
=
"fetchCurDept"
,
tags
=
{
"IBZDepartment"
}
,
notes
=
"fetchCurDept"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdepartments/fetchcurdept"
)
public
ResponseEntity
<
List
<
IBZDepartmentDTO
>>
fetchCurDept
(
IBZDepartmentSearchContext
context
)
{
...
...
@@ -150,7 +140,6 @@ public class IBZDepartmentResource {
.
body
(
list
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZDepartment-CurDept-all')"
)
@ApiOperation
(
value
=
"searchCurDept"
,
tags
=
{
"IBZDepartment"
}
,
notes
=
"searchCurDept"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/searchcurdept"
)
public
ResponseEntity
<
Page
<
IBZDepartmentDTO
>>
searchCurDept
(
@RequestBody
IBZDepartmentSearchContext
context
)
{
...
...
@@ -158,7 +147,6 @@ public class IBZDepartmentResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
)
.
body
(
new
PageImpl
(
ibzdepartmentMapping
.
toDto
(
domains
.
getContent
()),
context
.
getPageable
(),
domains
.
getTotalElements
()));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZDepartment-Default-all')"
)
@ApiOperation
(
value
=
"fetchDEFAULT"
,
tags
=
{
"IBZDepartment"
}
,
notes
=
"fetchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdepartments/fetchdefault"
)
public
ResponseEntity
<
List
<
IBZDepartmentDTO
>>
fetchDefault
(
IBZDepartmentSearchContext
context
)
{
...
...
@@ -171,7 +159,6 @@ public class IBZDepartmentResource {
.
body
(
list
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZDepartment-Default-all')"
)
@ApiOperation
(
value
=
"searchDEFAULT"
,
tags
=
{
"IBZDepartment"
}
,
notes
=
"searchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/searchdefault"
)
public
ResponseEntity
<
Page
<
IBZDepartmentDTO
>>
searchDefault
(
@RequestBody
IBZDepartmentSearchContext
context
)
{
...
...
ibzrt-provider/ibzrt-provider-api/src/main/java/cn/ibizlab/api/rest/IBZDeptMemberResource.java
浏览文件 @
71ffc6c5
...
...
@@ -11,7 +11,7 @@ import com.alibaba.fastjson.JSONObject;
import
javax.servlet.ServletRequest
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cglib.beans.BeanCopier
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.http.HttpStatus
;
...
...
@@ -46,10 +46,9 @@ public class IBZDeptMemberResource {
@Lazy
public
IBZDeptMemberMapping
ibzdeptmemberMapping
;
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZDeptMember-Update-all')"
)
@ApiOperation
(
value
=
"Update"
,
tags
=
{
"IBZDeptMember"
},
notes
=
"Update"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdeptmembers/{ibzdeptmember_id}"
)
@Transactional
public
ResponseEntity
<
IBZDeptMemberDTO
>
update
(
@PathVariable
(
"ibzdeptmember_id"
)
String
ibzdeptmember_id
,
@RequestBody
IBZDeptMemberDTO
ibzdeptmemberdto
)
{
IBZDeptMember
domain
=
ibzdeptmemberMapping
.
toDomain
(
ibzdeptmemberdto
);
domain
.
setMemberid
(
ibzdeptmember_id
);
...
...
@@ -58,7 +57,6 @@ public class IBZDeptMemberResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZDeptMember-Update-all')"
)
@ApiOperation
(
value
=
"UpdateBatch"
,
tags
=
{
"IBZDeptMember"
},
notes
=
"UpdateBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdeptmembers/batch"
)
public
ResponseEntity
<
Boolean
>
updateBatch
(
@RequestBody
List
<
IBZDeptMemberDTO
>
ibzdeptmemberdtos
)
{
...
...
@@ -66,7 +64,6 @@ public class IBZDeptMemberResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZDeptMember-Get-all')"
)
@ApiOperation
(
value
=
"Get"
,
tags
=
{
"IBZDeptMember"
},
notes
=
"Get"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdeptmembers/{ibzdeptmember_id}"
)
public
ResponseEntity
<
IBZDeptMemberDTO
>
get
(
@PathVariable
(
"ibzdeptmember_id"
)
String
ibzdeptmember_id
)
{
...
...
@@ -81,15 +78,13 @@ public class IBZDeptMemberResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzdeptmemberService
.
checkKey
(
ibzdeptmemberMapping
.
toDomain
(
ibzdeptmemberdto
)));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZDeptMember-Remove-all')"
)
@ApiOperation
(
value
=
"Remove"
,
tags
=
{
"IBZDeptMember"
},
notes
=
"Remove"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdeptmembers/{ibzdeptmember_id}"
)
@Transactional
public
ResponseEntity
<
Boolean
>
remove
(
@PathVariable
(
"ibzdeptmember_id"
)
String
ibzdeptmember_id
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzdeptmemberService
.
remove
(
ibzdeptmember_id
));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZDeptMember-Remove-all')"
)
@ApiOperation
(
value
=
"RemoveBatch"
,
tags
=
{
"IBZDeptMember"
},
notes
=
"RemoveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdeptmembers/batch"
)
public
ResponseEntity
<
Boolean
>
removeBatch
(
@RequestBody
List
<
String
>
ids
)
{
...
...
@@ -97,10 +92,9 @@ public class IBZDeptMemberResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZDeptMember-Create-all')"
)
@ApiOperation
(
value
=
"Create"
,
tags
=
{
"IBZDeptMember"
},
notes
=
"Create"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdeptmembers"
)
@Transactional
public
ResponseEntity
<
IBZDeptMemberDTO
>
create
(
@RequestBody
IBZDeptMemberDTO
ibzdeptmemberdto
)
{
IBZDeptMember
domain
=
ibzdeptmemberMapping
.
toDomain
(
ibzdeptmemberdto
);
ibzdeptmemberService
.
create
(
domain
);
...
...
@@ -108,7 +102,6 @@ public class IBZDeptMemberResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZDeptMember-Create-all')"
)
@ApiOperation
(
value
=
"createBatch"
,
tags
=
{
"IBZDeptMember"
},
notes
=
"createBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdeptmembers/batch"
)
public
ResponseEntity
<
Boolean
>
createBatch
(
@RequestBody
List
<
IBZDeptMemberDTO
>
ibzdeptmemberdtos
)
{
...
...
@@ -122,14 +115,12 @@ public class IBZDeptMemberResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzdeptmemberMapping
.
toDto
(
ibzdeptmemberService
.
getDraft
(
new
IBZDeptMember
())));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZDeptMember-Save-all')"
)
@ApiOperation
(
value
=
"Save"
,
tags
=
{
"IBZDeptMember"
},
notes
=
"Save"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdeptmembers/save"
)
public
ResponseEntity
<
Boolean
>
save
(
@RequestBody
IBZDeptMemberDTO
ibzdeptmemberdto
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzdeptmemberService
.
save
(
ibzdeptmemberMapping
.
toDomain
(
ibzdeptmemberdto
)));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZDeptMember-Save-all')"
)
@ApiOperation
(
value
=
"SaveBatch"
,
tags
=
{
"IBZDeptMember"
},
notes
=
"SaveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdeptmembers/savebatch"
)
public
ResponseEntity
<
Boolean
>
saveBatch
(
@RequestBody
List
<
IBZDeptMemberDTO
>
ibzdeptmemberdtos
)
{
...
...
@@ -137,7 +128,6 @@ public class IBZDeptMemberResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZDeptMember-Default-all')"
)
@ApiOperation
(
value
=
"fetchDEFAULT"
,
tags
=
{
"IBZDeptMember"
}
,
notes
=
"fetchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdeptmembers/fetchdefault"
)
public
ResponseEntity
<
List
<
IBZDeptMemberDTO
>>
fetchDefault
(
IBZDeptMemberSearchContext
context
)
{
...
...
@@ -150,7 +140,6 @@ public class IBZDeptMemberResource {
.
body
(
list
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZDeptMember-Default-all')"
)
@ApiOperation
(
value
=
"searchDEFAULT"
,
tags
=
{
"IBZDeptMember"
}
,
notes
=
"searchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdeptmembers/searchdefault"
)
public
ResponseEntity
<
Page
<
IBZDeptMemberDTO
>>
searchDefault
(
@RequestBody
IBZDeptMemberSearchContext
context
)
{
...
...
ibzrt-provider/ibzrt-provider-api/src/main/java/cn/ibizlab/api/rest/IBZEmployeeResource.java
浏览文件 @
71ffc6c5
...
...
@@ -11,7 +11,7 @@ import com.alibaba.fastjson.JSONObject;
import
javax.servlet.ServletRequest
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cglib.beans.BeanCopier
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.http.HttpStatus
;
...
...
@@ -46,15 +46,13 @@ public class IBZEmployeeResource {
@Lazy
public
IBZEmployeeMapping
ibzemployeeMapping
;
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.get(#ibzemployee_id),'ibzrt-IBZEmployee-Remove')"
)
@ApiOperation
(
value
=
"Remove"
,
tags
=
{
"IBZEmployee"
},
notes
=
"Remove"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzemployees/{ibzemployee_id}"
)
@Transactional
public
ResponseEntity
<
Boolean
>
remove
(
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
remove
(
ibzemployee_id
));
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.getIbzemployeeByIds(#ids),'ibzrt-IBZEmployee-Remove')"
)
@ApiOperation
(
value
=
"RemoveBatch"
,
tags
=
{
"IBZEmployee"
},
notes
=
"RemoveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzemployees/batch"
)
public
ResponseEntity
<
Boolean
>
removeBatch
(
@RequestBody
List
<
String
>
ids
)
{
...
...
@@ -62,10 +60,9 @@ public class IBZEmployeeResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.get(#ibzemployee_id),'ibzrt-IBZEmployee-Update')"
)
@ApiOperation
(
value
=
"Update"
,
tags
=
{
"IBZEmployee"
},
notes
=
"Update"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzemployees/{ibzemployee_id}"
)
@Transactional
public
ResponseEntity
<
IBZEmployeeDTO
>
update
(
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
domain
.
setUserid
(
ibzemployee_id
);
...
...
@@ -74,7 +71,6 @@ public class IBZEmployeeResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.getIbzemployeeByEntities(this.ibzemployeeMapping.toDomain(#ibzemployeedtos)),'ibzrt-IBZEmployee-Update')"
)
@ApiOperation
(
value
=
"UpdateBatch"
,
tags
=
{
"IBZEmployee"
},
notes
=
"UpdateBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzemployees/batch"
)
public
ResponseEntity
<
Boolean
>
updateBatch
(
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
...
...
@@ -88,7 +84,6 @@ public class IBZEmployeeResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
checkKey
(
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
)));
}
@PostAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(returnObject.body),'ibzrt-IBZEmployee-Get')"
)
@ApiOperation
(
value
=
"Get"
,
tags
=
{
"IBZEmployee"
},
notes
=
"Get"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzemployees/{ibzemployee_id}"
)
public
ResponseEntity
<
IBZEmployeeDTO
>
get
(
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
...
...
@@ -97,14 +92,12 @@ public class IBZEmployeeResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedto),'ibzrt-IBZEmployee-Save')"
)
@ApiOperation
(
value
=
"Save"
,
tags
=
{
"IBZEmployee"
},
notes
=
"Save"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/save"
)
public
ResponseEntity
<
Boolean
>
save
(
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
save
(
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
)));
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedtos),'ibzrt-IBZEmployee-Save')"
)
@ApiOperation
(
value
=
"SaveBatch"
,
tags
=
{
"IBZEmployee"
},
notes
=
"SaveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/savebatch"
)
public
ResponseEntity
<
Boolean
>
saveBatch
(
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
...
...
@@ -112,10 +105,9 @@ public class IBZEmployeeResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZEmployee-InitPwd-all')"
)
@ApiOperation
(
value
=
"初始化密码"
,
tags
=
{
"IBZEmployee"
},
notes
=
"初始化密码"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/{ibzemployee_id}/initpwd"
)
@Transactional
public
ResponseEntity
<
IBZEmployeeDTO
>
initPwd
(
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
IBZEmployee
ibzemployee
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
ibzemployee
.
setUserid
(
ibzemployee_id
);
...
...
@@ -130,10 +122,9 @@ public class IBZEmployeeResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeMapping
.
toDto
(
ibzemployeeService
.
getDraft
(
new
IBZEmployee
())));
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedto),'ibzrt-IBZEmployee-Create')"
)
@ApiOperation
(
value
=
"Create"
,
tags
=
{
"IBZEmployee"
},
notes
=
"Create"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees"
)
@Transactional
public
ResponseEntity
<
IBZEmployeeDTO
>
create
(
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
ibzemployeeService
.
create
(
domain
);
...
...
@@ -141,7 +132,6 @@ public class IBZEmployeeResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedtos),'ibzrt-IBZEmployee-Create')"
)
@ApiOperation
(
value
=
"createBatch"
,
tags
=
{
"IBZEmployee"
},
notes
=
"createBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/batch"
)
public
ResponseEntity
<
Boolean
>
createBatch
(
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
...
...
@@ -149,7 +139,6 @@ public class IBZEmployeeResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZEmployee-Default-all')"
)
@ApiOperation
(
value
=
"fetchDEFAULT"
,
tags
=
{
"IBZEmployee"
}
,
notes
=
"fetchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzemployees/fetchdefault"
)
public
ResponseEntity
<
List
<
IBZEmployeeDTO
>>
fetchDefault
(
IBZEmployeeSearchContext
context
)
{
...
...
@@ -162,7 +151,6 @@ public class IBZEmployeeResource {
.
body
(
list
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZEmployee-Default-all')"
)
@ApiOperation
(
value
=
"searchDEFAULT"
,
tags
=
{
"IBZEmployee"
}
,
notes
=
"searchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/searchdefault"
)
public
ResponseEntity
<
Page
<
IBZEmployeeDTO
>>
searchDefault
(
@RequestBody
IBZEmployeeSearchContext
context
)
{
...
...
ibzrt-provider/ibzrt-provider-api/src/main/java/cn/ibizlab/api/rest/IBZOrganizationResource.java
浏览文件 @
71ffc6c5
...
...
@@ -11,7 +11,7 @@ import com.alibaba.fastjson.JSONObject;
import
javax.servlet.ServletRequest
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cglib.beans.BeanCopier
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.http.HttpStatus
;
...
...
@@ -46,14 +46,12 @@ public class IBZOrganizationResource {
@Lazy
public
IBZOrganizationMapping
ibzorganizationMapping
;
@PreAuthorize
(
"hasPermission(this.ibzorganizationMapping.toDomain(#ibzorganizationdto),'ibzrt-IBZOrganization-Save')"
)
@ApiOperation
(
value
=
"Save"
,
tags
=
{
"IBZOrganization"
},
notes
=
"Save"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/save"
)
public
ResponseEntity
<
Boolean
>
save
(
@RequestBody
IBZOrganizationDTO
ibzorganizationdto
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzorganizationService
.
save
(
ibzorganizationMapping
.
toDomain
(
ibzorganizationdto
)));
}
@PreAuthorize
(
"hasPermission(this.ibzorganizationMapping.toDomain(#ibzorganizationdtos),'ibzrt-IBZOrganization-Save')"
)
@ApiOperation
(
value
=
"SaveBatch"
,
tags
=
{
"IBZOrganization"
},
notes
=
"SaveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/savebatch"
)
public
ResponseEntity
<
Boolean
>
saveBatch
(
@RequestBody
List
<
IBZOrganizationDTO
>
ibzorganizationdtos
)
{
...
...
@@ -67,7 +65,6 @@ public class IBZOrganizationResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzorganizationService
.
checkKey
(
ibzorganizationMapping
.
toDomain
(
ibzorganizationdto
)));
}
@PostAuthorize
(
"hasPermission(this.ibzorganizationMapping.toDomain(returnObject.body),'ibzrt-IBZOrganization-Get')"
)
@ApiOperation
(
value
=
"Get"
,
tags
=
{
"IBZOrganization"
},
notes
=
"Get"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzorganizations/{ibzorganization_id}"
)
public
ResponseEntity
<
IBZOrganizationDTO
>
get
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
)
{
...
...
@@ -76,10 +73,9 @@ public class IBZOrganizationResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasPermission(this.ibzorganizationMapping.toDomain(#ibzorganizationdto),'ibzrt-IBZOrganization-Create')"
)
@ApiOperation
(
value
=
"Create"
,
tags
=
{
"IBZOrganization"
},
notes
=
"Create"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations"
)
@Transactional
public
ResponseEntity
<
IBZOrganizationDTO
>
create
(
@RequestBody
IBZOrganizationDTO
ibzorganizationdto
)
{
IBZOrganization
domain
=
ibzorganizationMapping
.
toDomain
(
ibzorganizationdto
);
ibzorganizationService
.
create
(
domain
);
...
...
@@ -87,7 +83,6 @@ public class IBZOrganizationResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasPermission(this.ibzorganizationMapping.toDomain(#ibzorganizationdtos),'ibzrt-IBZOrganization-Create')"
)
@ApiOperation
(
value
=
"createBatch"
,
tags
=
{
"IBZOrganization"
},
notes
=
"createBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/batch"
)
public
ResponseEntity
<
Boolean
>
createBatch
(
@RequestBody
List
<
IBZOrganizationDTO
>
ibzorganizationdtos
)
{
...
...
@@ -95,15 +90,13 @@ public class IBZOrganizationResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasPermission(this.ibzorganizationService.get(#ibzorganization_id),'ibzrt-IBZOrganization-Remove')"
)
@ApiOperation
(
value
=
"Remove"
,
tags
=
{
"IBZOrganization"
},
notes
=
"Remove"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzorganizations/{ibzorganization_id}"
)
@Transactional
public
ResponseEntity
<
Boolean
>
remove
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzorganizationService
.
remove
(
ibzorganization_id
));
}
@PreAuthorize
(
"hasPermission(this.ibzorganizationService.getIbzorganizationByIds(#ids),'ibzrt-IBZOrganization-Remove')"
)
@ApiOperation
(
value
=
"RemoveBatch"
,
tags
=
{
"IBZOrganization"
},
notes
=
"RemoveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzorganizations/batch"
)
public
ResponseEntity
<
Boolean
>
removeBatch
(
@RequestBody
List
<
String
>
ids
)
{
...
...
@@ -117,10 +110,9 @@ public class IBZOrganizationResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzorganizationMapping
.
toDto
(
ibzorganizationService
.
getDraft
(
new
IBZOrganization
())));
}
@PreAuthorize
(
"hasPermission(this.ibzorganizationService.get(#ibzorganization_id),'ibzrt-IBZOrganization-Update')"
)
@ApiOperation
(
value
=
"Update"
,
tags
=
{
"IBZOrganization"
},
notes
=
"Update"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzorganizations/{ibzorganization_id}"
)
@Transactional
public
ResponseEntity
<
IBZOrganizationDTO
>
update
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@RequestBody
IBZOrganizationDTO
ibzorganizationdto
)
{
IBZOrganization
domain
=
ibzorganizationMapping
.
toDomain
(
ibzorganizationdto
);
domain
.
setOrgid
(
ibzorganization_id
);
...
...
@@ -129,7 +121,6 @@ public class IBZOrganizationResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasPermission(this.ibzorganizationService.getIbzorganizationByEntities(this.ibzorganizationMapping.toDomain(#ibzorganizationdtos)),'ibzrt-IBZOrganization-Update')"
)
@ApiOperation
(
value
=
"UpdateBatch"
,
tags
=
{
"IBZOrganization"
},
notes
=
"UpdateBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzorganizations/batch"
)
public
ResponseEntity
<
Boolean
>
updateBatch
(
@RequestBody
List
<
IBZOrganizationDTO
>
ibzorganizationdtos
)
{
...
...
@@ -137,7 +128,6 @@ public class IBZOrganizationResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZOrganization-Default-all')"
)
@ApiOperation
(
value
=
"fetchDEFAULT"
,
tags
=
{
"IBZOrganization"
}
,
notes
=
"fetchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzorganizations/fetchdefault"
)
public
ResponseEntity
<
List
<
IBZOrganizationDTO
>>
fetchDefault
(
IBZOrganizationSearchContext
context
)
{
...
...
@@ -150,7 +140,6 @@ public class IBZOrganizationResource {
.
body
(
list
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZOrganization-Default-all')"
)
@ApiOperation
(
value
=
"searchDEFAULT"
,
tags
=
{
"IBZOrganization"
}
,
notes
=
"searchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/searchdefault"
)
public
ResponseEntity
<
Page
<
IBZOrganizationDTO
>>
searchDefault
(
@RequestBody
IBZOrganizationSearchContext
context
)
{
...
...
@@ -158,7 +147,6 @@ public class IBZOrganizationResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
)
.
body
(
new
PageImpl
(
ibzorganizationMapping
.
toDto
(
domains
.
getContent
()),
context
.
getPageable
(),
domains
.
getTotalElements
()));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZOrganization-SelectPOrg-all')"
)
@ApiOperation
(
value
=
"fetch查询上级单位"
,
tags
=
{
"IBZOrganization"
}
,
notes
=
"fetch查询上级单位"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzorganizations/fetchselectporg"
)
public
ResponseEntity
<
List
<
IBZOrganizationDTO
>>
fetchSelectPOrg
(
IBZOrganizationSearchContext
context
)
{
...
...
@@ -171,7 +159,6 @@ public class IBZOrganizationResource {
.
body
(
list
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZOrganization-SelectPOrg-all')"
)
@ApiOperation
(
value
=
"search查询上级单位"
,
tags
=
{
"IBZOrganization"
}
,
notes
=
"search查询上级单位"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/searchselectporg"
)
public
ResponseEntity
<
Page
<
IBZOrganizationDTO
>>
searchSelectPOrg
(
@RequestBody
IBZOrganizationSearchContext
context
)
{
...
...
@@ -179,7 +166,6 @@ public class IBZOrganizationResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
)
.
body
(
new
PageImpl
(
ibzorganizationMapping
.
toDto
(
domains
.
getContent
()),
context
.
getPageable
(),
domains
.
getTotalElements
()));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZOrganization-SelectSOrg-all')"
)
@ApiOperation
(
value
=
"fetch查询下级单位"
,
tags
=
{
"IBZOrganization"
}
,
notes
=
"fetch查询下级单位"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzorganizations/fetchselectsorg"
)
public
ResponseEntity
<
List
<
IBZOrganizationDTO
>>
fetchSelectSOrg
(
IBZOrganizationSearchContext
context
)
{
...
...
@@ -192,7 +178,6 @@ public class IBZOrganizationResource {
.
body
(
list
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZOrganization-SelectSOrg-all')"
)
@ApiOperation
(
value
=
"search查询下级单位"
,
tags
=
{
"IBZOrganization"
}
,
notes
=
"search查询下级单位"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/searchselectsorg"
)
public
ResponseEntity
<
Page
<
IBZOrganizationDTO
>>
searchSelectSOrg
(
@RequestBody
IBZOrganizationSearchContext
context
)
{
...
...
ibzrt-provider/ibzrt-provider-api/src/main/java/cn/ibizlab/api/rest/SysRolePermissionResource.java
浏览文件 @
71ffc6c5
...
...
@@ -11,7 +11,7 @@ import com.alibaba.fastjson.JSONObject;
import
javax.servlet.ServletRequest
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cglib.beans.BeanCopier
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.http.HttpStatus
;
...
...
@@ -46,7 +46,6 @@ public class SysRolePermissionResource {
@Lazy
public
SysRolePermissionMapping
sysrolepermissionMapping
;
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRolePermission-Get-all')"
)
@ApiOperation
(
value
=
"Get"
,
tags
=
{
"SysRolePermission"
},
notes
=
"Get"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysrolepermissions/{sysrolepermission_id}"
)
public
ResponseEntity
<
SysRolePermissionDTO
>
get
(
@PathVariable
(
"sysrolepermission_id"
)
String
sysrolepermission_id
)
{
...
...
@@ -55,15 +54,13 @@ public class SysRolePermissionResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRolePermission-Remove-all')"
)
@ApiOperation
(
value
=
"Remove"
,
tags
=
{
"SysRolePermission"
},
notes
=
"Remove"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysrolepermissions/{sysrolepermission_id}"
)
@Transactional
public
ResponseEntity
<
Boolean
>
remove
(
@PathVariable
(
"sysrolepermission_id"
)
String
sysrolepermission_id
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
sysrolepermissionService
.
remove
(
sysrolepermission_id
));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRolePermission-Remove-all')"
)
@ApiOperation
(
value
=
"RemoveBatch"
,
tags
=
{
"SysRolePermission"
},
notes
=
"RemoveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysrolepermissions/batch"
)
public
ResponseEntity
<
Boolean
>
removeBatch
(
@RequestBody
List
<
String
>
ids
)
{
...
...
@@ -77,10 +74,9 @@ public class SysRolePermissionResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
sysrolepermissionMapping
.
toDto
(
sysrolepermissionService
.
getDraft
(
new
SysRolePermission
())));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRolePermission-Create-all')"
)
@ApiOperation
(
value
=
"Create"
,
tags
=
{
"SysRolePermission"
},
notes
=
"Create"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysrolepermissions"
)
@Transactional
public
ResponseEntity
<
SysRolePermissionDTO
>
create
(
@RequestBody
SysRolePermissionDTO
sysrolepermissiondto
)
{
SysRolePermission
domain
=
sysrolepermissionMapping
.
toDomain
(
sysrolepermissiondto
);
sysrolepermissionService
.
create
(
domain
);
...
...
@@ -88,7 +84,6 @@ public class SysRolePermissionResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRolePermission-Create-all')"
)
@ApiOperation
(
value
=
"createBatch"
,
tags
=
{
"SysRolePermission"
},
notes
=
"createBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysrolepermissions/batch"
)
public
ResponseEntity
<
Boolean
>
createBatch
(
@RequestBody
List
<
SysRolePermissionDTO
>
sysrolepermissiondtos
)
{
...
...
@@ -102,14 +97,12 @@ public class SysRolePermissionResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
sysrolepermissionService
.
checkKey
(
sysrolepermissionMapping
.
toDomain
(
sysrolepermissiondto
)));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRolePermission-Save-all')"
)
@ApiOperation
(
value
=
"Save"
,
tags
=
{
"SysRolePermission"
},
notes
=
"Save"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysrolepermissions/save"
)
public
ResponseEntity
<
Boolean
>
save
(
@RequestBody
SysRolePermissionDTO
sysrolepermissiondto
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
sysrolepermissionService
.
save
(
sysrolepermissionMapping
.
toDomain
(
sysrolepermissiondto
)));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRolePermission-Save-all')"
)
@ApiOperation
(
value
=
"SaveBatch"
,
tags
=
{
"SysRolePermission"
},
notes
=
"SaveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysrolepermissions/savebatch"
)
public
ResponseEntity
<
Boolean
>
saveBatch
(
@RequestBody
List
<
SysRolePermissionDTO
>
sysrolepermissiondtos
)
{
...
...
@@ -117,10 +110,9 @@ public class SysRolePermissionResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRolePermission-Update-all')"
)
@ApiOperation
(
value
=
"Update"
,
tags
=
{
"SysRolePermission"
},
notes
=
"Update"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysrolepermissions/{sysrolepermission_id}"
)
@Transactional
public
ResponseEntity
<
SysRolePermissionDTO
>
update
(
@PathVariable
(
"sysrolepermission_id"
)
String
sysrolepermission_id
,
@RequestBody
SysRolePermissionDTO
sysrolepermissiondto
)
{
SysRolePermission
domain
=
sysrolepermissionMapping
.
toDomain
(
sysrolepermissiondto
);
domain
.
setRolepermissionid
(
sysrolepermission_id
);
...
...
@@ -129,7 +121,6 @@ public class SysRolePermissionResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRolePermission-Update-all')"
)
@ApiOperation
(
value
=
"UpdateBatch"
,
tags
=
{
"SysRolePermission"
},
notes
=
"UpdateBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysrolepermissions/batch"
)
public
ResponseEntity
<
Boolean
>
updateBatch
(
@RequestBody
List
<
SysRolePermissionDTO
>
sysrolepermissiondtos
)
{
...
...
@@ -137,7 +128,6 @@ public class SysRolePermissionResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRolePermission-Default-all')"
)
@ApiOperation
(
value
=
"fetchDEFAULT"
,
tags
=
{
"SysRolePermission"
}
,
notes
=
"fetchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysrolepermissions/fetchdefault"
)
public
ResponseEntity
<
List
<
SysRolePermissionDTO
>>
fetchDefault
(
SysRolePermissionSearchContext
context
)
{
...
...
@@ -150,7 +140,6 @@ public class SysRolePermissionResource {
.
body
(
list
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRolePermission-Default-all')"
)
@ApiOperation
(
value
=
"searchDEFAULT"
,
tags
=
{
"SysRolePermission"
}
,
notes
=
"searchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysrolepermissions/searchdefault"
)
public
ResponseEntity
<
Page
<
SysRolePermissionDTO
>>
searchDefault
(
@RequestBody
SysRolePermissionSearchContext
context
)
{
...
...
ibzrt-provider/ibzrt-provider-api/src/main/java/cn/ibizlab/api/rest/SysRoleResource.java
浏览文件 @
71ffc6c5
...
...
@@ -11,7 +11,7 @@ import com.alibaba.fastjson.JSONObject;
import
javax.servlet.ServletRequest
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cglib.beans.BeanCopier
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.http.HttpStatus
;
...
...
@@ -46,14 +46,12 @@ public class SysRoleResource {
@Lazy
public
SysRoleMapping
sysroleMapping
;
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRole-Save-all')"
)
@ApiOperation
(
value
=
"Save"
,
tags
=
{
"SysRole"
},
notes
=
"Save"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysroles/save"
)
public
ResponseEntity
<
Boolean
>
save
(
@RequestBody
SysRoleDTO
sysroledto
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
sysroleService
.
save
(
sysroleMapping
.
toDomain
(
sysroledto
)));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRole-Save-all')"
)
@ApiOperation
(
value
=
"SaveBatch"
,
tags
=
{
"SysRole"
},
notes
=
"SaveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysroles/savebatch"
)
public
ResponseEntity
<
Boolean
>
saveBatch
(
@RequestBody
List
<
SysRoleDTO
>
sysroledtos
)
{
...
...
@@ -61,10 +59,9 @@ public class SysRoleResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRole-Update-all')"
)
@ApiOperation
(
value
=
"Update"
,
tags
=
{
"SysRole"
},
notes
=
"Update"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysroles/{sysrole_id}"
)
@Transactional
public
ResponseEntity
<
SysRoleDTO
>
update
(
@PathVariable
(
"sysrole_id"
)
String
sysrole_id
,
@RequestBody
SysRoleDTO
sysroledto
)
{
SysRole
domain
=
sysroleMapping
.
toDomain
(
sysroledto
);
domain
.
setRoleid
(
sysrole_id
);
...
...
@@ -73,7 +70,6 @@ public class SysRoleResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRole-Update-all')"
)
@ApiOperation
(
value
=
"UpdateBatch"
,
tags
=
{
"SysRole"
},
notes
=
"UpdateBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysroles/batch"
)
public
ResponseEntity
<
Boolean
>
updateBatch
(
@RequestBody
List
<
SysRoleDTO
>
sysroledtos
)
{
...
...
@@ -81,10 +77,9 @@ public class SysRoleResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRole-Create-all')"
)
@ApiOperation
(
value
=
"Create"
,
tags
=
{
"SysRole"
},
notes
=
"Create"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysroles"
)
@Transactional
public
ResponseEntity
<
SysRoleDTO
>
create
(
@RequestBody
SysRoleDTO
sysroledto
)
{
SysRole
domain
=
sysroleMapping
.
toDomain
(
sysroledto
);
sysroleService
.
create
(
domain
);
...
...
@@ -92,7 +87,6 @@ public class SysRoleResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRole-Create-all')"
)
@ApiOperation
(
value
=
"createBatch"
,
tags
=
{
"SysRole"
},
notes
=
"createBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysroles/batch"
)
public
ResponseEntity
<
Boolean
>
createBatch
(
@RequestBody
List
<
SysRoleDTO
>
sysroledtos
)
{
...
...
@@ -100,7 +94,6 @@ public class SysRoleResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRole-Get-all')"
)
@ApiOperation
(
value
=
"Get"
,
tags
=
{
"SysRole"
},
notes
=
"Get"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysroles/{sysrole_id}"
)
public
ResponseEntity
<
SysRoleDTO
>
get
(
@PathVariable
(
"sysrole_id"
)
String
sysrole_id
)
{
...
...
@@ -109,15 +102,13 @@ public class SysRoleResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRole-Remove-all')"
)
@ApiOperation
(
value
=
"Remove"
,
tags
=
{
"SysRole"
},
notes
=
"Remove"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysroles/{sysrole_id}"
)
@Transactional
public
ResponseEntity
<
Boolean
>
remove
(
@PathVariable
(
"sysrole_id"
)
String
sysrole_id
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
sysroleService
.
remove
(
sysrole_id
));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRole-Remove-all')"
)
@ApiOperation
(
value
=
"RemoveBatch"
,
tags
=
{
"SysRole"
},
notes
=
"RemoveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysroles/batch"
)
public
ResponseEntity
<
Boolean
>
removeBatch
(
@RequestBody
List
<
String
>
ids
)
{
...
...
@@ -137,7 +128,6 @@ public class SysRoleResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
sysroleService
.
checkKey
(
sysroleMapping
.
toDomain
(
sysroledto
)));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRole-Default-all')"
)
@ApiOperation
(
value
=
"fetchDEFAULT"
,
tags
=
{
"SysRole"
}
,
notes
=
"fetchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysroles/fetchdefault"
)
public
ResponseEntity
<
List
<
SysRoleDTO
>>
fetchDefault
(
SysRoleSearchContext
context
)
{
...
...
@@ -150,7 +140,6 @@ public class SysRoleResource {
.
body
(
list
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysRole-Default-all')"
)
@ApiOperation
(
value
=
"searchDEFAULT"
,
tags
=
{
"SysRole"
}
,
notes
=
"searchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysroles/searchdefault"
)
public
ResponseEntity
<
Page
<
SysRoleDTO
>>
searchDefault
(
@RequestBody
SysRoleSearchContext
context
)
{
...
...
ibzrt-provider/ibzrt-provider-api/src/main/java/cn/ibizlab/api/rest/SysUserResource.java
浏览文件 @
71ffc6c5
...
...
@@ -11,7 +11,7 @@ import com.alibaba.fastjson.JSONObject;
import
javax.servlet.ServletRequest
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cglib.beans.BeanCopier
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.http.HttpStatus
;
...
...
@@ -46,15 +46,13 @@ public class SysUserResource {
@Lazy
public
SysUserMapping
sysuserMapping
;
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUser-Remove-all')"
)
@ApiOperation
(
value
=
"Remove"
,
tags
=
{
"SysUser"
},
notes
=
"Remove"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysusers/{sysuser_id}"
)
@Transactional
public
ResponseEntity
<
Boolean
>
remove
(
@PathVariable
(
"sysuser_id"
)
String
sysuser_id
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
sysuserService
.
remove
(
sysuser_id
));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUser-Remove-all')"
)
@ApiOperation
(
value
=
"RemoveBatch"
,
tags
=
{
"SysUser"
},
notes
=
"RemoveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysusers/batch"
)
public
ResponseEntity
<
Boolean
>
removeBatch
(
@RequestBody
List
<
String
>
ids
)
{
...
...
@@ -62,10 +60,9 @@ public class SysUserResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUser-Update-all')"
)
@ApiOperation
(
value
=
"Update"
,
tags
=
{
"SysUser"
},
notes
=
"Update"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysusers/{sysuser_id}"
)
@Transactional
public
ResponseEntity
<
SysUserDTO
>
update
(
@PathVariable
(
"sysuser_id"
)
String
sysuser_id
,
@RequestBody
SysUserDTO
sysuserdto
)
{
SysUser
domain
=
sysuserMapping
.
toDomain
(
sysuserdto
);
domain
.
setUserid
(
sysuser_id
);
...
...
@@ -74,7 +71,6 @@ public class SysUserResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUser-Update-all')"
)
@ApiOperation
(
value
=
"UpdateBatch"
,
tags
=
{
"SysUser"
},
notes
=
"UpdateBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysusers/batch"
)
public
ResponseEntity
<
Boolean
>
updateBatch
(
@RequestBody
List
<
SysUserDTO
>
sysuserdtos
)
{
...
...
@@ -88,7 +84,6 @@ public class SysUserResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
sysuserService
.
checkKey
(
sysuserMapping
.
toDomain
(
sysuserdto
)));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUser-Get-all')"
)
@ApiOperation
(
value
=
"Get"
,
tags
=
{
"SysUser"
},
notes
=
"Get"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysusers/{sysuser_id}"
)
public
ResponseEntity
<
SysUserDTO
>
get
(
@PathVariable
(
"sysuser_id"
)
String
sysuser_id
)
{
...
...
@@ -97,14 +92,12 @@ public class SysUserResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUser-Save-all')"
)
@ApiOperation
(
value
=
"Save"
,
tags
=
{
"SysUser"
},
notes
=
"Save"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysusers/save"
)
public
ResponseEntity
<
Boolean
>
save
(
@RequestBody
SysUserDTO
sysuserdto
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
sysuserService
.
save
(
sysuserMapping
.
toDomain
(
sysuserdto
)));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUser-Save-all')"
)
@ApiOperation
(
value
=
"SaveBatch"
,
tags
=
{
"SysUser"
},
notes
=
"SaveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysusers/savebatch"
)
public
ResponseEntity
<
Boolean
>
saveBatch
(
@RequestBody
List
<
SysUserDTO
>
sysuserdtos
)
{
...
...
@@ -118,10 +111,9 @@ public class SysUserResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
sysuserMapping
.
toDto
(
sysuserService
.
getDraft
(
new
SysUser
())));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUser-Create-all')"
)
@ApiOperation
(
value
=
"Create"
,
tags
=
{
"SysUser"
},
notes
=
"Create"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysusers"
)
@Transactional
public
ResponseEntity
<
SysUserDTO
>
create
(
@RequestBody
SysUserDTO
sysuserdto
)
{
SysUser
domain
=
sysuserMapping
.
toDomain
(
sysuserdto
);
sysuserService
.
create
(
domain
);
...
...
@@ -129,7 +121,6 @@ public class SysUserResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUser-Create-all')"
)
@ApiOperation
(
value
=
"createBatch"
,
tags
=
{
"SysUser"
},
notes
=
"createBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysusers/batch"
)
public
ResponseEntity
<
Boolean
>
createBatch
(
@RequestBody
List
<
SysUserDTO
>
sysuserdtos
)
{
...
...
@@ -137,7 +128,6 @@ public class SysUserResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUser-Default-all')"
)
@ApiOperation
(
value
=
"fetchDEFAULT"
,
tags
=
{
"SysUser"
}
,
notes
=
"fetchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysusers/fetchdefault"
)
public
ResponseEntity
<
List
<
SysUserDTO
>>
fetchDefault
(
SysUserSearchContext
context
)
{
...
...
@@ -150,7 +140,6 @@ public class SysUserResource {
.
body
(
list
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUser-Default-all')"
)
@ApiOperation
(
value
=
"searchDEFAULT"
,
tags
=
{
"SysUser"
}
,
notes
=
"searchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysusers/searchdefault"
)
public
ResponseEntity
<
Page
<
SysUserDTO
>>
searchDefault
(
@RequestBody
SysUserSearchContext
context
)
{
...
...
ibzrt-provider/ibzrt-provider-api/src/main/java/cn/ibizlab/api/rest/SysUserRoleResource.java
浏览文件 @
71ffc6c5
...
...
@@ -11,7 +11,7 @@ import com.alibaba.fastjson.JSONObject;
import
javax.servlet.ServletRequest
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cglib.beans.BeanCopier
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.http.HttpStatus
;
...
...
@@ -58,10 +58,9 @@ public class SysUserRoleResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
sysuserroleMapping
.
toDto
(
sysuserroleService
.
getDraft
(
new
SysUserRole
())));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUserRole-Update-all')"
)
@ApiOperation
(
value
=
"Update"
,
tags
=
{
"SysUserRole"
},
notes
=
"Update"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysuserroles/{sysuserrole_id}"
)
@Transactional
public
ResponseEntity
<
SysUserRoleDTO
>
update
(
@PathVariable
(
"sysuserrole_id"
)
String
sysuserrole_id
,
@RequestBody
SysUserRoleDTO
sysuserroledto
)
{
SysUserRole
domain
=
sysuserroleMapping
.
toDomain
(
sysuserroledto
);
domain
.
setUserroleid
(
sysuserrole_id
);
...
...
@@ -70,7 +69,6 @@ public class SysUserRoleResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUserRole-Update-all')"
)
@ApiOperation
(
value
=
"UpdateBatch"
,
tags
=
{
"SysUserRole"
},
notes
=
"UpdateBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/sysuserroles/batch"
)
public
ResponseEntity
<
Boolean
>
updateBatch
(
@RequestBody
List
<
SysUserRoleDTO
>
sysuserroledtos
)
{
...
...
@@ -78,15 +76,13 @@ public class SysUserRoleResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUserRole-Remove-all')"
)
@ApiOperation
(
value
=
"Remove"
,
tags
=
{
"SysUserRole"
},
notes
=
"Remove"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysuserroles/{sysuserrole_id}"
)
@Transactional
public
ResponseEntity
<
Boolean
>
remove
(
@PathVariable
(
"sysuserrole_id"
)
String
sysuserrole_id
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
sysuserroleService
.
remove
(
sysuserrole_id
));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUserRole-Remove-all')"
)
@ApiOperation
(
value
=
"RemoveBatch"
,
tags
=
{
"SysUserRole"
},
notes
=
"RemoveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/sysuserroles/batch"
)
public
ResponseEntity
<
Boolean
>
removeBatch
(
@RequestBody
List
<
String
>
ids
)
{
...
...
@@ -94,10 +90,9 @@ public class SysUserRoleResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUserRole-Create-all')"
)
@ApiOperation
(
value
=
"Create"
,
tags
=
{
"SysUserRole"
},
notes
=
"Create"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysuserroles"
)
@Transactional
public
ResponseEntity
<
SysUserRoleDTO
>
create
(
@RequestBody
SysUserRoleDTO
sysuserroledto
)
{
SysUserRole
domain
=
sysuserroleMapping
.
toDomain
(
sysuserroledto
);
sysuserroleService
.
create
(
domain
);
...
...
@@ -105,7 +100,6 @@ public class SysUserRoleResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUserRole-Create-all')"
)
@ApiOperation
(
value
=
"createBatch"
,
tags
=
{
"SysUserRole"
},
notes
=
"createBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysuserroles/batch"
)
public
ResponseEntity
<
Boolean
>
createBatch
(
@RequestBody
List
<
SysUserRoleDTO
>
sysuserroledtos
)
{
...
...
@@ -113,7 +107,6 @@ public class SysUserRoleResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUserRole-Get-all')"
)
@ApiOperation
(
value
=
"Get"
,
tags
=
{
"SysUserRole"
},
notes
=
"Get"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysuserroles/{sysuserrole_id}"
)
public
ResponseEntity
<
SysUserRoleDTO
>
get
(
@PathVariable
(
"sysuserrole_id"
)
String
sysuserrole_id
)
{
...
...
@@ -122,14 +115,12 @@ public class SysUserRoleResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUserRole-Save-all')"
)
@ApiOperation
(
value
=
"Save"
,
tags
=
{
"SysUserRole"
},
notes
=
"Save"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysuserroles/save"
)
public
ResponseEntity
<
Boolean
>
save
(
@RequestBody
SysUserRoleDTO
sysuserroledto
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
sysuserroleService
.
save
(
sysuserroleMapping
.
toDomain
(
sysuserroledto
)));
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUserRole-Save-all')"
)
@ApiOperation
(
value
=
"SaveBatch"
,
tags
=
{
"SysUserRole"
},
notes
=
"SaveBatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysuserroles/savebatch"
)
public
ResponseEntity
<
Boolean
>
saveBatch
(
@RequestBody
List
<
SysUserRoleDTO
>
sysuserroledtos
)
{
...
...
@@ -137,7 +128,6 @@ public class SysUserRoleResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUserRole-Default-all')"
)
@ApiOperation
(
value
=
"fetchDEFAULT"
,
tags
=
{
"SysUserRole"
}
,
notes
=
"fetchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/sysuserroles/fetchdefault"
)
public
ResponseEntity
<
List
<
SysUserRoleDTO
>>
fetchDefault
(
SysUserRoleSearchContext
context
)
{
...
...
@@ -150,7 +140,6 @@ public class SysUserRoleResource {
.
body
(
list
);
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-SysUserRole-Default-all')"
)
@ApiOperation
(
value
=
"searchDEFAULT"
,
tags
=
{
"SysUserRole"
}
,
notes
=
"searchDEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/sysuserroles/searchdefault"
)
public
ResponseEntity
<
Page
<
SysUserRoleDTO
>>
searchDefault
(
@RequestBody
SysUserRoleSearchContext
context
)
{
...
...
编辑
预览
Markdown
格式
0%
请重试
or
添加新附件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录