Blame view

parking-module-pay/src/main/java/com/zteits/pay/dao/impl/TdCAcctPersonChangeDaoImpl.java 3.06 KB
55f68655   王彪总   新项目
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
  package com.zteits.pay.dao.impl;
  import com.zteits.pay.domain.TdCAcctPersonChange;
  import com.zteits.pay.domain.TdCAcctPersonChangeExample;
  import com.zteits.clouds.api.dto.pay.param.TdCAcctPersonChangeRequest;
  import com.zteits.pay.dao.TdCAcctPersonChangeDao;
  import com.zteits.pay.mapper.TdCAcctPersonChangeMapper;
  
  import org.springframework.beans.factory.annotation.Autowired;
  import org.springframework.stereotype.Component;
  
  import com.zteits.clouds.api.apibase.constants.DataStatusEnum;
  
  import java.util.Date;
  import java.util.List;
  
  @Component
  public class TdCAcctPersonChangeDaoImpl implements  TdCAcctPersonChangeDao {
      @Autowired
      private TdCAcctPersonChangeMapper tdCAcctPersonChangeMapper;
  
      @Override
      public int saveTdCAcctPersonChange(TdCAcctPersonChange tdCAcctPersonChange) {
          if(tdCAcctPersonChange.getCreateDate()==null){
              tdCAcctPersonChange.setCreateDate(new Date());
          }
          return tdCAcctPersonChangeMapper.insertSelective(tdCAcctPersonChange);
      }
  
      @Override
      public int updateByExampleSelective(TdCAcctPersonChange record, TdCAcctPersonChangeExample example) {
          return tdCAcctPersonChangeMapper.updateByExampleSelective(record,example);
      }
  
      @Override
      public int updateByPrimaryKeySelective(TdCAcctPersonChange record) {
          return tdCAcctPersonChangeMapper.updateByPrimaryKeySelective(record);
      }
  
      @Override
      public List<TdCAcctPersonChange> selectByExample(TdCAcctPersonChangeExample example) {
          return tdCAcctPersonChangeMapper.selectByExample(example);
      }
  
      @Override
      public TdCAcctPersonChange queryByPrimaryKey(Long id) {
          return tdCAcctPersonChangeMapper.selectByPrimaryKey(id);
      }
  
      @Override
      public List<TdCAcctPersonChange> queryTdCAcctPersonChange(TdCAcctPersonChangeRequest request) {
          //TODO 编写smapper实现
          //return tdCAcctPersonChangeSMapper.queryTdCAcctPersonChange(request);
          return null;
      }
  
      @Override
      public int batchDeleteTdCAcctPersonChangeByPrimaryKey(List<Long> ids, String opId, String opName) {
          TdCAcctPersonChange record = new TdCAcctPersonChange();
          record.setModfiyEmpid(opId);
          record.setModfiyDate(new Date());
          record.setDataState(DataStatusEnum.DATA_STATUS_NO_VALID.value());
          TdCAcctPersonChangeExample example = new TdCAcctPersonChangeExample();
          example.createCriteria().andIdIn(ids);
          return tdCAcctPersonChangeMapper.updateByExampleSelective(record,example);
      }
  
      /*@Override
      public PageInfo<TdCAcctPersonChange> queryTdCAcctPersonChangeForPage(TdCAcctPersonChangeRequest request) {
          PageHelper.startPage(request.getBaseRequest().getPageNum(), request.getBaseRequest().getPageSize());
          //TODO 编写smapper实现
          *//*List<TdCAcctPersonChange> list = tdCAcctPersonChangeSMapper.queryTdCAcctPersonChange(request);
          if (CollectionUtils.isNotEmpty(list)) {
              return new PageInfo<TdCAcctPersonChange>(list);
          }*//*
          return new PageInfo<TdCAcctPersonChange>(new ArrayList<TdCAcctPersonChange>());
      }*/
  }