Browse Source

1、定制功能修改-支持修改功能说明。2.列表查询sql修改

dev_shibei_match
zhangyongzhangyong 5 years ago
parent
commit
352c936f4f
  1. 2
      epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/controller/FunctionCustomizedController.java
  2. 2
      epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/FunctionCustomizedService.java
  3. 8
      epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/impl/FunctionCustomizedServiceImpl.java
  4. 4
      epmet-module/oper-customize/oper-customize-server/src/main/resources/mapper/FunctionCustomizedDao.xml

2
epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/controller/FunctionCustomizedController.java

@ -143,7 +143,7 @@ public class FunctionCustomizedController {
/** /**
* 定制功能修改 * 定制功能修改
* 有客户在使用该功能时则不允许修改上下架状态业务域名和外链地址所属端app, * 有客户在使用该功能时则不允许修改上下架状态业务域名和外链地址所属端app,
* 只能修改功能名称和大小图标 * 只能修改功能名称和大小图标功能说明
* 修改的要判断是否有客户在使用有用的要批量更新已使用客户数据 * 修改的要判断是否有客户在使用有用的要批量更新已使用客户数据
* *
* @param formDTO * @param formDTO

2
epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/FunctionCustomizedService.java

@ -130,7 +130,7 @@ public interface FunctionCustomizedService extends BaseService<FunctionCustomize
/** /**
* 定制功能修改 * 定制功能修改
* 有客户在使用该功能时则不允许修改上下架状态业务域名和外链地址所属端app, * 有客户在使用该功能时则不允许修改上下架状态业务域名和外链地址所属端app,
* 只能修改功能名称和大小图标 * 只能修改功能名称和大小图标功能说明
* 修改的要判断是否有客户在使用有用的要批量更新已使用客户数据 * 修改的要判断是否有客户在使用有用的要批量更新已使用客户数据
* *
* @param formDTO * @param formDTO

8
epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/impl/FunctionCustomizedServiceImpl.java

@ -200,18 +200,18 @@ public class FunctionCustomizedServiceImpl extends BaseServiceImpl<FunctionCusto
&& customizedDTO.getIconSmallImg().equals(customizedId.get(i).getIconSmallImg()) && customizedDTO.getIconSmallImg().equals(customizedId.get(i).getIconSmallImg())
&& customizedDTO.getDomainName().equals(customizedId.get(i).getDomainName()) && customizedDTO.getDomainName().equals(customizedId.get(i).getDomainName())
&& customizedDTO.getTargetLink().equals(customizedId.get(i).getTargetLink()) ){ && customizedDTO.getTargetLink().equals(customizedId.get(i).getTargetLink()) ){
// 这个功能,客户使用的是默认的,则判断本次修改的字段,如果是功能名称和大小图标,则批量更新客户数据,负责提示 不能修改 // 这个功能,客户使用的是默认的,则判断本次修改的字段,如果是功能名称和大小图标、功能说明,则批量更新客户数据,负责提示 不能修改
if (!formDTO.getShoppingStatus().equals(customizedDTO.getShoppingStatus()) if (!formDTO.getShoppingStatus().equals(customizedDTO.getShoppingStatus())
|| !formDTO.getFunctionExplain().equals(customizedDTO.getFunctionExplain())
|| !formDTO.getTargetLink().equals(customizedDTO.getTargetLink()) || !formDTO.getTargetLink().equals(customizedDTO.getTargetLink())
|| !formDTO.getDomainName().equals(customizedDTO.getDomainName()) || !formDTO.getDomainName().equals(customizedDTO.getDomainName())
|| !formDTO.getFromApp().equals(customizedDTO.getFromApp()) ){ || !formDTO.getFromApp().equals(customizedDTO.getFromApp()) ){
// 4.1 如果修改的内容是其他字段,则返回语句 // 4.1 如果修改的内容是其他字段,则返回语句
tipCustomizedInfoUserId.append(customizedId.get(i).getId() + ","); tipCustomizedInfoUserId.append(customizedId.get(i).getId() + ",");
} else if (!formDTO.getFunctionName().equals(customizedDTO.getCustomizedName()) } else if (!formDTO.getFunctionName().equals(customizedDTO.getCustomizedName())
|| !formDTO.getFunctionExplain().equals(customizedDTO.getFunctionExplain())
|| !formDTO.getIconLargeImg().equals(customizedDTO.getIconLargeImg()) || !formDTO.getIconLargeImg().equals(customizedDTO.getIconLargeImg())
|| !formDTO.getIconSmallImg().equals(customizedDTO.getIconSmallImg())){ || !formDTO.getIconSmallImg().equals(customizedDTO.getIconSmallImg())){
// 4.2 如果修改的内容只是:功能名称和大小图标,, 需要批量更新客户数据 // 4.2 如果修改的内容只是:功能名称和大小图标、功能说明,, 需要批量更新客户数据
CustomerFunctionDetailEntity customer = new CustomerFunctionDetailEntity(); CustomerFunctionDetailEntity customer = new CustomerFunctionDetailEntity();
customer.setFunctionName(formDTO.getFunctionName()); customer.setFunctionName(formDTO.getFunctionName());
customer.setIconLargeImg(formDTO.getIconLargeImg()); customer.setIconLargeImg(formDTO.getIconLargeImg());
@ -340,9 +340,9 @@ public class FunctionCustomizedServiceImpl extends BaseServiceImpl<FunctionCusto
entity.setId(formDTO.getFunctionId()); entity.setId(formDTO.getFunctionId());
entity.setFunctionName(formDTO.getFunctionName()); entity.setFunctionName(formDTO.getFunctionName());
entity.setFunctionIcon(formDTO.getIconLargeImg()); entity.setFunctionIcon(formDTO.getIconLargeImg());
entity.setFunctionExplain(formDTO.getFunctionExplain());
if (NumConstant.ONE == flag){ if (NumConstant.ONE == flag){
entity.setShoppingStatus(Integer.valueOf(formDTO.getShoppingStatus())); entity.setShoppingStatus(Integer.valueOf(formDTO.getShoppingStatus()));
entity.setFunctionExplain(formDTO.getFunctionExplain());
} }
functionService.updateById(entity); functionService.updateById(entity);
} }

4
epmet-module/oper-customize/oper-customize-server/src/main/resources/mapper/FunctionCustomizedDao.xml

@ -66,7 +66,7 @@
AND cu.CUSTOMIZED_NAME like concat('%', #{customizedName}, '%') AND cu.CUSTOMIZED_NAME like concat('%', #{customizedName}, '%')
</if> </if>
<if test="fromApp != null and fromApp.trim() != ''"> <if test="fromApp != null and fromApp.trim() != ''">
AND cu.FROM_APP = 'gov' AND cu.FROM_APP = #{fromApp}
</if> </if>
ORDER BY cu.FROM_APP, f.CREATED_TIME DESC ORDER BY cu.FROM_APP, f.CREATED_TIME DESC
</select> </select>
@ -84,7 +84,7 @@
AND cu.CUSTOMIZED_NAME like concat('%', #{customizedName}, '%') AND cu.CUSTOMIZED_NAME like concat('%', #{customizedName}, '%')
</if> </if>
<if test="fromApp != null and fromApp.trim() != ''"> <if test="fromApp != null and fromApp.trim() != ''">
AND cu.FROM_APP = 'gov' AND cu.FROM_APP = #{fromApp}
</if> </if>
</select> </select>
<select id="selectDomains" resultType="com.epmet.dto.FunctionCustomizedDTO"> <select id="selectDomains" resultType="com.epmet.dto.FunctionCustomizedDTO">

Loading…
Cancel
Save