mirror of
https://github.com/lnbits/lnbits-legend.git
synced 2025-03-15 12:20:21 +01:00
fix reseting rounding and better UX
This commit is contained in:
parent
f4c0c92655
commit
12b69a7f82
1 changed files with 19 additions and 13 deletions
|
@ -230,21 +230,25 @@
|
||||||
:outline="!($q.dark.isActive)"
|
:outline="!($q.dark.isActive)"
|
||||||
rounded
|
rounded
|
||||||
color="primary"
|
color="primary"
|
||||||
label="Custom"
|
label="Round to"
|
||||||
></q-btn>
|
></q-btn>
|
||||||
<q-input
|
<div class="row q-my-lg" v-if="rounding">
|
||||||
class="q-my-lg"
|
<q-input
|
||||||
ref="inputRounding"
|
class="col"
|
||||||
v-if="rounding"
|
ref="inputRounding"
|
||||||
filled
|
v-model.number="tipRounding"
|
||||||
v-model.number="tipRounding"
|
:placeholder="roundToSugestion"
|
||||||
:placeholder="roundToSugestion"
|
hint="Total amount including tip"
|
||||||
hint="Total amount including tip"
|
:prefix="currency"
|
||||||
|
>
|
||||||
|
<!-- <template v-slot:append>
|
||||||
|
<q-icon name="send" @click="calculatePercent" />
|
||||||
|
</template> -->
|
||||||
|
</q-input>
|
||||||
|
<q-btn class="q-ml-sm" style="margin-bottom: 20px;" color="primary" @click="calculatePercent"
|
||||||
|
>Ok</q-btn
|
||||||
>
|
>
|
||||||
<template v-slot:append>
|
</div>
|
||||||
<q-icon name="check" @click="calculatePercent" />
|
|
||||||
</template>
|
|
||||||
</q-input>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="row q-mt-lg">
|
<div class="row q-mt-lg">
|
||||||
<q-btn flat color="primary" @click="processTipSelection(0)"
|
<q-btn flat color="primary" @click="processTipSelection(0)"
|
||||||
|
@ -478,6 +482,8 @@
|
||||||
},
|
},
|
||||||
submitForm: function () {
|
submitForm: function () {
|
||||||
if (this.tip_options && this.tip_options.length) {
|
if (this.tip_options && this.tip_options.length) {
|
||||||
|
this.rounding = false
|
||||||
|
this.tipRounding = null
|
||||||
this.showTipModal()
|
this.showTipModal()
|
||||||
} else {
|
} else {
|
||||||
this.showInvoice()
|
this.showInvoice()
|
||||||
|
|
Loading…
Add table
Reference in a new issue