Quotes
This commit is contained in:
parent
a6023a8bca
commit
ee360fe764
|
|
@ -30,6 +30,9 @@ const int kInvoiceStatusPaid = 6;
|
|||
const int kDefaultDateFormat = 5;
|
||||
const int kDefaultDateTimeFormat = 5;
|
||||
|
||||
const int kInvoiceTypeStandard = 1;
|
||||
const int kInvoiceTypeQuote = 2;
|
||||
|
||||
const int kActivityEmailInvoice = 6;
|
||||
|
||||
class InvoiceStatusColors {
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ abstract class InvoiceEntity extends Object
|
|||
implements Built<InvoiceEntity, InvoiceEntityBuilder> {
|
||||
static int counter = 0;
|
||||
|
||||
factory InvoiceEntity() {
|
||||
factory InvoiceEntity({bool isQuote = false}) {
|
||||
return _$InvoiceEntity._(
|
||||
id: --InvoiceEntity.counter,
|
||||
amount: 0.0,
|
||||
|
|
@ -81,7 +81,7 @@ abstract class InvoiceEntity extends Object
|
|||
terms: '',
|
||||
publicNotes: '',
|
||||
privateNotes: '',
|
||||
invoiceTypeId: 0,
|
||||
invoiceTypeId: isQuote ? kInvoiceTypeQuote : kInvoiceTypeStandard,
|
||||
isRecurring: false,
|
||||
frequencyId: 0,
|
||||
startDate: '',
|
||||
|
|
|
|||
|
|
@ -14,10 +14,10 @@ import 'package:invoiceninja_flutter/utils/localization.dart';
|
|||
import 'package:font_awesome_flutter/font_awesome_flutter.dart';
|
||||
import 'package:redux/redux.dart';
|
||||
import 'package:url_launcher/url_launcher.dart';
|
||||
|
||||
// STARTER: import - do not remove comment
|
||||
import 'package:invoiceninja_flutter/redux/quote/quote_actions.dart';
|
||||
|
||||
|
||||
class AppDrawer extends StatelessWidget {
|
||||
final AppDrawerVM viewModel;
|
||||
|
||||
|
|
@ -179,12 +179,18 @@ class AppDrawer extends StatelessWidget {
|
|||
},
|
||||
),
|
||||
// STARTER: menu - do not remove comment
|
||||
ListTile(
|
||||
leading: Icon(Icons.widgets),
|
||||
title: Text('Quotes'),
|
||||
onTap: () => store.dispatch(ViewQuoteList(context)),
|
||||
),
|
||||
|
||||
DrawerTile(
|
||||
user: user,
|
||||
entityType: EntityType.quote,
|
||||
icon: FontAwesomeIcons.fileAltO,
|
||||
title: AppLocalization.of(context).quotes,
|
||||
onTap: () => store.dispatch(ViewQuoteList(context)),
|
||||
onCreateTap: () {
|
||||
navigator.pop();
|
||||
store.dispatch(EditQuote(
|
||||
quote: InvoiceEntity(isQuote: true), context: context));
|
||||
},
|
||||
),
|
||||
DrawerTile(
|
||||
user: user,
|
||||
icon: FontAwesomeIcons.cog,
|
||||
|
|
@ -278,7 +284,6 @@ class DrawerTile extends StatelessWidget {
|
|||
'payments' => 'credit-card',
|
||||
'recurring_invoices' => 'files-o',
|
||||
'credits' => 'credit-card',
|
||||
'quotes' => 'file-text-o',
|
||||
'proposals' => 'th-large',
|
||||
'tasks' => 'clock-o',
|
||||
'expenses' => 'file-image-o',
|
||||
|
|
|
|||
Loading…
Reference in New Issue