医院废弃物信息化管理平台
“mitao”
2025-12-24 3763145f34d7706923d55edc32f5cfbc8bc08b92
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
package cn.besteam.modules.medical.service.impl;
 
import cn.besteam.modules.medical.entity.MwDeviceAgent;
import cn.besteam.modules.medical.entity.MwDeviceAgentDevice;
import cn.besteam.modules.medical.mapper.MwDeviceAgentMapper;
import cn.besteam.modules.medical.service.IMwDeviceAgentDeviceService;
import cn.besteam.modules.medical.service.IMwDeviceAgentService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
 
/**
 * @Description: 设备代理商
 * @author: besteam
 * @date: 2020-04-25
 * @version: V1.0
 */
@Service
public class MwDeviceAgentServiceImpl extends ServiceImpl<MwDeviceAgentMapper, MwDeviceAgent> implements IMwDeviceAgentService {
 
    @Autowired
    private IMwDeviceAgentDeviceService mwDeviceAgentDeviceService;
 
    @Transactional(rollbackFor = Exception.class)
    @Override
    public boolean delete(Integer id) {
 
        removeById(id);
        mwDeviceAgentDeviceService.remove(new QueryWrapper<MwDeviceAgentDevice>().lambda().eq(MwDeviceAgentDevice::getDeviceAgentId, id));
        return true;
    }
 
}