diff --git a/jianshui-admin/src/main/java/com/jianshui/web/controller/system/CompanyserviceController.java b/jianshui-admin/src/main/java/com/jianshui/web/controller/system/CompanyserviceController.java index d1639ff..8de2d7a 100644 --- a/jianshui-admin/src/main/java/com/jianshui/web/controller/system/CompanyserviceController.java +++ b/jianshui-admin/src/main/java/com/jianshui/web/controller/system/CompanyserviceController.java @@ -3,6 +3,7 @@ package com.jianshui.web.controller.system; import java.util.List; import javax.servlet.http.HttpServletResponse; +import com.jianshui.common.constant.RebackType; import com.jianshui.common.core.domain.entity.Companyservice; import org.apache.commons.lang3.StringUtils; import org.springframework.security.access.prepost.PreAuthorize; @@ -57,6 +58,7 @@ public class CompanyserviceController extends BaseController public void export(HttpServletResponse response, Companyservice companyservice) { List list = companyserviceService.selectCompanyserviceList(companyservice); + list.forEach(e -> e.setRebackType(RebackType.getRebackType(e.getRebackType()))); ExcelUtil util = new ExcelUtil(Companyservice.class); util.exportExcel(response, list, "销方信息数据"); } diff --git a/jianshui-common/src/main/java/com/jianshui/common/constant/RebackType.java b/jianshui-common/src/main/java/com/jianshui/common/constant/RebackType.java new file mode 100644 index 0000000..e3f8870 --- /dev/null +++ b/jianshui-common/src/main/java/com/jianshui/common/constant/RebackType.java @@ -0,0 +1,32 @@ +package com.jianshui.common.constant; + +public enum RebackType { + REBACK_TYPE_1("1", "系统推送"), + REBACK_TYPE_2("2", "SAP推送"), + REBACK_TYPE_3("3", "数据回写"); + + private String rebackTypeCode; + private String rebackTypeMsg; + + RebackType(String rebackTypeCode, String rebackTypeMsg){ + this.rebackTypeCode = rebackTypeCode; + this.rebackTypeMsg = rebackTypeMsg; + } + + public String getRebackTypeMsg(){ + return rebackTypeMsg; + } + + public String getrebackTypeCode(){ + return rebackTypeCode; + } + + public static String getRebackType(String code){ + for(RebackType rebackType : RebackType.values()){ + if(rebackType.getrebackTypeCode().equals(code)){ + return rebackType.getRebackTypeMsg(); + } + } + return "未知回调方式"; + } +} diff --git a/jianshui-common/src/main/java/com/jianshui/common/core/domain/entity/Companyservice.java b/jianshui-common/src/main/java/com/jianshui/common/core/domain/entity/Companyservice.java index b31aa2d..5058931 100644 --- a/jianshui-common/src/main/java/com/jianshui/common/core/domain/entity/Companyservice.java +++ b/jianshui-common/src/main/java/com/jianshui/common/core/domain/entity/Companyservice.java @@ -20,6 +20,7 @@ public class Companyservice { /** * 企业编号 */ + @Excel(name = "企业编号") private Long companyid; /** @@ -99,7 +100,7 @@ public class Companyservice { * 回写方式 */ @Excel(name = "回写方式") - private Long rebackType; + private String rebackType; /** 分机号 */ // @Excel(name = "分机号") @@ -281,11 +282,11 @@ public class Companyservice { this.rebackurl = rebackurl; } - public Long getRebackType() { + public String getRebackType() { return rebackType; } - public void setRebackType(Long rebackType) { + public void setRebackType(String rebackType) { this.rebackType = rebackType; } diff --git a/jianshui-system/src/main/java/com/jianshui/system/domain/ServiceManage.java b/jianshui-system/src/main/java/com/jianshui/system/domain/ServiceManage.java index 300701f..0c9bace 100644 --- a/jianshui-system/src/main/java/com/jianshui/system/domain/ServiceManage.java +++ b/jianshui-system/src/main/java/com/jianshui/system/domain/ServiceManage.java @@ -21,9 +21,11 @@ public class ServiceManage extends BaseEntity private Long id; /** 企业ID */ + @Excel(name = "企业ID") private Long companyId; /** 服务类型 */ + @Excel(name = "服务类型") private String serviceKey; /** 服务状态 */ diff --git a/jianshui-system/src/main/resources/mapper/system/CompanyserviceMapper.xml b/jianshui-system/src/main/resources/mapper/system/CompanyserviceMapper.xml index 144609b..c2fabfe 100644 --- a/jianshui-system/src/main/resources/mapper/system/CompanyserviceMapper.xml +++ b/jianshui-system/src/main/resources/mapper/system/CompanyserviceMapper.xml @@ -66,7 +66,7 @@ and sellertax = #{sellertax} and sellername like concat('%', #{sellername}, '%') and phone = #{phone} - and reback_type = #{rebackType} + and reback_type = #{rebackType} @@ -106,7 +106,7 @@ identity, rebackurl, - reback_type, + reback_type, createtime, create_user, @@ -125,7 +125,7 @@ #{identity}, #{rebackurl}, - #{rebackType}, + #{rebackType}, #{createTime}, #{createUser}, @@ -149,7 +149,7 @@ rebackurl = #{rebackurl}, - reback_type = #{rebackType}, + reback_type = #{rebackType}, createtime = #{createTime}, diff --git a/jianshui-ui/src/views/system/manageservices/index.vue b/jianshui-ui/src/views/system/manageservices/index.vue index 94924ad..4c09dfc 100644 --- a/jianshui-ui/src/views/system/manageservices/index.vue +++ b/jianshui-ui/src/views/system/manageservices/index.vue @@ -197,7 +197,7 @@ /> - +