update perbaikan pos, return, dan report profit nlost
All checks were successful
All checks were successful
This commit is contained in:
@@ -20,7 +20,7 @@
|
||||
@csrf
|
||||
@method('put')
|
||||
|
||||
<div class="row ">
|
||||
<div class="row mt-3">
|
||||
<div class="col-lg-4">
|
||||
<label>{{ __('Customer') }}</label>
|
||||
<div class="input-group">
|
||||
@@ -58,7 +58,7 @@ class="btn btn-danger square-btn d-flex justify-content-center align-items-cente
|
||||
@foreach ($products as $product)
|
||||
@if (!empty($product->stocks) && $product->stocks->count() > 1)
|
||||
{{-- when multiple stock --}}
|
||||
<div class="product-option-item single-product {{ $product->id }}" data-product_id="{{ $product->id }}" data-default_price="{{ $product->productSalePrice }}" data-route="{{ route('business.carts.store') }}" data-product_name="{{ $product->productName }}" data-product_code="{{ $product->productCode }}" data-product_unit_id="{{ $product->unit_id }}" data-product_unit_name="{{ $product->unit->unitName ?? '' }}" data-purchase_price="{{ $product->productPurchasePrice }}" data-product_image="{{ $product->productPicture }}">
|
||||
<div class="product-option-item single-product {{ $product->id }}" data-product_id="{{ $product->id }}" data-default_price="{{ $product->productSalePrice }}" data-route="{{ route('business.carts.store') }}" data-product_name="{{ $product->productName }}" data-product_code="{{ $product->productCode }}" data-product_unit_id="{{ $product->unit_id }}" data-product_unit_name="{{ $product->unit->unitName ?? '' }}" data-purchase_price="{{ $product->productPurchasePrice }}" data-product_image="{{ $product->productPicture }}" data-vat_percent="{{ $product->vat->rate ?? 0 }}">
|
||||
<div class="product-left">
|
||||
<img src="{{ asset($product->productPicture ?? 'assets/images/products/box.svg') }}" alt="">
|
||||
<div class="product-text">
|
||||
@@ -79,10 +79,11 @@ class="btn btn-danger square-btn d-flex justify-content-center align-items-cente
|
||||
data-product_unit_name="{{ $product->unit->unitName ?? '' }}"
|
||||
data-purchase_price="{{ $product->productPurchasePrice }}"
|
||||
data-product_image="{{ $product->productPicture }}"
|
||||
data-route="{{ route('business.carts.store') }}">
|
||||
data-route="{{ route('business.carts.store') }}"
|
||||
data-vat_percent="{{ $product->vat->rate ?? 0 }}">
|
||||
<div class="product-des">
|
||||
{{ __('Batch') }}: {{ $stock->batch_no ?? 'N/A' }}
|
||||
{{ $product->color ? ', Color: ' . $product->color : '' }}, Code : {{ $product->productCode }}
|
||||
{{ $product->color ? ', Color: ' . $product->color : '' }}
|
||||
<span class="product-in-stock">{{ __('In Stock') }}: {{ $stock->productStock }}</span>
|
||||
</div>
|
||||
<div class="product-price product_price">
|
||||
@@ -108,7 +109,8 @@ class="btn btn-danger square-btn d-flex justify-content-center align-items-cente
|
||||
data-product_image="{{ $product->productPicture }}"
|
||||
data-product_batch_no="{{ $stock->batch_no ?? '' }}"
|
||||
data-product_expire_date="{{ $stock->expire_date ?? '' }}"
|
||||
data-route="{{ route('business.carts.store') }}">
|
||||
data-route="{{ route('business.carts.store') }}"
|
||||
data-vat_percent="{{ $product->vat->rate ?? 0 }}">
|
||||
<div class="product-left">
|
||||
<img src="{{ asset($product->productPicture ?? 'assets/images/products/box.svg') }}" alt="">
|
||||
<div class="product-text">
|
||||
@@ -118,7 +120,7 @@ class="btn btn-danger square-btn d-flex justify-content-center align-items-cente
|
||||
</div>
|
||||
<div class="d-flex align-items-center justify-content-between w-100">
|
||||
<div class="product-des">
|
||||
{{ __('Batch') }}: {{ $stock->batch_no ?? 'N/A' }}, {{ __('Code') }}: {{ $product->productCode }}
|
||||
{{ __('Batch') }}: {{ $stock->batch_no ?? 'N/A' }}
|
||||
{{ $product->color ? ', Color: ' . $product->color : '' }}
|
||||
<span class="product-in-stock">{{ __('In Stock') }}: {{ $stock->productStock ?? 0 }}</span>
|
||||
</div>
|
||||
@@ -157,23 +159,23 @@ class="btn btn-danger square-btn d-flex justify-content-center align-items-cente
|
||||
<th class="border p-2 table-background">{{ __('Batch') }}</th>
|
||||
<th class="border p-2 table-background">{{ __('Unit') }}</th>
|
||||
<th class="border p-2 table-background">{{ __('Sale Price') }}</th>
|
||||
@if (moduleCheck('SerialCodeAddon'))
|
||||
<th class="border table-background serial-option">{{ __('Serial') }}</th>
|
||||
@endif
|
||||
@if ($modules['allow_product_discount'] ?? false)
|
||||
<th class="border p-2 table-background">{{ __('Discount') }}</th>
|
||||
@endif
|
||||
<th class="border p-2 table-background">{{ __('Vat %') }}</th>
|
||||
<th class="border p-2 table-background">{{ __('Vat Value') }}</th>
|
||||
<th class="border p-2 table-background">{{ __('Qty') }}</th>
|
||||
<th class="border p-2 table-background">{{ __('Sub Total') }}</th>
|
||||
<th class="border p-2 table-background">{{ __('Action') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody id="sale_cart_list">
|
||||
<tbody id="cart-list">
|
||||
@include('business::sales.cart-list')
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-sm-12 col-md-6 col-lg-6 mt-5">
|
||||
<div class="amount-info-container inventory-amount-info-container">
|
||||
<div class="row amount-container align-items-center mb-2">
|
||||
@@ -207,20 +209,13 @@ class="btn btn-danger square-btn d-flex justify-content-center align-items-cente
|
||||
<h6 class="fw-bold" id="sub_total">
|
||||
{{ currency_format(0, currency: business_currency()) }}</h6>
|
||||
</div>
|
||||
<div class="row save-amount-container align-items-center mb-2">
|
||||
<h6 class="payment-title col-6">{{ __('Discount') }}</h6>
|
||||
<div class="col-6 w-100 d-flex justify-content-between gap-2">
|
||||
<div class="d-flex d-flex align-items-center gap-2">
|
||||
<select name="discount_type" class="form-select discount_type" id='form-ware'>
|
||||
<option value="flat" @selected($sale->discount_type == 'flat')>{{ __('Flat') }} ({{ business_currency()->symbol }})</option>
|
||||
<option value="percent" @selected($sale->discount_type == 'percent')>{{ __('Percent (%)') }}</option>
|
||||
</select>
|
||||
</div>
|
||||
<input type="number" step="any" name="discountAmount" value="{{ $sale->discount_type == 'percent' ? $sale->discount_percent : $sale->discountAmount }}" id="discount_amount" min="0" class="right-start-input form-control" placeholder="{{ __('0') }}">
|
||||
</div>
|
||||
<div class="mb-2 d-flex align-items-center justify-content-between">
|
||||
<h6>{{ __('Vat') }}</h6>
|
||||
<h6 class="fw-bold" id="vat_amount_txt">
|
||||
{{ currency_format(($sale->vat_amount ?? 0) != 0 ? $sale->vat_amount : (($sale->vat_percent ?? 0) != 0 ? $sale->vat_percent : 0), currency: business_currency()) }}</h6>
|
||||
</div>
|
||||
<div class="row save-amount-container align-items-center mb-2">
|
||||
<h6 class="payment-title col-6">{{ get_business_option('business-settings')['vat_name'] ?? 'Vat' }}</h6>
|
||||
<div class="row save-amount-container align-items-center mb-2 d-none">
|
||||
<h6 class="payment-title col-6">{{ __('Vat') }}</h6>
|
||||
<div class="col-6 w-100 d-flex justify-content-between gap-2">
|
||||
<div class="d-flex d-flex align-items-center gap-2">
|
||||
<select name="vat_id" class="form-select vat_select" id='form-ware'>
|
||||
@@ -233,6 +228,18 @@ class="btn btn-danger square-btn d-flex justify-content-center align-items-cente
|
||||
<input type="number" step="any" name="vat_amount" id="vat_amount" value="{{ ($sale->vat_amount ?? 0) != 0 ? $sale->vat_amount : (($sale->vat_percent ?? 0) != 0 ? $sale->vat_percent : 0) }}" min="0" class="form-control right-start-input" placeholder="{{ __('0') }}" readonly>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row save-amount-container align-items-center mb-2">
|
||||
<h6 class="payment-title col-6">{{ __('Discount') }}</h6>
|
||||
<div class="col-6 w-100 d-flex justify-content-between gap-2">
|
||||
<div class="d-flex d-flex align-items-center gap-2">
|
||||
<select name="discount_type" class="form-select discount_type" id='form-ware'>
|
||||
<option value="flat" @selected($sale->discount_type == 'flat')>{{ __('Flat') }} ({{ business_currency()->symbol }})</option>
|
||||
<option value="percent" @selected($sale->discount_type == 'percent')>{{ __('Percent (%)') }}</option>
|
||||
</select>
|
||||
</div>
|
||||
<input type="number" step="any" name="discountAmount" value="{{ $sale->discount_type == 'percent' ? $sale->discount_percent : $sale->discountAmount }}" id="discount_amount" min="0" class="right-start-input form-control" placeholder="{{ __('0') }}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="row save-amount-container align-items-center mb-2">
|
||||
<h6 class="payment-title col-6">{{ __('Shipping Charge') }}</h6>
|
||||
<div class="col-12 ">
|
||||
@@ -286,16 +293,9 @@ class="theme-btn border-btn m-2">{{__('Cancel')}}
|
||||
<input type="hidden" id="selectedProductValue" name="selectedProductValue">
|
||||
<input type="hidden" id="asset_base_url" value="{{ asset('') }}">
|
||||
<input type="hidden" id="get_stock_prices" value="{{ route('business.products.stocks-prices') }}">
|
||||
<input type="hidden" id="has-serial-code-addon" value="{{ moduleCheck('SerialCodeAddon') }}">
|
||||
<input type="hidden" id="check-serial-exist" value="{{ route('business.products.check-serial') }}">
|
||||
<input type="hidden" id="get-product-serials" value="{{ route('business.products.get-serials') }}"> <input type="hidden" id="is-inventory-page" value="1">
|
||||
|
||||
@endsection
|
||||
|
||||
@push('modal')
|
||||
@if (moduleCheck('SerialCodeAddon'))
|
||||
@include('serialcodeaddon::select-serial-modal')
|
||||
@endif
|
||||
@include('business::sales.calculator')
|
||||
@include('business::sales.customer-create')
|
||||
@endpush
|
||||
|
||||
Reference in New Issue
Block a user