...
|
...
|
@@ -39,36 +39,38 @@ var ENUM = { |
|
|
{en:"reject",cn:"互斥促销"},
|
|
|
{en:"display",cn:"促销显示"},]
|
|
|
};
|
|
|
|
|
|
//加载显示tab页内容
|
|
|
var loadTabHtml=function(columnname){
|
|
|
var default_html="<a href='#'>bad error</a>";
|
|
|
if (columnname === ENUM.tabName[0].en) {//baseinfo
|
|
|
var html_baseinfo=$("#fm_baseInfo").html();
|
|
|
$("#tab_body").html(html_baseinfo);
|
|
|
}else if(columnname === ENUM.tabName[1].en) {//condition
|
|
|
var html_condition = $("#fm_condition").html()||default_html;
|
|
|
$("#tab_body").html(html_condition);
|
|
|
} else if(columnname === ENUM.tabName[2].en) {//operation
|
|
|
var html_operation = $("#fm_operation").html()||default_html;
|
|
|
$("#tab_body").html(html_operation);
|
|
|
}else if(columnname === ENUM.tabName[3].en) {//limit
|
|
|
var html_limit = $("#fm_limit").html()||default_html;
|
|
|
$("#tab_body").html(html_limit);
|
|
|
}else if(columnname === ENUM.tabName[4].en) {//reject
|
|
|
// 加载促销列表
|
|
|
var html_promotions=$("#fm_reject").html();
|
|
|
$("#tab_body").html(html_promotions);
|
|
|
rejectPromotions.init();
|
|
|
}else if(columnname === ENUM.tabName[5].en) {//display
|
|
|
var html_display = $("#fm_display").html()||default_html;
|
|
|
$("#tab_body").html(html_display);
|
|
|
}
|
|
|
}
|
|
|
//tab 页组件
|
|
|
var t = new common.tab2({
|
|
|
el: "#basicTab",
|
|
|
active: 0,
|
|
|
click: function () {
|
|
|
var columnname = t.options.columns[t.options.active].name;
|
|
|
var default_html="<a href='#'>bad error</a>";
|
|
|
if (columnname === ENUM.tabName[0].en) {//baseinfo
|
|
|
var html_baseinfo=$("#fm_baseInfo").html();
|
|
|
$("#tab_body").html(html_baseinfo);
|
|
|
}else if(columnname === ENUM.tabName[1].en) {//condition
|
|
|
var html_condition = $("#fm_condition").html()||default_html;
|
|
|
$("#tab_body").html(html_condition);
|
|
|
} else if(columnname === ENUM.tabName[2].en) {//operation
|
|
|
var html_operation = $("#fm_operation").html()||default_html;
|
|
|
$("#tab_body").html(html_operation);
|
|
|
}else if(columnname === ENUM.tabName[3].en) {//limit
|
|
|
var html_limit = $("#fm_limit").html()||default_html;
|
|
|
$("#tab_body").html(html_limit);
|
|
|
}else if(columnname === ENUM.tabName[4].en) {//reject
|
|
|
// 加载促销列表
|
|
|
var html_promotions=$("#fm_reject").html();
|
|
|
$("#tab_body").html(html_promotions);
|
|
|
rejectPromotions.init();
|
|
|
}else if(columnname === ENUM.tabName[5].en) {//display
|
|
|
var html_display = $("#fm_display").html()||default_html;
|
|
|
$("#tab_body").html(html_display);
|
|
|
}
|
|
|
|
|
|
loadTabHtml(columnname);
|
|
|
},
|
|
|
columns: [{
|
|
|
name: ENUM.tabName[0].en,
|
...
|
...
|
@@ -96,5 +98,5 @@ var t = new common.tab2({ |
|
|
display: ENUM.tabName[5].cn
|
|
|
}]
|
|
|
}).init(ENUM.tab);
|
|
|
|
|
|
|
|
|
//默认加载
|
|
|
loadTabHtml(t.options.columns[t.options.active].name); |
...
|
...
|
|