Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
I
iBiz企业中心
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
iBiz企业套件
iBiz企业中心
提交
03963983
提交
03963983
编写于
7月 22, 2020
作者:
ibizdev
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
xignzi006 发布系统代码
上级
361c3675
变更
61
展开全部
隐藏空白字符变更
内嵌
并排
正在显示
61 个修改的文件
包含
3536 行增加
和
1190 行删除
+3536
-1190
dropdown-list.vue
...essCentral/src/components/dropdown-list/dropdown-list.vue
+26
-12
central-base.tsx
app_BusinessCentral/src/pages/base/central/central-base.tsx
+5
-3
router.ts
app_BusinessCentral/src/pages/base/central/router.ts
+1
-1
account-service-base.ts
...sinessCentral/src/service/account/account-service-base.ts
+50
-50
campaign-service-base.ts
...nessCentral/src/service/campaign/campaign-service-base.ts
+50
-50
competitor-service-base.ts
...Central/src/service/competitor/competitor-service-base.ts
+50
-50
contact-service-base.ts
...sinessCentral/src/service/contact/contact-service-base.ts
+131
-131
ibiz-list-service-base.ts
...ssCentral/src/service/ibiz-list/ibiz-list-service-base.ts
+82
-82
lead-service-base.ts
app_BusinessCentral/src/service/lead/lead-service-base.ts
+334
-334
sales-literature-service-base.ts
...service/sales-literature/sales-literature-service-base.ts
+50
-50
app-content-left-exp.tsx
...ents/layout/app-content-left-exp/app-content-left-exp.tsx
+1
-0
app-content.tsx
...studio-core/components/layout/app-content/app-content.tsx
+2
-2
studio-view-layout.less
...tudio-core/components/studio-view/studio-view-layout.less
+1
-0
studio-view.less
...l/src/studio-core/components/studio-view/studio-view.less
+1
-0
view-toolbar.tsx
.../src/studio-core/components/view-toolbar/view-toolbar.tsx
+1
-1
index.ts
app_BusinessCentral/src/studio-core/decorators/index.ts
+4
-0
ServiceData.ts
...Central/src/studio-core/decorators/service/ServiceData.ts
+61
-0
ServiceInjector.ts
...ral/src/studio-core/decorators/service/ServiceInjector.ts
+23
-0
ServiceProvide.ts
...tral/src/studio-core/decorators/service/ServiceProvide.ts
+20
-0
EditFormControlBase.tsx
...ssCentral/src/studio-core/widgets/EditFormControlBase.tsx
+3
-3
FormControlBase.tsx
...sinessCentral/src/studio-core/widgets/FormControlBase.tsx
+2
-2
GridControllerBase.tsx
...essCentral/src/studio-core/widgets/GridControllerBase.tsx
+6
-5
ListControllerBase.tsx
...essCentral/src/studio-core/widgets/ListControllerBase.tsx
+2
-2
default.less
app_BusinessCentral/src/styles/default.less
+21
-9
template.html
app_BusinessCentral/src/template.html
+1
-1
auth-guard.ts
app_BusinessCentral/src/utils/auth-guard/auth-guard.ts
+6
-2
AppointmentServiceImpl.java
...entral/core/base/service/impl/AppointmentServiceImpl.java
+1
-1
EmailServiceImpl.java
...inesscentral/core/base/service/impl/EmailServiceImpl.java
+1
-1
FaxServiceImpl.java
...usinesscentral/core/base/service/impl/FaxServiceImpl.java
+1
-1
LetterServiceImpl.java
...nesscentral/core/base/service/impl/LetterServiceImpl.java
+1
-1
PhoneCallServiceImpl.java
...scentral/core/base/service/impl/PhoneCallServiceImpl.java
+1
-1
TaskServiceImpl.java
...sinesscentral/core/base/service/impl/TaskServiceImpl.java
+1
-1
Attendance.java
...businesscentral/core/humanresource/domain/Attendance.java
+106
-0
Company.java
...ab/businesscentral/core/humanresource/domain/Company.java
+106
-0
Employee.java
...b/businesscentral/core/humanresource/domain/Employee.java
+106
-0
Leave.java
...zlab/businesscentral/core/humanresource/domain/Leave.java
+106
-0
AttendanceSearchContext.java
...al/core/humanresource/filter/AttendanceSearchContext.java
+54
-0
CompanySearchContext.java
...ntral/core/humanresource/filter/CompanySearchContext.java
+54
-0
EmployeeSearchContext.java
...tral/core/humanresource/filter/EmployeeSearchContext.java
+54
-0
LeaveSearchContext.java
...central/core/humanresource/filter/LeaveSearchContext.java
+54
-0
AttendanceMapper.java
...sscentral/core/humanresource/mapper/AttendanceMapper.java
+65
-0
CompanyMapper.java
...inesscentral/core/humanresource/mapper/CompanyMapper.java
+65
-0
EmployeeMapper.java
...nesscentral/core/humanresource/mapper/EmployeeMapper.java
+65
-0
LeaveMapper.java
...usinesscentral/core/humanresource/mapper/LeaveMapper.java
+65
-0
IAttendanceService.java
...entral/core/humanresource/service/IAttendanceService.java
+59
-0
ICompanyService.java
...sscentral/core/humanresource/service/ICompanyService.java
+59
-0
IEmployeeService.java
...scentral/core/humanresource/service/IEmployeeService.java
+59
-0
ILeaveService.java
...nesscentral/core/humanresource/service/ILeaveService.java
+59
-0
AttendanceServiceImpl.java
...ore/humanresource/service/impl/AttendanceServiceImpl.java
+206
-0
CompanyServiceImpl.java
...l/core/humanresource/service/impl/CompanyServiceImpl.java
+206
-0
EmployeeServiceImpl.java
.../core/humanresource/service/impl/EmployeeServiceImpl.java
+206
-0
LeaveServiceImpl.java
...ral/core/humanresource/service/impl/LeaveServiceImpl.java
+206
-0
CampaignActivityServiceImpl.java
...e/marketing/service/impl/CampaignActivityServiceImpl.java
+1
-1
CampaignResponseServiceImpl.java
...e/marketing/service/impl/CampaignResponseServiceImpl.java
+1
-1
ServiceAppointmentServiceImpl.java
...e/service/service/impl/ServiceAppointmentServiceImpl.java
+1
-1
h2_table.xml
...esscentral-core/src/main/resources/liquibase/h2_table.xml
+475
-391
AttendanceMapper.xml
...rces/mapper/humanresource/attendance/AttendanceMapper.xml
+39
-0
CompanyMapper.xml
.../resources/mapper/humanresource/company/CompanyMapper.xml
+39
-0
EmployeeMapper.xml
...esources/mapper/humanresource/employee/EmployeeMapper.xml
+39
-0
LeaveMapper.xml
...main/resources/mapper/humanresource/leave/LeaveMapper.xml
+39
-0
FeignRequestInterceptor.java
...lab/businesscentral/util/web/FeignRequestInterceptor.java
+2
-0
未找到文件。
app_BusinessCentral/src/components/dropdown-list/dropdown-list.vue
浏览文件 @
03963983
...
...
@@ -58,17 +58,7 @@ export default class DropDownList extends Vue {
@
Watch
(
'itemValue'
)
public
valueWatch
()
{
try
{
if
(
this
.
$util
.
typeOf
(
this
.
itemValue
)
===
this
.
valueType
)
{
this
.
value
=
this
.
itemValue
;
}
else
if
(
this
.
valueType
===
'number'
)
{
if
(
this
.
itemValue
.
indexOf
(
'.'
)
===
-
1
)
{
this
.
value
=
parseInt
(
this
.
itemValue
);
}
else
{
this
.
value
=
parseFloat
(
this
.
itemValue
);
}
}
else
{
this
.
value
=
this
.
itemValue
.
toString
();
}
this
.
readyValue
();
// 代码表集合中不存在改选项,重新准备集合
if
(
this
.
value
&&
!
this
.
items
.
find
((
item
:
any
)
=>
Object
.
is
(
this
.
value
,
item
.
value
)))
{
this
.
readyCodelist
();
...
...
@@ -193,7 +183,7 @@ export default class DropDownList extends Vue {
* @memberof DropDownList
*/
get
currentVal
()
{
return
this
.
itemV
alue
;
return
this
.
v
alue
;
}
/**
...
...
@@ -269,8 +259,32 @@ export default class DropDownList extends Vue {
*/
public
created
()
{
this
.
readyCodelist
();
this
.
readyValue
();
}
/**
* 准备值
*
* @memberof DropDownList
*/
public
readyValue
()
{
if
(
this
.
itemValue
==
null
)
{
this
.
value
=
null
;
return
;
}
if
(
this
.
$util
.
typeOf
(
this
.
itemValue
)
===
this
.
valueType
)
{
this
.
value
=
this
.
itemValue
;
}
else
if
(
this
.
valueType
===
'number'
)
{
if
(
this
.
itemValue
.
indexOf
(
'.'
)
===
-
1
)
{
this
.
value
=
parseInt
(
this
.
itemValue
);
}
else
{
this
.
value
=
parseFloat
(
this
.
itemValue
);
}
}
else
{
this
.
value
=
this
.
itemValue
.
toString
();
}
}
/**
* 准备代码表
*
...
...
app_BusinessCentral/src/pages/base/central/central-base.tsx
浏览文件 @
03963983
...
...
@@ -221,9 +221,11 @@ export class CentralBase extends Vue {
if
(
params
?.
central
)
{
this
.
context
.
central
=
params
.
central
;
}
if
(
this
.
$store
.
getters
.
getAppData
()
&&
this
.
$store
.
getters
.
getAppData
().
context
)
{
Object
.
assign
(
this
.
context
,
this
.
$store
.
getters
.
getAppData
().
context
);
this
.
$store
.
getters
.
getAppData
().
context
=
this
.
context
;
const
context
=
this
.
$appService
.
contextStore
.
appContext
;
if
(
context
)
{
Object
.
assign
(
this
.
context
,
context
);
context
.
clearAll
();
Object
.
assign
(
context
,
this
.
context
);
}
}
...
...
app_BusinessCentral/src/pages/base/central/router.ts
浏览文件 @
03963983
...
...
@@ -17,7 +17,7 @@ const router = new Router({
const
routerParamsName
=
'central'
;
const
params
:
any
=
{};
if
(
to
.
params
&&
to
.
params
[
routerParamsName
])
{
Object
.
assign
(
params
,
qs
.
parse
(
to
.
params
[
routerParamsName
],
{
delimiter
:
';'
}))
;
params
[
routerParamsName
]
=
to
.
params
[
routerParamsName
]
;
}
const
url
:
string
=
'/appdata'
;
await
AuthGuard
.
getInstance
().
authGuard
(
url
,
params
,
router
);
...
...
app_BusinessCentral/src/service/account/account-service-base.ts
浏览文件 @
03963983
此差异已折叠。
点击以展开。
app_BusinessCentral/src/service/campaign/campaign-service-base.ts
浏览文件 @
03963983
此差异已折叠。
点击以展开。
app_BusinessCentral/src/service/competitor/competitor-service-base.ts
浏览文件 @
03963983
此差异已折叠。
点击以展开。
app_BusinessCentral/src/service/contact/contact-service-base.ts
浏览文件 @
03963983
此差异已折叠。
点击以展开。
app_BusinessCentral/src/service/ibiz-list/ibiz-list-service-base.ts
浏览文件 @
03963983
此差异已折叠。
点击以展开。
app_BusinessCentral/src/service/lead/lead-service-base.ts
浏览文件 @
03963983
此差异已折叠。
点击以展开。
app_BusinessCentral/src/service/sales-literature/sales-literature-service-base.ts
浏览文件 @
03963983
此差异已折叠。
点击以展开。
app_BusinessCentral/src/studio-core/components/layout/app-content-left-exp/app-content-left-exp.tsx
浏览文件 @
03963983
...
...
@@ -75,6 +75,7 @@ export class AppContentLeftExp extends Vue {
if
(
this
.
activeIndex
===
index
)
{
this
.
uiState
.
leftExpContentShowChange
();
}
else
{
this
.
uiState
.
leftExpContentShowChange
(
true
);
this
.
changeActiveItem
(
item
,
index
);
}
}
...
...
app_BusinessCentral/src/studio-core/components/layout/app-content/app-content.tsx
浏览文件 @
03963983
...
...
@@ -71,7 +71,7 @@ export class AppContent extends Vue {
*/
protected
renderContent
(
isSlot
:
boolean
):
any
{
return
<
div
slot=
{
isSlot
?
'right'
:
null
}
class=
{
{
'app-content-right'
:
true
,
'hidden-bottom'
:
(
!
this
.
$uiState
.
layoutState
.
contentBottomShow
||
!
this
.
$slots
.
content_bottom
)
}
}
>
<
split
mode=
"vertical"
v
-
model=
{
this
.
$uiState
.
layoutState
.
contentVerticalSplit
}
>
<
split
mode=
"vertical"
v
-
model=
{
this
.
$uiState
.
layoutState
.
contentVerticalSplit
}
max=
{
0.1
}
>
<
div
slot=
"top"
class=
"app-content-exp"
>
{
this
.
$slots
.
default
}
</
div
>
...
...
@@ -99,7 +99,7 @@ export class AppContent extends Vue {
this
.
renderContent
(
false
)
]
}
else
{
content
=
this
.
$slots
.
content_left
?
<
split
class=
{
{
'app-content-split'
:
true
,
'hidden-left'
:
!
this
.
$uiState
.
layoutState
.
leftExpContentShow
}
}
v
-
model=
{
this
.
$uiState
.
layoutState
.
contentHorizontalSplit
}
>
content
=
this
.
$slots
.
content_left
?
<
split
class=
{
{
'app-content-split'
:
true
,
'hidden-left'
:
!
this
.
$uiState
.
layoutState
.
leftExpContentShow
}
}
v
-
model=
{
this
.
$uiState
.
layoutState
.
contentHorizontalSplit
}
min=
{
0.1
}
max=
{
0.5
}
>
<
div
slot=
"left"
class=
"app-content-left"
>
{
this
.
$slots
.
content_left
}
</
div
>
...
...
app_BusinessCentral/src/studio-core/components/studio-view/studio-view-layout.less
浏览文件 @
03963983
...
...
@@ -224,6 +224,7 @@
height: 28px;
line-height: 28px;
color: var(--view-button-color);
background-color: var(--view-button-background-color);
}
}
}
...
...
app_BusinessCentral/src/studio-core/components/studio-view/studio-view.less
浏览文件 @
03963983
...
...
@@ -30,6 +30,7 @@
height: 28px;
line-height: 28px;
color: var(--view-button-color);
background-color: var(--view-button-background-color);
}
}
...
...
app_BusinessCentral/src/studio-core/components/view-toolbar/view-toolbar.tsx
浏览文件 @
03963983
...
...
@@ -213,7 +213,7 @@ export class ViewToolbar extends Vue {
}
return
<
i
-
button
title=
{
item
.
tooltip
}
v
-
show=
{
item
.
visabled
}
disabled=
{
item
.
disabled
}
class=
{
item
.
class
}
on
-
click=
{
(
e
:
any
)
=>
this
.
itemClick
({
tag
:
item
.
name
},
e
)
}
>
<
menu
-
icon
item=
{
item
}
/>
<
span
class=
'caption'
>
{
item
.
caption
}
</
span
>
<
span
class=
'caption'
v
-
show=
{
item
.
isShowCaption
}
>
{
item
.
caption
}
</
span
>
</
i
-
button
>;
});
}
...
...
app_BusinessCentral/src/studio-core/decorators/index.ts
0 → 100644
浏览文件 @
03963983
export
{
ServiceInjector
}
from
'./service/ServiceInjector'
;
export
{
ServiceProvide
}
from
'./service/ServiceProvide'
;
export
{
SingletonMode
}
from
'./SingletonMode'
;
export
{
VueLifeCycleProcessing
}
from
'./VueLifeCycleProcessing'
;
\ No newline at end of file
app_BusinessCentral/src/studio-core/decorators/service/ServiceData.ts
0 → 100644
浏览文件 @
03963983
class
ServiceData
{
/**
* 全局服务
*
* @private
* @type {*}
* @memberof ServiceData
*/
private
readonly
service
:
any
=
{};
/**
* 模块服务
*
* @private
* @type {*}
* @memberof ServiceData
*/
private
readonly
modules
:
any
=
{};
/**
* 新增服务
*
* @param {*} service
* @param {string} name
* @param {string} [module]
* @returns {*}
* @memberof ServiceData
*/
public
add
(
service
:
any
,
name
:
string
,
module
?:
string
):
any
{
if
(
module
&&
!
isEmpty
(
module
))
{
const
m
=
this
.
modules
[
module
];
if
(
m
&&
!
m
[
name
])
{
m
[
name
]
=
service
;
}
}
else
if
(
!
this
.
service
[
name
])
{
this
.
service
[
name
]
=
service
;
}
}
/**
* 获取服务
*
* @param {string} name
* @param {string} [module]
* @returns {*}
* @memberof ServiceData
*/
public
get
(
name
:
string
,
module
?:
string
):
any
{
if
(
module
&&
!
isEmpty
(
module
))
{
const
m
=
this
.
modules
[
module
];
if
(
m
)
{
return
m
[
name
];
}
}
return
this
.
service
[
name
];
}
}
// 导出实例
export
const
serviceData
=
new
ServiceData
();
\ No newline at end of file
app_BusinessCentral/src/studio-core/decorators/service/ServiceInjector.ts
0 → 100644
浏览文件 @
03963983
import
{
serviceData
}
from
'./ServiceData'
/**
* 服务注入器
*
* @export
* @param {string} name
* @param {string} [module]
* @returns {*}
*/
export
function
ServiceInjector
(
name
:
string
,
module
?:
string
):
any
{
/**
* 装饰器处理
*/
return
function
(
target
:
any
,
fileName
:
string
)
{
const
service
=
serviceData
.
get
(
name
,
module
);
if
(
service
)
{
target
[
fileName
]
=
service
;
}
}
}
\ No newline at end of file
app_BusinessCentral/src/studio-core/decorators/service/ServiceProvide.ts
0 → 100644
浏览文件 @
03963983
import
{
serviceData
}
from
'./ServiceData'
/**
* 服务注入器
*
* @export
* @param {string} name 服务名称
* @param {string} [module] 模块名称
* @returns {*}
*/
export
function
ServiceProvide
(
name
:
string
,
module
?:
string
):
any
{
/**
* 装饰器处理
*/
return
function
(
target
:
any
)
{
serviceData
.
add
(
new
target
(),
name
,
module
);
}
}
\ No newline at end of file
app_BusinessCentral/src/studio-core/widgets/EditFormControlBase.tsx
浏览文件 @
03963983
...
...
@@ -261,7 +261,7 @@ export class EditFormControlBase extends FormControlBase {
const
action
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)
?
this
.
updateAction
:
this
.
createAction
;
if
(
!
action
)
{
let
actionName
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)
?
"updateAction"
:
"createAction"
;
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'${view.getName()}'
+
(
this
.
$t
(
'app.formpage.notconfig.actionname'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.formpage.notconfig.actionname'
)
as
string
)
});
return
;
}
Object
.
assign
(
arg
,
{
viewparams
:
this
.
viewparams
});
...
...
@@ -333,7 +333,7 @@ export class EditFormControlBase extends FormControlBase {
const
action
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)
?
this
.
updateAction
:
this
.
createAction
;
if
(
!
action
)
{
let
actionName
:
any
=
Object
.
is
(
data
.
srfuf
,
'1'
)
?
"updateAction"
:
"createAction"
;
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'${view.getName()}'
+
(
this
.
$t
(
'app.formpage.notconfig.actionname'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.formpage.notconfig.actionname'
)
as
string
)
});
return
;
}
Object
.
assign
(
arg
,
{
viewparams
:
this
.
viewparams
});
...
...
@@ -394,7 +394,7 @@ export class EditFormControlBase extends FormControlBase {
public
remove
(
opt
:
Array
<
any
>
=
[],
showResultInfo
?:
boolean
):
Promise
<
any
>
{
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
if
(
!
this
.
removeAction
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'${view.getName()}视图表单removeAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
`
${
this
.
name
}
表单removeAction参数未配置`
});
return
;
}
const
arg
:
any
=
opt
[
0
];
...
...
app_BusinessCentral/src/studio-core/widgets/FormControlBase.tsx
浏览文件 @
03963983
...
...
@@ -463,7 +463,7 @@ export class FormControlBase extends MainControlBase {
*/
public
load
(
opt
:
any
=
{}):
void
{
if
(
!
this
.
loadAction
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'${view.getName()}'
+
(
this
.
$t
(
'app.formpage.notconfig.loadaction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.formpage.notconfig.loadaction'
)
as
string
)
});
return
;
}
const
arg
:
any
=
{
...
opt
};
...
...
@@ -499,7 +499,7 @@ export class FormControlBase extends MainControlBase {
*/
public
loadDraft
(
opt
:
any
=
{}):
void
{
if
(
!
this
.
loaddraftAction
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'${view.getName()}视图表单loaddraftAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
`
${
this
.
name
}
表单loaddraftAction参数未配置`
});
return
;
}
const
arg
:
any
=
{
...
opt
};
...
...
app_BusinessCentral/src/studio-core/widgets/GridControllerBase.tsx
浏览文件 @
03963983
...
...
@@ -370,7 +370,7 @@ export class GridControllerBase extends MDControlBase {
try
{
if
(
Object
.
is
(
item
.
rowDataState
,
'create'
))
{
if
(
!
this
.
createAction
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'${view.getName()}'
+
(
this
.
$t
(
'app.gridpage.notConfig.createAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.gridpage.notConfig.createAction'
)
as
string
)
});
}
else
{
Object
.
assign
(
item
,
{
viewparams
:
this
.
viewparams
});
let
response
=
await
this
.
service
.
add
(
this
.
createAction
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
context
)),
item
,
this
.
showBusyIndicator
);
...
...
@@ -378,7 +378,7 @@ export class GridControllerBase extends MDControlBase {
}
}
else
if
(
Object
.
is
(
item
.
rowDataState
,
'update'
))
{
if
(
!
this
.
updateAction
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'${view.getName()}'
+
(
this
.
$t
(
'app.gridpage.notConfig.updateAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.gridpage.notConfig.updateAction'
)
as
string
)
});
}
else
{
Object
.
assign
(
item
,
{
viewparams
:
this
.
viewparams
});
if
(
item
[
this
.
appDeName
])
{
...
...
@@ -416,7 +416,7 @@ export class GridControllerBase extends MDControlBase {
*/
public
load
(
opt
:
any
=
{},
pageReset
:
boolean
=
false
):
void
{
if
(
!
this
.
fetchAction
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'${view.getName()}'
+
(
this
.
$t
(
'app.gridpage.notConfig.fetchAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.gridpage.notConfig.fetchAction'
)
as
string
)
});
return
;
}
if
(
pageReset
)
{
...
...
@@ -500,7 +500,7 @@ export class GridControllerBase extends MDControlBase {
*/
public
async
remove
(
items
:
any
[]):
Promise
<
any
>
{
if
(
!
this
.
removeAction
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'${view.getName()}'
+
(
this
.
$t
(
'app.gridpage.notConfig.removeAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.gridpage.notConfig.removeAction'
)
as
string
)
});
return
;
}
const
arr
:
any
[]
=
[];
...
...
@@ -1030,7 +1030,7 @@ export class GridControllerBase extends MDControlBase {
*/
public
newRow
(
args
:
any
[],
params
?:
any
,
$event
?:
any
,
xData
?:
any
):
void
{
if
(
!
this
.
loaddraftAction
)
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
'${view.getName()}'
+
(
this
.
$t
(
'app.gridpage.notConfig.loaddraftAction'
)
as
string
)
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.wrong'
)
as
string
),
desc
:
(
this
.
$t
(
'app.gridpage.notConfig.loaddraftAction'
)
as
string
)
});
return
;
}
Object
.
assign
(
args
[
0
],
{
viewparams
:
this
.
viewparams
});
...
...
@@ -1045,6 +1045,7 @@ export class GridControllerBase extends MDControlBase {
const
data
=
response
.
data
;
this
.
createDefault
(
data
);
data
.
rowDataState
=
"create"
;
Object
.
assign
(
data
,
this
.
getActionState
(
data
));
this
.
items
.
push
(
data
);
this
.
gridItemsModel
.
push
(
this
.
getGridRowModel
());
}).
catch
((
response
:
any
)
=>
{
...
...
app_BusinessCentral/src/studio-core/widgets/ListControllerBase.tsx
浏览文件 @
03963983
...
...
@@ -96,7 +96,7 @@ export class ListControllerBase extends MDControlBase {
*/
public
load
(
opt
:
any
=
{}):
void
{
if
(
!
this
.
fetchAction
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'
${view.getName()}
视图列表fetchAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'视图列表fetchAction参数未配置'
});
return
;
}
const
arg
:
any
=
{
...
opt
};
...
...
@@ -160,7 +160,7 @@ export class ListControllerBase extends MDControlBase {
*/
public
async
remove
(
items
:
any
[]):
Promise
<
any
>
{
if
(
!
this
.
removeAction
)
{
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
'${view.getName()}视图表格removeAction参数未配置'
});
this
.
$Notice
.
error
({
title
:
'错误'
,
desc
:
`
${
this
.
name
}
列表removeAction参数未配置`
});
return
;
}
if
(
items
.
length
===
0
)
{
...
...
app_BusinessCentral/src/styles/default.less
浏览文件 @
03963983
...
...
@@ -211,7 +211,12 @@ div::-webkit-scrollbar-thumb {
>.el-checkbox__inner {
background-color: var(--form-editor-background-color);
border: 1px solid var(--view-background-color-bright);
border: 1px solid var(--form-editor-border-color);
}
>.el-checkbox__inner::after{
border: 1px solid var(--form-editor-font-color);
border-left: 0;
border-top: 0;
}
}
}
...
...
@@ -253,6 +258,12 @@ div::-webkit-scrollbar-thumb {
background-color: var(--form-editor-background-color);
border: 1px solid var(--view-background-color-bright);
}
>.el-checkbox__inner::after{
border: 1px solid var(--form-editor-font-color);
border-left: 0;
border-top: 0;
}
}
}
}
...
...
@@ -343,7 +354,7 @@ div::-webkit-scrollbar-thumb {
.ivu-page-item-active {
>a {
color: var(--view-
font-color-bright
);
color: var(--view-
button-color
);
}
}
...
...
@@ -355,9 +366,9 @@ div::-webkit-scrollbar-thumb {
>.ivu-select-selection {
height: 22px;
background-color: var(--
form-editor
-background-color);
border: 1px solid var(--form-editor-b
ackground
-color);
color: var(--
form-editor-font
-color);
background-color: var(--
view-button
-background-color);
border: 1px solid var(--form-editor-b
order
-color);
color: var(--
view-button
-color);
>div {
...
...
@@ -369,8 +380,9 @@ div::-webkit-scrollbar-thumb {
}
>.ivu-select-selection:hover {
border-color: var(--form-editor-active-color);
background-color: var(--form-editor-active-color);
border-color: var(--view-button-background-color-active);
background-color: var(--view-button-background-color-active);
color: var(--view-button-color-active);
}
}
}
...
...
@@ -645,7 +657,7 @@ div::-webkit-scrollbar-thumb {
>.ivu-select-selection {
background: var(--form-editor-background-color);
border-color:
transparent
;
border-color:
var(--form-editor-border-color);
;
.ivu-select-placeholder {
color: var(--form-editor-placeholder-font-color);
...
...
@@ -673,7 +685,7 @@ div::-webkit-scrollbar-thumb {
}
.ivu-input-number {
border-color:
transparent
;
border-color:
var(--form-editor-border-color)
;
.ivu-input-number-input {
text-align: left;
...
...
app_BusinessCentral/src/template.html
浏览文件 @
03963983
<!DOCTYPE html>
<html
lang=
"en"
class=
"app-theme-
light
"
>
<html
lang=
"en"
class=
"app-theme-
dark-white
"
>
<head>
<meta
charset=
"utf-8"
>
<meta
http-equiv=
"X-UA-Compatible"
content=
"IE=edge"
>
...
...
app_BusinessCentral/src/utils/auth-guard/auth-guard.ts
浏览文件 @
03963983
...
...
@@ -51,7 +51,8 @@ export class AuthGuard {
*/
public
async
authGuard
(
url
:
string
,
params
:
any
=
{},
router
:
any
):
Promise
<
boolean
>
{
try
{
const
response
=
await
Http
.
getInstance
().
get
(
url
);
let
appContext
=
{};
const
response
=
await
Http
.
getInstance
().
get
(
url
,
params
);
if
(
response
&&
response
.
status
===
200
)
{
let
{
data
}:
{
data
:
any
}
=
response
;
if
(
data
)
{
...
...
@@ -66,11 +67,14 @@ export class AuthGuard {
data
=
JSON
.
parse
(
JSON
.
stringify
(
localAppData
));
}
this
.
formatAppData
(
data
);
new
AppService
().
contextStore
.
appContext
=
data
.
context
;
if
(
data
.
context
)
{
appContext
=
data
.
context
;
}
router
.
app
.
$store
.
commit
(
'addAppData'
,
data
);
// 提交统一资源数据
router
.
app
.
$store
.
dispatch
(
'authresource/commitAuthData'
,
data
);
}
new
AppService
().
contextStore
.
appContext
=
appContext
;
}
return
true
;
}
catch
(
err
)
{
...
...
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/base/service/impl/AppointmentServiceImpl.java
浏览文件 @
03963983
...
...
@@ -89,8 +89,8 @@ public class AppointmentServiceImpl extends ServiceImpl<AppointmentMapper, Appoi
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
activitypointerService
.
remove
(
key
);
boolean
result
=
removeById
(
key
);
return
result
;
}
...
...
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/base/service/impl/EmailServiceImpl.java
浏览文件 @
03963983
...
...
@@ -94,8 +94,8 @@ public class EmailServiceImpl extends ServiceImpl<EmailMapper, Email> implements
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
activitypointerService
.
remove
(
key
);
boolean
result
=
removeById
(
key
);
return
result
;
}
...
...
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/base/service/impl/FaxServiceImpl.java
浏览文件 @
03963983
...
...
@@ -89,8 +89,8 @@ public class FaxServiceImpl extends ServiceImpl<FaxMapper, Fax> implements IFaxS
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
activitypointerService
.
remove
(
key
);
boolean
result
=
removeById
(
key
);
return
result
;
}
...
...
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/base/service/impl/LetterServiceImpl.java
浏览文件 @
03963983
...
...
@@ -89,8 +89,8 @@ public class LetterServiceImpl extends ServiceImpl<LetterMapper, Letter> impleme
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
activitypointerService
.
remove
(
key
);
boolean
result
=
removeById
(
key
);
return
result
;
}
...
...
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/base/service/impl/PhoneCallServiceImpl.java
浏览文件 @
03963983
...
...
@@ -89,8 +89,8 @@ public class PhoneCallServiceImpl extends ServiceImpl<PhoneCallMapper, PhoneCall
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
activitypointerService
.
remove
(
key
);
boolean
result
=
removeById
(
key
);
return
result
;
}
...
...
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/base/service/impl/TaskServiceImpl.java
浏览文件 @
03963983
...
...
@@ -89,8 +89,8 @@ public class TaskServiceImpl extends ServiceImpl<TaskMapper, Task> implements IT
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
activitypointerService
.
remove
(
key
);
boolean
result
=
removeById
(
key
);
return
result
;
}
...
...
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/domain/Attendance.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
domain
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.math.BigInteger
;
import
java.util.HashMap
;
import
java.math.BigDecimal
;
import
java.text.SimpleDateFormat
;
import
com.alibaba.fastjson.annotation.JSONField
;
import
com.fasterxml.jackson.annotation.JsonIgnore
;
import
com.fasterxml.jackson.annotation.JsonProperty
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.DigestUtils
;
import
cn.ibizlab.businesscentral.util.domain.EntityBase
;
import
cn.ibizlab.businesscentral.util.annotation.DEField
;
import
cn.ibizlab.businesscentral.util.enums.DEPredefinedFieldType
;
import
cn.ibizlab.businesscentral.util.enums.DEFieldDefaultValueType
;
import
java.io.Serializable
;
import
lombok.*
;
import
org.springframework.data.annotation.Transient
;
import
cn.ibizlab.businesscentral.util.annotation.Audit
;
import
com.fasterxml.jackson.annotation.JsonIgnoreProperties
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.businesscentral.util.domain.EntityMP
;
/**
* 实体[考勤]
*/
@Getter
@Setter
@NoArgsConstructor
@JsonIgnoreProperties
(
value
=
"handler"
)
@TableName
(
value
=
"ATTENDANCE"
,
resultMap
=
"AttendanceResultMap"
)
public
class
Attendance
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 考勤标识
*/
@DEField
(
isKeyField
=
true
)
@TableId
(
value
=
"attendanceid"
,
type
=
IdType
.
ASSIGN_UUID
)
@JSONField
(
name
=
"attendanceid"
)
@JsonProperty
(
"attendanceid"
)
private
String
attendanceid
;
/**
* 考勤名称
*/
@TableField
(
value
=
"attendancename"
)
@JSONField
(
name
=
"attendancename"
)
@JsonProperty
(
"attendancename"
)
private
String
attendancename
;
/**
* 建立时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@TableField
(
value
=
"createdate"
,
fill
=
FieldFill
.
INSERT
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"createdate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"createdate"
)
private
Timestamp
createdate
;
/**
* 更新人
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEMAN
)
@TableField
(
value
=
"updateman"
)
@JSONField
(
name
=
"updateman"
)
@JsonProperty
(
"updateman"
)
private
String
updateman
;
/**
* 建立人
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEMAN
)
@TableField
(
value
=
"createman"
,
fill
=
FieldFill
.
INSERT
)
@JSONField
(
name
=
"createman"
)
@JsonProperty
(
"createman"
)
private
String
createman
;
/**
* 更新时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEDATE
)
@TableField
(
value
=
"updatedate"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"updatedate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"updatedate"
)
private
Timestamp
updatedate
;
/**
* 设置 [考勤名称]
*/
public
void
setAttendancename
(
String
attendancename
){
this
.
attendancename
=
attendancename
;
this
.
modify
(
"attendancename"
,
attendancename
);
}
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/domain/Company.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
domain
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.math.BigInteger
;
import
java.util.HashMap
;
import
java.math.BigDecimal
;
import
java.text.SimpleDateFormat
;
import
com.alibaba.fastjson.annotation.JSONField
;
import
com.fasterxml.jackson.annotation.JsonIgnore
;
import
com.fasterxml.jackson.annotation.JsonProperty
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.DigestUtils
;
import
cn.ibizlab.businesscentral.util.domain.EntityBase
;
import
cn.ibizlab.businesscentral.util.annotation.DEField
;
import
cn.ibizlab.businesscentral.util.enums.DEPredefinedFieldType
;
import
cn.ibizlab.businesscentral.util.enums.DEFieldDefaultValueType
;
import
java.io.Serializable
;
import
lombok.*
;
import
org.springframework.data.annotation.Transient
;
import
cn.ibizlab.businesscentral.util.annotation.Audit
;
import
com.fasterxml.jackson.annotation.JsonIgnoreProperties
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.businesscentral.util.domain.EntityMP
;
/**
* 实体[公司]
*/
@Getter
@Setter
@NoArgsConstructor
@JsonIgnoreProperties
(
value
=
"handler"
)
@TableName
(
value
=
"COMPANY"
,
resultMap
=
"CompanyResultMap"
)
public
class
Company
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 公司标识
*/
@DEField
(
isKeyField
=
true
)
@TableId
(
value
=
"companyid"
,
type
=
IdType
.
ASSIGN_UUID
)
@JSONField
(
name
=
"companyid"
)
@JsonProperty
(
"companyid"
)
private
String
companyid
;
/**
* 建立人
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEMAN
)
@TableField
(
value
=
"createman"
,
fill
=
FieldFill
.
INSERT
)
@JSONField
(
name
=
"createman"
)
@JsonProperty
(
"createman"
)
private
String
createman
;
/**
* 公司名称
*/
@TableField
(
value
=
"companyname"
)
@JSONField
(
name
=
"companyname"
)
@JsonProperty
(
"companyname"
)
private
String
companyname
;
/**
* 更新人
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEMAN
)
@TableField
(
value
=
"updateman"
)
@JSONField
(
name
=
"updateman"
)
@JsonProperty
(
"updateman"
)
private
String
updateman
;
/**
* 建立时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@TableField
(
value
=
"createdate"
,
fill
=
FieldFill
.
INSERT
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"createdate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"createdate"
)
private
Timestamp
createdate
;
/**
* 更新时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEDATE
)
@TableField
(
value
=
"updatedate"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"updatedate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"updatedate"
)
private
Timestamp
updatedate
;
/**
* 设置 [公司名称]
*/
public
void
setCompanyname
(
String
companyname
){
this
.
companyname
=
companyname
;
this
.
modify
(
"companyname"
,
companyname
);
}
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/domain/Employee.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
domain
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.math.BigInteger
;
import
java.util.HashMap
;
import
java.math.BigDecimal
;
import
java.text.SimpleDateFormat
;
import
com.alibaba.fastjson.annotation.JSONField
;
import
com.fasterxml.jackson.annotation.JsonIgnore
;
import
com.fasterxml.jackson.annotation.JsonProperty
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.DigestUtils
;
import
cn.ibizlab.businesscentral.util.domain.EntityBase
;
import
cn.ibizlab.businesscentral.util.annotation.DEField
;
import
cn.ibizlab.businesscentral.util.enums.DEPredefinedFieldType
;
import
cn.ibizlab.businesscentral.util.enums.DEFieldDefaultValueType
;
import
java.io.Serializable
;
import
lombok.*
;
import
org.springframework.data.annotation.Transient
;
import
cn.ibizlab.businesscentral.util.annotation.Audit
;
import
com.fasterxml.jackson.annotation.JsonIgnoreProperties
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.businesscentral.util.domain.EntityMP
;
/**
* 实体[员工]
*/
@Getter
@Setter
@NoArgsConstructor
@JsonIgnoreProperties
(
value
=
"handler"
)
@TableName
(
value
=
"EMPLOYEE"
,
resultMap
=
"EmployeeResultMap"
)
public
class
Employee
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 员工标识
*/
@DEField
(
isKeyField
=
true
)
@TableId
(
value
=
"employeeid"
,
type
=
IdType
.
ASSIGN_UUID
)
@JSONField
(
name
=
"employeeid"
)
@JsonProperty
(
"employeeid"
)
private
String
employeeid
;
/**
* 员工名称
*/
@TableField
(
value
=
"employeename"
)
@JSONField
(
name
=
"employeename"
)
@JsonProperty
(
"employeename"
)
private
String
employeename
;
/**
* 建立人
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEMAN
)
@TableField
(
value
=
"createman"
,
fill
=
FieldFill
.
INSERT
)
@JSONField
(
name
=
"createman"
)
@JsonProperty
(
"createman"
)
private
String
createman
;
/**
* 更新人
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEMAN
)
@TableField
(
value
=
"updateman"
)
@JSONField
(
name
=
"updateman"
)
@JsonProperty
(
"updateman"
)
private
String
updateman
;
/**
* 更新时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEDATE
)
@TableField
(
value
=
"updatedate"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"updatedate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"updatedate"
)
private
Timestamp
updatedate
;
/**
* 建立时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@TableField
(
value
=
"createdate"
,
fill
=
FieldFill
.
INSERT
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"createdate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"createdate"
)
private
Timestamp
createdate
;
/**
* 设置 [员工名称]
*/
public
void
setEmployeename
(
String
employeename
){
this
.
employeename
=
employeename
;
this
.
modify
(
"employeename"
,
employeename
);
}
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/domain/Leave.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
domain
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.math.BigInteger
;
import
java.util.HashMap
;
import
java.math.BigDecimal
;
import
java.text.SimpleDateFormat
;
import
com.alibaba.fastjson.annotation.JSONField
;
import
com.fasterxml.jackson.annotation.JsonIgnore
;
import
com.fasterxml.jackson.annotation.JsonProperty
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.DigestUtils
;
import
cn.ibizlab.businesscentral.util.domain.EntityBase
;
import
cn.ibizlab.businesscentral.util.annotation.DEField
;
import
cn.ibizlab.businesscentral.util.enums.DEPredefinedFieldType
;
import
cn.ibizlab.businesscentral.util.enums.DEFieldDefaultValueType
;
import
java.io.Serializable
;
import
lombok.*
;
import
org.springframework.data.annotation.Transient
;
import
cn.ibizlab.businesscentral.util.annotation.Audit
;
import
com.fasterxml.jackson.annotation.JsonIgnoreProperties
;
import
com.baomidou.mybatisplus.annotation.*
;
import
cn.ibizlab.businesscentral.util.domain.EntityMP
;
/**
* 实体[请假]
*/
@Getter
@Setter
@NoArgsConstructor
@JsonIgnoreProperties
(
value
=
"handler"
)
@TableName
(
value
=
"LEAVE"
,
resultMap
=
"LeaveResultMap"
)
public
class
Leave
extends
EntityMP
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 请假名称
*/
@TableField
(
value
=
"leavename"
)
@JSONField
(
name
=
"leavename"
)
@JsonProperty
(
"leavename"
)
private
String
leavename
;
/**
* 请假标识
*/
@DEField
(
isKeyField
=
true
)
@TableId
(
value
=
"leaveid"
,
type
=
IdType
.
ASSIGN_UUID
)
@JSONField
(
name
=
"leaveid"
)
@JsonProperty
(
"leaveid"
)
private
String
leaveid
;
/**
* 更新人
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEMAN
)
@TableField
(
value
=
"updateman"
)
@JSONField
(
name
=
"updateman"
)
@JsonProperty
(
"updateman"
)
private
String
updateman
;
/**
* 建立人
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEMAN
)
@TableField
(
value
=
"createman"
,
fill
=
FieldFill
.
INSERT
)
@JSONField
(
name
=
"createman"
)
@JsonProperty
(
"createman"
)
private
String
createman
;
/**
* 建立时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
CREATEDATE
)
@TableField
(
value
=
"createdate"
,
fill
=
FieldFill
.
INSERT
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"createdate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"createdate"
)
private
Timestamp
createdate
;
/**
* 更新时间
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEDATE
)
@TableField
(
value
=
"updatedate"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
locale
=
"zh"
,
timezone
=
"GMT+8"
)
@JSONField
(
name
=
"updatedate"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
@JsonProperty
(
"updatedate"
)
private
Timestamp
updatedate
;
/**
* 设置 [请假名称]
*/
public
void
setLeavename
(
String
leavename
){
this
.
leavename
=
leavename
;
this
.
modify
(
"leavename"
,
leavename
);
}
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/filter/AttendanceSearchContext.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
filter
;
import
java.math.BigDecimal
;
import
java.math.BigInteger
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
lombok.*
;
import
lombok.extern.slf4j.Slf4j
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.alibaba.fastjson.annotation.JSONField
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.businesscentral.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.businesscentral.core.humanresource.domain.Attendance
;
/**
* 关系型数据实体[Attendance] 查询条件对象
*/
@Slf4j
@Data
public
class
AttendanceSearchContext
extends
QueryWrapperContext
<
Attendance
>
{
private
String
n_attendancename_like
;
//[考勤名称]
public
void
setN_attendancename_like
(
String
n_attendancename_like
)
{
this
.
n_attendancename_like
=
n_attendancename_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_attendancename_like
)){
this
.
getSearchCond
().
like
(
"attendancename"
,
n_attendancename_like
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSearchCond
().
and
(
wrapper
->
wrapper
.
like
(
"attendancename"
,
query
)
);
}
}
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/filter/CompanySearchContext.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
filter
;
import
java.math.BigDecimal
;
import
java.math.BigInteger
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
lombok.*
;
import
lombok.extern.slf4j.Slf4j
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.alibaba.fastjson.annotation.JSONField
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.businesscentral.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.businesscentral.core.humanresource.domain.Company
;
/**
* 关系型数据实体[Company] 查询条件对象
*/
@Slf4j
@Data
public
class
CompanySearchContext
extends
QueryWrapperContext
<
Company
>
{
private
String
n_companyname_like
;
//[公司名称]
public
void
setN_companyname_like
(
String
n_companyname_like
)
{
this
.
n_companyname_like
=
n_companyname_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_companyname_like
)){
this
.
getSearchCond
().
like
(
"companyname"
,
n_companyname_like
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSearchCond
().
and
(
wrapper
->
wrapper
.
like
(
"companyname"
,
query
)
);
}
}
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/filter/EmployeeSearchContext.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
filter
;
import
java.math.BigDecimal
;
import
java.math.BigInteger
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
lombok.*
;
import
lombok.extern.slf4j.Slf4j
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.alibaba.fastjson.annotation.JSONField
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.businesscentral.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.businesscentral.core.humanresource.domain.Employee
;
/**
* 关系型数据实体[Employee] 查询条件对象
*/
@Slf4j
@Data
public
class
EmployeeSearchContext
extends
QueryWrapperContext
<
Employee
>
{
private
String
n_employeename_like
;
//[员工名称]
public
void
setN_employeename_like
(
String
n_employeename_like
)
{
this
.
n_employeename_like
=
n_employeename_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_employeename_like
)){
this
.
getSearchCond
().
like
(
"employeename"
,
n_employeename_like
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSearchCond
().
and
(
wrapper
->
wrapper
.
like
(
"employeename"
,
query
)
);
}
}
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/filter/LeaveSearchContext.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
filter
;
import
java.math.BigDecimal
;
import
java.math.BigInteger
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
lombok.*
;
import
lombok.extern.slf4j.Slf4j
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.alibaba.fastjson.annotation.JSONField
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.StringUtils
;
import
cn.ibizlab.businesscentral.util.filter.QueryWrapperContext
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
cn.ibizlab.businesscentral.core.humanresource.domain.Leave
;
/**
* 关系型数据实体[Leave] 查询条件对象
*/
@Slf4j
@Data
public
class
LeaveSearchContext
extends
QueryWrapperContext
<
Leave
>
{
private
String
n_leavename_like
;
//[请假名称]
public
void
setN_leavename_like
(
String
n_leavename_like
)
{
this
.
n_leavename_like
=
n_leavename_like
;
if
(!
ObjectUtils
.
isEmpty
(
this
.
n_leavename_like
)){
this
.
getSearchCond
().
like
(
"leavename"
,
n_leavename_like
);
}
}
/**
* 启用快速搜索
*/
public
void
setQuery
(
String
query
)
{
this
.
query
=
query
;
if
(!
StringUtils
.
isEmpty
(
query
)){
this
.
getSearchCond
().
and
(
wrapper
->
wrapper
.
like
(
"leavename"
,
query
)
);
}
}
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/mapper/AttendanceMapper.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
mapper
;
import
java.util.List
;
import
org.apache.ibatis.annotations.*
;
import
java.util.Map
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
java.util.HashMap
;
import
org.apache.ibatis.annotations.Select
;
import
cn.ibizlab.businesscentral.core.humanresource.domain.Attendance
;
import
cn.ibizlab.businesscentral.core.humanresource.filter.AttendanceSearchContext
;
import
org.springframework.cache.annotation.CacheEvict
;
import
org.springframework.cache.annotation.Cacheable
;
import
java.io.Serializable
;
import
com.baomidou.mybatisplus.core.toolkit.Constants
;
import
com.alibaba.fastjson.JSONObject
;
public
interface
AttendanceMapper
extends
BaseMapper
<
Attendance
>{
Page
<
Attendance
>
searchDefault
(
IPage
page
,
@Param
(
"srf"
)
AttendanceSearchContext
context
,
@Param
(
"ew"
)
Wrapper
<
Attendance
>
wrapper
)
;
@Override
Attendance
selectById
(
Serializable
id
);
@Override
int
insert
(
Attendance
entity
);
@Override
int
updateById
(
@Param
(
Constants
.
ENTITY
)
Attendance
entity
);
@Override
int
update
(
@Param
(
Constants
.
ENTITY
)
Attendance
entity
,
@Param
(
"ew"
)
Wrapper
<
Attendance
>
updateWrapper
);
@Override
int
deleteById
(
Serializable
id
);
/**
* 自定义查询SQL
* @param sql
* @return
*/
@Select
(
"${sql}"
)
List
<
JSONObject
>
selectBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
/**
* 自定义更新SQL
* @param sql
* @return
*/
@Update
(
"${sql}"
)
boolean
updateBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
/**
* 自定义插入SQL
* @param sql
* @return
*/
@Insert
(
"${sql}"
)
boolean
insertBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
/**
* 自定义删除SQL
* @param sql
* @return
*/
@Delete
(
"${sql}"
)
boolean
deleteBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/mapper/CompanyMapper.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
mapper
;
import
java.util.List
;
import
org.apache.ibatis.annotations.*
;
import
java.util.Map
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
java.util.HashMap
;
import
org.apache.ibatis.annotations.Select
;
import
cn.ibizlab.businesscentral.core.humanresource.domain.Company
;
import
cn.ibizlab.businesscentral.core.humanresource.filter.CompanySearchContext
;
import
org.springframework.cache.annotation.CacheEvict
;
import
org.springframework.cache.annotation.Cacheable
;
import
java.io.Serializable
;
import
com.baomidou.mybatisplus.core.toolkit.Constants
;
import
com.alibaba.fastjson.JSONObject
;
public
interface
CompanyMapper
extends
BaseMapper
<
Company
>{
Page
<
Company
>
searchDefault
(
IPage
page
,
@Param
(
"srf"
)
CompanySearchContext
context
,
@Param
(
"ew"
)
Wrapper
<
Company
>
wrapper
)
;
@Override
Company
selectById
(
Serializable
id
);
@Override
int
insert
(
Company
entity
);
@Override
int
updateById
(
@Param
(
Constants
.
ENTITY
)
Company
entity
);
@Override
int
update
(
@Param
(
Constants
.
ENTITY
)
Company
entity
,
@Param
(
"ew"
)
Wrapper
<
Company
>
updateWrapper
);
@Override
int
deleteById
(
Serializable
id
);
/**
* 自定义查询SQL
* @param sql
* @return
*/
@Select
(
"${sql}"
)
List
<
JSONObject
>
selectBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
/**
* 自定义更新SQL
* @param sql
* @return
*/
@Update
(
"${sql}"
)
boolean
updateBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
/**
* 自定义插入SQL
* @param sql
* @return
*/
@Insert
(
"${sql}"
)
boolean
insertBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
/**
* 自定义删除SQL
* @param sql
* @return
*/
@Delete
(
"${sql}"
)
boolean
deleteBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/mapper/EmployeeMapper.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
mapper
;
import
java.util.List
;
import
org.apache.ibatis.annotations.*
;
import
java.util.Map
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
java.util.HashMap
;
import
org.apache.ibatis.annotations.Select
;
import
cn.ibizlab.businesscentral.core.humanresource.domain.Employee
;
import
cn.ibizlab.businesscentral.core.humanresource.filter.EmployeeSearchContext
;
import
org.springframework.cache.annotation.CacheEvict
;
import
org.springframework.cache.annotation.Cacheable
;
import
java.io.Serializable
;
import
com.baomidou.mybatisplus.core.toolkit.Constants
;
import
com.alibaba.fastjson.JSONObject
;
public
interface
EmployeeMapper
extends
BaseMapper
<
Employee
>{
Page
<
Employee
>
searchDefault
(
IPage
page
,
@Param
(
"srf"
)
EmployeeSearchContext
context
,
@Param
(
"ew"
)
Wrapper
<
Employee
>
wrapper
)
;
@Override
Employee
selectById
(
Serializable
id
);
@Override
int
insert
(
Employee
entity
);
@Override
int
updateById
(
@Param
(
Constants
.
ENTITY
)
Employee
entity
);
@Override
int
update
(
@Param
(
Constants
.
ENTITY
)
Employee
entity
,
@Param
(
"ew"
)
Wrapper
<
Employee
>
updateWrapper
);
@Override
int
deleteById
(
Serializable
id
);
/**
* 自定义查询SQL
* @param sql
* @return
*/
@Select
(
"${sql}"
)
List
<
JSONObject
>
selectBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
/**
* 自定义更新SQL
* @param sql
* @return
*/
@Update
(
"${sql}"
)
boolean
updateBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
/**
* 自定义插入SQL
* @param sql
* @return
*/
@Insert
(
"${sql}"
)
boolean
insertBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
/**
* 自定义删除SQL
* @param sql
* @return
*/
@Delete
(
"${sql}"
)
boolean
deleteBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/mapper/LeaveMapper.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
mapper
;
import
java.util.List
;
import
org.apache.ibatis.annotations.*
;
import
java.util.Map
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.core.conditions.Wrapper
;
import
java.util.HashMap
;
import
org.apache.ibatis.annotations.Select
;
import
cn.ibizlab.businesscentral.core.humanresource.domain.Leave
;
import
cn.ibizlab.businesscentral.core.humanresource.filter.LeaveSearchContext
;
import
org.springframework.cache.annotation.CacheEvict
;
import
org.springframework.cache.annotation.Cacheable
;
import
java.io.Serializable
;
import
com.baomidou.mybatisplus.core.toolkit.Constants
;
import
com.alibaba.fastjson.JSONObject
;
public
interface
LeaveMapper
extends
BaseMapper
<
Leave
>{
Page
<
Leave
>
searchDefault
(
IPage
page
,
@Param
(
"srf"
)
LeaveSearchContext
context
,
@Param
(
"ew"
)
Wrapper
<
Leave
>
wrapper
)
;
@Override
Leave
selectById
(
Serializable
id
);
@Override
int
insert
(
Leave
entity
);
@Override
int
updateById
(
@Param
(
Constants
.
ENTITY
)
Leave
entity
);
@Override
int
update
(
@Param
(
Constants
.
ENTITY
)
Leave
entity
,
@Param
(
"ew"
)
Wrapper
<
Leave
>
updateWrapper
);
@Override
int
deleteById
(
Serializable
id
);
/**
* 自定义查询SQL
* @param sql
* @return
*/
@Select
(
"${sql}"
)
List
<
JSONObject
>
selectBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
/**
* 自定义更新SQL
* @param sql
* @return
*/
@Update
(
"${sql}"
)
boolean
updateBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
/**
* 自定义插入SQL
* @param sql
* @return
*/
@Insert
(
"${sql}"
)
boolean
insertBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
/**
* 自定义删除SQL
* @param sql
* @return
*/
@Delete
(
"${sql}"
)
boolean
deleteBySQL
(
@Param
(
"sql"
)
String
sql
,
@Param
(
"et"
)
Map
param
);
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/service/IAttendanceService.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
service
;
import
java.io.Serializable
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
java.math.BigInteger
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.cache.annotation.CacheEvict
;
import
cn.ibizlab.businesscentral.core.humanresource.domain.Attendance
;
import
cn.ibizlab.businesscentral.core.humanresource.filter.AttendanceSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[Attendance] 服务对象接口
*/
public
interface
IAttendanceService
extends
IService
<
Attendance
>{
boolean
create
(
Attendance
et
)
;
void
createBatch
(
List
<
Attendance
>
list
)
;
boolean
update
(
Attendance
et
)
;
void
updateBatch
(
List
<
Attendance
>
list
)
;
boolean
remove
(
String
key
)
;
void
removeBatch
(
Collection
<
String
>
idList
)
;
Attendance
get
(
String
key
)
;
Attendance
getDraft
(
Attendance
et
)
;
boolean
checkKey
(
Attendance
et
)
;
boolean
save
(
Attendance
et
)
;
void
saveBatch
(
List
<
Attendance
>
list
)
;
Page
<
Attendance
>
searchDefault
(
AttendanceSearchContext
context
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
List
<
Attendance
>
getAttendanceByIds
(
List
<
String
>
ids
)
;
List
<
Attendance
>
getAttendanceByEntities
(
List
<
Attendance
>
entities
)
;
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/service/ICompanyService.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
service
;
import
java.io.Serializable
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
java.math.BigInteger
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.cache.annotation.CacheEvict
;
import
cn.ibizlab.businesscentral.core.humanresource.domain.Company
;
import
cn.ibizlab.businesscentral.core.humanresource.filter.CompanySearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[Company] 服务对象接口
*/
public
interface
ICompanyService
extends
IService
<
Company
>{
boolean
create
(
Company
et
)
;
void
createBatch
(
List
<
Company
>
list
)
;
boolean
update
(
Company
et
)
;
void
updateBatch
(
List
<
Company
>
list
)
;
boolean
remove
(
String
key
)
;
void
removeBatch
(
Collection
<
String
>
idList
)
;
Company
get
(
String
key
)
;
Company
getDraft
(
Company
et
)
;
boolean
checkKey
(
Company
et
)
;
boolean
save
(
Company
et
)
;
void
saveBatch
(
List
<
Company
>
list
)
;
Page
<
Company
>
searchDefault
(
CompanySearchContext
context
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
List
<
Company
>
getCompanyByIds
(
List
<
String
>
ids
)
;
List
<
Company
>
getCompanyByEntities
(
List
<
Company
>
entities
)
;
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/service/IEmployeeService.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
service
;
import
java.io.Serializable
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
java.math.BigInteger
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.cache.annotation.CacheEvict
;
import
cn.ibizlab.businesscentral.core.humanresource.domain.Employee
;
import
cn.ibizlab.businesscentral.core.humanresource.filter.EmployeeSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[Employee] 服务对象接口
*/
public
interface
IEmployeeService
extends
IService
<
Employee
>{
boolean
create
(
Employee
et
)
;
void
createBatch
(
List
<
Employee
>
list
)
;
boolean
update
(
Employee
et
)
;
void
updateBatch
(
List
<
Employee
>
list
)
;
boolean
remove
(
String
key
)
;
void
removeBatch
(
Collection
<
String
>
idList
)
;
Employee
get
(
String
key
)
;
Employee
getDraft
(
Employee
et
)
;
boolean
checkKey
(
Employee
et
)
;
boolean
save
(
Employee
et
)
;
void
saveBatch
(
List
<
Employee
>
list
)
;
Page
<
Employee
>
searchDefault
(
EmployeeSearchContext
context
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
List
<
Employee
>
getEmployeeByIds
(
List
<
String
>
ids
)
;
List
<
Employee
>
getEmployeeByEntities
(
List
<
Employee
>
entities
)
;
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/service/ILeaveService.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
service
;
import
java.io.Serializable
;
import
java.sql.Timestamp
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
java.math.BigInteger
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Pageable
;
import
com.alibaba.fastjson.JSONObject
;
import
org.springframework.cache.annotation.CacheEvict
;
import
cn.ibizlab.businesscentral.core.humanresource.domain.Leave
;
import
cn.ibizlab.businesscentral.core.humanresource.filter.LeaveSearchContext
;
import
com.baomidou.mybatisplus.extension.service.IService
;
/**
* 实体[Leave] 服务对象接口
*/
public
interface
ILeaveService
extends
IService
<
Leave
>{
boolean
create
(
Leave
et
)
;
void
createBatch
(
List
<
Leave
>
list
)
;
boolean
update
(
Leave
et
)
;
void
updateBatch
(
List
<
Leave
>
list
)
;
boolean
remove
(
String
key
)
;
void
removeBatch
(
Collection
<
String
>
idList
)
;
Leave
get
(
String
key
)
;
Leave
getDraft
(
Leave
et
)
;
boolean
checkKey
(
Leave
et
)
;
boolean
save
(
Leave
et
)
;
void
saveBatch
(
List
<
Leave
>
list
)
;
Page
<
Leave
>
searchDefault
(
LeaveSearchContext
context
)
;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List
<
JSONObject
>
select
(
String
sql
,
Map
param
);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean
execute
(
String
sql
,
Map
param
);
List
<
Leave
>
getLeaveByIds
(
List
<
String
>
ids
)
;
List
<
Leave
>
getLeaveByEntities
(
List
<
Leave
>
entities
)
;
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/service/impl/AttendanceServiceImpl.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
service
.
impl
;
import
java.io.Serializable
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Set
;
import
java.util.Map
;
import
java.util.HashSet
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
java.util.Objects
;
import
java.util.Optional
;
import
java.math.BigInteger
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cglib.beans.BeanCopier
;
import
org.springframework.stereotype.Service
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.PageImpl
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.context.annotation.Lazy
;
import
cn.ibizlab.businesscentral.core.humanresource.domain.Attendance
;
import
cn.ibizlab.businesscentral.core.humanresource.filter.AttendanceSearchContext
;
import
cn.ibizlab.businesscentral.core.humanresource.service.IAttendanceService
;
import
cn.ibizlab.businesscentral.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.businesscentral.core.humanresource.mapper.AttendanceMapper
;
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
@Service
(
"AttendanceServiceImpl"
)
public
class
AttendanceServiceImpl
extends
ServiceImpl
<
AttendanceMapper
,
Attendance
>
implements
IAttendanceService
{
protected
int
batchSize
=
500
;
@Override
@Transactional
public
boolean
create
(
Attendance
et
)
{
if
(!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
)))
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getAttendanceid
()),
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
Attendance
>
list
)
{
this
.
saveBatch
(
list
,
batchSize
);
}
@Override
@Transactional
public
boolean
update
(
Attendance
et
)
{
if
(!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"attendanceid"
,
et
.
getAttendanceid
())))
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getAttendanceid
()),
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
Attendance
>
list
)
{
updateBatchById
(
list
,
batchSize
);
}
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
}
@Override
@Transactional
public
Attendance
get
(
String
key
)
{
Attendance
et
=
getById
(
key
);
if
(
et
==
null
){
et
=
new
Attendance
();
et
.
setAttendanceid
(
key
);
}
else
{
}
return
et
;
}
@Override
public
Attendance
getDraft
(
Attendance
et
)
{
return
et
;
}
@Override
public
boolean
checkKey
(
Attendance
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getAttendanceid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getAttendanceid
())));
}
@Override
@Transactional
public
boolean
save
(
Attendance
et
)
{
if
(!
saveOrUpdate
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
Attendance
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
}
@Override
public
boolean
saveBatch
(
Collection
<
Attendance
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
Attendance
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
);
}
/**
* 查询集合 DEFAULT
*/
@Override
public
Page
<
Attendance
>
searchDefault
(
AttendanceSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
Attendance
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
());
return
new
PageImpl
<
Attendance
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
());
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
}
@Override
public
List
<
Attendance
>
getAttendanceByIds
(
List
<
String
>
ids
)
{
return
this
.
listByIds
(
ids
);
}
@Override
public
List
<
Attendance
>
getAttendanceByEntities
(
List
<
Attendance
>
entities
)
{
List
ids
=
new
ArrayList
();
for
(
Attendance
entity
:
entities
){
Serializable
id
=
entity
.
getAttendanceid
();
if
(!
ObjectUtils
.
isEmpty
(
id
)){
ids
.
add
(
id
);
}
}
if
(
ids
.
size
()>
0
)
return
this
.
listByIds
(
ids
);
else
return
entities
;
}
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/service/impl/CompanyServiceImpl.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
service
.
impl
;
import
java.io.Serializable
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Set
;
import
java.util.Map
;
import
java.util.HashSet
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
java.util.Objects
;
import
java.util.Optional
;
import
java.math.BigInteger
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cglib.beans.BeanCopier
;
import
org.springframework.stereotype.Service
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.PageImpl
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.context.annotation.Lazy
;
import
cn.ibizlab.businesscentral.core.humanresource.domain.Company
;
import
cn.ibizlab.businesscentral.core.humanresource.filter.CompanySearchContext
;
import
cn.ibizlab.businesscentral.core.humanresource.service.ICompanyService
;
import
cn.ibizlab.businesscentral.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.businesscentral.core.humanresource.mapper.CompanyMapper
;
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
@Service
(
"CompanyServiceImpl"
)
public
class
CompanyServiceImpl
extends
ServiceImpl
<
CompanyMapper
,
Company
>
implements
ICompanyService
{
protected
int
batchSize
=
500
;
@Override
@Transactional
public
boolean
create
(
Company
et
)
{
if
(!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
)))
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getCompanyid
()),
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
Company
>
list
)
{
this
.
saveBatch
(
list
,
batchSize
);
}
@Override
@Transactional
public
boolean
update
(
Company
et
)
{
if
(!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"companyid"
,
et
.
getCompanyid
())))
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getCompanyid
()),
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
Company
>
list
)
{
updateBatchById
(
list
,
batchSize
);
}
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
}
@Override
@Transactional
public
Company
get
(
String
key
)
{
Company
et
=
getById
(
key
);
if
(
et
==
null
){
et
=
new
Company
();
et
.
setCompanyid
(
key
);
}
else
{
}
return
et
;
}
@Override
public
Company
getDraft
(
Company
et
)
{
return
et
;
}
@Override
public
boolean
checkKey
(
Company
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getCompanyid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getCompanyid
())));
}
@Override
@Transactional
public
boolean
save
(
Company
et
)
{
if
(!
saveOrUpdate
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
Company
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
}
@Override
public
boolean
saveBatch
(
Collection
<
Company
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
Company
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
);
}
/**
* 查询集合 DEFAULT
*/
@Override
public
Page
<
Company
>
searchDefault
(
CompanySearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
Company
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
());
return
new
PageImpl
<
Company
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
());
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
}
@Override
public
List
<
Company
>
getCompanyByIds
(
List
<
String
>
ids
)
{
return
this
.
listByIds
(
ids
);
}
@Override
public
List
<
Company
>
getCompanyByEntities
(
List
<
Company
>
entities
)
{
List
ids
=
new
ArrayList
();
for
(
Company
entity
:
entities
){
Serializable
id
=
entity
.
getCompanyid
();
if
(!
ObjectUtils
.
isEmpty
(
id
)){
ids
.
add
(
id
);
}
}
if
(
ids
.
size
()>
0
)
return
this
.
listByIds
(
ids
);
else
return
entities
;
}
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/service/impl/EmployeeServiceImpl.java
0 → 100644
浏览文件 @
03963983
package
cn
.
ibizlab
.
businesscentral
.
core
.
humanresource
.
service
.
impl
;
import
java.io.Serializable
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Set
;
import
java.util.Map
;
import
java.util.HashSet
;
import
java.util.HashMap
;
import
java.util.Collection
;
import
java.util.Objects
;
import
java.util.Optional
;
import
java.math.BigInteger
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.cglib.beans.BeanCopier
;
import
org.springframework.stereotype.Service
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.PageImpl
;
import
org.springframework.data.domain.Pageable
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.context.annotation.Lazy
;
import
cn.ibizlab.businesscentral.core.humanresource.domain.Employee
;
import
cn.ibizlab.businesscentral.core.humanresource.filter.EmployeeSearchContext
;
import
cn.ibizlab.businesscentral.core.humanresource.service.IEmployeeService
;
import
cn.ibizlab.businesscentral.util.helper.CachedBeanCopier
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
cn.ibizlab.businesscentral.core.humanresource.mapper.EmployeeMapper
;
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
@Service
(
"EmployeeServiceImpl"
)
public
class
EmployeeServiceImpl
extends
ServiceImpl
<
EmployeeMapper
,
Employee
>
implements
IEmployeeService
{
protected
int
batchSize
=
500
;
@Override
@Transactional
public
boolean
create
(
Employee
et
)
{
if
(!
this
.
retBool
(
this
.
baseMapper
.
insert
(
et
)))
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getEmployeeid
()),
et
);
return
true
;
}
@Override
public
void
createBatch
(
List
<
Employee
>
list
)
{
this
.
saveBatch
(
list
,
batchSize
);
}
@Override
@Transactional
public
boolean
update
(
Employee
et
)
{
if
(!
update
(
et
,(
Wrapper
)
et
.
getUpdateWrapper
(
true
).
eq
(
"employeeid"
,
et
.
getEmployeeid
())))
return
false
;
CachedBeanCopier
.
copy
(
get
(
et
.
getEmployeeid
()),
et
);
return
true
;
}
@Override
public
void
updateBatch
(
List
<
Employee
>
list
)
{
updateBatchById
(
list
,
batchSize
);
}
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
return
result
;
}
@Override
public
void
removeBatch
(
Collection
<
String
>
idList
)
{
removeByIds
(
idList
);
}
@Override
@Transactional
public
Employee
get
(
String
key
)
{
Employee
et
=
getById
(
key
);
if
(
et
==
null
){
et
=
new
Employee
();
et
.
setEmployeeid
(
key
);
}
else
{
}
return
et
;
}
@Override
public
Employee
getDraft
(
Employee
et
)
{
return
et
;
}
@Override
public
boolean
checkKey
(
Employee
et
)
{
return
(!
ObjectUtils
.
isEmpty
(
et
.
getEmployeeid
()))&&(!
Objects
.
isNull
(
this
.
getById
(
et
.
getEmployeeid
())));
}
@Override
@Transactional
public
boolean
save
(
Employee
et
)
{
if
(!
saveOrUpdate
(
et
))
return
false
;
return
true
;
}
@Override
@Transactional
(
rollbackFor
=
{
Exception
.
class
}
)
public
boolean
saveOrUpdate
(
Employee
et
)
{
if
(
null
==
et
)
{
return
false
;
}
else
{
return
checkKey
(
et
)
?
this
.
update
(
et
)
:
this
.
create
(
et
);
}
}
@Override
public
boolean
saveBatch
(
Collection
<
Employee
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
);
return
true
;
}
@Override
public
void
saveBatch
(
List
<
Employee
>
list
)
{
saveOrUpdateBatch
(
list
,
batchSize
);
}
/**
* 查询集合 DEFAULT
*/
@Override
public
Page
<
Employee
>
searchDefault
(
EmployeeSearchContext
context
)
{
com
.
baomidou
.
mybatisplus
.
extension
.
plugins
.
pagination
.
Page
<
Employee
>
pages
=
baseMapper
.
searchDefault
(
context
.
getPages
(),
context
,
context
.
getSelectCond
());
return
new
PageImpl
<
Employee
>(
pages
.
getRecords
(),
context
.
getPageable
(),
pages
.
getTotal
());
}
@Override
public
List
<
JSONObject
>
select
(
String
sql
,
Map
param
){
return
this
.
baseMapper
.
selectBySQL
(
sql
,
param
);
}
@Override
@Transactional
public
boolean
execute
(
String
sql
,
Map
param
){
if
(
sql
==
null
||
sql
.
isEmpty
())
{
return
false
;
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"insert"
))
{
return
this
.
baseMapper
.
insertBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"update"
))
{
return
this
.
baseMapper
.
updateBySQL
(
sql
,
param
);
}
if
(
sql
.
toLowerCase
().
trim
().
startsWith
(
"delete"
))
{
return
this
.
baseMapper
.
deleteBySQL
(
sql
,
param
);
}
log
.
warn
(
"暂未支持的SQL语法"
);
return
true
;
}
@Override
public
List
<
Employee
>
getEmployeeByIds
(
List
<
String
>
ids
)
{
return
this
.
listByIds
(
ids
);
}
@Override
public
List
<
Employee
>
getEmployeeByEntities
(
List
<
Employee
>
entities
)
{
List
ids
=
new
ArrayList
();
for
(
Employee
entity
:
entities
){
Serializable
id
=
entity
.
getEmployeeid
();
if
(!
ObjectUtils
.
isEmpty
(
id
)){
ids
.
add
(
id
);
}
}
if
(
ids
.
size
()>
0
)
return
this
.
listByIds
(
ids
);
else
return
entities
;
}
}
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/humanresource/service/impl/LeaveServiceImpl.java
0 → 100644
浏览文件 @
03963983
此差异已折叠。
点击以展开。
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/marketing/service/impl/CampaignActivityServiceImpl.java
浏览文件 @
03963983
...
...
@@ -83,8 +83,8 @@ public class CampaignActivityServiceImpl extends ServiceImpl<CampaignActivityMap
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
activitypointerService
.
remove
(
key
);
boolean
result
=
removeById
(
key
);
return
result
;
}
...
...
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/marketing/service/impl/CampaignResponseServiceImpl.java
浏览文件 @
03963983
...
...
@@ -89,8 +89,8 @@ public class CampaignResponseServiceImpl extends ServiceImpl<CampaignResponseMap
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
activitypointerService
.
remove
(
key
);
boolean
result
=
removeById
(
key
);
return
result
;
}
...
...
businesscentral-core/src/main/java/cn/ibizlab/businesscentral/core/service/service/impl/ServiceAppointmentServiceImpl.java
浏览文件 @
03963983
...
...
@@ -92,8 +92,8 @@ public class ServiceAppointmentServiceImpl extends ServiceImpl<ServiceAppointmen
@Override
@Transactional
public
boolean
remove
(
String
key
)
{
boolean
result
=
removeById
(
key
);
activitypointerService
.
remove
(
key
);
boolean
result
=
removeById
(
key
);
return
result
;
}
...
...
businesscentral-core/src/main/resources/liquibase/h2_table.xml
浏览文件 @
03963983
此差异已折叠。
点击以展开。
businesscentral-core/src/main/resources/mapper/humanresource/attendance/AttendanceMapper.xml
0 → 100644
浏览文件 @
03963983
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"cn.ibizlab.businesscentral.core.humanresource.mapper.AttendanceMapper"
>
<!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性-->
<select
id=
"selectById"
resultMap=
"AttendanceResultMap"
databaseId=
"mysql"
>
<![CDATA[select t1.* from (SELECT t1.`ATTENDANCEID`, t1.`ATTENDANCENAME`, t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `ATTENDANCE` t1 ) t1 where attendanceid=#{id}]]>
</select>
<!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 -->
<resultMap
id=
"AttendanceResultMap"
type=
"cn.ibizlab.businesscentral.core.humanresource.domain.Attendance"
autoMapping=
"true"
>
<id
property=
"attendanceid"
column=
"attendanceid"
/>
<!--主键字段映射-->
</resultMap>
<!--数据集合[Default]-->
<select
id=
"searchDefault"
parameterType=
"cn.ibizlab.businesscentral.core.humanresource.filter.AttendanceSearchContext"
resultMap=
"AttendanceResultMap"
>
select t1.* from (
<include
refid=
"Default"
/>
)t1
<where><if
test=
"ew!=null and ew.sqlSegment!=null and !ew.emptyOfWhere"
>
${ew.sqlSegment}
</if></where>
<if
test=
"ew!=null and ew.sqlSegment!=null and ew.emptyOfWhere"
>
${ew.sqlSegment}
</if>
</select>
<!--数据查询[Default]-->
<sql
id=
"Default"
databaseId=
"mysql"
>
<![CDATA[ SELECT t1.`ATTENDANCEID`, t1.`ATTENDANCENAME`, t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `ATTENDANCE` t1
]]>
</sql>
<!--数据查询[View]-->
<sql
id=
"View"
databaseId=
"mysql"
>
<![CDATA[ SELECT t1.`ATTENDANCEID`, t1.`ATTENDANCENAME`, t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `ATTENDANCE` t1
]]>
</sql>
</mapper>
businesscentral-core/src/main/resources/mapper/humanresource/company/CompanyMapper.xml
0 → 100644
浏览文件 @
03963983
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"cn.ibizlab.businesscentral.core.humanresource.mapper.CompanyMapper"
>
<!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性-->
<select
id=
"selectById"
resultMap=
"CompanyResultMap"
databaseId=
"mysql"
>
<![CDATA[select t1.* from (SELECT t1.`COMPANYID`, t1.`COMPANYNAME`, t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `COMPANY` t1 ) t1 where companyid=#{id}]]>
</select>
<!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 -->
<resultMap
id=
"CompanyResultMap"
type=
"cn.ibizlab.businesscentral.core.humanresource.domain.Company"
autoMapping=
"true"
>
<id
property=
"companyid"
column=
"companyid"
/>
<!--主键字段映射-->
</resultMap>
<!--数据集合[Default]-->
<select
id=
"searchDefault"
parameterType=
"cn.ibizlab.businesscentral.core.humanresource.filter.CompanySearchContext"
resultMap=
"CompanyResultMap"
>
select t1.* from (
<include
refid=
"Default"
/>
)t1
<where><if
test=
"ew!=null and ew.sqlSegment!=null and !ew.emptyOfWhere"
>
${ew.sqlSegment}
</if></where>
<if
test=
"ew!=null and ew.sqlSegment!=null and ew.emptyOfWhere"
>
${ew.sqlSegment}
</if>
</select>
<!--数据查询[Default]-->
<sql
id=
"Default"
databaseId=
"mysql"
>
<![CDATA[ SELECT t1.`COMPANYID`, t1.`COMPANYNAME`, t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `COMPANY` t1
]]>
</sql>
<!--数据查询[View]-->
<sql
id=
"View"
databaseId=
"mysql"
>
<![CDATA[ SELECT t1.`COMPANYID`, t1.`COMPANYNAME`, t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `COMPANY` t1
]]>
</sql>
</mapper>
businesscentral-core/src/main/resources/mapper/humanresource/employee/EmployeeMapper.xml
0 → 100644
浏览文件 @
03963983
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"cn.ibizlab.businesscentral.core.humanresource.mapper.EmployeeMapper"
>
<!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性-->
<select
id=
"selectById"
resultMap=
"EmployeeResultMap"
databaseId=
"mysql"
>
<![CDATA[select t1.* from (SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`EMPLOYEEID`, t1.`EMPLOYEENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EMPLOYEE` t1 ) t1 where employeeid=#{id}]]>
</select>
<!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 -->
<resultMap
id=
"EmployeeResultMap"
type=
"cn.ibizlab.businesscentral.core.humanresource.domain.Employee"
autoMapping=
"true"
>
<id
property=
"employeeid"
column=
"employeeid"
/>
<!--主键字段映射-->
</resultMap>
<!--数据集合[Default]-->
<select
id=
"searchDefault"
parameterType=
"cn.ibizlab.businesscentral.core.humanresource.filter.EmployeeSearchContext"
resultMap=
"EmployeeResultMap"
>
select t1.* from (
<include
refid=
"Default"
/>
)t1
<where><if
test=
"ew!=null and ew.sqlSegment!=null and !ew.emptyOfWhere"
>
${ew.sqlSegment}
</if></where>
<if
test=
"ew!=null and ew.sqlSegment!=null and ew.emptyOfWhere"
>
${ew.sqlSegment}
</if>
</select>
<!--数据查询[Default]-->
<sql
id=
"Default"
databaseId=
"mysql"
>
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`EMPLOYEEID`, t1.`EMPLOYEENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EMPLOYEE` t1
]]>
</sql>
<!--数据查询[View]-->
<sql
id=
"View"
databaseId=
"mysql"
>
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`EMPLOYEEID`, t1.`EMPLOYEENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EMPLOYEE` t1
]]>
</sql>
</mapper>
businesscentral-core/src/main/resources/mapper/humanresource/leave/LeaveMapper.xml
0 → 100644
浏览文件 @
03963983
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"cn.ibizlab.businesscentral.core.humanresource.mapper.LeaveMapper"
>
<!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性-->
<select
id=
"selectById"
resultMap=
"LeaveResultMap"
databaseId=
"mysql"
>
<![CDATA[select t1.* from (SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`LEAVEID`, t1.`LEAVENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `LEAVE` t1 ) t1 where leaveid=#{id}]]>
</select>
<!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 -->
<resultMap
id=
"LeaveResultMap"
type=
"cn.ibizlab.businesscentral.core.humanresource.domain.Leave"
autoMapping=
"true"
>
<id
property=
"leaveid"
column=
"leaveid"
/>
<!--主键字段映射-->
</resultMap>
<!--数据集合[Default]-->
<select
id=
"searchDefault"
parameterType=
"cn.ibizlab.businesscentral.core.humanresource.filter.LeaveSearchContext"
resultMap=
"LeaveResultMap"
>
select t1.* from (
<include
refid=
"Default"
/>
)t1
<where><if
test=
"ew!=null and ew.sqlSegment!=null and !ew.emptyOfWhere"
>
${ew.sqlSegment}
</if></where>
<if
test=
"ew!=null and ew.sqlSegment!=null and ew.emptyOfWhere"
>
${ew.sqlSegment}
</if>
</select>
<!--数据查询[Default]-->
<sql
id=
"Default"
databaseId=
"mysql"
>
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`LEAVEID`, t1.`LEAVENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `LEAVE` t1
]]>
</sql>
<!--数据查询[View]-->
<sql
id=
"View"
databaseId=
"mysql"
>
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`LEAVEID`, t1.`LEAVENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `LEAVE` t1
]]>
</sql>
</mapper>
businesscentral-util/src/main/java/cn/ibizlab/businesscentral/util/web/FeignRequestInterceptor.java
浏览文件 @
03963983
...
...
@@ -29,6 +29,8 @@ public class FeignRequestInterceptor implements RequestInterceptor {
if
(
headerNames
!=
null
)
{
while
(
headerNames
.
hasMoreElements
())
{
String
name
=
headerNames
.
nextElement
();
if
(
name
.
equalsIgnoreCase
(
"transfer-encoding"
))
continue
;
String
values
=
request
.
getHeader
(
name
);
requestTemplate
.
header
(
name
,
values
);
}
...
...
编辑
预览
Markdown
格式
0%
请重试
or
添加新附件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录