This commit is contained in:
kifio
2017-09-21 09:11:48 +03:00
parent 912aa2248f
commit 78fe8f01bd
16 changed files with 196 additions and 53 deletions

View File

@@ -47,7 +47,8 @@ android {
buildConfigField "String", "locale", "\"ru\"" buildConfigField "String", "locale", "\"ru\""
buildConfigField "String", "flavor", "\"autobonus\"" buildConfigField "String", "flavor", "\"autobonus\""
buildConfigField "int", "currency", "643" buildConfigField "int", "currency", "643"
buildConfigField "String", "support", "\"8-800-234-6064\"" buildConfigField "String", "supportPhone", "\"8-800-234-6064\""
buildConfigField "String", "supportUrl", "\"https://www.auto-club.biz\""
} }
pip { pip {
@@ -55,7 +56,8 @@ android {
buildConfigField "String", "locale", "\"ua\"" buildConfigField "String", "locale", "\"ua\""
buildConfigField "String", "flavor", "\"pip\"" buildConfigField "String", "flavor", "\"pip\""
buildConfigField "int", "currency", "980" buildConfigField "int", "currency", "980"
buildConfigField "String", "support", "\"+38 080 030 9997\\n+38 044 390 1697\"" buildConfigField "String", "supportPhone", "\"+38 080 030 9997\\n+38 044 390 1697\""
buildConfigField "String", "supportUrl", "\"http://discount.kiev.ua/\""
} }
} }

View File

@@ -238,7 +238,7 @@ public abstract class AbstractScannerActivity extends AppCompatActivity {
public void run() { public void run() {
String message = String.format(getString(R.string.identifier_not_found), card) String message = String.format(getString(R.string.identifier_not_found), card)
+ ".\n" + ".\n"
+ String.format(getString(R.string.error_contact_support), BuildConfig.support); + String.format(getString(R.string.error_contact_support), BuildConfig.supportPhone);
Toast.makeText(AbstractScannerActivity.this, message, Toast.LENGTH_SHORT).show(); Toast.makeText(AbstractScannerActivity.this, message, Toast.LENGTH_SHORT).show();
} }
}); });

View File

@@ -53,7 +53,6 @@ public class MainActivity extends FlutterActivity {
protected void onCreate(Bundle savedInstanceState) { protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState); super.onCreate(savedInstanceState);
GeneratedPluginRegistrant.registerWith(this); GeneratedPluginRegistrant.registerWith(this);
initLocale(this);
mChannel = new MethodChannel(getFlutterView(), "com.dinect.checker/instance_id"); mChannel = new MethodChannel(getFlutterView(), "com.dinect.checker/instance_id");
mChannel.setMethodCallHandler( mChannel.setMethodCallHandler(
new MethodCallHandler() { new MethodCallHandler() {
@@ -67,7 +66,7 @@ public class MainActivity extends FlutterActivity {
private void callMethod(MethodCall call, Result result) { private void callMethod(MethodCall call, Result result) {
switch (call.method) { switch (call.method) {
case "getLocale": case "getLocale":
result.success(BuildConfig.locale); result.success(Locale.getDefault().getLanguage());
break; break;
case "getFlavor": case "getFlavor":
result.success(BuildConfig.flavor); result.success(BuildConfig.flavor);
@@ -82,6 +81,12 @@ public class MainActivity extends FlutterActivity {
case "isOnline": case "isOnline":
checkInternetConnection(result); checkInternetConnection(result);
break; break;
case "getSupportPhone":
result.success(BuildConfig.supportPhone);
break;
case "getSupportUrl":
result.success(BuildConfig.supportUrl);
break;
default: default:
result.notImplemented(); result.notImplemented();
break; break;
@@ -133,28 +138,6 @@ public class MainActivity extends FlutterActivity {
} }
} }
public static void initLocale(Context context) {
Resources res = context.getResources();
Configuration configuration = new Configuration(res.getConfiguration());
switch (BuildConfig.locale) {
case "en":
configuration.locale = new Locale("en");
Locale.setDefault(configuration.locale);
res.updateConfiguration(configuration, res.getDisplayMetrics());
break;
case "ru":
configuration.locale = new Locale("ru");
Locale.setDefault(configuration.locale);
res.updateConfiguration(configuration, res.getDisplayMetrics());
break;
case "ua":
configuration.locale = new Locale("ua");
Locale.setDefault(configuration.locale);
res.updateConfiguration(configuration, res.getDisplayMetrics());
break;
}
}
public void getFlavor() { public void getFlavor() {
} }
@@ -175,4 +158,12 @@ public class MainActivity extends FlutterActivity {
} }
public void getSupportPhone() {
}
public void getSupportUrl() {
}
} }

View File

@@ -11,5 +11,5 @@
<string name="logout_no">Ні</string> <string name="logout_no">Ні</string>
<string name="identifier_not_found">"Ідентифікатор %s не знайден"</string> <string name="identifier_not_found">"Ідентифікатор %s не знайден"</string>
<string name="enter_manual">Введіть штрихкод вручну</string> <string name="enter_manual">Введіть штрихкод вручну</string>
<string name="error_contact_support">Можете воспользоваться ручным вводом или позвонить на номер:\n%s</string> <string name="error_contact_support">Можете скористатися ручним введенням або зателефонувати на номер:\n%s</string>
</resources> </resources>

View File

@@ -11,5 +11,5 @@
<string name="logout_no">No</string> <string name="logout_no">No</string>
<string name="identifier_not_found">"Identifier %s is not found"</string> <string name="identifier_not_found">"Identifier %s is not found"</string>
<string name="enter_manual">Enter the barcode manually</string> <string name="enter_manual">Enter the barcode manually</string>
<string name="error_contact_support">Можете воспользоваться ручным вводом или позвонить на номер:\n%s</string> <string name="error_contact_support">You can use manual input or call the number:\n%s</string>
</resources> </resources>

33
ios/Podfile.lock Normal file
View File

@@ -0,0 +1,33 @@
PODS:
- Flutter (1.0.0)
- FMDB (2.7.2):
- FMDB/standard (= 2.7.2)
- FMDB/standard (2.7.2)
- path_provider (0.0.1):
- Flutter
- sqflite (0.0.1):
- Flutter
- FMDB
DEPENDENCIES:
- Flutter (from `/Users/kifio/flutter/bin/cache/artifacts/engine/ios`)
- path_provider (from `/Users/kifio/.pub-cache/hosted/pub.dartlang.org/path_provider-0.2.1+1/ios`)
- sqflite (from `/Users/kifio/.pub-cache/hosted/pub.dartlang.org/sqflite-0.2.2/ios`)
EXTERNAL SOURCES:
Flutter:
:path: /Users/kifio/flutter/bin/cache/artifacts/engine/ios
path_provider:
:path: /Users/kifio/.pub-cache/hosted/pub.dartlang.org/path_provider-0.2.1+1/ios
sqflite:
:path: /Users/kifio/.pub-cache/hosted/pub.dartlang.org/sqflite-0.2.2/ios
SPEC CHECKSUMS:
Flutter: d674e78c937094a75ac71dd77e921e840bea3dbf
FMDB: 6198a90e7b6900cfc046e6bc0ef6ebb7be9236aa
path_provider: f96fff6166a8867510d2c25fdcc346327cc4b259
sqflite: 8e2d9fe1e7cdc95d4d537fc7eb2d23c8dc428e3c
PODFILE CHECKSUM: 351e02e34b831289961ec3558a535cbd2c4965d2
COCOAPODS: 1.2.0

View File

@@ -11,6 +11,7 @@
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; };
3B80C3941E831B6300D905FE /* App.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; }; 3B80C3941E831B6300D905FE /* App.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; };
3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
755861CA44FB15BD2EFD12F7 /* libPods-Runner.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 28B464359F9DDCC3EF756D7D /* libPods-Runner.a */; };
9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; }; 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; };
9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
9740EEB41CF90195004384FC /* Debug.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 9740EEB21CF90195004384FC /* Debug.xcconfig */; }; 9740EEB41CF90195004384FC /* Debug.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 9740EEB21CF90195004384FC /* Debug.xcconfig */; };
@@ -54,6 +55,7 @@
/* Begin PBXFileReference section */ /* Begin PBXFileReference section */
1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = "<group>"; }; 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = "<group>"; };
1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = "<group>"; }; 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = "<group>"; };
28B464359F9DDCC3EF756D7D /* libPods-Runner.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-Runner.a"; sourceTree = BUILT_PRODUCTS_DIR; };
3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = "<group>"; }; 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = "<group>"; };
3B80C3931E831B6300D905FE /* App.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = App.framework; path = Flutter/App.framework; sourceTree = "<group>"; }; 3B80C3931E831B6300D905FE /* App.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = App.framework; path = Flutter/App.framework; sourceTree = "<group>"; };
7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = "<group>"; }; 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = "<group>"; };
@@ -120,12 +122,20 @@
9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */, 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */,
3B80C3941E831B6300D905FE /* App.framework in Frameworks */, 3B80C3941E831B6300D905FE /* App.framework in Frameworks */,
BBA9BB5B1F179C320053B6EA /* libzbar.a in Frameworks */, BBA9BB5B1F179C320053B6EA /* libzbar.a in Frameworks */,
755861CA44FB15BD2EFD12F7 /* libPods-Runner.a in Frameworks */,
); );
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
}; };
/* End PBXFrameworksBuildPhase section */ /* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */ /* Begin PBXGroup section */
578B8FA7D56ACA2E56C02128 /* Pods */ = {
isa = PBXGroup;
children = (
);
name = Pods;
sourceTree = "<group>";
};
9740EEB11CF90186004384FC /* Flutter */ = { 9740EEB11CF90186004384FC /* Flutter */ = {
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
@@ -148,6 +158,7 @@
97C146F01CF9000F007C117D /* Runner */, 97C146F01CF9000F007C117D /* Runner */,
97C146EF1CF9000F007C117D /* Products */, 97C146EF1CF9000F007C117D /* Products */,
BBA9BB001F1786510053B6EA /* Frameworks */, BBA9BB001F1786510053B6EA /* Frameworks */,
578B8FA7D56ACA2E56C02128 /* Pods */,
); );
sourceTree = "<group>"; sourceTree = "<group>";
}; };
@@ -195,6 +206,7 @@
BBA9BB351F1792690053B6EA /* CoreMedia.framework */, BBA9BB351F1792690053B6EA /* CoreMedia.framework */,
BBA9BB331F17925F0053B6EA /* CoreGraphics.framework */, BBA9BB331F17925F0053B6EA /* CoreGraphics.framework */,
BBA9BB311F1792570053B6EA /* AVFoundation.framework */, BBA9BB311F1792570053B6EA /* AVFoundation.framework */,
28B464359F9DDCC3EF756D7D /* libPods-Runner.a */,
); );
name = Frameworks; name = Frameworks;
sourceTree = "<group>"; sourceTree = "<group>";
@@ -270,12 +282,15 @@
isa = PBXNativeTarget; isa = PBXNativeTarget;
buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */;
buildPhases = ( buildPhases = (
586CFDEBE2C82C2A9F7DA22E /* [CP] Check Pods Manifest.lock */,
9740EEB61CF901F6004384FC /* Run Script */, 9740EEB61CF901F6004384FC /* Run Script */,
97C146EA1CF9000F007C117D /* Sources */, 97C146EA1CF9000F007C117D /* Sources */,
97C146EB1CF9000F007C117D /* Frameworks */, 97C146EB1CF9000F007C117D /* Frameworks */,
97C146EC1CF9000F007C117D /* Resources */, 97C146EC1CF9000F007C117D /* Resources */,
9705A1C41CF9048500538489 /* Embed Frameworks */, 9705A1C41CF9048500538489 /* Embed Frameworks */,
3B06AD1E1E4923F5004D2608 /* Thin Binary */, 3B06AD1E1E4923F5004D2608 /* Thin Binary */,
889CEA9B47E2F8AFF76F6433 /* [CP] Embed Pods Frameworks */,
1F7C9AAD1A9D38F5484B84D1 /* [CP] Copy Pods Resources */,
); );
buildRules = ( buildRules = (
); );
@@ -342,6 +357,21 @@
/* End PBXResourcesBuildPhase section */ /* End PBXResourcesBuildPhase section */
/* Begin PBXShellScriptBuildPhase section */ /* Begin PBXShellScriptBuildPhase section */
1F7C9AAD1A9D38F5484B84D1 /* [CP] Copy Pods Resources */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "[CP] Copy Pods Resources";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-Runner/Pods-Runner-resources.sh\"\n";
showEnvVarsInLog = 0;
};
3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = {
isa = PBXShellScriptBuildPhase; isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647; buildActionMask = 2147483647;
@@ -356,6 +386,36 @@
shellPath = /bin/sh; shellPath = /bin/sh;
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" thin"; shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" thin";
}; };
586CFDEBE2C82C2A9F7DA22E /* [CP] Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "[CP] Check Pods Manifest.lock";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n";
showEnvVarsInLog = 0;
};
889CEA9B47E2F8AFF76F6433 /* [CP] Embed Pods Frameworks */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "[CP] Embed Pods Frameworks";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n";
showEnvVarsInLog = 0;
};
9740EEB61CF901F6004384FC /* Run Script */ = { 9740EEB61CF901F6004384FC /* Run Script */ = {
isa = PBXShellScriptBuildPhase; isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647; buildActionMask = 2147483647;

View File

@@ -4,4 +4,7 @@
<FileRef <FileRef
location = "group:Runner.xcodeproj"> location = "group:Runner.xcodeproj">
</FileRef> </FileRef>
<FileRef
location = "group:Pods/Pods.xcodeproj">
</FileRef>
</Workspace> </Workspace>

View File

@@ -1,7 +1,6 @@
import 'package:checker/resources.dart'; import 'package:checker/resources.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter/services.dart'; import 'package:flutter/services.dart';
import 'package:intl/intl.dart';
import 'package:checker/common.dart'; import 'package:checker/common.dart';
import 'package:checker/consts.dart'; import 'package:checker/consts.dart';
@@ -52,7 +51,9 @@ abstract class BaseState<T extends StatefulWidget> extends State<T> {
} }
AppBar getAppBar() { AppBar getAppBar() {
return new AppBar(title: new Text(getTitle(), style: new TextStyle(fontSize: 18.0)), return new AppBar(title: new Container(
margin: new EdgeInsets.only(left: 16.0),
child: new Text(getTitle(), style: new TextStyle(fontSize: 18.0))),
backgroundColor: Resources.getPrimaryColor(app), actions: getMenuButtons()); backgroundColor: Resources.getPrimaryColor(app), actions: getMenuButtons());
} }

View File

@@ -1,6 +1,5 @@
import 'dart:async'; import 'dart:async';
import 'dart:io'; import 'dart:io';
import 'dart:ui';
import 'package:path/path.dart'; import 'package:path/path.dart';
import 'package:sqflite/sqflite.dart'; import 'package:sqflite/sqflite.dart';

View File

@@ -50,6 +50,21 @@ class MessageLookup extends MessageLookupByLibrary {
"ruble" : MessageLookupByLibrary.simpleMessage("Ruble"), "ruble" : MessageLookupByLibrary.simpleMessage("Ruble"),
"dollar" : MessageLookupByLibrary.simpleMessage("Dollar"), "dollar" : MessageLookupByLibrary.simpleMessage("Dollar"),
"hryvna" : MessageLookupByLibrary.simpleMessage("Hryvna"), "hryvna" : MessageLookupByLibrary.simpleMessage("Hryvna"),
"nominative_ruble": MessageLookupByLibrary.simpleMessage("Ruble"),
"singular_ruble": MessageLookupByLibrary.simpleMessage("Ruble"),
"plural_ruble": MessageLookupByLibrary.simpleMessage("Rubles"),
"nominative_dollar": MessageLookupByLibrary.simpleMessage("US Dollar"),
"singular_dollar": MessageLookupByLibrary.simpleMessage("US Dollar"),
"plural_dollar": MessageLookupByLibrary.simpleMessage("US Dollars"),
"nominative_hryvna": MessageLookupByLibrary.simpleMessage("Hryvnia"),
"singular_hryvna": MessageLookupByLibrary.simpleMessage("Hryvnia"),
"plural_hryvna": MessageLookupByLibrary.simpleMessage("Hryvnia"),
"nominative_tenge": MessageLookupByLibrary.simpleMessage("Tenge"),
"singular_tenge": MessageLookupByLibrary.simpleMessage("Tenge"),
"plural_tenge": MessageLookupByLibrary.simpleMessage("Tenge"),
"nominative_euro": MessageLookupByLibrary.simpleMessage("Euro"),
"singular_euro": MessageLookupByLibrary.simpleMessage("Euro"),
"plural_euro": MessageLookupByLibrary.simpleMessage("Euro"),
"registration_guide": MessageLookupByLibrary.simpleMessage(''' "registration_guide": MessageLookupByLibrary.simpleMessage('''
Store log in screen is the first thing you will see after starting the application. Store log in screen is the first thing you will see after starting the application.

View File

@@ -47,8 +47,57 @@ class MessageLookup extends MessageLookupByLibrary {
"ruble" : MessageLookupByLibrary.simpleMessage("Ruble"), "ruble" : MessageLookupByLibrary.simpleMessage("Ruble"),
"dollar" : MessageLookupByLibrary.simpleMessage("Dollar"), "dollar" : MessageLookupByLibrary.simpleMessage("Dollar"),
"hryvna" : MessageLookupByLibrary.simpleMessage("Hryvna"), "hryvna" : MessageLookupByLibrary.simpleMessage("Hryvna"),
"nominative_ruble": MessageLookupByLibrary.simpleMessage("Rublo"),
"singular_ruble": MessageLookupByLibrary.simpleMessage("Rublo"),
"plural_ruble": MessageLookupByLibrary.simpleMessage("Rublos"),
"nominative_dollar": MessageLookupByLibrary.simpleMessage("Dólar Dolares"),
"singular_dollar": MessageLookupByLibrary.simpleMessage("Dólar Dolares"),
"plural_dollar": MessageLookupByLibrary.simpleMessage("Dólar Dolares"),
"nominative_hryvna": MessageLookupByLibrary.simpleMessage("Hryvnia"),
"singular_hryvna": MessageLookupByLibrary.simpleMessage("Hryvnia"),
"plural_hryvna": MessageLookupByLibrary.simpleMessage("Hryvnia"),
"nominative_tenge": MessageLookupByLibrary.simpleMessage("Tenge"),
"singular_tenge": MessageLookupByLibrary.simpleMessage("Tenge"),
"plural_tenge": MessageLookupByLibrary.simpleMessage("Tenge"),
"nominative_euro": MessageLookupByLibrary.simpleMessage("Euro"),
"singular_euro": MessageLookupByLibrary.simpleMessage("Euro"),
"plural_euro": MessageLookupByLibrary.simpleMessage("Euro"),
"registration_guide": MessageLookupByLibrary.simpleMessage(''' "registration_guide": MessageLookupByLibrary.simpleMessage('''
Después del inicio de una aplicación móvil usted será movido a la página del registro del negocio. Ponga DIN del negocio (DIN está generada por el sistema en el paso del registro del negocio). Store log in screen is the first thing you will see after starting the application.
''')
Enter the store number (DIN). You can look it up in the loyalty program control panel. If you do not have access to the control panel, ask the administrator.
Click the ""Login"" button.
Please wait while the administrator activates your request. You can refresh your store activation status by pressing the ""Update activation status"" button.
After the administrator activates your request, click the ""Complete activation"" button. The application is ready to use.
If you want to log in as another store, click the Menu button (upper right corner of the screen) and select "Exit".
'''),
"usage_guide": MessageLookupByLibrary.simpleMessage('''
Step 1:
Launch this application and scan your customer's loyalty card using the built in scanner.
If the scan is successful, the customer's information will appear on the screen.
Step 2:
Enter the purchase amount and click the ""Create a purchase"" button.
In a pop-up window press ""YES"" to confirm the amount and allot the points to a customer.
If you want to correct the amount, press ""NO"" and you will return back to the purchase screen where you can adjust the amount.
'''),
"support_guide": MessageLookupByLibrary.simpleMessage('''
Always recommend your customers to install your loyalty card app, so they can participate in your loyalty program.
If you have any problems with the application, feel free to contact the support.
Phone:\n%s\n
Our website:\n%s'''),
"common_guide": MessageLookupByLibrary.simpleMessage('''
To improve barcode scanning quality, adjust the distance between the camera and the barcode so that the border around the barcode (if any) is not visible. Otherwise the vertical lines of the border could be wrongly considered as part of the code.''')
}; };
} }

View File

@@ -1,5 +1,3 @@
import 'dart:async';
import 'package:checker/base/base_screen.dart'; import 'package:checker/base/base_screen.dart';
import 'package:checker/base/settings_base_state.dart'; import 'package:checker/base/settings_base_state.dart';
import 'package:checker/db.dart'; import 'package:checker/db.dart';

View File

@@ -1,3 +1,5 @@
import 'dart:async';
import 'package:checker/resources.dart'; import 'package:checker/resources.dart';
import 'package:checker/strings.dart'; import 'package:checker/strings.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
@@ -5,7 +7,6 @@ import 'package:flutter/material.dart';
import 'package:checker/base/base_state.dart'; import 'package:checker/base/base_state.dart';
import 'package:checker/consts.dart'; import 'package:checker/consts.dart';
import 'package:checker/common.dart'; import 'package:checker/common.dart';
import 'package:checker/db.dart';
/// Класс содержит заголовки и текст блоков FAQ. /// Класс содержит заголовки и текст блоков FAQ.
class Entry { class Entry {
@@ -88,25 +89,19 @@ class FAQScreenState<T> extends BaseState<FAQScreen> {
@override Widget build(BuildContext context) { @override Widget build(BuildContext context) {
if (app == null) { if (app == null) {
platform.invokeMethod('getFlavor').then((flavor) { platform.invokeMethod('getFlavor').then((flavor) {
setState(() { initPhoneAndUrl().then((_) {
app = flavor; setState(() {
initPhoneAndUrl(); app = flavor;
});
}); });
}); });
} }
return new Scaffold(appBar: getAppBar(), body: getScreenContent()); return new Scaffold(appBar: getAppBar(), body: getScreenContent());
} }
void initPhoneAndUrl() { Future initPhoneAndUrl() async {
String phone, url; initHelp(await platform.invokeMethod('getSupportPhone'),
if (app == 'pip') { await platform.invokeMethod('getSupportUrl'));
phone = '+38 080 030 9997\n+38 044 390 1697';
url = 'http://discount.kiev.ua/';
} else if (app == 'autobonus') {
phone = '8-800-234-6064';
url = 'https://www.auto-club.biz';
}
initHelp(phone, url);
} }
void initHelp(String phone, String url) { void initHelp(String phone, String url) {

View File

@@ -2,7 +2,6 @@ import 'package:checker/base/base_screen.dart';
import 'package:checker/base/settings_base_state.dart'; import 'package:checker/base/settings_base_state.dart';
import 'package:checker/db.dart'; import 'package:checker/db.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:checker/consts.dart';
import 'package:checker/strings.dart'; import 'package:checker/strings.dart';
import 'package:checker/common.dart'; import 'package:checker/common.dart';
import 'package:intl/intl.dart'; import 'package:intl/intl.dart';

View File

@@ -1,5 +1,3 @@
import 'dart:async';
import 'package:checker/base/base_screen.dart'; import 'package:checker/base/base_screen.dart';
import 'package:checker/base/base_state.dart'; import 'package:checker/base/base_state.dart';
import 'package:checker/common.dart'; import 'package:checker/common.dart';