Email templates
This commit is contained in:
parent
33cbaacf7c
commit
0aaf3aa6df
|
|
@ -23,5 +23,7 @@
|
||||||
<orderEntry type="jdk" jdkName="Android API 25 Platform" jdkType="Android SDK" />
|
<orderEntry type="jdk" jdkName="Android API 25 Platform" jdkType="Android SDK" />
|
||||||
<orderEntry type="sourceFolder" forTests="false" />
|
<orderEntry type="sourceFolder" forTests="false" />
|
||||||
<orderEntry type="library" name="Flutter for Android" level="project" />
|
<orderEntry type="library" name="Flutter for Android" level="project" />
|
||||||
|
<orderEntry type="library" name="Dart SDK" level="project" />
|
||||||
|
<orderEntry type="library" name="Dart Packages" level="project" />
|
||||||
</component>
|
</component>
|
||||||
</module>
|
</module>
|
||||||
|
|
@ -43,67 +43,82 @@ class _EmailInvoiceViewState extends State<EmailInvoiceView> {
|
||||||
padding: const EdgeInsets.all(16.0),
|
padding: const EdgeInsets.all(16.0),
|
||||||
child: Row(
|
child: Row(
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Expanded(
|
DropdownButtonHideUnderline(
|
||||||
child: DropdownButtonHideUnderline(
|
child: DropdownButton<String>(
|
||||||
child: DropdownButton<String>(
|
value: selectedTemplate,
|
||||||
value: selectedTemplate,
|
onChanged: (value) {
|
||||||
onChanged: (value) {
|
setState(() {
|
||||||
setState(() {
|
final localization = AppLocalization.of(context);
|
||||||
final localization = AppLocalization.of(context);
|
final company = widget.viewModel.company;
|
||||||
final company = widget.viewModel.company;
|
selectedTemplate = value;
|
||||||
selectedTemplate = value;
|
|
||||||
|
|
||||||
switch (value) {
|
switch (value) {
|
||||||
//case const :
|
//case const :
|
||||||
}
|
}
|
||||||
selectedTemplate = localization.initialEmail;
|
selectedTemplate = localization.initialEmail;
|
||||||
emailSubject = company.emailSubjectInvoice;
|
emailSubject = company.emailSubjectInvoice;
|
||||||
emailBody = company.emailBodyInvoice;
|
emailBody = company.emailBodyInvoice;
|
||||||
|
});
|
||||||
});
|
},
|
||||||
},
|
items: [
|
||||||
items: [
|
DropdownMenuItem<String>(
|
||||||
DropdownMenuItem<String>(
|
child: Text(localization.initialEmail),
|
||||||
child: Text(localization.initialEmail),
|
value: localization.initialEmail,
|
||||||
value: localization.initialEmail,
|
),
|
||||||
),
|
DropdownMenuItem<String>(
|
||||||
DropdownMenuItem<String>(
|
child: Text(localization.firstReminder),
|
||||||
child: Text(localization.firstReminder),
|
value: localization.firstReminder,
|
||||||
value: localization.firstReminder,
|
),
|
||||||
),
|
DropdownMenuItem<String>(
|
||||||
DropdownMenuItem<String>(
|
child: Text(localization.secondReminder),
|
||||||
child: Text(localization.secondReminder),
|
value: localization.secondReminder,
|
||||||
value: localization.secondReminder,
|
),
|
||||||
),
|
DropdownMenuItem<String>(
|
||||||
DropdownMenuItem<String>(
|
child: Text(localization.thirdReminder),
|
||||||
child: Text(localization.thirdReminder),
|
value: localization.thirdReminder,
|
||||||
value: localization.thirdReminder,
|
),
|
||||||
),
|
],
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
Expanded(
|
||||||
|
child: Container(),
|
||||||
|
),
|
||||||
SizedBox(
|
SizedBox(
|
||||||
width: 10.0,
|
width: 10.0,
|
||||||
),
|
),
|
||||||
ElevatedButton(
|
ElevatedButton(
|
||||||
label: localization.send,
|
label: localization.send,
|
||||||
color: Colors.orange,
|
color: Colors.orange,
|
||||||
onPressed: () {
|
onPressed: () {},
|
||||||
|
|
||||||
},
|
|
||||||
)
|
)
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
SingleChildScrollView(
|
ListView(
|
||||||
child: Container(
|
shrinkWrap: true,
|
||||||
color: Colors.white,
|
children: <Widget>[
|
||||||
child: HtmlView(
|
Container(
|
||||||
//data: widget.viewModel.company.emailBodyInvoice,
|
color: Colors.white,
|
||||||
data: emailBody,
|
child: Padding(
|
||||||
|
padding: const EdgeInsets.all(13.0),
|
||||||
|
child: Text(
|
||||||
|
emailSubject,
|
||||||
|
style: TextStyle(
|
||||||
|
color: Colors.black,
|
||||||
|
fontWeight: FontWeight.bold,
|
||||||
|
fontSize: 16.0,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
),
|
),
|
||||||
),
|
Container(
|
||||||
|
color: Colors.white,
|
||||||
|
child: HtmlView(
|
||||||
|
//data: widget.viewModel.company.emailBodyInvoice,
|
||||||
|
data: emailBody,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
);
|
);
|
||||||
|
|
|
||||||
18
pubspec.lock
18
pubspec.lock
|
|
@ -112,14 +112,14 @@ packages:
|
||||||
name: cli_util
|
name: cli_util
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "0.1.3"
|
version: "0.1.3+2"
|
||||||
code_builder:
|
code_builder:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
name: code_builder
|
name: code_builder
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "3.1.1"
|
version: "3.1.2"
|
||||||
collection:
|
collection:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
|
@ -154,7 +154,7 @@ packages:
|
||||||
name: dart_style
|
name: dart_style
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.1.1"
|
version: "1.1.3"
|
||||||
file:
|
file:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
|
@ -168,7 +168,7 @@ packages:
|
||||||
name: fixnum
|
name: fixnum
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "0.10.7"
|
version: "0.10.8"
|
||||||
flutter:
|
flutter:
|
||||||
dependency: "direct main"
|
dependency: "direct main"
|
||||||
description: flutter
|
description: flutter
|
||||||
|
|
@ -258,7 +258,7 @@ packages:
|
||||||
name: graphs
|
name: graphs
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "0.1.2"
|
version: "0.1.2+1"
|
||||||
html:
|
html:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
|
@ -508,7 +508,7 @@ packages:
|
||||||
name: source_gen
|
name: source_gen
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "0.8.3"
|
version: "0.8.3+1"
|
||||||
source_map_stack_trace:
|
source_map_stack_trace:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
|
@ -550,7 +550,7 @@ packages:
|
||||||
name: stream_transform
|
name: stream_transform
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "0.0.14"
|
version: "0.0.14+1"
|
||||||
string_scanner:
|
string_scanner:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
|
@ -592,7 +592,7 @@ packages:
|
||||||
name: url_launcher
|
name: url_launcher
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "3.0.2"
|
version: "3.0.3"
|
||||||
utf:
|
utf:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
|
@ -650,5 +650,5 @@ packages:
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "2.1.15"
|
version: "2.1.15"
|
||||||
sdks:
|
sdks:
|
||||||
dart: ">=2.0.0-dev.62.0 <=2.0.0-dev.69.5.flutter-eab492385c"
|
dart: ">=2.0.0-dev.65 <=2.0.0-dev.69.5.flutter-eab492385c"
|
||||||
flutter: ">=0.2.5 <2.0.0"
|
flutter: ">=0.2.5 <2.0.0"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue