New UI Implemented arabic check

mirza_dev
devmirza121 2 years ago
parent 0f185d4f8d
commit 3b6eb17adc

@ -103,7 +103,7 @@ class ServiceProviderBranch {
final int? id;
int? countryID;
final String? countryName;
String? countryName;
final int? cityId;
final dynamic? cityName;
final String? branchName;

@ -33,7 +33,6 @@ class _BranchDetailPageState extends State<BranchDetailPage> {
// TODO: implement initState
super.initState();
widget.branchData.serviceProviderServices!.forEach((element) {
categories.add(
new CategoryData(
id: element.categoryId,
@ -75,7 +74,7 @@ class _BranchDetailPageState extends State<BranchDetailPage> {
Row(
children: [
Expanded(
child: titleWidget(icons + "ic_branchs.svg", "Branch Info"),
child: titleWidget(icons + "ic_branchs.svg", LocaleKeys.branchInfo),
),
IconButton(
onPressed: () {
@ -90,11 +89,11 @@ class _BranchDetailPageState extends State<BranchDetailPage> {
8.height,
Column(
children: [
showData("Country:", widget.branchData.countryID.toString()),
showData("City", widget.branchData.cityId.toString()),
showData("Branch Name:", widget.branchData.branchName.toString()),
showData("Branch Description:", widget.branchData.branchDescription.toString()),
showData("Address:", widget.branchData.address.toString()),
showData(LocaleKeys.country.tr() + ":", widget.branchData.countryName.toString()),
showData(LocaleKeys.city.tr() + ":", widget.branchData.cityName.toString()),
showData(LocaleKeys.branchName.tr() + ":", widget.branchData.branchName.toString()),
showData(LocaleKeys.branchDescription.tr() + ":", widget.branchData.branchDescription.toString()),
showData(LocaleKeys.address.tr() + ":", widget.branchData.address.toString()),
],
),
Container(
@ -115,7 +114,11 @@ class _BranchDetailPageState extends State<BranchDetailPage> {
ListView.builder(
itemBuilder: (context, index) {
return Container(
child: ("- " + categories[pIndex].services![index].serviceName.toString()).toText14(),
child: ("- " +
(EasyLocalization.of(context)?.currentLocale?.countryCode == "SA"
? categories[pIndex].services![index].serviceNameN.toString()
: categories[pIndex].services![index].serviceName.toString()))
.toText14(),
);
},
itemCount: categories[pIndex].services?.length,
@ -142,7 +145,7 @@ class _BranchDetailPageState extends State<BranchDetailPage> {
Padding(
padding: const EdgeInsets.all(12.0),
child: ShowFillButton(
title: "Edit Services",
title: LocaleKeys.editServices,
maxWidth: double.infinity,
onPressed: () {
navigateWithName(

@ -85,7 +85,7 @@ class _BranchListPageState extends State<BranchListPage> {
Row(
children: [
Icon(
Icons.place,
Icons.place,
size: 12,
color: MyColors.darkPrimaryColor,
),
@ -143,7 +143,8 @@ class _BranchListPageState extends State<BranchListPage> {
).toContainer().onPress(() async {
// await navigateWithName(context, AppRoutes.defineBranch, arguments: snapshot.data!.data![index]);
// setState(() {});
snapshot.data!.data!.serviceProviderBranch![index].countryID=snapshot.data!.data!.countryID;
snapshot.data!.data!.serviceProviderBranch![index].countryID = snapshot.data!.data!.countryID;
snapshot.data!.data!.serviceProviderBranch![index].countryName = snapshot.data!.data!.countryName;
await navigateWithName(context, AppRoutes.branchDetail, arguments: snapshot.data!.data!.serviceProviderBranch![index]);
setState(() {});
});

@ -55,7 +55,7 @@ class _DefineBranchPageState extends State<DefineBranchPage> {
country = await UserApiClent().getAllCountries();
setState(() {
country!.data?.forEach((element) {
if (widget.branchData!.id != null) {
if (widget.branchData != null) if (widget.branchData!.id != null) {
if (element.id == widget.branchData!.countryID) {
countryValue = new DropValue(
element.id ?? 0, EasyLocalization.of(context)?.currentLocale?.countryCode == "SA" ? (element.countryNameN ?? "") : (element.countryName ?? ""), element.countryCode ?? "");
@ -64,7 +64,7 @@ class _DefineBranchPageState extends State<DefineBranchPage> {
countryDropList.add(
new DropValue(element.id ?? 0, EasyLocalization.of(context)?.currentLocale?.countryCode == "SA" ? (element.countryNameN ?? "") : (element.countryName ?? ""), element.countryCode ?? ""));
});
if (widget.branchData!.id != null) fetchCites();
if (widget.branchData != null) if (widget.branchData!.id != null) fetchCites();
});
}
@ -76,7 +76,7 @@ class _DefineBranchPageState extends State<DefineBranchPage> {
cities = await UserApiClent().getAllCites(countryId.toString());
setState(() {
cities!.data?.forEach((element) {
if (widget.branchData!.id != null) {
if (widget.branchData != null) if (widget.branchData!.id != null) {
if (element.id == widget.branchData!.cityId) {
address = widget.branchData!.address!;
branchName = widget.branchData!.branchName!;
@ -237,9 +237,9 @@ class _DefineBranchPageState extends State<DefineBranchPage> {
child: Padding(
padding: const EdgeInsets.only(left: 20, right: 20, bottom: 20),
child: ShowFillButton(
title: widget.branchData!.id == null ? LocaleKeys.createBranch.tr() : LocaleKeys.updateBranch.tr(),
title: widget.branchData != null ? (widget.branchData!.id == null ? LocaleKeys.createBranch.tr() : LocaleKeys.updateBranch.tr()) : LocaleKeys.createBranch.tr(),
onPressed: () async {
if (widget.branchData!.id == null) {
if (widget.branchData == null) {
Utils.showLoading(context);
MResponse res = await BranchApiClent().createBranch(branchName, branchDescription, cityId.toString(), address, latitude.toString(), longitude.toString());
Utils.hideLoading(context);

@ -130,7 +130,7 @@ class _DefineLicensePageState extends State<DefineLicensePage> {
),
Padding(
padding: const EdgeInsets.only(left: 20, right: 20, top: 4, bottom: 8),
child: "Please enter the detail for commercial records and attach the license images".toText14(color: MyColors.lightTextColor, textAlign: TextAlign.center),
child: LocaleKeys.enter_licence_detail.tr().toText14(color: MyColors.lightTextColor, textAlign: TextAlign.center),
),
TxtField(
hint: LocaleKeys.description.tr(),

@ -34,21 +34,21 @@
"change": "تغيير",
"verifyAccount": "التحقق من الحساب",
"login": "تسجيل دخول",
"log_in": "Log In",
"log_in": "تسجيل الدخول",
"welcomeMessage": "مرحبا",
"welcomeDes": "You one stop place all your car needs",
"welcomeDes": "أنت مكان واحد لكل ما تحتاجه سيارتك",
"forgetPass": "نسيت كلمة المرور ؟",
"enterPhoneNumber": "رقم جوال ",
"phoneNumberVerified": "تم التحقق من الجوال",
"verifyNewPassword": "التحقق من كلمة المرور",
"EnterPass": "ادخل كلمة المرور",
"send": "Send",
"retrivePassword": "Retrive password by one of following method",
"retriveOnPhone": "We will send the opt to your registered mobile number",
"retriveOnEmail": "We will send the opt to your registered email address",
"enterPhoneForVerfication": "Please enter your phone number We will send you the verification code",
"selectYourCountry": "Select Your Country",
"welcomeBack": "Welcome Back!!!",
"send": "إرسال",
"retrivePassword": "استرجع كلمة المرور بإحدى الطرق التالية",
"retriveOnPhone": "سوف نرسل الاختيار إلى رقم هاتفك المحمول المسجل",
"retriveOnEmail": "سوف نرسل الاختيار إلى عنوان بريدك الإلكتروني المسجل",
"enterPhoneForVerfication": "الرجاء إدخال رقم هاتفك وسنرسل لك رمز التحقق",
"selectYourCountry": "اختر بلدك",
"welcomeBack": "مرحبًا بعودتك!!!",
"alreadySigned": " تم تسجيل الدخول",
"emailChangedSuccessfully": "تم تغيير الايميل بنجاح",
"passwordIsUpdated": "تم تحجيث كلمة المرور",
@ -164,10 +164,14 @@
"remove": "إزالة",
"no_branch": "لم يتم إضافة فرع حتى الآن",
"login_once": "الرجاء تسجيل الدخول مرة واحدة",
"defineLicenese": "Upload Licenses and Certificates",
"description": "Description",
"attachFile": "Attach File",
"branchLocation": "Branch info and Location",
"tapToEdit": "Tap to edit",
"myServiceBranches": "My Service Branches"
"defineLicenese": "تحميل التراخيص والشهادات",
"description": "وصف",
"attachFile": "أرفق ملف",
"branchLocation": "معلومات الفرع والموقع",
"tapToEdit": "انقر للتعديل",
"myServiceBranches": "فروع خدمتي",
"enter_licence_detail": "الرجاء إدخال تفاصيل السجلات التجارية وإرفاق صور الترخيص",
"country": "بلد",
"city": "مدينة",
"editServices": "تحرير الخدمات"
}

@ -169,5 +169,9 @@
"attachFile": "Attach File",
"branchLocation": "Branch info and Location",
"tapToEdit": "Tap to edit",
"myServiceBranches": "My Service Branches"
"myServiceBranches": "My Service Branches",
"enter_licence_detail": "Please enter the detail for commercial records and attach the license images",
"country": "country",
"city": "city",
"editServices": "Edit Services"
}

Loading…
Cancel
Save