Commit 89f8a7d3 by huluobin

发券data fix

parent ec486450
......@@ -38,4 +38,7 @@ public interface CouponCustomerRelevanceMapper extends BaseMapper<CouponCustomer
List<Integer> queryCouponCustomerServeRelevance(Integer couponId);
List<CouponCustomerRelevance> selectByOrderTimes();
List<CouponCustomerRelevance> couponCustomerRelevanceError();
}
......@@ -77,7 +77,7 @@ public class TakeLeaveEventController {
return JsonResult.success();
}
@ApiOperation("/总后台驳回请假")
@ApiOperation("/总后台审批请假")
@PostMapping("/admin/takeLeave/adminRefuseTakeLeaveEvent/{takeLeaveEventId}")
public JsonResult<Void> adminRefuseTakeLeaveEvent(@PathVariable Integer takeLeaveEventId) {
takeLeaveEventCmdService.adminRefuseTakeLeaveEvent(takeLeaveEventId);
......
......@@ -31,6 +31,9 @@
where t2.finish_time > '2020-01-01'
and t1.state = 2
</select>
<select id="couponCustomerRelevanceError" resultType="com.gogirl.domain.market.coupon.CouponCustomerRelevance">
select * from coupon_customer_relevance where valid_end_time &lt; valid_start_time and state =3
</select>
<update id="setCouponExpire" parameterType="java.util.Date">
update coupon_customer_relevance
......
......@@ -480,7 +480,7 @@ public class Test {
@org.junit.Test
public void testMail() {
mailService.sendSimpleMail("robbendev@qq.com","pre","test");
mailService.sendSimpleMail("robbendev@qq.com", "pre", "test");
}
......@@ -488,7 +488,19 @@ public class Test {
Schedule schedule;
@org.junit.Test
public void career(){
public void career() {
schedule.syncTechnicianCareer();
}
@org.junit.Test
public void couponCustomerRelevanceError() {
List<CouponCustomerRelevance> couponCustomerRelevanceList = couponCustomerRelevanceMapper.couponCustomerRelevanceError();
couponCustomerRelevanceList.forEach(couponCustomerRelevance -> {
couponCustomerRelevance.setValidEndTime(new Date(couponCustomerRelevance.getValidStartTime().getTime() + 30 * 24 * 60 * 60 * 1000L));
if (couponCustomerRelevance.isValid()) {
couponCustomerRelevance.setState(1);
}
couponCustomerRelevanceMapper.updateById(couponCustomerRelevance);
});
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment