Commit 61667eab authored by 廖旭伟's avatar 廖旭伟

Merge remote-tracking branch 'origin/master'

parents 3171b9c0 ccdfedf7
...@@ -19,18 +19,23 @@ ...@@ -19,18 +19,23 @@
<span class="ml10">修改为</span> <span class="ml10">修改为</span>
</div> </div>
<div class="mt10"> <div class="mt10">
<!-- 处理异常状态 -->
<!--
<Field label="" v-model="dealParams.processResult" type="select" :enumData="dict.errorStatus"/>
-->
<!-- 处理异常状态 -->
<el-select v-model="dealParams.processResult"> <el-select v-model="dealParams.processResult">
<el-option <el-option
v-for='($label, $value) in dict.errorStatus' v-for='($label, $value) in dict.errorStatus'
:key="$value" :key="$value"
:label="$label" :label="$label"
:value="$label"> :value="$value">
</el-option> </el-option>
</el-select> </el-select>
<!-- 早退/迟到 --> <!-- 早退/迟到 -->
<el-input style="width:220px" placeholder="请输入数字" :maxlength="4" v-model="duration" <el-input style="width:220px" placeholder="请输入数字" :maxlength="4" v-model="duration"
v-if="dealParams.processResult == '迟到'|| dealParams.processResult == '早退'" v-if="dealParams.processResult == '1'|| dealParams.processResult == '2'"
class="ml20" type="number"> class="ml20" type="number">
<template slot="append">分钟</template> <template slot="append">分钟</template>
</el-input> </el-input>
...@@ -44,7 +49,7 @@ ...@@ -44,7 +49,7 @@
<div class="mt20"> <div class="mt20">
<el-button type="primary" @click="saveForm">确定</el-button> <el-button type="primary" @click="saveForm">确定</el-button>
<el-button @click="cancleFn">取消</el-button> <el-button @click="cancleFn">取消</el-button>
</div> </div>
</div> </div>
</el-drawer> </el-drawer>
...@@ -54,7 +59,7 @@ ...@@ -54,7 +59,7 @@
export default { export default {
name: "AttendanceRecordDetail", name: "AttendanceRecordDetail",
created() { created() {
}, },
data() { data() {
return { return {
...@@ -65,6 +70,7 @@ ...@@ -65,6 +70,7 @@
// 是否显示弹出层 // 是否显示弹出层
open: false, open: false,
direction:"rtl", direction:"rtl",
toString: ["processResult"],
// 表单校验 // 表单校验
rules: { rules: {
staffName: [ staffName: [
...@@ -77,6 +83,8 @@ ...@@ -77,6 +83,8 @@
}, },
dealParams:{ dealParams:{
remark:'', remark:'',
errorStatus:null,
durtion:0,
processResult:'', processResult:'',
recordErrorEntities:[],//处理员工 recordErrorEntities:[],//处理员工
processStatus:1//处理状态 processStatus:1//处理状态
...@@ -131,8 +139,10 @@ ...@@ -131,8 +139,10 @@
this.$message.error('请选择处理结果') this.$message.error('请选择处理结果')
return return
} }
if(this.duration && (this.dealParams.processResult == '早退' || this.dealParams.processResult == '迟到')){ this.dealParams.errorStatus=this.dealParams.processResult
this.dealParams.processResult = this.dealParams.processResult + this.duration +'分钟' if(this.duration && (this.dealParams.processResult == '1' || this.dealParams.processResult == '2')){
this.dealParams.processResult =this.dict.errorStatus[this.dealParams.processResult] + this.duration +'分钟'
this.dealParams.durtion=this.duration
} }
// 保存结果处理 // 保存结果处理
this.$post(this.urls.saveUrl,this.dealParams).then(res => { this.$post(this.urls.saveUrl,this.dealParams).then(res => {
...@@ -145,6 +155,8 @@ ...@@ -145,6 +155,8 @@
this.open = false this.open = false
this.dealParams = { this.dealParams = {
remark:'', remark:'',
errorStatus:null,
durtion:0,
processResult:'', processResult:'',
recordErrorEntities:[],//处理员工 recordErrorEntities:[],//处理员工
processStatus:1//处理状态 processStatus:1//处理状态
......
...@@ -91,14 +91,12 @@ ...@@ -91,14 +91,12 @@
{ {
name: "deptId", name: "deptId",
type: "select", type: "select",
label: "全部部门", label: "全部部门"
fuzzy: false
}, },
{ {
name: "groupId", name: "groupId",
type: "select", type: "select",
label: "全部考勤组", label: "全部考勤组"
fuzzy: false
}, },
/* { /* {
name: "classId", name: "classId",
...@@ -109,38 +107,34 @@ ...@@ -109,38 +107,34 @@
{ {
name: "errorStatus", name: "errorStatus",
type: "select", type: "select",
label: "全部异常状态", label: "全部异常状态"
fuzzy: false
}, },
{ {
name: "processStatus", name: "processStatus",
type: "select", type: "select",
label: "全部处理状态", label: "全部处理状态"
fuzzy: false
}, },
{ {
name:'attendanceDateStart', name:'errorDateTimeStart',
type: "date", type: "date",
label: "异常开始时间", label: "异常开始时间"
fuzzy: false
}, },
{ {
name:'attendanceDateEnd', name:'attendanceDateEnd',
type: "date", type: "date",
label: "异常结束时间", label: "errorDateTimeEnd"
fuzzy: false
}, },
{ {
name: "staffName", name: "staffName",
type: "text", type: "text",
label: "员工姓名", label: "员工姓名",
fuzzy: false fuzzy: true
}, },
{ {
name: "phoneNumber", name: "phoneNumber",
type: "text", type: "text",
label: "手机号", label: "手机号",
fuzzy: false fuzzy: true
}, },
], ],
columns: [ columns: [
......
...@@ -24,4 +24,16 @@ public class AttendanceRecordErrorVo extends BaseEntityLong { ...@@ -24,4 +24,16 @@ public class AttendanceRecordErrorVo extends BaseEntityLong {
*/ */
private List<AttendanceRecordErrorEntity> recordErrorEntities; private List<AttendanceRecordErrorEntity> recordErrorEntities;
/** 开始 异常时间 */
private String errorDateTimeStart;
/** 结束 异常时间 */
private String errorDateTimeEnd;
private Integer duration;
} }
...@@ -143,15 +143,19 @@ public class AttendanceRecordErrorController extends BaseCRUDJsonBodyMappingCont ...@@ -143,15 +143,19 @@ public class AttendanceRecordErrorController extends BaseCRUDJsonBodyMappingCont
for (AttendanceRecordErrorEntity recordErrorEntity : entity.getRecordErrorEntities()) { for (AttendanceRecordErrorEntity recordErrorEntity : entity.getRecordErrorEntities()) {
AttendanceRecordErrorEntity updateEntity = new AttendanceRecordErrorEntity(); AttendanceRecordErrorEntity updateEntity = new AttendanceRecordErrorEntity();
updateEntity.setId(recordErrorEntity.getId()); updateEntity.setId(recordErrorEntity.getId());
updateEntity.setErrorDateTime(recordErrorEntity.getErrorDateTime());
updateEntity.setGoOffDateTime(recordErrorEntity.getGoOffDateTime());
updateEntity.setProcessStatus(entity.getProcessStatus()); updateEntity.setProcessStatus(entity.getProcessStatus());
updateEntity.setGoOffDateTime(null);
updateEntity.setProcessResult(entity.getProcessResult()); updateEntity.setProcessResult(entity.getProcessResult());
updateEntity.setStaffId(recordErrorEntity.getStaffId());
updateEntity.setErrorStatus(entity.getErrorStatus());
updateEntity.setOpertor(context.getUser().getRealName()); updateEntity.setOpertor(context.getUser().getRealName());
updateEntity.setOperDateTime(new Date()); updateEntity.setOperDateTime(new Date());
updateEntity.setRemark(entity.getRemark()); updateEntity.setRemark(entity.getRemark());
updateEntity.setUpdateTime(new Date()); updateEntity.setUpdateTime(new Date());
updateEntity.setUpdateUserId(this.getContextUserId(getContext())); updateEntity.setUpdateUserId(this.getContextUserId(getContext()));
this.service.update(recordErrorEntity, getContext()); updateEntity.setDuration(entity.getDuration());
this.service.update(updateEntity, getContext());
} }
for (AttendanceRecordErrorEntity item : entity.getRecordErrorEntities()) { for (AttendanceRecordErrorEntity item : entity.getRecordErrorEntities()) {
...@@ -220,49 +224,6 @@ public class AttendanceRecordErrorController extends BaseCRUDJsonBodyMappingCont ...@@ -220,49 +224,6 @@ public class AttendanceRecordErrorController extends BaseCRUDJsonBodyMappingCont
} }
@Override
protected int saveAfter(AttendanceRecordErrorEntity entity, Map<String, Object> model, Context context) throws AppException {
if (YesNoEnum.YES.getValue() == entity.getProcessStatus()) {
//已经处理,根据错误状态提交考勤绩效
String ruleCode = "";
if (ErrorStatusEnum.早退.getValue() == entity.getErrorStatus()) {
//判断时间差定义
//entity.getErrorStatus()
}
/* AttendSaveReq attendSaveReq = new AttendSaveReq();
attendSaveReq.setAttendanceGroupId(entity.getAttendanceGroupId());
attendSaveReq.setAttendanceGroupName(entity.getAttendanceGroupName());
attendSaveReq.setAttendanceDate(entity.getActualAttendanceDateTime());
attendSaveReq.setErrorTime(entity.getErrorDateTime());
attendSaveReq.setGoOffTimeStr(entity.getGoOrOff());
attendSaveReq.setActualAttendTime();
attendSaveReq.setErrorResult(entity.getRemark());
attendSaveReq.setExt();
attendSaveReq.setWorkNum();
attendSaveReq.setTitle();
attendSaveReq.setHappenTime(entity.getErrorDateTime());
attendSaveReq.setRuleCode(ruleCode);
attendSaveReq.setRuleId();
attendSaveReq.setPhone();
attendSaveReq.setPerformType();
attendSaveReq.setStaffId();*/
// apiWebPerformController.attendSave(attendSaveReq);
}
return super.saveAfter(entity, model, context);
}
@Override @Override
protected int editAfter(Long id, Map<String, Object> model, AttendanceRecordErrorEntity entity, Context context) throws AppException { protected int editAfter(Long id, Map<String, Object> model, AttendanceRecordErrorEntity entity, Context context) throws AppException {
this.addDict(model, "errorStatus", paramService.getParamBySecondOrganize("AttendanceRecordDetail", "goWorkResult")); this.addDict(model, "errorStatus", paramService.getParamBySecondOrganize("AttendanceRecordDetail", "goWorkResult"));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment