|
|
|
@ -292,6 +292,16 @@ public class TerminalServiceImpl implements TerminalService {
|
|
|
|
|
*/
|
|
|
|
|
@Override
|
|
|
|
|
public ServiceBody<String> deleteTerminal(TerminalIdListVo vo) {
|
|
|
|
|
Integer type = vo.getType();
|
|
|
|
|
if (type == null) {
|
|
|
|
|
type = CommonStatus.DELETE.value();
|
|
|
|
|
} else {
|
|
|
|
|
if (type == 0) {
|
|
|
|
|
type = CommonStatus.DELETE.value();
|
|
|
|
|
} else {
|
|
|
|
|
type = CommonStatus.EFFECTIVE.value();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
ArrayList<Terminals> list = new ArrayList<>();
|
|
|
|
|
List<TerminalIdVo> beans = vo.getList();
|
|
|
|
|
for (TerminalIdVo item : beans) {
|
|
|
|
@ -299,7 +309,7 @@ public class TerminalServiceImpl implements TerminalService {
|
|
|
|
|
terminals.setId(item.getTermid());
|
|
|
|
|
list.add(terminals);
|
|
|
|
|
}
|
|
|
|
|
int i = terminalsDao.deleteById(list, CommonStatus.DELETE.value(), new Date());
|
|
|
|
|
int i = terminalsDao.deleteById(list, type, new Date());
|
|
|
|
|
cacheService.updateTerminalMap();
|
|
|
|
|
if (i != 0) {
|
|
|
|
|
return Asserts.success("删除成功");
|
|
|
|
|