Commit 0a6111bb by 杨林龙

开发 1.9.0 设备调频功能展示

1 parent 5fd999a7
......@@ -56,6 +56,9 @@ public class DeviceFreqService {
@Autowired
private VehicleSharedMapper vehicleSharedMapper;
@Autowired
private UserService userService;
public void adjFreq(DeviceWorkBO model) {
// 更新上个设备调频记录
updateDeviceFreqRecord(model.getSn());
......@@ -96,8 +99,10 @@ public class DeviceFreqService {
// 插入用户类型
if (UserConstants.RolePermitCastType.wxShared.getCode().equals(ShieldContextHolder.getRolePermissionType())) {
df.setUserType(2);
df.setCreatedBy(userService.getCTerminalUserId());
} else {
df.setUserType(1);
df.setCreatedBy(ShieldContextHolder.getUserId());
}
df.setCreatedBy(ShieldContextHolder.getUserId());
df.setCreatedDate(new Date());
......@@ -134,10 +139,11 @@ public class DeviceFreqService {
// 插入用户类型
if (UserConstants.RolePermitCastType.wxShared.getCode().equals(ShieldContextHolder.getRolePermissionType())) {
df.setUserType(2);
df.setCreatedBy(userService.getCTerminalUserId());
} else {
df.setUserType(1);
df.setCreatedBy(ShieldContextHolder.getUserId());
}
df.setCreatedBy(ShieldContextHolder.getUserId());
df.setCreatedDate(new Date());
df.setUpdatedDate(new Date());
//设置操作渠道 4 新E盾系统 5 小程序
......
......@@ -59,6 +59,8 @@
LEFT(tdf.created_date, 19) AS createTime,
tdf.freq_type AS freqType,
tdf.channel ,
tcuar.user_id AS wxUserId,
tcula.avatar AS wxAvatar,
IF(tdf.user_type = 1, tu.username, tcula.username) AS operation,
tdf.catching_timer AS catchingTimer,
tdf.timer ,
......@@ -70,7 +72,7 @@
TIMESTAMPDIFF(MINUTE, tdf.created_date, tdf.updated_date) AS diffMinuteTime,
TIMESTAMPDIFF(DAY, tdf.created_date, tdf.updated_date) AS diffDayTime
FROM t_device_freq tdf
LEFT JOIN t_vehicle tv ON tv.id = tdf.vehicle_id
LEFT JOIN t_vehicle tv ON tv.id = tdf.vehicle_id
LEFT JOIN t_user tu ON tu.id = tdf.created_by
LEFT JOIN t_cust_user_auth_rel tcuar ON tcuar.user_id = tdf.created_by and tcuar.auth_type = 'local'
LEFT JOIN t_cust_user_local_account tcula ON tcula.auth_id = tcuar.auth_id
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!