Merge remote-tracking branch 'origin/huacheng_test' into huacheng_test
| | |
| | | */ |
| | | @ApiOperation(value = "导办事物列表(不分页)",response = TransactionEvent.class) |
| | | @GetMapping("/selectList") |
| | | public TableDataInfo selectList() |
| | | public TableDataInfo selectList(@RequestParam(value = "keyWord",required = false) String keyWord) |
| | | { |
| | | return getDataTable(iTransactionEventService.selectList()); |
| | | return getDataTable(iTransactionEventService.selectList(keyWord)); |
| | | } |
| | | |
| | | |
| | |
| | | */ |
| | | @ApiOperation(value = "导办事物列表(不分页)",response = TransactionEvent.class) |
| | | @GetMapping("/selectList") |
| | | public TableDataInfo selectList() |
| | | public TableDataInfo selectList(@RequestParam(value = "keyWord",required = false) String keyWord) |
| | | { |
| | | return getDataTable(iTransactionEventService.selectList()); |
| | | return getDataTable(iTransactionEventService.selectList(keyWord)); |
| | | } |
| | | |
| | | /** |
| | |
| | | * 导办事物列表(不分页) |
| | | * @return |
| | | */ |
| | | List<TransactionEvent> selectList(); |
| | | List<TransactionEvent> selectList(String keyWord); |
| | | |
| | | /** |
| | | * 智能咨询 |
| | |
| | | DateTime dateTime = td.nextWeekDay(dateTimeUser); |
| | | Calendar calendar = dateTime.toCalendar(); |
| | | LocalDateTime localDateTime = LocalDateTime.of(calendar.get(Calendar.YEAR), |
| | | calendar.get(Calendar.MONTH), calendar.get(Calendar.DATE), |
| | | calendar.get(Calendar.MONTH)+1, calendar.get(Calendar.DATE), |
| | | 9 + automessageSysSettings.getTimeoutNotificationNum(), 0);//设置时间为下一个工作日时间的9点+设置超时时间 |
| | | guideRepairOrder.setTimeoutTime(localDateTime); |
| | | } |
| | |
| | | DateTime dateTime = td.nextWeekDay(dateTimeUser); |
| | | Calendar calendar = dateTime.toCalendar(); |
| | | LocalDateTime localDateTime = LocalDateTime.of(calendar.get(Calendar.YEAR), |
| | | calendar.get(Calendar.MONTH), calendar.get(Calendar.DATE), |
| | | calendar.get(Calendar.MONTH)+1, calendar.get(Calendar.DATE), |
| | | 9 + automessageSysSettings.getTimeoutNotificationNum(), 0);//设置时间为下一个工作日时间的9点+设置超时时间 |
| | | guideRepairOrder.setTimeoutTime(localDateTime); |
| | | } |
| | |
| | | } |
| | | |
| | | @Override |
| | | public List<TransactionEvent> selectList() { |
| | | public List<TransactionEvent> selectList(String keyWord) { |
| | | if (keyWord!=null&&keyWord!=""){ |
| | | return baseMapper.selectList(new QueryWrapper<TransactionEvent>().lambda().like(TransactionEvent::getMatterName,keyWord)); |
| | | } |
| | | else { |
| | | return baseMapper.selectList(new QueryWrapper<TransactionEvent>().lambda()); |
| | | } |
| | | } |
| | | } |
| | |
| | | @ApiModelProperty(value = "社区id", hidden = true) |
| | | private Long communityId; |
| | | |
| | | @ApiModelProperty(value = "社区id集合", hidden = true) |
| | | private List<Long> communityIds; |
| | | |
| | | @ApiModelProperty(value = "社区名称") |
| | | private String communityName; |
| | | |
| | |
| | | package com.panzhihua.common.model.vos.partybuilding; |
| | | |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | |
| | |
| | | @ApiModelProperty("社区id") |
| | | private Long communityId; |
| | | |
| | | @ApiModelProperty("社区id集合") |
| | | private List<Long> communityIds; |
| | | |
| | | @ApiModelProperty("动态内容富文本--纯文本") |
| | | private String contentText; |
| | | |
| | |
| | | import lombok.Data; |
| | | |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @program: springcloud_k8s_panzhihuazhihuishequ |
| | |
| | | @JsonSerialize(using = ToStringSerializer.class) |
| | | private Long communityId; |
| | | |
| | | |
| | | @ApiModelProperty("社区id集合") |
| | | @JsonSerialize(using = ToStringSerializer.class) |
| | | private List<Long> communityIds; |
| | | |
| | | @ApiModelProperty("动态内容富文本--纯文本") |
| | | private String contentText; |
| | | |
| | |
| | | } |
| | | return accessToken; |
| | | } |
| | | |
| | | /** |
| | | * 发布消息时重新设置access_token 防止过期 |
| | | * @param appId |
| | | * @param appSecret |
| | | * @throws Exception |
| | | */ |
| | | public void setAppAccessTokenToCache(String appId,String appSecret) throws Exception{ |
| | | String accessToken = "0"; |
| | | try { |
| | | log.info("获取微信token参数:appid=" + appId + ",appSecret=" + appSecret); |
| | | String accessTokenUrl = ACCESS_TOKEN_URL + "&appid=" + appId + "&secret=" + appSecret; |
| | | String result = HttpClientUtil.httpGet(accessTokenUrl, null, null); |
| | | Map<String, Object> resultMap = JSON.parseObject(result, Map.class); |
| | | if (resultMap.containsKey("access_token")) { |
| | | accessToken = resultMap.get("access_token").toString(); |
| | | wxXCXTempSend.stringRedisTemplate.opsForValue().set("access_token:access_token:" + appId, accessToken, EXPIRE_TIME,TimeUnit.HOURS); |
| | | } |
| | | } catch (IOException ioe) { |
| | | log.error("小程序http请求异常"); |
| | | ioe.printStackTrace(); |
| | | } |
| | | } |
| | | |
| | | public String getAccessTokenNoValid(String appId) throws Exception { |
| | | String accessToken = ""; |
| | | accessToken=wxXCXTempSend.stringRedisTemplate.boundValueOps("access_token:access_token:"+appId).get(); |
| | | return accessToken; |
| | | } |
| | | public String getWsAccessToken() throws Exception { |
| | | String accessToken = "0"; |
| | | try { |
| | |
| | | List<ComEventTransferRecord> listByComEventTransferRecord(@Param("comEventTransferRecord") ComEventTransferRecord comEventTransferRecord); |
| | | |
| | | |
| | | int insertSelective(ComEventTransferRecord comEventTransferRecord); |
| | | int insertSelective(@Param("comEventTransferRecord") ComEventTransferRecord comEventTransferRecord); |
| | | } |
| | |
| | | } |
| | | @RabbitListener(queues = ACID_MESSAGE_QUEUE) |
| | | public void sendMessage(ComActDynVO comActDynVO){ |
| | | List<String> openIds=sysUserDao.selectOpenId(); |
| | | WxXCXTempSend wxXCXTempSend=new WxXCXTempSend(); |
| | | for(String openId:openIds){ |
| | | try { |
| | | WxUtil.sendLongTimeTemplate(openId,wxXCXTempSend.getAccessToken("wx118de8a734d269f0"),"疫情快讯",comActDynVO.getTitle().length()>10?comActDynVO.getTitle().substring(0,10)+"..":comActDynVO.getTitle(),"/pages/community_child/community/detail?id="+comActDynVO.getId()+"&title=疫情快讯详情"); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | try{ |
| | | List<String> openIds=sysUserDao.selectOpenId(); |
| | | String appId = "wx118de8a734d269f0"; |
| | | String appSecret = "0264342daefde5cd70a6adada09ee5b1"; |
| | | WxXCXTempSend wxXCXTempSend=new WxXCXTempSend(); |
| | | wxXCXTempSend.setAppAccessTokenToCache(appId,appSecret); |
| | | for(String openId:openIds){ |
| | | try { |
| | | WxUtil.sendLongTimeTemplate(openId,wxXCXTempSend.getAccessTokenNoValid(appId),"疫情快讯",comActDynVO.getTitle().length()>10?comActDynVO.getTitle().substring(0,10)+"..":comActDynVO.getTitle(),"/pages/community_child/community/detail?id="+comActDynVO.getId()+"&title=疫情快讯详情"); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | } |
| | | } |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | } |
| | | |
| | | } |
| | | } |
| | |
| | | |
| | | private String appId; |
| | | |
| | | @TableField(exist = false) |
| | | private String solvePhone; |
| | | |
| | | } |
| | |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import com.panzhihua.common.constants.HttpStatus; |
| | | import com.panzhihua.common.model.dtos.community.ActivityInviteDTO; |
| | | import com.panzhihua.service_community.dao.ComActNeighborCircleDAO; |
| | |
| | | } |
| | | page.setSize(pageSize); |
| | | page.setCurrent(pageNum); |
| | | Long communityId = comActActivityVO.getCommunityId(); |
| | | if (null != communityId){ |
| | | List<Long> communityIds = comActDAO.selectIds(communityId); |
| | | if (CollUtil.isEmpty(communityIds)) { |
| | | communityIds = new ArrayList<>(); |
| | | communityIds.add(communityId); |
| | | } |
| | | comActActivityVO.setCommunityIds(communityIds); |
| | | } |
| | | Integer type = comActActivityVO.getType(); |
| | | IPage<ComActActivityVO> iPage = null; |
| | | if (nonNull(type) && type.equals(4)) { |
| | | if (nonNull(comActActivityVO.getCommunityId())) { |
| | | ComActDO comActDO = comActDAO.selectById(comActActivityVO.getCommunityId()); |
| | | if (nonNull(comActDO)) { |
| | | comActActivityVO.setStreetId(comActDO.getStreetId()); |
| | | } |
| | | ComActDO comActDO = comActDAO.selectById(comActActivityVO.getCommunityId()); |
| | | if (nonNull(comActDO)) { |
| | | comActActivityVO.setStreetId(comActDO.getStreetId()); |
| | | } |
| | | } |
| | | iPage = comActActivityDAO.pageProjectActivity(page, comActActivityVO); |
| | | } else { |
| | |
| | | } |
| | | page.setSize(pageSize); |
| | | page.setCurrent(pageNum); |
| | | Long communityId = comActActivityVO.getCommunityId(); |
| | | if (null != communityId){ |
| | | List<Long> communityIds = comActDAO.selectIds(communityId); |
| | | if (CollUtil.isEmpty(communityIds)) { |
| | | communityIds = new ArrayList<>(); |
| | | communityIds.add(communityId); |
| | | } |
| | | comActActivityVO.setCommunityIds(communityIds); |
| | | } |
| | | IPage<ComActActivityVO> iPage = comActActivityDAO.pageActivityCommunityBack(page, comActActivityVO); |
| | | iPage.getRecords().forEach(vo ->{ |
| | | List<ComActActEvaluateDO> comActActEvaluateDOList = comActActEvaluateDAO |
| | |
| | | private ComBatteryCommodityOrderBargainRecordMapper orderBargainRecordMapper; |
| | | @Value("${min.app.isTest}") |
| | | private Boolean isTest; |
| | | @Value("${min.app.isRefundTest}") |
| | | private Boolean isRefundTest; |
| | | @Value("${min.app.appid}") |
| | | private String appid; |
| | | @Value("${min.app.payKey}") |
| | | private String payKey; |
| | | @Value("${min.app.mchId}") |
| | | private String mchId; |
| | | @Value("${min.app.currencyNotifyUrl}") |
| | | private String currencyNotifyUrl; |
| | | // @Value("${min.app.currencyNotifyUrl}") |
| | | // private String currencyNotifyUrl; |
| | | |
| | | /** |
| | | * description queryByPage 分页查询 |
| | |
| | | money = BigDecimal.valueOf(0.01); |
| | | } |
| | | // 调用wx支付 |
| | | result = WxPayUtils.getUnifiedorder(appid, mchId, payKey, currencyNotifyUrl + PayCpmstant.BATTERY_STORE_ACTIVITY_PAY_NOTIFY_URL |
| | | , remark, openId, orderNo, money,type); |
| | | // result = WxPayUtils.getUnifiedorder(appid, mchId, payKey, currencyNotifyUrl + PayCpmstant.BATTERY_STORE_ACTIVITY_PAY_NOTIFY_URL |
| | | // , remark, openId, orderNo, money,type); |
| | | log.info("用户购买商品微信支付返回参数:" + result); |
| | | return result; |
| | | } |
| | |
| | | private ComBatteryTradeOrderService tradeOrderService; |
| | | @Value("${min.app.isTest}") |
| | | private Boolean isTest; |
| | | @Value("${min.app.isRefundTest}") |
| | | private Boolean isRefundTest; |
| | | @Value("${min.app.appid}") |
| | | private String appid; |
| | | @Value("${min.app.payKey}") |
| | | private String payKey; |
| | | @Value("${min.app.mchId}") |
| | | private String mchId; |
| | | @Value("${min.app.currencyNotifyUrl}") |
| | | private String currencyNotifyUrl; |
| | | // @Value("${min.app.currencyNotifyUrl}") |
| | | // private String currencyNotifyUrl; |
| | | @Resource |
| | | private ComBatteryCommodityMapper commodityMapper; |
| | | @Resource |
| | |
| | | money = BigDecimal.valueOf(0.01); |
| | | } |
| | | // 调用wx支付 |
| | | result = WxPayUtils.getUnifiedorder(appid, mchId, payKey, currencyNotifyUrl + PayCpmstant.BATTERY_STORE_ACTIVITY_PAY_NOTIFY_URL |
| | | , remark, openId, orderNo, money,type); |
| | | // result = WxPayUtils.getUnifiedorder(appid, mchId, payKey, currencyNotifyUrl + PayCpmstant.BATTERY_STORE_ACTIVITY_PAY_NOTIFY_URL |
| | | // , remark, openId, orderNo, money,type); |
| | | log.info("用户购买商品微信支付返回参数:" + result); |
| | | return result; |
| | | } |
| | |
| | | private ComBatteryTradeOrderService tradeOrderService; |
| | | @Value("${min.app.isTest}") |
| | | private Boolean isTest; |
| | | @Value("${min.app.isRefundTest}") |
| | | private Boolean isRefundTest; |
| | | @Value("${min.app.appid}") |
| | | private String appid; |
| | | @Value("${min.app.payKey}") |
| | | private String payKey; |
| | | @Value("${min.app.mchId}") |
| | | private String mchId; |
| | | @Value("${min.app.currencyNotifyUrl}") |
| | | private String currencyNotifyUrl; |
| | | // @Value("${min.app.currencyNotifyUrl}") |
| | | // private String currencyNotifyUrl; |
| | | @Resource |
| | | private ComBatteryCommodityOrderCollageTeamMapper orderCollageTeamMapper; |
| | | @Resource |
| | |
| | | money = BigDecimal.valueOf(0.01); |
| | | } |
| | | // 调用wx支付 |
| | | result = WxPayUtils.getUnifiedorder(appid, mchId, payKey, currencyNotifyUrl + PayCpmstant.BATTERY_STORE_PAY_NOTIFY_URL |
| | | , remark, openId, orderNo, money,null); |
| | | // result = WxPayUtils.getUnifiedorder(appid, mchId, payKey, currencyNotifyUrl + PayCpmstant.BATTERY_STORE_PAY_NOTIFY_URL |
| | | // , remark, openId, orderNo, money,null); |
| | | log.info("用户购买商品微信支付返回参数:" + result); |
| | | return result; |
| | | } |
| | |
| | | comEvent.setCurrentOrgId(community.getCommunityId().toString()); |
| | | comEvent.setCurrentProcessType(5); |
| | | } |
| | | if (!StringUtils.isEmpty(comEvent.getCenterId())) { |
| | | if (!StringUtils.isEmpty(comEvent.getCenterId())) { |
| | | //创建时处理级别都是专家 |
| | | ComSanshuoIndustryCenter center = comSanShuoIndustryCenterService.getById(comEvent.getCenterId()); |
| | | comEvent.setCurrentOrgName(center.getName()); |
| | |
| | | return R.ok(ReturnMsgConstants.SAVE_SUCCESS); |
| | | } |
| | | |
| | | |
| | | public void sendMessage(Long expertId,ComEvent comEvent){ |
| | | //获取专家的openId |
| | | ComSanshuoExpert expert = comSanShuoExpertService.getById(expertId); |
| | | SysUser sysUser = sysUserDao.selectOne(new QueryWrapper<SysUser>().lambda().eq(SysUser::getPhone, expert.getPhone()).eq(SysUser::getType, 1)); |
| | | SysUser sysUser = sysUserDao.selectOne(new QueryWrapper<SysUser>().lambda().eq(SysUser::getPhone, expert.getPhone()).eq(SysUser::getType, 1).eq(SysUser::getAppId,"wx0cef797390444b75" )); |
| | | SanShuoMessageVO vo=new SanShuoMessageVO(); |
| | | if (nonNull(sysUser)){ |
| | | if (isNull(sysUser.getOpenid())){ |
| | |
| | | <if test='comActActivityVO.type != null and comActActivityVO.type == 4'> |
| | | left join (select count(t.id) as socialCount,activity_id from com_act_act_regist t LEFT JOIN sys_user t1 on t.user_id = t1.user_id LEFT JOIN com_act_social_worker t2 on t1.phone = t2.telephone where t2.id is not null GROUP BY t.activity_id) so on a.id = so.activity_id |
| | | </if> |
| | | WHERE a.community_id=#{comActActivityVO.communityId} |
| | | WHERE 1=1 |
| | | <if test="comActActivityVO.communityIds != null and comActActivityVO.communityIds.size() != 0"> |
| | | and a.community_id in |
| | | <foreach collection="comActActivityVO.communityIds" item="item" open="(" separator="," close=")"> |
| | | #{item} |
| | | </foreach> |
| | | </if> |
| | | <if test='comActActivityVO.type != null'> |
| | | AND a.type = #{comActActivityVO.type} |
| | | </if> |
| | |
| | | LEFT JOIN ( SELECT * FROM com_act_act_sign WHERE `status` = 1 ) s ON a.id = s.activity_id |
| | | LEFT JOIN com_act ca ON a.community_id = ca.community_id |
| | | WHERE 1 = 1 |
| | | <if test ="comActActivityVO.communityId != null and comActActivityVO.communityId != 0"> |
| | | <if test ="comActActivityVO.communityIds != null and comActActivityVO.communityIds.size() != 0"> |
| | | <if test="comActActivityVO.checkUnitId != null"> |
| | | AND (a.community_id = ${comActActivityVO.communityId} OR a.check_unit_id = #{comActActivityVO.checkUnitId}) |
| | | AND (a.community_id in |
| | | <foreach collection="comActActivityVO.communityIds" item="item" open="(" separator="," close=")"> |
| | | #{item} |
| | | </foreach> |
| | | OR a.check_unit_id = #{comActActivityVO.checkUnitId}) |
| | | </if> |
| | | <if test="comActActivityVO.checkUnitId == null"> |
| | | AND a.community_id = ${comActActivityVO.communityId} |
| | | AND a.community_id in |
| | | <foreach collection="comActActivityVO.communityIds" item="item" open="(" separator="," close=")"> |
| | | #{item} |
| | | </foreach> |
| | | <if test="comActActivityVO.type == null"> |
| | | AND a.`type` != 5 |
| | | </if> |
| | |
| | | <insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.panzhihua.service_community.entity.ComEventTransferRecord"> |
| | | insert into com_sanshuo_event_transfer_record |
| | | <trim prefix="(" suffix=")" suffixOverrides=","> |
| | | <if test="id != null"> |
| | | <if test="comEventTransferRecord.id != null"> |
| | | id, |
| | | </if> |
| | | <if test="eventId != null"> |
| | | <if test="comEventTransferRecord.eventId != null"> |
| | | event_id, |
| | | </if> |
| | | <if test="parentsTransferEventId != null"> |
| | | <if test="comEventTransferRecord.parentsTransferEventId != null"> |
| | | parents_transfer_event_id, |
| | | </if> |
| | | <if test="fromType != null"> |
| | | <if test="comEventTransferRecord.fromType != null"> |
| | | from_type, |
| | | </if> |
| | | <if test="fromId != null"> |
| | | <if test="comEventTransferRecord.fromId != null"> |
| | | from_id, |
| | | </if> |
| | | <if test="fromName != null"> |
| | | <if test="comEventTransferRecord.fromName != null"> |
| | | from_name, |
| | | </if> |
| | | <if test="fromUserId != null"> |
| | | <if test="comEventTransferRecord.fromUserId != null"> |
| | | from_user_id, |
| | | </if> |
| | | <if test="toType != null"> |
| | | <if test="comEventTransferRecord.toType != null"> |
| | | to_type, |
| | | </if> |
| | | <if test="toId != null"> |
| | | <if test="comEventTransferRecord.toId != null"> |
| | | to_id, |
| | | </if> |
| | | <if test="toName != null"> |
| | | <if test="comEventTransferRecord.toName != null"> |
| | | to_name, |
| | | </if> |
| | | <if test="toUserId != null"> |
| | | <if test="comEventTransferRecord.toUserId != null"> |
| | | to_user_id, |
| | | </if> |
| | | <if test="save != null"> |
| | | <if test="comEventTransferRecord.save != null"> |
| | | `save`, |
| | | </if> |
| | | <if test="processResult != null"> |
| | | <if test="comEventTransferRecord.processResult != null"> |
| | | process_result, |
| | | </if> |
| | | <if test="processResultData != null"> |
| | | <if test="comEventTransferRecord.processResultData != null"> |
| | | process_result_data, |
| | | </if> |
| | | <if test="processDate != null"> |
| | | <if test="comEventTransferRecord.processDate != null"> |
| | | process_date, |
| | | </if> |
| | | <if test="processBy != null"> |
| | | <if test="comEventTransferRecord.processBy != null"> |
| | | process_by, |
| | | </if> |
| | | <if test="processByName != null"> |
| | | <if test="comEventTransferRecord.processByName != null"> |
| | | process_by_name, |
| | | </if> |
| | | <if test="processType != null"> |
| | | <if test="comEventTransferRecord.processType != null"> |
| | | process_type, |
| | | </if> |
| | | <if test="createAt != null"> |
| | | <if test="comEventTransferRecord.createAt != null"> |
| | | create_at, |
| | | </if> |
| | | <if test="specialistId != null"> |
| | | <if test="comEventTransferRecord.specialistId != null"> |
| | | specialist_id, |
| | | </if> |
| | | <if test="specialistOrg != null"> |
| | | <if test="comEventTransferRecord.specialistOrg != null"> |
| | | specialist_org, |
| | | </if> |
| | | <if test="specialistLevel != null"> |
| | | <if test="comEventTransferRecord.specialistLevel != null"> |
| | | specialist_level, |
| | | </if> |
| | | <if test="specialistName != null"> |
| | | <if test="comEventTransferRecord.specialistName != null"> |
| | | specialist_name, |
| | | </if> |
| | | <if test="eventResult != null"> |
| | | <if test="comEventTransferRecord.eventResult != null"> |
| | | event_result, |
| | | </if> |
| | | <if test="eventStatus != null"> |
| | | <if test="comEventTransferRecord.eventStatus != null"> |
| | | event_status, |
| | | </if> |
| | | </trim> |
| | | <trim prefix="values (" suffix=")" suffixOverrides=","> |
| | | <if test="id != null"> |
| | | #{id,jdbcType=BIGINT}, |
| | | <if test="comEventTransferRecord.id != null"> |
| | | #{comEventTransferRecord.id,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="eventId != null"> |
| | | #{eventId,jdbcType=BIGINT}, |
| | | <if test="comEventTransferRecord.eventId != null"> |
| | | #{comEventTransferRecord.eventId,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="parentsTransferEventId != null"> |
| | | #{parentsTransferEventId,jdbcType=BIGINT}, |
| | | <if test="comEventTransferRecord.parentsTransferEventId != null"> |
| | | #{comEventTransferRecord.parentsTransferEventId,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="fromType != null"> |
| | | #{fromType,jdbcType=TINYINT}, |
| | | <if test="comEventTransferRecord.fromType != null"> |
| | | #{comEventTransferRecord.fromType,jdbcType=TINYINT}, |
| | | </if> |
| | | <if test="fromId != null"> |
| | | #{fromId,jdbcType=BIGINT}, |
| | | <if test="comEventTransferRecord.fromId != null"> |
| | | #{comEventTransferRecord.fromId,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="fromName != null"> |
| | | #{fromName,jdbcType=VARCHAR}, |
| | | <if test="comEventTransferRecord.fromName != null"> |
| | | #{comEventTransferRecord.fromName,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="fromUserId != null"> |
| | | #{fromUserId,jdbcType=BIGINT}, |
| | | <if test="comEventTransferRecord.fromUserId != null"> |
| | | #{comEventTransferRecord.fromUserId,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="toType != null"> |
| | | #{toType,jdbcType=TINYINT}, |
| | | <if test="comEventTransferRecord.toType != null"> |
| | | #{comEventTransferRecord.toType,jdbcType=TINYINT}, |
| | | </if> |
| | | <if test="toId != null"> |
| | | #{toId,jdbcType=BIGINT}, |
| | | <if test="comEventTransferRecord.toId != null"> |
| | | #{comEventTransferRecord.toId,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="toName != null"> |
| | | #{toName,jdbcType=VARCHAR}, |
| | | <if test="comEventTransferRecord.toName != null"> |
| | | #{comEventTransferRecord.toName,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="toUserId != null"> |
| | | #{toUserId,jdbcType=BIGINT}, |
| | | <if test="comEventTransferRecord.toUserId != null"> |
| | | #{comEventTransferRecord.toUserId,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="save != null"> |
| | | #{save,jdbcType=BIT}, |
| | | <if test="comEventTransferRecord.save != null"> |
| | | #{comEventTransferRecord.save,jdbcType=BIT}, |
| | | </if> |
| | | <if test="processResult != null"> |
| | | #{processResult,jdbcType=VARCHAR}, |
| | | <if test="comEventTransferRecord.processResult != null"> |
| | | #{comEventTransferRecord.processResult,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="processResultData != null"> |
| | | #{processResultData,jdbcType=VARCHAR}, |
| | | <if test="comEventTransferRecord.processResultData != null"> |
| | | #{comEventTransferRecord.processResultData,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="processDate != null"> |
| | | #{processDate,jdbcType=TIMESTAMP}, |
| | | <if test="comEventTransferRecord.processDate != null"> |
| | | #{comEventTransferRecord.processDate,jdbcType=TIMESTAMP}, |
| | | </if> |
| | | <if test="processBy != null"> |
| | | #{processBy,jdbcType=BIGINT}, |
| | | <if test="comEventTransferRecord.processBy != null"> |
| | | #{comEventTransferRecord.processBy,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="processByName != null"> |
| | | #{processByName,jdbcType=VARCHAR}, |
| | | <if test="comEventTransferRecord.processByName != null"> |
| | | #{comEventTransferRecord.processByName,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="processType != null"> |
| | | #{processType,jdbcType=INTEGER}, |
| | | <if test="comEventTransferRecord.processType != null"> |
| | | #{comEventTransferRecord.processType,jdbcType=INTEGER}, |
| | | </if> |
| | | <if test="createAt != null"> |
| | | #{createAt,jdbcType=TIMESTAMP}, |
| | | <if test="comEventTransferRecord.createAt != null"> |
| | | #{comEventTransferRecord.createAt,jdbcType=TIMESTAMP}, |
| | | </if> |
| | | <if test="specialistId != null"> |
| | | #{specialistId,jdbcType=BIGINT}, |
| | | <if test="comEventTransferRecord.specialistId != null"> |
| | | #{comEventTransferRecord.specialistId,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="specialistOrg != null"> |
| | | #{specialistOrg,jdbcType=VARCHAR}, |
| | | <if test="comEventTransferRecord.specialistOrg != null"> |
| | | #{comEventTransferRecord.specialistOrg,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="specialistLevel != null"> |
| | | #{specialistLevel,jdbcType=VARCHAR}, |
| | | <if test="comEventTransferRecord.specialistLevel != null"> |
| | | #{comEventTransferRecord.specialistLevel,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="specialistName != null"> |
| | | #{specialistName,jdbcType=VARCHAR}, |
| | | <if test="comEventTransferRecord.specialistName != null"> |
| | | #{comEventTransferRecord.specialistName,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="eventResult != null"> |
| | | #{eventResult,jdbcType=TINYINT}, |
| | | <if test="comEventTransferRecord.eventResult != null"> |
| | | #{comEventTransferRecord.eventResult,jdbcType=TINYINT}, |
| | | </if> |
| | | <if test="eventStatus != null"> |
| | | #{eventStatus,jdbcType=TINYINT}, |
| | | <if test="comEventTransferRecord.eventStatus != null"> |
| | | #{comEventTransferRecord.eventStatus,jdbcType=TINYINT}, |
| | | </if> |
| | | </trim> |
| | | </insert> |
| | |
| | | ComEvent comEvent=new ComEvent(); |
| | | // comEvent.setCreateBy(1l); |
| | | comEvent.setKeyword("17345059081"); |
| | | R data = comEventService.pageByComEvent(comEvent, pagination); |
| | | log.info(JSONObject.toJSONString(data)); |
| | | // R data = comEventService.pageByComEvent(comEvent, pagination); |
| | | // log.info(JSONObject.toJSONString(data)); |
| | | } |
| | | |
| | | @Test |
| | |
| | | |
| | | @Test |
| | | void calculate() { |
| | | R data = comEventService.calculate(); |
| | | log.info(JSONObject.toJSONString(data)); |
| | | // R data = comEventService.calculate(); |
| | | // log.info(JSONObject.toJSONString(data)); |
| | | } |
| | | |
| | | @Test |
| | |
| | | // " </where>" + |
| | | // "</script>") |
| | | |
| | | @Select("<script> " + "SELECT\n" + "d.id,\n" + "d.title, d.jump_url, d.jump_type,\n" + "COUNT( u.id ) readingVolume,\n" + "d.`status`,\n" |
| | | + "d.publish_at,\n" + "d.content,\n" + "d.cover,\n" + "d.cover_mode,\n" + "d.dyn_type,\n" + "d.create_at,t.name as communityName,d.policy_type \n" |
| | | + "FROM\n" + "com_pb_dyn d\n" + "LEFT JOIN com_pb_dyn_user u ON d.id = u.dyn_id left join com_act t on d.community_id = t.community_id\n" |
| | | + "where d.type=#{partyBuildingComPbDynVO.type} \n" |
| | | + "<if test='partyBuildingComPbDynVO.communityId != null and partyBuildingComPbDynVO.communityId != 0'>" |
| | | + "and d.community_id = ${partyBuildingComPbDynVO.communityId} \n" + " </if> " |
| | | + "<if test='partyBuildingComPbDynVO.dynType != null and partyBuildingComPbDynVO.dynType != 0'>" |
| | | + "and d.dyn_type = #{partyBuildingComPbDynVO.dynType} \n" + " </if> " |
| | | + "<if test='partyBuildingComPbDynVO.policyType != null and partyBuildingComPbDynVO.policyType != 0'>" |
| | | + "and d.policy_type = #{partyBuildingComPbDynVO.policyType} \n" + " </if> " |
| | | + "<if test='partyBuildingComPbDynVO.policyType == 0'>" |
| | | + "and d.policy_type is not null \n" + " </if> " |
| | | + "<if test='partyBuildingComPbDynVO.title != null and partyBuildingComPbDynVO.title.trim() != ""'>" |
| | | + "and d.title like concat(#{partyBuildingComPbDynVO.title},'%') \n" + " </if> " |
| | | + "<if test='partyBuildingComPbDynVO.status != null and partyBuildingComPbDynVO.status != 0'>" |
| | | + "AND d.`status` = #{partyBuildingComPbDynVO.status} \n" + " </if> " |
| | | + "<if test='partyBuildingComPbDynVO.publishAtBegin != null '>" |
| | | + "AND d.publish_at BETWEEN #{partyBuildingComPbDynVO.publishAtBegin} \n" |
| | | + "AND #{partyBuildingComPbDynVO.publishAtEnd} \n" + " </if> " + "GROUP BY\n" + "d.id\n" |
| | | + "ORDER BY d.publish_at <if test='partyBuildingComPbDynVO.sort !=null and partyBuildingComPbDynVO.sort !=""'> asc </if> <if test='partyBuildingComPbDynVO.sort ==null'> desc</if>" + "</script>") |
| | | IPage<PartyBuildingComPbDynVO> pageYnamic(Page page, |
| | | @Param("partyBuildingComPbDynVO") PartyBuildingComPbDynVO partyBuildingComPbDynVO); |
| | | |
| | |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.hutool.core.util.IdcardUtil; |
| | | import com.google.common.collect.Lists; |
| | | import com.panzhihua.common.enums.ComPbMemberRoleTypeEnum; |
| | |
| | | private CommunityWestService communityWestService; |
| | | @Resource |
| | | private UserService userService; |
| | | @Resource |
| | | private ComPbMemberDAO comPbMemberDAO; |
| | | |
| | | /** |
| | | * 新增党员 |
| | |
| | | } |
| | | page.setSize(pageSize); |
| | | page.setCurrent(pageNum); |
| | | Long communityId = partyBuildingComPbDynVO.getCommunityId(); |
| | | if (null != communityId){ |
| | | List<Long> communityIds = comPbMemberDAO.selectIds(communityId); |
| | | if (CollUtil.isEmpty(communityIds)) { |
| | | communityIds = new ArrayList<>(); |
| | | communityIds.add(communityId); |
| | | } |
| | | partyBuildingComPbDynVO.setCommunityIds(communityIds); |
| | | } |
| | | IPage<PartyBuildingComPbDynVO> iPage = comPbDynDAO.pageYnamic(page, partyBuildingComPbDynVO); |
| | | List<PartyBuildingComPbDynVO> records = iPage.getRecords(); |
| | | if (!(ObjectUtils.isEmpty(records))) { |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.panzhihua.service_dangjian.dao.ComPbDynDAO"> |
| | | |
| | | <resultMap type="com.panzhihua.service_dangjian.model.dos.ComPbDynDO" id="ComPbOrgMap"> |
| | | <result property="id" column="id" jdbcType="INTEGER"/> |
| | | <result property="title" column="title"/> |
| | | <result property="status" column="status"/> |
| | | <result property="publishAt" column="publish_at"/> |
| | | <result property="cover" column="cover"/> |
| | | <result property="createAt" column="create_at"/> |
| | | <result property="content" column="content"/> |
| | | <result property="createBy" column="create_by"/> |
| | | <result property="type" column="type"/> |
| | | <result property="communityId" column="community_id"/> |
| | | <result property="dynType" column="dyn_type"/> |
| | | <result property="coverMode" column="cover_mode"/> |
| | | <result property="jumpUrl" column="jump_url"/> |
| | | <result property="jumpType" column="jump_type"/> |
| | | <result property="policyType" column="policy_type"/> |
| | | </resultMap> |
| | | <select id="pageYnamic" resultType="com.panzhihua.common.model.vos.partybuilding.west.PartyBuildingComPbDynVO"> |
| | | SELECT |
| | | d.id, |
| | | d.title, d.jump_url, d.jump_type, |
| | | COUNT( u.id ) readingVolume, |
| | | d.`status`, |
| | | d.publish_at, |
| | | d.content, |
| | | d.cover, |
| | | d.cover_mode, |
| | | d.dyn_type, |
| | | d.create_at,t.name as communityName,d.policy_type |
| | | FROM |
| | | com_pb_dyn d |
| | | LEFT JOIN com_pb_dyn_user u ON d.id = u.dyn_id left join com_act t on d.community_id = t.community_id |
| | | where d.type=#{partyBuildingComPbDynVO.type} |
| | | <if test='partyBuildingComPbDynVO.communityIds != null and partyBuildingComPbDynVO.communityIds.size() > 0 '> |
| | | and d.community_id in |
| | | <foreach item="item" collection="partyBuildingComPbDynVO.communityIds" separator="," open="(" close=")" |
| | | index="index"> |
| | | #{item} |
| | | </foreach> |
| | | </if> |
| | | <if test='partyBuildingComPbDynVO.dynType != null and partyBuildingComPbDynVO.dynType != 0'> |
| | | and d.dyn_type = #{partyBuildingComPbDynVO.dynType} |
| | | </if> |
| | | <if test='partyBuildingComPbDynVO.policyType != null and partyBuildingComPbDynVO.policyType != 0'> |
| | | and d.policy_type = #{partyBuildingComPbDynVO.policyType} |
| | | </if> |
| | | <if test='partyBuildingComPbDynVO.policyType == 0'> |
| | | and d.policy_type is not null |
| | | </if> |
| | | <if test='partyBuildingComPbDynVO.title != null and partyBuildingComPbDynVO.title.trim() != ""'> |
| | | and d.title like concat(#{partyBuildingComPbDynVO.title},'%') |
| | | </if> |
| | | <if test='partyBuildingComPbDynVO.status != null and partyBuildingComPbDynVO.status != 0'> |
| | | AND d.`status` = #{partyBuildingComPbDynVO.status} |
| | | </if> |
| | | <if test='partyBuildingComPbDynVO.publishAtBegin != null '> |
| | | AND d.publish_at BETWEEN #{partyBuildingComPbDynVO.publishAtBegin} AND #{partyBuildingComPbDynVO.publishAtEnd} |
| | | </if> |
| | | GROUP BY d.id |
| | | ORDER BY d.publish_at |
| | | <if test="partyBuildingComPbDynVO.sort !=null and partyBuildingComPbDynVO.sort !=""">asc</if> |
| | | <if test='partyBuildingComPbDynVO.sort ==null'>desc</if> |
| | | </select> |
| | | |
| | | |
| | | </mapper> |
| | | |