Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
D
device-back
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
1
议题
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
Matrix
device-back
Commits
6d3dfc57
提交
6d3dfc57
authored
4月 08, 2021
作者:
133
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[清退 退役 用户] 代码提交
上级
a76386c1
全部展开
显示空白字符变更
内嵌
并排
正在显示
17 个修改的文件
包含
163 行增加
和
62 行删除
+163
-62
DeviceDecommissioningBusinessService.java
...sioning/service/DeviceDecommissioningBusinessService.java
+1
-0
DeviceDecommissioningBusinessServiceImpl.java
...ervice/impl/DeviceDecommissioningBusinessServiceImpl.java
+25
-5
DeviceLibraryDao.java
.../tykj/dev/device/library/repository/DeviceLibraryDao.java
+1
-1
DeviceLibraryServiceImpl.java
...device/library/service/impl/DeviceLibraryServiceImpl.java
+1
-1
pom.xml
dev-loss/pom.xml
+5
-0
DeviceLossVo.java
...java/com/tykj/dev/device/loss/entity/vo/DeviceLossVo.java
+1
-0
DeviceLossService.java
...a/com/tykj/dev/device/loss/service/DeviceLossService.java
+12
-0
LossBillSelectServiceImpl.java
...v/device/loss/service/impl/LossBillSelectServiceImpl.java
+3
-1
LossBillServiceImpl.java
...ykj/dev/device/loss/service/impl/LossBillServiceImpl.java
+8
-0
StatusEnum.java
...misc/src/main/java/com/tykj/dev/misc/base/StatusEnum.java
+1
-16
ScrapBusinessServiceImpl.java
...v/device/scrap/service/impl/ScrapBusinessServiceImpl.java
+25
-2
DeviceRepel.java
...m/tykj/dev/device/sendback/entity/domain/DeviceRepel.java
+12
-0
SupervisorVo.java
.../com/tykj/dev/device/sendback/entity/vo/SupervisorVo.java
+25
-0
RepelBusinessService.java
...ykj/dev/device/sendback/service/RepelBusinessService.java
+5
-0
RepelBusinessServiceImpl.java
...evice/sendback/service/impl/RepelBusinessServiceImpl.java
+0
-0
RepelQueryServiceImpl.java
...v/device/sendback/service/impl/RepelQueryServiceImpl.java
+38
-10
UserController.java
...kj/dev/device/user/subject/controller/UserController.java
+0
-26
没有找到文件。
dev-decommissioning/src/main/java/com/tykj/dev/device/decommissioning/service/DeviceDecommissioningBusinessService.java
浏览文件 @
6d3dfc57
...
@@ -12,6 +12,7 @@ import com.tykj.dev.device.decommissioning.entity.vo.StorageDeviceDevommissiong;
...
@@ -12,6 +12,7 @@ import com.tykj.dev.device.decommissioning.entity.vo.StorageDeviceDevommissiong;
* @createTime 2021年03月29日 16:37:00
* @createTime 2021年03月29日 16:37:00
*/
*/
public
interface
DeviceDecommissioningBusinessService
{
public
interface
DeviceDecommissioningBusinessService
{
/**
/**
* 生成省中办退役的任务
* 生成省中办退役的任务
* @param userId 用户id
* @param userId 用户id
...
...
dev-decommissioning/src/main/java/com/tykj/dev/device/decommissioning/service/impl/DeviceDecommissioningBusinessServiceImpl.java
浏览文件 @
6d3dfc57
package
com
.
tykj
.
dev
.
device
.
decommissioning
.
service
.
impl
;
package
com
.
tykj
.
dev
.
device
.
decommissioning
.
service
.
impl
;
import
com.fasterxml.jackson.core.type.TypeReference
;
import
com.sun.org.apache.bcel.internal.generic.NEW
;
import
com.tykj.dev.config.base.DeviceLifeStatus
;
import
com.tykj.dev.config.base.DeviceLifeStatus
;
import
com.tykj.dev.device.decommissioning.entity.DeviceDecommissioningDetail
;
import
com.tykj.dev.device.decommissioning.entity.DeviceDecommissioningDetail
;
import
com.tykj.dev.device.decommissioning.entity.vo.DecommissioningOrderOutData
;
import
com.tykj.dev.device.decommissioning.entity.vo.DecommissioningOrderOutData
;
...
@@ -12,6 +14,7 @@ import com.tykj.dev.device.library.service.DeviceLogService;
...
@@ -12,6 +14,7 @@ import com.tykj.dev.device.library.service.DeviceLogService;
import
com.tykj.dev.device.library.subject.Dto.DeviceLogDto
;
import
com.tykj.dev.device.library.subject.Dto.DeviceLogDto
;
import
com.tykj.dev.device.library.subject.domin.DeviceLibrary
;
import
com.tykj.dev.device.library.subject.domin.DeviceLibrary
;
import
com.tykj.dev.device.library.subject.domin.DeviceLog
;
import
com.tykj.dev.device.library.subject.domin.DeviceLog
;
import
com.tykj.dev.device.library.subject.vo.ScriptSaveVo
;
import
com.tykj.dev.device.task.service.TaskService
;
import
com.tykj.dev.device.task.service.TaskService
;
import
com.tykj.dev.device.task.subject.bto.TaskBto
;
import
com.tykj.dev.device.task.subject.bto.TaskBto
;
import
com.tykj.dev.device.user.read.service.MessageService
;
import
com.tykj.dev.device.user.read.service.MessageService
;
...
@@ -22,9 +25,11 @@ import com.tykj.dev.device.user.subject.service.UnitsService;
...
@@ -22,9 +25,11 @@ import com.tykj.dev.device.user.subject.service.UnitsService;
import
com.tykj.dev.device.user.subject.service.UserService
;
import
com.tykj.dev.device.user.subject.service.UserService
;
import
com.tykj.dev.misc.base.BusinessEnum
;
import
com.tykj.dev.misc.base.BusinessEnum
;
import
com.tykj.dev.misc.base.StatusEnum
;
import
com.tykj.dev.misc.base.StatusEnum
;
import
com.tykj.dev.misc.utils.DeviceSeqUtil
;
import
com.tykj.dev.misc.utils.JacksonUtil
;
import
com.tykj.dev.misc.utils.JacksonUtil
;
import
com.tykj.dev.misc.utils.StringUtils
;
import
com.tykj.dev.misc.utils.StringUtils
;
import
com.tykj.dev.misc.utils.TaskDisposeUtil
;
import
com.tykj.dev.misc.utils.TaskDisposeUtil
;
import
jdk.nashorn.internal.ir.IfNode
;
import
lombok.extern.slf4j.Slf4j
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
...
@@ -81,7 +86,17 @@ public class DeviceDecommissioningBusinessServiceImpl implements DeviceDecommiss
...
@@ -81,7 +86,17 @@ public class DeviceDecommissioningBusinessServiceImpl implements DeviceDecommiss
deviceDecommissioningDetail
.
setNum
(
"NO:第"
+
LocalDateTime
.
now
().
getYear
()+
"QT"
+
deviceDecommissioningDetail
.
getId
());
deviceDecommissioningDetail
.
setNum
(
"NO:第"
+
LocalDateTime
.
now
().
getYear
()+
"QT"
+
deviceDecommissioningDetail
.
getId
());
deviceDecommissioningDetail
.
setDeviceLibraryEntities
(
findInvoleDevice
(
deviceDecommissioningDetail
.
getDeviceIds
()));
deviceDecommissioningDetail
.
setDeviceLibraryEntities
(
findInvoleDevice
(
deviceDecommissioningDetail
.
getDeviceIds
()));
deviceDecommissioningDetailService
.
saveDeviceDecommissioningDetail
(
deviceDecommissioningDetail
);
deviceDecommissioningDetailService
.
saveDeviceDecommissioningDetail
(
deviceDecommissioningDetail
);
deviceLibraryDao
.
upDateLeftStatus
(
DeviceLifeStatus
.
RETIRED
.
id
,
decommissioningOrderOutData
.
getDevIds
());
List
<
ScriptSaveVo
>
scriptSaveVos
=
decommissioningOrderOutData
.
getScriptSaveVos
();
List
<
String
>
seqNumbers
=
new
ArrayList
<>();
scriptSaveVos
.
forEach
(
scriptSaveVo
->
{
if
(
scriptSaveVo
.
getSeqNumber
()!=
null
){
seqNumbers
.
addAll
(
DeviceSeqUtil
.
selectDeviceSeqs
(
scriptSaveVo
.
getSeqNumber
()));
}
}
);
deviceLibraryDao
.
upDateSeqNumbersLeftStatus
(
DeviceLifeStatus
.
RETIRED
.
id
,
seqNumbers
);
TaskBto
taskBto
=
sendOutSuperior
(
units
.
getUnitId
(),
deviceDecommissioningDetail
.
getId
());
TaskBto
taskBto
=
sendOutSuperior
(
units
.
getUnitId
(),
deviceDecommissioningDetail
.
getId
());
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"发起退役任务,待上传回执单据"
,
gainThisUser
(
user
.
getUserId
(),
user
.
getUnitsId
())));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"发起退役任务,待上传回执单据"
,
gainThisUser
(
user
.
getUserId
(),
user
.
getUnitsId
())));
return
deviceDecommissioningDetail
;
return
deviceDecommissioningDetail
;
...
@@ -110,7 +125,15 @@ public class DeviceDecommissioningBusinessServiceImpl implements DeviceDecommiss
...
@@ -110,7 +125,15 @@ public class DeviceDecommissioningBusinessServiceImpl implements DeviceDecommiss
}
}
taskService
.
moveToEnd
(
taskBto
);
taskService
.
moveToEnd
(
taskBto
);
deviceDecommissioningDetail
.
setRepelStatus
(
2
);
deviceDecommissioningDetail
.
setRepelStatus
(
2
);
deviceLibraryDao
.
upDateLeftStatusAndUnitNameAndLockStatus
(
DeviceLifeStatus
.
RETIRE
.
id
,
deviceDecommissioningDetail
.
getReceiveUnit
(),
0
,
StringUtils
.
stringToList
(
deviceDecommissioningDetail
.
getDeviceIds
()));
List
<
String
>
seqNumbers
=
new
ArrayList
<>();
JacksonUtil
.
readValue
(
deviceDecommissioningDetail
.
getScriptJson
(),
new
TypeReference
<
List
<
ScriptSaveVo
>>()
{}).
forEach
(
scriptSaveVo
->
{
if
(
scriptSaveVo
.
getSeqNumber
()!=
null
){
seqNumbers
.
addAll
(
DeviceSeqUtil
.
selectDeviceSeqs
(
scriptSaveVo
.
getSeqNumber
()));
}
}
);
deviceLibraryDao
.
upDateSeqNumbersLeftStatusAndUnitNameAndLockStatus
(
DeviceLifeStatus
.
RETIRE
.
id
,
deviceDecommissioningDetail
.
getReceiveUnit
(),
0
,
seqNumbers
);
deviceDecommissioningDetailService
.
saveDeviceDecommissioningDetail
(
deviceDecommissioningDetail
);
deviceDecommissioningDetailService
.
saveDeviceDecommissioningDetail
(
deviceDecommissioningDetail
);
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"退役任务回执单据上传成功任务结束"
,
gainThisUser
(
user
.
getUserId
(),
user
.
getUnitsId
())));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"退役任务回执单据上传成功任务结束"
,
gainThisUser
(
user
.
getUserId
(),
user
.
getUnitsId
())));
}
}
...
@@ -130,9 +153,6 @@ public class DeviceDecommissioningBusinessServiceImpl implements DeviceDecommiss
...
@@ -130,9 +153,6 @@ public class DeviceDecommissioningBusinessServiceImpl implements DeviceDecommiss
/**
/**
* 异步添加装备日志
* 异步添加装备日志
* @param deviceLibraries
* @param remark
* @param userId
*/
*/
private
void
devLogAdd
(
List
<
DeviceLibrary
>
deviceLibraries
,
String
remark
,
Integer
userId
){
private
void
devLogAdd
(
List
<
DeviceLibrary
>
deviceLibraries
,
String
remark
,
Integer
userId
){
List
<
DeviceLog
>
logDtos
=
new
ArrayList
<>();
List
<
DeviceLog
>
logDtos
=
new
ArrayList
<>();
...
...
dev-library/src/main/java/com/tykj/dev/device/library/repository/DeviceLibraryDao.java
浏览文件 @
6d3dfc57
...
@@ -104,7 +104,7 @@ public interface DeviceLibraryDao extends JpaRepository<DeviceLibrary, Integer>,
...
@@ -104,7 +104,7 @@ public interface DeviceLibraryDao extends JpaRepository<DeviceLibrary, Integer>,
@Transactional
@Transactional
@Modifying
@Modifying
@Query
(
"update DeviceLibrary o set o.lifeStatus = :lifeStatus ,o.ownUnit = :unitName where o.id in :idList"
)
@Query
(
"update DeviceLibrary o set o.lifeStatus = :lifeStatus ,o.ownUnit = :unitName
,o.locationUnit = :unitName
where o.id in :idList"
)
int
upDateLeftStatusAndOwnUnitName
(
Integer
lifeStatus
,
String
unitName
,
@Param
(
"idList"
)
List
<
Integer
>
idList
);
int
upDateLeftStatusAndOwnUnitName
(
Integer
lifeStatus
,
String
unitName
,
@Param
(
"idList"
)
List
<
Integer
>
idList
);
List
<
DeviceLibrary
>
findAllByLifeStatus
(
Integer
status
);
List
<
DeviceLibrary
>
findAllByLifeStatus
(
Integer
status
);
...
...
dev-library/src/main/java/com/tykj/dev/device/library/service/impl/DeviceLibraryServiceImpl.java
浏览文件 @
6d3dfc57
...
@@ -434,7 +434,7 @@ public class DeviceLibraryServiceImpl implements DeviceLibraryService {
...
@@ -434,7 +434,7 @@ public class DeviceLibraryServiceImpl implements DeviceLibraryService {
public
void
isInStockOrWaitRetired
(
List
<
Integer
>
ids
)
{
public
void
isInStockOrWaitRetired
(
List
<
Integer
>
ids
)
{
ids
.
forEach
(
integer
->
{
ids
.
forEach
(
integer
->
{
DeviceLibrary
deviceLibrary
=
getOne
(
integer
);
DeviceLibrary
deviceLibrary
=
getOne
(
integer
);
if
(
deviceLibrary
.
getLifeStatus
()!=
2
&&
deviceLibrary
.
getLifeStatus
()!=
15
&&
!
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
SEND_BACK
.
id
)
){
if
(
deviceLibrary
.
getLifeStatus
()!=
2
&&
deviceLibrary
.
getLifeStatus
()!=
15
&&
deviceLibrary
.
getLifeStatus
()!=
DeviceLifeStatus
.
SEND_BACK
.
id
){
throw
new
ApiException
(
ResponseEntity
.
status
(
303
).
body
(
"序列号"
+
deviceLibrary
.
getSeqNumber
()+
"的装备已被其他专管员操作"
));
throw
new
ApiException
(
ResponseEntity
.
status
(
303
).
body
(
"序列号"
+
deviceLibrary
.
getSeqNumber
()+
"的装备已被其他专管员操作"
));
}
}
});
});
...
...
dev-loss/pom.xml
浏览文件 @
6d3dfc57
...
@@ -12,18 +12,22 @@
...
@@ -12,18 +12,22 @@
<artifactId>
dev-loss
</artifactId>
<artifactId>
dev-loss
</artifactId>
<dependencies>
<dependencies>
<dependency>
<dependency>
<groupId>
com.tykj
</groupId>
<groupId>
com.tykj
</groupId>
<artifactId>
dev-library
</artifactId>
<artifactId>
dev-library
</artifactId>
</dependency>
</dependency>
<dependency>
<dependency>
<groupId>
com.tykj
</groupId>
<groupId>
com.tykj
</groupId>
<artifactId>
dev-task
</artifactId>
<artifactId>
dev-task
</artifactId>
</dependency>
</dependency>
<dependency>
<dependency>
<groupId>
com.tykj
</groupId>
<groupId>
com.tykj
</groupId>
<artifactId>
dev-packing
</artifactId>
<artifactId>
dev-packing
</artifactId>
</dependency>
</dependency>
<dependency>
<dependency>
<groupId>
com.tykj.dev
</groupId>
<groupId>
com.tykj.dev
</groupId>
<artifactId>
misc
</artifactId>
<artifactId>
misc
</artifactId>
...
@@ -33,6 +37,7 @@
...
@@ -33,6 +37,7 @@
<groupId>
com.tykj
</groupId>
<groupId>
com.tykj
</groupId>
<artifactId>
dev-file
</artifactId>
<artifactId>
dev-file
</artifactId>
</dependency>
</dependency>
<dependency>
<dependency>
<groupId>
com.tykj.dev
</groupId>
<groupId>
com.tykj.dev
</groupId>
<artifactId>
config
</artifactId>
<artifactId>
config
</artifactId>
...
...
dev-loss/src/main/java/com/tykj/dev/device/loss/entity/vo/DeviceLossVo.java
浏览文件 @
6d3dfc57
...
@@ -25,6 +25,7 @@ public class DeviceLossVo {
...
@@ -25,6 +25,7 @@ public class DeviceLossVo {
@ApiModelProperty
(
value
=
"类型"
)
@ApiModelProperty
(
value
=
"类型"
)
private
Integer
type
;
private
Integer
type
;
private
String
typeName
;
/**
/**
* 装备名称
* 装备名称
*/
*/
...
...
dev-loss/src/main/java/com/tykj/dev/device/loss/service/DeviceLossService.java
浏览文件 @
6d3dfc57
...
@@ -5,12 +5,24 @@ import com.tykj.dev.device.loss.entity.domain.DeviceLoss;
...
@@ -5,12 +5,24 @@ import com.tykj.dev.device.loss.entity.domain.DeviceLoss;
import
java.util.List
;
import
java.util.List
;
public
interface
DeviceLossService
{
public
interface
DeviceLossService
{
/**
* 丢失、找回表单信息保存
*/
DeviceLoss
save
(
DeviceLoss
deviceLoss
);
DeviceLoss
save
(
DeviceLoss
deviceLoss
);
/**
* 丢失、找回 根据单据id查询单据详情
*/
DeviceLoss
findByDeviceLoss
(
Integer
lossId
);
DeviceLoss
findByDeviceLoss
(
Integer
lossId
);
/**
* 丢失、找回 查询所有的丢失、找回单据信息
*/
List
<
DeviceLoss
>
findByListLoss
();
List
<
DeviceLoss
>
findByListLoss
();
/**
* 丢失、找回 根据单位ID查询单据信息集合
*/
List
<
DeviceLoss
>
findByListLossUnitId
(
Integer
unitId
);
List
<
DeviceLoss
>
findByListLossUnitId
(
Integer
unitId
);
...
...
dev-loss/src/main/java/com/tykj/dev/device/loss/service/impl/LossBillSelectServiceImpl.java
浏览文件 @
6d3dfc57
...
@@ -44,6 +44,8 @@ public class LossBillSelectServiceImpl implements LossBillSelectService {
...
@@ -44,6 +44,8 @@ public class LossBillSelectServiceImpl implements LossBillSelectService {
private
DeviceLossVo
toDeviceLossVo
(
DeviceLibrary
deviceLibrary
){
private
DeviceLossVo
toDeviceLossVo
(
DeviceLibrary
deviceLibrary
){
ModelMapper
mapper
=
BeanHelper
.
getUserMapper
();
ModelMapper
mapper
=
BeanHelper
.
getUserMapper
();
return
mapper
.
map
(
deviceLibrary
,
DeviceLossVo
.
class
);
DeviceLossVo
deviceLossVo
=
mapper
.
map
(
deviceLibrary
,
DeviceLossVo
.
class
);
deviceLossVo
.
setTypeName
(
deviceLibrary
.
setConfigName
().
getTypeName
());
return
deviceLossVo
;
}
}
}
}
dev-loss/src/main/java/com/tykj/dev/device/loss/service/impl/LossBillServiceImpl.java
浏览文件 @
6d3dfc57
...
@@ -13,6 +13,7 @@ import com.tykj.dev.device.loss.service.LossBillService;
...
@@ -13,6 +13,7 @@ import com.tykj.dev.device.loss.service.LossBillService;
import
com.tykj.dev.device.loss.util.StringUtils
;
import
com.tykj.dev.device.loss.util.StringUtils
;
import
com.tykj.dev.device.task.service.TaskService
;
import
com.tykj.dev.device.task.service.TaskService
;
import
com.tykj.dev.device.task.subject.bto.TaskBto
;
import
com.tykj.dev.device.task.subject.bto.TaskBto
;
import
com.tykj.dev.device.user.read.service.MessageService
;
import
com.tykj.dev.device.user.subject.entity.Area
;
import
com.tykj.dev.device.user.subject.entity.Area
;
import
com.tykj.dev.device.user.subject.entity.SecurityUser
;
import
com.tykj.dev.device.user.subject.entity.SecurityUser
;
import
com.tykj.dev.device.user.subject.entity.Units
;
import
com.tykj.dev.device.user.subject.entity.Units
;
...
@@ -61,6 +62,9 @@ public class LossBillServiceImpl implements LossBillService {
...
@@ -61,6 +62,9 @@ public class LossBillServiceImpl implements LossBillService {
@Autowired
@Autowired
DeviceLogService
deviceLogService
;
DeviceLogService
deviceLogService
;
@Autowired
MessageService
messageService
;
@Override
@Override
public
void
initiateLoss
(
DeviceLoss
deviceLoss
,
SecurityUser
securityUser
)
{
public
void
initiateLoss
(
DeviceLoss
deviceLoss
,
SecurityUser
securityUser
)
{
deviceLibraryService
.
isInStockOrWaitRetired
(
deviceLoss
.
getDevIdsList
());
deviceLibraryService
.
isInStockOrWaitRetired
(
deviceLoss
.
getDevIdsList
());
...
@@ -90,12 +94,16 @@ public class LossBillServiceImpl implements LossBillService {
...
@@ -90,12 +94,16 @@ public class LossBillServiceImpl implements LossBillService {
Area
area
=
areaService
.
findByid
(
units
.
getAreaId
());
Area
area
=
areaService
.
findByid
(
units
.
getAreaId
());
TaskBto
taskBto
=
taskService
.
get
(
lossAuditvo
.
getTaskId
());
TaskBto
taskBto
=
taskService
.
get
(
lossAuditvo
.
getTaskId
());
DeviceLoss
deviceLoss
=
deviceLossService
.
findByDeviceLoss
(
taskBto
.
getBillId
());
DeviceLoss
deviceLoss
=
deviceLossService
.
findByDeviceLoss
(
taskBto
.
getBillId
());
if
(
units
.
getLevel
()==
1
){
if
(
units
.
getLevel
()==
1
){
TaskDisposeUtil
.
isNotSubmit
(
taskBto
.
getBillStatus
(),
StatusEnum
.
LOSS1301
);
TaskDisposeUtil
.
isNotSubmit
(
taskBto
.
getBillStatus
(),
StatusEnum
.
LOSS1301
);
deviceLoss
.
setProvinceUnitName
(
units
.
getName
());
deviceLoss
.
setProvinceUnitName
(
units
.
getName
());
deviceLoss
.
setProvinceDes
(
lossAuditvo
.
getDes
());
deviceLoss
.
setProvinceDes
(
lossAuditvo
.
getDes
());
taskService
.
moveToEnd
(
taskBto
);
taskService
.
moveToEnd
(
taskBto
);
}
else
{
}
else
{
TaskDisposeUtil
.
isNotSubmit
(
taskBto
.
getBillStatus
(),
StatusEnum
.
LOSS1300
);
TaskDisposeUtil
.
isNotSubmit
(
taskBto
.
getBillStatus
(),
StatusEnum
.
LOSS1300
);
Units
parentUnits
=
unitsService
.
findUnitAreaId
(
area
.
getFatherId
());
Units
parentUnits
=
unitsService
.
findUnitAreaId
(
area
.
getFatherId
());
deviceLoss
.
setCityUnitName
(
units
.
getName
());
deviceLoss
.
setCityUnitName
(
units
.
getName
());
...
...
dev-misc/src/main/java/com/tykj/dev/misc/base/StatusEnum.java
浏览文件 @
6d3dfc57
...
@@ -60,16 +60,6 @@ public enum StatusEnum {
...
@@ -60,16 +60,6 @@ public enum StatusEnum {
/**
/**
* 清退任务
* 清退任务
*/
*/
//以下为stat状态
// SEND_BACK_1200(1200, "省市清退查看"),
// SEND_BACK_1201(1201, "统计数据等待办结"),
// SEND_BACK_1202(1202, "出库待审核"),
// SEND_BACK_1203(1203, "出库待校验"),
// SEND_BACK_1204(1204, "入库待审核"),
// SEND_BACK_1205(1205, "异常装备待描述"),
// SEND_BACK_1206(1206, "入库待校验"),
// SEND_BACK_1207(1207, "异常装备确认"),
SEND_BACK_1200
(
1200
,
"省清退任务待各市提交"
),
SEND_BACK_1200
(
1200
,
"省清退任务待各市提交"
),
SEND_BACK_1201
(
1201
,
"市清退任务待执行"
),
SEND_BACK_1201
(
1201
,
"市清退任务待执行"
),
SEND_BACK_1202
(
1202
,
"省直属装备待清退"
),
SEND_BACK_1202
(
1202
,
"省直属装备待清退"
),
...
@@ -86,6 +76,7 @@ public enum StatusEnum {
...
@@ -86,6 +76,7 @@ public enum StatusEnum {
SEND_BACK_1213
(
1213
,
"省直属清退任务待上传单据"
),
SEND_BACK_1213
(
1213
,
"省直属清退任务待上传单据"
),
SEND_BACK_1214
(
1214
,
"清退出库等待上传回执单"
),
SEND_BACK_1214
(
1214
,
"清退出库等待上传回执单"
),
SEND_BACK_1215
(
1215
,
"清退出库接收方单据待补充"
),
SEND_BACK_1215
(
1215
,
"清退出库接收方单据待补充"
),
SEND_BACK_1216
(
1216
,
"市本级装备待清退"
),
...
@@ -131,12 +122,6 @@ public enum StatusEnum {
...
@@ -131,12 +122,6 @@ public enum StatusEnum {
TRAIN1010
(
1010
,
"待培训"
),
TRAIN1010
(
1010
,
"待培训"
),
WORKHANDOVER1011
(
1011
,
"待上传签字单"
),
WORKHANDOVER1011
(
1011
,
"待上传签字单"
),
//
// TRAIN1011(1011,""),
//
// TRAIN1012(1012,""),
//
// TRAIN1013(1013,""),
/**
/**
* 业务封存
* 业务封存
...
...
dev-scrap/src/main/java/com/tykj/dev/device/scrap/service/impl/ScrapBusinessServiceImpl.java
浏览文件 @
6d3dfc57
package
com
.
tykj
.
dev
.
device
.
scrap
.
service
.
impl
;
package
com
.
tykj
.
dev
.
device
.
scrap
.
service
.
impl
;
import
com.fasterxml.jackson.core.type.TypeReference
;
import
com.tykj.dev.config.base.DeviceLifeStatus
;
import
com.tykj.dev.config.base.DeviceLifeStatus
;
import
com.tykj.dev.device.file.service.FilesUtil
;
import
com.tykj.dev.device.file.service.FilesUtil
;
import
com.tykj.dev.device.library.repository.DeviceLibraryDao
;
import
com.tykj.dev.device.library.repository.DeviceLibraryDao
;
...
@@ -7,6 +8,7 @@ import com.tykj.dev.device.library.service.DeviceLogService;
...
@@ -7,6 +8,7 @@ import com.tykj.dev.device.library.service.DeviceLogService;
import
com.tykj.dev.device.library.subject.Dto.DeviceLogDto
;
import
com.tykj.dev.device.library.subject.Dto.DeviceLogDto
;
import
com.tykj.dev.device.library.subject.domin.DeviceLibrary
;
import
com.tykj.dev.device.library.subject.domin.DeviceLibrary
;
import
com.tykj.dev.device.library.subject.domin.DeviceLog
;
import
com.tykj.dev.device.library.subject.domin.DeviceLog
;
import
com.tykj.dev.device.library.subject.vo.ScriptSaveVo
;
import
com.tykj.dev.device.scrap.service.ScrapBusinessService
;
import
com.tykj.dev.device.scrap.service.ScrapBusinessService
;
import
com.tykj.dev.device.scrap.service.ScrapService
;
import
com.tykj.dev.device.scrap.service.ScrapService
;
import
com.tykj.dev.device.scrap.subject.domin.Scrap
;
import
com.tykj.dev.device.scrap.subject.domin.Scrap
;
...
@@ -22,6 +24,7 @@ import com.tykj.dev.device.user.subject.service.UnitsService;
...
@@ -22,6 +24,7 @@ import com.tykj.dev.device.user.subject.service.UnitsService;
import
com.tykj.dev.device.user.subject.service.UserService
;
import
com.tykj.dev.device.user.subject.service.UserService
;
import
com.tykj.dev.misc.base.BusinessEnum
;
import
com.tykj.dev.misc.base.BusinessEnum
;
import
com.tykj.dev.misc.base.StatusEnum
;
import
com.tykj.dev.misc.base.StatusEnum
;
import
com.tykj.dev.misc.utils.DeviceSeqUtil
;
import
com.tykj.dev.misc.utils.JacksonUtil
;
import
com.tykj.dev.misc.utils.JacksonUtil
;
import
com.tykj.dev.misc.utils.StringUtils
;
import
com.tykj.dev.misc.utils.StringUtils
;
import
com.tykj.dev.misc.utils.TaskDisposeUtil
;
import
com.tykj.dev.misc.utils.TaskDisposeUtil
;
...
@@ -43,6 +46,7 @@ import java.util.stream.Collectors;
...
@@ -43,6 +46,7 @@ import java.util.stream.Collectors;
* @createTime 2021年03月31日 13:16:00
* @createTime 2021年03月31日 13:16:00
*/
*/
@Service
@Service
@SuppressWarnings
(
"ALL"
)
public
class
ScrapBusinessServiceImpl
implements
ScrapBusinessService
{
public
class
ScrapBusinessServiceImpl
implements
ScrapBusinessService
{
@Autowired
@Autowired
UserService
userService
;
UserService
userService
;
...
@@ -79,13 +83,23 @@ public class ScrapBusinessServiceImpl implements ScrapBusinessService {
...
@@ -79,13 +83,23 @@ public class ScrapBusinessServiceImpl implements ScrapBusinessService {
List
<
DeviceLibrary
>
deviceLibraries
=
findInvoleDevice
(
scrap
.
getDeviceIds
());
List
<
DeviceLibrary
>
deviceLibraries
=
findInvoleDevice
(
scrap
.
getDeviceIds
());
scrap
.
setDeviceLibraryEntities
(
findInvoleDevice
(
scrap
.
getDeviceIds
()));
scrap
.
setDeviceLibraryEntities
(
findInvoleDevice
(
scrap
.
getDeviceIds
()));
scrapService
.
saveScrap
(
scrap
);
scrapService
.
saveScrap
(
scrap
);
deviceLibraryDao
.
upDateLeftStatus
(
DeviceLifeStatus
.
RETIRED
.
id
,
scrapOrderOutData
.
getDevIds
());
List
<
ScriptSaveVo
>
scriptSaveVos
=
scrapOrderOutData
.
getScriptSaveVos
();
List
<
String
>
seqNumbers
=
new
ArrayList
<>();
scriptSaveVos
.
forEach
(
scriptSaveVo
->
{
if
(
scriptSaveVo
.
getSeqNumber
()!=
null
){
seqNumbers
.
addAll
(
DeviceSeqUtil
.
selectDeviceSeqs
(
scriptSaveVo
.
getSeqNumber
()));
}
}
);
deviceLibraryDao
.
upDateSeqNumbersLeftStatus
(
DeviceLifeStatus
.
RETIRED
.
id
,
seqNumbers
);
devLogAdd
(
deviceLibraries
,
"发起了报废任务"
,
userId
);
devLogAdd
(
deviceLibraries
,
"发起了报废任务"
,
userId
);
TaskBto
taskBto
=
sendOutSuperior
(
units
.
getUnitId
(),
scrap
.
getId
(),
userId
);
TaskBto
taskBto
=
sendOutSuperior
(
units
.
getUnitId
(),
scrap
.
getId
(),
userId
);
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"发起退役任务,待上传回执单据"
,
gainThisUser
(
user
.
getUserId
(),
user
.
getUnitsId
())));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"发起退役任务,待上传回执单据"
,
gainThisUser
(
user
.
getUserId
(),
user
.
getUnitsId
())));
return
scrap
;
return
scrap
;
}
}
@Override
@Override
public
void
receiptSingle
(
Integer
taskId
,
StorageScrap
storageScrap
)
{
public
void
receiptSingle
(
Integer
taskId
,
StorageScrap
storageScrap
)
{
User
user
=
userService
.
findByUser
(
storageScrap
.
getUserId
());
User
user
=
userService
.
findByUser
(
storageScrap
.
getUserId
());
...
@@ -108,7 +122,16 @@ public class ScrapBusinessServiceImpl implements ScrapBusinessService {
...
@@ -108,7 +122,16 @@ public class ScrapBusinessServiceImpl implements ScrapBusinessService {
scrap
.
setReceiveUserA
(
storageScrap
.
getUserAName
());
scrap
.
setReceiveUserA
(
storageScrap
.
getUserAName
());
}
}
taskService
.
moveToEnd
(
taskBto
);
taskService
.
moveToEnd
(
taskBto
);
deviceLibraryDao
.
upDateLeftStatusAndUnitNameAndLockStatus
(
DeviceLifeStatus
.
RETIRE
.
id
,
scrap
.
getReceiveUnit
(),
0
,
StringUtils
.
stringToList
(
scrap
.
getDeviceIds
()));
List
<
String
>
seqNumbers
=
new
ArrayList
<>();
JacksonUtil
.
readValue
(
scrap
.
getScriptJson
(),
new
TypeReference
<
List
<
ScriptSaveVo
>>()
{}).
forEach
(
scriptSaveVo
->
{
if
(
scriptSaveVo
.
getSeqNumber
()!=
null
){
seqNumbers
.
addAll
(
DeviceSeqUtil
.
selectDeviceSeqs
(
scriptSaveVo
.
getSeqNumber
()));
}
}
);
deviceLibraryDao
.
upDateSeqNumbersLeftStatusAndUnitNameAndLockStatus
(
DeviceLifeStatus
.
RETIRE
.
id
,
scrap
.
getReceiveUnit
(),
0
,
seqNumbers
);
scrapService
.
saveScrap
(
scrap
);
scrapService
.
saveScrap
(
scrap
);
devLogAdd
(
findInvoleDevice
(
scrap
.
getDeviceIds
()),
"上传了报废单据,装备状态-》已报废"
,
storageScrap
.
getUserId
());
devLogAdd
(
findInvoleDevice
(
scrap
.
getDeviceIds
()),
"上传了报废单据,装备状态-》已报废"
,
storageScrap
.
getUserId
());
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"退役任务回执单据上传成功任务结束"
,
gainThisUser
(
user
.
getUserId
(),
user
.
getUnitsId
())));
addMessage
(
new
MessageBto
(
taskBto
.
getId
(),
taskBto
.
getBusinessType
(),
"退役任务回执单据上传成功任务结束"
,
gainThisUser
(
user
.
getUserId
(),
user
.
getUnitsId
())));
...
...
dev-sendback/src/main/java/com/tykj/dev/device/sendback/entity/domain/DeviceRepel.java
浏览文件 @
6d3dfc57
...
@@ -103,6 +103,18 @@ public class DeviceRepel extends BaseEntity {
...
@@ -103,6 +103,18 @@ public class DeviceRepel extends BaseEntity {
*/
*/
private
Integer
unitId
;
private
Integer
unitId
;
/**
* 装备序列号
*/
@Column
(
name
=
"seq_numbers"
,
columnDefinition
=
"TEXT"
)
private
String
seqNumbers
;
/**
* type为123时使用
*/
@Column
(
name
=
"equipment_involving_unit"
,
columnDefinition
=
"TEXT"
)
private
String
equipmentInvolvingUnit
;
/**
/**
* 类型集合多个列装id
* 类型集合多个列装id
* 页面类型
* 页面类型
...
...
dev-sendback/src/main/java/com/tykj/dev/device/sendback/entity/vo/SupervisorVo.java
0 → 100644
浏览文件 @
6d3dfc57
package
com
.
tykj
.
dev
.
device
.
sendback
.
entity
.
vo
;
import
io.swagger.annotations.ApiModel
;
import
lombok.AllArgsConstructor
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.util.List
;
/**
* @author zjm
* @version 1.0.0
* @ClassName SupervisorVo.java
* @Description TODO
* @createTime 2021年04月07日 10:31:00
*/
@Data
@AllArgsConstructor
@NoArgsConstructor
public
class
SupervisorVo
{
private
String
unitName
;
private
Integer
unitid
;
}
dev-sendback/src/main/java/com/tykj/dev/device/sendback/service/RepelBusinessService.java
浏览文件 @
6d3dfc57
...
@@ -62,6 +62,10 @@ public interface RepelBusinessService {
...
@@ -62,6 +62,10 @@ public interface RepelBusinessService {
*/
*/
DeviceRepelDetail
sendBackOutCheck
(
Integer
taskId
,
Integer
userId
,
OrderOutData
orderOutData
);
DeviceRepelDetail
sendBackOutCheck
(
Integer
taskId
,
Integer
userId
,
OrderOutData
orderOutData
);
// void SealOfAudit()
/**
/**
* 上级清退装备入库
* 上级清退装备入库
*/
*/
...
@@ -73,6 +77,7 @@ public interface RepelBusinessService {
...
@@ -73,6 +77,7 @@ public interface RepelBusinessService {
*/
*/
void
oneselfRepel
(
Integer
taskId
,
StorageDeviceRepel
storageDeviceRepel
,
Integer
userId
);
void
oneselfRepel
(
Integer
taskId
,
StorageDeviceRepel
storageDeviceRepel
,
Integer
userId
);
/**
/**
* 省直属任务等待上传 (需要根据主业务的type 给涉及的装备装备给不同的状态)
* 省直属任务等待上传 (需要根据主业务的type 给涉及的装备装备给不同的状态)
*/
*/
...
...
dev-sendback/src/main/java/com/tykj/dev/device/sendback/service/impl/RepelBusinessServiceImpl.java
浏览文件 @
6d3dfc57
差异被折叠。
点击展开。
dev-sendback/src/main/java/com/tykj/dev/device/sendback/service/impl/RepelQueryServiceImpl.java
浏览文件 @
6d3dfc57
...
@@ -19,6 +19,7 @@ import com.tykj.dev.device.user.subject.service.UnitsService;
...
@@ -19,6 +19,7 @@ import com.tykj.dev.device.user.subject.service.UnitsService;
import
com.tykj.dev.misc.base.BusinessEnum
;
import
com.tykj.dev.misc.base.BusinessEnum
;
import
com.tykj.dev.misc.base.DeviceLifeStatus
;
import
com.tykj.dev.misc.base.DeviceLifeStatus
;
import
com.tykj.dev.misc.base.StatusEnum
;
import
com.tykj.dev.misc.base.StatusEnum
;
import
com.tykj.dev.misc.utils.DeviceSeqUtil
;
import
com.tykj.dev.misc.utils.JacksonUtil
;
import
com.tykj.dev.misc.utils.JacksonUtil
;
import
com.tykj.dev.misc.utils.StringUtils
;
import
com.tykj.dev.misc.utils.StringUtils
;
import
lombok.extern.slf4j.Slf4j
;
import
lombok.extern.slf4j.Slf4j
;
...
@@ -77,7 +78,7 @@ public class RepelQueryServiceImpl implements RepelQueryService {
...
@@ -77,7 +78,7 @@ public class RepelQueryServiceImpl implements RepelQueryService {
@Override
@Override
public
DeviceRepel
findDeviceRepel
(
Integer
taskId
)
{
public
DeviceRepel
findDeviceRepel
(
Integer
taskId
)
{
TaskBto
taskBto
=
taskService
.
get
(
taskId
);
TaskBto
taskBto
=
taskService
.
get
(
taskId
);
if
(
taskBto
.
getBusinessType
()==
18
){
if
(
taskBto
.
getBusinessType
()==
BusinessEnum
.
SEND_BACK_STATISTICAL
.
id
){
return
deviceRepelService
.
findDeviceRepel
(
taskBto
.
getBillId
());
return
deviceRepelService
.
findDeviceRepel
(
taskBto
.
getBillId
());
}
}
DeviceRepelDetail
deviceRepelDetail
=
repelDetailService
.
findDeviceRepelDetailNoDev
(
taskBto
.
getBillId
());
DeviceRepelDetail
deviceRepelDetail
=
repelDetailService
.
findDeviceRepelDetailNoDev
(
taskBto
.
getBillId
());
...
@@ -89,26 +90,53 @@ public class RepelQueryServiceImpl implements RepelQueryService {
...
@@ -89,26 +90,53 @@ public class RepelQueryServiceImpl implements RepelQueryService {
List
<
DeviceLibrary
>
deviceLibraries
=
new
ArrayList
<>();
List
<
DeviceLibrary
>
deviceLibraries
=
new
ArrayList
<>();
List
<
DeviceLibrary
>
deviceLibrariesAbnormal
=
new
ArrayList
<>();
List
<
DeviceLibrary
>
deviceLibrariesAbnormal
=
new
ArrayList
<>();
Units
units
=
unitsService
.
findById
(
unitId
);
Units
units
=
unitsService
.
findById
(
unitId
);
deviceLibraryDao
.
findAllByPackingIdInAndOwnUnit
(
fielding
,
units
.
getName
()).
stream
()
DeviceRepelDetail
deviceRepelDetail
=
repelDetailService
.
findDeviceRepelDetail
(
taskService
.
get
(
taskId
).
getBillId
());
DeviceRepel
deviceRepel
=
deviceRepelService
.
findDeviceRepel
(
deviceRepelDetail
.
getRepelId
());
if
(
deviceRepel
.
getType
()==
0
)
{
deviceLibraryDao
.
findAllByPackingIdInAndOwnUnit
(
fielding
,
units
.
getName
()).
stream
()
.
filter
(
deviceLibrary
->
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
IN_LIBRARY
.
id
)
.
filter
(
deviceLibrary
->
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
IN_LIBRARY
.
id
)
||
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
REPEL
.
id
)
||
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
REPEL
.
id
)
||
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
SEND_BACK
.
id
)
||
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
SEND_BACK
.
id
)
||
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
REPAIRING
.
id
)
||
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
REPAIRING
.
id
)
||
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
IN_TRANSIT
.
id
)
||
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
IN_TRANSIT
.
id
)
||
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
USE
.
id
))
||
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
USE
.
id
))
.
map
(
DeviceLibrary:
:
setConfigName
).
forEach
(
.
map
(
DeviceLibrary:
:
setConfigName
).
forEach
(
deviceLibrary
->
{
deviceLibrary
->
{
if
(
deviceLibrary
.
getOwnUnit
().
equals
(
deviceLibrary
.
getLocationUnit
()))
{
if
(
deviceLibrary
.
getOwnUnit
().
equals
(
deviceLibrary
.
getLocationUnit
()))
{
if
(
deviceLibrary
.
getLifeStatus
()==
2
||
deviceLibrary
.
getLifeStatus
()==
15
||
deviceLibrary
.
getLifeStatus
()==
14
||
deviceLibrary
.
getLifeStatus
()==
6
)
{
if
(
deviceLibrary
.
getLifeStatus
()
==
2
||
deviceLibrary
.
getLifeStatus
()
==
15
||
deviceLibrary
.
getLifeStatus
()
==
14
||
deviceLibrary
.
getLifeStatus
()
==
6
)
{
deviceLibraries
.
add
(
deviceLibrary
);
deviceLibraries
.
add
(
deviceLibrary
);
}
else
{
}
else
{
deviceLibrariesAbnormal
.
add
(
deviceLibrary
);
}
}
else
{
deviceLibrariesAbnormal
.
add
(
deviceLibrary
);
deviceLibrariesAbnormal
.
add
(
deviceLibrary
);
}
}
}
);
}
else
{
}
else
{
deviceLibraryDao
.
findAllBySeqNumberIn
(
DeviceSeqUtil
.
selectDeviceSeqs
(
deviceRepel
.
getSeqNumbers
())).
stream
()
.
filter
(
deviceLibrary
->
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
IN_LIBRARY
.
id
)
||
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
REPEL
.
id
)
||
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
SEND_BACK
.
id
)
||
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
REPAIRING
.
id
)
||
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
IN_TRANSIT
.
id
)
||
deviceLibrary
.
getLifeStatus
().
equals
(
DeviceLifeStatus
.
USE
.
id
))
.
filter
(
deviceLibrary
->
deviceLibrary
.
getOwnUnit
().
equals
(
units
.
getName
()))
.
map
(
DeviceLibrary:
:
setConfigName
).
forEach
(
deviceLibrary
->
{
if
(
deviceLibrary
.
getOwnUnit
().
equals
(
deviceLibrary
.
getLocationUnit
()))
{
if
(
deviceLibrary
.
getLifeStatus
()
==
2
||
deviceLibrary
.
getLifeStatus
()
==
15
||
deviceLibrary
.
getLifeStatus
()
==
14
||
deviceLibrary
.
getLifeStatus
()
==
6
)
{
deviceLibraries
.
add
(
deviceLibrary
);
}
else
{
deviceLibrariesAbnormal
.
add
(
deviceLibrary
);
}
}
else
{
deviceLibrariesAbnormal
.
add
(
deviceLibrary
);
deviceLibrariesAbnormal
.
add
(
deviceLibrary
);
}
}
}
}
);
);
}
int
isNotSub
=
1
;
int
isNotSub
=
1
;
if
(
units
.
getLevel
()==
2
)
{
if
(
units
.
getLevel
()==
2
)
{
TaskBto
taskBto
=
taskService
.
findFatherIdAndCustomInfo
(
taskId
);
TaskBto
taskBto
=
taskService
.
findFatherIdAndCustomInfo
(
taskId
);
...
...
dev-user/src/main/java/com/tykj/dev/device/user/subject/controller/UserController.java
浏览文件 @
6d3dfc57
...
@@ -122,22 +122,12 @@ public class UserController {
...
@@ -122,22 +122,12 @@ public class UserController {
@GetMapping
(
value
=
"/findAll"
)
@GetMapping
(
value
=
"/findAll"
)
@ApiOperation
(
value
=
"所有用户查询接口"
,
notes
=
"成功返回用户对象集合"
)
@ApiOperation
(
value
=
"所有用户查询接口"
,
notes
=
"成功返回用户对象集合"
)
public
ResponseEntity
findAllUser
(
@ApiIgnore
@AuthenticationPrincipal
SecurityUser
securityUser
)
{
public
ResponseEntity
findAllUser
(
@ApiIgnore
@AuthenticationPrincipal
SecurityUser
securityUser
)
{
// log.info("当前登入对象:{}",securityUser.getCurrentUserInfo().getUsername());
return
ResponseEntity
.
ok
(
userService
.
findAll
());
return
ResponseEntity
.
ok
(
userService
.
findAll
());
}
}
// @GetMapping(value = "/findAll/{userId}")
// @ApiOperation(value = "根据用户id查询同级用户信息", notes = "成功返回用户对象集合")
// public ResponseEntity findAll(@ApiIgnore @AuthenticationPrincipal SecurityUser securityUser, @PathVariable Integer userId){
//// log.info("当前登入对象:{}",securityUser.getCurrentUserInfo().getUsername());
// return ResponseEntity.ok(userService.findByUserId(userId));
// }
@GetMapping
(
value
=
"/findAll/{unitsId}"
)
@GetMapping
(
value
=
"/findAll/{unitsId}"
)
@ApiOperation
(
value
=
"根据单位查询用户(下拉)"
,
notes
=
"成功返回用户对象集合"
)
@ApiOperation
(
value
=
"根据单位查询用户(下拉)"
,
notes
=
"成功返回用户对象集合"
)
public
ResponseEntity
findAll2
(
@ApiIgnore
@AuthenticationPrincipal
SecurityUser
securityUser
,
@PathVariable
Integer
unitsId
)
{
public
ResponseEntity
findAll2
(
@ApiIgnore
@AuthenticationPrincipal
SecurityUser
securityUser
,
@PathVariable
Integer
unitsId
)
{
// log.info("当前登入对象:{}",securityUser.getCurrentUserInfo().getUsername());
return
ResponseEntity
.
ok
(
userService
.
findByUniteId
(
unitsId
));
return
ResponseEntity
.
ok
(
userService
.
findByUniteId
(
unitsId
));
}
}
...
@@ -154,7 +144,6 @@ public class UserController {
...
@@ -154,7 +144,6 @@ public class UserController {
return
ResponseEntity
.
ok
(
userService
.
findByUserId
(
userId
));
return
ResponseEntity
.
ok
(
userService
.
findByUserId
(
userId
));
}
}
@PostMapping
(
value
=
"/archives/update/password"
)
@PostMapping
(
value
=
"/archives/update/password"
)
@ApiOperation
(
value
=
"修改用户密码"
,
notes
=
"返回修改结果"
)
@ApiOperation
(
value
=
"修改用户密码"
,
notes
=
"返回修改结果"
)
public
ResponseEntity
updatePassword
(
@ApiIgnore
@AuthenticationPrincipal
SecurityUser
securityUser
,
@RequestBody
UserUpdatePw
userUpdatePw
)
{
public
ResponseEntity
updatePassword
(
@ApiIgnore
@AuthenticationPrincipal
SecurityUser
securityUser
,
@RequestBody
UserUpdatePw
userUpdatePw
)
{
...
@@ -169,13 +158,6 @@ public class UserController {
...
@@ -169,13 +158,6 @@ public class UserController {
return
ResponseEntity
.
ok
(
"修改密码成功"
);
return
ResponseEntity
.
ok
(
"修改密码成功"
);
}
}
// @GetMapping(value = "/get/train/{userId}")
// @ApiOperation(value = "根据用户id查询下级用户列表", notes = "成功返回UserTrainVo对象集合")
// public ResponseEntity getFind(@ApiIgnore @AuthenticationPrincipal SecurityUser securityUser, @PathVariable Integer userId) {
//
// return ResponseEntity.ok(userService.findByIdUserTarinVo(userId));
// }
@GetMapping
(
value
=
"/get/trainUnits/{userId}"
)
@GetMapping
(
value
=
"/get/trainUnits/{userId}"
)
@ApiOperation
(
value
=
"根据用户id查询下级单位列表"
,
notes
=
"成功返回UnitsTrainVo对象集合"
)
@ApiOperation
(
value
=
"根据用户id查询下级单位列表"
,
notes
=
"成功返回UnitsTrainVo对象集合"
)
public
ResponseEntity
getFindTrainVo
(
@ApiIgnore
@AuthenticationPrincipal
SecurityUser
securityUser
,
@PathVariable
Integer
userId
)
{
public
ResponseEntity
getFindTrainVo
(
@ApiIgnore
@AuthenticationPrincipal
SecurityUser
securityUser
,
@PathVariable
Integer
userId
)
{
...
@@ -190,13 +172,6 @@ public class UserController {
...
@@ -190,13 +172,6 @@ public class UserController {
return
ResponseEntity
.
ok
(
userService
.
findById
(
userId
));
return
ResponseEntity
.
ok
(
userService
.
findById
(
userId
));
}
}
// @PostMapping(value = "/update")
// @ApiOperation(value = "修改用户信息", notes = "成功返回UnitsTrainVo对象集合")
// public ResponseEntity getFindMemberThatVo(@ApiIgnore @AuthenticationPrincipal SecurityUser securityUser, @RequestBody MemberThat memberThat){
// userService.update(memberThat.toUserVo());
// return ResponseEntity.ok(memberThat);
// }
@GetMapping
(
"/findAll/superiorList"
)
@GetMapping
(
"/findAll/superiorList"
)
@ApiOperation
(
value
=
"根据用户ID查询上级单位用户"
,
notes
=
"List<UserSuperiorVo>"
)
@ApiOperation
(
value
=
"根据用户ID查询上级单位用户"
,
notes
=
"List<UserSuperiorVo>"
)
public
ResponseEntity
getFindMemberThatVo
(
@ApiIgnore
@AuthenticationPrincipal
SecurityUser
securityUser
)
{
public
ResponseEntity
getFindMemberThatVo
(
@ApiIgnore
@AuthenticationPrincipal
SecurityUser
securityUser
)
{
...
@@ -250,7 +225,6 @@ public class UserController {
...
@@ -250,7 +225,6 @@ public class UserController {
@PostMapping
(
"/list/unitName"
)
@PostMapping
(
"/list/unitName"
)
@ApiOperation
(
value
=
"根据单位名称查询单位用户"
)
@ApiOperation
(
value
=
"根据单位名称查询单位用户"
)
public
ResponseEntity
findUnitName
(
@RequestBody
UnitNameVo
unitNameVo
){
public
ResponseEntity
findUnitName
(
@RequestBody
UnitNameVo
unitNameVo
){
return
ResponseEntity
.
ok
(
userService
.
findUnitNameListUser
(
unitNameVo
));
return
ResponseEntity
.
ok
(
userService
.
findUnitNameListUser
(
unitNameVo
));
}
}
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论