Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
attendance-performance-platform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
attendance-performance-platform
Commits
178557b8
Commit
178557b8
authored
Aug 22, 2023
by
廖旭伟
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/master'
parents
cb473df3
2e76bc11
Changes
11
Show whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
146 additions
and
35 deletions
+146
-35
attendance-performance-manager-ui/admin/src/components/SearchForm.vue
...erformance-manager-ui/admin/src/components/SearchForm.vue
+3
-3
attendance-performance-manager-ui/admin/src/views/attendance/record/error/drawershow.vue
...ui/admin/src/views/attendance/record/error/drawershow.vue
+18
-6
attendance-performance-manager-ui/admin/src/views/attendance/record/hik/list.vue
...manager-ui/admin/src/views/attendance/record/hik/list.vue
+5
-4
attendance-performance-manager-ui/admin/src/views/attendance/record/list.vue
...nce-manager-ui/admin/src/views/attendance/record/list.vue
+6
-0
attendance-performance-manager-ui/admin/src/views/attendance/stat/list.vue
...mance-manager-ui/admin/src/views/attendance/stat/list.vue
+1
-0
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/model/AttendanceRecordEntity.java
...s/xhx/module/attendance/model/AttendanceRecordEntity.java
+1
-1
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/model/vo/AttendanceRecordVo.java
...ls/xhx/module/attendance/model/vo/AttendanceRecordVo.java
+2
-2
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/service/work/FixWorkOtherAttendance.java
...odule/attendance/service/work/FixWorkOtherAttendance.java
+7
-9
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/web/AttendanceRecordController.java
...xhx/module/attendance/web/AttendanceRecordController.java
+95
-4
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/web/AttendanceRecordErrorController.java
...odule/attendance/web/AttendanceRecordErrorController.java
+4
-4
attendance-performance-manager/src/main/resources/sqlmap/module/attendance/AttendanceStatMapperExt.xml
...rces/sqlmap/module/attendance/AttendanceStatMapperExt.xml
+4
-2
No files found.
attendance-performance-manager-ui/admin/src/components/SearchForm.vue
View file @
178557b8
...
@@ -38,11 +38,11 @@
...
@@ -38,11 +38,11 @@
v-if=
"item.type === 'select'"
v-if=
"item.type === 'select'"
:placeholder=
"'请选择' + item.label"
:placeholder=
"'请选择' + item.label"
>
>
<el-option
<
!--
<
el-option
label=
"
全部
"
label=
""
value=
""
value=
""
v-if=
"!item.multiple && !item.notShowAll"
v-if=
"!item.multiple && !item.notShowAll"
></el-option>
></el-option>
-->
<el-option
<el-option
:label=
"label"
:label=
"label"
:value=
"value"
:value=
"value"
...
...
attendance-performance-manager-ui/admin/src/views/attendance/record/error/drawershow.vue
View file @
178557b8
...
@@ -63,7 +63,9 @@
...
@@ -63,7 +63,9 @@
</div>
</div>
</div>
</div>
<div
class=
"mt20"
>
<div
class=
"mt20"
>
<el-button
type=
"primary"
@
click=
"saveForm"
>
确定
</el-button>
<el-button
type=
"primary"
@
click=
"saveForm"
:loading=
"btnLoading"
>
确定
</el-button
>
<el-button
@
click=
"cancleFn"
>
取消
</el-button>
<el-button
@
click=
"cancleFn"
>
取消
</el-button>
</div>
</div>
</div>
</div>
...
@@ -110,6 +112,7 @@ export default {
...
@@ -110,6 +112,7 @@ export default {
errorStatus
:
""
,
errorStatus
:
""
,
},
},
duration
:
""
,
duration
:
""
,
btnLoading
:
false
,
};
};
},
},
...
@@ -162,11 +165,20 @@ export default {
...
@@ -162,11 +165,20 @@ export default {
"
分钟
"
;
"
分钟
"
;
this
.
dealParams
.
durtion
=
this
.
duration
;
this
.
dealParams
.
durtion
=
this
.
duration
;
}
}
this
.
btnLoading
=
true
;
// 保存结果处理
// 保存结果处理
this
.
$post
(
this
.
urls
.
saveUrl
,
this
.
dealParams
).
then
((
res
)
=>
{
this
.
$post
(
this
.
urls
.
saveUrl
,
this
.
dealParams
)
.
then
((
res
)
=>
{
this
.
btnLoading
=
false
;
if
(
res
.
code
==
1
)
{
if
(
res
.
code
==
1
)
{
this
.
cancleFn
();
this
.
cancleFn
();
this
.
$message
.
success
(
res
.
msg
);
}
}
})
.
catch
((
error
)
=>
{
this
.
btnLoading
=
false
;
console
.
log
(
error
);
this
.
$message
.
error
(
error
.
message
);
});
});
},
},
cancleFn
()
{
cancleFn
()
{
...
...
attendance-performance-manager-ui/admin/src/views/attendance/record/hik/list.vue
View file @
178557b8
...
@@ -220,13 +220,10 @@ export default {
...
@@ -220,13 +220,10 @@ export default {
},
},
/** 导出Excel */
/** 导出Excel */
doExport
()
{
doExport
()
{
console
.
log
(
"
isExport:
"
,
this
.
isExport
==
true
)
if
(
this
.
isExport
==
true
)
{
if
(
this
.
isExport
==
true
)
{
console
.
log
(
"
isExport:
"
,
this
.
isExport
)
console
.
log
(
"
isExport:
"
,
this
.
isExport
)
this
.
$message
.
info
(
"
考勤数据正在导出中,请勿重复点击!
"
)
this
.
$message
.
info
(
"
考勤数据正在导出中,请勿重复点击!
"
)
return
false
;
return
false
;
}
else
{
console
.
log
(
"
isExport11:
"
,
this
.
isExport
)
}
}
this
.
isExport
=
true
;
this
.
isExport
=
true
;
...
@@ -241,6 +238,8 @@ export default {
...
@@ -241,6 +238,8 @@ export default {
params
[
"
idList
"
]
=
this
.
selection
;
params
[
"
idList
"
]
=
this
.
selection
;
}
}
let
that
=
this
;
this
.
$download
(
this
.
$download
(
"
/attendance/record/hik/exportExcel
"
,
"
/attendance/record/hik/exportExcel
"
,
{
{
...
@@ -248,7 +247,9 @@ export default {
...
@@ -248,7 +247,9 @@ export default {
},
},
{
type
:
"
excel
"
}
{
type
:
"
excel
"
}
)
)
.
then
(()
=>
(
this
.
isExport
=
false
))
.
then
(()
=>
{
console
.
log
(
"
isExport222:
"
,
this
.
isExport
)
that
.
isExport
=
false
})
.
catch
((
error
)
=>
{
.
catch
((
error
)
=>
{
this
.
isExport
=
false
;
this
.
isExport
=
false
;
this
.
$message
.
error
(
error
.
message
);
this
.
$message
.
error
(
error
.
message
);
...
...
attendance-performance-manager-ui/admin/src/views/attendance/record/list.vue
View file @
178557b8
...
@@ -486,6 +486,12 @@ export default {
...
@@ -486,6 +486,12 @@ export default {
label
:
"
班次
"
,
label
:
"
班次
"
,
fuzzy
:
false
,
fuzzy
:
false
,
},
},
{
name
:
"
punchResult
"
,
type
:
"
select
"
,
label
:
"
打卡结果
"
,
fuzzy
:
false
,
},
{
{
name
:
"
attendanceDateStart
"
,
name
:
"
attendanceDateStart
"
,
type
:
"
date
"
,
type
:
"
date
"
,
...
...
attendance-performance-manager-ui/admin/src/views/attendance/stat/list.vue
View file @
178557b8
...
@@ -202,6 +202,7 @@ export default {
...
@@ -202,6 +202,7 @@ export default {
params
[
value
.
name
]
=
this
.
query
[
value
.
name
];
params
[
value
.
name
]
=
this
.
query
[
value
.
name
];
}
}
}
}
if
(
this
.
selection
.
length
>
0
)
{
if
(
this
.
selection
.
length
>
0
)
{
params
[
"
idList
"
]
=
this
.
selection
;
params
[
"
idList
"
]
=
this
.
selection
;
}
}
...
...
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/model/AttendanceRecordEntity.java
View file @
178557b8
...
@@ -64,7 +64,7 @@ public class AttendanceRecordEntity extends AttendanceRecordVo {
...
@@ -64,7 +64,7 @@ public class AttendanceRecordEntity extends AttendanceRecordVo {
/**
/**
* 打卡日期
* 打卡日期
*/
*/
@Excel
(
name
=
"打卡日期"
,
width
=
30
,
dateFormat
=
"yyyy-MM-dd
HH:mm:ss
"
)
@Excel
(
name
=
"打卡日期"
,
width
=
30
,
dateFormat
=
"yyyy-MM-dd"
)
private
Date
attendanceDate
;
private
Date
attendanceDate
;
/**
/**
* 备注
* 备注
...
...
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/model/vo/AttendanceRecordVo.java
View file @
178557b8
...
@@ -19,13 +19,13 @@ public class AttendanceRecordVo extends BaseEntityLong {
...
@@ -19,13 +19,13 @@ public class AttendanceRecordVo extends BaseEntityLong {
private
List
<
AttendanceGroupFixedworkSpecialVo
>
list
;
private
List
<
AttendanceGroupFixedworkSpecialVo
>
list
;
@Excels
({
/*
@Excels({
@Excel(name = "上班打卡时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss", targetAttr = "goWorkDate", type = Excel.Type.EXPORT),
@Excel(name = "上班打卡时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss", targetAttr = "goWorkDate", type = Excel.Type.EXPORT),
@Excel(name = "上班打卡结果", readConverterExp = "1=正常,2=请假,3=缺卡,4=迟到,5=早退", targetAttr = "goWorkResult", type = Excel.Type.EXPORT),
@Excel(name = "上班打卡结果", readConverterExp = "1=正常,2=请假,3=缺卡,4=迟到,5=早退", targetAttr = "goWorkResult", type = Excel.Type.EXPORT),
@Excel(name = "下班打卡时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss", targetAttr = "offWorkDate", type = Excel.Type.EXPORT),
@Excel(name = "下班打卡时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss", targetAttr = "offWorkDate", type = Excel.Type.EXPORT),
@Excel(name = "下班打卡结果", readConverterExp = "1=正常,2=请假,3=缺卡,4=迟到,5=早退", targetAttr = "offWorkResult", type = Excel.Type.EXPORT)
@Excel(name = "下班打卡结果", readConverterExp = "1=正常,2=请假,3=缺卡,4=迟到,5=早退", targetAttr = "offWorkResult", type = Excel.Type.EXPORT)
})
})
*/
private
AttendanceRecordDetailEntity
attendanceRecordDetailEntity
;
private
AttendanceRecordDetailEntity
attendanceRecordDetailEntity
;
/**
/**
...
...
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/service/work/FixWorkOtherAttendance.java
View file @
178557b8
...
@@ -314,7 +314,7 @@ public class FixWorkOtherAttendance extends AttendanceWorkAbstract {
...
@@ -314,7 +314,7 @@ public class FixWorkOtherAttendance extends AttendanceWorkAbstract {
errorQuery
.
setCreateTimeStart
(
DateUtil
.
today
());
errorQuery
.
setCreateTimeStart
(
DateUtil
.
today
());
errorQuery
.
setCreateTimeEnd
(
DateUtil
.
today
());
errorQuery
.
setCreateTimeEnd
(
DateUtil
.
today
());
errorQuery
.
setStaffId
(
attendanceRecordEntity
.
getStaffId
());
errorQuery
.
setStaffId
(
attendanceRecordEntity
.
getStaffId
());
errorQuery
.
setProcessStatus
(
ProcessStatusEnum
.
未处理
.
getValue
());
errorQuery
.
setProcessStatus
(
YesNoEnum
.
NO
.
getValue
());
Long
[]
errorIds
=
errorService
.
find
(
errorQuery
).
stream
().
map
(
i
->
i
.
getId
()).
toArray
(
Long
[]::
new
);
Long
[]
errorIds
=
errorService
.
find
(
errorQuery
).
stream
().
map
(
i
->
i
.
getId
()).
toArray
(
Long
[]::
new
);
...
@@ -323,23 +323,21 @@ public class FixWorkOtherAttendance extends AttendanceWorkAbstract {
...
@@ -323,23 +323,21 @@ public class FixWorkOtherAttendance extends AttendanceWorkAbstract {
}
}
for
(
AttendanceRecordErrorEntity
errorEntity
:
errorEntityList
)
{
for
(
AttendanceRecordErrorEntity
errorEntity
:
errorEntityList
)
{
errorService
.
save
(
errorEntity
,
context
);
//查看是否存在相同的异常记录,如果存在 则不添加
/* //查看是否存在相同的异常记录,如果存在 则不添加
errorQuery
=
new
AttendanceRecordErrorQuery
();
errorQuery
=
new
AttendanceRecordErrorQuery
();
errorQuery
.
setShiftsId
(
errorEntity
.
getShiftsId
());
errorQuery
.
setShiftsId
(
errorEntity
.
getShiftsId
());
errorQuery
.
setGoOffDateTime
(
errorEntity
.
getErrorDateTime
());
errorQuery
.
setGoOffDateTime
(
errorEntity
.
getErrorDateTime
());
errorQuery
.
setStaffId
(
errorEntity
.
getStaffId
());
errorQuery
.
setStaffId
(
errorEntity
.
getStaffId
());
errorQuery.setProcessStatus(
ProcessStatusEnum.未处理
.getValue());
errorQuery
.
setProcessStatus
(
YesNoEnum
.
YES
.
getValue
());
AttendanceRecordErrorEntity
attendanceRecordErrorEntity
=
errorService
.
selectOne
(
errorQuery
,
context
);
AttendanceRecordErrorEntity
attendanceRecordErrorEntity
=
errorService
.
selectOne
(
errorQuery
,
context
);
if
(
ObjectUtils
.
isEmpty
(
attendanceRecordErrorEntity
))
{
if
(
ObjectUtils
.
isEmpty
(
attendanceRecordErrorEntity
))
{
errorService
.
save
(
errorEntity
,
context
);
errorService
.
save
(
errorEntity
,
context
);
}
else
{
}
else
{
errorEntity.setId(attendanceRecordErrorEntity.getId());
/*
errorEntity.setId(attendanceRecordErrorEntity.getId());
errorService.update(errorEntity,context);
errorService.update(errorEntity,context);
*/
log.info("已经存在相同的
异常记录,更新
保存!");
log
.
info
(
"已经存在相同的
已处理异常记录,不
保存!"
);
}
*/
}
}
}
}
}
}
}
...
...
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/web/AttendanceRecordController.java
View file @
178557b8
package
com.mortals.xhx.module.attendance.web
;
package
com.mortals.xhx.module.attendance.web
;
import
cn.hutool.core.date.DateUtil
;
import
cn.hutool.core.util.ReflectUtil
;
import
cn.hutool.core.util.ReflectUtil
;
import
com.alibaba.fastjson.JSONObject
;
import
com.alibaba.fastjson.JSONObject
;
import
com.mortals.framework.annotation.Excel
;
import
com.mortals.framework.annotation.Excel
;
import
com.mortals.framework.common.Rest
;
import
com.mortals.framework.common.Rest
;
import
com.mortals.framework.exception.AppException
;
import
com.mortals.framework.exception.AppException
;
import
com.mortals.framework.model.OrderCol
;
import
com.mortals.framework.model.OrderCol
;
import
com.mortals.framework.model.PageInfo
;
import
com.mortals.framework.service.ICacheService
;
import
com.mortals.framework.service.ICacheService
;
import
com.mortals.framework.util.StringUtils
;
import
com.mortals.framework.utils.ReflectUtils
;
import
com.mortals.framework.utils.ServletUtils
;
import
com.mortals.framework.utils.ServletUtils
;
import
com.mortals.framework.utils.poi.ExcelUtil
;
import
com.mortals.framework.web.BaseCRUDJsonBodyMappingController
;
import
com.mortals.framework.web.BaseCRUDJsonBodyMappingController
;
import
com.mortals.xhx.base.system.param.service.ParamService
;
import
com.mortals.xhx.base.system.param.service.ParamService
;
import
com.mortals.xhx.base.system.upload.service.UploadService
;
import
com.mortals.xhx.base.system.upload.service.UploadService
;
...
@@ -27,6 +32,7 @@ import com.mortals.xhx.module.dept.service.DeptService;
...
@@ -27,6 +32,7 @@ import com.mortals.xhx.module.dept.service.DeptService;
import
com.mortals.xhx.module.perform.model.PerformAttendAppealEntity
;
import
com.mortals.xhx.module.perform.model.PerformAttendAppealEntity
;
import
com.mortals.xhx.module.perform.model.vo.AppealInfo
;
import
com.mortals.xhx.module.perform.model.vo.AppealInfo
;
import
com.mortals.xhx.module.staff.service.StaffService
;
import
com.mortals.xhx.module.staff.service.StaffService
;
import
org.apache.poi.ss.formula.functions.T
;
import
org.checkerframework.checker.units.qual.A
;
import
org.checkerframework.checker.units.qual.A
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
@@ -100,14 +106,15 @@ public class AttendanceRecordController extends BaseCRUDJsonBodyMappingControlle
...
@@ -100,14 +106,15 @@ public class AttendanceRecordController extends BaseCRUDJsonBodyMappingControlle
@Override
@Override
public
void
doExportBefore
(
Context
context
,
AttendanceRecordEntity
query
,
List
<
String
>
properties
)
throws
AppException
{
public
void
doExportBefore
(
Context
context
,
AttendanceRecordEntity
query
,
List
<
String
>
properties
)
throws
AppException
{
String
bool
=
cacheService
.
get
(
RedisCacheKeys
.
getRecordExportLockKey
());
String
bool
=
cacheService
.
get
(
RedisCacheKeys
.
getRecordExportLockKey
());
if
(!
ObjectUtils
.
isEmpty
(
bool
))
{
if
(!
ObjectUtils
.
isEmpty
(
bool
))
{
throw
new
AppException
(
"每日数据正在导出中,请稍后再试!"
);
throw
new
AppException
(
"每日数据正在导出中,请稍后再试!"
);
}
}
cacheService
.
set
(
RedisCacheKeys
.
getRecordExportLockKey
(),
"111"
,
120L
);
cacheService
.
set
(
RedisCacheKeys
.
getRecordExportLockKey
(),
"111"
,
120L
);
query
.
setOrderColList
(
Arrays
.
asList
(
new
OrderCol
(
"attendanceDate"
,
OrderCol
.
DESCENDING
),
new
OrderCol
(
"staffName"
,
OrderCol
.
DESCENDING
)));
if
(!
ObjectUtils
.
isEmpty
(
query
.
getProperties
()))
{
if
(!
ObjectUtils
.
isEmpty
(
query
.
getProperties
()))
{
/* //通过属性转换为注解
/* //通过属性转换为注解
List<Field> tempFields = new ArrayList<>();
List<Field> tempFields = new ArrayList<>();
...
@@ -127,7 +134,7 @@ public class AttendanceRecordController extends BaseCRUDJsonBodyMappingControlle
...
@@ -127,7 +134,7 @@ public class AttendanceRecordController extends BaseCRUDJsonBodyMappingControlle
@Override
@Override
public
void
doExportAfter
(
Context
context
,
List
<
AttendanceRecordEntity
>
list
)
throws
AppException
{
public
void
doExportAfter
(
Context
context
,
List
<
AttendanceRecordEntity
>
list
)
throws
AppException
{
ArrayList
<
AttendanceRecordEntity
>
attendanceRecordEntities
=
new
ArrayList
<>();
/*
ArrayList<AttendanceRecordEntity> attendanceRecordEntities = new ArrayList<>();
for (AttendanceRecordEntity recordEntity : list) {
for (AttendanceRecordEntity recordEntity : list) {
List<AttendanceRecordDetailEntity> attendanceRecordDetailList = recordEntity.getAttendanceRecordDetailList();
List<AttendanceRecordDetailEntity> attendanceRecordDetailList = recordEntity.getAttendanceRecordDetailList();
...
@@ -150,9 +157,93 @@ public class AttendanceRecordController extends BaseCRUDJsonBodyMappingControlle
...
@@ -150,9 +157,93 @@ public class AttendanceRecordController extends BaseCRUDJsonBodyMappingControlle
if (!ObjectUtils.isEmpty(attendanceRecordEntities)) {
if (!ObjectUtils.isEmpty(attendanceRecordEntities)) {
list.clear();
list.clear();
list.addAll(attendanceRecordEntities);
list.addAll(attendanceRecordEntities);
}*/
}
}
@Override
public
void
exportExcel
(
@RequestBody
AttendanceRecordEntity
query
)
{
Context
context
=
getContext
();
String
busiDesc
=
"导出"
+
getModuleDesc
();
List
<
String
>
properties
=
new
ArrayList
<>();
try
{
doExportBefore
(
context
,
query
,
properties
);
String
name
=
StringUtils
.
trim
(
this
.
moduleDesc
);
if
(
StringUtils
.
isEmpty
(
name
))
{
name
=
System
.
currentTimeMillis
()
+
""
;
}
String
fileName
=
name
+
".xlsx"
;
PageInfo
pageInfo
=
new
PageInfo
(-
1
);
List
<
AttendanceRecordEntity
>
list
=
this
.
service
.
find
(
query
,
pageInfo
,
getContext
()).
getList
();
Class
<
AttendanceRecordEntity
>
tClass
=
ReflectUtils
.
getClassGenricType
(
getClass
(),
1
);
ExcelUtil
<
AttendanceRecordEntity
,
Long
>
util
=
new
ExcelUtil
<>(
tClass
);
doExportAfter
(
context
,
list
);
//求详细最大数量
final
Integer
colSize
=
list
.
parallelStream
().
map
(
i
->
i
.
getAttendanceRecordDetailList
().
size
()).
max
(
Comparator
.
comparing
(
Integer:
:
intValue
)).
orElseGet
(()
->
0
);
//构建动态list
List
<
List
<
Map
<
String
,
Object
>>>
lists
=
list
.
stream
().
map
(
item
->
{
List
<
AttendanceRecordDetailEntity
>
attendanceRecordDetailList
=
item
.
getAttendanceRecordDetailList
();
List
<
Map
<
String
,
Object
>>
mapList
=
new
ArrayList
<>();
for
(
int
i
=
0
;
i
<
colSize
;
i
++)
{
if
(
attendanceRecordDetailList
.
size
()
>
i
)
{
AttendanceRecordDetailEntity
detailEntity
=
attendanceRecordDetailList
.
get
(
i
);
//生成上班 结果 下班 结果 4个map
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"name"
,
String
.
format
(
"上班打卡时间%d"
,
i
+
1
));
map
.
put
(
"value"
,
DateUtil
.
formatDateTime
(
detailEntity
.
getGoWorkDate
()));
mapList
.
add
(
map
);
map
=
new
HashMap
<>();
map
.
put
(
"name"
,
String
.
format
(
"上班打卡结果%d"
,
i
+
1
));
map
.
put
(
"value"
,
GoWorkResultEnum
.
getByValue
(
detailEntity
.
getGoWorkResult
()).
getDesc
());
mapList
.
add
(
map
);
map
=
new
HashMap
<>();
map
.
put
(
"name"
,
String
.
format
(
"下班打卡时间%d"
,
i
+
1
));
map
.
put
(
"value"
,
DateUtil
.
formatDateTime
(
detailEntity
.
getOffWorkDate
()));
mapList
.
add
(
map
);
map
=
new
HashMap
<>();
map
.
put
(
"name"
,
String
.
format
(
"下班打卡结果%d"
,
i
+
1
));
map
.
put
(
"value"
,
OffWorkResultEnum
.
getByValue
(
detailEntity
.
getOffWorkResult
()).
getDesc
());
mapList
.
add
(
map
);
}
else
{
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"name"
,
String
.
format
(
"上班打卡时间%d"
,
i
+
1
));
map
.
put
(
"value"
,
"--"
);
mapList
.
add
(
map
);
map
=
new
HashMap
<>();
map
.
put
(
"name"
,
String
.
format
(
"上班打卡结果%d"
,
i
+
1
));
map
.
put
(
"value"
,
"--"
);
mapList
.
add
(
map
);
map
=
new
HashMap
<>();
map
.
put
(
"name"
,
String
.
format
(
"下班打卡时间%d"
,
i
+
1
));
map
.
put
(
"value"
,
"--"
);
mapList
.
add
(
map
);
map
=
new
HashMap
<>();
map
.
put
(
"name"
,
String
.
format
(
"下班打卡结果%d"
,
i
+
1
));
map
.
put
(
"value"
,
"--"
);
mapList
.
add
(
map
);
}
}
}
return
mapList
;
}).
collect
(
Collectors
.
toList
());
byte
[]
data
=
util
.
exportExcel
(
list
,
properties
,
lists
,
name
);
// byte[] data = util.exportExcel(list, properties, name);
doExportFileAfter
(
data
,
query
,
context
);
this
.
responseStream
(
response
,
data
,
fileName
);
recordSysLog
(
request
,
busiDesc
+
" 【成功】"
);
}
catch
(
Exception
e
)
{
this
.
doException
(
request
,
"导出异常"
,
new
HashMap
<>(),
e
);
}
}
@Override
@Override
public
void
doExportFileAfter
(
byte
[]
data
,
AttendanceRecordEntity
query
,
Context
context
)
throws
AppException
{
public
void
doExportFileAfter
(
byte
[]
data
,
AttendanceRecordEntity
query
,
Context
context
)
throws
AppException
{
...
...
attendance-performance-manager/src/main/java/com/mortals/xhx/module/attendance/web/AttendanceRecordErrorController.java
View file @
178557b8
...
@@ -104,7 +104,7 @@ public class AttendanceRecordErrorController extends BaseCRUDJsonBodyMappingCont
...
@@ -104,7 +104,7 @@ public class AttendanceRecordErrorController extends BaseCRUDJsonBodyMappingCont
query
.
setProcessResult
(
"已撤销处理"
);
query
.
setProcessResult
(
"已撤销处理"
);
errorService
.
update
(
query
);
errorService
.
update
(
query
);
DateUtils
.
convertTime2Str
(
query
.
getErrorDateTime
().
getTime
(),
DateUtils
.
P_yyyy_MM_dd
);
/*
DateUtils.convertTime2Str(query.getErrorDateTime().getTime(), DateUtils.P_yyyy_MM_dd);
AttendanceRecordQuery attendanceRecordQuery = new AttendanceRecordQuery();
AttendanceRecordQuery attendanceRecordQuery = new AttendanceRecordQuery();
attendanceRecordQuery.setStaffId(query.getStaffId());
attendanceRecordQuery.setStaffId(query.getStaffId());
attendanceRecordQuery.setAttendanceDateStart(DateUtils.convertTime2Str(query.getErrorDateTime().getTime(), DateUtils.P_yyyy_MM_dd));
attendanceRecordQuery.setAttendanceDateStart(DateUtils.convertTime2Str(query.getErrorDateTime().getTime(), DateUtils.P_yyyy_MM_dd));
...
@@ -132,7 +132,7 @@ public class AttendanceRecordErrorController extends BaseCRUDJsonBodyMappingCont
...
@@ -132,7 +132,7 @@ public class AttendanceRecordErrorController extends BaseCRUDJsonBodyMappingCont
recordDetailEntity.setOffWorkResult(5);
recordDetailEntity.setOffWorkResult(5);
}
}
}
}
}
}
*/
return
Rest
.
ok
();
return
Rest
.
ok
();
}
}
...
@@ -162,7 +162,7 @@ public class AttendanceRecordErrorController extends BaseCRUDJsonBodyMappingCont
...
@@ -162,7 +162,7 @@ public class AttendanceRecordErrorController extends BaseCRUDJsonBodyMappingCont
entity
.
setId
(
recordErrorEntity
.
getId
());
entity
.
setId
(
recordErrorEntity
.
getId
());
}
}
for
(
AttendanceRecordErrorEntity
item
:
entity
.
getRecordErrorEntities
())
{
/*
for (AttendanceRecordErrorEntity item : entity.getRecordErrorEntities()) {
DateUtils.convertTime2Str(item.getErrorDateTime().getTime(), DateUtils.P_yyyy_MM_dd);
DateUtils.convertTime2Str(item.getErrorDateTime().getTime(), DateUtils.P_yyyy_MM_dd);
AttendanceRecordQuery attendanceRecordQuery = new AttendanceRecordQuery();
AttendanceRecordQuery attendanceRecordQuery = new AttendanceRecordQuery();
attendanceRecordQuery.setStaffId(item.getStaffId());
attendanceRecordQuery.setStaffId(item.getStaffId());
...
@@ -223,7 +223,7 @@ public class AttendanceRecordErrorController extends BaseCRUDJsonBodyMappingCont
...
@@ -223,7 +223,7 @@ public class AttendanceRecordErrorController extends BaseCRUDJsonBodyMappingCont
}
}
attendanceRecordDetailService.update(recordDetailEntity);
attendanceRecordDetailService.update(recordDetailEntity);
}
}
}
}
*/
super
.
saveBefore
(
entity
,
model
,
context
);
super
.
saveBefore
(
entity
,
model
,
context
);
}
}
...
...
attendance-performance-manager/src/main/resources/sqlmap/module/attendance/AttendanceStatMapperExt.xml
View file @
178557b8
...
@@ -5,6 +5,7 @@
...
@@ -5,6 +5,7 @@
<select
id=
"getListExt"
parameterType=
"com.mortals.xhx.module.attendance.model.vo.AttendanceSummaryQuery"
resultMap=
"AttendanceStatEntity-Map"
>
<select
id=
"getListExt"
parameterType=
"com.mortals.xhx.module.attendance.model.vo.AttendanceSummaryQuery"
resultMap=
"AttendanceStatEntity-Map"
>
SELECT * FROM (
SELECT * FROM (
SELECT
SELECT
s.id,
s.staffId,
s.staffId,
s.staffName,
s.staffName,
s.deptId,
s.deptId,
...
@@ -52,8 +53,8 @@
...
@@ -52,8 +53,8 @@
<if
test=
"staffName != null and staffName!=''"
>
AND s.staffName like #{staffName}
</if>
<if
test=
"staffName != null and staffName!=''"
>
AND s.staffName like #{staffName}
</if>
<if
test=
"phoneNumer != null and phoneNumer!=''"
>
AND s.phoneNumer like #{phoneNumer}
</if>
<if
test=
"phoneNumer != null and phoneNumer!=''"
>
AND s.phoneNumer like #{phoneNumer}
</if>
<if
test=
"deptId != null and deptId!=''"
>
AND s.deptId = #{deptId}
</if>
<if
test=
"deptId != null and deptId!=''"
>
AND s.deptId = #{deptId}
</if>
<if
test=
"idList != null and idList.
length
>0"
>
<if
test=
"idList != null and idList.
size
>0"
>
and
a
.id in
and
s
.id in
<foreach
collection=
"idList"
open=
"("
close=
")"
index=
"index"
item=
"item"
separator=
","
>
<foreach
collection=
"idList"
open=
"("
close=
")"
index=
"index"
item=
"item"
separator=
","
>
#{item}
#{item}
</foreach>
</foreach>
...
@@ -70,6 +71,7 @@
...
@@ -70,6 +71,7 @@
<select
id=
"getListCountExt"
parameterType=
"com.mortals.xhx.module.attendance.model.vo.AttendanceSummaryQuery"
resultType=
"int"
>
<select
id=
"getListCountExt"
parameterType=
"com.mortals.xhx.module.attendance.model.vo.AttendanceSummaryQuery"
resultType=
"int"
>
SELECT count(1) FROM (
SELECT count(1) FROM (
SELECT
SELECT
s.id,
s.staffId,
s.staffId,
s.staffName,
s.staffName,
s.deptId,
s.deptId,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment