소스 검색

Merge branch 'dev'

prodstable
부모
커밋
b7a3ff82de
4개의 변경된 파일7개의 추가작업 그리고 2개의 파일을 삭제
  1. +4
    -0
      backend/controllers/OrderController.php
  2. +1
    -1
      common/helpers/Price.php
  3. +1
    -0
      common/models/Subscription.php
  4. +1
    -1
      producer/controllers/OrderController.php

+ 4
- 0
backend/controllers/OrderController.php 파일 보기

@@ -109,6 +109,7 @@ class OrderController extends BackendController
$productOrder->price = $p->price;
$productOrder->unit = $p->unit;
$productOrder->step = $p->step;
$productOrder->id_tax_rate = $p->taxRate->id ;
$productOrder->save();
}
}
@@ -144,6 +145,7 @@ class OrderController extends BackendController
$productOrder->price = $p->price;
$productOrder->unit = $p->unit;
$productOrder->step = $p->step;
$productOrder->id_tax_rate = $p->taxRate->id ;
$productOrder->save();
}
}
@@ -863,6 +865,7 @@ class OrderController extends BackendController
$productOrder->unit = $product->unit;
$productOrder->step = $product->step;
$productOrder->price = $product->price;
$productOrder->id_tax_rate = $product->taxRate->id;
$productOrder->save();
}
}
@@ -924,6 +927,7 @@ class OrderController extends BackendController
$productOrder->unit = $product->unit;
$productOrder->step = $product->step;
$productOrder->price = $product->price;
$productOrder->id_tax_rate = $product->taxRate->id;
}
}


+ 1
- 1
common/helpers/Price.php 파일 보기

@@ -53,7 +53,7 @@ class Price

public static function getPriceWithTax($priceWithoutTax, $taxRate)
{
return floatval($priceWithoutTax) * ($taxRate + 1) ;
return self::numberTwoDecimals(floatval($priceWithoutTax) * ($taxRate + 1)) ;
}

public static function numberTwoDecimals($number)

+ 1
- 0
common/models/Subscription.php 파일 보기

@@ -246,6 +246,7 @@ class Subscription extends ActiveRecordCommon
$productOrder->price = $productSubscription->product->price;
$productOrder->unit = $productSubscription->product->unit;
$productOrder->step = $productSubscription->product->step;
$productOrder->id_tax_rate = $productSubscription->product->taxRate->id;
$productOrder->save();
$productsAdd = true;
}

+ 1
- 1
producer/controllers/OrderController.php 파일 보기

@@ -326,7 +326,7 @@ class OrderController extends ProducerBaseController
$productOrder->id_product = $product->id;

$productOrder->price = $product->price;
$productOrder->id_tax_rate = $product->id_tax_rate;
$productOrder->id_tax_rate = $product->taxRate->id;

$unit = (!is_null($order) && isset($unitsArray[$product->id])) ? $unitsArray[$product->id] : $product->unit;
$coefficient = Product::$unitsArray[$unit]['coefficient'];

Loading…
취소
저장