|
@@ -126,7 +126,7 @@ public class TaShareChildRecordServiceImpl extends ServiceImpl<TaShareChildRecor
|
126
|
126
|
|
127
|
127
|
//查看是否拼团成功
|
128
|
128
|
TaShareActivity taShareActivity = activityMapper.selectById(taShareChildRecord.getGroupActivityId());
|
129
|
|
- if (taShareActivity.getJoinPeople() >= taShareActivity.getGroupBuyPeople()){
|
|
129
|
+ if (taShareRecord.getJoinPeople() >= taShareActivity.getGroupBuyPeople()){
|
130
|
130
|
return ResponseBean.error("拼团失败", ResponseBean.ERROR_UNAVAILABLE);
|
131
|
131
|
}
|
132
|
132
|
if (taShareActivity.getEndTime().isBefore(LocalDateTime.now())){
|
|
@@ -150,7 +150,7 @@ public class TaShareChildRecordServiceImpl extends ServiceImpl<TaShareChildRecor
|
150
|
150
|
}
|
151
|
151
|
|
152
|
152
|
//反更新人数
|
153
|
|
- taShareActivity.setJoinPeople(taShareActivity.getJoinPeople()+1);
|
|
153
|
+ taShareRecord.setJoinPeople(taShareRecord.getJoinPeople()+1);
|
154
|
154
|
activityMapper.updateById(taShareActivity);
|
155
|
155
|
|
156
|
156
|
//成为团员
|
|
@@ -158,7 +158,7 @@ public class TaShareChildRecordServiceImpl extends ServiceImpl<TaShareChildRecor
|
158
|
158
|
taShareChildRecord.setStatus(CommConstant.STATUS_NORMAL);
|
159
|
159
|
taShareChildRecord.setPersonId(person.getPersonId());
|
160
|
160
|
taShareChildRecordMapper.insert(taShareChildRecord);
|
161
|
|
- if (taShareActivity.getJoinPeople().equals(taShareActivity.getGroupBuyPeople())){
|
|
161
|
+ if (taShareRecord.getJoinPeople().equals(taShareActivity.getGroupBuyPeople())){
|
162
|
162
|
//发送微信模板消息所有人都发送
|
163
|
163
|
sendWxMessage(taShareRecord,orgId,taShareActivity);
|
164
|
164
|
|