| | |
| | | package cn.flightfeather.supervision.domain.ds2.repository |
| | | |
| | | import cn.flightfeather.supervision.common.utils.Constant |
| | | import cn.flightfeather.supervision.common.utils.UUIDGenerator |
| | | import cn.flightfeather.supervision.domain.ds2.entity.UserinfoTZ |
| | | import cn.flightfeather.supervision.domain.ds2.mapper.UserinfoTZMapper |
| | | import org.springframework.stereotype.Repository |
| | | import tk.mybatis.mapper.entity.Example |
| | | import java.util.* |
| | | |
| | | @Repository |
| | | class UserInfoTZRep(private val userinfoTZMapper: UserinfoTZMapper) { |
| | |
| | | and(createCriteria().orIsNull("workno").orNotEqualTo("workno", "test")) |
| | | }) |
| | | } |
| | | |
| | | fun findOne(userinfoTZ: UserinfoTZ): UserinfoTZ? { |
| | | return userinfoTZMapper.selectOne(userinfoTZ) |
| | | } |
| | | |
| | | fun insert(userinfoTZ: UserinfoTZ): Int { |
| | | if (userinfoTZ.guid == null) userinfoTZ.guid = UUIDGenerator.generate16ShortUUID() |
| | | if (userinfoTZ.headIconUrl == null) userinfoTZ.headIconUrl = "" |
| | | userinfoTZ.uiCreateTime = Date() |
| | | return userinfoTZMapper.insert(userinfoTZ) |
| | | } |
| | | |
| | | } |