|
|
@ -13,6 +13,7 @@ import com.epmet.commons.tools.exception.EpmetException; |
|
|
|
import com.epmet.commons.tools.page.PageData; |
|
|
|
import com.epmet.commons.tools.utils.ConvertUtils; |
|
|
|
import com.epmet.commons.tools.utils.Result; |
|
|
|
import com.epmet.constant.SystemMessageType; |
|
|
|
import com.epmet.dao.PointAdditiveRuleDao; |
|
|
|
import com.epmet.dao.PointApplyDao; |
|
|
|
import com.epmet.dto.CategorydetailResultDTO; |
|
|
@ -212,11 +213,15 @@ public class PointAdditiveRuleServiceImpl extends BaseServiceImpl<PointAdditiveR |
|
|
|
List<PointAdditiveRuleDTO> result = baseDao.selectList4tree(dto); |
|
|
|
if (CollectionUtils.isNotEmpty(result)) { |
|
|
|
result.forEach(item -> { |
|
|
|
if (null != rule) { |
|
|
|
if (item.getId().equals(rule.getId()) || item.getPid().equals(rule.getId())) { |
|
|
|
item.setEditFlag(NumConstant.ZERO_STR); |
|
|
|
} else { |
|
|
|
item.setEditFlag(NumConstant.ONE_STR); |
|
|
|
} |
|
|
|
} else { |
|
|
|
item.setEditFlag(NumConstant.ONE_STR); |
|
|
|
} |
|
|
|
}); |
|
|
|
} |
|
|
|
return new Result<List<PointAdditiveRuleDTO>>().ok(result); |
|
|
@ -335,7 +340,7 @@ public class PointAdditiveRuleServiceImpl extends BaseServiceImpl<PointAdditiveR |
|
|
|
wrapper = new LambdaQueryWrapper<>(); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCustomerId, customerId); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryCode, "party_building"); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryName, "支部委员会"); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryName, SystemMessageType.ZBWYH); |
|
|
|
PointAdditiveRuleEntity zbdyh = baseDao.selectOne(wrapper); |
|
|
|
if (null == zbdyh) { |
|
|
|
zbdyh = new PointAdditiveRuleEntity(); |
|
|
@ -343,7 +348,7 @@ public class PointAdditiveRuleServiceImpl extends BaseServiceImpl<PointAdditiveR |
|
|
|
zbdyh.setType("rule"); |
|
|
|
zbdyh.setApplyFlag(NumConstant.ONE_STR); |
|
|
|
zbdyh.setCategoryCode("party_building"); |
|
|
|
zbdyh.setRuleName("支部委员会"); |
|
|
|
zbdyh.setRuleName(SystemMessageType.ZBWYH); |
|
|
|
zbdyh.setPid(djhd.getId()); |
|
|
|
zbdyh.setPids(djhd.getPids().concat(StrConstant.COLON).concat(djhd.getId())); |
|
|
|
zbdyh.setPointValue(10); |
|
|
@ -353,7 +358,7 @@ public class PointAdditiveRuleServiceImpl extends BaseServiceImpl<PointAdditiveR |
|
|
|
wrapper = new LambdaQueryWrapper<>(); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCustomerId, customerId); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryCode, "party_building"); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryName, "支部党员大会"); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryName, SystemMessageType.ZBDYDH); |
|
|
|
PointAdditiveRuleEntity zbdydh = baseDao.selectOne(wrapper); |
|
|
|
if (null == zbdydh) { |
|
|
|
zbdydh = new PointAdditiveRuleEntity(); |
|
|
@ -361,7 +366,7 @@ public class PointAdditiveRuleServiceImpl extends BaseServiceImpl<PointAdditiveR |
|
|
|
zbdydh.setType("rule"); |
|
|
|
zbdydh.setApplyFlag(NumConstant.ONE_STR); |
|
|
|
zbdydh.setCategoryCode("party_building"); |
|
|
|
zbdydh.setRuleName("支部党员大会"); |
|
|
|
zbdydh.setRuleName(SystemMessageType.ZBDYDH); |
|
|
|
zbdydh.setPid(djhd.getId()); |
|
|
|
zbdydh.setPids(djhd.getPids().concat(StrConstant.COLON).concat(djhd.getId())); |
|
|
|
zbdydh.setPointValue(20); |
|
|
@ -371,7 +376,7 @@ public class PointAdditiveRuleServiceImpl extends BaseServiceImpl<PointAdditiveR |
|
|
|
wrapper = new LambdaQueryWrapper<>(); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCustomerId, customerId); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryCode, "party_building"); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryName, "党小组会"); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryName, SystemMessageType.DXZH); |
|
|
|
PointAdditiveRuleEntity dxzh = baseDao.selectOne(wrapper); |
|
|
|
if (null == dxzh) { |
|
|
|
dxzh = new PointAdditiveRuleEntity(); |
|
|
@ -379,7 +384,7 @@ public class PointAdditiveRuleServiceImpl extends BaseServiceImpl<PointAdditiveR |
|
|
|
dxzh.setType("rule"); |
|
|
|
dxzh.setApplyFlag(NumConstant.ONE_STR); |
|
|
|
dxzh.setCategoryCode("party_building"); |
|
|
|
dxzh.setRuleName("党小组会"); |
|
|
|
dxzh.setRuleName(SystemMessageType.DXZH); |
|
|
|
dxzh.setPid(djhd.getId()); |
|
|
|
dxzh.setPids(djhd.getPids().concat(StrConstant.COLON).concat(djhd.getId())); |
|
|
|
dxzh.setPointValue(10); |
|
|
@ -389,7 +394,7 @@ public class PointAdditiveRuleServiceImpl extends BaseServiceImpl<PointAdditiveR |
|
|
|
wrapper = new LambdaQueryWrapper<>(); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCustomerId, customerId); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryCode, "party_building"); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryName, "党课"); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryName, SystemMessageType.DANGKE); |
|
|
|
PointAdditiveRuleEntity dk = baseDao.selectOne(wrapper); |
|
|
|
if (null == dk) { |
|
|
|
dk = new PointAdditiveRuleEntity(); |
|
|
@ -397,7 +402,7 @@ public class PointAdditiveRuleServiceImpl extends BaseServiceImpl<PointAdditiveR |
|
|
|
dk.setType("rule"); |
|
|
|
dk.setApplyFlag(NumConstant.ONE_STR); |
|
|
|
dk.setCategoryCode("party_building"); |
|
|
|
dk.setRuleName("党课"); |
|
|
|
dk.setRuleName(SystemMessageType.DANGKE); |
|
|
|
dk.setPid(djhd.getId()); |
|
|
|
dk.setPids(djhd.getPids().concat(StrConstant.COLON).concat(djhd.getId())); |
|
|
|
dk.setPointValue(15); |
|
|
@ -407,7 +412,7 @@ public class PointAdditiveRuleServiceImpl extends BaseServiceImpl<PointAdditiveR |
|
|
|
wrapper = new LambdaQueryWrapper<>(); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCustomerId, customerId); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryCode, "party_building"); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryName, "主题党日"); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryName, SystemMessageType.ZTDR); |
|
|
|
PointAdditiveRuleEntity ztdr = baseDao.selectOne(wrapper); |
|
|
|
if (null == ztdr) { |
|
|
|
ztdr = new PointAdditiveRuleEntity(); |
|
|
@ -415,7 +420,7 @@ public class PointAdditiveRuleServiceImpl extends BaseServiceImpl<PointAdditiveR |
|
|
|
ztdr.setType("rule"); |
|
|
|
ztdr.setApplyFlag(NumConstant.ONE_STR); |
|
|
|
ztdr.setCategoryCode("party_building"); |
|
|
|
ztdr.setRuleName("主题党日"); |
|
|
|
ztdr.setRuleName(SystemMessageType.ZTDR); |
|
|
|
ztdr.setPid(djhd.getId()); |
|
|
|
ztdr.setPids(djhd.getPids().concat(StrConstant.COLON).concat(djhd.getId())); |
|
|
|
ztdr.setPointValue(15); |
|
|
@ -425,7 +430,7 @@ public class PointAdditiveRuleServiceImpl extends BaseServiceImpl<PointAdditiveR |
|
|
|
wrapper = new LambdaQueryWrapper<>(); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCustomerId, customerId); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryCode, "party_building"); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryName, "为民服务活动"); |
|
|
|
wrapper.eq(PointAdditiveRuleEntity::getCategoryName, SystemMessageType.WMFWHD); |
|
|
|
PointAdditiveRuleEntity wmfwhd = baseDao.selectOne(wrapper); |
|
|
|
if (null == wmfwhd) { |
|
|
|
wmfwhd = new PointAdditiveRuleEntity(); |
|
|
@ -433,7 +438,7 @@ public class PointAdditiveRuleServiceImpl extends BaseServiceImpl<PointAdditiveR |
|
|
|
wmfwhd.setType("rule"); |
|
|
|
wmfwhd.setApplyFlag(NumConstant.ONE_STR); |
|
|
|
wmfwhd.setCategoryCode("party_building"); |
|
|
|
wmfwhd.setRuleName("为民服务活动"); |
|
|
|
wmfwhd.setRuleName(SystemMessageType.WMFWHD); |
|
|
|
wmfwhd.setPid(djhd.getId()); |
|
|
|
wmfwhd.setPids(djhd.getPids().concat(StrConstant.COLON).concat(djhd.getId())); |
|
|
|
wmfwhd.setPointValue(15); |
|
|
|