Contractjournal finished & Started Contractconfig Hooks for Provisioning Workflow
This commit is contained in:
@@ -354,9 +354,33 @@
|
||||
});
|
||||
|
||||
$('#product_id').on("autocomplete.select", function(evt, item) {
|
||||
if(item && item.value === 0) {
|
||||
$('#product_id').autoComplete('set', null);
|
||||
if(item) {
|
||||
if(item.value === 0) {
|
||||
$('#product_id').autoComplete('set', null);
|
||||
return;
|
||||
}
|
||||
product_id = item.value;
|
||||
|
||||
$.get("<?=self::getUrl("Product","api")?>", {
|
||||
do: "getProduct",
|
||||
"product_id": product_id
|
||||
},
|
||||
function(success) {
|
||||
if(success.status != "OK") return;
|
||||
|
||||
p = success.result.product;
|
||||
$("#price").val(p.price);
|
||||
$("#price_setup").val(p.price_setup);
|
||||
$("#price_nne").val(p.price_nne);
|
||||
$("#price_nbe").val(p.price_nbe);
|
||||
$("#billing_delay").val(p.billing_delay);
|
||||
$("#billing_period").val(p.billing_period);
|
||||
},
|
||||
"json"
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
});
|
||||
// product autocomplete
|
||||
|
||||
|
||||
Reference in New Issue
Block a user