Authored by linlong

品牌排序update

... ... @@ -69,6 +69,7 @@
<label>促销短语:</label>
<input id="salesPhrase" class="form-control" type="text" value="[[salesPhrase]]" style="display: inline-block;width: 280px;">
</div>
<!--
<div class="form-group">
<label>是否热销:</label>
<span>
... ... @@ -77,4 +78,5 @@
<input id="isHostsell" type="hidden" for="radio" value="[[isHostsell]]">
</span>
</div>
-->
</script>
\ No newline at end of file
... ...
... ... @@ -13,6 +13,7 @@
<div class="col-sm-2">
<input type="text" class="form-control" id="sort0" value="0" required />
</div>
<!--
<label class="col-sm-1 control-label" for="sort1">奥莱</label>
<div class="col-sm-2">
<input type="text" class="form-control" id="sort1" value="0" required />
... ... @@ -21,6 +22,7 @@
<div class="col-sm-2">
<input type="text" class="form-control" id="sort2" value="0" required />
</div>
-->
</div>
<div class="col-sm-12" style="color: red;"><div class="col-sm-1"></div>提示:商品在品牌商品列表中的排序,数字越大越靠前</div>
</div>
... ...
... ... @@ -310,6 +310,8 @@ var g = new common.grid({
}
HtmArr.push('<a href="/goods/netsale/info/' + item.productSkn + editPostion + '" class="btn btn-info btn-xs info-btn">查看</a>');
HtmArr.push('<a href="javascript:;" class="btn btn-success btn-xs chima-btn" data-index="' + item.__index + '">尺码</a>');
HtmArr.push('<br><br><input type="text" style="width:100px" name="brandSort" />');
HtmArr.push('<a href="javascript:;" class="btn btn-success btn-xs brandSort-btn" data-index="' + item.__index + '" >品牌排序</a>');
return HtmArr.join('');
}
}]
... ... @@ -633,5 +635,28 @@ $(document).on("click", ".chima-btn", function () {
}
}, true);
});
/**
*品牌排序
*/
$(document).on("click", ".brandSort-btn", function () {
var item = g.rows[$(this).data("index")];
var num = $("input:text[name='brandSort']").eq($(this).data("index")).val();
var searchSortList = [];
for (var i = 0; i < 3; i++) {
searchSortList[i] = {
id:item.productSearchId,
productSkn: item.productSkn,
modelId: i + 1,
projectId: 1,
intValue: num
};
}
common.util.__ajax({
url: '/netSale/saveSearchSort',
data: {
searchSortList: JSON.stringify(searchSortList)
}
});
});
//当点击“无需测量”,该列输入框不可编辑
common.sizeInfo.check();
\ No newline at end of file
... ...