|
|
|
@ -26,22 +26,21 @@ public class ApiAppletAddressController { |
|
|
|
|
|
|
|
@ApiOperation("地址-地址列表数据查询") |
|
|
|
@GetMapping("/addressList") |
|
|
|
public AjaxResult outDateList(){ |
|
|
|
public AjaxResult outDateList(AppletAddress appletAddress){ |
|
|
|
|
|
|
|
// 使用AppletTokenUtils工具类从请求头中获取当前用户ID |
|
|
|
Long currentUserId = AppletTokenUtils.requireCurrentAppletUserId(); |
|
|
|
|
|
|
|
AppletAddress appletAddress = new AppletAddress(); |
|
|
|
appletAddress.setUserId(currentUserId); |
|
|
|
// Long currentUserId = AppletTokenUtils.requireCurrentAppletUserId(); |
|
|
|
// |
|
|
|
// appletAddress.setUserId(currentUserId); |
|
|
|
|
|
|
|
List<AppletAddress> addressList = appletAddressService.selectAppletAddressList(appletAddress); |
|
|
|
if(addressList.size()>0){ |
|
|
|
//如果地址信息不为空则循环设置不接单日期 |
|
|
|
for (AppletAddress appletAddress1 : addressList){ |
|
|
|
if(appletAddress1.getId() != null){ |
|
|
|
AppletOutDate appletOutDate = new AppletOutDate(); |
|
|
|
appletOutDate.setAddressId(appletAddress1.getId()); |
|
|
|
List<AppletOutDate> outDateList = appletOutDateService.selectAppletOutDateList(appletOutDate); |
|
|
|
appletAddress1.setAppletOutDate(outDateList); |
|
|
|
} |
|
|
|
//如果地址信息不为空则循环设置不接单日期 |
|
|
|
for (AppletAddress appletAddress1 : addressList){ |
|
|
|
if(appletAddress1.getId() != null){ |
|
|
|
AppletOutDate appletOutDate = new AppletOutDate(); |
|
|
|
appletOutDate.setAddressId(appletAddress1.getId()); |
|
|
|
List<AppletOutDate> outDateList = appletOutDateService.selectAppletOutDateList(appletOutDate); |
|
|
|
appletAddress1.setAppletOutDate(outDateList); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|