| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113 |
- package com.goafanti.Interview.service.impl;
- import com.goafanti.Interview.bo.UpdateUserBo;
- import com.goafanti.Interview.service.UserArchivesInterviewService;
- import com.goafanti.common.dao.PublicReleaseMapper;
- import com.goafanti.common.dao.UserArchivesInterviewMapper;
- import com.goafanti.common.dao.UserArchivesMapper;
- import com.goafanti.common.model.UserArchives;
- import com.goafanti.common.model.UserArchivesInterview;
- import com.goafanti.core.mybatis.BaseMybatisDao;
- import com.goafanti.core.mybatis.page.Pagination;
- import org.springframework.stereotype.Service;
- import javax.annotation.Resource;
- import java.util.HashMap;
- import java.util.Map;
- /**
- * 客户档案面谈表(UserArchivesInterview)表服务实现类
- *
- * @author makejava
- * @since 2025-04-10 17:09:23
- */
- @Service("userArchivesInterviewService")
- public class UserArchivesInterviewServiceImpl extends BaseMybatisDao<UserArchivesInterviewMapper> implements UserArchivesInterviewService {
- @Resource
- private UserArchivesInterviewMapper userArchivesInterviewMapper;
- @Resource
- private UserArchivesMapper userArchivesMapper;
- @Resource
- private PublicReleaseMapper publicReleaseMapper;
- @Override
- public Pagination<UserArchivesInterview> list(UserArchivesInterview userArchivesInterview, Integer pageNo, Integer pageSize) {
- Map<String, Object> params = new HashMap<>();
- params.put("in", userArchivesInterview);
- return (Pagination<UserArchivesInterview>) findPage("findUserArchivesInterviewList",
- "findUserArchivesInterviewCount", params, pageNo, pageSize);
- }
- /**
- * 通过ID查询单条数据
- *
- * @param id 主键
- * @return 实例对象
- */
- @Override
- public UserArchivesInterview queryById(Integer id) {
- return this.userArchivesInterviewMapper.selectById(id);
- }
- /**
- * 新增数据
- *
- * @param userArchivesInterview 实例对象
- * @return 实例对象
- */
- @Override
- public UserArchivesInterview insert(UserArchivesInterview userArchivesInterview) {
- this.userArchivesInterviewMapper.insert(userArchivesInterview);
- return userArchivesInterview;
- }
- /**
- * 修改数据
- *
- * @param userArchivesInterview 实例对象
- * @return 实例对象
- */
- @Override
- public UserArchivesInterview update(UserArchivesInterview userArchivesInterview) {
- this.userArchivesInterviewMapper.update(userArchivesInterview);
- return this.queryById(userArchivesInterview.getId());
- }
- /**
- * 通过主键删除数据
- *
- * @param id 主键
- * @return 是否成功
- */
- @Override
- public boolean deleteById(Integer id) {
- return this.userArchivesInterviewMapper.deleteById(id) > 0;
- }
- @Override
- public Object updateUser(UpdateUserBo in) {
- //先修改用户档案表
- UserArchives update = new UserArchives();
- update.setId(in.getId());
- update.setPatentCount(in.getPatentCount());
- update.setInventionPatentCount(in.getInventionPatentCount());
- update.setUtilityModelCount(in.getUtilityModelCount());
- update.setAppearancePatentCount(in.getAppearancePatentCount());
- update.setSoftwareWorksCount(in.getSoftwareWorksCount());
- update.setOtherCount(in.getOtherCount());
- update.setCompanyCount(in.getCompanyCount());
- update.setSocialSecurityCount(in.getSocialSecurityCount());
- update.setExternalInvestCount(in.getExternalInvestCount());
- update.setExternalInvestIndustry(in.getExternalInvestIndustry());
- update.setExternalInvestName(in.getExternalInvestName());
- //第一次面谈时间
- // publicReleaseMapper.selectByUid()
- // update.setFirstInterviewDate();
- userArchivesMapper.update(in);
- return null;
- }
- }
|