Browse Source

修改bug

master
young 3 years ago
parent
commit
ab3ed9d091
  1. 4
      mls-admin/src/main/java/com/mls/web/controller/bmb/activity/api/BusClubActivityApiController.java
  2. 8
      mls-admin/src/main/java/com/mls/web/controller/bmbsys/BusClubActivityController.java
  3. 116
      mls-admin/src/main/resources/templates/bmb/busClubActivity/busClubActivity.html
  4. 2
      mls-bmb/src/main/java/com/mls/bmb/activity/service/IBusClubActivityService.java
  5. 15
      mls-bmb/src/main/java/com/mls/bmb/activity/service/impl/BusClubActivityServiceImpl.java
  6. 2
      mls-bmb/src/main/java/com/mls/bmb/club/service/impl/BusClubInfoServiceImpl.java
  7. 40
      mls-bmb/src/main/java/com/mls/bmb/order/service/impl/CancelOrderReceiver.java
  8. 12
      mls-bmb/src/main/java/com/mls/bmb/order/service/impl/CancelOrderSender.java
  9. 7
      mls-bmb/src/main/resources/mapper/activity/BusClubActivityMapper.xml
  10. 2
      mls-bmb/src/main/resources/mapper/club/BusClubInfoMapper.xml

4
mls-admin/src/main/java/com/mls/web/controller/bmb/activity/api/BusClubActivityApiController.java

@ -46,6 +46,7 @@ public class BusClubActivityApiController extends BaseMobileController {
@PostMapping("/detail") @PostMapping("/detail")
public MobileResult<ActivityDetailVO> detail(String activityId) public MobileResult<ActivityDetailVO> detail(String activityId)
{ {
System.out.println("11-------------我是活动详情 -------");
ActivityDetailVO data = busClubActivityService.selectBusClubActivityByActivityId(activityId); ActivityDetailVO data = busClubActivityService.selectBusClubActivityByActivityId(activityId);
return MobileResult.success(data); return MobileResult.success(data);
} }
@ -58,6 +59,7 @@ public class BusClubActivityApiController extends BaseMobileController {
@PostMapping("/byId") @PostMapping("/byId")
public MobileResult<ActivityVO> byId(String activityId) public MobileResult<ActivityVO> byId(String activityId)
{ {
System.out.println("查询俱乐部活动信息11111111");
ActivityVO data = busClubActivityService.selectBusClubActivityById(activityId); ActivityVO data = busClubActivityService.selectBusClubActivityById(activityId);
return MobileResult.success(data); return MobileResult.success(data);
} }
@ -285,6 +287,7 @@ public class BusClubActivityApiController extends BaseMobileController {
@PostMapping("/edit") @PostMapping("/edit")
public MobileResult editSave(ActivityEditVO req) public MobileResult editSave(ActivityEditVO req)
{ {
System.out.println("编辑俱乐部活动-------");
return toAjax(busClubActivityService.updateBusClubActivity(req, getUserId())); return toAjax(busClubActivityService.updateBusClubActivity(req, getUserId()));
} }
@ -297,6 +300,7 @@ public class BusClubActivityApiController extends BaseMobileController {
@PostMapping( "/remove") @PostMapping( "/remove")
public MobileResult remove(String activityId) public MobileResult remove(String activityId)
{ {
System.out.println("删除俱乐部活动-------");
return toAjax(busClubActivityService.updateBusClubActivityRecordStatus(activityId, getUserId())); return toAjax(busClubActivityService.updateBusClubActivityRecordStatus(activityId, getUserId()));
} }

8
mls-admin/src/main/java/com/mls/web/controller/bmbsys/BusClubActivityController.java

@ -114,12 +114,14 @@ public class BusClubActivityController extends BaseController {
/* /*
* 删除俱乐部活动 * 删除俱乐部活动
*/ */
/*@RequiresPermissions("bmb:activity:remove") @RequiresPermissions("bmb:activity:remove")
@Log(title = "俱乐部活动", businessType = BusinessType.DELETE) @Log(title = "俱乐部活动", businessType = BusinessType.DELETE)
@PostMapping( "/remove") @PostMapping( "/remove")
@ResponseBody @ResponseBody
public AjaxResult remove(String ids) public AjaxResult remove(String ids)
{ {
return toAjax(busClubActivityService.deleteBusClubActivityByIds(ids)); System.out.println("我是一个删除功能~~~~~~~");
}*/
return toAjax(busClubActivityService.deleteBusClubActivityById(ids));
}
} }

116
mls-admin/src/main/resources/templates/bmb/busClubActivity/busClubActivity.html

@ -133,16 +133,16 @@
checkbox: true checkbox: true
}, },
{ {
field : 'activityId', field : 'activityId',
title : '活动id', title : '活动id',
visible: false visible: false
}, },
{ {
field : 'activityName', field : 'activityName',
title : '活动名' title : '活动名'
}, },
{ {
field : 'activityLogo', field : 'activityLogo',
title : '活动logo', title : '活动logo',
formatter: function(value, row, index) { formatter: function(value, row, index) {
if(value==null){ if(value==null){
@ -152,7 +152,7 @@
} }
}, },
{ {
field : 'coverFirstImage', field : 'coverFirstImage',
title : '封面首图', title : '封面首图',
formatter: function(value, row, index) { formatter: function(value, row, index) {
if(value==null){ if(value==null){
@ -162,7 +162,7 @@
} }
}, },
{ {
field : 'coverSmallImage', field : 'coverSmallImage',
title : '封面小图', title : '封面小图',
formatter: function(value, row, index) { formatter: function(value, row, index) {
if(value==null){ if(value==null){
@ -172,7 +172,7 @@
} }
}, },
{ {
field : 'coverBigImage', field : 'coverBigImage',
title : '封面大图', title : '封面大图',
formatter: function(value, row, index) { formatter: function(value, row, index) {
if(value==null){ if(value==null){
@ -182,155 +182,155 @@
} }
}, },
{ {
field : 'clubId', field : 'clubId',
title : '俱乐部id' title : '俱乐部id'
}, },
{ {
field : 'activityContent', field : 'activityContent',
title : '活动内容' title : '活动内容'
}, },
{ {
field : 'activityAddr', field : 'activityAddr',
title : '活动地址' title : '活动地址'
}, },
{ {
field : 'lonAndLat', field : 'lonAndLat',
title : '地址经纬度' title : '地址经纬度'
}, },
{ {
field : 'addrLon', field : 'addrLon',
title : '地址经度' title : '地址经度'
}, },
{ {
field : 'addrLat', field : 'addrLat',
title : '地址纬度' title : '地址纬度'
}, },
{ {
field : 'startRegisterTime', field : 'startRegisterTime',
title : '报名开始时间' title : '报名开始时间'
}, },
{ {
field : 'endRegisterTime', field : 'endRegisterTime',
title : '报名结束时间' title : '报名结束时间'
}, },
{ {
field : 'startTime', field : 'startTime',
title : '活动开始时间' title : '活动开始时间'
}, },
{ {
field : 'endTime', field : 'endTime',
title : '活动结束时间' title : '活动结束时间'
}, },
{ {
field : 'isFree', field : 'isFree',
title : '是否免费' title : '是否免费'
}, },
{ {
field : 'isHelpRegister', field : 'isHelpRegister',
title : '是否允许帮助别人报名' title : '是否允许帮助别人报名'
}, },
{ {
field : 'isLimitSelect', field : 'isLimitSelect',
title : '是否限制费用项数' title : '是否限制费用项数'
}, },
{ {
field : 'isCheck', field : 'isCheck',
title : '参加报名人是否需要审核' title : '参加报名人是否需要审核'
}, },
{ {
field : 'refundType', field : 'refundType',
title : '退款设置/退款类型' title : '退款设置/退款类型'
}, },
{ {
field : 'refundTime', field : 'refundTime',
title : '退款时间' title : '退款时间'
}, },
{ {
field : 'isUpdateRegister', field : 'isUpdateRegister',
title : '是否可以修改报名信息' title : '是否可以修改报名信息'
}, },
{ {
field : 'isShowRegister', field : 'isShowRegister',
title : '是否显示报名列表' title : '是否显示报名列表'
}, },
{ {
field : 'isShowSponsor', field : 'isShowSponsor',
title : '是否显示主办方信息' title : '是否显示主办方信息'
}, },
{ {
field : 'showRegisterType', field : 'showRegisterType',
title : '报名信息展示方式' title : '报名信息展示方式'
}, },
{ {
field : 'registerBtnName', field : 'registerBtnName',
title : '报名按钮名称' title : '报名按钮名称'
}, },
{ {
field : 'costId', field : 'costId',
title : '费用id' title : '费用id'
}, },
{ {
field : 'activityPrice', field : 'activityPrice',
title : '活动单价' title : '活动单价'
}, },
{ {
field : 'officialPrice', field : 'officialPrice',
title : '官方价格/单价' title : '官方价格/单价'
}, },
{ {
field : 'teamPrice', field : 'teamPrice',
title : '团队价格/单价' title : '团队价格/单价'
}, },
{ {
field : 'isLimit', field : 'isLimit',
title : '是否限制人数' title : '是否限制人数'
}, },
/*{ /*{
field : 'activityRead', field : 'activityRead',
title : '浏览量' title : '浏览量'
}, },
{ {
field : 'activityShare', field : 'activityShare',
title : '分享量' title : '分享量'
},*/ },*/
{ {
field : 'insuranceType', field : 'insuranceType',
title : '买保险方式' title : '买保险方式'
}, },
{ {
field : 'insurancePrice', field : 'insurancePrice',
title : '保险费用' title : '保险费用'
}, },
{ {
field : 'isSmsNotify', field : 'isSmsNotify',
title : '是否短信通知' title : '是否短信通知'
}, },
{ {
field : 'smsNotifyTime', field : 'smsNotifyTime',
title : '短信通知时间' title : '短信通知时间'
}, },
{ {
field : 'smsExplain', field : 'smsExplain',
title : '短信通知说明' title : '短信通知说明'
}, },
{ {
field : 'smsContent', field : 'smsContent',
title : '短信通知内容' title : '短信通知内容'
}, },
{ {
field : 'isAppletNotify', field : 'isAppletNotify',
title : '是否小程序通知' title : '是否小程序通知'
}, },
{ {
field : 'appletNotifyTime', field : 'appletNotifyTime',
title : '小程序通知时间' title : '小程序通知时间'
}, },
{ {
field : 'isJoin', field : 'isJoin',
title : '报名后是否自动加入俱乐部' title : '报名后是否自动加入俱乐部'
}, },
{ {
field : 'poster', field : 'poster',
title : '海报图片', title : '海报图片',
formatter: function(value, row, index) { formatter: function(value, row, index) {
if(value==null){ if(value==null){
@ -344,68 +344,68 @@
title : '活动允许报名' title : '活动允许报名'
}, },
{ {
field : 'isOpenTeam', field : 'isOpenTeam',
title : '是否开启团报' title : '是否开启团报'
}, },
{ {
field : 'isRecommend', field : 'isRecommend',
title : '是否精品推荐活动', title : '是否精品推荐活动',
formatter: function (value, item, index) { formatter: function (value, item, index) {
return $.table.selectDictLabel(bus_is_recommend, value); return $.table.selectDictLabel(bus_is_recommend, value);
} }
}, },
{ {
field : 'checkStatus', field : 'checkStatus',
title : '审核状态', title : '审核状态',
formatter: function (value, item, index) { formatter: function (value, item, index) {
return $.table.selectDictLabel(bus_check_status, value); return $.table.selectDictLabel(bus_check_status, value);
} }
}, },
{ {
field : 'publishStatus', field : 'publishStatus',
title : '发布状态' title : '发布状态'
}, },
{ {
field : 'registerStatus', field : 'registerStatus',
title : '报名状态' title : '报名状态'
}, },
{ {
field : 'signStatus', field : 'signStatus',
title : '签到状态' title : '签到状态'
}, },
{ {
field : 'recordStatus', field : 'recordStatus',
title : '记录状态', title : '记录状态',
formatter: function (value, item, index) { formatter: function (value, item, index) {
return $.table.selectDictLabel(bus_record_status, value); return $.table.selectDictLabel(bus_record_status, value);
} }
}, },
{ {
field : 'createdTel', field : 'createdTel',
title : '发起人联系方式' title : '发起人联系方式'
}, },
{ {
field : 'revision', field : 'revision',
title : '乐观锁' title : '乐观锁'
}, },
{ {
field : 'createdBy', field : 'createdBy',
title : '创建人,发起人' title : '创建人,发起人'
}, },
{ {
field : 'createdTime', field : 'createdTime',
title : '创建时间' title : '创建时间'
}, },
{ {
field : 'updatedBy', field : 'updatedBy',
title : '更新人' title : '更新人'
}, },
{ {
field : 'updatedTime', field : 'updatedTime',
title : '更新时间' title : '更新时间'
}, },
{ {
field : 'notes', field : 'notes',
title : '备注' title : '备注'
}, },
{ {

2
mls-bmb/src/main/java/com/mls/bmb/activity/service/IBusClubActivityService.java

@ -247,5 +247,5 @@ public interface IBusClubActivityService
* @param activityId 俱乐部活动ID * @param activityId 俱乐部活动ID
* @return 结果 * @return 结果
*/ */
//public int deleteBusClubActivityById(String activityId); public int deleteBusClubActivityById(String activityId);
} }

15
mls-bmb/src/main/java/com/mls/bmb/activity/service/impl/BusClubActivityServiceImpl.java

@ -65,6 +65,10 @@ public class BusClubActivityServiceImpl implements IBusClubActivityService
// return CollectionCopyUtils.copyList(data, ActivityRecommendVO.class); // return CollectionCopyUtils.copyList(data, ActivityRecommendVO.class);
} }
/**
* 查询热门活动 api
* @return
*/
@Override @Override
public List<BusClubActivity> selectBusClubActivityByHot() { public List<BusClubActivity> selectBusClubActivityByHot() {
// 热门活动按照报名人最多的倒序查询 // 热门活动按照报名人最多的倒序查询
@ -143,6 +147,7 @@ public class BusClubActivityServiceImpl implements IBusClubActivityService
*/ */
@Override @Override
public ActivityVO selectBusClubActivityById(String activityId) { public ActivityVO selectBusClubActivityById(String activityId) {
System.out.println("ActivityVO 俱乐部活动ID");
BusClubActivity activity = busClubActivityMapper.selectBusClubActivityById(activityId); BusClubActivity activity = busClubActivityMapper.selectBusClubActivityById(activityId);
ActivityVO result = new ActivityVO(); ActivityVO result = new ActivityVO();
BeanUtils.copyProperties(activity, result); BeanUtils.copyProperties(activity, result);
@ -157,6 +162,7 @@ public class BusClubActivityServiceImpl implements IBusClubActivityService
*/ */
@Override @Override
public BusClubActivity selectBusClubActivityByAId(String activityId) { public BusClubActivity selectBusClubActivityByAId(String activityId) {
System.out.println("BusClubActivity 俱乐部活动ID");
return busClubActivityMapper.selectBusClubActivityById(activityId); return busClubActivityMapper.selectBusClubActivityById(activityId);
} }
@ -302,7 +308,8 @@ public class BusClubActivityServiceImpl implements IBusClubActivityService
// [4] 若收款类型为管理员代收 则创建俱乐部管理员钱包(活动创建者) // [4] 若收款类型为管理员代收 则创建俱乐部管理员钱包(活动创建者)
BusClubInfo club = busClubInfoMapper.selectBusClubInfoById(clubId); BusClubInfo club = busClubInfoMapper.selectBusClubInfoById(clubId);
// 收款类型 1-会长账户 2-管理员账户 // 收款类型 1-会长账户 2-管理员账户
String payType = club.getPayType(); // String payType = club.getPayType(); --廖杨6月18日修改
String payType = "1";
if("2".equals(payType)){ if("2".equals(payType)){
String walletId = busClubWalletService.getClubWalletId(clubId); String walletId = busClubWalletService.getClubWalletId(clubId);
busClubWalletService.insertBusClubBlankWallet(walletId, clubId, userId); busClubWalletService.insertBusClubBlankWallet(walletId, clubId, userId);
@ -566,6 +573,12 @@ public class BusClubActivityServiceImpl implements IBusClubActivityService
return busClubActivityMapper.updateBusClubActivity(busClubActivity); return busClubActivityMapper.updateBusClubActivity(busClubActivity);
} }
@Override
public int deleteBusClubActivityById(String activityId) {
System.out.println("我要删除的 活动ID=======" + activityId + " dfdfd");
return busClubActivityMapper.deleteBusClubActivityById(activityId);
}
/* /*
* 删除俱乐部活动对象 * 删除俱乐部活动对象
* *

2
mls-bmb/src/main/java/com/mls/bmb/club/service/impl/BusClubInfoServiceImpl.java

@ -367,6 +367,8 @@ public class BusClubInfoServiceImpl implements IBusClubInfoService
member.setCreatedTime(new Date()); member.setCreatedTime(new Date());
member.setCreatedBy(userId); member.setCreatedBy(userId);
member.setRecordStatus("1"); member.setRecordStatus("1");
System.out.println( "新增俱乐部==="+ member.getUserId() +" 2");
busClubMemberMapper.insertBusClubMember(member); busClubMemberMapper.insertBusClubMember(member);
// [3] 保存俱乐部信息 // [3] 保存俱乐部信息

40
mls-bmb/src/main/java/com/mls/bmb/order/service/impl/CancelOrderReceiver.java

@ -17,26 +17,26 @@ import java.io.IOException;
* @author dongdong * @author dongdong
* @date 2021-04-24 * @date 2021-04-24
*/ */
@Component //@Component
@RabbitListener(queues = "mall.order.cancel.ttl", containerFactory = "multiListenerContainer") //@RabbitListener(queues = "mall.order.cancel.ttl", containerFactory = "multiListenerContainer")
public class CancelOrderReceiver { public class CancelOrderReceiver {
private final Logger logger = LoggerFactory.getLogger(CancelOrderReceiver.class.getName()); // private final Logger logger = LoggerFactory.getLogger(CancelOrderReceiver.class.getName());
@Autowired // @Autowired
private IBusOrderInfoService busOrderInfoService; // private IBusOrderInfoService busOrderInfoService;
//
@RabbitHandler // @RabbitHandler
public void handle(String orderNumber, Channel channel, Message message) { // public void handle(String orderNumber, Channel channel, Message message) {
logger.info("Receiver orderNumber:{}", orderNumber); // logger.info("Receiver orderNumber:{}", orderNumber);
try { // try {
//业务处理 // //业务处理
busOrderInfoService.updateBusOrderStatusByTimeout(orderNumber); // busOrderInfoService.updateBusOrderStatusByTimeout(orderNumber);
}catch (Exception e){ // }catch (Exception e){
try { // try {
channel.basicAck(message.getMessageProperties().getDeliveryTag(),false); // channel.basicAck(message.getMessageProperties().getDeliveryTag(),false);
} catch (IOException ioException) { // } catch (IOException ioException) {
ioException.printStackTrace(); // ioException.printStackTrace();
} // }
} // }
} // }
} }

12
mls-bmb/src/main/java/com/mls/bmb/order/service/impl/CancelOrderSender.java

@ -26,11 +26,11 @@ public class CancelOrderSender {
*/ */
public void sendMessage(String orderNumber, final long delayTimes) { public void sendMessage(String orderNumber, final long delayTimes) {
// 给延迟队列发送消息 // 给延迟队列发送消息
amqpTemplate.convertAndSend(QueueEnum.QUEUE_ORDER_CANCEL.getExchange(), // amqpTemplate.convertAndSend(QueueEnum.QUEUE_ORDER_CANCEL.getExchange(),
QueueEnum.QUEUE_ORDER_CANCEL.getRouteKey(), orderNumber, message -> { // QueueEnum.QUEUE_ORDER_CANCEL.getRouteKey(), orderNumber, message -> {
message.getMessageProperties().setExpiration(String.valueOf(delayTimes)); // message.getMessageProperties().setExpiration(String.valueOf(delayTimes));
return message; // return message;
}); // });
logger.info("Send orderNumber:{}", orderNumber); // logger.info("Send orderNumber:{}", orderNumber);
} }
} }

7
mls-bmb/src/main/resources/mapper/activity/BusClubActivityMapper.xml

@ -81,7 +81,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</resultMap> </resultMap>
<sql id="selectBusClubActivityAll"> <sql id="selectBusClubActivityAll">
select activity_id, activity_name, activity_logo, cover_first_image, cover_small_image, cover_big_image, club_id, activity_content, activity_addr, lon_and_lat, addr_lon, addr_lat, start_register_time, end_register_time, start_time, end_time, is_free, is_help_register, is_limit_select, is_check, refund_type, refund_time, refund_start_time, refund_end_time, is_update_register, is_show_register, is_show_sponsor, show_register_type, register_btn_name, cost_id, activity_price, official_price, team_price, is_limit, activity_read, activity_share, insurance_type, insurance_price, is_sms_notify, sms_notify_time, sms_explain, sms_content, is_applet_notify, applet_notify_time, is_join, poster, is_register, is_open_team, is_recommend, check_status, publish_status, register_status, sign_status, record_status, created_tel, REVISION, CREATED_BY, CREATED_TIME, UPDATED_BY, UPDATED_TIME, notes from bus_club_activity select activity_id, activity_name, activity_logo, cover_first_image, cover_small_image, cover_big_image, club_id, activity_content, activity_addr, lon_and_lat, addr_lon, addr_lat, start_register_time, end_register_time, start_time, end_time, is_free, is_help_register, is_limit_select, is_check, refund_type, refund_time, refund_start_time, refund_end_time, is_update_register, is_show_register, is_show_sponsor, show_register_type, register_btn_name, cost_id, activity_price, official_price, team_price, is_limit, activity_read, activity_share, insurance_type, insurance_price, is_sms_notify, sms_notify_time, sms_explain, sms_content, is_applet_notify, applet_notify_time, is_join, poster, is_register, is_open_team, is_recommend, check_status, publish_status, register_status, sign_status, record_status, created_tel, REVISION, CREATED_BY, CREATED_TIME, UPDATED_BY, UPDATED_TIME, notes from bus_club_activity where stats='1'
</sql> </sql>
<select id="selectBusClubActivityList" parameterType="BusClubActivity" resultMap="BusClubActivityResult"> <select id="selectBusClubActivityList" parameterType="BusClubActivity" resultMap="BusClubActivityResult">
@ -272,6 +272,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
where a.record_status = "1" where a.record_status = "1"
and a.publish_status = "1" and a.publish_status = "1"
and a.check_status = "1" and a.check_status = "1"
and a.stats = "1"
group by a.activity_id, activity_name, activity_logo, cover_first_image, cover_small_image, cover_big_image, group by a.activity_id, activity_name, activity_logo, cover_first_image, cover_small_image, cover_big_image,
a.club_id, activity_content, activity_addr, lon_and_lat, addr_lon, addr_lat, start_register_time, a.club_id, activity_content, activity_addr, lon_and_lat, addr_lon, addr_lat, start_register_time,
end_register_time, start_time, end_time, is_free, is_help_register, is_limit_select, end_register_time, start_time, end_time, is_free, is_help_register, is_limit_select,
@ -851,9 +852,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</trim> </trim>
where activity_id = #{activityId} where activity_id = #{activityId}
</update> </update>
<!-- PC删除该俱乐部活动 -->
<delete id="deleteBusClubActivityById" parameterType="String"> <delete id="deleteBusClubActivityById" parameterType="String">
delete from bus_club_activity where activity_id = #{activityId} update bus_club_activity set stats = 0 where activity_id = #{activityId}
</delete> </delete>
<delete id="deleteBusClubActivityByIds" parameterType="String"> <delete id="deleteBusClubActivityByIds" parameterType="String">

2
mls-bmb/src/main/resources/mapper/club/BusClubInfoMapper.xml

@ -209,7 +209,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
select club_id from bus_club_member where user_id = #{userId} select club_id from bus_club_member where user_id = #{userId}
and (member_type="1" or member_type="2" or member_type="3") and record_status = "1" and (member_type="1" or member_type="2" or member_type="3") and record_status = "1"
) )
and c.check_status = "1" and c.record_status = "1" and c.record_status = "1"
</select> </select>

Loading…
Cancel
Save