新店铺模板问题修改
This commit is contained in:
parent
8fb45b9bf9
commit
04b0966998
@ -77,6 +77,7 @@ public class ShopPageAppController extends BaseControllerImpl {
|
||||
Map data_arr = null;
|
||||
JSONArray items_arr =null;
|
||||
List<Map> items =null;
|
||||
boolean isNewFlag=false;
|
||||
try {
|
||||
// data_arr = cloundService.getAppTpl(accountBaseConfigService.getConfig("service_user_id", 0), accountBaseConfigService.getConfig("service_app_key", ""), null);
|
||||
if(user.isStore()) {
|
||||
@ -89,6 +90,7 @@ public class ShopPageAppController extends BaseControllerImpl {
|
||||
data_arr = (Map)jsonObject.get("data");
|
||||
items_arr = (JSONArray) data_arr.get("items");
|
||||
items = JSONUtil.toList(items_arr, Map.class);
|
||||
isNewFlag=true;
|
||||
}else {
|
||||
Gson gson = new Gson();
|
||||
String gsonStrList= gson.toJson(shopPageAppList);
|
||||
@ -125,9 +127,12 @@ public class ShopPageAppController extends BaseControllerImpl {
|
||||
continue;
|
||||
}
|
||||
//String appId= 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"))))) {
|
||||
if(isNewFlag&&shopStoreInfo.getStore_template().equals(String.valueOf(item.get("tpl_label")))){
|
||||
current_tpl = item;
|
||||
}else {
|
||||
if (is_use==1&&(shopStoreInfo.getStore_template().equals(tpl_label))) {
|
||||
current_tpl = item;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
|
||||
@ -175,7 +180,9 @@ public class ShopPageAppController extends BaseControllerImpl {
|
||||
queryWrapper.eq("store_id", 0);
|
||||
}
|
||||
*/
|
||||
|
||||
if(isNewFlag){
|
||||
items=new ArrayList<>();
|
||||
}
|
||||
data.put("items", items);
|
||||
data.put("current_tpl", current_tpl);
|
||||
return CommonResult.success(data);
|
||||
|
||||
@ -666,7 +666,10 @@ public class ShopPageAppServiceImpl extends BaseServiceImpl<ShopPageAppMapper, S
|
||||
} else {
|
||||
Map app_row = null;
|
||||
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) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
@ -734,7 +737,10 @@ public class ShopPageAppServiceImpl extends BaseServiceImpl<ShopPageAppMapper, S
|
||||
} else {
|
||||
Map app_row = null;
|
||||
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) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
@ -781,6 +787,7 @@ public class ShopPageAppServiceImpl extends BaseServiceImpl<ShopPageAppMapper, S
|
||||
page_cloud_row.setPage_share_image("");
|
||||
page_cloud_row.setPage_qrcode("");
|
||||
page_cloud_row.setApp_id(shopPageApp.getApp_id());
|
||||
page_cloud_row.setPage_tpl(shopPageApp.getTpl_id());
|
||||
|
||||
|
||||
shopPageBaseService.add(page_cloud_row);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user