Ver código fonte

信息平台需求优化V1.3.12

kaick 1 ano atrás
pai
commit
a016d4e0be

+ 58 - 8
src/main/java/com/caimei365/user/controller/CmBrandLandingApi.java

@@ -1,6 +1,7 @@
 package com.caimei365.user.controller;
 package com.caimei365.user.controller;
 
 
 import com.caimei365.user.idempotent.IpSave;
 import com.caimei365.user.idempotent.IpSave;
+import com.caimei365.user.mapper.BaseMapper;
 import com.caimei365.user.mapper.CmBrandBannerMapper;
 import com.caimei365.user.mapper.CmBrandBannerMapper;
 import com.caimei365.user.model.ResponseJson;
 import com.caimei365.user.model.ResponseJson;
 import com.caimei365.user.model.dto.BaikeProductDto;
 import com.caimei365.user.model.dto.BaikeProductDto;
@@ -10,12 +11,14 @@ import com.caimei365.user.model.dto.ShopUpdateDto;
 import com.caimei365.user.model.po.*;
 import com.caimei365.user.model.po.*;
 import com.caimei365.user.model.vo.*;
 import com.caimei365.user.model.vo.*;
 import com.caimei365.user.service.*;
 import com.caimei365.user.service.*;
+import com.caimei365.user.utils.DateUtil;
 import com.github.pagehelper.PageInfo;
 import com.github.pagehelper.PageInfo;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiImplicitParam;
 import io.swagger.annotations.ApiImplicitParam;
 import io.swagger.annotations.ApiImplicitParams;
 import io.swagger.annotations.ApiImplicitParams;
 import io.swagger.annotations.ApiOperation;
 import io.swagger.annotations.ApiOperation;
 import lombok.RequiredArgsConstructor;
 import lombok.RequiredArgsConstructor;
+import org.apache.commons.collections.CollectionUtils;
 import org.apache.commons.lang.StringUtils;
 import org.apache.commons.lang.StringUtils;
 import org.springframework.web.bind.annotation.*;
 import org.springframework.web.bind.annotation.*;
 
 
@@ -42,6 +45,7 @@ public class CmBrandLandingApi {
     private final CmBrandFilesService cmBrandFilesService;
     private final CmBrandFilesService cmBrandFilesService;
 
 
     private final CmQuestionnaireService cmQuestionnaireService;
     private final CmQuestionnaireService cmQuestionnaireService;
+    private final BaseMapper baseMapper;
     @Resource
     @Resource
     private RemoteCallService remoteCallService;
     private RemoteCallService remoteCallService;
 
 
@@ -60,7 +64,7 @@ public class CmBrandLandingApi {
             return ResponseJson.error("source异常!", null);
             return ResponseJson.error("source异常!", null);
         }
         }
         CmBrandBanner cmBrandBanner = new CmBrandBanner().setType("2");
         CmBrandBanner cmBrandBanner = new CmBrandBanner().setType("2");
-        CmBrandLanding landing = new CmBrandLanding().setType("1,2,3");
+        CmBrandLanding landing = new CmBrandLanding().type("1,2,3");
         if (source == 1) {
         if (source == 1) {
             cmBrandBanner.setPcStatus("1");
             cmBrandBanner.setPcStatus("1");
             landing.setPcStatus("1");
             landing.setPcStatus("1");
@@ -72,18 +76,58 @@ public class CmBrandLandingApi {
         HashMap<String, Object> map = new HashMap(2);
         HashMap<String, Object> map = new HashMap(2);
         List<CmBrandBanner> cmBrandBanners = cmBrandBannerService.selectCmBrandBannerList(cmBrandBanner);
         List<CmBrandBanner> cmBrandBanners = cmBrandBannerService.selectCmBrandBannerList(cmBrandBanner);
         List<CmBrandLanding> cmBrandLandings = cmBrandLandingService.selectCmBrandLandingList(landing);
         List<CmBrandLanding> cmBrandLandings = cmBrandLandingService.selectCmBrandLandingList(landing);
-        cmBrandLandings.forEach(cmBrandLanding -> {
-            CmBrandFiles cmBrandFiles = new CmBrandFiles();
-            cmBrandFiles.setId(cmBrandLanding.getVideo());
-            cmBrandFiles.setType("1");
-            cmBrandLanding.setCmBrandFiles(cmBrandLanding.getVideo() == null ? null :
-                    cmBrandFilesService.selectCmBrandFilesList(cmBrandFiles));
-        });
+        if(CollectionUtils.isNotEmpty(cmBrandLandings)) {
+            cmBrandLandings.forEach(cmBrandLanding -> {
+                CmBrandFiles cmBrandFiles = new CmBrandFiles();
+                cmBrandFiles.setId(cmBrandLanding.getVideo());
+                cmBrandFiles.setType("1");
+                cmBrandLanding.setCmBrandFiles(cmBrandLanding.getVideo() == null ? null :
+                        cmBrandFilesService.selectCmBrandFilesList(cmBrandFiles));
+            });
+        }
         map.put("banner", cmBrandBanners);
         map.put("banner", cmBrandBanners);
         map.put("landing", cmBrandLandings);
         map.put("landing", cmBrandLandings);
         return ResponseJson.success(map);
         return ResponseJson.success(map);
     }
     }
 
 
+    /**
+     * 查询供应商落地页资料
+     *
+     * @return source 1PC端,2小程序
+     * @return Map(userPo, clubPo)
+     * @return banner > banner管理
+     * @return landing.type 1成功案例,2视频列表,3文章列表
+     */
+    @ApiOperation("查询供应商落地页资料")
+    @GetMapping("/shopTypeInfo")
+    public ResponseJson<Map<String, Object>> shopTypeInfo(Integer source,CmBrandLanding landing) {
+        if(source==null){
+            return ResponseJson.error("source异常!", null);
+        }
+        if(landing.type()==null){
+            return ResponseJson.error("type异常!", null);
+        }
+        if (source == 1) {
+            landing.setPcStatus("1");
+        }
+        if (source == 2) {
+            landing.setAppStatus("1");
+        }
+        HashMap<String, Object> map = new HashMap(2);
+        List<CmBrandLanding> cmBrandLandings = cmBrandLandingService.selectCmBrandLandingList(landing);
+        if(landing.type().equals("2")&&CollectionUtils.isNotEmpty(cmBrandLandings)){
+            cmBrandLandings.forEach(s -> {
+                CmBrandFiles cmBrandFiles = new CmBrandFiles();
+                cmBrandFiles.setId(s.getVideo());
+                cmBrandFiles.setType("1");
+                s.setCmBrandFiles(s.getVideo() == null ? null :
+                        cmBrandFilesService.selectCmBrandFilesList(cmBrandFiles));
+            });
+        }
+        map.put("landing", CmBrandLandingVO.setValues(cmBrandLandings));
+        return ResponseJson.success(map);
+    }
+
     @ApiOperation("供应商落地页解决方案用户需求")
     @ApiOperation("供应商落地页解决方案用户需求")
     @ApiImplicitParams({
     @ApiImplicitParams({
             @ApiImplicitParam(name = "userId", required = true, value = "userId"),
             @ApiImplicitParam(name = "userId", required = true, value = "userId"),
@@ -104,6 +148,12 @@ public class CmBrandLandingApi {
                     CmQuestionnaire byCmQuestionnaire = cmQuestionnaireService.getByCmQuestionnaire(new CmQuestionnaire()
                     CmQuestionnaire byCmQuestionnaire = cmQuestionnaireService.getByCmQuestionnaire(new CmQuestionnaire()
                             .setLevel(cmQuestionnaire.getLevel())
                             .setLevel(cmQuestionnaire.getLevel())
                             .setMobile(cmQuestionnaire.getMobile()));
                             .setMobile(cmQuestionnaire.getMobile()));
+                    List<String> adminMobileList = baseMapper.findAdminMobileList(1);
+                    if(CollectionUtils.isNotEmpty(adminMobileList)){
+                        adminMobileList.forEach(s->{
+                            remoteCallService.remoteSendSms(0, 1, s, "【采美365】采美后台-供应商落地页-用户需求:"+ DateUtil.formatDateTime(new Date(),"yyyy-MM-dd HH:mm") +"新增一条供应商需求,请及时查看。");
+                        });
+                    }
                     if (byCmQuestionnaire==null||byCmQuestionnaire.getCreateTime().getTime() < (new Date().getTime()-3600000)) {
                     if (byCmQuestionnaire==null||byCmQuestionnaire.getCreateTime().getTime() < (new Date().getTime()-3600000)) {
                         remoteCallService.remoteSendSms(24, 1, cmQuestionnaire.getMobile(), message);
                         remoteCallService.remoteSendSms(24, 1, cmQuestionnaire.getMobile(), message);
                     }
                     }

+ 2 - 0
src/main/java/com/caimei365/user/mapper/BaseMapper.java

@@ -220,6 +220,8 @@ public interface BaseMapper {
      */
      */
     public CmUser getByUser(CmUser user);
     public CmUser getByUser(CmUser user);
 
 
+    public List<String> findAdminMobileList(Integer type);
+
     CmUser findUserByMobile(@Param("mobile") String mobile, @Param("oldUserId") Integer oldUserId, @Param("userIdentity") Integer userIdentity);
     CmUser findUserByMobile(@Param("mobile") String mobile, @Param("oldUserId") Integer oldUserId, @Param("userIdentity") Integer userIdentity);
 
 
 }
 }

+ 0 - 1
src/main/java/com/caimei365/user/mapper/CmBrandLandingMapper.java

@@ -2,7 +2,6 @@ package com.caimei365.user.mapper;
 
 
 import java.util.List;
 import java.util.List;
 import com.caimei365.user.model.po.CmBrandLanding;
 import com.caimei365.user.model.po.CmBrandLanding;
-import com.caimei365.user.model.vo.CmBrandLandingVO;
 import org.apache.ibatis.annotations.Mapper;
 import org.apache.ibatis.annotations.Mapper;
 
 
 /**
 /**

+ 2 - 0
src/main/java/com/caimei365/user/mapper/CmQuestionnaireMapper.java

@@ -39,6 +39,8 @@ public interface CmQuestionnaireMapper
      */
      */
     public List<String> getByIds(CmQuestionnaire cmQuestionnaire);
     public List<String> getByIds(CmQuestionnaire cmQuestionnaire);
 
 
+
+
     /**
     /**
      * 查询用户需求调查
      * 查询用户需求调查
      *
      *

+ 183 - 194
src/main/java/com/caimei365/user/model/po/CmBrandLanding.java

@@ -19,7 +19,7 @@ import java.util.List;
  * @author Kaick
  * @author Kaick
  * @date 2023-05-31
  * @date 2023-05-31
  */
  */
-@Accessors(chain  = true )
+@Accessors(fluent   = true )
 @Data
 @Data
 @Alias("CmBrandLanding")
 @Alias("CmBrandLanding")
 public class CmBrandLanding
 public class CmBrandLanding
@@ -53,6 +53,9 @@ public class CmBrandLanding
     /** picture跳转链接 */
     /** picture跳转链接 */
     private String jumpLink;
     private String jumpLink;
 
 
+    /** picture跳转链接 */
+    private String jumpAppLink;
+
     /** 标题
     /** 标题
  */
  */
     private String title;
     private String title;
@@ -76,7 +79,10 @@ public class CmBrandLanding
     /** 删除状态 0正常,1删除 */
     /** 删除状态 0正常,1删除 */
     private String delFlag;
     private String delFlag;
 
 
-
+    /** 归属者Id(type字段表Id) */
+    private String authorId;
+    /** 子级分类: (type=4){1 大图,2小图}(已弃用),(type=5){1 大图,2小图,2小图}  */
+    private String levelType;
     /** 修改时间 */
     /** 修改时间 */
     @JsonFormat(pattern = "yyyy-MM-dd")
     @JsonFormat(pattern = "yyyy-MM-dd")
     private Date updateTime;
     private Date updateTime;
@@ -86,196 +92,179 @@ public class CmBrandLanding
     /** 文件资料 */
     /** 文件资料 */
     private List<CmBrandFilesVO> cmBrandFiles;
     private List<CmBrandFilesVO> cmBrandFiles;
 
 
-//    public List<CmBrandFiles> getCmBrandFiles() {
-//        return cmBrandFiles;
-//    }
-//
-//    public void setCmBrandFiles(List<CmBrandFiles> cmBrandFiles) {
-//        this.cmBrandFiles = cmBrandFiles;
-//    }
-//
-//    public void setId(String id)
-//    {
-//        this.id = id;
-//    }
-//
-//    public String getId()
-//    {
-//        return id;
-//    }
-//    public void setAuthUserId(String authUserId)
-//    {
-//        this.authUserId = authUserId;
-//    }
-//
-//    public String getAuthUserId()
-//    {
-//        return authUserId;
-//    }
-//    public void setType(String type)
-//    {
-//        this.type = type;
-//    }
-//
-//    public String getType()
-//    {
-//        return type;
-//    }
-//    public void setHeadPcBanner(String headPcBanner)
-//    {
-//        this.headPcBanner = headPcBanner;
-//    }
-//
-//    public String getHeadPcBanner()
-//    {
-//        return headPcBanner;
-//    }
-//    public void setHeadAppBanner(String headAppBanner)
-//    {
-//        this.headAppBanner = headAppBanner;
-//    }
-//
-//    public String getHeadAppBanner()
-//    {
-//        return headAppBanner;
-//    }
-//    public void setJumpStatus(String jumpStatus)
-//    {
-//        this.jumpStatus = jumpStatus;
-//    }
-//
-//    public String getJumpStatus()
-//    {
-//        return jumpStatus;
-//    }
-//    public void setJumpPcPicture(String jumpPcPicture)
-//    {
-//        this.jumpPcPicture = jumpPcPicture;
-//    }
-//
-//    public String getJumpPcPicture()
-//    {
-//        return jumpPcPicture;
-//    }
-//    public void setJumpAppPicture(String jumpAppPicture)
-//    {
-//        this.jumpAppPicture = jumpAppPicture;
-//    }
-//
-//    public String getJumpAppPicture()
-//    {
-//        return jumpAppPicture;
-//    }
-//    public void setJumpLink(String jumpLink)
-//    {
-//        this.jumpLink = jumpLink;
-//    }
-//
-//    public String getJumpLink()
-//    {
-//        return jumpLink;
-//    }
-//    public void setTitle(String title)
-//    {
-//        this.title = title;
-//    }
-//
-//    public String getTitle()
-//    {
-//        return title;
-//    }
-//    public void setContent(String content)
-//    {
-//        this.content = content;
-//    }
-//
-//    public String getContent()
-//    {
-//        return content;
-//    }
-//    public void setVideo(String video)
-//    {
-//        this.video = video;
-//    }
-//
-//    public String getVideo()
-//    {
-//        return video;
-//    }
-//    public void setSort(String sort)
-//    {
-//        this.sort = sort;
-//    }
-//
-//    public String getSort()
-//    {
-//        return sort;
-//    }
-//    public void setPcStatus(String pcStatus)
-//    {
-//        this.pcStatus = pcStatus;
-//    }
-//
-//    public String getPcStatus()
-//    {
-//        return pcStatus;
-//    }
-//    public void setAppStatus(String appStatus)
-//    {
-//        this.appStatus = appStatus;
-//    }
-//
-//    public String getAppStatus()
-//    {
-//        return appStatus;
-//    }
-//    public void setDelFlag(String delFlag)
-//    {
-//        this.delFlag = delFlag;
-//    }
-//
-//    public String getDelFlag()
-//    {
-//        return delFlag;
-//    }
-//    public void setAddTime(Date addTime)
-//    {
-//        this.addTime = addTime;
-//    }
-//
-//    public Date getAddTime()
-//    {
-//        return addTime;
-//    }
-//    public Date getUpdateTime() {
-//        return updateTime;
-//    }
-//
-//    public void setUpdateTime(Date updateTime) {
-//        this.updateTime = updateTime;
-//    }
-//
-//    @Override
-//    public String toString() {
-//        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
-//            .append("id", getId())
-//            .append("authUserId", getAuthUserId())
-//            .append("type", getType())
-//            .append("headPcBanner", getHeadPcBanner())
-//            .append("headAppBanner", getHeadAppBanner())
-//            .append("jumpStatus", getJumpStatus())
-//            .append("jumpPcPicture", getJumpPcPicture())
-//            .append("jumpAppPicture", getJumpAppPicture())
-//            .append("jumpLink", getJumpLink())
-//            .append("title", getTitle())
-//            .append("content", getContent())
-//            .append("video", getVideo())
-//            .append("sort", getSort())
-//            .append("pcStatus", getPcStatus())
-//            .append("appStatus", getAppStatus())
-//            .append("delFlag", getDelFlag())
-//            .append("updateTime", getUpdateTime())
-//            .append("addTime", getAddTime())
-//            .toString();
-//    }
+    public String getAuthorId() {
+        return authorId;
+    }
+
+    public void setAuthorId(String authorId) {
+        this.authorId = authorId;
+    }
+
+    public String getLevelType() {
+        return levelType;
+    }
+
+    public void setLevelType(String levelType) {
+        this.levelType = levelType;
+    }
+
+    public String getId() {
+        return id;
+    }
+
+    public void setId(String id) {
+        this.id = id;
+    }
+
+    public String getAuthUserId() {
+        return authUserId;
+    }
+
+    public void setAuthUserId(String authUserId) {
+        this.authUserId = authUserId;
+    }
+
+    public String getType() {
+        return type;
+    }
+
+    public void setType(String type) {
+        this.type = type;
+    }
+
+    public String getHeadPcBanner() {
+        return headPcBanner;
+    }
+
+    public void setHeadPcBanner(String headPcBanner) {
+        this.headPcBanner = headPcBanner;
+    }
+
+    public String getHeadAppBanner() {
+        return headAppBanner;
+    }
+
+    public void setHeadAppBanner(String headAppBanner) {
+        this.headAppBanner = headAppBanner;
+    }
+
+    public String getJumpStatus() {
+        return jumpStatus;
+    }
+
+    public void setJumpStatus(String jumpStatus) {
+        this.jumpStatus = jumpStatus;
+    }
+
+    public String getJumpPcPicture() {
+        return jumpPcPicture;
+    }
+
+    public void setJumpPcPicture(String jumpPcPicture) {
+        this.jumpPcPicture = jumpPcPicture;
+    }
+
+    public String getJumpAppPicture() {
+        return jumpAppPicture;
+    }
+
+    public void setJumpAppPicture(String jumpAppPicture) {
+        this.jumpAppPicture = jumpAppPicture;
+    }
+
+    public String getJumpLink() {
+        return jumpLink;
+    }
+
+    public void setJumpLink(String jumpLink) {
+        this.jumpLink = jumpLink;
+    }
+
+    public String getJumpAppLink() {
+        return jumpAppLink;
+    }
+
+    public void setJumpAppLink(String jumpAppLink) {
+        this.jumpAppLink = jumpAppLink;
+    }
+
+    public String getTitle() {
+        return title;
+    }
+
+    public void setTitle(String title) {
+        this.title = title;
+    }
+
+    public String getContent() {
+        return content;
+    }
+
+    public void setContent(String content) {
+        this.content = content;
+    }
+
+    public String getVideo() {
+        return video;
+    }
+
+    public void setVideo(String video) {
+        this.video = video;
+    }
+
+    public String getSort() {
+        return sort;
+    }
+
+    public void setSort(String sort) {
+        this.sort = sort;
+    }
+
+    public String getPcStatus() {
+        return pcStatus;
+    }
+
+    public void setPcStatus(String pcStatus) {
+        this.pcStatus = pcStatus;
+    }
+
+    public String getAppStatus() {
+        return appStatus;
+    }
+
+    public void setAppStatus(String appStatus) {
+        this.appStatus = appStatus;
+    }
+
+    public String getDelFlag() {
+        return delFlag;
+    }
+
+    public void setDelFlag(String delFlag) {
+        this.delFlag = delFlag;
+    }
+
+    public Date getUpdateTime() {
+        return updateTime;
+    }
+
+    public void setUpdateTime(Date updateTime) {
+        this.updateTime = updateTime;
+    }
+
+    public Date getAddTime() {
+        return addTime;
+    }
+
+    public void setAddTime(Date addTime) {
+        this.addTime = addTime;
+    }
+
+    public List<CmBrandFilesVO> getCmBrandFiles() {
+        return cmBrandFiles;
+    }
+
+    public void setCmBrandFiles(List<CmBrandFilesVO> cmBrandFiles) {
+        this.cmBrandFiles = cmBrandFiles;
+    }
 }
 }

+ 60 - 6
src/main/java/com/caimei365/user/model/vo/CmBrandLandingVO.java

@@ -1,11 +1,15 @@
 package com.caimei365.user.model.vo;
 package com.caimei365.user.model.vo;
 
 
+import java.util.ArrayList;
 import java.util.Date;
 import java.util.Date;
 
 
+import com.caimei365.user.model.po.CmBrandLanding;
+import com.caimei365.user.model.po.CmDistribution;
 import com.caimei365.user.model.vo.CmBrandFilesVO;
 import com.caimei365.user.model.vo.CmBrandFilesVO;
 import com.fasterxml.jackson.annotation.JsonFormat;
 import com.fasterxml.jackson.annotation.JsonFormat;
 import lombok.Data;
 import lombok.Data;
 import lombok.experimental.Accessors;
 import lombok.experimental.Accessors;
+import org.apache.commons.collections.CollectionUtils;
 import org.apache.ibatis.type.Alias;
 import org.apache.ibatis.type.Alias;
 import org.apache.commons.lang3.builder.ToStringBuilder;
 import org.apache.commons.lang3.builder.ToStringBuilder;
 import org.apache.commons.lang3.builder.ToStringStyle;
 import org.apache.commons.lang3.builder.ToStringStyle;
@@ -24,16 +28,19 @@ import java.util.List;
 @Alias("CmBrandLandingVO")
 @Alias("CmBrandLandingVO")
 public class CmBrandLandingVO implements Serializable
 public class CmBrandLandingVO implements Serializable
 {
 {
-    private static final Long serialVersionUID = 1L;
+    private static final long serialVersionUID = 1L;
 
 
     /** id */
     /** id */
     private String id;
     private String id;
 
 
+    /** 分类:1成功案例,2增长社区-视频列表,3增长社区-文章列表, 4信息中心导航栏(info_type)(已弃用) , 5信息中心首页轮播图 */
+    private String type;
+
     /** 供应商id */
     /** 供应商id */
     private String authUserId;
     private String authUserId;
 
 
-    /** 分类:1成功案例,2增长社区-视频列表,3增长社区-文章列表 */
-    private String type;
+    /** 归属者Id(type字段表Id) */
+    private String authorId;
 
 
     /** pc端picture */
     /** pc端picture */
     private String headPcBanner;
     private String headPcBanner;
@@ -54,21 +61,68 @@ public class CmBrandLandingVO implements Serializable
     private String jumpLink;
     private String jumpLink;
 
 
     /** 标题
     /** 标题
- */
+     */
     private String title;
     private String title;
 
 
     /** 内容
     /** 内容
- */
+     */
     private String content;
     private String content;
 
 
-    /** 视频文件 */
+    /** 视频文件 cm_brand_files表id */
     private String video;
     private String video;
 
 
     /** 排序 */
     /** 排序 */
     private String sort;
     private String sort;
 
 
+    /** pc端status 1启用,0停用 */
+    private String pcStatus;
+
+    /** 移动端status 1启用,0停用 */
+    private String appStatus;
+
+    /** 子级分类: (type=4){1 大图,2小图}(已弃用),(type=5){1 大图,2小图,2小图}  */
+    private String levelType;
+
+    /** 添加时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    private Date addTime;
+
     /** 文件资料 */
     /** 文件资料 */
     List<CmBrandFilesVO> cmBrandFiles;
     List<CmBrandFilesVO> cmBrandFiles;
 
 
+    public static List<CmBrandLandingVO> setValues(List<CmBrandLanding> cmBrandLandingList) {
+        List<CmBrandLandingVO> cmBrandLandingVOList = new ArrayList<>();
+        if(CollectionUtils.isNotEmpty(cmBrandLandingList)) {
+            cmBrandLandingList.forEach(s -> {
+                cmBrandLandingVOList.add(setValue(s));
+            });
+        }
+        return cmBrandLandingVOList;
+    }
+
+    public static CmBrandLandingVO setValue(CmBrandLanding cmBrandLanding) {
+        CmBrandLandingVO cmBrandLandingVO = new CmBrandLandingVO();
+        if(null!=cmBrandLanding) {
+            cmBrandLandingVO.setId(cmBrandLanding.getId());
+            cmBrandLandingVO.setType(cmBrandLanding.getType());
+            cmBrandLandingVO.setAuthUserId(cmBrandLanding.getAuthUserId());
+            cmBrandLandingVO.setAuthorId(cmBrandLanding.getAuthorId());
+            cmBrandLandingVO.setHeadPcBanner(cmBrandLanding.getHeadPcBanner());
+            cmBrandLandingVO.setHeadAppBanner(cmBrandLanding.getHeadAppBanner());
+            cmBrandLandingVO.setJumpStatus(cmBrandLanding.getJumpStatus());
+            cmBrandLandingVO.setJumpPcPicture(cmBrandLanding.getJumpPcPicture());
+            cmBrandLandingVO.setJumpAppPicture(cmBrandLanding.getJumpAppPicture());
+            cmBrandLandingVO.setJumpLink(cmBrandLanding.getJumpLink());
+            cmBrandLandingVO.setTitle(cmBrandLanding.getTitle());
+            cmBrandLandingVO.setContent(cmBrandLanding.getContent());
+            cmBrandLandingVO.setVideo(cmBrandLanding.getVideo());
+            cmBrandLandingVO.setSort(cmBrandLanding.getSort());
+            cmBrandLandingVO.setPcStatus(cmBrandLanding.getPcStatus());
+            cmBrandLandingVO.setAppStatus(cmBrandLanding.getAppStatus());
+            cmBrandLandingVO.setLevelType(cmBrandLanding.getLevelType());
+            cmBrandLandingVO.setAddTime(cmBrandLanding.getAddTime());
+        }
+        return cmBrandLandingVO;
+    }
 
 
 }
 }

+ 0 - 1
src/main/java/com/caimei365/user/service/CmBrandLandingService.java

@@ -1,7 +1,6 @@
 package com.caimei365.user.service;
 package com.caimei365.user.service;
 
 
 import com.caimei365.user.model.po.CmBrandLanding;
 import com.caimei365.user.model.po.CmBrandLanding;
-import com.caimei365.user.model.vo.CmBrandLandingVO;
 
 
 import java.util.List;
 import java.util.List;
 
 

+ 0 - 15
src/main/java/com/caimei365/user/service/CmQuestionnaireService.java

@@ -91,19 +91,4 @@ public interface CmQuestionnaireService
      */
      */
     public int delCmQuestionnaireById(String id);
     public int delCmQuestionnaireById(String id);
 
 
-    /**
-     * 批量新增用户需求调查
-     *
-     * @param cmQuestionnaireList 用户需求调查列表
-     * @return 结果
-     */
-    public void batchAddCmQuestionnaire(List<CmQuestionnaire> cmQuestionnaireList);
-
-    /**
-     * 批量修改用户需求调查
-     *
-     * @param cmQuestionnaireList 用户需求调查列表
-     * @return 结果
-     */
-    public void batchUpdateCmQuestionnaire(List<CmQuestionnaire> cmQuestionnaireList);
 }
 }

+ 0 - 1
src/main/java/com/caimei365/user/service/impl/CmBrandLandingServiceImpl.java

@@ -5,7 +5,6 @@ import java.util.List;
 
 
 import com.caimei365.user.mapper.CmBrandLandingMapper;
 import com.caimei365.user.mapper.CmBrandLandingMapper;
 import com.caimei365.user.model.po.CmBrandLanding;
 import com.caimei365.user.model.po.CmBrandLanding;
-import com.caimei365.user.model.vo.CmBrandLandingVO;
 import com.caimei365.user.service.CmBrandLandingService;
 import com.caimei365.user.service.CmBrandLandingService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 import org.springframework.stereotype.Service;

+ 14 - 53
src/main/java/com/caimei365/user/service/impl/CmQuestionnaireServiceImpl.java

@@ -16,8 +16,7 @@ import com.caimei365.user.service.CmQuestionnaireService;
  * @date 2023-07-14
  * @date 2023-07-14
  */
  */
 @Service
 @Service
-public class CmQuestionnaireServiceImpl implements CmQuestionnaireService
-{
+public class CmQuestionnaireServiceImpl implements CmQuestionnaireService {
     @Autowired
     @Autowired
     private CmQuestionnaireMapper cmQuestionnaireMapper;
     private CmQuestionnaireMapper cmQuestionnaireMapper;
 
 
@@ -28,8 +27,7 @@ public class CmQuestionnaireServiceImpl implements CmQuestionnaireService
      * @return 用户需求调查
      * @return 用户需求调查
      */
      */
     @Override
     @Override
-    public CmQuestionnaire getCmQuestionnaireById(String id)
-    {
+    public CmQuestionnaire getCmQuestionnaireById(String id) {
         return cmQuestionnaireMapper.getCmQuestionnaireById(id);
         return cmQuestionnaireMapper.getCmQuestionnaireById(id);
     }
     }
 
 
@@ -40,8 +38,7 @@ public class CmQuestionnaireServiceImpl implements CmQuestionnaireService
      * @return String
      * @return String
      */
      */
     @Override
     @Override
-    public String getById(CmQuestionnaire cmQuestionnaire)
-    {
+    public String getById(CmQuestionnaire cmQuestionnaire) {
         return cmQuestionnaireMapper.getById(cmQuestionnaire);
         return cmQuestionnaireMapper.getById(cmQuestionnaire);
     }
     }
 
 
@@ -52,8 +49,7 @@ public class CmQuestionnaireServiceImpl implements CmQuestionnaireService
      * @return List<String>
      * @return List<String>
      */
      */
     @Override
     @Override
-    public List<String> getByIds(CmQuestionnaire cmQuestionnaire)
-    {
+    public List<String> getByIds(CmQuestionnaire cmQuestionnaire) {
         return cmQuestionnaireMapper.getByIds(cmQuestionnaire);
         return cmQuestionnaireMapper.getByIds(cmQuestionnaire);
     }
     }
 
 
@@ -64,8 +60,7 @@ public class CmQuestionnaireServiceImpl implements CmQuestionnaireService
      * @return 用户需求调查
      * @return 用户需求调查
      */
      */
     @Override
     @Override
-    public CmQuestionnaire getByCmQuestionnaire(CmQuestionnaire cmQuestionnaire)
-    {
+    public CmQuestionnaire getByCmQuestionnaire(CmQuestionnaire cmQuestionnaire) {
         return cmQuestionnaireMapper.getByCmQuestionnaire(cmQuestionnaire);
         return cmQuestionnaireMapper.getByCmQuestionnaire(cmQuestionnaire);
     }
     }
 
 
@@ -76,10 +71,10 @@ public class CmQuestionnaireServiceImpl implements CmQuestionnaireService
      * @return 用户需求调查
      * @return 用户需求调查
      */
      */
     @Override
     @Override
-    public List<CmQuestionnaire> getCmQuestionnaireList(CmQuestionnaire cmQuestionnaire)
-    {
+    public List<CmQuestionnaire> getCmQuestionnaireList(CmQuestionnaire cmQuestionnaire) {
         return cmQuestionnaireMapper.getCmQuestionnaireList(cmQuestionnaire);
         return cmQuestionnaireMapper.getCmQuestionnaireList(cmQuestionnaire);
     }
     }
+
     /**
     /**
      * 查询用户需求调查记录总数
      * 查询用户需求调查记录总数
      *
      *
@@ -87,8 +82,7 @@ public class CmQuestionnaireServiceImpl implements CmQuestionnaireService
      * @return 用户需求调查
      * @return 用户需求调查
      */
      */
     @Override
     @Override
-    public int getCmQuestionnaireCount(CmQuestionnaire cmQuestionnaire)
-    {
+    public int getCmQuestionnaireCount(CmQuestionnaire cmQuestionnaire) {
         return cmQuestionnaireMapper.getCmQuestionnaireCount(cmQuestionnaire);
         return cmQuestionnaireMapper.getCmQuestionnaireCount(cmQuestionnaire);
     }
     }
 
 
@@ -99,8 +93,7 @@ public class CmQuestionnaireServiceImpl implements CmQuestionnaireService
      * @return 结果
      * @return 结果
      */
      */
     @Override
     @Override
-    public int addCmQuestionnaire(CmQuestionnaire cmQuestionnaire)
-    {
+    public int addCmQuestionnaire(CmQuestionnaire cmQuestionnaire) {
         cmQuestionnaire.setCreateTime(new Date());
         cmQuestionnaire.setCreateTime(new Date());
         return cmQuestionnaireMapper.addCmQuestionnaire(cmQuestionnaire);
         return cmQuestionnaireMapper.addCmQuestionnaire(cmQuestionnaire);
     }
     }
@@ -112,8 +105,7 @@ public class CmQuestionnaireServiceImpl implements CmQuestionnaireService
      * @return 结果
      * @return 结果
      */
      */
     @Override
     @Override
-    public int updateCmQuestionnaire(CmQuestionnaire cmQuestionnaire)
-    {
+    public int updateCmQuestionnaire(CmQuestionnaire cmQuestionnaire) {
         cmQuestionnaire.setUpdateTime(new Date());
         cmQuestionnaire.setUpdateTime(new Date());
         return cmQuestionnaireMapper.updateCmQuestionnaire(cmQuestionnaire);
         return cmQuestionnaireMapper.updateCmQuestionnaire(cmQuestionnaire);
     }
     }
@@ -125,9 +117,8 @@ public class CmQuestionnaireServiceImpl implements CmQuestionnaireService
      * @return 结果
      * @return 结果
      */
      */
     @Override
     @Override
-    public int delCmQuestionnaireByIds(String[] ids)
-    {
-        return cmQuestionnaireMapper.updateDelCmQuestionnaireByIds(ids,1);
+    public int delCmQuestionnaireByIds(String[] ids) {
+        return cmQuestionnaireMapper.updateDelCmQuestionnaireByIds(ids, 1);
         //return cmQuestionnaireMapper.delCmQuestionnaireByIds(ids);
         //return cmQuestionnaireMapper.delCmQuestionnaireByIds(ids);
     }
     }
 
 
@@ -138,39 +129,9 @@ public class CmQuestionnaireServiceImpl implements CmQuestionnaireService
      * @return 结果
      * @return 结果
      */
      */
     @Override
     @Override
-    public int delCmQuestionnaireById(String id)
-    {
+    public int delCmQuestionnaireById(String id) {
         return cmQuestionnaireMapper.updateCmQuestionnaire(new CmQuestionnaire().setId(id).setDelFlag(1));
         return cmQuestionnaireMapper.updateCmQuestionnaire(new CmQuestionnaire().setId(id).setDelFlag(1));
         //return cmQuestionnaireMapper.delCmQuestionnaireById(id);
         //return cmQuestionnaireMapper.delCmQuestionnaireById(id);
     }
     }
+}
 
 
-    /**
-     * 批量新增用户需求调查
-     *
-     * @param cmQuestionnaireList 用户需求调查列表
-     * @return 结果
-     */
-    @Override
-    public void batchAddCmQuestionnaire(List<CmQuestionnaire> cmQuestionnaireList)
-    {
-            for (CmQuestionnaire cmQuestionnaire : cmQuestionnaireList)
-            {
-                    cmQuestionnaireMapper.addCmQuestionnaire(cmQuestionnaire);
-            }
-    }
-
-    /**
-     * 批量修改用户需求调查
-     *
-     * @param cmQuestionnaireList 用户需求调查列表
-     * @return 结果
-     */
-    @Override
-    public void batchUpdateCmQuestionnaire(List<CmQuestionnaire> cmQuestionnaireList)
-    {
-            for (CmQuestionnaire cmQuestionnaire : cmQuestionnaireList)
-            {
-                   cmQuestionnaireMapper.updateCmQuestionnaire(cmQuestionnaire);
-            }
-        }
-    }

+ 7 - 1
src/main/java/com/caimei365/user/utils/DateUtil.java

@@ -123,6 +123,12 @@ public class DateUtil {
     public static String formatDateTime(Date date) {
     public static String formatDateTime(Date date) {
         return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(date);
         return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(date);
     }
     }
+    /**
+     * 得到日期时间字符串,转换格式(yyyy-MM-dd HH:mm:ss)
+     */
+    public static String formatDateTime(Date date,String format) {
+        return new SimpleDateFormat(format!=null?format:"yyyy-MM-dd HH:mm:ss").format(date);
+    }
 
 
     /**
     /**
      * date2比date1多的天数
      * date2比date1多的天数
@@ -159,4 +165,4 @@ public class DateUtil {
             return day2 - day1;
             return day2 - day1;
         }
         }
     }
     }
-}
+}

+ 10 - 0
src/main/resources/mapper/BaseMapper.xml

@@ -676,4 +676,14 @@
         limit 0,1
         limit 0,1
     </select>
     </select>
 
 
+    <select id="findAdminMobileList" parameterType="String" resultType="String">
+        select
+        cm_admin_mobile.mobile,
+        from cm_admin_mobile AS cm_admin_mobile
+        <where>  cm_admin_mobile.delFlag = 0 and cm_admin_mobile.enabledStatus = 1
+            <if test="type != null  and type != ''"> and cm_admin_mobile.type = #{type}</if>
+        </where>
+        group by cm_admin_mobile.id
+        order by cm_admin_mobile.createTime desc
+    </select>
 </mapper>
 </mapper>

+ 1 - 0
src/main/resources/mapper/CmBrandBannerMapper.xml

@@ -55,6 +55,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="updateTime != null "> and updateTime = #{updateTime}</if>
             <if test="updateTime != null "> and updateTime = #{updateTime}</if>
             <if test="addTime != null "> and addTime = #{addTime}</if>
             <if test="addTime != null "> and addTime = #{addTime}</if>
         </where>
         </where>
+        order by sort desc,addTime desc
     </select>
     </select>
 
 
     <select id="selectCmBrandBannerById" parameterType="String" resultMap="CmBrandBannerResult">
     <select id="selectCmBrandBannerById" parameterType="String" resultMap="CmBrandBannerResult">

+ 4 - 1
src/main/resources/mapper/CmBrandLandingMapper.xml

@@ -14,6 +14,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <result property="jumpPcPicture"    column="jumpPcPicture"    />
         <result property="jumpPcPicture"    column="jumpPcPicture"    />
         <result property="jumpAppPicture"    column="jumpAppPicture"    />
         <result property="jumpAppPicture"    column="jumpAppPicture"    />
         <result property="jumpLink"    column="jumpLink"    />
         <result property="jumpLink"    column="jumpLink"    />
+        <result property="jumpAppLink"    column="jumpAppLink"    />
         <result property="title"    column="title"    />
         <result property="title"    column="title"    />
         <result property="content"    column="content"    />
         <result property="content"    column="content"    />
         <result property="video"    column="video"    />
         <result property="video"    column="video"    />
@@ -27,7 +28,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
 
 
 
     <sql id="selectCmBrandLandingVo">
     <sql id="selectCmBrandLandingVo">
-        select id, authUserId, type, headPcBanner, headAppBanner, jumpStatus, jumpPcPicture, jumpAppPicture, jumpLink, title, content, video, sort, pcStatus, appStatus, delFlag, updateTime, addTime from cm_brand_landing
+        select id, authUserId, type, headPcBanner, headAppBanner, jumpStatus, jumpPcPicture, jumpAppPicture, jumpLink,jumpAppLink, title, content, video, sort, pcStatus, appStatus, delFlag, updateTime, addTime from cm_brand_landing
     </sql>
     </sql>
 
 
     <select id="selectCmBrandLandingList" parameterType="com.caimei365.user.model.po.CmBrandLanding" resultMap="CmBrandLandingResult">
     <select id="selectCmBrandLandingList" parameterType="com.caimei365.user.model.po.CmBrandLanding" resultMap="CmBrandLandingResult">
@@ -56,6 +57,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="updateTime != null "> and updateTime = #{updateTime}</if>
             <if test="updateTime != null "> and updateTime = #{updateTime}</if>
             <if test="addTime != null "> and addTime = #{addTime}</if>
             <if test="addTime != null "> and addTime = #{addTime}</if>
         </where>
         </where>
+        order by sort desc,addTime desc
     </select>
     </select>
 
 
     <select id="selectCmBrandLandingById" parameterType="String" resultMap="CmBrandLandingResult">
     <select id="selectCmBrandLandingById" parameterType="String" resultMap="CmBrandLandingResult">
@@ -116,6 +118,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="jumpPcPicture != null">jumpPcPicture = #{jumpPcPicture},</if>
             <if test="jumpPcPicture != null">jumpPcPicture = #{jumpPcPicture},</if>
             <if test="jumpAppPicture != null">jumpAppPicture = #{jumpAppPicture},</if>
             <if test="jumpAppPicture != null">jumpAppPicture = #{jumpAppPicture},</if>
             <if test="jumpLink != null">jumpLink = #{jumpLink},</if>
             <if test="jumpLink != null">jumpLink = #{jumpLink},</if>
+            <if test="jumpAppLink != null">jumpAppLink = #{jumpAppLink},</if>
             <if test="title != null">title = #{title},</if>
             <if test="title != null">title = #{title},</if>
             <if test="content != null">content = #{content},</if>
             <if test="content != null">content = #{content},</if>
             <if test="video != null">video = #{video},</if>
             <if test="video != null">video = #{video},</if>

+ 2 - 0
src/main/resources/mapper/CmQuestionnaireMapper.xml

@@ -165,6 +165,8 @@
         where  cm_questionnaire.delFlag = 0 and cm_questionnaire.id = #{id}
         where  cm_questionnaire.delFlag = 0 and cm_questionnaire.id = #{id}
     </select>
     </select>
 
 
+
+
     <select id="getByIds" parameterType="CmQuestionnaire" resultMap="CmQuestionnaireResult">
     <select id="getByIds" parameterType="CmQuestionnaire" resultMap="CmQuestionnaireResult">
         select id
         select id
         from cm_questionnaire AS cm_questionnaire
         from cm_questionnaire AS cm_questionnaire