...
|
...
|
@@ -22,7 +22,7 @@ var Bll = { |
|
|
__checkSkn:function(callback) {
|
|
|
var flag = false;
|
|
|
if(editBean.limitSkn) {
|
|
|
common.util.__ajax({
|
|
|
common.util.__ajax2({
|
|
|
async: false,
|
|
|
url: "/limitCode/checkSknValidity",
|
|
|
data: {
|
...
|
...
|
@@ -41,7 +41,10 @@ var Bll = { |
|
|
common.util.__tip("SKN已上架,请先下架");
|
|
|
}
|
|
|
callback && callback(res);
|
|
|
}, true);
|
|
|
}, function() {
|
|
|
flag = true;
|
|
|
common.util.__tip("网络请求异常");
|
|
|
});
|
|
|
}
|
|
|
return flag;
|
|
|
},
|
...
|
...
|
@@ -100,7 +103,7 @@ $(document).on("change", ".observe", function () { |
|
|
});
|
|
|
|
|
|
//输入限制
|
|
|
$(".number").on("keyup", function() {
|
|
|
$(document).on("keyup", ".number", function() {
|
|
|
$(this).val($(this).val().replace(/\D/g, ''));
|
|
|
});
|
|
|
|
...
|
...
|
@@ -116,6 +119,7 @@ $(document).on("click", ".delSku", function () { |
|
|
var index = $(this).data("index");
|
|
|
editBean.skusInfo.splice(index, 1);
|
|
|
Bll.__render();
|
|
|
$(".addSku").attr("disabled", false);
|
|
|
});
|
|
|
$(document).on("click", ".addSku", function () {
|
|
|
editBean.skusInfo.push({
|
...
|
...
|
@@ -145,6 +149,8 @@ $(document).on("blur", ".skus", function() { |
|
|
});
|
|
|
$(document).on("click","#save_brand", function() {
|
|
|
// 限购码状态0:待审核 1:审核通过 2:驳回 3:过期 4:作废
|
|
|
console.log((type == "add" ? (!editBean.limitSkn || !Bll.__checkSkn()) : true));
|
|
|
return;
|
|
|
if(e.validate() && (type == "add" ? (!editBean.limitSkn || !Bll.__checkSkn()) : true)) {
|
|
|
editBean.reqDepartment = editBean.reqDepartment.join("/");
|
|
|
editBean.creatorId = $("#auth_id").val();
|
...
|
...
|
|