package cn.com.goldenwater.dcproj.service.impl; import cn.com.goldenwater.dcproj.dao.BisInspWrwsRgstrWtutDao; import cn.com.goldenwater.dcproj.model.BisInspWrwsRgstrWtut; import cn.com.goldenwater.dcproj.param.BisInspWrwsRgstrWtutParam; import cn.com.goldenwater.dcproj.service.BisInspWrwsRgstrWtutService; import cn.com.goldenwater.core.service.AbstractCrudService; import com.github.pagehelper.PageHelper; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import cn.com.goldenwater.id.util.UuidUtil; import java.util.List; import java.util.Date; /** * @author lhc * @date 2020-9-23 */ @Service @Transactional public class BisInspWrwsRgstrWtutServiceImpl extends AbstractCrudService implements BisInspWrwsRgstrWtutService { @Autowired private BisInspWrwsRgstrWtutDao bisInspWrwsRgstrWtutDao; public BisInspWrwsRgstrWtutServiceImpl(BisInspWrwsRgstrWtutDao bisInspWrwsRgstrWtutDao) { super(bisInspWrwsRgstrWtutDao); this.bisInspWrwsRgstrWtutDao = bisInspWrwsRgstrWtutDao; } @Override public int insert(BisInspWrwsRgstrWtut bisInspWrwsRgstrWtut) { String uuid = UuidUtil.uuid(); // 生成uuid bisInspWrwsRgstrWtut.setId(uuid); bisInspWrwsRgstrWtut.setIntm(new Date()); bisInspWrwsRgstrWtut.setUptm(new Date()); bisInspWrwsRgstrWtut.setDataStat("0"); return this.bisInspWrwsRgstrWtutDao.insert(bisInspWrwsRgstrWtut); } @Override public int update(BisInspWrwsRgstrWtut bisInspWrwsRgstrWtut) { bisInspWrwsRgstrWtut.setUptm(new Date()); return this.bisInspWrwsRgstrWtutDao.update(bisInspWrwsRgstrWtut); } @Override public int delete(String id) { return this.bisInspWrwsRgstrWtutDao.delete(id); } }