commit
This commit is contained in:
@@ -24,6 +24,7 @@ import io.v.nutz.web.commons.base.Globals;
|
|||||||
import io.v.nutz.web.commons.utils.ShiroUtil;
|
import io.v.nutz.web.commons.utils.ShiroUtil;
|
||||||
import io.v.nutz.zhgh.welfare.feature.WelfareFeature;
|
import io.v.nutz.zhgh.welfare.feature.WelfareFeature;
|
||||||
import io.v.nutz.zhgh.welfare.mode.CourierNumberExcelMode;
|
import io.v.nutz.zhgh.welfare.mode.CourierNumberExcelMode;
|
||||||
|
import io.v.nutz.zhgh.welfare.mode.WelfareProvideMode;
|
||||||
import io.v.nutz.zhgh.welfare.model.*;
|
import io.v.nutz.zhgh.welfare.model.*;
|
||||||
import io.v.nutz.zhgh.welfare.service.WelfareListService;
|
import io.v.nutz.zhgh.welfare.service.WelfareListService;
|
||||||
import io.v.nutz.zhgh.welfare.service.WelfareProjectService;
|
import io.v.nutz.zhgh.welfare.service.WelfareProjectService;
|
||||||
@@ -284,13 +285,19 @@ public class WelfareListController {
|
|||||||
Cnd.where("welfareId", "=", editData.getString("projectId"))
|
Cnd.where("welfareId", "=", editData.getString("projectId"))
|
||||||
.and("selectUserId", "=", editData.getString("userId")));
|
.and("selectUserId", "=", editData.getString("userId")));
|
||||||
String finalSign = sign;
|
String finalSign = sign;
|
||||||
|
WelfareProject project = dao.fetch(WelfareProject.class, editData.getString("projectId"));
|
||||||
|
boolean personalProvideMode = project != null && WelfareProvideMode.PERSONAL.getCode().equals(project.getProvideMode());
|
||||||
List<WelfareUserSelection> userSelections = optionList.stream().map(v -> {
|
List<WelfareUserSelection> userSelections = optionList.stream().map(v -> {
|
||||||
WelfareUserSelection selection = new WelfareUserSelection();
|
WelfareUserSelection selection = new WelfareUserSelection();
|
||||||
selection.setSelectTime(new Date());
|
selection.setSelectTime(new Date());
|
||||||
selection.setWelfareId(editData.getString("projectId"));
|
selection.setWelfareId(editData.getString("projectId"));
|
||||||
selection.setSelectUserId(editData.getString("userId"));
|
selection.setSelectUserId(editData.getString("userId"));
|
||||||
selection.setSelectOptionId(v.getString("id"));
|
selection.setSelectOptionId(v.getString("id"));
|
||||||
selection.setReceiveAddress(StrUtil.isNotBlank(v.getString("shoppingId")) ? v.getString("receiveAddress") : editData.getString("receiveAddress"));
|
// 邮寄到家保存整单收货地址,其他模式保留供应商门店地址优先逻辑。
|
||||||
|
String receiveAddress = personalProvideMode
|
||||||
|
? editData.getString("receiveAddress")
|
||||||
|
: StrUtil.isNotBlank(v.getString("shoppingId")) ? v.getString("receiveAddress") : editData.getString("receiveAddress");
|
||||||
|
selection.setReceiveAddress(receiveAddress);
|
||||||
selection.setSubjectId(v.getString("subjectId"));
|
selection.setSubjectId(v.getString("subjectId"));
|
||||||
selection.setSelectNum(v.getInt("selectNum"));
|
selection.setSelectNum(v.getInt("selectNum"));
|
||||||
selection.setUserSign(finalSign);
|
selection.setUserSign(finalSign);
|
||||||
|
|||||||
Reference in New Issue
Block a user