...
|
...
|
@@ -6,13 +6,24 @@ var curCategoryId = 0, |
|
|
selectedNum = 0,
|
|
|
curTab = 0;
|
|
|
|
|
|
var ENUM = {
|
|
|
status: {
|
|
|
'0': '未上架',
|
|
|
'1': '已上架'
|
|
|
}
|
|
|
}
|
|
|
|
|
|
var g1 = new common.grid({
|
|
|
el: '#productTable',
|
|
|
parms: function() {
|
|
|
return {
|
|
|
categoryId: curCategoryId,
|
|
|
productSKN: common.util.__input("productSKN"),
|
|
|
productName: common.util.__input("productName")
|
|
|
productName: common.util.__input("productName"),
|
|
|
maxSortId: tabTree.selected[0] ? tabTree.selected[0].id : "",
|
|
|
middleSortId: tabTree.selected[1] ? tabTree.selected[1].id : "",
|
|
|
smallSortId: tabTree.selected[2] ? tabTree.selected[2].id : "",
|
|
|
status: common.util.__input("status-select")
|
|
|
};
|
|
|
},
|
|
|
columns: [
|
...
|
...
|
@@ -30,6 +41,10 @@ var g1 = new common.grid({ |
|
|
{display: "SKN", name: "productSKN"},
|
|
|
{display: "商品名称", name: "productName"},
|
|
|
{display: "销售价(元)", name: "salePrice"},
|
|
|
{display: "可售库存", name: "storage"},
|
|
|
{display: "上下架状态", render: function(item) {
|
|
|
return ENUM.status[item.status];
|
|
|
}},
|
|
|
{display: "分类", name: "productSort"},
|
|
|
{display: "商品分类", render: function (item) {
|
|
|
var name = item.categoryName ? item.categoryName : '未分类';
|
...
|
...
|
@@ -64,7 +79,11 @@ var g2 = new common.grid({ |
|
|
return {
|
|
|
categoryId: curCategoryId,
|
|
|
productSKN: common.util.__input("productSKN"),
|
|
|
productName: common.util.__input("productName")
|
|
|
productName: common.util.__input("productName"),
|
|
|
maxSortId: tabTree.selected[0] ? tabTree.selected[0].id : "",
|
|
|
middleSortId: tabTree.selected[1] ? tabTree.selected[1].id : "",
|
|
|
smallSortId: tabTree.selected[2] ? tabTree.selected[2].id : "",
|
|
|
status: common.util.__input("status-select")
|
|
|
};
|
|
|
},
|
|
|
columns: [
|
...
|
...
|
@@ -83,6 +102,10 @@ var g2 = new common.grid({ |
|
|
{display: "SKN", name: "productSKN"},
|
|
|
{display: "商品名称", name: "productName"},
|
|
|
{display: "销售价(元)", name: "salePrice"},
|
|
|
{display: "可售库存", name: "storage"},
|
|
|
{display: "上下架状态", render: function(item) {
|
|
|
return ENUM.status[item.status];
|
|
|
}},
|
|
|
{display: "分类", name: "productSort"},
|
|
|
{display: "商品分类", render: function (item) {
|
|
|
var name = item.categoryName ? item.categoryName : '未分类';
|
...
|
...
|
@@ -107,6 +130,9 @@ var g2 = new common.grid({ |
|
|
}
|
|
|
});
|
|
|
|
|
|
var tabTree = new common.tabTree("#sortTree");
|
|
|
tabTree.init();
|
|
|
|
|
|
var Bll = {
|
|
|
init: function () {
|
|
|
this.getParamsInUrl();
|
...
|
...
|
|