Преглед на файлове

//..merchant

release_toaliyun_real
xhxu преди 2 години
родител
ревизия
6acae37c6b
променени са 3 файла, в които са добавени 21 реда и са изтрити 1 реда
  1. +7
    -0
      mallinkService/src/main/java/com/iformall/domain/dto/WxMerchantDto.java
  2. +4
    -1
      mallinkService/src/main/java/com/iformall/service/impl/WxMerchantServiceImpl.java
  3. +10
    -0
      mallinkService/src/main/resources/mapper/WxMerchantMapper.xml

+ 7
- 0
mallinkService/src/main/java/com/iformall/domain/dto/WxMerchantDto.java Целия файл

@@ -1,9 +1,12 @@
package com.iformall.domain.dto;

import com.baomidou.mybatisplus.annotation.TableField;
import com.iformall.domain.po.base.TenantEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.List;

@Data
@EqualsAndHashCode(callSuper = true)
public class WxMerchantDto extends TenantEntity {
@@ -40,6 +43,10 @@ public class WxMerchantDto extends TenantEntity {
@io.swagger.annotations.ApiModelProperty(value = "是否显示在广场", name = "isPrivate")
private Integer isPrivate;

@io.swagger.annotations.ApiModelProperty(value="EnumMerchantAdmin",name="isAdmin")
private Integer isAdmin;
private List<Integer> adminTypes;

@io.swagger.annotations.ApiModelProperty(value = "品牌名称", name = "brandName")
private String brandName;



+ 4
- 1
mallinkService/src/main/java/com/iformall/service/impl/WxMerchantServiceImpl.java Целия файл

@@ -206,6 +206,9 @@ public class WxMerchantServiceImpl implements WxMerchantService {
List<Long> merchantIds = getFloorBuildMerchantIds(wxMerchantDto, null, wxMerchantDto.getBuilding(), wxMerchantDto.getFloor(), null, null);
wxMerchantDto.setIds(merchantIds);
}
if(wxMerchantDto.getIsAdmin() == null){
wxMerchantDto.setAdminTypes(EnumMerchantAdmin.getOrdinaryTypes());
}
PageInfo<WxMerchant> pageInfo = PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxMerchantMapper.findListCVo(wxMerchantDto));
PageInfo<WxMerchantVo> retPageInfo = new PageInfo<WxMerchantVo>();
retPageInfo.setPageNum(pageInfo.getPageNum());
@@ -291,7 +294,7 @@ public class WxMerchantServiceImpl implements WxMerchantService {
@Override
public List<Long> findIdList(WxMerchant record) {
if(record == null){
if(record.getIsAdmin() == null){
record.setAdminTypes(EnumMerchantAdmin.getOrdinaryTypes());
}
return wxMerchantMapper.findIdList(record);


+ 10
- 0
mallinkService/src/main/resources/mapper/WxMerchantMapper.xml Целия файл

@@ -284,10 +284,20 @@
<if test=" null != isPrivate">
and m.`is_private` = #{isPrivate}
</if>
<if test=" null != isAdmin ">
and m.`is_admin` = #{isAdmin}
</if>
<if test=" null != id">
and m.`id` = #{id}
</if>

<if test=" null != adminTypes and adminTypes.size > 0">
and m.`is_admin` in
<foreach collection="adminTypes" index="index" item="typeItem" open="(" separator="," close=")">
#{typeItem}
</foreach>
</if>
<if test=" null != ids ">
and m.id in


Зареждане…
Отказ
Запис