Merge branch 'akaunting:master' into invoice-form-enhancements
This commit is contained in:
@ -78,7 +78,7 @@
|
||||
@if (!$hideQuantity)
|
||||
<div>
|
||||
@stack('quantity_input_start')
|
||||
<input
|
||||
<input
|
||||
type="number"
|
||||
min="0"
|
||||
class="form-control text-center p-0 input-number-disabled"
|
||||
@ -163,11 +163,15 @@
|
||||
</div>
|
||||
@stack('discount_input_start')
|
||||
<div class="form-group mb-0 w-100" style="display: inline-block; position: relative;">
|
||||
<div class="input-group input-group-merge mb-0 select-tax">
|
||||
<div class="input-group mb-0 select-tax">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text" id="input-discount">
|
||||
<i class="fa fa-percent"></i>
|
||||
</span>
|
||||
<button class="btn btn-sm" :class="[{'btn-outline-primary' : row.discount_type !== 'percentage'}, {'btn-primary' : row.discount_type === 'percentage'}]"
|
||||
@click="onChangeLineDiscountType(index, 'percentage')" type="button">
|
||||
<i class="fa fa-percent fa-sm"></i>
|
||||
</button>
|
||||
<button class="btn btn-sm" :class="[{'btn-outline-primary' : row.discount_type !== 'fixed'}, {'btn-primary' : row.discount_type === 'fixed'}]"
|
||||
@click="onChangeLineDiscountType(index, 'fixed')" type="button">{{ $currency->symbol }}
|
||||
</button>
|
||||
</div>
|
||||
<input type="number"
|
||||
max="100"
|
||||
@ -217,18 +221,19 @@
|
||||
:placeholder="'{{ trans('general.form.select.field', ['field' => trans_choice('general.taxes', 1)]) }}'"
|
||||
:name="'items.' + index + '.taxes.' + row_tax_index"
|
||||
:options="{{ json_encode($taxes->pluck('title', 'id')) }}"
|
||||
:dynamic-options="dynamic_taxes"
|
||||
:disabled-options="form.items[index].tax_ids"
|
||||
:value="row_tax.id"
|
||||
@interface="row_tax.id = $event"
|
||||
@change="onCalculateTotal()"
|
||||
@new="taxes.push($event)"
|
||||
@new="dynamic_taxes.push($event)"
|
||||
:form-error="form.errors.get('items.' + index + '.taxes')"
|
||||
:no-data-text="'{{ trans('general.no_data') }}'"
|
||||
:no-matching-data-text="'{{ trans('general.no_matching_data') }}'"
|
||||
></akaunting-select>
|
||||
@stack('taxes_input_end')
|
||||
</div>
|
||||
|
||||
|
||||
<div class="line-item-content-right">
|
||||
<div class="line-item-content-right-price long-texts text-right">
|
||||
{{ Form::moneyGroup('tax', '', '', ['required' => 'required', 'disabled' => 'true' , 'row-input' => 'true', 'v-model' => 'row_tax.price', 'data-item' => 'total', 'currency' => $currency, 'dynamic-currency' => 'currency'], 0.00, 'text-right input-price disabled-money') }}
|
||||
@ -243,7 +248,7 @@
|
||||
<div v-if="row.add_tax" class="line-item-area pb-3" :class="{'pt-2' : row.add_discount}">
|
||||
<div class="line-item-content">
|
||||
<div class="long-texts line-item-text" style="float: left; margin-top: 15px; margin-right:2px; position: absolute; left: -63px;">
|
||||
{{ trans_choice('general.taxes', 1) }}
|
||||
{{ trans_choice('general.taxes', 1) }}
|
||||
</div>
|
||||
|
||||
@stack('taxes_input_start')
|
||||
@ -256,6 +261,7 @@
|
||||
:placeholder="'{{ trans('general.form.select.field', ['field' => trans_choice('general.taxes', 1)]) }}'"
|
||||
:name="'items.' + index + '.taxes.999'"
|
||||
:options="{{ json_encode($taxes->pluck('title', 'id')) }}"
|
||||
:dynamic-options="dynamic_taxes"
|
||||
:disabled-options="form.items[index].tax_ids"
|
||||
:value="tax_id"
|
||||
:add-new="{{ json_encode([
|
||||
@ -281,7 +287,7 @@
|
||||
])}}"
|
||||
@interface="tax_id = $event"
|
||||
@visible-change="onSelectedTax(index)"
|
||||
@new="taxes.push($event)"
|
||||
@new="dynamic_taxes.push($event)"
|
||||
:form-error="form.errors.get('items.' + index + '.taxes')"
|
||||
:no-data-text="'{{ trans('general.no_data') }}'"
|
||||
:no-matching-data-text="'{{ trans('general.no_matching_data') }}'"
|
||||
|
@ -49,27 +49,32 @@
|
||||
<el-popover
|
||||
popper-class="p-0 h-0"
|
||||
placement="bottom"
|
||||
width="300"
|
||||
width="350"
|
||||
v-model="discount">
|
||||
<div class="card d-none" :class="[{'show' : discount}]">
|
||||
<div class="discount card-body">
|
||||
<div class="row align-items-center">
|
||||
<div class="col-sm-6">
|
||||
<div class="input-group input-group-merge">
|
||||
<div class="col-sm-8">
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text" id="input-discount">
|
||||
<i class="fa fa-percent"></i>
|
||||
</span>
|
||||
<button class="btn btn-sm" :class="[{'btn-outline-primary' : form.discount_type !== 'percentage'}, {'btn-primary' : form.discount_type === 'percentage'}]"
|
||||
@click="onChangeDiscountType('percentage')" type="button">
|
||||
<i class="fa fa-percent fa-sm"></i>
|
||||
</button>
|
||||
<button class="btn btn-sm" :class="[{'btn-outline-primary' : form.discount_type !== 'fixed'}, {'btn-primary' : form.discount_type === 'fixed'}]"
|
||||
@click="onChangeDiscountType('fixed')" type="button">{{ $currency->symbol }}
|
||||
</button>
|
||||
</div>
|
||||
{!! Form::number('pre_discount', null, ['id' => 'pre-discount', 'class' => 'form-control', 'v-model' => 'form.discount']) !!}
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-6">
|
||||
<div class="col-sm-4">
|
||||
<div class="discount-description">
|
||||
<strong>{{ trans('invoices.discount_desc') }}</strong>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="discount card-footer">
|
||||
<div class="row float-right">
|
||||
|
Reference in New Issue
Block a user