|
@@ -6,13 +6,24 @@ var curCategoryId = 0, |
|
@@ -6,13 +6,24 @@ var curCategoryId = 0, |
6
|
selectedNum = 0,
|
6
|
selectedNum = 0,
|
7
|
curTab = 0;
|
7
|
curTab = 0;
|
8
|
|
8
|
|
|
|
9
|
+var ENUM = {
|
|
|
10
|
+ status: {
|
|
|
11
|
+ '0': '未上架',
|
|
|
12
|
+ '1': '已上架'
|
|
|
13
|
+ }
|
|
|
14
|
+}
|
|
|
15
|
+
|
9
|
var g1 = new common.grid({
|
16
|
var g1 = new common.grid({
|
10
|
el: '#productTable',
|
17
|
el: '#productTable',
|
11
|
parms: function() {
|
18
|
parms: function() {
|
12
|
return {
|
19
|
return {
|
13
|
categoryId: curCategoryId,
|
20
|
categoryId: curCategoryId,
|
14
|
productSKN: common.util.__input("productSKN"),
|
21
|
productSKN: common.util.__input("productSKN"),
|
15
|
- productName: common.util.__input("productName")
|
22
|
+ productName: common.util.__input("productName"),
|
|
|
23
|
+ maxSortId: tabTree.selected[0] ? tabTree.selected[0].id : "",
|
|
|
24
|
+ middleSortId: tabTree.selected[1] ? tabTree.selected[1].id : "",
|
|
|
25
|
+ smallSortId: tabTree.selected[2] ? tabTree.selected[2].id : "",
|
|
|
26
|
+ status: common.util.__input("status-select")
|
16
|
};
|
27
|
};
|
17
|
},
|
28
|
},
|
18
|
columns: [
|
29
|
columns: [
|
|
@@ -30,6 +41,10 @@ var g1 = new common.grid({ |
|
@@ -30,6 +41,10 @@ var g1 = new common.grid({ |
30
|
{display: "SKN", name: "productSKN"},
|
41
|
{display: "SKN", name: "productSKN"},
|
31
|
{display: "商品名称", name: "productName"},
|
42
|
{display: "商品名称", name: "productName"},
|
32
|
{display: "销售价(元)", name: "salePrice"},
|
43
|
{display: "销售价(元)", name: "salePrice"},
|
|
|
44
|
+ {display: "可售库存", name: "storage"},
|
|
|
45
|
+ {display: "上下架状态", render: function(item) {
|
|
|
46
|
+ return ENUM.status[item.status];
|
|
|
47
|
+ }},
|
33
|
{display: "分类", name: "productSort"},
|
48
|
{display: "分类", name: "productSort"},
|
34
|
{display: "商品分类", render: function (item) {
|
49
|
{display: "商品分类", render: function (item) {
|
35
|
var name = item.categoryName ? item.categoryName : '未分类';
|
50
|
var name = item.categoryName ? item.categoryName : '未分类';
|
|
@@ -64,7 +79,11 @@ var g2 = new common.grid({ |
|
@@ -64,7 +79,11 @@ var g2 = new common.grid({ |
64
|
return {
|
79
|
return {
|
65
|
categoryId: curCategoryId,
|
80
|
categoryId: curCategoryId,
|
66
|
productSKN: common.util.__input("productSKN"),
|
81
|
productSKN: common.util.__input("productSKN"),
|
67
|
- productName: common.util.__input("productName")
|
82
|
+ productName: common.util.__input("productName"),
|
|
|
83
|
+ maxSortId: tabTree.selected[0] ? tabTree.selected[0].id : "",
|
|
|
84
|
+ middleSortId: tabTree.selected[1] ? tabTree.selected[1].id : "",
|
|
|
85
|
+ smallSortId: tabTree.selected[2] ? tabTree.selected[2].id : "",
|
|
|
86
|
+ status: common.util.__input("status-select")
|
68
|
};
|
87
|
};
|
69
|
},
|
88
|
},
|
70
|
columns: [
|
89
|
columns: [
|
|
@@ -83,6 +102,10 @@ var g2 = new common.grid({ |
|
@@ -83,6 +102,10 @@ var g2 = new common.grid({ |
83
|
{display: "SKN", name: "productSKN"},
|
102
|
{display: "SKN", name: "productSKN"},
|
84
|
{display: "商品名称", name: "productName"},
|
103
|
{display: "商品名称", name: "productName"},
|
85
|
{display: "销售价(元)", name: "salePrice"},
|
104
|
{display: "销售价(元)", name: "salePrice"},
|
|
|
105
|
+ {display: "可售库存", name: "storage"},
|
|
|
106
|
+ {display: "上下架状态", render: function(item) {
|
|
|
107
|
+ return ENUM.status[item.status];
|
|
|
108
|
+ }},
|
86
|
{display: "分类", name: "productSort"},
|
109
|
{display: "分类", name: "productSort"},
|
87
|
{display: "商品分类", render: function (item) {
|
110
|
{display: "商品分类", render: function (item) {
|
88
|
var name = item.categoryName ? item.categoryName : '未分类';
|
111
|
var name = item.categoryName ? item.categoryName : '未分类';
|
|
@@ -107,6 +130,9 @@ var g2 = new common.grid({ |
|
@@ -107,6 +130,9 @@ var g2 = new common.grid({ |
107
|
}
|
130
|
}
|
108
|
});
|
131
|
});
|
109
|
|
132
|
|
|
|
133
|
+var tabTree = new common.tabTree("#sortTree");
|
|
|
134
|
+tabTree.init();
|
|
|
135
|
+
|
110
|
var Bll = {
|
136
|
var Bll = {
|
111
|
init: function () {
|
137
|
init: function () {
|
112
|
this.getParamsInUrl();
|
138
|
this.getParamsInUrl();
|