select2
This commit is contained in:
parent
75aa96b61d
commit
e579f15ce6
|
|
@ -250,6 +250,7 @@ class LoadTransport extends ComponentBase
|
|||
//->where("status_accountant", "accept")
|
||||
//->where("status_director", "accept")
|
||||
->addSelect(DB::raw("SUM(amount) as quantity"))
|
||||
->having('quantity', '>', 0)
|
||||
->groupBy('romanah_gokbakja_rulon_action.product_id')
|
||||
->orderBy('id', 'DESC')
|
||||
->get();
|
||||
|
|
@ -316,6 +317,7 @@ class LoadTransport extends ComponentBase
|
|||
//->where("status_accountant", "accept")
|
||||
//->where("status_director", "accept")
|
||||
->addSelect(DB::raw("SUM(amount) as quantity"))
|
||||
->having('quantity', '>', 0)
|
||||
->groupBy('romanah_gokbakja_bag_actions.product_id')
|
||||
->orderBy('id', 'DESC')
|
||||
->get();
|
||||
|
|
|
|||
|
|
@ -97,6 +97,7 @@ function onStart(){
|
|||
</div>
|
||||
|
||||
<div class="col" id="inStockProducts">
|
||||
|
||||
</div>
|
||||
|
||||
<div class="col">
|
||||
|
|
@ -278,7 +279,7 @@ function onStart(){
|
|||
|
||||
if(data.productFromStock.inStockAmount > 0){
|
||||
dropDownProducts = `<label class="form-label">Sklatdan Haryt Saýlaň</label>
|
||||
<select class="form-control select2" name="product_id">
|
||||
<select class="form-control select2" name="product_id" id="testq">
|
||||
<option value="0">Saýla</option>`;
|
||||
|
||||
if(data.productFromStock.orderItemType == "rulon"){
|
||||
|
|
@ -301,6 +302,7 @@ function onStart(){
|
|||
dropDownProducts += `<input type="hidden" name="product_type" value="`+data.productFromStock.orderItemType+`">`;
|
||||
|
||||
$('#inStockProducts').html(dropDownProducts);
|
||||
$('#testq').select2();
|
||||
}else{
|
||||
dropDownProducts = `<label class="form-label">Sklatda Bu Haryt Ýok</label>
|
||||
<select class="form-control" disabled>
|
||||
|
|
|
|||
Loading…
Reference in New Issue