修改大屏的多配置
parent
8d2b984abb
commit
b7f45c850c
|
|
@ -0,0 +1,44 @@
|
||||||
|
# yanzhu-bigscreen 项目中调用的 attendance_ubi_data 相关 Mapper 方法
|
||||||
|
|
||||||
|
## 完整对应关系
|
||||||
|
|
||||||
|
|
||||||
|
| 后台 Mapper 方法 | yanzhu-bigscreen 调用位置 | 调用文件 |
|
||||||
|
| ------------------------------------- | -------------------------------- | -------------------------------------- |
|
||||||
|
| **AttendanceUbiDataMapper** | | |
|
||||||
|
| `selectAttendanceUbiDataList[ok]` | `attendanceUbiDataList()` | src/api/detail.js |
|
||||||
|
| | → attendanceInfoDlg.vue#L168 | src/views/detail/attendanceInfoDlg.vue |
|
||||||
|
| **ProProjectInfoSubdeptsUsersMapper** | | |
|
||||||
|
| `groupByCraftTypeByAttendance[ok]` | `groupByCraftTypeByAttendance()` | src/api/detail.js |
|
||||||
|
| | → projectDetail.vue#L715 | src/views/projectDetail.vue |
|
||||||
|
| | → projectLabor.vue#L523 | src/views/projectLabor.vue |
|
||||||
|
| `getWorkerCountGroupByType` | `getWorkerCountGroupByType()` | src/api/labor.js |
|
||||||
|
| | → projectLabor.vue#L230 | src/views/projectLabor.vue |
|
||||||
|
| `getAttendanceAlert[ok]` | `getAttendanceAlert()` | src/api/labor.js |
|
||||||
|
| | → projectLabor.vue#L231 | src/views/projectLabor.vue |
|
||||||
|
| `getRealAttendance[ok]` | `getRealAttendance()` | src/api/labor.js |
|
||||||
|
| | → projectLabor.vue#L229 | src/views/projectLabor.vue |
|
||||||
|
| `groupAttendanceLastWeek` | `groupAttendanceLastWeek()` | src/api/labor.js |
|
||||||
|
| | → projectLabor.vue#L228 | src/views/projectLabor.vue |
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
## yanzhu-bigscreen 中未调用的方法
|
||||||
|
|
||||||
|
以下后台方法虽然在 Mapper 中存在,但 **未在 yanzhu-bigscreen 项目中调用**:
|
||||||
|
|
||||||
|
|
||||||
|
| Mapper | 未调用的方法 |
|
||||||
|
| ------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
|
| **AttendanceUbiDataMapper** | `queryAttendaceInfo`、`queryStatistics`、`queryStatisticsByUserIds`、`selectAttendanceUbiDataById`、`insertAttendanceUbiData`、`updateAttendanceUbiData`、`deleteAttendanceUbiDataById`、`deleteAttendanceUbiDataByIds`、`statsAttendanceDays`、`statsAttendanceView` |
|
||||||
|
| **ProProjectInfoSubdeptsUsersMapper** | `getEduCompletedCount` |
|
||||||
|
| **QuartzProAttendanceDataMapper** | 全部未调用(该 Mapper 属于 job 模块) |
|
||||||
|
|
||||||
|
## 汇总
|
||||||
|
|
||||||
|
|
||||||
|
| 状态 | 数量 |
|
||||||
|
| --------------------------- | --------- |
|
||||||
|
| **yanzhu-bigscreen 已调用** | 6 个方法 |
|
||||||
|
| **未调用** | 11 个方法 |
|
||||||
|
|
@ -12328,7 +12328,7 @@
|
||||||
},
|
},
|
||||||
"node_modules/process": {
|
"node_modules/process": {
|
||||||
"version": "0.11.10",
|
"version": "0.11.10",
|
||||||
"resolved": "https://registry.npmmirror.com/process/-/process-0.11.10.tgz",
|
"resolved": "https://registry.npmjs.org/process/-/process-0.11.10.tgz",
|
||||||
"integrity": "sha512-cdGef/drWFoydD1JsMzuFf8100nZl+GT+yacc2bEced5f9Rjk4z+WtFUTBu9PhOi9j/jfmBPu0mMEY4wIdAF8A==",
|
"integrity": "sha512-cdGef/drWFoydD1JsMzuFf8100nZl+GT+yacc2bEced5f9Rjk4z+WtFUTBu9PhOi9j/jfmBPu0mMEY4wIdAF8A==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
|
|
|
||||||
|
|
@ -91,31 +91,20 @@ module.exports = defineConfig({
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
configureWebpack: (config) => {
|
configureWebpack: (config) => {
|
||||||
if (process.env.NODE_ENV === "production") {
|
|
||||||
config.externals = {
|
config.externals = {
|
||||||
vue: "Vue",
|
vue: "Vue",
|
||||||
};
|
};
|
||||||
}
|
|
||||||
|
|
||||||
// 为了解决 ezuikit-js 中的 require is not defined 问题
|
// 为了解决 ezuikit-js 中的 require is not defined 问题
|
||||||
if (!config.resolve) {
|
if (!config.resolve) {
|
||||||
config.resolve = {};
|
config.resolve = {};
|
||||||
}
|
}
|
||||||
if (!config.resolve.fallback) {
|
if (!config.resolve.alias) {
|
||||||
config.resolve.fallback = {};
|
config.resolve.alias = {};
|
||||||
}
|
}
|
||||||
|
|
||||||
Object.assign(config.resolve.fallback, {
|
// 使用 ezuikit.js 的 UMD 版本,避免 require is not defined 错误
|
||||||
"path": require.resolve("path-browserify"),
|
config.resolve.alias['ezuikit-js'] = require.resolve('ezuikit-js/ezuikit.js');
|
||||||
"buffer": require.resolve("buffer"),
|
|
||||||
"stream": require.resolve("stream-browserify"),
|
|
||||||
"crypto": require.resolve("crypto-browserify"),
|
|
||||||
"http": require.resolve("stream-http"),
|
|
||||||
"https": require.resolve("https-browserify"),
|
|
||||||
"os": require.resolve("os-browserify"),
|
|
||||||
"url": require.resolve("url/"),
|
|
||||||
"zlib": require.resolve("browserify-zlib")
|
|
||||||
});
|
|
||||||
|
|
||||||
// 添加插件提供全局变量
|
// 添加插件提供全局变量
|
||||||
config.plugins = (config.plugins || []).concat([
|
config.plugins = (config.plugins || []).concat([
|
||||||
|
|
|
||||||
|
|
@ -6882,7 +6882,7 @@ process-nextick-args@~2.0.0:
|
||||||
|
|
||||||
process@^0.11.10, process@0.11.10:
|
process@^0.11.10, process@0.11.10:
|
||||||
version "0.11.10"
|
version "0.11.10"
|
||||||
resolved "https://registry.npmmirror.com/process/-/process-0.11.10.tgz"
|
resolved "https://registry.npmjs.org/process/-/process-0.11.10.tgz"
|
||||||
integrity sha512-cdGef/drWFoydD1JsMzuFf8100nZl+GT+yacc2bEced5f9Rjk4z+WtFUTBu9PhOi9j/jfmBPu0mMEY4wIdAF8A==
|
integrity sha512-cdGef/drWFoydD1JsMzuFf8100nZl+GT+yacc2bEced5f9Rjk4z+WtFUTBu9PhOi9j/jfmBPu0mMEY4wIdAF8A==
|
||||||
|
|
||||||
progress-webpack-plugin@^1.0.12:
|
progress-webpack-plugin@^1.0.12:
|
||||||
|
|
|
||||||
|
|
@ -38,6 +38,8 @@ public class ProProjectInfoSubdeptsUsers extends BaseEntity
|
||||||
/** 分包单位 */
|
/** 分包单位 */
|
||||||
private Long subDeptId;
|
private Long subDeptId;
|
||||||
|
|
||||||
|
private Long cfgId;
|
||||||
|
|
||||||
/** 分包单位名称 */
|
/** 分包单位名称 */
|
||||||
private String subDeptName;
|
private String subDeptName;
|
||||||
|
|
||||||
|
|
@ -203,6 +205,14 @@ public class ProProjectInfoSubdeptsUsers extends BaseEntity
|
||||||
/** 数据来源 */
|
/** 数据来源 */
|
||||||
private String source;
|
private String source;
|
||||||
|
|
||||||
|
public Long getCfgId() {
|
||||||
|
return cfgId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCfgId(Long cfgId) {
|
||||||
|
this.cfgId = cfgId;
|
||||||
|
}
|
||||||
|
|
||||||
public Long getId() {
|
public Long getId() {
|
||||||
return id;
|
return id;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -190,7 +190,7 @@ public interface ProProjectInfoSubdeptsUsersMapper
|
||||||
* @param prjId
|
* @param prjId
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
List<ProProjectInfoSubdeptsUsers> getAttendanceAlert(@Param("projectId")Long prjId);
|
List<ProProjectInfoSubdeptsUsers> getAttendanceAlert(@Param("projectId")Long prjId,@Param("cfgId")Long cfgId);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 完成三级安全教育人数
|
* 完成三级安全教育人数
|
||||||
|
|
|
||||||
|
|
@ -132,7 +132,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
|
||||||
<select id="selectDefaultCfgByProjectAndCom" resultMap="AttendanceCfgResult">
|
<select id="selectDefaultCfgByProjectAndCom" resultMap="AttendanceCfgResult">
|
||||||
<include refid="selectAttendanceCfgVo"/>
|
<include refid="selectAttendanceCfgVo"/>
|
||||||
where ac.project_id = #{projectId} and ac.com_id = #{comId} and ac.is_default = 1 and ac.enabled = 1
|
where ac.project_id = #{projectId} and
|
||||||
|
ac.is_default = 1 and ac.enabled = 1
|
||||||
|
<if test="comId != null"> and ac.com_id = #{comId}</if>
|
||||||
limit 1
|
limit 1
|
||||||
</select>
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
@ -367,8 +367,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<where>
|
<where>
|
||||||
<if test="comId != null">and com_id = #{comId}</if>
|
<if test="comId != null">and com_id = #{comId}</if>
|
||||||
<if test="projectId != null">and project_id = #{projectId}</if>
|
<if test="projectId != null">and project_id = #{projectId}</if>
|
||||||
|
<if test="cfgId!=null and cfgId!=0">and cfg_id=#{cfgId}</if>
|
||||||
<if test="createTime != null">
|
<if test="createTime != null">
|
||||||
and (date(inTime)= date( #{createTime}) or date(outTime)=date( #{createTime})))</if>
|
and (date(inTime)= date( #{createTime}) or date(outTime)=date( #{createTime})))</if>
|
||||||
|
|
||||||
</where>
|
</where>
|
||||||
GROUP BY
|
GROUP BY
|
||||||
craft_type
|
craft_type
|
||||||
|
|
@ -483,6 +485,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
join (
|
join (
|
||||||
select userId,max(ifNull(inTime,outTime)) dt from attendance_ubi_data
|
select userId,max(ifNull(inTime,outTime)) dt from attendance_ubi_data
|
||||||
where projectid=#{projectId} and is_del!=1
|
where projectid=#{projectId} and is_del!=1
|
||||||
|
<if test="cfgId != null and cfgId!=0"> and cfg_id=#{cfgId}</if>
|
||||||
group by userId
|
group by userId
|
||||||
order by max(ifNull(inTime,outTime)) ) att on us.id=att.userId
|
order by max(ifNull(inTime,outTime)) ) att on us.id=att.userId
|
||||||
</select>
|
</select>
|
||||||
|
|
|
||||||
|
|
@ -112,6 +112,7 @@ public class LaborController extends BaseController {
|
||||||
@GetMapping("/getAttendanceAlert/{type}/{prjId}")
|
@GetMapping("/getAttendanceAlert/{type}/{prjId}")
|
||||||
public AjaxResult getAttendanceAlert(@PathVariable("type")String type, @PathVariable("prjId") Long prjId){
|
public AjaxResult getAttendanceAlert(@PathVariable("type")String type, @PathVariable("prjId") Long prjId){
|
||||||
if("uni".equals(type.toLowerCase())){
|
if("uni".equals(type.toLowerCase())){
|
||||||
|
|
||||||
List<ProProjectInfoSubdeptsUsers> sList=proProjectInfoSubdeptsUsersService.getAttendanceAlert(prjId);
|
List<ProProjectInfoSubdeptsUsers> sList=proProjectInfoSubdeptsUsersService.getAttendanceAlert(prjId);
|
||||||
return AjaxResult.success(sList);
|
return AjaxResult.success(sList);
|
||||||
}else{
|
}else{
|
||||||
|
|
|
||||||
|
|
@ -73,6 +73,12 @@ public class AttendanceUbiDataServiceImpl implements IAttendanceUbiDataService
|
||||||
@Override
|
@Override
|
||||||
public List<AttendanceUbiData> selectAttendanceUbiDataList(AttendanceUbiData attendanceUbiData)
|
public List<AttendanceUbiData> selectAttendanceUbiDataList(AttendanceUbiData attendanceUbiData)
|
||||||
{
|
{
|
||||||
|
if(attendanceUbiData.getCfgId()==null){
|
||||||
|
AttendanceCfg cfg=attendanceCfgService.getDefaultAttendanceCfg(attendanceUbiData.getProjectId(),attendanceUbiData.getComId());
|
||||||
|
if(cfg!=null){
|
||||||
|
attendanceUbiData.setCfgId(cfg.getId());
|
||||||
|
}
|
||||||
|
}
|
||||||
return attendanceUbiDataMapper.selectAttendanceUbiDataList(attendanceUbiData);
|
return attendanceUbiDataMapper.selectAttendanceUbiDataList(attendanceUbiData);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -135,6 +141,12 @@ public class AttendanceUbiDataServiceImpl implements IAttendanceUbiDataService
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<AttendanceUbiData> queryStatistics(AttendanceUbiData attendanceUbiData) {
|
public List<AttendanceUbiData> queryStatistics(AttendanceUbiData attendanceUbiData) {
|
||||||
|
if(attendanceUbiData.getCfgId()==null){
|
||||||
|
AttendanceCfg cfg=attendanceCfgService.getDefaultAttendanceCfg(attendanceUbiData.getProjectId(),attendanceUbiData.getComId());
|
||||||
|
if(cfg!=null){
|
||||||
|
attendanceUbiData.setCfgId(cfg.getId());
|
||||||
|
}
|
||||||
|
}
|
||||||
return attendanceUbiDataMapper.queryStatistics(attendanceUbiData);
|
return attendanceUbiDataMapper.queryStatistics(attendanceUbiData);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -17,6 +17,7 @@ import com.yanzhu.manage.config.ProfileConfig;
|
||||||
import com.yanzhu.manage.domain.*;
|
import com.yanzhu.manage.domain.*;
|
||||||
import com.yanzhu.manage.enums.*;
|
import com.yanzhu.manage.enums.*;
|
||||||
import com.yanzhu.manage.mapper.*;
|
import com.yanzhu.manage.mapper.*;
|
||||||
|
import com.yanzhu.manage.service.IAttendanceCfgService;
|
||||||
import com.yanzhu.manage.service.IProProjectInfoSubdeptsUsersService;
|
import com.yanzhu.manage.service.IProProjectInfoSubdeptsUsersService;
|
||||||
import com.yanzhu.manage.service.IProUserInoutRecordService;
|
import com.yanzhu.manage.service.IProUserInoutRecordService;
|
||||||
import com.yanzhu.manage.service.IUniService;
|
import com.yanzhu.manage.service.IUniService;
|
||||||
|
|
@ -95,6 +96,9 @@ public class ProProjectInfoSubdeptsUsersServiceImpl implements IProProjectInfoSu
|
||||||
@Autowired
|
@Autowired
|
||||||
private IBaiduFaceService baiduFaceService;
|
private IBaiduFaceService baiduFaceService;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private IAttendanceCfgService attendanceCfgService;
|
||||||
|
|
||||||
|
|
||||||
private static final Logger log = LoggerFactory.getLogger(ProProjectInfoSubdeptsUsersServiceImpl.class);
|
private static final Logger log = LoggerFactory.getLogger(ProProjectInfoSubdeptsUsersServiceImpl.class);
|
||||||
|
|
||||||
|
|
@ -1577,6 +1581,10 @@ public class ProProjectInfoSubdeptsUsersServiceImpl implements IProProjectInfoSu
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public List<ProProjectInfoSubdeptsUsers> groupByCraftTypeByAttendance(ProProjectInfoSubdeptsUsers where) {
|
public List<ProProjectInfoSubdeptsUsers> groupByCraftTypeByAttendance(ProProjectInfoSubdeptsUsers where) {
|
||||||
|
AttendanceCfg cfg=attendanceCfgService.getDefaultAttendanceCfg(where.getProjectId(),where.getComId());
|
||||||
|
if(cfg!=null){
|
||||||
|
where.setCfgId(cfg.getId());
|
||||||
|
}
|
||||||
return proProjectInfoSubdeptsUsersMapper.groupByCraftTypeByAttendance(where);
|
return proProjectInfoSubdeptsUsersMapper.groupByCraftTypeByAttendance(where);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1851,7 +1859,9 @@ public class ProProjectInfoSubdeptsUsersServiceImpl implements IProProjectInfoSu
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public List<ProProjectInfoSubdeptsUsers> getAttendanceAlert(Long prjId) {
|
public List<ProProjectInfoSubdeptsUsers> getAttendanceAlert(Long prjId) {
|
||||||
return proProjectInfoSubdeptsUsersMapper.getAttendanceAlert(prjId);
|
AttendanceCfg cfg= attendanceCfgService.getDefaultAttendanceCfg(prjId,null);
|
||||||
|
Long cfgId=cfg!=null?cfg.getId():null;
|
||||||
|
return proProjectInfoSubdeptsUsersMapper.getAttendanceAlert(prjId,cfgId);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
|
|
@ -168,10 +168,8 @@
|
||||||
<el-switch v-model="form.enabled" :active-value="1" :inactive-value="0" />
|
<el-switch v-model="form.enabled" :active-value="1" :inactive-value="0" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="是否默认" prop="isDefault">
|
<el-form-item label="是否默认" prop="isDefault">
|
||||||
<el-tag :type="form.isDefault === 1 ? 'success' : 'info'" v-if="form.id">
|
|
||||||
{{ form.isDefault === 1 ? '是' : '否' }}
|
<el-switch v-model="form.isDefault" :active-value="1" :inactive-value="0" />
|
||||||
</el-tag>
|
|
||||||
<el-switch v-model="form.isDefault" :active-value="1" :inactive-value="0" v-if="!form.id" />
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<template #footer>
|
<template #footer>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue