|
|
|
|
|
|
|
|
methods: { |
|
|
methods: { |
|
|
formatPrice: formatPrice, |
|
|
formatPrice: formatPrice, |
|
|
init: function () { |
|
|
init: function () { |
|
|
|
|
|
var app = this; |
|
|
|
|
|
|
|
|
if (this.getDocumentId()) { |
|
|
if (this.getDocumentId()) { |
|
|
var app = this; |
|
|
|
|
|
|
|
|
|
|
|
axios.get(UrlManager.getBaseUrlAbsolute() + "document/ajax-init", { |
|
|
axios.get(UrlManager.getBaseUrlAbsolute() + "document/ajax-init", { |
|
|
params: { |
|
|
params: { |
|
|
idDocument: this.getDocumentId(), |
|
|
idDocument: this.getDocumentId(), |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
}); |
|
|
}); |
|
|
} |
|
|
} |
|
|
|
|
|
else { |
|
|
|
|
|
$('.select2-document-form').on('select2:select', function (e) { |
|
|
|
|
|
var idUser = e.params.data.id; |
|
|
|
|
|
app.idUser = idUser; |
|
|
|
|
|
app.changeUser(); |
|
|
|
|
|
}); |
|
|
|
|
|
} |
|
|
}, |
|
|
}, |
|
|
getProductById: function(idProduct) { |
|
|
getProductById: function(idProduct) { |
|
|
var app = this; |
|
|
var app = this; |