fix: update price
This commit is contained in:
@@ -522,11 +522,15 @@ export class TransactionService {
|
||||
|
||||
let newProductPrice = new ProductHistoryPrice();
|
||||
|
||||
newProductPrice = product_price;
|
||||
newProductPrice.id = uuid.v4();
|
||||
newProductPrice.type = product_price.type;
|
||||
newProductPrice.price = hitSupplier.harga;
|
||||
newProductPrice.mark_up_price = product_price.mark_up_price;
|
||||
newProductPrice.startDate = new Date();
|
||||
newProductPrice.product = product;
|
||||
newProductPrice.partner = product_price.partner;
|
||||
|
||||
await this.productHistoryPriceService.create(product_price);
|
||||
await this.productHistoryPriceService.updateEndDate(product.id);
|
||||
await this.productHistoryPriceService.create(newProductPrice);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user