提交 | 用户 | 时间
|
97d38f
|
1 |
package com.iailab.module.model.mcs.pre.service.impl; |
潘 |
2 |
|
b06c21
|
3 |
import com.iailab.framework.common.pojo.PageResult; |
潘 |
4 |
import com.iailab.framework.common.service.impl.BaseServiceImpl; |
|
5 |
import com.iailab.framework.common.util.object.BeanUtils; |
|
6 |
import com.iailab.module.model.mcs.pre.dao.MmPredictAlarmMessageDao; |
|
7 |
import com.iailab.module.model.mcs.pre.entity.MmPredictAlarmMessageEntity; |
97d38f
|
8 |
import com.iailab.module.model.mcs.pre.service.MmPredictAlarmMessageService; |
b06c21
|
9 |
import com.iailab.module.model.mcs.pre.vo.MmPredictAlarmMessagePageReqVO; |
潘 |
10 |
import com.iailab.module.model.mcs.pre.vo.MmPredictAlarmMessageSaveReqVO; |
|
11 |
import org.springframework.stereotype.Service; |
|
12 |
|
|
13 |
import java.util.Date; |
|
14 |
import java.util.UUID; |
97d38f
|
15 |
|
潘 |
16 |
/** |
|
17 |
* @author PanZhibao |
|
18 |
* @Description |
|
19 |
* @createTime 2024年11月19日 |
|
20 |
*/ |
b06c21
|
21 |
@Service |
潘 |
22 |
public class MmPredictAlarmMessageServiceImpl extends BaseServiceImpl<MmPredictAlarmMessageDao, MmPredictAlarmMessageEntity> |
|
23 |
implements MmPredictAlarmMessageService { |
|
24 |
|
|
25 |
|
|
26 |
@Override |
|
27 |
public PageResult<MmPredictAlarmMessageEntity> page(MmPredictAlarmMessagePageReqVO reqVO) { |
|
28 |
return baseDao.selectPage(reqVO); |
|
29 |
} |
|
30 |
|
|
31 |
@Override |
|
32 |
public MmPredictAlarmMessageEntity getInfo(String id) { |
|
33 |
return baseDao.selectById(id); |
|
34 |
} |
|
35 |
|
|
36 |
@Override |
|
37 |
public void create(MmPredictAlarmMessageSaveReqVO reqVO) { |
|
38 |
MmPredictAlarmMessageEntity entity = BeanUtils.toBean(reqVO, MmPredictAlarmMessageEntity.class); |
|
39 |
entity.setId(UUID.randomUUID().toString()); |
|
40 |
entity.setCreateTime(new Date()); |
|
41 |
baseDao.insert(entity); |
|
42 |
} |
|
43 |
|
|
44 |
@Override |
|
45 |
public void update(MmPredictAlarmMessageSaveReqVO reqVO) { |
|
46 |
MmPredictAlarmMessageEntity entity = BeanUtils.toBean(reqVO, MmPredictAlarmMessageEntity.class); |
|
47 |
baseDao.updateById(entity); |
|
48 |
} |
|
49 |
|
|
50 |
@Override |
|
51 |
public void delete(String id) { |
|
52 |
baseDao.deleteById(id); |
|
53 |
} |
97d38f
|
54 |
} |