disable cancel invoice in customer

This commit is contained in:
Sai Naw Wun
2020-10-28 06:58:45 +06:30
parent fca5b2e8bf
commit 703a633108
3 changed files with 39 additions and 10 deletions

View File

@@ -37,11 +37,13 @@ class _PaymentPageState extends State<PaymentPage> {
bool isNew;
File _file;
bool _hasBalance;
@override
void initState() {
super.initState();
_invoice = widget.invoice;
_hasBalance = widget.invoice.balance > 0;
_loadInvoice();
}
@@ -100,16 +102,18 @@ class _PaymentPageState extends State<PaymentPage> {
body: ListView(
padding: const EdgeInsets.all(10.0),
children: <Widget>[
amountBox,
_hasBalance ? amountBox : Container(),
SizedBox(height: 10),
Align(
child: Padding(
padding: const EdgeInsets.all(8.0),
child: receiptFileBox,
),
alignment: Alignment.centerLeft,
),
payBtnBox,
_hasBalance
? Align(
child: Padding(
padding: const EdgeInsets.all(8.0),
child: receiptFileBox,
),
alignment: Alignment.centerLeft,
)
: Container(),
_hasBalance ? payBtnBox : Container(),
SizedBox(height: 15),
LocalTitle(textKey: "pm.receipt"),
Column(