This commit is contained in:
Shohrat 2024-01-18 11:46:04 +05:00
parent 0dcbcba626
commit d6e8b4ddc3
3 changed files with 7 additions and 6 deletions

View File

@ -57,9 +57,9 @@ return [
'engine' => 'InnoDB',
'host' => 'localhost',
'port' => 3306,
'database' => 'gok_bakja_12',
'database' => 'gok_bakja_from_server',
'username' => 'root',
'password' => '',
'password' => 'bt110226',
'charset' => 'utf8mb4',
'collation' => 'utf8mb4_unicode_ci',
'prefix' => '',

View File

@ -244,7 +244,7 @@ class LoadTransport extends ComponentBase
->where('color_id', $color);
})
->with(['product' => function($q){
$q->with(['bag_type', 'bag_size', 'color']);
$q->with(['bag_type', 'bag_size', 'color', 'machine']);
}])
->where("stock_id", $stock->id)
//->where("status_accountant", "accept")

View File

@ -24,7 +24,7 @@ function onStart(){
$this["orderItems"] = Romanah\Gokbakja\Models\OrderItem::where("order_id", $orderId)->orderBy('id', 'DESC')->get();
$this["loadedItems"] = Romanah\Gokbakja\Models\LoadTransport::where("order_id", $orderId)->where("transport_id", $this["transportId"])->with("order_item")->orderBy("id", "DESC")->get();
$this["loadedItems"] = Romanah\Gokbakja\Models\LoadTransport::where("order_id", $orderId)->where("transport_id", $this["transportId"])->with("order_item")->with('product.machine')->orderBy("id", "DESC")->get();
$this["transport"] = Romanah\Gokbakja\Models\ShippingTransport::where("id", $this["transportId"] )->first();
@ -194,7 +194,8 @@ function onStart(){
<td>#{{loadedItem.order_item_id}}</td>
<td>
{% if loadedItem.order_item.order_item_type == 'rulon' %}
#Rulon{{loadedItem.product_id}}-({{loadedItem.product.produced_weight}}), Jemi: {{loadedItem.order_item.amount}} kg
#Rulon{{loadedItem.product_id}} - Enjam: {{loadedItem.product.machine.name}} - (<font style="color: green;">netto: {{loadedItem.product.produced_weight}} </font>,
<font style="color: darkgoldenrod;"> brutto: {{loadedItem.product.brutto_kg}}) </font>, Sargyt edilen Jemi: {{loadedItem.order_item.amount}} kg
{% else %}
#Halta{{loadedItem.product_id}}, Jemi: {{loadedItem.order_item.amount}} sany, {{loadedItem.order_item.bag_gram}} gr
{% endif %}
@ -285,7 +286,7 @@ function onStart(){
if(data.productFromStock.orderItemType == "rulon"){
var option = '';
for (var item of data.productFromStock.products) {
option += `<option value="`+item.product_id+`">#Rulon` + (item.product_id) + `- sklatda: ` + (item.quantity) + ` kg, ` + (item.product.bag_type.name)+`, Ölçegi: `+ (item.product.width)+`, ` + (item.product.gram)+ `m2, `+ (item.product.layer) + ` gat, ` + (item.product.color.name) +`</option>`;
option += `<option value="`+item.product_id+`">#Rulon` + (item.product_id)+ ` - Enjam: ` + item.product.machine.name + `- sklatda: ` + (item.quantity) + ` kg, ` + (item.product.bag_type.name)+`, Ölçegi: `+ (item.product.width)+`, ` + (item.product.gram)+ `m2, `+ (item.product.layer) + ` gat, ` + (item.product.color.name) +`</option>`;
}
dropDownProducts +=option;
// console.log(option);