From 177249c76aeea0b4bf8d8816d4994e3b445b45ce Mon Sep 17 00:00:00 2001 From: huanghongfa <huanghongfa123456> Date: 星期四, 02 九月 2021 10:39:34 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/zzj' into zzj --- springcloud_k8s_panzhihuazhihuishequ/service_grid/src/main/java/com/panzhihua/service_grid/service/impl/EventApplicationAppReleaseServiceImpl.java | 63 +++++++++++++++++++------------ 1 files changed, 39 insertions(+), 24 deletions(-) diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_grid/src/main/java/com/panzhihua/service_grid/service/impl/EventApplicationAppReleaseServiceImpl.java b/springcloud_k8s_panzhihuazhihuishequ/service_grid/src/main/java/com/panzhihua/service_grid/service/impl/EventApplicationAppReleaseServiceImpl.java index 6118712..6821d6a 100644 --- a/springcloud_k8s_panzhihuazhihuishequ/service_grid/src/main/java/com/panzhihua/service_grid/service/impl/EventApplicationAppReleaseServiceImpl.java +++ b/springcloud_k8s_panzhihuazhihuishequ/service_grid/src/main/java/com/panzhihua/service_grid/service/impl/EventApplicationAppReleaseServiceImpl.java @@ -1,5 +1,12 @@ package com.panzhihua.service_grid.service.impl; +import java.util.Date; + +import javax.annotation.Resource; + +import org.springframework.beans.BeanUtils; +import org.springframework.stereotype.Service; + import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; @@ -10,15 +17,11 @@ import com.panzhihua.common.model.vos.R; import com.panzhihua.common.model.vos.grid.EventApplicationAppReleaseDetailsVO; import com.panzhihua.common.model.vos.grid.EventApplicationAppReleaseVO; -import com.panzhihua.service_grid.dao.*; -import com.panzhihua.service_grid.model.dos.*; +import com.panzhihua.service_grid.dao.EventApplicationAppReleaseMapper; +import com.panzhihua.service_grid.model.dos.EventApplicationAppReleaseDO; import com.panzhihua.service_grid.service.EventApplicationAppReleaseService; -import lombok.extern.slf4j.Slf4j; -import org.springframework.stereotype.Service; -import org.springframework.beans.BeanUtils; -import javax.annotation.Resource; -import java.util.Date; +import lombok.extern.slf4j.Slf4j; /** * @auther lyq @@ -27,20 +30,24 @@ */ @Slf4j @Service -public class EventApplicationAppReleaseServiceImpl extends ServiceImpl<EventApplicationAppReleaseMapper, EventApplicationAppReleaseDO> implements EventApplicationAppReleaseService { +public class EventApplicationAppReleaseServiceImpl + extends ServiceImpl<EventApplicationAppReleaseMapper, EventApplicationAppReleaseDO> + implements EventApplicationAppReleaseService { @Resource private EventApplicationAppReleaseMapper eventApplicationAppReleaseMapper; + /** * 新增APP应用版本信息 + * * @param eventApplicationAppReleaseAddDTO * @return 新增结果 */ - public R add(EventApplicationAppReleaseAddDTO eventApplicationAppReleaseAddDTO){ + public R add(EventApplicationAppReleaseAddDTO eventApplicationAppReleaseAddDTO) { EventApplicationAppReleaseDO eventApplicationAppReleaseDO = new EventApplicationAppReleaseDO(); BeanUtils.copyProperties(eventApplicationAppReleaseAddDTO, eventApplicationAppReleaseDO); eventApplicationAppReleaseDO.setCreateAt(new Date()); - if(eventApplicationAppReleaseMapper.insert(eventApplicationAppReleaseDO)>0){ + if (eventApplicationAppReleaseMapper.insert(eventApplicationAppReleaseDO) > 0) { return R.ok(); } return R.fail(); @@ -48,14 +55,15 @@ /** * 修改APP应用版本信息 + * * @param eventApplicationAppReleaseEditDTO * @return 维护结果 */ - public R edit(EventApplicationAppReleaseEditDTO eventApplicationAppReleaseEditDTO){ + public R edit(EventApplicationAppReleaseEditDTO eventApplicationAppReleaseEditDTO) { EventApplicationAppReleaseDO eventApplicationAppReleaseDO = new EventApplicationAppReleaseDO(); BeanUtils.copyProperties(eventApplicationAppReleaseEditDTO, eventApplicationAppReleaseDO); - //eventApplicationAppReleaseDO.setUpdateAt(new Date()); - if(eventApplicationAppReleaseMapper.updateById(eventApplicationAppReleaseDO)>0){ + // eventApplicationAppReleaseDO.setUpdateAt(new Date()); + if (eventApplicationAppReleaseMapper.updateById(eventApplicationAppReleaseDO) > 0) { return R.ok(); } return R.fail(); @@ -63,15 +71,17 @@ /** * 分页查找APP应用版本信息 + * * @param pageEventApplicationAppReleaseDTO * @return 维护结果 */ - public R<IPage<EventApplicationAppReleaseVO>> query(PageEventApplicationAppReleaseDTO pageEventApplicationAppReleaseDTO){ - Page page = new Page(1,10); - if(pageEventApplicationAppReleaseDTO.getPageNum()!=null) { + public R<IPage<EventApplicationAppReleaseVO>> + query(PageEventApplicationAppReleaseDTO pageEventApplicationAppReleaseDTO) { + Page page = new Page(1, 10); + if (pageEventApplicationAppReleaseDTO.getPageNum() != null) { page.setCurrent(pageEventApplicationAppReleaseDTO.getPageNum()); } - if(pageEventApplicationAppReleaseDTO.getPageSize()!=null) { + if (pageEventApplicationAppReleaseDTO.getPageSize() != null) { page.setSize(pageEventApplicationAppReleaseDTO.getPageSize()); } return R.ok(eventApplicationAppReleaseMapper.findByPage(page, pageEventApplicationAppReleaseDTO)); @@ -79,22 +89,26 @@ /** * 删除APP应用版本信息 + * * @param EventApplicationAppReleaseDeleteDTO * @return 平台用户信息 */ - public R delete(EventApplicationAppReleaseDeleteDTO EventApplicationAppReleaseDeleteDTO){ + public R delete(EventApplicationAppReleaseDeleteDTO EventApplicationAppReleaseDeleteDTO) { return R.fail(); } /** * 查询APP应用版本信息详细信息 - * @param id APP应用版本信息 id + * + * @param id + * APP应用版本信息 id * @return 查找结果 */ - public R<EventApplicationAppReleaseDetailsVO> eventApplicationAppReleaseDetails(Long id){ + public R<EventApplicationAppReleaseDetailsVO> eventApplicationAppReleaseDetails(Long id) { EventApplicationAppReleaseDO eventApplicationAppReleaseDO = eventApplicationAppReleaseMapper.selectById(id); - if(eventApplicationAppReleaseDO!=null) { - EventApplicationAppReleaseDetailsVO eventApplicationAppReleaseDetailsVO = new EventApplicationAppReleaseDetailsVO(); + if (eventApplicationAppReleaseDO != null) { + EventApplicationAppReleaseDetailsVO eventApplicationAppReleaseDetailsVO = + new EventApplicationAppReleaseDetailsVO(); BeanUtils.copyProperties(eventApplicationAppReleaseDO, eventApplicationAppReleaseDetailsVO); return R.ok(eventApplicationAppReleaseDetailsVO); } @@ -103,10 +117,11 @@ /** * 获取最新版本信息 - * @return 版本信息 + * + * @return 版本信息 */ @Override - public R editionUpdate(){ + public R editionUpdate() { return R.ok(this.baseMapper.editionUpdate()); } -- Gitblit v1.7.1