|
|
@ -195,12 +195,6 @@ |
|
|
|
<input name="merchandiserTelephone" class="form-control" type="text"> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<div class="form-group"> |
|
|
|
<label class="col-sm-3 control-label">采购员:</label> |
|
|
|
<div class="col-sm-8"> |
|
|
|
<select id="purchaseBuyer_add" name="purchaseBuyer" class="form-control" ></select> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<div class="form-group"> |
|
|
|
<label class="col-sm-3 control-label">是否含税:</label> |
|
|
|
<div class="col-sm-8"> |
|
|
@ -310,41 +304,20 @@ |
|
|
|
var userName = [[${@permission.getPrincipalProperty('userName')}]]; |
|
|
|
$("#form-supplier-add").validate({focusCleanup: true}); |
|
|
|
$(function () { |
|
|
|
getPurchaseOrderCode(); |
|
|
|
}) |
|
|
|
function getPurchaseOrderCode(){ |
|
|
|
$.ajax({ |
|
|
|
url: prefix + "/getId", |
|
|
|
type: "post", |
|
|
|
dateType: "json", |
|
|
|
success: function (resp) { |
|
|
|
if (resp.code === 0) { |
|
|
|
$("input[name='supplierCode']").val(resp.data); |
|
|
|
} else { |
|
|
|
$.modal.msgError("失败啦"); |
|
|
|
} |
|
|
|
if (resp.code === 0) {$("input[name='supplierCode']").val(resp.data);} |
|
|
|
else { $.modal.msgError("失败啦");} |
|
|
|
}, |
|
|
|
error: function () { |
|
|
|
$.modal.msgError("后台出错啦!"); |
|
|
|
} |
|
|
|
error: function () {$.modal.msgError("后台出错啦!");} |
|
|
|
}); |
|
|
|
$.ajax({ |
|
|
|
url: ctx + 'system/user/list', |
|
|
|
type: 'post', |
|
|
|
data:{ |
|
|
|
userName: '业务' |
|
|
|
}, |
|
|
|
success: function (res) { |
|
|
|
if (res.rows.length > 0) { |
|
|
|
var usertData = res.rows; |
|
|
|
for (let i in usertData) { |
|
|
|
$("#purchaseBuyer_add").append( |
|
|
|
"<option value='" + usertData[i].userName + "'>" + usertData[i].userName + "</option>"); |
|
|
|
} |
|
|
|
$("purchaseBuyer_add").val(userName).trigger("change"); |
|
|
|
} else { |
|
|
|
$.modal.msgError(res.msg); |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}) |
|
|
|
} |
|
|
|
|
|
|
|
function submitHandler() { |
|
|
|
if ($.validate.form()) { |
|
|
|