Authored by dongjunjie

店铺销售类目代码优化

... ... @@ -111,13 +111,6 @@ var Bll = {
curShopId = paramList[1];
curCategoryId = paramList[2];
}
if(paramUrl.indexOf("add") > 0){
var param = paramUrl.substring(paramUrl.indexOf("add"));
var paramList = param.split("/");
curShopId = paramList[1];
curCategoryId = window.ViewModel.data;
}
}
};
... ...
... ... @@ -64,7 +64,6 @@ var Bll = {
if(isLoading==1 && loadModal) loadModal.close();
var data = res.data;
console.log(data);
currentShopCategoryNum = data.length;
$('#initCategory').hide();
$('#showCategory').html(common.util.__template2($("#listTemplate").html(),{shopId:currentShopId, data:data})).show();
... ... @@ -133,7 +132,6 @@ $(document).on('click', '.addBtn', function () {
$(document).on('click', '.editCategory', function () {
var categoryName = $(this).parent().parent().find('td').eq(1).text();
var categoryId = $(this).data('categoryid');
console.log(categoryId)
Bll.toast(1, '/shops/shopCategory/update', categoryName, categoryId);
});
... ...
... ... @@ -46,11 +46,13 @@ var Bll = {
},
getUrlParams: function () {
var paramUrl = location.href + "";
if(paramUrl.indexOf("info") > 0){
var param = paramUrl.substring(paramUrl.indexOf("info"));
var paramList = param.split("/");
curShopId = paramList[1];
curCategoryId = paramList[2];
}
}
};
Bll.init();
... ...