Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
I
ibzrt
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
ibiz4jteam
ibzrt
提交
a223d1f5
提交
a223d1f5
编写于
8月 07, 2020
作者:
ibizdev
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
zhouweidong@lab.ibiz5.com 发布系统代码
上级
c3eb3f49
变更
17
隐藏空白字符变更
内嵌
并排
正在显示
17 个修改的文件
包含
950 行增加
和
615 行删除
+950
-615
app-department-select.vue
...omponents/app-department-select/app-department-select.vue
+3
-3
app-group-select.vue
app_Web/src/components/app-group-select/app-group-select.vue
+64
-12
app-upicker.less
app_Web/src/components/app-upicker/app-upicker.less
+2
-2
app-upicker.vue
app_Web/src/components/app-upicker/app-upicker.vue
+731
-95
main-form-base.vue
...eb/src/widgets/ibzdepartment/main-form/main-form-base.vue
+1
-0
application-web-prod.yml
...ibzrt-app-web/src/main/resources/application-web-prod.yml
+1
-1
application-dev.yml
ibzrt-boot/src/main/resources/application-dev.yml
+4
-0
IBZEmployeeExService.java
...ibizlab/core/extensions/service/IBZEmployeeExService.java
+0
-4
IBZEmployee.java
.../src/main/java/cn/ibizlab/core/ou/domain/IBZEmployee.java
+47
-59
IBZEmployeeSearchContext.java
...a/cn/ibizlab/core/ou/filter/IBZEmployeeSearchContext.java
+15
-86
IIBZEmployeeService.java
.../java/cn/ibizlab/core/ou/service/IIBZEmployeeService.java
+2
-19
IBZDepartmentServiceImpl.java
...bizlab/core/ou/service/impl/IBZDepartmentServiceImpl.java
+0
-3
IBZEmployeeServiceImpl.java
.../ibizlab/core/ou/service/impl/IBZEmployeeServiceImpl.java
+63
-172
IBZOrganizationServiceImpl.java
...zlab/core/ou/service/impl/IBZOrganizationServiceImpl.java
+0
-3
IBZPostServiceImpl.java
...a/cn/ibizlab/core/ou/service/impl/IBZPostServiceImpl.java
+0
-3
h2_table.xml
ibzrt-core/src/main/resources/liquibase/h2_table.xml
+0
-88
IBZEmployeeResource.java
...rc/main/java/cn/ibizlab/api/rest/IBZEmployeeResource.java
+17
-65
未找到文件。
app_Web/src/components/app-department-select/app-department-select.vue
浏览文件 @
a223d1f5
...
@@ -103,7 +103,7 @@ export default class AppDepartmentSelect extends Vue {
...
@@ -103,7 +103,7 @@ export default class AppDepartmentSelect extends Vue {
* @type {*}
* @type {*}
* @memberof AppDepartmentSelect
* @memberof AppDepartmentSelect
*/
*/
public
oldurl
:
any
[]
=
[]
;
public
oldurl
:
any
;
/**
/**
* 获取节点数据
* 获取节点数据
...
@@ -136,14 +136,14 @@ export default class AppDepartmentSelect extends Vue {
...
@@ -136,14 +136,14 @@ export default class AppDepartmentSelect extends Vue {
}
}
this
.
oldurl
=
_url
;
this
.
oldurl
=
_url
;
// 缓存机制
// 缓存机制
const
result
:
any
=
this
.
$store
.
getters
.
getDepData
(
this
.
filter
);
const
result
:
any
=
this
.
$store
.
getters
.
getDepData
(
_url
);
if
(
result
){
if
(
result
){
this
.
Nodesdata
=
result
;
this
.
Nodesdata
=
result
;
return
;
return
;
}
}
this
.
$http
.
get
(
_url
).
then
((
response
:
any
)
=>
{
this
.
$http
.
get
(
_url
).
then
((
response
:
any
)
=>
{
this
.
Nodesdata
=
response
.
data
;
this
.
Nodesdata
=
response
.
data
;
this
.
$store
.
commit
(
'addDepData'
,
{
srfkey
:
this
.
filter
,
depData
:
response
.
data
});
this
.
$store
.
commit
(
'addDepData'
,
{
srfkey
:
_url
,
depData
:
response
.
data
});
}).
catch
((
response
:
any
)
=>
{
}).
catch
((
response
:
any
)
=>
{
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.error'
)
as
string
),
desc
:
(
this
.
$t
(
'app.commonWords.sysException'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.error'
)
as
string
),
desc
:
(
this
.
$t
(
'app.commonWords.sysException'
)
as
string
)
});
...
...
app_Web/src/components/app-group-select/app-group-select.vue
浏览文件 @
a223d1f5
...
@@ -21,6 +21,7 @@
...
@@ -21,6 +21,7 @@
<
script
lang=
"ts"
>
<
script
lang=
"ts"
>
import
{
Component
,
Vue
,
Prop
,
Watch
}
from
'vue-property-decorator'
;
import
{
Component
,
Vue
,
Prop
,
Watch
}
from
'vue-property-decorator'
;
import
{
Subject
}
from
'rxjs'
;
import
{
Subject
}
from
'rxjs'
;
import
CodeListService
from
'@/service/app/codelist-service'
;
@
Component
({})
@
Component
({})
export
default
class
AppGroupSelect
extends
Vue
{
export
default
class
AppGroupSelect
extends
Vue
{
...
@@ -64,6 +65,20 @@ export default class AppGroupSelect extends Vue {
...
@@ -64,6 +65,20 @@ export default class AppGroupSelect extends Vue {
*/
*/
@
Prop
()
data
:
any
;
@
Prop
()
data
:
any
;
/**
* 代码表标识
*
* @memberof AppGroupSelect
*/
@
Prop
()
public
tag
?:
string
;
/**
* 代码表类型
*
* @memberof AppGroupSelect
*/
@
Prop
()
public
codelistType
?:
string
;
/**
/**
* 过滤属性标识
* 过滤属性标识
*
*
...
@@ -126,12 +141,12 @@ export default class AppGroupSelect extends Vue {
...
@@ -126,12 +141,12 @@ export default class AppGroupSelect extends Vue {
* @type {*}
* @type {*}
* @memberof AppGroupSelect
* @memberof AppGroupSelect
*/
*/
@
Watch
(
'
value'
)
@
Watch
(
'
data'
,{
immediate
:
true
,
deep
:
true
}
)
onValueChange
(
newVal
:
any
)
{
onValueChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
selects
=
[];
this
.
selects
=
[];
if
(
newVal
)
{
if
(
newVal
)
{
let
item
:
any
=
{};
let
item
:
any
=
{};
item
.
label
=
newVal
.
split
(
','
)
;
item
.
label
=
this
.
data
[
this
.
name
]?
this
.
data
[
this
.
name
].
split
(
','
):[]
;
if
(
this
.
valueitem
)
{
if
(
this
.
valueitem
)
{
item
.
id
=
this
.
data
[
this
.
valueitem
]
?
this
.
data
[
this
.
valueitem
].
split
(
','
)
:
[];
item
.
id
=
this
.
data
[
this
.
valueitem
]
?
this
.
data
[
this
.
valueitem
].
split
(
','
)
:
[];
}
}
...
@@ -140,13 +155,24 @@ export default class AppGroupSelect extends Vue {
...
@@ -140,13 +155,24 @@ export default class AppGroupSelect extends Vue {
item
[
this
.
fillmap
[
key
]]
=
this
.
data
[
key
]
?
this
.
data
[
key
].
split
(
','
)
:
[];
item
[
this
.
fillmap
[
key
]]
=
this
.
data
[
key
]
?
this
.
data
[
key
].
split
(
','
)
:
[];
}
}
}
}
item
.
label
.
forEach
((
val
:
string
,
index
:
number
)
=>
{
const
callback
:
any
=
(
item
:
any
)
=>
{
let
_item
:
any
=
{};
item
.
label
.
forEach
((
val
:
string
,
index
:
number
)
=>
{
for
(
let
key
in
item
)
{
let
_item
:
any
=
{};
_item
[
key
]
=
item
[
key
][
index
]
?
item
[
key
][
index
]
:
null
;
for
(
let
key
in
item
)
{
}
_item
[
key
]
=
item
[
key
][
index
]
?
item
[
key
][
index
]
:
null
;
this
.
selects
.
push
(
_item
)
}
})
this
.
selects
.
push
(
_item
)
})
}
if
(
item
.
label
.
length
==
0
&&
item
.
id
.
length
>
0
){
this
.
fillLabel
(
item
,
item
.
id
,(
result
:
any
)
=>
{
item
.
label
=
result
.
label
;
callback
(
item
);
});
}
else
{
callback
(
item
);
}
}
}
}
}
...
@@ -259,7 +285,6 @@ export default class AppGroupSelect extends Vue {
...
@@ -259,7 +285,6 @@ export default class AppGroupSelect extends Vue {
}
}
});
});
}
else
{
}
else
{
item
=
this
.
selects
.
length
>
0
?
this
.
selects
[
0
]
:
{};
item
[
this
.
name
]
=
this
.
selects
.
length
>
0
?
this
.
selects
[
0
].
label
:
null
;
item
[
this
.
name
]
=
this
.
selects
.
length
>
0
?
this
.
selects
[
0
].
label
:
null
;
if
(
this
.
valueitem
)
{
if
(
this
.
valueitem
)
{
item
[
this
.
valueitem
]
=
this
.
selects
.
length
>
0
?
this
.
selects
[
0
].
id
:
null
;
item
[
this
.
valueitem
]
=
this
.
selects
.
length
>
0
?
this
.
selects
[
0
].
id
:
null
;
...
@@ -273,7 +298,34 @@ export default class AppGroupSelect extends Vue {
...
@@ -273,7 +298,34 @@ export default class AppGroupSelect extends Vue {
for
(
let
key
in
item
)
{
for
(
let
key
in
item
)
{
this
.
$emit
(
'formitemvaluechange'
,
{
name
:
key
,
value
:
item
[
key
]
});
this
.
$emit
(
'formitemvaluechange'
,
{
name
:
key
,
value
:
item
[
key
]
});
}
}
}
}
/**
* 填充label
*
* @memberof AppGroupSelect
*/
public
fillLabel
(
tempObject
:
any
,
valueItem
:
Array
<
any
>
,
callback
:
any
){
if
(
tempObject
.
label
.
length
===
0
&&
tempObject
.
id
.
length
>
0
&&
this
.
tag
&&
this
.
codelistType
&&
Object
.
is
(
this
.
codelistType
,
"DYNAMIC"
)){
let
codeListService
:
CodeListService
=
new
CodeListService
();
codeListService
.
getItems
(
this
.
tag
).
then
((
items
:
any
)
=>
{
if
(
items
&&
items
.
length
>
0
&&
valueItem
.
length
>
0
){
let
tempLabel
:
Array
<
any
>
=
[];
valueItem
.
forEach
((
value
:
any
)
=>
{
let
result
:
any
=
items
.
find
((
item
:
any
)
=>
{
return
item
.
id
===
value
;
})
tempLabel
.
push
(
result
.
label
);
})
Object
.
assign
(
tempObject
,{
label
:
tempLabel
});
}
callback
(
tempObject
);
}).
catch
((
error
:
any
)
=>
{
console
.
log
(
error
);
})
}
}
}
}
</
script
>
</
script
>
...
...
app_Web/src/components/app-upicker/app-upicker.less
浏览文件 @
a223d1f5
.app-picker {
.app-
u
picker {
width: 100%;
width: 100%;
.el-select {
.el-select {
.el-input__suffix {
.el-input__suffix {
right: 20px
;
display: none
;
}
}
}
}
.text-value {
.text-value {
...
...
app_Web/src/components/app-upicker/app-upicker.vue
浏览文件 @
a223d1f5
<
template
>
<
template
>
<el-select
style=
"width: 100%;"
size=
'small'
@
change=
"onSelect"
v-model=
"value"
:disabled=
"disabled"
@
visible-change=
"onSelectOpen"
>
<div
v-if=
"Object.is(editortype, 'dropdown')"
class=
'app-upicker'
>
<el-option
v-for=
"(item, index) in items"
:key=
"index"
:label=
"item.label"
:value=
"item.value"
></el-option>
<el-select
ref=
"appPicker"
:value=
"refvalue"
size=
'small'
filterable
</el-select>
@
change=
"onSelect"
:disabled=
"disabled"
style=
'width:100%;'
clearable
@
clear=
"onClear"
@
visible-change=
"onSelectOpen"
>
<template
v-if=
"items"
>
<el-option
v-for=
"(_item,index) in items"
:key=
"index"
:value=
"_item.value"
:label=
"_item.label"
></el-option>
</
template
>
</el-select>
<span
style=
'position: absolute;right: 5px;color: #c0c4cc;top:0;font-size: 13px;'
>
<i
v-show=
"open"
class=
'el-icon-arrow-up'
@
click=
"closeDropdown"
></i>
<i
v-show=
"!open"
class=
'el-icon-arrow-down'
@
click=
"openDropdown"
></i>
</span>
</div>
</template>
</template>
<
script
lang
=
"ts"
>
<
script
lang
=
'ts'
>
import
{
Component
,
Vue
,
Prop
,
Model
,
Watch
}
from
"vue-property-decorator"
;
import
{
Component
,
Vue
,
Prop
,
Model
,
Watch
}
from
'vue-property-decorator'
;
import
{
Subject
}
from
"rxjs"
;
import
{
Subject
}
from
'rxjs'
;
import
{
AppModal
}
from
"@/utils"
;
import
{
AppModal
}
from
'@/utils'
;
@
Component
({})
@
Component
({
})
export
default
class
AppPicker
extends
Vue
{
export
default
class
AppPicker
extends
Vue
{
/**
/**
* 请求到的数据
* @type {any[]}
* @memberof AppPicker
*/
public
itemList
:
any
[]
=
[]
/**
* 列表项请求路径
*
* @type {string}
* @memberof AppUpicker
*/
public
url
:
string
=
''
;
/**
* 请求参数和请求数据的映射关系
*
* @type {*}
* @memberof AppUpicker
*/
public
interaction
:
any
=
{};
/**
* 编辑器参数
*
* @type {*}
* @memberof AppUpicker
*/
@
Prop
()
public
itemParams
?:
any
;
/**
* 视图上下文
*
* @type {*}
* @memberof AppFormDRUIPart
*/
@
Prop
()
public
context
!
:
any
;
/**
* 视图参数
*
* @type {*}
* @memberof AppFormDRUIPart
*/
@
Prop
()
public
viewparams
!
:
any
;
/**
* AC参数
*
* @type {*}
* @memberof AppFormDRUIPart
*/
@
Prop
({
default
:
()
=>
{}})
public
acParams
?:
any
;
/**
* 表单服务
*
* @type {*}
* @memberof AppFormDRUIPart
*/
@
Prop
()
public
service
?:
any
;
/**
* 应用实体主信息属性名称
*
* @type {string}
* @memberof AppAutocomplete
*/
@
Prop
({
default
:
'srfmajortext'
})
public
deMajorField
!
:
string
;
/**
* 应用实体主键属性名称
*
* @type {string}
* @memberof AppAutocomplete
*/
@
Prop
({
default
:
'srfkey'
})
public
deKeyField
!
:
string
;
/**
* 表单数据
* 表单数据
*
*
* @type {*}
* @type {*}
* @memberof AppPicker
* @memberof AppPicker
*/
*/
@
Prop
()
public
data
!
:
any
;
@
Prop
()
public
data
!
:
any
;
/**
/**
* 属性项名称
* 属性项名称
*
*
* @type {string}
* @type {string}
* @memberof AppPicker
* @memberof AppPicker
*/
*/
@
Prop
()
public
name
!
:
string
;
@
Prop
()
public
name
!
:
string
;
/**
/**
* 视图上下文
* 是否启用
*
* @type {boolean}
* @memberof AppPicker
*/
@
Prop
()
public
disabled
?:
boolean
;
/**
* 是否显示按钮
*
* @type {boolean}
* @memberof AppPicker
*/
@
Prop
({
default
:
true
})
public
showButton
?:
boolean
;
/**
* 类型
*
* @type {string}
* @memberof AppPicker
*/
@
Prop
()
public
editortype
?:
string
;
/**
* 视图参数(如:视图name,title,width,height)
*
*
* @type {*}
* @type {*}
* @memberof App
FormDRUIPart
* @memberof App
Picker
*/
*/
@
Prop
()
public
context
!
:
any
;
@
Prop
()
public
pickupView
?:
any
;
/**
* 编辑器禁用
*
* @type {boolean}
* @memberof AppUpicker
*/
@
Prop
()
disabled
?:
boolean
;
/**
/**
*
视图
参数
*
数据链接
参数
*
*
* @type {*}
* @type {*}
* @memberof
SelectFormBase
* @memberof
AppPicker
*/
*/
@
Prop
()
public
viewparams
:
any
;
@
Prop
()
public
linkview
?
:
any
;
/**
/**
* 请求参数和请求数据的映射关系
* 局部上下文导航参数
*
*
* @type {*
}
* @type {any
}
* @memberof AppUp
icker
* @memberof AppP
icker
*/
*/
public
interaction
:
any
=
{}
;
@
Prop
()
public
localContext
!
:
any
;
/**
/**
* 当前表单项绑定的值
* 局部导航参数
*
*
* @type {string
}
* @type {any
}
* @memberof AppUp
icker
* @memberof AppP
icker
*/
*/
public
value
:
string
=
""
;
@
Prop
()
public
localParam
!
:
any
;
/**
/**
* 编辑器参数
* 值项名称
*
*
* @type {*
}
* @type {string
}
* @memberof AppUp
icker
* @memberof AppP
icker
*/
*/
@
Prop
()
public
itemParams
?:
any
;
@
Prop
()
public
valueitem
!
:
string
;
/**
/**
* 编辑器参数
* 排序
*
*
* @type {string}
* @type {string}
* @memberof AppUp
icker
* @memberof AppP
icker
*/
*/
@
Prop
()
public
valueItem
?:
string
;
@
Prop
()
public
sort
?:
string
;
/**
/**
* 列表项请求路径
* 行为组
*
*
* @type {string
}
* @type {Array<any>
}
* @memberof AppUp
icker
* @memberof AppP
icker
*/
*/
public
url
:
string
=
''
;
@
Prop
()
public
actionDetails
?:
Array
<
any
>
;
/**
* 下拉数组
* @type {any[]}
* @memberof AppPicker
*/
public
items
:
any
[]
=
[];
/**
/**
* 请求到的数据
* 值
* @type {any[]}
*
* @memberof AppPicker
* @type {*}
*/
* @memberof AppPicker
public
itemList
:
any
[]
=
[{
a
:
1
,
b
:
"zhangsan"
},{
a
:
2
,
b
:
"lisi"
},{
a
:
3
,
b
:
"wangwu"
}]
*/
@
Model
(
'change'
)
public
value
?:
any
;
/**
* 当前值
*
* @type {string}
* @memberof AppPicker
*/
public
curvalue
:
string
=
''
;
/**
* 下拉数组
* @type {any[]}
* @memberof AppPicker
*/
public
items
:
any
[]
=
[];
/**
* 下拉图标指向状态管理
* @type {boolean}
* @memberof AppPicker
*/
public
open
:
boolean
=
false
;
/**
* 输入状态
*
* @type {boolean}
* @memberof AppAutocomplete
*/
public
inputState
:
boolean
=
false
;
/**
* 当前选择的值
*
* @type {string}
* @memberof AppPicker
*/
public
selectValue
=
this
.
value
;
/**
* 获取关联数据项值
*
* @readonly
* @memberof AppPicker
*/
get
refvalue
()
{
if
(
this
.
valueitem
&&
this
.
data
)
{
return
this
.
data
[
this
.
valueitem
];
}
return
this
.
curvalue
;
}
/**
* 值变化
*
* @param {*} newVal
* @param {*} oldVal
* @memberof AppPicker
*/
@
Watch
(
'value'
,{
immediate
:
true
})
public
onValueChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
curvalue
=
newVal
;
if
(
Object
.
is
(
this
.
editortype
,
'dropdown'
)
&&
this
.
valueitem
)
{
const
value
=
this
.
data
[
this
.
valueitem
];
const
index
=
this
.
items
.
findIndex
((
item
:
any
)
=>
Object
.
is
(
item
.
value
,
value
));
if
(
index
!==
-
1
)
{
return
;
}
this
.
items
=
[];
if
(
value
)
{
this
.
items
.
push
({
text
:
newVal
,
value
:
value
});
}
this
.
fectchItemList
(
this
.
url
);
}
}
/**
* vue 生命周期
*
* @memberof AppPicker
*/
public
created
()
{
if
(
!
Object
.
is
(
this
.
editortype
,
'pickup-no-ac'
)
&&
!
Object
.
is
(
this
.
editortype
,
'dropdown'
)){
this
.
curvalue
=
this
.
value
;
}
}
/**
/**
* vue 生命周期
* vue 生命周期
*
*
* @memberof AppPicker
* @memberof AppPicker
*/
*/
public
mounted
()
{
public
mounted
()
{
// 解析编辑器参数
// 解析编辑器参数
this
.
analysis
(
this
.
itemParams
);
this
.
analysis
(
this
.
itemParams
);
// 请求下拉数据
// 请求下拉数据
this
.
fectchItemList
(
this
.
url
);
this
.
fectchItemList
(
this
.
url
);
}
}
/**
/**
*
下拉重新加载数据
*
组件销毁
*
*
* @memberof AppPicker
* @memberof AppPicker
*/
*/
public
onSelectOpen
()
{
public
destroyed
():
void
{
this
.
fectchItemList
(
this
.
url
);
}
}
/**
/**
* 解析编辑器参数
* 解析编辑器参数
* @param {*} itemparams
* @param {*} itemparams
...
@@ -183,26 +369,476 @@ export default class AppPicker extends Vue {
...
@@ -183,26 +369,476 @@ export default class AppPicker extends Vue {
});
});
});
});
}
}
public
onSelect
(
val
:
string
)
{
/**
let
index
=
this
.
items
.
findIndex
((
item
)
=>
Object
.
is
(
item
.
value
,
val
));
* 下拉切换回调
if
(
index
>=
0
)
{
* @param flag
this
.
onACSelect
(
this
.
items
[
index
]);
*/
public
onSelectOpen
(
flag
:
boolean
):
void
{
this
.
open
=
flag
;
if
(
this
.
open
)
{
this
.
fectchItemList
(
this
.
url
);
}
}
}
}
/**
/**
* 执行搜索数据
* @param query
* @param callback
*/
public
onSearch
(
query
:
any
,
callback
:
any
,
other
:
boolean
):
void
{
// 公共参数处理
let
data
:
any
=
{};
const
bcancel
:
boolean
=
this
.
handlePublicParams
(
data
);
if
(
!
bcancel
)
{
return
;
}
// 处理搜索参数
let
_context
=
data
.
context
;
let
_param
=
data
.
param
;
query
=
!
query
?
''
:
query
;
if
(
!
this
.
inputState
&&
other
&&
Object
.
is
(
query
,
this
.
value
))
{
query
=
''
;
}
this
.
inputState
=
false
;
if
(
this
.
sort
&&
!
Object
.
is
(
this
.
sort
,
""
))
{
Object
.
assign
(
_param
,
{
sort
:
this
.
sort
});
}
Object
.
assign
(
_param
,
{
query
:
query
,
size
:
1000
});
// 错误信息国际化
let
error
:
string
=
(
this
.
$t
(
'components.appPicker.error'
)
as
any
);
let
miss
:
string
=
(
this
.
$t
(
'components.appPicker.miss'
)
as
any
);
let
requestException
:
string
=
(
this
.
$t
(
'components.appPicker.requestException'
)
as
any
);
if
(
!
this
.
service
){
this
.
$Notice
.
error
({
title
:
error
,
desc
:
miss
+
'service'
});
}
else
if
(
!
this
.
acParams
.
serviceName
)
{
this
.
$Notice
.
error
({
title
:
error
,
desc
:
miss
+
'serviceName'
});
}
else
if
(
!
this
.
acParams
.
interfaceName
)
{
this
.
$Notice
.
error
({
title
:
error
,
desc
:
miss
+
'interfaceName'
});
}
else
{
this
.
service
.
getItems
(
this
.
acParams
.
serviceName
,
this
.
acParams
.
interfaceName
,
_context
,
_param
).
then
((
response
:
any
)
=>
{
if
(
!
response
)
{
this
.
$Notice
.
error
({
title
:
error
,
desc
:
requestException
});
}
else
{
this
.
items
=
[...
response
];
}
// if(this.acParams && this.linkview){
// this.items.push({ isNew :true });
// }
if
(
this
.
acParams
&&
this
.
actionDetails
&&
this
.
actionDetails
.
length
>
0
){
this
.
items
=
[...
this
.
items
,...
this
.
actionDetails
];
}
if
(
callback
)
{
callback
(
this
.
items
);
}
}).
catch
((
error
:
any
)
=>
{
if
(
callback
)
{
callback
([]);
}
});
}
}
/**
* 选中数据回调
* 选中数据回调
* @param item
* @param item
*/
*/
public
onACSelect
(
item
:
any
):
void
{
public
onACSelect
(
item
:
any
):
void
{
if
(
this
.
name
){
this
.
selectValue
=
item
.
value
;
this
.
$emit
(
'formitemvaluechange'
,
{
name
:
this
.
name
,
value
:
item
.
value
});
if
(
this
.
valueitem
)
{
}
this
.
$emit
(
'formitemvaluechange'
,
{
name
:
this
.
valueitem
,
value
:
item
.
value
});
if
(
this
.
valueItem
){
}
this
.
$emit
(
'formitemvaluechange'
,
{
name
:
this
.
valueItem
,
value
:
item
.
value
});
if
(
this
.
name
)
{
}
this
.
$emit
(
'formitemvaluechange'
,
{
name
:
this
.
name
,
value
:
item
.
value
});
}
}
/**
* 下拉选中
*
* @param {string} val
* @memberof AppPicker
*/
public
onSelect
(
val
:
string
)
{
let
index
=
this
.
items
.
findIndex
((
item
)
=>
Object
.
is
(
item
.
value
,
val
));
if
(
index
>=
0
)
{
this
.
onACSelect
(
this
.
items
[
index
]);
}
}
/**
* 失去焦点事件
* @param e
*/
public
onBlur
(
e
:
any
):
void
{
this
.
curvalue
=
this
.
value
;
}
/**
* 清除
*/
public
onClear
(
$event
:
any
):
void
{
if
(
this
.
valueitem
)
{
this
.
$emit
(
'formitemvaluechange'
,
{
name
:
this
.
valueitem
,
value
:
''
});
}
if
(
this
.
name
)
{
this
.
$emit
(
'formitemvaluechange'
,
{
name
:
this
.
name
,
value
:
''
});
}
this
.
$forceUpdate
();
}
/**
* 打开视图
*/
public
openView
(
$event
:
any
):
void
{
if
(
this
.
disabled
)
{
return
;
}
// 公共参数处理
let
data
:
any
=
{};
const
bcancel
:
boolean
=
this
.
handlePublicParams
(
data
);
if
(
!
bcancel
)
{
return
;
}
// 参数处理
const
view
=
{
...
this
.
pickupView
};
let
_context
=
data
.
context
;
let
_param
=
data
.
param
;
_param
.
selectedData
=
[{
srfkey
:
this
.
data
[
this
.
valueitem
],
srfmajortext
:
this
.
curvalue
}];
// 判断打开方式
if
(
view
.
placement
&&
!
Object
.
is
(
view
.
placement
,
''
))
{
if
(
Object
.
is
(
view
.
placement
,
'POPOVER'
))
{
this
.
openPopOver
(
$event
,
view
,
_context
,
_param
);
}
else
{
this
.
openDrawer
(
view
,
_context
,
_param
);
}
}
else
{
this
.
openPopupModal
(
view
,
_context
,
_param
);
}
}
}
/**
* 路由模式打开视图
*
* @private
* @param {string} viewpath
* @param {*} data
* @memberof AppPicker
*/
private
openIndexViewTab
(
view
:
any
,
context
:
any
,
param
:
any
):
void
{
const
routePath
=
this
.
$viewTool
.
buildUpRoutePath
(
this
.
$route
,
this
.
context
,
view
.
deResParameters
,
view
.
parameters
,
[
context
]
,
param
);
this
.
$router
.
push
(
routePath
);
}
/**
* 模态模式打开视图
*
* @private
* @param {*} view
* @param {*} data
* @memberof AppPicker
*/
private
openPopupModal
(
view
:
any
,
context
:
any
,
param
:
any
):
void
{
let
container
:
Subject
<
any
>
=
this
.
$appmodal
.
openModal
(
view
,
context
,
param
);
container
.
subscribe
((
result
:
any
)
=>
{
if
(
!
result
||
!
Object
.
is
(
result
.
ret
,
'OK'
))
{
return
;
}
this
.
openViewClose
(
result
);
});
}
/**
* 抽屉模式打开视图
*
* @private
* @param {*} view
* @param {*} data
* @memberof AppPicker
*/
private
openDrawer
(
view
:
any
,
context
:
any
,
param
:
any
):
void
{
let
container
:
Subject
<
any
>
=
this
.
$appdrawer
.
openDrawer
(
view
,
context
,
param
);
container
.
subscribe
((
result
:
any
)
=>
{
if
(
!
result
||
!
Object
.
is
(
result
.
ret
,
'OK'
))
{
return
;
}
this
.
openViewClose
(
result
);
});
}
/**
* 气泡卡片模式打开
*
* @private
* @param {*} $event
* @param {*} view
* @param {*} data
* @memberof AppPicker
*/
private
openPopOver
(
$event
:
any
,
view
:
any
,
context
:
any
,
param
:
any
):
void
{
let
container
:
Subject
<
any
>
=
this
.
$apppopover
.
openPop
(
$event
,
view
,
context
,
param
);
container
.
subscribe
((
result
:
any
)
=>
{
if
(
!
result
||
!
Object
.
is
(
result
.
ret
,
'OK'
))
{
return
;
}
this
.
openViewClose
(
result
);
});
}
/**
* 独立里面弹出
*
* @private
* @param {string} url
* @memberof AppPicker
*/
private
openPopupApp
(
url
:
string
):
void
{
window
.
open
(
url
,
'_blank'
);
}
/**
* 打开重定向视图
*
* @private
* @param {*} $event
* @param {*} view
* @param {*} data
* @memberof AppPicker
*/
private
openRedirectView
(
$event
:
any
,
view
:
any
,
data
:
any
):
void
{
this
.
$http
.
get
(
view
.
url
,
data
).
then
((
response
:
any
)
=>
{
if
(
!
response
||
response
.
status
!==
200
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'components.appPicker.error'
)
as
any
),
desc
:
(
this
.
$t
(
'components.appPicker.requestException'
)
as
any
)
});
}
if
(
response
.
status
===
401
)
{
return
;
}
const
{
data
:
result
}
=
response
;
if
(
result
.
viewparams
&&
!
Object
.
is
(
result
.
viewparams
.
srfkey
,
''
))
{
Object
.
assign
(
data
,
{
srfkey
:
result
.
viewparams
.
srfkey
});
}
if
(
Object
.
is
(
result
.
openmode
,
'POPUPAPP'
)
&&
result
.
url
&&
!
Object
.
is
(
result
.
url
,
''
))
{
this
.
openPopupApp
(
result
.
url
);
}
else
if
(
Object
.
is
(
result
.
openmode
,
'INDEXVIEWTAB'
)
||
Object
.
is
(
result
.
openmode
,
''
))
{
// 所有数据保持在同一级
if
(
data
.
srfparentdata
)
{
Object
.
assign
(
data
,
data
.
srfparentdata
);
delete
data
.
srfparentdata
;
}
this
.
openIndexViewTab
(
view
,
null
,
data
);
}
else
if
(
Object
.
is
(
result
.
openmode
,
'POPUPMODAL'
))
{
const
viewname
=
this
.
$util
.
srfFilePath2
(
result
.
viewname
);
const
view
:
any
=
{
viewname
:
viewname
,
title
:
result
.
title
,
width
:
result
.
width
,
height
:
result
.
height
,
}
this
.
openPopupModal
(
view
,
null
,
data
);
}
else
if
(
result
.
openmode
.
startsWith
(
'DRAWER'
))
{
const
viewname
=
this
.
$util
.
srfFilePath2
(
result
.
viewname
);
const
view
:
any
=
{
viewname
:
viewname
,
title
:
result
.
title
,
width
:
result
.
width
,
height
:
result
.
height
,
placement
:
result
.
openmode
,
}
this
.
openDrawer
(
view
,
null
,
data
);
}
else
if
(
Object
.
is
(
result
.
openmode
,
'POPOVER'
))
{
const
viewname
=
this
.
$util
.
srfFilePath2
(
result
.
viewname
);
const
view
:
any
=
{
viewname
:
viewname
,
title
:
result
.
title
,
width
:
result
.
width
,
height
:
result
.
height
,
placement
:
result
.
openmode
,
}
this
.
openPopOver
(
$event
,
view
,
null
,
data
);
}
}).
catch
((
response
:
any
)
=>
{
if
(
!
response
||
!
response
.
status
||
!
response
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'components.appPicker.error'
)
as
any
),
desc
:
(
this
.
$t
(
'components.appPicker.systemException'
)
as
any
)
});
return
;
}
if
(
response
.
status
===
401
)
{
return
;
}
});
}
/**
* 打开链接视图
*
* @memberof AppPicker
*/
public
openLinkView
(
$event
:
any
):
void
{
if
(
!
this
.
data
||
!
this
.
valueitem
||
!
this
.
data
[
this
.
valueitem
])
{
console
.
error
({
title
:
(
this
.
$t
(
'components.appPicker.error'
)
as
any
),
desc
:
(
this
.
$t
(
'components.appPicker.valueitemException'
)
as
any
)
});
return
;
}
// 公共参数处理
let
data
:
any
=
{};
const
bcancel
:
boolean
=
this
.
handlePublicParams
(
data
);
if
(
!
bcancel
)
{
return
;
}
// 参数处理
let
_context
=
data
.
context
;
let
_param
=
data
.
param
;
Object
.
assign
(
_context
,
{
[
this
.
deKeyField
]:
this
.
data
[
this
.
valueitem
]
});
const
view
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
linkview
));
const
viewname2
:
string
=
this
.
$util
.
srfFilePath2
(
view
.
viewname
);
view
.
viewname
=
viewname2
;
if
(
view
.
isRedirectView
)
{
this
.
openRedirectView
(
$event
,
view
,
data
);
}
else
if
(
Object
.
is
(
view
.
placement
,
'INDEXVIEWTAB'
)
||
Object
.
is
(
view
.
placement
,
''
))
{
this
.
openIndexViewTab
(
view
,
_context
,
_param
);
}
else
if
(
Object
.
is
(
view
.
placement
,
'POPOVER'
))
{
this
.
openPopOver
(
$event
,
view
,
_context
,
_param
);
}
else
if
(
Object
.
is
(
view
.
placement
,
'POPUPMODAL'
))
{
this
.
openPopupModal
(
view
,
_context
,
_param
);
}
else
if
(
view
.
placement
.
startsWith
(
'DRAWER'
))
{
this
.
openDrawer
(
view
,
_context
,
_param
);
}
}
/**
* 打开页面关闭
*
* @param {*} result
* @memberof AppPicker
*/
public
openViewClose
(
result
:
any
)
{
let
item
:
any
=
{};
if
(
result
.
datas
&&
Array
.
isArray
(
result
.
datas
))
{
Object
.
assign
(
item
,
result
.
datas
[
0
]);
}
if
(
this
.
data
)
{
if
(
this
.
valueitem
)
{
this
.
$emit
(
'formitemvaluechange'
,
{
name
:
this
.
valueitem
,
value
:
item
[
this
.
deKeyField
]?
item
[
this
.
deKeyField
]:
item
[
"srfkey"
]
});
}
if
(
this
.
name
)
{
this
.
$emit
(
'formitemvaluechange'
,
{
name
:
this
.
name
,
value
:
item
[
this
.
deMajorField
]?
item
[
this
.
deMajorField
]:
item
[
"srfmajortext"
]
});
}
}
}
/**
* 公共参数处理
*
* @param {*} arg
* @returns
* @memberof AppPicker
*/
public
handlePublicParams
(
arg
:
any
):
boolean
{
if
(
!
this
.
data
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'components.appPicker.error'
)
as
any
),
desc
:
(
this
.
$t
(
'components.appPicker.formdataException'
)
as
any
)
});
return
false
;
}
// 合并表单参数
arg
.
param
=
this
.
viewparams
?
JSON
.
parse
(
JSON
.
stringify
(
this
.
viewparams
))
:
{};
arg
.
context
=
this
.
context
?
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
))
:
{};
// 附加参数处理
if
(
this
.
localContext
&&
Object
.
keys
(
this
.
localContext
).
length
>
0
)
{
let
_context
=
this
.
$util
.
computedNavData
(
this
.
data
,
arg
.
context
,
arg
.
param
,
this
.
localContext
);
Object
.
assign
(
arg
.
context
,
_context
);
}
if
(
this
.
localParam
&&
Object
.
keys
(
this
.
localParam
).
length
>
0
)
{
let
_param
=
this
.
$util
.
computedNavData
(
this
.
data
,
arg
.
param
,
arg
.
param
,
this
.
localParam
);
Object
.
assign
(
arg
.
param
,
_param
);
}
return
true
;
}
/**
* 触发界面行为
*
* @param {*} arg
* @returns
* @memberof AppPicker
*/
public
clickAction
(
arg
:
any
){
this
.
$emit
(
'editoractionclick'
,
arg
);
}
/**
* 创建并编辑
*
* @param {*} arg
* @returns
* @memberof AppPicker
*/
public
newAndEdit
(
$event
:
any
){
if
(
this
.
disabled
)
{
return
;
}
// 公共参数处理
let
data
:
any
=
{};
const
bcancel
:
boolean
=
this
.
handlePublicParams
(
data
);
if
(
!
bcancel
)
{
return
;
}
// 参数处理
const
view
=
{
...
this
.
linkview
};
view
.
viewname
=
this
.
$util
.
srfFilePath2
(
view
.
viewname
);
let
_context
=
data
.
context
;
delete
_context
[
this
.
deKeyField
];
let
_param
=
data
.
param
;
// 判断打开方式
if
(
view
.
placement
&&
!
Object
.
is
(
view
.
placement
,
''
))
{
if
(
Object
.
is
(
view
.
placement
,
'POPOVER'
))
{
this
.
openPopOver
(
$event
,
view
,
_context
,
_param
);
}
else
{
this
.
openDrawer
(
view
,
_context
,
_param
);
}
}
else
{
this
.
openPopupModal
(
view
,
_context
,
_param
);
}
}
/**
* 输入过程中
*
* @memberof AppAutocomplete
*/
public
onInput
(
$event
:
any
)
{
if
(
Object
.
is
(
$event
,
this
.
value
))
{
this
.
inputState
=
true
;
}
}
/**
* 展开下拉
*
* @memberof AppPicker
*/
public
openDropdown
()
{
const
appPicker
:
any
=
this
.
$refs
.
appPicker
;
if
(
appPicker
)
{
appPicker
.
focus
();
}
}
/**
* 收起下拉
*
* @memberof AppPicker
*/
public
closeDropdown
()
{
const
appPicker
:
any
=
this
.
$refs
.
appPicker
;
if
(
appPicker
)
{
appPicker
.
blur
();
}
}
}
}
</
script
>
</
script
>
<
style
lang=
"less"
>
<
style
lang=
"less"
>
...
...
app_Web/src/widgets/ibzdepartment/main-form/main-form-base.vue
浏览文件 @
a223d1f5
...
@@ -100,6 +100,7 @@
...
@@ -100,6 +100,7 @@
:disabled="detailsModel.leadername.disabled"
:disabled="detailsModel.leadername.disabled"
:data="data"
:data="data"
:context="context"
:context="context"
@formitemvaluechange="onFormItemValueChange">
@formitemvaluechange="onFormItemValueChange">
</app-group-select>
</app-group-select>
...
...
ibzrt-app/ibzrt-app-web/src/main/resources/application-web-prod.yml
浏览文件 @
a223d1f5
...
@@ -97,7 +97,7 @@ zuul:
...
@@ -97,7 +97,7 @@ zuul:
stripPrefix
:
false
stripPrefix
:
false
ibzemp
:
ibzemp
:
path
:
/ibzemployees/**
path
:
/ibzemployees/**
serviceId
:
${ibiz.ref.service.ibz
rt-api:ibzrt
-api}
serviceId
:
${ibiz.ref.service.ibz
ou-api:ibzou
-api}
stripPrefix
:
false
stripPrefix
:
false
sys_app
:
sys_app
:
path
:
/sysapps/**
path
:
/sysapps/**
...
...
ibzrt-boot/src/main/resources/application-dev.yml
浏览文件 @
a223d1f5
...
@@ -20,6 +20,10 @@ zuul:
...
@@ -20,6 +20,10 @@ zuul:
path
:
/ibzdeptmembers/**
path
:
/ibzdeptmembers/**
serviceId
:
${ibiz.ref.service.ibzou-api:ibzou-api}
serviceId
:
${ibiz.ref.service.ibzou-api:ibzou-api}
stripPrefix
:
false
stripPrefix
:
false
ibzemp
:
path
:
/ibzemps/**
serviceId
:
${ibiz.ref.service.ibzou-api:ibzou-api}
stripPrefix
:
false
ibzorg
:
ibzorg
:
path
:
/ibzorgs/**
path
:
/ibzorgs/**
serviceId
:
${ibiz.ref.service.ibzou-api:ibzou-api}
serviceId
:
${ibiz.ref.service.ibzou-api:ibzou-api}
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/extensions/service/IBZEmployeeExService.java
浏览文件 @
a223d1f5
...
@@ -16,10 +16,6 @@ import java.util.*;
...
@@ -16,10 +16,6 @@ import java.util.*;
@Service
(
"IBZEmployeeExService"
)
@Service
(
"IBZEmployeeExService"
)
public
class
IBZEmployeeExService
extends
IBZEmployeeServiceImpl
{
public
class
IBZEmployeeExService
extends
IBZEmployeeServiceImpl
{
@Override
protected
Class
currentModelClass
()
{
return
com
.
baomidou
.
mybatisplus
.
core
.
toolkit
.
ReflectionKit
.
getSuperClassGenericType
(
this
.
getClass
().
getSuperclass
(),
1
);
}
/**
/**
* 自定义行为[InitPwd]用户扩展
* 自定义行为[InitPwd]用户扩展
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/ou/domain/IBZEmployee.java
浏览文件 @
a223d1f5
...
@@ -23,312 +23,300 @@ import lombok.*;
...
@@ -23,312 +23,300 @@ import lombok.*;
import
org.springframework.data.annotation.Transient
;
import
org.springframework.data.annotation.Transient
;
import
cn.ibizlab.util.annotation.Audit
;
import
cn.ibizlab.util.annotation.Audit
;
import
cn.ibizlab.util.domain.EntityClient
;
import
com.fasterxml.jackson.annotation.JsonIgnoreProperties
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.util.domain.EntityMP
;
/**
/**
*
实体[人员]
*
ServiceApi [人员] 对象
*/
*/
@Getter
@Data
@Setter
public
class
IBZEmployee
extends
EntityClient
implements
Serializable
{
@NoArgsConstructor
@JsonIgnoreProperties
(
value
=
"handler"
)
@TableName
(
value
=
"IBZEMP"
,
resultMap
=
"IBZEmployeeResultMap"
)
public
class
IBZEmployee
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
/**
/**
* 用户标识
* 用户标识
*/
*/
@DEField
(
isKeyField
=
true
)
@DEField
(
isKeyField
=
true
)
@TableId
(
value
=
"userid"
,
type
=
IdType
.
ASSIGN_UUID
)
@JSONField
(
name
=
"userid"
)
@JSONField
(
name
=
"userid"
)
@JsonProperty
(
"userid"
)
@JsonProperty
(
"userid"
)
private
String
userid
;
private
String
userid
;
/**
/**
* 用户全局名
* 用户全局名
*/
*/
@TableField
(
value
=
"username"
)
@JSONField
(
name
=
"username"
)
@JSONField
(
name
=
"username"
)
@JsonProperty
(
"username"
)
@JsonProperty
(
"username"
)
private
String
username
;
private
String
username
;
/**
/**
* 姓名
* 姓名
*/
*/
@TableField
(
value
=
"personname"
)
@JSONField
(
name
=
"personname"
)
@JSONField
(
name
=
"personname"
)
@JsonProperty
(
"personname"
)
@JsonProperty
(
"personname"
)
private
String
personname
;
private
String
personname
;
/**
/**
* 用户工号
* 用户工号
*/
*/
@TableField
(
value
=
"usercode"
)
@JSONField
(
name
=
"usercode"
)
@JSONField
(
name
=
"usercode"
)
@JsonProperty
(
"usercode"
)
@JsonProperty
(
"usercode"
)
private
String
usercode
;
private
String
usercode
;
/**
/**
* 登录名
* 登录名
*/
*/
@TableField
(
value
=
"loginname"
)
@JSONField
(
name
=
"loginname"
)
@JSONField
(
name
=
"loginname"
)
@JsonProperty
(
"loginname"
)
@JsonProperty
(
"loginname"
)
private
String
loginname
;
private
String
loginname
;
/**
/**
* 密码
* 密码
*/
*/
@TableField
(
value
=
"password"
)
@JSONField
(
name
=
"password"
)
@JSONField
(
name
=
"password"
)
@JsonProperty
(
"password"
)
@JsonProperty
(
"password"
)
private
String
password
;
private
String
password
;
/**
/**
* 区属
* 区属
*/
*/
@TableField
(
value
=
"domains"
)
@JSONField
(
name
=
"domains"
)
@JSONField
(
name
=
"domains"
)
@JsonProperty
(
"domains"
)
@JsonProperty
(
"domains"
)
private
String
domains
;
private
String
domains
;
/**
/**
* 主部门
* 主部门
*/
*/
@TableField
(
value
=
"mdeptid"
)
@JSONField
(
name
=
"mdeptid"
)
@JSONField
(
name
=
"mdeptid"
)
@JsonProperty
(
"mdeptid"
)
@JsonProperty
(
"mdeptid"
)
private
String
mdeptid
;
private
String
mdeptid
;
/**
/**
* 主部门代码
* 主部门代码
*/
*/
@TableField
(
value
=
"mdeptcode"
)
@JSONField
(
name
=
"mdeptcode"
)
@JSONField
(
name
=
"mdeptcode"
)
@JsonProperty
(
"mdeptcode"
)
@JsonProperty
(
"mdeptcode"
)
private
String
mdeptcode
;
private
String
mdeptcode
;
/**
/**
* 主部门名称
* 主部门名称
*/
*/
@TableField
(
value
=
"mdeptname"
)
@JSONField
(
name
=
"mdeptname"
)
@JSONField
(
name
=
"mdeptname"
)
@JsonProperty
(
"mdeptname"
)
@JsonProperty
(
"mdeptname"
)
private
String
mdeptname
;
private
String
mdeptname
;
/**
/**
* 业务编码
* 业务编码
*/
*/
@TableField
(
value
=
"bcode"
)
@JSONField
(
name
=
"bcode"
)
@JSONField
(
name
=
"bcode"
)
@JsonProperty
(
"bcode"
)
@JsonProperty
(
"bcode"
)
private
String
bcode
;
private
String
bcode
;
/**
/**
* 岗位标识
* 岗位标识
*/
*/
@TableField
(
value
=
"postid"
)
@JSONField
(
name
=
"postid"
)
@JSONField
(
name
=
"postid"
)
@JsonProperty
(
"postid"
)
@JsonProperty
(
"postid"
)
private
String
postid
;
private
String
postid
;
/**
/**
* 岗位代码
* 岗位代码
*/
*/
@TableField
(
value
=
"postcode"
)
@JSONField
(
name
=
"postcode"
)
@JSONField
(
name
=
"postcode"
)
@JsonProperty
(
"postcode"
)
@JsonProperty
(
"postcode"
)
private
String
postcode
;
private
String
postcode
;
/**
/**
* 岗位名称
* 岗位名称
*/
*/
@TableField
(
value
=
"postname"
)
@JSONField
(
name
=
"postname"
)
@JSONField
(
name
=
"postname"
)
@JsonProperty
(
"postname"
)
@JsonProperty
(
"postname"
)
private
String
postname
;
private
String
postname
;
/**
/**
* 单位
* 单位
*/
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
ORGID
)
@DEField
(
preType
=
DEPredefinedFieldType
.
ORGID
)
@TableField
(
value
=
"orgid"
)
@JSONField
(
name
=
"orgid"
)
@JSONField
(
name
=
"orgid"
)
@JsonProperty
(
"orgid"
)
@JsonProperty
(
"orgid"
)
private
String
orgid
;
private
String
orgid
;
/**
/**
* 单位代码
* 单位代码
*/
*/
@TableField
(
value
=
"orgcode"
)
@JSONField
(
name
=
"orgcode"
)
@JSONField
(
name
=
"orgcode"
)
@JsonProperty
(
"orgcode"
)
@JsonProperty
(
"orgcode"
)
private
String
orgcode
;
private
String
orgcode
;
/**
/**
* 单位名称
* 单位名称
*/
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
ORGNAME
)
@DEField
(
preType
=
DEPredefinedFieldType
.
ORGNAME
)
@TableField
(
value
=
"orgname"
)
@JSONField
(
name
=
"orgname"
)
@JSONField
(
name
=
"orgname"
)
@JsonProperty
(
"orgname"
)
@JsonProperty
(
"orgname"
)
private
String
orgname
;
private
String
orgname
;
/**
/**
* 昵称别名
* 昵称别名
*/
*/
@TableField
(
value
=
"nickname"
)
@JSONField
(
name
=
"nickname"
)
@JSONField
(
name
=
"nickname"
)
@JsonProperty
(
"nickname"
)
@JsonProperty
(
"nickname"
)
private
String
nickname
;
private
String
nickname
;
/**
/**
* 性别
* 性别
*/
*/
@TableField
(
value
=
"sex"
)
@JSONField
(
name
=
"sex"
)
@JSONField
(
name
=
"sex"
)
@JsonProperty
(
"sex"
)
@JsonProperty
(
"sex"
)
private
String
sex
;
private
String
sex
;
/**
/**
* 证件号码
* 证件号码
*/
*/
@TableField
(
value
=
"certcode"
)
@JSONField
(
name
=
"certcode"
)
@JSONField
(
name
=
"certcode"
)
@JsonProperty
(
"certcode"
)
@JsonProperty
(
"certcode"
)
private
String
certcode
;
private
String
certcode
;
/**
/**
* 联系方式
* 联系方式
*/
*/
@TableField
(
value
=
"phone"
)
@JSONField
(
name
=
"phone"
)
@JSONField
(
name
=
"phone"
)
@JsonProperty
(
"phone"
)
@JsonProperty
(
"phone"
)
private
String
phone
;
private
String
phone
;
/**
/**
* 出生日期
* 出生日期
*/
*/
@TableField
(
value
=
"birthday"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"birthday"
,
format
=
"yyyy-MM-dd"
)
@JSONField
(
name
=
"birthday"
,
format
=
"yyyy-MM-dd"
)
@JsonProperty
(
"birthday"
)
@JsonProperty
(
"birthday"
)
private
Timestamp
birthday
;
private
Timestamp
birthday
;
/**
/**
* 邮件
* 邮件
*/
*/
@TableField
(
value
=
"email"
)
@JSONField
(
name
=
"email"
)
@JSONField
(
name
=
"email"
)
@JsonProperty
(
"email"
)
@JsonProperty
(
"email"
)
private
String
email
;
private
String
email
;
/**
/**
* 社交账号
* 社交账号
*/
*/
@TableField
(
value
=
"avatar"
)
@JSONField
(
name
=
"avatar"
)
@JSONField
(
name
=
"avatar"
)
@JsonProperty
(
"avatar"
)
@JsonProperty
(
"avatar"
)
private
String
avatar
;
private
String
avatar
;
/**
/**
* 地址
* 地址
*/
*/
@TableField
(
value
=
"addr"
)
@JSONField
(
name
=
"addr"
)
@JSONField
(
name
=
"addr"
)
@JsonProperty
(
"addr"
)
@JsonProperty
(
"addr"
)
private
String
addr
;
private
String
addr
;
/**
/**
* 照片
* 照片
*/
*/
@TableField
(
value
=
"usericon"
)
@JSONField
(
name
=
"usericon"
)
@JSONField
(
name
=
"usericon"
)
@JsonProperty
(
"usericon"
)
@JsonProperty
(
"usericon"
)
private
String
usericon
;
private
String
usericon
;
/**
/**
* ip地址
* ip地址
*/
*/
@TableField
(
value
=
"ipaddr"
)
@JSONField
(
name
=
"ipaddr"
)
@JSONField
(
name
=
"ipaddr"
)
@JsonProperty
(
"ipaddr"
)
@JsonProperty
(
"ipaddr"
)
private
String
ipaddr
;
private
String
ipaddr
;
/**
/**
* 样式
* 样式
*/
*/
@TableField
(
value
=
"theme"
)
@JSONField
(
name
=
"theme"
)
@JSONField
(
name
=
"theme"
)
@JsonProperty
(
"theme"
)
@JsonProperty
(
"theme"
)
private
String
theme
;
private
String
theme
;
/**
/**
* 语言
* 语言
*/
*/
@TableField
(
value
=
"lang"
)
@JSONField
(
name
=
"lang"
)
@JSONField
(
name
=
"lang"
)
@JsonProperty
(
"lang"
)
@JsonProperty
(
"lang"
)
private
String
lang
;
private
String
lang
;
/**
/**
* 字号
* 字号
*/
*/
@TableField
(
value
=
"fontsize"
)
@JSONField
(
name
=
"fontsize"
)
@JSONField
(
name
=
"fontsize"
)
@JsonProperty
(
"fontsize"
)
@JsonProperty
(
"fontsize"
)
private
String
fontsize
;
private
String
fontsize
;
/**
/**
* 备注
* 备注
*/
*/
@TableField
(
value
=
"memo"
)
@JSONField
(
name
=
"memo"
)
@JSONField
(
name
=
"memo"
)
@JsonProperty
(
"memo"
)
@JsonProperty
(
"memo"
)
private
String
memo
;
private
String
memo
;
/**
/**
* 保留
* 保留
*/
*/
@TableField
(
value
=
"reserver"
)
@JSONField
(
name
=
"reserver"
)
@JSONField
(
name
=
"reserver"
)
@JsonProperty
(
"reserver"
)
@JsonProperty
(
"reserver"
)
private
String
reserver
;
private
String
reserver
;
/**
/**
* 排序
* 排序
*/
*/
@TableField
(
value
=
"showorder"
)
@JSONField
(
name
=
"showorder"
)
@JSONField
(
name
=
"showorder"
)
@JsonProperty
(
"showorder"
)
@JsonProperty
(
"showorder"
)
private
Integer
showorder
;
private
Integer
showorder
;
/**
/**
* 逻辑有效
* 逻辑有效
*/
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
LOGICVALID
,
logicval
=
"1"
,
logicdelval
=
"0"
)
@DEField
(
preType
=
DEPredefinedFieldType
.
LOGICVALID
,
logicval
=
"1"
,
logicdelval
=
"0"
)
@TableLogic
(
value
=
"1"
,
delval
=
"0"
)
@TableField
(
value
=
"enable"
)
@JSONField
(
name
=
"enable"
)
@JSONField
(
name
=
"enable"
)
@JsonProperty
(
"enable"
)
@JsonProperty
(
"enable"
)
private
Integer
enable
;
private
Integer
enable
;
/**
/**
* 创建时间
* 创建时间
*/
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@TableField
(
value
=
"createdate"
,
fill
=
FieldFill
.
INSERT
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"createdate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JSONField
(
name
=
"createdate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"createdate"
)
@JsonProperty
(
"createdate"
)
private
Timestamp
createdate
;
private
Timestamp
createdate
;
/**
/**
* 最后修改时间
* 最后修改时间
*/
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEDATE
)
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEDATE
)
@TableField
(
value
=
"updatedate"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"updatedate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JSONField
(
name
=
"updatedate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"updatedate"
)
@JsonProperty
(
"updatedate"
)
private
Timestamp
updatedate
;
private
Timestamp
updatedate
;
/**
/**
*
*
*/
*/
@JsonIgnore
@JSONField
(
name
=
"maindept"
)
@JSONField
(
serialize
=
false
)
@JsonProperty
(
"maindept"
)
@TableField
(
exist
=
false
)
private
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZDepartment
maindept
;
private
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZDepartment
maindept
;
/**
/**
*
*
*/
*/
@JsonIgnore
@JSONField
(
name
=
"org"
)
@JSONField
(
serialize
=
false
)
@JsonProperty
(
"org"
)
@TableField
(
exist
=
false
)
private
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZOrganization
org
;
private
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZOrganization
org
;
/**
/**
*
*
*/
*/
@JsonIgnore
@JSONField
(
name
=
"post"
)
@JSONField
(
serialize
=
false
)
@JsonProperty
(
"post"
)
@TableField
(
exist
=
false
)
private
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZPost
post
;
private
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZPost
post
;
/**
/**
* 设置 [用户全局名]
* 设置 [用户全局名]
*/
*/
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/ou/filter/IBZEmployeeSearchContext.java
浏览文件 @
a223d1f5
...
@@ -17,107 +17,36 @@ import org.springframework.util.ObjectUtils;
...
@@ -17,107 +17,36 @@ import org.springframework.util.ObjectUtils;
import
org.springframework.util.StringUtils
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.util.filter.QueryWrapperContext
;
import
cn.ibizlab.util.filter.SearchContextBase
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.core.ou.domain.IBZEmployee
;
/**
/**
*
关系型
数据实体[IBZEmployee] 查询条件对象
*
ServiceApi
数据实体[IBZEmployee] 查询条件对象
*/
*/
@Slf4j
@Slf4j
@Data
@Data
public
class
IBZEmployeeSearchContext
extends
QueryWrapperContext
<
IBZEmployee
>
{
public
class
IBZEmployeeSearchContext
extends
SearchContextBase
{
private
String
n_personname_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
.
getSearchCond
().
like
(
"personname"
,
n_personname_like
);
}
}
private
String
n_usercode_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
.
getSearchCond
().
like
(
"usercode"
,
n_usercode_like
);
}
}
private
String
n_mdeptid_eq
;
//[主部门]
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
.
getSearchCond
().
eq
(
"mdeptid"
,
n_mdeptid_eq
);
}
}
private
String
n_mdeptname_like
;
//[主部门名称]
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
.
getSearchCond
().
like
(
"mdeptname"
,
n_mdeptname_like
);
}
}
private
String
n_bcode_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
.
getSearchCond
().
like
(
"bcode"
,
n_bcode_like
);
}
}
private
String
n_postid_eq
;
//[岗位标识]
private
String
n_postid_eq
;
//[岗位标识]
public
void
setN_postid_eq
(
String
n_postid_eq
)
{
this
.
n_postid_eq
=
n_postid_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_postid_eq
)){
this
.
getSearchCond
().
eq
(
"postid"
,
n_postid_eq
);
}
}
private
String
n_postname_eq
;
//[岗位名称]
private
String
n_postname_eq
;
//[岗位名称]
public
void
setN_postname_eq
(
String
n_postname_eq
)
{
this
.
n_postname_eq
=
n_postname_eq
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_postname_eq
)){
this
.
getSearchCond
().
eq
(
"postname"
,
n_postname_eq
);
}
}
private
String
n_postname_like
;
//[岗位名称]
private
String
n_postname_like
;
//[岗位名称]
public
void
setN_postname_like
(
String
n_postname_like
)
{
this
.
n_postname_like
=
n_postname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_postname_like
)){
this
.
getSearchCond
().
like
(
"postname"
,
n_postname_like
);
}
}
private
String
n_orgid_eq
;
//[单位]
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
.
getSearchCond
().
eq
(
"orgid"
,
n_orgid_eq
);
}
}
private
String
n_orgcode_leftlike
;
//[单位代码]
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
.
getSearchCond
().
likeRight
(
"orgcode"
,
n_orgcode_leftlike
);
}
}
private
String
n_sex_eq
;
//[性别]
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
.
getSearchCond
().
eq
(
"sex"
,
n_sex_eq
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSearchCond
().
and
(
wrapper
->
wrapper
.
like
(
"personname"
,
query
)
);
}
}
}
}
ibzrt-core/src/main/java/cn/ibizlab/core/ou/service/IIBZEmployeeService.java
浏览文件 @
a223d1f5
...
@@ -18,12 +18,10 @@ import cn.ibizlab.core.ou.domain.IBZEmployee;
...
@@ -18,12 +18,10 @@ import cn.ibizlab.core.ou.domain.IBZEmployee;
import
cn.ibizlab.core.ou.filter.IBZEmployeeSearchContext
;
import
cn.ibizlab.core.ou.filter.IBZEmployeeSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
/**
* 实体[IBZEmployee] 服务对象接口
* 实体[IBZEmployee] 服务对象接口
*/
*/
public
interface
IIBZEmployeeService
extends
IService
<
IBZEmployee
>
{
public
interface
IIBZEmployeeService
{
boolean
create
(
IBZEmployee
et
)
;
boolean
create
(
IBZEmployee
et
)
;
@CacheEvict
(
value
=
"ibzemployee"
,
allEntries
=
true
)
@CacheEvict
(
value
=
"ibzemployee"
,
allEntries
=
true
)
...
@@ -51,23 +49,8 @@ public interface IIBZEmployeeService extends IService<IBZEmployee>{
...
@@ -51,23 +49,8 @@ public interface IIBZEmployeeService extends IService<IBZEmployee>{
List
<
IBZEmployee
>
selectByPostid
(
String
postid
)
;
List
<
IBZEmployee
>
selectByPostid
(
String
postid
)
;
@CacheEvict
(
value
=
"ibzemployee"
,
allEntries
=
true
)
@CacheEvict
(
value
=
"ibzemployee"
,
allEntries
=
true
)
void
removeByPostid
(
String
postid
)
;
void
removeByPostid
(
String
postid
)
;
/**
*自定义查询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/impl/IBZDepartmentServiceImpl.java
浏览文件 @
a223d1f5
...
@@ -43,9 +43,6 @@ public class IBZDepartmentServiceImpl implements IIBZDepartmentService {
...
@@ -43,9 +43,6 @@ public class IBZDepartmentServiceImpl implements IIBZDepartmentService {
@Autowired
@Autowired
IBZDepartmentFeignClient
iBZDepartmentFeignClient
;
IBZDepartmentFeignClient
iBZDepartmentFeignClient
;
@Autowired
@Lazy
protected
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZEmployeeService
ibzemployeeService
;
@Override
@Override
public
boolean
create
(
IBZDepartment
et
)
{
public
boolean
create
(
IBZDepartment
et
)
{
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/ou/service/impl/IBZEmployeeServiceImpl.java
浏览文件 @
a223d1f5
...
@@ -31,110 +31,79 @@ import cn.ibizlab.util.helper.CachedBeanCopier;
...
@@ -31,110 +31,79 @@ import cn.ibizlab.util.helper.CachedBeanCopier;
import
cn.ibizlab.util.helper.DEFieldCacheMap
;
import
cn.ibizlab.util.helper.DEFieldCacheMap
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.core.ou.client.IBZEmployeeFeignClient
;
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
;
/**
/**
* 实体[人员] 服务对象接口实现
* 实体[人员] 服务对象接口实现
*/
*/
@Slf4j
@Slf4j
@Service
(
"IBZEmployeeServiceImpl"
)
@Service
public
class
IBZEmployeeServiceImpl
extends
ServiceImpl
<
IBZEmployeeMapper
,
IBZEmployee
>
implements
IIBZEmployeeService
{
public
class
IBZEmployeeServiceImpl
implements
IIBZEmployeeService
{
@Autowired
@Autowired
@Lazy
IBZEmployeeFeignClient
iBZEmployeeFeignClient
;
protected
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZDeptMemberService
ibzdeptmemberService
;
@Autowired
@Lazy
protected
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZTeamMemberService
ibzteammemberService
;
@Autowired
@Lazy
protected
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZDepartmentService
ibzdepartmentService
;
@Autowired
@Lazy
protected
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZOrganizationService
ibzorganizationService
;
@Autowired
@Lazy
protected
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZPostService
ibzpostService
;
@Autowired
@Lazy
protected
cn
.
ibizlab
.
core
.
ou
.
service
.
logic
.
IIBZEmployeesaveDeptMemberLogic
savedeptmemberLogic
;
protected
int
batchSize
=
500
;
@Override
@Override
@Transactional
public
boolean
create
(
IBZEmployee
et
)
{
public
boolean
create
(
IBZEmployee
et
)
{
fillParentData
(
et
);
IBZEmployee
rt
=
iBZEmployeeFeignClient
.
create
(
et
);
if
(
!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
))
)
if
(
rt
==
null
)
return
false
;
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getUserid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
savedeptmemberLogic
.
execute
(
et
);
savedeptmemberLogic
.
execute
(
et
);
return
true
;
return
true
;
}
}
@Override
public
void
createBatch
(
List
<
IBZEmployee
>
list
){
public
void
createBatch
(
List
<
IBZEmployee
>
list
)
{
iBZEmployeeFeignClient
.
createBatch
(
list
)
;
list
.
forEach
(
item
->
fillParentData
(
item
));
this
.
saveBatch
(
list
,
batchSize
);
}
}
@Override
@Override
@Transactional
public
boolean
update
(
IBZEmployee
et
)
{
public
boolean
update
(
IBZEmployee
et
)
{
fillParentData
(
et
);
IBZEmployee
rt
=
iBZEmployeeFeignClient
.
update
(
et
.
getUserid
(),
et
);
if
(
!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"userid"
,
et
.
getUserid
()))
)
if
(
rt
==
null
)
return
false
;
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getUserid
())
,
et
);
CachedBeanCopier
.
copy
(
rt
,
et
);
savedeptmemberLogic
.
execute
(
et
);
savedeptmemberLogic
.
execute
(
et
);
return
true
;
return
true
;
}
}
@Override
public
void
updateBatch
(
List
<
IBZEmployee
>
list
){
public
void
updateBatch
(
List
<
IBZEmployee
>
list
)
{
iBZEmployeeFeignClient
.
updateBatch
(
list
)
;
list
.
forEach
(
item
->
fillParentData
(
item
));
updateBatchById
(
list
,
batchSize
);
}
}
@Override
@Override
@Transactional
public
boolean
remove
(
String
userid
)
{
public
boolean
remove
(
String
key
)
{
boolean
result
=
iBZEmployeeFeignClient
.
remove
(
userid
)
;
boolean
result
=
removeById
(
key
);
return
result
;
return
result
;
}
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
){
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
iBZEmployeeFeignClient
.
removeBatch
(
idList
);
removeByIds
(
idList
);
}
}
@Override
@Override
@Transactional
public
IBZEmployee
get
(
String
userid
)
{
public
IBZEmployee
get
(
String
key
)
{
IBZEmployee
et
=
iBZEmployeeFeignClient
.
get
(
userid
);
IBZEmployee
et
=
getById
(
key
);
if
(
et
==
null
){
if
(
et
==
null
){
et
=
new
IBZEmployee
();
et
=
new
IBZEmployee
();
et
.
setUserid
(
key
);
et
.
setUserid
(
userid
);
}
}
else
{
else
{
}
}
return
et
;
return
et
;
}
}
@Override
@Override
public
IBZEmployee
getDraft
(
IBZEmployee
et
)
{
public
IBZEmployee
getDraft
(
IBZEmployee
et
)
{
fillParentData
(
et
);
et
=
iBZEmployeeFeignClient
.
getDraft
(
);
return
et
;
return
et
;
}
}
@Override
@Override
public
boolean
checkKey
(
IBZEmployee
et
)
{
public
boolean
checkKey
(
IBZEmployee
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getUserid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getUserid
()))
);
return
iBZEmployeeFeignClient
.
checkKey
(
et
);
}
}
@Override
@Override
@Transactional
@Transactional
...
@@ -146,164 +115,86 @@ public class IBZEmployeeServiceImpl extends ServiceImpl<IBZEmployeeMapper, IBZEm
...
@@ -146,164 +115,86 @@ public class IBZEmployeeServiceImpl extends ServiceImpl<IBZEmployeeMapper, IBZEm
@Override
@Override
@Transactional
@Transactional
public
boolean
save
(
IBZEmployee
et
)
{
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
false
;
return
true
;
return
true
;
}
}
@Override
@Transactional
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
@Override
public
void
saveBatch
(
List
<
IBZEmployee
>
list
)
{
public
void
saveBatch
(
List
<
IBZEmployee
>
list
)
{
list
.
forEach
(
item
->
fillParentData
(
item
));
iBZEmployeeFeignClient
.
saveBatch
(
list
)
;
saveOrUpdateBatch
(
list
,
batchSize
);
}
}
@Override
@Override
public
List
<
IBZEmployee
>
selectByMdeptid
(
String
deptid
)
{
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
@Override
public
void
removeByMdeptid
(
String
deptid
)
{
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
@Override
public
List
<
IBZEmployee
>
selectByOrgid
(
String
orgid
)
{
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
@Override
public
void
removeByOrgid
(
String
orgid
)
{
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
);
}
}
@Override
@Override
public
List
<
IBZEmployee
>
selectByPostid
(
String
postid
)
{
public
List
<
IBZEmployee
>
selectByPostid
(
String
postid
)
{
return
baseMapper
.
selectByPostid
(
postid
);
IBZEmployeeSearchContext
context
=
new
IBZEmployeeSearchContext
();
context
.
setSize
(
Integer
.
MAX_VALUE
);
context
.
setN_postid_eq
(
postid
);
return
iBZEmployeeFeignClient
.
searchDefault
(
context
).
getContent
();
}
}
@Override
@Override
public
void
removeByPostid
(
String
postid
)
{
public
void
removeByPostid
(
String
postid
)
{
this
.
remove
(
new
QueryWrapper
<
IBZEmployee
>().
eq
(
"postid"
,
postid
));
Set
<
String
>
delIds
=
new
HashSet
<
String
>();
for
(
IBZEmployee
before:
selectByPostid
(
postid
)){
delIds
.
add
(
before
.
getUserid
());
}
if
(
delIds
.
size
()>
0
)
this
.
removeBatch
(
delIds
);
}
}
/**
/**
* 查询集合 DEFAULT
* 查询集合 DEFAULT
*/
*/
@Override
@Override
public
Page
<
IBZEmployee
>
searchDefault
(
IBZEmployeeSearchContext
context
)
{
public
Page
<
IBZEmployee
>
searchDefault
(
IBZEmployeeSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
IBZEmployee
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
()
);
Page
<
IBZEmployee
>
iBZEmployees
=
iBZEmployeeFeignClient
.
searchDefault
(
context
);
return
new
PageImpl
<
IBZEmployee
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
())
;
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
());
}
//实体关系[DER1N_IBZEMP_IBZPOST_POSTID]
if
(!
ObjectUtils
.
isEmpty
(
et
.
getPostid
())){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZPost
post
=
et
.
getPost
();
if
(
ObjectUtils
.
isEmpty
(
post
)){
cn
.
ibizlab
.
core
.
ou
.
domain
.
IBZPost
majorEntity
=
ibzpostService
.
get
(
et
.
getPostid
());
et
.
setPost
(
majorEntity
);
post
=
majorEntity
;
}
et
.
setPostcode
(
post
.
getPostcode
());
et
.
setPostname
(
post
.
getPostname
());
}
}
@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
浏览文件 @
a223d1f5
...
@@ -43,9 +43,6 @@ public class IBZOrganizationServiceImpl implements IIBZOrganizationService {
...
@@ -43,9 +43,6 @@ public class IBZOrganizationServiceImpl implements IIBZOrganizationService {
@Autowired
@Autowired
IBZOrganizationFeignClient
iBZOrganizationFeignClient
;
IBZOrganizationFeignClient
iBZOrganizationFeignClient
;
@Autowired
@Lazy
protected
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZEmployeeService
ibzemployeeService
;
@Override
@Override
public
boolean
create
(
IBZOrganization
et
)
{
public
boolean
create
(
IBZOrganization
et
)
{
...
...
ibzrt-core/src/main/java/cn/ibizlab/core/ou/service/impl/IBZPostServiceImpl.java
浏览文件 @
a223d1f5
...
@@ -43,9 +43,6 @@ public class IBZPostServiceImpl implements IIBZPostService {
...
@@ -43,9 +43,6 @@ public class IBZPostServiceImpl implements IIBZPostService {
@Autowired
@Autowired
IBZPostFeignClient
iBZPostFeignClient
;
IBZPostFeignClient
iBZPostFeignClient
;
@Autowired
@Lazy
protected
cn
.
ibizlab
.
core
.
ou
.
service
.
IIBZEmployeeService
ibzemployeeService
;
@Override
@Override
public
boolean
create
(
IBZPost
et
)
{
public
boolean
create
(
IBZPost
et
)
{
...
...
ibzrt-core/src/main/resources/liquibase/h2_table.xml
浏览文件 @
a223d1f5
...
@@ -11,84 +11,6 @@
...
@@ -11,84 +11,6 @@
<!--输出实体[IBZEMP]数据结构 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"tab-ibzemp-2-1"
>
<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>
...
@@ -144,15 +66,5 @@
...
@@ -144,15 +66,5 @@
<!--输出实体[IBZEMP]外键关系 -->
<changeSet
author=
"a_A_5d9d78509"
id=
"fk-ibzemp-2-2"
>
<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-2-3"
>
<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>
<changeSet
author=
"a_A_5d9d78509"
id=
"fk-ibzemp-2-4"
>
<addForeignKeyConstraint
baseColumnNames=
"POSTID"
baseTableName=
"IBZEMP"
constraintName=
"DER1N_IBZEMP_IBZPOST_POSTID"
deferrable=
"false"
initiallyDeferred=
"false"
onDelete=
"RESTRICT"
onUpdate=
"RESTRICT"
referencedColumnNames=
"POSTID"
referencedTableName=
"IBZPOST"
validate=
"true"
/>
</changeSet>
</databaseChangeLog>
</databaseChangeLog>
ibzrt-provider/ibzrt-provider-api/src/main/java/cn/ibizlab/api/rest/IBZEmployeeResource.java
浏览文件 @
a223d1f5
...
@@ -11,7 +11,7 @@ import com.alibaba.fastjson.JSONObject;
...
@@ -11,7 +11,7 @@ import com.alibaba.fastjson.JSONObject;
import
javax.servlet.ServletRequest
;
import
javax.servlet.ServletRequest
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cglib.beans.BeanCopier
;
import
org.springframework.cglib.beans.BeanCopier
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.http.ResponseEntity
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.http.HttpStatus
;
import
org.springframework.http.HttpStatus
;
...
@@ -47,10 +47,9 @@ public class IBZEmployeeResource {
...
@@ -47,10 +47,9 @@ public class IBZEmployeeResource {
@Lazy
@Lazy
public
IBZEmployeeMapping
ibzemployeeMapping
;
public
IBZEmployeeMapping
ibzemployeeMapping
;
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedto),'ibzrt-IBZEmployee-Create')"
)
@ApiOperation
(
value
=
"新建人员"
,
tags
=
{
"人员"
},
notes
=
"新建人员"
)
@ApiOperation
(
value
=
"新建人员"
,
tags
=
{
"人员"
},
notes
=
"新建人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees"
)
@Transactional
public
ResponseEntity
<
IBZEmployeeDTO
>
create
(
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
create
(
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
ibzemployeeService
.
create
(
domain
);
ibzemployeeService
.
create
(
domain
);
...
@@ -58,7 +57,6 @@ public class IBZEmployeeResource {
...
@@ -58,7 +57,6 @@ public class IBZEmployeeResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedtos),'ibzrt-IBZEmployee-Create')"
)
@ApiOperation
(
value
=
"批量新建人员"
,
tags
=
{
"人员"
},
notes
=
"批量新建人员"
)
@ApiOperation
(
value
=
"批量新建人员"
,
tags
=
{
"人员"
},
notes
=
"批量新建人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/batch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/batch"
)
public
ResponseEntity
<
Boolean
>
createBatch
(
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
public
ResponseEntity
<
Boolean
>
createBatch
(
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
...
@@ -67,10 +65,9 @@ public class IBZEmployeeResource {
...
@@ -67,10 +65,9 @@ public class IBZEmployeeResource {
}
}
@VersionCheck
(
entity
=
"ibzemployee"
,
versionfield
=
"updatedate"
)
@VersionCheck
(
entity
=
"ibzemployee"
,
versionfield
=
"updatedate"
)
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.get(#ibzemployee_id),'ibzrt-IBZEmployee-Update')"
)
@ApiOperation
(
value
=
"更新人员"
,
tags
=
{
"人员"
},
notes
=
"更新人员"
)
@ApiOperation
(
value
=
"更新人员"
,
tags
=
{
"人员"
},
notes
=
"更新人员"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzemployees/{ibzemployee_id}"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzemployees/{ibzemployee_id}"
)
@Transactional
public
ResponseEntity
<
IBZEmployeeDTO
>
update
(
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
update
(
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
domain
.
setUserid
(
ibzemployee_id
);
domain
.
setUserid
(
ibzemployee_id
);
...
@@ -79,7 +76,6 @@ public class IBZEmployeeResource {
...
@@ -79,7 +76,6 @@ public class IBZEmployeeResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.getIbzemployeeByEntities(this.ibzemployeeMapping.toDomain(#ibzemployeedtos)),'ibzrt-IBZEmployee-Update')"
)
@ApiOperation
(
value
=
"批量更新人员"
,
tags
=
{
"人员"
},
notes
=
"批量更新人员"
)
@ApiOperation
(
value
=
"批量更新人员"
,
tags
=
{
"人员"
},
notes
=
"批量更新人员"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzemployees/batch"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzemployees/batch"
)
public
ResponseEntity
<
Boolean
>
updateBatch
(
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
public
ResponseEntity
<
Boolean
>
updateBatch
(
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
...
@@ -87,15 +83,13 @@ public class IBZEmployeeResource {
...
@@ -87,15 +83,13 @@ public class IBZEmployeeResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.get(#ibzemployee_id),'ibzrt-IBZEmployee-Remove')"
)
@ApiOperation
(
value
=
"删除人员"
,
tags
=
{
"人员"
},
notes
=
"删除人员"
)
@ApiOperation
(
value
=
"删除人员"
,
tags
=
{
"人员"
},
notes
=
"删除人员"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzemployees/{ibzemployee_id}"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzemployees/{ibzemployee_id}"
)
@Transactional
public
ResponseEntity
<
Boolean
>
remove
(
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
public
ResponseEntity
<
Boolean
>
remove
(
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
remove
(
ibzemployee_id
));
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
remove
(
ibzemployee_id
));
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.getIbzemployeeByIds(#ids),'ibzrt-IBZEmployee-Remove')"
)
@ApiOperation
(
value
=
"批量删除人员"
,
tags
=
{
"人员"
},
notes
=
"批量删除人员"
)
@ApiOperation
(
value
=
"批量删除人员"
,
tags
=
{
"人员"
},
notes
=
"批量删除人员"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzemployees/batch"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzemployees/batch"
)
public
ResponseEntity
<
Boolean
>
removeBatch
(
@RequestBody
List
<
String
>
ids
)
{
public
ResponseEntity
<
Boolean
>
removeBatch
(
@RequestBody
List
<
String
>
ids
)
{
...
@@ -103,7 +97,6 @@ public class IBZEmployeeResource {
...
@@ -103,7 +97,6 @@ public class IBZEmployeeResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
}
@PostAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(returnObject.body),'ibzrt-IBZEmployee-Get')"
)
@ApiOperation
(
value
=
"获取人员"
,
tags
=
{
"人员"
},
notes
=
"获取人员"
)
@ApiOperation
(
value
=
"获取人员"
,
tags
=
{
"人员"
},
notes
=
"获取人员"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzemployees/{ibzemployee_id}"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzemployees/{ibzemployee_id}"
)
public
ResponseEntity
<
IBZEmployeeDTO
>
get
(
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
get
(
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
...
@@ -124,10 +117,9 @@ public class IBZEmployeeResource {
...
@@ -124,10 +117,9 @@ public class IBZEmployeeResource {
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
checkKey
(
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
)));
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
checkKey
(
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
)));
}
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZEmployee-InitPwd-all')"
)
@ApiOperation
(
value
=
"初始化密码"
,
tags
=
{
"人员"
},
notes
=
"初始化密码"
)
@ApiOperation
(
value
=
"初始化密码"
,
tags
=
{
"人员"
},
notes
=
"初始化密码"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/{ibzemployee_id}/initpwd"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/{ibzemployee_id}/initpwd"
)
@Transactional
public
ResponseEntity
<
IBZEmployeeDTO
>
initPwd
(
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
initPwd
(
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
domain
.
setUserid
(
ibzemployee_id
);
domain
.
setUserid
(
ibzemployee_id
);
...
@@ -136,14 +128,12 @@ domain.setUserid(ibzemployee_id);
...
@@ -136,14 +128,12 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeedto
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeedto
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedto),'ibzrt-IBZEmployee-Save')"
)
@ApiOperation
(
value
=
"保存人员"
,
tags
=
{
"人员"
},
notes
=
"保存人员"
)
@ApiOperation
(
value
=
"保存人员"
,
tags
=
{
"人员"
},
notes
=
"保存人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/save"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/save"
)
public
ResponseEntity
<
Boolean
>
save
(
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
Boolean
>
save
(
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
save
(
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
)));
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
save
(
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
)));
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedtos),'ibzrt-IBZEmployee-Save')"
)
@ApiOperation
(
value
=
"批量保存人员"
,
tags
=
{
"人员"
},
notes
=
"批量保存人员"
)
@ApiOperation
(
value
=
"批量保存人员"
,
tags
=
{
"人员"
},
notes
=
"批量保存人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/savebatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/savebatch"
)
public
ResponseEntity
<
Boolean
>
saveBatch
(
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
public
ResponseEntity
<
Boolean
>
saveBatch
(
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
...
@@ -151,7 +141,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -151,7 +141,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZEmployee-searchDefault-all') and hasPermission(#context,'ibzrt-IBZEmployee-Get')"
)
@ApiOperation
(
value
=
"获取DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"获取DEFAULT"
)
@ApiOperation
(
value
=
"获取DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"获取DEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzemployees/fetchdefault"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzemployees/fetchdefault"
)
public
ResponseEntity
<
List
<
IBZEmployeeDTO
>>
fetchDefault
(
IBZEmployeeSearchContext
context
)
{
public
ResponseEntity
<
List
<
IBZEmployeeDTO
>>
fetchDefault
(
IBZEmployeeSearchContext
context
)
{
...
@@ -164,7 +153,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -164,7 +153,6 @@ domain.setUserid(ibzemployee_id);
.
body
(
list
);
.
body
(
list
);
}
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZEmployee-searchDefault-all') and hasPermission(#context,'ibzrt-IBZEmployee-Get')"
)
@ApiOperation
(
value
=
"查询DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"查询DEFAULT"
)
@ApiOperation
(
value
=
"查询DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"查询DEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/searchdefault"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzemployees/searchdefault"
)
public
ResponseEntity
<
Page
<
IBZEmployeeDTO
>>
searchDefault
(
@RequestBody
IBZEmployeeSearchContext
context
)
{
public
ResponseEntity
<
Page
<
IBZEmployeeDTO
>>
searchDefault
(
@RequestBody
IBZEmployeeSearchContext
context
)
{
...
@@ -172,10 +160,9 @@ domain.setUserid(ibzemployee_id);
...
@@ -172,10 +160,9 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
)
return
ResponseEntity
.
status
(
HttpStatus
.
OK
)
.
body
(
new
PageImpl
(
ibzemployeeMapping
.
toDto
(
domains
.
getContent
()),
context
.
getPageable
(),
domains
.
getTotalElements
()));
.
body
(
new
PageImpl
(
ibzemployeeMapping
.
toDto
(
domains
.
getContent
()),
context
.
getPageable
(),
domains
.
getTotalElements
()));
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedto),'ibzrt-IBZEmployee-Create')"
)
@ApiOperation
(
value
=
"根据部门建立人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门建立人员"
)
@ApiOperation
(
value
=
"根据部门建立人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门建立人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees"
)
@Transactional
public
ResponseEntity
<
IBZEmployeeDTO
>
createByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
createByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
domain
.
setMdeptid
(
ibzdepartment_id
);
domain
.
setMdeptid
(
ibzdepartment_id
);
...
@@ -184,7 +171,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -184,7 +171,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedtos),'ibzrt-IBZEmployee-Create')"
)
@ApiOperation
(
value
=
"根据部门批量建立人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门批量建立人员"
)
@ApiOperation
(
value
=
"根据部门批量建立人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门批量建立人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/batch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/batch"
)
public
ResponseEntity
<
Boolean
>
createBatchByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
public
ResponseEntity
<
Boolean
>
createBatchByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
...
@@ -197,10 +183,9 @@ domain.setUserid(ibzemployee_id);
...
@@ -197,10 +183,9 @@ domain.setUserid(ibzemployee_id);
}
}
@VersionCheck
(
entity
=
"ibzemployee"
,
versionfield
=
"updatedate"
)
@VersionCheck
(
entity
=
"ibzemployee"
,
versionfield
=
"updatedate"
)
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.get(#ibzemployee_id),'ibzrt-IBZEmployee-Update')"
)
@ApiOperation
(
value
=
"根据部门更新人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门更新人员"
)
@ApiOperation
(
value
=
"根据部门更新人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门更新人员"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}"
)
@Transactional
public
ResponseEntity
<
IBZEmployeeDTO
>
updateByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
updateByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
domain
.
setMdeptid
(
ibzdepartment_id
);
domain
.
setMdeptid
(
ibzdepartment_id
);
...
@@ -210,7 +195,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -210,7 +195,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.getIbzemployeeByEntities(this.ibzemployeeMapping.toDomain(#ibzemployeedtos)),'ibzrt-IBZEmployee-Update')"
)
@ApiOperation
(
value
=
"根据部门批量更新人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门批量更新人员"
)
@ApiOperation
(
value
=
"根据部门批量更新人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门批量更新人员"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/batch"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/batch"
)
public
ResponseEntity
<
Boolean
>
updateBatchByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
public
ResponseEntity
<
Boolean
>
updateBatchByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
...
@@ -222,15 +206,13 @@ domain.setUserid(ibzemployee_id);
...
@@ -222,15 +206,13 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.get(#ibzemployee_id),'ibzrt-IBZEmployee-Remove')"
)
@ApiOperation
(
value
=
"根据部门删除人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门删除人员"
)
@ApiOperation
(
value
=
"根据部门删除人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门删除人员"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}"
)
@Transactional
public
ResponseEntity
<
Boolean
>
removeByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
public
ResponseEntity
<
Boolean
>
removeByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
remove
(
ibzemployee_id
));
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
remove
(
ibzemployee_id
));
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.getIbzemployeeByIds(#ids),'ibzrt-IBZEmployee-Remove')"
)
@ApiOperation
(
value
=
"根据部门批量删除人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门批量删除人员"
)
@ApiOperation
(
value
=
"根据部门批量删除人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门批量删除人员"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/batch"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/batch"
)
public
ResponseEntity
<
Boolean
>
removeBatchByIBZDepartment
(
@RequestBody
List
<
String
>
ids
)
{
public
ResponseEntity
<
Boolean
>
removeBatchByIBZDepartment
(
@RequestBody
List
<
String
>
ids
)
{
...
@@ -238,7 +220,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -238,7 +220,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
}
@PostAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(returnObject.body),'ibzrt-IBZEmployee-Get')"
)
@ApiOperation
(
value
=
"根据部门获取人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门获取人员"
)
@ApiOperation
(
value
=
"根据部门获取人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门获取人员"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}"
)
public
ResponseEntity
<
IBZEmployeeDTO
>
getByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
getByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
...
@@ -261,10 +242,9 @@ domain.setUserid(ibzemployee_id);
...
@@ -261,10 +242,9 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
checkKey
(
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
)));
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
checkKey
(
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
)));
}
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZEmployee-InitPwd-all')"
)
@ApiOperation
(
value
=
"根据部门人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门人员"
)
@ApiOperation
(
value
=
"根据部门人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}/initpwd"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}/initpwd"
)
@Transactional
public
ResponseEntity
<
IBZEmployeeDTO
>
initPwdByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
initPwdByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
domain
.
setMdeptid
(
ibzdepartment_id
);
domain
.
setMdeptid
(
ibzdepartment_id
);
...
@@ -273,7 +253,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -273,7 +253,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeedto
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeedto
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedto),'ibzrt-IBZEmployee-Save')"
)
@ApiOperation
(
value
=
"根据部门保存人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门保存人员"
)
@ApiOperation
(
value
=
"根据部门保存人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门保存人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/save"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/save"
)
public
ResponseEntity
<
Boolean
>
saveByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
Boolean
>
saveByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
...
@@ -282,7 +261,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -282,7 +261,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
save
(
domain
));
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
save
(
domain
));
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedtos),'ibzrt-IBZEmployee-Save')"
)
@ApiOperation
(
value
=
"根据部门批量保存人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门批量保存人员"
)
@ApiOperation
(
value
=
"根据部门批量保存人员"
,
tags
=
{
"人员"
},
notes
=
"根据部门批量保存人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/savebatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/savebatch"
)
public
ResponseEntity
<
Boolean
>
saveBatchByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
public
ResponseEntity
<
Boolean
>
saveBatchByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
...
@@ -294,7 +272,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -294,7 +272,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZEmployee-searchDefault-all') and hasPermission(#context,'ibzrt-IBZEmployee-Get')"
)
@ApiOperation
(
value
=
"根据部门获取DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"根据部门获取DEFAULT"
)
@ApiOperation
(
value
=
"根据部门获取DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"根据部门获取DEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/fetchdefault"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/fetchdefault"
)
public
ResponseEntity
<
List
<
IBZEmployeeDTO
>>
fetchIBZEmployeeDefaultByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
IBZEmployeeSearchContext
context
)
{
public
ResponseEntity
<
List
<
IBZEmployeeDTO
>>
fetchIBZEmployeeDefaultByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
IBZEmployeeSearchContext
context
)
{
...
@@ -308,7 +285,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -308,7 +285,6 @@ domain.setUserid(ibzemployee_id);
.
body
(
list
);
.
body
(
list
);
}
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZEmployee-searchDefault-all') and hasPermission(#context,'ibzrt-IBZEmployee-Get')"
)
@ApiOperation
(
value
=
"根据部门查询DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"根据部门查询DEFAULT"
)
@ApiOperation
(
value
=
"根据部门查询DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"根据部门查询DEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/searchdefault"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzdepartments/{ibzdepartment_id}/ibzemployees/searchdefault"
)
public
ResponseEntity
<
Page
<
IBZEmployeeDTO
>>
searchIBZEmployeeDefaultByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
IBZEmployeeSearchContext
context
)
{
public
ResponseEntity
<
Page
<
IBZEmployeeDTO
>>
searchIBZEmployeeDefaultByIBZDepartment
(
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
IBZEmployeeSearchContext
context
)
{
...
@@ -317,10 +293,9 @@ domain.setUserid(ibzemployee_id);
...
@@ -317,10 +293,9 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
)
return
ResponseEntity
.
status
(
HttpStatus
.
OK
)
.
body
(
new
PageImpl
(
ibzemployeeMapping
.
toDto
(
domains
.
getContent
()),
context
.
getPageable
(),
domains
.
getTotalElements
()));
.
body
(
new
PageImpl
(
ibzemployeeMapping
.
toDto
(
domains
.
getContent
()),
context
.
getPageable
(),
domains
.
getTotalElements
()));
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedto),'ibzrt-IBZEmployee-Create')"
)
@ApiOperation
(
value
=
"根据单位机构建立人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构建立人员"
)
@ApiOperation
(
value
=
"根据单位机构建立人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构建立人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees"
)
@Transactional
public
ResponseEntity
<
IBZEmployeeDTO
>
createByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
createByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
domain
.
setOrgid
(
ibzorganization_id
);
domain
.
setOrgid
(
ibzorganization_id
);
...
@@ -329,7 +304,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -329,7 +304,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedtos),'ibzrt-IBZEmployee-Create')"
)
@ApiOperation
(
value
=
"根据单位机构批量建立人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构批量建立人员"
)
@ApiOperation
(
value
=
"根据单位机构批量建立人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构批量建立人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/batch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/batch"
)
public
ResponseEntity
<
Boolean
>
createBatchByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
public
ResponseEntity
<
Boolean
>
createBatchByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
...
@@ -342,10 +316,9 @@ domain.setUserid(ibzemployee_id);
...
@@ -342,10 +316,9 @@ domain.setUserid(ibzemployee_id);
}
}
@VersionCheck
(
entity
=
"ibzemployee"
,
versionfield
=
"updatedate"
)
@VersionCheck
(
entity
=
"ibzemployee"
,
versionfield
=
"updatedate"
)
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.get(#ibzemployee_id),'ibzrt-IBZEmployee-Update')"
)
@ApiOperation
(
value
=
"根据单位机构更新人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构更新人员"
)
@ApiOperation
(
value
=
"根据单位机构更新人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构更新人员"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/{ibzemployee_id}"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/{ibzemployee_id}"
)
@Transactional
public
ResponseEntity
<
IBZEmployeeDTO
>
updateByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
updateByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
domain
.
setOrgid
(
ibzorganization_id
);
domain
.
setOrgid
(
ibzorganization_id
);
...
@@ -355,7 +328,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -355,7 +328,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.getIbzemployeeByEntities(this.ibzemployeeMapping.toDomain(#ibzemployeedtos)),'ibzrt-IBZEmployee-Update')"
)
@ApiOperation
(
value
=
"根据单位机构批量更新人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构批量更新人员"
)
@ApiOperation
(
value
=
"根据单位机构批量更新人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构批量更新人员"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/batch"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/batch"
)
public
ResponseEntity
<
Boolean
>
updateBatchByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
public
ResponseEntity
<
Boolean
>
updateBatchByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
...
@@ -367,15 +339,13 @@ domain.setUserid(ibzemployee_id);
...
@@ -367,15 +339,13 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.get(#ibzemployee_id),'ibzrt-IBZEmployee-Remove')"
)
@ApiOperation
(
value
=
"根据单位机构删除人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构删除人员"
)
@ApiOperation
(
value
=
"根据单位机构删除人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构删除人员"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/{ibzemployee_id}"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/{ibzemployee_id}"
)
@Transactional
public
ResponseEntity
<
Boolean
>
removeByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
public
ResponseEntity
<
Boolean
>
removeByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
remove
(
ibzemployee_id
));
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
remove
(
ibzemployee_id
));
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.getIbzemployeeByIds(#ids),'ibzrt-IBZEmployee-Remove')"
)
@ApiOperation
(
value
=
"根据单位机构批量删除人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构批量删除人员"
)
@ApiOperation
(
value
=
"根据单位机构批量删除人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构批量删除人员"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/batch"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/batch"
)
public
ResponseEntity
<
Boolean
>
removeBatchByIBZOrganization
(
@RequestBody
List
<
String
>
ids
)
{
public
ResponseEntity
<
Boolean
>
removeBatchByIBZOrganization
(
@RequestBody
List
<
String
>
ids
)
{
...
@@ -383,7 +353,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -383,7 +353,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
}
@PostAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(returnObject.body),'ibzrt-IBZEmployee-Get')"
)
@ApiOperation
(
value
=
"根据单位机构获取人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构获取人员"
)
@ApiOperation
(
value
=
"根据单位机构获取人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构获取人员"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/{ibzemployee_id}"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/{ibzemployee_id}"
)
public
ResponseEntity
<
IBZEmployeeDTO
>
getByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
getByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
...
@@ -406,10 +375,9 @@ domain.setUserid(ibzemployee_id);
...
@@ -406,10 +375,9 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
checkKey
(
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
)));
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
checkKey
(
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
)));
}
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZEmployee-InitPwd-all')"
)
@ApiOperation
(
value
=
"根据单位机构人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构人员"
)
@ApiOperation
(
value
=
"根据单位机构人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/{ibzemployee_id}/initpwd"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/{ibzemployee_id}/initpwd"
)
@Transactional
public
ResponseEntity
<
IBZEmployeeDTO
>
initPwdByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
initPwdByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
domain
.
setOrgid
(
ibzorganization_id
);
domain
.
setOrgid
(
ibzorganization_id
);
...
@@ -418,7 +386,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -418,7 +386,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeedto
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeedto
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedto),'ibzrt-IBZEmployee-Save')"
)
@ApiOperation
(
value
=
"根据单位机构保存人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构保存人员"
)
@ApiOperation
(
value
=
"根据单位机构保存人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构保存人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/save"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/save"
)
public
ResponseEntity
<
Boolean
>
saveByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
Boolean
>
saveByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
...
@@ -427,7 +394,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -427,7 +394,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
save
(
domain
));
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
save
(
domain
));
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedtos),'ibzrt-IBZEmployee-Save')"
)
@ApiOperation
(
value
=
"根据单位机构批量保存人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构批量保存人员"
)
@ApiOperation
(
value
=
"根据单位机构批量保存人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构批量保存人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/savebatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/savebatch"
)
public
ResponseEntity
<
Boolean
>
saveBatchByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
public
ResponseEntity
<
Boolean
>
saveBatchByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
...
@@ -439,7 +405,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -439,7 +405,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZEmployee-searchDefault-all') and hasPermission(#context,'ibzrt-IBZEmployee-Get')"
)
@ApiOperation
(
value
=
"根据单位机构获取DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"根据单位机构获取DEFAULT"
)
@ApiOperation
(
value
=
"根据单位机构获取DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"根据单位机构获取DEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/fetchdefault"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/fetchdefault"
)
public
ResponseEntity
<
List
<
IBZEmployeeDTO
>>
fetchIBZEmployeeDefaultByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
IBZEmployeeSearchContext
context
)
{
public
ResponseEntity
<
List
<
IBZEmployeeDTO
>>
fetchIBZEmployeeDefaultByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
IBZEmployeeSearchContext
context
)
{
...
@@ -453,7 +418,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -453,7 +418,6 @@ domain.setUserid(ibzemployee_id);
.
body
(
list
);
.
body
(
list
);
}
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZEmployee-searchDefault-all') and hasPermission(#context,'ibzrt-IBZEmployee-Get')"
)
@ApiOperation
(
value
=
"根据单位机构查询DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"根据单位机构查询DEFAULT"
)
@ApiOperation
(
value
=
"根据单位机构查询DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"根据单位机构查询DEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/searchdefault"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzemployees/searchdefault"
)
public
ResponseEntity
<
Page
<
IBZEmployeeDTO
>>
searchIBZEmployeeDefaultByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@RequestBody
IBZEmployeeSearchContext
context
)
{
public
ResponseEntity
<
Page
<
IBZEmployeeDTO
>>
searchIBZEmployeeDefaultByIBZOrganization
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@RequestBody
IBZEmployeeSearchContext
context
)
{
...
@@ -462,10 +426,9 @@ domain.setUserid(ibzemployee_id);
...
@@ -462,10 +426,9 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
)
return
ResponseEntity
.
status
(
HttpStatus
.
OK
)
.
body
(
new
PageImpl
(
ibzemployeeMapping
.
toDto
(
domains
.
getContent
()),
context
.
getPageable
(),
domains
.
getTotalElements
()));
.
body
(
new
PageImpl
(
ibzemployeeMapping
.
toDto
(
domains
.
getContent
()),
context
.
getPageable
(),
domains
.
getTotalElements
()));
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedto),'ibzrt-IBZEmployee-Create')"
)
@ApiOperation
(
value
=
"根据单位机构部门建立人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门建立人员"
)
@ApiOperation
(
value
=
"根据单位机构部门建立人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门建立人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees"
)
@Transactional
public
ResponseEntity
<
IBZEmployeeDTO
>
createByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
createByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
domain
.
setMdeptid
(
ibzdepartment_id
);
domain
.
setMdeptid
(
ibzdepartment_id
);
...
@@ -474,7 +437,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -474,7 +437,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedtos),'ibzrt-IBZEmployee-Create')"
)
@ApiOperation
(
value
=
"根据单位机构部门批量建立人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门批量建立人员"
)
@ApiOperation
(
value
=
"根据单位机构部门批量建立人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门批量建立人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/batch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/batch"
)
public
ResponseEntity
<
Boolean
>
createBatchByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
public
ResponseEntity
<
Boolean
>
createBatchByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
...
@@ -487,10 +449,9 @@ domain.setUserid(ibzemployee_id);
...
@@ -487,10 +449,9 @@ domain.setUserid(ibzemployee_id);
}
}
@VersionCheck
(
entity
=
"ibzemployee"
,
versionfield
=
"updatedate"
)
@VersionCheck
(
entity
=
"ibzemployee"
,
versionfield
=
"updatedate"
)
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.get(#ibzemployee_id),'ibzrt-IBZEmployee-Update')"
)
@ApiOperation
(
value
=
"根据单位机构部门更新人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门更新人员"
)
@ApiOperation
(
value
=
"根据单位机构部门更新人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门更新人员"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}"
)
@Transactional
public
ResponseEntity
<
IBZEmployeeDTO
>
updateByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
updateByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
domain
.
setMdeptid
(
ibzdepartment_id
);
domain
.
setMdeptid
(
ibzdepartment_id
);
...
@@ -500,7 +461,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -500,7 +461,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
dto
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.getIbzemployeeByEntities(this.ibzemployeeMapping.toDomain(#ibzemployeedtos)),'ibzrt-IBZEmployee-Update')"
)
@ApiOperation
(
value
=
"根据单位机构部门批量更新人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门批量更新人员"
)
@ApiOperation
(
value
=
"根据单位机构部门批量更新人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门批量更新人员"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/batch"
)
@RequestMapping
(
method
=
RequestMethod
.
PUT
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/batch"
)
public
ResponseEntity
<
Boolean
>
updateBatchByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
public
ResponseEntity
<
Boolean
>
updateBatchByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
...
@@ -512,15 +472,13 @@ domain.setUserid(ibzemployee_id);
...
@@ -512,15 +472,13 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.get(#ibzemployee_id),'ibzrt-IBZEmployee-Remove')"
)
@ApiOperation
(
value
=
"根据单位机构部门删除人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门删除人员"
)
@ApiOperation
(
value
=
"根据单位机构部门删除人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门删除人员"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}"
)
@Transactional
public
ResponseEntity
<
Boolean
>
removeByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
public
ResponseEntity
<
Boolean
>
removeByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
remove
(
ibzemployee_id
));
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
remove
(
ibzemployee_id
));
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeService.getIbzemployeeByIds(#ids),'ibzrt-IBZEmployee-Remove')"
)
@ApiOperation
(
value
=
"根据单位机构部门批量删除人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门批量删除人员"
)
@ApiOperation
(
value
=
"根据单位机构部门批量删除人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门批量删除人员"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/batch"
)
@RequestMapping
(
method
=
RequestMethod
.
DELETE
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/batch"
)
public
ResponseEntity
<
Boolean
>
removeBatchByIBZOrganizationIBZDepartment
(
@RequestBody
List
<
String
>
ids
)
{
public
ResponseEntity
<
Boolean
>
removeBatchByIBZOrganizationIBZDepartment
(
@RequestBody
List
<
String
>
ids
)
{
...
@@ -528,7 +486,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -528,7 +486,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
}
@PostAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(returnObject.body),'ibzrt-IBZEmployee-Get')"
)
@ApiOperation
(
value
=
"根据单位机构部门获取人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门获取人员"
)
@ApiOperation
(
value
=
"根据单位机构部门获取人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门获取人员"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}"
)
public
ResponseEntity
<
IBZEmployeeDTO
>
getByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
getByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
)
{
...
@@ -551,10 +508,9 @@ domain.setUserid(ibzemployee_id);
...
@@ -551,10 +508,9 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
checkKey
(
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
)));
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
checkKey
(
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
)));
}
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZEmployee-InitPwd-all')"
)
@ApiOperation
(
value
=
"根据单位机构部门人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门人员"
)
@ApiOperation
(
value
=
"根据单位机构部门人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}/initpwd"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/{ibzemployee_id}/initpwd"
)
@Transactional
public
ResponseEntity
<
IBZEmployeeDTO
>
initPwdByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
IBZEmployeeDTO
>
initPwdByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@PathVariable
(
"ibzemployee_id"
)
String
ibzemployee_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
IBZEmployee
domain
=
ibzemployeeMapping
.
toDomain
(
ibzemployeedto
);
domain
.
setMdeptid
(
ibzdepartment_id
);
domain
.
setMdeptid
(
ibzdepartment_id
);
...
@@ -563,7 +519,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -563,7 +519,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeedto
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeedto
);
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedto),'ibzrt-IBZEmployee-Save')"
)
@ApiOperation
(
value
=
"根据单位机构部门保存人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门保存人员"
)
@ApiOperation
(
value
=
"根据单位机构部门保存人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门保存人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/save"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/save"
)
public
ResponseEntity
<
Boolean
>
saveByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
public
ResponseEntity
<
Boolean
>
saveByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
IBZEmployeeDTO
ibzemployeedto
)
{
...
@@ -572,7 +527,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -572,7 +527,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
save
(
domain
));
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
ibzemployeeService
.
save
(
domain
));
}
}
@PreAuthorize
(
"hasPermission(this.ibzemployeeMapping.toDomain(#ibzemployeedtos),'ibzrt-IBZEmployee-Save')"
)
@ApiOperation
(
value
=
"根据单位机构部门批量保存人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门批量保存人员"
)
@ApiOperation
(
value
=
"根据单位机构部门批量保存人员"
,
tags
=
{
"人员"
},
notes
=
"根据单位机构部门批量保存人员"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/savebatch"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/savebatch"
)
public
ResponseEntity
<
Boolean
>
saveBatchByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
public
ResponseEntity
<
Boolean
>
saveBatchByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
List
<
IBZEmployeeDTO
>
ibzemployeedtos
)
{
...
@@ -584,7 +538,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -584,7 +538,6 @@ domain.setUserid(ibzemployee_id);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
true
);
}
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZEmployee-searchDefault-all') and hasPermission(#context,'ibzrt-IBZEmployee-Get')"
)
@ApiOperation
(
value
=
"根据单位机构部门获取DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"根据单位机构部门获取DEFAULT"
)
@ApiOperation
(
value
=
"根据单位机构部门获取DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"根据单位机构部门获取DEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/fetchdefault"
)
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/fetchdefault"
)
public
ResponseEntity
<
List
<
IBZEmployeeDTO
>>
fetchIBZEmployeeDefaultByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
IBZEmployeeSearchContext
context
)
{
public
ResponseEntity
<
List
<
IBZEmployeeDTO
>>
fetchIBZEmployeeDefaultByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
IBZEmployeeSearchContext
context
)
{
...
@@ -598,7 +551,6 @@ domain.setUserid(ibzemployee_id);
...
@@ -598,7 +551,6 @@ domain.setUserid(ibzemployee_id);
.
body
(
list
);
.
body
(
list
);
}
}
@PreAuthorize
(
"hasAnyAuthority('ROLE_SUPERADMIN','ibzrt-IBZEmployee-searchDefault-all') and hasPermission(#context,'ibzrt-IBZEmployee-Get')"
)
@ApiOperation
(
value
=
"根据单位机构部门查询DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"根据单位机构部门查询DEFAULT"
)
@ApiOperation
(
value
=
"根据单位机构部门查询DEFAULT"
,
tags
=
{
"人员"
}
,
notes
=
"根据单位机构部门查询DEFAULT"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/searchdefault"
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/ibzorganizations/{ibzorganization_id}/ibzdepartments/{ibzdepartment_id}/ibzemployees/searchdefault"
)
public
ResponseEntity
<
Page
<
IBZEmployeeDTO
>>
searchIBZEmployeeDefaultByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
IBZEmployeeSearchContext
context
)
{
public
ResponseEntity
<
Page
<
IBZEmployeeDTO
>>
searchIBZEmployeeDefaultByIBZOrganizationIBZDepartment
(
@PathVariable
(
"ibzorganization_id"
)
String
ibzorganization_id
,
@PathVariable
(
"ibzdepartment_id"
)
String
ibzdepartment_id
,
@RequestBody
IBZEmployeeSearchContext
context
)
{
...
...
编辑
预览
Markdown
格式
0%
请重试
or
添加新附件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录