Compare commits

..

No commits in common. "5c6a4e985af3a70de92f41610a9bb0208c2dd2dc" and "06df245d59598e97d86eaefe55e287a5c0c5ca1f" have entirely different histories.

4 changed files with 11 additions and 25 deletions

View File

@ -77,7 +77,6 @@ public class ShopPageAppController extends BaseControllerImpl {
Map data_arr = null; Map data_arr = null;
JSONArray items_arr =null; JSONArray items_arr =null;
List<Map> items =null; List<Map> items =null;
boolean isNewFlag=false;
try { try {
// data_arr = cloundService.getAppTpl(accountBaseConfigService.getConfig("service_user_id", 0), accountBaseConfigService.getConfig("service_app_key", ""), null); // data_arr = cloundService.getAppTpl(accountBaseConfigService.getConfig("service_user_id", 0), accountBaseConfigService.getConfig("service_app_key", ""), null);
if(user.isStore()) { if(user.isStore()) {
@ -90,7 +89,6 @@ public class ShopPageAppController extends BaseControllerImpl {
data_arr = (Map)jsonObject.get("data"); data_arr = (Map)jsonObject.get("data");
items_arr = (JSONArray) data_arr.get("items"); items_arr = (JSONArray) data_arr.get("items");
items = JSONUtil.toList(items_arr, Map.class); items = JSONUtil.toList(items_arr, Map.class);
isNewFlag=true;
}else { }else {
Gson gson = new Gson(); Gson gson = new Gson();
String gsonStrList= gson.toJson(shopPageAppList); String gsonStrList= gson.toJson(shopPageAppList);
@ -127,12 +125,9 @@ public class ShopPageAppController extends BaseControllerImpl {
continue; continue;
} }
//String appId= String.valueOf(item.get("tpl_label")); //String appId= String.valueOf(item.get("tpl_label"));
if(isNewFlag&&shopStoreInfo.getStore_template().equals(String.valueOf(item.get("tpl_label")))){ if (is_use==1&&(shopStoreInfo.getStore_template().equals(tpl_label)||
shopStoreInfo.getStore_template().equals(String.valueOf(item.get("tpl_label"))))) {
current_tpl = item; current_tpl = item;
}else {
if (is_use==1&&(shopStoreInfo.getStore_template().equals(tpl_label))) {
current_tpl = item;
}
} }
} else { } else {
@ -180,9 +175,7 @@ public class ShopPageAppController extends BaseControllerImpl {
queryWrapper.eq("store_id", 0); queryWrapper.eq("store_id", 0);
} }
*/ */
if(isNewFlag){
items=new ArrayList<>();
}
data.put("items", items); data.put("items", items);
data.put("current_tpl", current_tpl); data.put("current_tpl", current_tpl);
return CommonResult.success(data); return CommonResult.success(data);

View File

@ -665,10 +665,7 @@ public class ShopPageAppServiceImpl extends BaseServiceImpl<ShopPageAppMapper, S
} else { } else {
Map app_row = null; Map app_row = null;
try { try {
// app_row = cloundService.getAppTpl(accountBaseConfigService.getConfig("service_user_id", 0), accountBaseConfigService.getConfig("service_app_key", ""), tpl_id); app_row = cloundService.getAppTpl(accountBaseConfigService.getConfig("service_user_id", 0), accountBaseConfigService.getConfig("service_app_key", ""), tpl_id);
String resultStr= accountBaseConfigService.getSystemConfig("service_app_tpl");
JSONObject jsonObject = JSONUtil.parseObj(resultStr);
app_row = (Map)jsonObject.get("data");
} catch (Exception e) { } catch (Exception e) {
throw new RuntimeException(e); throw new RuntimeException(e);
} }
@ -736,10 +733,7 @@ public class ShopPageAppServiceImpl extends BaseServiceImpl<ShopPageAppMapper, S
} else { } else {
Map app_row = null; Map app_row = null;
try { try {
// app_row = cloundService.getAppTpl(accountBaseConfigService.getConfig("service_user_id", 0), accountBaseConfigService.getConfig("service_app_key", ""), tpl_id); app_row = cloundService.getAppTpl(accountBaseConfigService.getConfig("service_user_id", 0), accountBaseConfigService.getConfig("service_app_key", ""), tpl_id);
String resultStr= accountBaseConfigService.getSystemConfig("service_app_tpl");
JSONObject jsonObject = JSONUtil.parseObj(resultStr);
app_row = (Map)jsonObject.get("data");
} catch (Exception e) { } catch (Exception e) {
throw new RuntimeException(e); throw new RuntimeException(e);
} }
@ -786,7 +780,6 @@ public class ShopPageAppServiceImpl extends BaseServiceImpl<ShopPageAppMapper, S
page_cloud_row.setPage_share_image(""); page_cloud_row.setPage_share_image("");
page_cloud_row.setPage_qrcode(""); page_cloud_row.setPage_qrcode("");
page_cloud_row.setApp_id(shopPageApp.getApp_id()); page_cloud_row.setApp_id(shopPageApp.getApp_id());
page_cloud_row.setPage_tpl(shopPageApp.getTpl_id());
shopPageBaseService.add(page_cloud_row); shopPageBaseService.add(page_cloud_row);

View File

@ -5398,14 +5398,14 @@ public class ShopProductBaseServiceImpl extends BaseServiceImpl<ShopProductBaseM
Long existId = Long.valueOf(existBaseIdAndState[0]); Long existId = Long.valueOf(existBaseIdAndState[0]);
Integer product_state_id = Integer.valueOf(existBaseIdAndState[1]); Integer product_state_id = Integer.valueOf(existBaseIdAndState[1]);
base.setProduct_id(existId); base.setProduct_id(existId);
//base.setProduct_name(null); base.setProduct_name(null);
base.setProduct_src_id(existId); base.setProduct_src_id(existId);
if (!(base.getProduct_state_id() == StateCode.PRODUCT_STATE_OFF_THE_SHELF_UNCHECK)) {//重新分配 if (!(base.getProduct_state_id() == StateCode.PRODUCT_STATE_OFF_THE_SHELF_UNCHECK)) {//重新分配
base.setProduct_state_id(product_state_id); base.setProduct_state_id(product_state_id);
} }
shopProductBaseList.get(i).setProduct_id(existId); shopProductBaseList.get(i).setProduct_id(existId);
// shopProductIndexList.get(i).setProduct_name(null); shopProductIndexList.get(i).setProduct_name(null);
// shopProductIndexList.get(i).setProduct_name_index(null); shopProductIndexList.get(i).setProduct_name_index(null);
//shopProductIndexList.get(i).setProduct_id(existId); //shopProductIndexList.get(i).setProduct_id(existId);
// shopProductIndexList.get(i).setProduct_unit_points(BigDecimal.ZERO); // shopProductIndexList.get(i).setProduct_unit_points(BigDecimal.ZERO);
shopProductIndexList.get(i).setProduct_unit_price_max(base.getProduct_market_price()); shopProductIndexList.get(i).setProduct_unit_price_max(base.getProduct_market_price());

View File

@ -844,10 +844,10 @@ public abstract class SyncBaseThirdSxAbstract{
shopProductBase.setProduct_state_id(StateCode.PRODUCT_STATE_OFF_THE_SHELF);//默认是下架 shopProductBase.setProduct_state_id(StateCode.PRODUCT_STATE_OFF_THE_SHELF);//默认是下架
shopProductBase.setUnit_price(BigDecimal.valueOf(jsonObj.getDouble("retail_price"))); shopProductBase.setUnit_price(BigDecimal.valueOf(jsonObj.getDouble("retail_price")));
if(!checkProductContainUnits(productName)){ if(!checkProductContainUnits(productName)){
//String spectItem=StringUtils.isNotEmpty(shopProductBase.getSpecItem())?shopProductBase.getSpecItem():"";//规格 String spectItem=StringUtils.isNotEmpty(shopProductBase.getSpecItem())?shopProductBase.getSpecItem():"";//规格
String unit=StringUtils.isNotEmpty(shopProductBase.getSpecUnit())?shopProductBase.getSpecUnit():"";//规格单位 String unit=StringUtils.isNotEmpty(shopProductBase.getSpecUnit())?shopProductBase.getSpecUnit():"";//规格单位
if(StringUtils.isNotEmpty(unit)){ if(StringUtils.isNotEmpty(spectItem)||StringUtils.isNotEmpty(unit)){
productName=productName+"/"+unit; productName=productName+spectItem+"/"+unit;
} }
} }