diff --git a/lib/l10n/app_en.arb b/lib/l10n/app_en.arb index fff6704..7127c90 100644 --- a/lib/l10n/app_en.arb +++ b/lib/l10n/app_en.arb @@ -405,5 +405,246 @@ "qrCodeData": "qr_code_data", "@qrCodeData": { "description": "QR data field label" }, "barCodeData": "Bar Code Data", - "@barCodeData": { "description": "Barcode data field label" } + "@barCodeData": { "description": "Barcode data field label" }, + "sysParamTitle": "System Parameter", + "@sysParamTitle": { "description": "System parameter title" }, + "tooltipFor": "Tooltip for {label}", + "@tooltipFor": { + "description": "Generic field tooltip", + "placeholders": { "label": { "type": "String" } } + }, + "schedulerTimer": "Scheduler Timer", + "@schedulerTimer": { "description": "Scheduler timer field" }, + "leaseTaxCode": "Lease Tax Code", + "@leaseTaxCode": { "description": "Lease tax code field" }, + "vesselConfProcessLimit": "Vessel Confirmation Process Limit", + "@vesselConfProcessLimit": { "description": "Vessel limit field" }, + "rowToDisplay": "Row To Display", + "@rowToDisplay": { "description": "Row to display field" }, + "linkToDisplay": "Link To Display", + "@linkToDisplay": { "description": "Link to display field" }, + "rowToAdd": "Row To Add", + "@rowToAdd": { "description": "Row to add field" }, + "lovRowToDisplay": "LOV Row To Display", + "@lovRowToDisplay": { "description": "LOV row field" }, + "lovLinkToDisplay": "LOV Link To Display", + "@lovLinkToDisplay": { "description": "LOV link field" }, + "oidServerName": "OID Server Name", + "@oidServerName": { "description": "OID server name field" }, + "oidBase": "OID Base", + "@oidBase": { "description": "OID base field" }, + "oidAdminUser": "OID Admin User", + "@oidAdminUser": { "description": "OID admin field" }, + "oidServerPort": "OID Server Port", + "@oidServerPort": { "description": "OID port field" }, + "userDefaultGroup": "User Default Group", + "@userDefaultGroup": { "description": "Default group field" }, + "defaultDepartment": "Default Department", + "@defaultDepartment": { "description": "Default department field" }, + "defaultPosition": "Default Position", + "@defaultPosition": { "description": "Default position field" }, + "singleCharge": "Single Charge", + "@singleCharge": { "description": "Single charge field" }, + "firstDayOfWeek": "First Day of The Week", + "@firstDayOfWeek": { "description": "First day field" }, + "hourPerShift": "Hour per Shift", + "@hourPerShift": { "description": "Hour per shift field" }, + "cnBillingFrequency": "CN Billing Frequency", + "@cnBillingFrequency": { "description": "Billing frequency field" }, + "billingDepartmentCode": "Billing Department Code", + "@billingDepartmentCode": { "description": "Billing dept field" }, + "basePriceList": "Base Price List", + "@basePriceList": { "description": "Price list field" }, + "nonContainerServiceOrder": "Non-Container Service Order Auto-Approval Department Code", + "@nonContainerServiceOrder": { "description": "NCSO field" }, + "ediMaeScheduler": "EDI MAE Scheduler ON/OFF", + "@ediMaeScheduler": { "description": "EDI MAE field" }, + "ediScheduler": "EDI Scheduler ON/OFF", + "@ediScheduler": { "description": "EDI scheduler field" }, + "regAllowed": "Is Registration Allowed?", + "@regAllowed": { "description": "Registration allowed label" }, + "yes": "Yes", + "@yes": { "description": "Yes option" }, + "no": "No", + "@no": { "description": "No option" }, + "pickCompanyLogo": "Pick a Company Logo", + "@pickCompanyLogo": { "description": "Pick logo button" }, + "logoUploadSuccess": "Company Logo uploaded Successful", + "@logoUploadSuccess": { "description": "Logo uploaded label" }, + "mscTooltip": "Allow customer code for MSC taulia CSV generation", + "@mscTooltip": { "description": "MSC tooltip" }, + "miscInfoLabel": "i", + "@miscInfoLabel": { "description": "Info field label" }, + "saveBtn": "Save", + "@saveBtn": { "description": "Save button" }, + "failedCreateProject": "Failed to create project: {error}", + "@failedCreateProject": { + "description": "Create project failure", + "placeholders": { "error": { "type": "String" } } + }, + "failedUpdateProject": "Failed to update project: {error}", + "@failedUpdateProject": { + "description": "Update project failure", + "placeholders": { "error": { "type": "String" } } + }, + "setupScreen": "Setup Screen", + "@setupScreen": { "description": "Setup title" }, + "userMaintenance": "User Maintenance", + "@userMaintenance": { "description": "User maintenance menu" }, + "userGroupMaintenance": "User Group Maintenance", + "@userGroupMaintenance": { "description": "User group menu" }, + "menuMaintenance": "Menu Maintenance", + "@menuMaintenance": { "description": "Menu maintenance menu" }, + "menuAccess": "Menu Access", + "@menuAccess": { "description": "Menu access menu" }, + "accessType": "Access Type", + "@accessType": { "description": "Access type menu" }, + "dashboardMenu": "Dashboard", + "@dashboardMenu": { "description": "Dashboard menu" }, + "createDynamicForm": "Create Dynamic Form", + "@createDynamicForm": { "description": "Create form title" }, + "formName": "Form Name", + "@formName": { "description": "Form name label" }, + "enterFormName": "Enter Form Name", + "@enterFormName": { "description": "Form name hint" }, + "formDescription": "Form Description", + "@formDescription": { "description": "Form description label" }, + "enterFormDescription": "Enter Form Description", + "@enterFormDescription": { "description": "Form description hint" }, + "selectRelatedTo": "Select Related To", + "@selectRelatedTo": { "description": "Related to label" }, + "selectPageEvent": "Select Page Event", + "@selectPageEvent": { "description": "Page event label" }, + "buttonCaption": "Button Caption", + "@buttonCaption": { "description": "Button caption label" }, + "enterButtonCaption": "Enter Button Caption", + "@enterButtonCaption": { "description": "Button caption hint" }, + "componentsDetails": "Components Details", + "@componentsDetails": { "description": "Components header" }, + "colLabel": "Label", + "@colLabel": { "description": "Label column" }, + "colType": "Type", + "@colType": { "description": "Type column" }, + "colMapping": "Mapping", + "@colMapping": { "description": "Mapping column" }, + "colMandatory": "Mandatory", + "@colMandatory": { "description": "Mandatory column" }, + "colReadonly": "Readonly", + "@colReadonly": { "description": "Readonly column" }, + "colDropValues": "Drop Values", + "@colDropValues": { "description": "Drop values column" }, + "colSP": "SP", + "@colSP": { "description": "SP column" }, + "colActions": "Actions", + "@colActions": { "description": "Actions column" }, + "selectType": "Select Type", + "@selectType": { "description": "Type dropdown label" }, + "selectMapping": "Select Mapping", + "@selectMapping": { "description": "Mapping dropdown label" }, + "selectReadOnly": "Select Read Only", + "@selectReadOnly": { "description": "Readonly dropdown label" }, + "addRow": "Add Row", + "@addRow": { "description": "Add row button" }, + "dynamicForm": "Dynamic Form", + "@dynamicForm": { "description": "Dynamic form title" }, + "noServices": "No Services available.", + "@noServices": { "description": "Empty forms message" }, + "relatedTo": "Related To", + "@relatedTo": { "description": "Related to column" }, + "pageEvent": "Page Event", + "@pageEvent": { "description": "Page event column" }, + "buildCol": "Build", + "@buildCol": { "description": "Build column" }, + "buildBtn": "build", + "@buildBtn": { "description": "Build button" }, + "deleteModuleConfirm": "Are you sure you want to delete this Module?", + "@deleteModuleConfirm": { "description": "Delete module confirm" }, + "editForm": "Edit Form", + "@editForm": { "description": "Edit form title" }, + "deleteEntityFailed": "Failed to delete entity: {error}", + "@deleteEntityFailed": { + "description": "Delete entity failure", + "placeholders": { "error": { "type": "String" } } + }, + "createBookmarks": "Create Bookmarks", + "@createBookmarks": { "description": "Create bookmarks title" }, + "failedCreateEntity": "Failed to create entity: {error}", + "@failedCreateEntity": { + "description": "Create entity failure", + "placeholders": { "error": { "type": "String" } } + }, + "updateBookmarks": "Update Bookmarks", + "@updateBookmarks": { "description": "Update bookmarks title" }, + "failedUpdateEntity": "Failed to update entity: {error}", + "@failedUpdateEntity": { + "description": "Update entity failure", + "placeholders": { "error": { "type": "String" } } + }, + "bookmarksTitle": "Bookmarks", + "@bookmarksTitle": { "description": "Bookmarks title" }, + "noBookmarks": "No BookMarks found.", + "@noBookmarks": { "description": "Empty bookmarks message" }, + "noDatabases": "No Databases available", + "@noDatabases": { "description": "No databases message" }, + "failedFetchEntities": "Failed to fetch entities: {error}", + "@failedFetchEntities": { + "description": "Fetch failure", + "placeholders": { "error": { "type": "String" } } + }, + "failedLaunchUrl": "Failed to launch URL: {error}", + "@failedLaunchUrl": { + "description": "URL launch failure", + "placeholders": { "error": { "type": "String" } } + }, + "raisedTickets": "Raised Tickets", + "@raisedTickets": { "description": "Raised tickets title" }, + "ticketIdRow": "Ticket ID: {id}", + "@ticketIdRow": { + "description": "Ticket ID row", + "placeholders": { "id": { "type": "String" } } + }, + "ticketNameRow": "Ticket Name: {name}", + "@ticketNameRow": { + "description": "Ticket name row", + "placeholders": { "name": { "type": "String" } } + }, + "raiseTicket": "Raise a Ticket", + "@raiseTicket": { "description": "Raise ticket title" }, + "ticketTitle": "Title", + "@ticketTitle": { "description": "Ticket title label" }, + "enterTicketTitle": "Enter Title", + "@enterTicketTitle": { "description": "Ticket title hint" }, + "ticketDescription": "Description", + "@ticketDescription": { "description": "Ticket description label" }, + "enterTicketDescription": "Enter Description", + "@enterTicketDescription": { "description": "Ticket description hint" }, + "projectName": "Project Name", + "@projectName": { "description": "Project name label" }, + "enterProjectName": "Enter Project Name", + "@enterProjectName": { "description": "Project name hint" }, + "pickScreenshot": "Pick Screenshot of issue", + "@pickScreenshot": { "description": "Screenshot picker label" }, + "reportEditor": "Report Editor", + "@reportEditor": { "description": "Report editor title" }, + "dragDropFields": "Drag and Drop Fields:", + "@dragDropFields": { "description": "Palette header" }, + "dragTitle": "Title", + "@dragTitle": { "description": "Title palette item" }, + "dragPhone": "Phone Number", + "@dragPhone": { "description": "Phone palette item" }, + "dragDate": "Date", + "@dragDate": { "description": "Date palette item" }, + "scaleBarTitle": "Scale Bar Report Editor", + "@scaleBarTitle": { "description": "Scale bar label" }, + "keyLabel": "Key", + "@keyLabel": { "description": "Key field label" }, + "valueLabel": "Value", + "@valueLabel": { "description": "Value field label" }, + "dropHere": "Drop Here", + "@dropHere": { "description": "Drop target label" }, + "pdfSaved": "PDF saved to {path}", + "@pdfSaved": { + "description": "PDF saved message", + "placeholders": { "path": { "type": "String" } } + } } diff --git a/lib/l10n/app_hi.arb b/lib/l10n/app_hi.arb index 15580f4..5443946 100644 --- a/lib/l10n/app_hi.arb +++ b/lib/l10n/app_hi.arb @@ -169,5 +169,109 @@ "qrCodeScanner": "क्यूआर कोड स्कैनर", "barCodeScanner": "बार कोड स्कैनर", "qrCodeData": "क्यूआर कोड डेटा", - "barCodeData": "बार कोड डेटा" + "barCodeData": "बार कोड डेटा", + "sysParamTitle": "सिस्टम पैरामीटर", + "tooltipFor": "{label} के लिए टूलटिप", + "schedulerTimer": "समय सारणी टाइमर", + "leaseTaxCode": "लीज़ कर कोड", + "vesselConfProcessLimit": "जहाज पुष्टि प्रक्रिया सीमा", + "rowToDisplay": "दिखाने के लिए पंक्तियां", + "linkToDisplay": "दिखाने के लिए लिंक", + "rowToAdd": "जोड़ने के लिए पंक्तियां", + "lovRowToDisplay": "दिखाने के लिए LOV पंक्तियां", + "lovLinkToDisplay": "दिखाने के लिए LOV लिंक", + "oidServerName": "OID सर्वर नाम", + "oidBase": "OID बेस", + "oidAdminUser": "OID व्यवस्थापक उपयोगकर्ता", + "oidServerPort": "OID सर्वर पोर्ट", + "userDefaultGroup": "उपयोगकर्ता डिफ़ॉल्ट समूह", + "defaultDepartment": "डिफ़ॉल्ट विभाग", + "defaultPosition": "डिफ़ॉल्ट पद", + "singleCharge": "एकल शुल्क", + "firstDayOfWeek": "सप्ताह का पहला दिन", + "hourPerShift": "प्रति पाली घंटा", + "cnBillingFrequency": "CN बिलिंग आवृत्ति", + "billingDepartmentCode": "बिलिंग विभाग कोड", + "basePriceList": "बेस मूल्य सूची", + "nonContainerServiceOrder": "गैर-कंटेनर सेवा आदेश स्वतः अनुमोदन विभाग कोड", + "ediMaeScheduler": "EDI MAE शेड्यूलर चालू/बंद", + "ediScheduler": "EDI शेड्यूलर चालू/बंद", + "regAllowed": "क्या पंजीकरण की अनुमति है?", + "yes": "हां", + "no": "नहीं", + "pickCompanyLogo": "कंपनी लोगो चुनें", + "logoUploadSuccess": "कंपनी लोगो सफलतापूर्वक अपलोड हुआ", + "mscTooltip": "MSC तौलिया CSV जनरेशन के लिए ग्राहक कोड की अनुमति दें", + "miscInfoLabel": "i", + "saveBtn": "सहेजें", + "failedCreateProject": "प्रोजेक्ट बनाने में विफल: {error}", + "failedUpdateProject": "प्रोजेक्ट अपडेट करने में विफल: {error}", + "setupScreen": "सेटअप स्क्रीन", + "userMaintenance": "उपयोगकर्ता रखरखाव", + "userGroupMaintenance": "उपयोगकर्ता समूह रखरखाव", + "menuMaintenance": "मेनू रखरखाव", + "menuAccess": "मेनू एक्सेस", + "accessType": "एक्सेस प्रकार", + "dashboardMenu": "डैशबोर्ड", + "createDynamicForm": "डायनामिक फॉर्म बनाएं", + "formName": "फॉर्म नाम", + "enterFormName": "फॉर्म नाम दर्ज करें", + "formDescription": "फॉर्म विवरण", + "enterFormDescription": "फॉर्म विवरण दर्ज करें", + "selectRelatedTo": "संबंधित चुनें", + "selectPageEvent": "पेज इवेंट चुनें", + "buttonCaption": "बटन कैप्शन", + "enterButtonCaption": "बटन कैप्शन दर्ज करें", + "componentsDetails": "कंपोनेंट विवरण", + "colLabel": "लेबल", + "colType": "प्रकार", + "colMapping": "मैपिंग", + "colMandatory": "अनिवार्य", + "colReadonly": "केवल-पठन", + "colDropValues": "ड्रॉप मान", + "colSP": "SP", + "colActions": "क्रियाएं", + "selectType": "प्रकार चुनें", + "selectMapping": "मैपिंग चुनें", + "selectReadOnly": "केवल-पठन चुनें", + "addRow": "पंक्ति जोड़ें", + "dynamicForm": "डायनामिक फॉर्म", + "noServices": "कोई सेवा उपलब्ध नहीं।", + "relatedTo": "संबंधित", + "pageEvent": "पेज इवेंट", + "buildCol": "बिल्ड", + "buildBtn": "बिल्ड करें", + "deleteModuleConfirm": "क्या आप वाकई यह मॉड्यूल हटाना चाहते हैं?", + "editForm": "फॉर्म संपादित करें", + "deleteEntityFailed": "एंटिटी हटाने में विफल: {error}", + "createBookmarks": "बुकमार्क बनाएं", + "failedCreateEntity": "एंटिटी बनाने में विफल: {error}", + "updateBookmarks": "बुकमार्क अपडेट करें", + "failedUpdateEntity": "एंटिटी अपडेट करने में विफल: {error}", + "bookmarksTitle": "बुकमार्क", + "noBookmarks": "कोई बुकमार्क नहीं मिला।", + "noDatabases": "कोई डेटाबेस उपलब्ध नहीं", + "failedFetchEntities": "एंटिटी लाने में विफल: {error}", + "failedLaunchUrl": "URL खोलने में विफल: {error}", + "raisedTickets": "उठाए गए टिकट", + "ticketIdRow": "टिकट आईडी: {id}", + "ticketNameRow": "टिकट नाम: {name}", + "raiseTicket": "टिकट उठाएं", + "ticketTitle": "शीर्षक", + "enterTicketTitle": "शीर्षक दर्ज करें", + "ticketDescription": "विवरण", + "enterTicketDescription": "विवरण दर्ज करें", + "projectName": "प्रोजेक्ट नाम", + "enterProjectName": "प्रोजेक्ट नाम दर्ज करें", + "pickScreenshot": "समस्या का स्क्रीनशॉट चुनें", + "reportEditor": "रिपोर्ट संपादक", + "dragDropFields": "फ़ील्ड खींचें और छोड़ें:", + "dragTitle": "शीर्षक", + "dragPhone": "फ़ोन नंबर", + "dragDate": "तिथि", + "scaleBarTitle": "स्केल बार रिपोर्ट संपादक", + "keyLabel": "कुंजी", + "valueLabel": "मान", + "dropHere": "यहां छोड़ें", + "pdfSaved": "PDF यहां सहेजा गया {path}" } diff --git a/lib/l10n/app_localizations.dart b/lib/l10n/app_localizations.dart index d79d20c..12b1ba6 100644 --- a/lib/l10n/app_localizations.dart +++ b/lib/l10n/app_localizations.dart @@ -1111,6 +1111,630 @@ abstract class AppLocalizations { /// In en, this message translates to: /// **'Bar Code Data'** String get barCodeData; + + /// System parameter title + /// + /// In en, this message translates to: + /// **'System Parameter'** + String get sysParamTitle; + + /// Generic field tooltip + /// + /// In en, this message translates to: + /// **'Tooltip for {label}'** + String tooltipFor(String label); + + /// Scheduler timer field + /// + /// In en, this message translates to: + /// **'Scheduler Timer'** + String get schedulerTimer; + + /// Lease tax code field + /// + /// In en, this message translates to: + /// **'Lease Tax Code'** + String get leaseTaxCode; + + /// Vessel limit field + /// + /// In en, this message translates to: + /// **'Vessel Confirmation Process Limit'** + String get vesselConfProcessLimit; + + /// Row to display field + /// + /// In en, this message translates to: + /// **'Row To Display'** + String get rowToDisplay; + + /// Link to display field + /// + /// In en, this message translates to: + /// **'Link To Display'** + String get linkToDisplay; + + /// Row to add field + /// + /// In en, this message translates to: + /// **'Row To Add'** + String get rowToAdd; + + /// LOV row field + /// + /// In en, this message translates to: + /// **'LOV Row To Display'** + String get lovRowToDisplay; + + /// LOV link field + /// + /// In en, this message translates to: + /// **'LOV Link To Display'** + String get lovLinkToDisplay; + + /// OID server name field + /// + /// In en, this message translates to: + /// **'OID Server Name'** + String get oidServerName; + + /// OID base field + /// + /// In en, this message translates to: + /// **'OID Base'** + String get oidBase; + + /// OID admin field + /// + /// In en, this message translates to: + /// **'OID Admin User'** + String get oidAdminUser; + + /// OID port field + /// + /// In en, this message translates to: + /// **'OID Server Port'** + String get oidServerPort; + + /// Default group field + /// + /// In en, this message translates to: + /// **'User Default Group'** + String get userDefaultGroup; + + /// Default department field + /// + /// In en, this message translates to: + /// **'Default Department'** + String get defaultDepartment; + + /// Default position field + /// + /// In en, this message translates to: + /// **'Default Position'** + String get defaultPosition; + + /// Single charge field + /// + /// In en, this message translates to: + /// **'Single Charge'** + String get singleCharge; + + /// First day field + /// + /// In en, this message translates to: + /// **'First Day of The Week'** + String get firstDayOfWeek; + + /// Hour per shift field + /// + /// In en, this message translates to: + /// **'Hour per Shift'** + String get hourPerShift; + + /// Billing frequency field + /// + /// In en, this message translates to: + /// **'CN Billing Frequency'** + String get cnBillingFrequency; + + /// Billing dept field + /// + /// In en, this message translates to: + /// **'Billing Department Code'** + String get billingDepartmentCode; + + /// Price list field + /// + /// In en, this message translates to: + /// **'Base Price List'** + String get basePriceList; + + /// NCSO field + /// + /// In en, this message translates to: + /// **'Non-Container Service Order Auto-Approval Department Code'** + String get nonContainerServiceOrder; + + /// EDI MAE field + /// + /// In en, this message translates to: + /// **'EDI MAE Scheduler ON/OFF'** + String get ediMaeScheduler; + + /// EDI scheduler field + /// + /// In en, this message translates to: + /// **'EDI Scheduler ON/OFF'** + String get ediScheduler; + + /// Registration allowed label + /// + /// In en, this message translates to: + /// **'Is Registration Allowed?'** + String get regAllowed; + + /// Yes option + /// + /// In en, this message translates to: + /// **'Yes'** + String get yes; + + /// No option + /// + /// In en, this message translates to: + /// **'No'** + String get no; + + /// Pick logo button + /// + /// In en, this message translates to: + /// **'Pick a Company Logo'** + String get pickCompanyLogo; + + /// Logo uploaded label + /// + /// In en, this message translates to: + /// **'Company Logo uploaded Successful'** + String get logoUploadSuccess; + + /// MSC tooltip + /// + /// In en, this message translates to: + /// **'Allow customer code for MSC taulia CSV generation'** + String get mscTooltip; + + /// Info field label + /// + /// In en, this message translates to: + /// **'i'** + String get miscInfoLabel; + + /// Save button + /// + /// In en, this message translates to: + /// **'Save'** + String get saveBtn; + + /// Create project failure + /// + /// In en, this message translates to: + /// **'Failed to create project: {error}'** + String failedCreateProject(String error); + + /// Update project failure + /// + /// In en, this message translates to: + /// **'Failed to update project: {error}'** + String failedUpdateProject(String error); + + /// Setup title + /// + /// In en, this message translates to: + /// **'Setup Screen'** + String get setupScreen; + + /// User maintenance menu + /// + /// In en, this message translates to: + /// **'User Maintenance'** + String get userMaintenance; + + /// User group menu + /// + /// In en, this message translates to: + /// **'User Group Maintenance'** + String get userGroupMaintenance; + + /// Menu maintenance menu + /// + /// In en, this message translates to: + /// **'Menu Maintenance'** + String get menuMaintenance; + + /// Menu access menu + /// + /// In en, this message translates to: + /// **'Menu Access'** + String get menuAccess; + + /// Access type menu + /// + /// In en, this message translates to: + /// **'Access Type'** + String get accessType; + + /// Dashboard menu + /// + /// In en, this message translates to: + /// **'Dashboard'** + String get dashboardMenu; + + /// Create form title + /// + /// In en, this message translates to: + /// **'Create Dynamic Form'** + String get createDynamicForm; + + /// Form name label + /// + /// In en, this message translates to: + /// **'Form Name'** + String get formName; + + /// Form name hint + /// + /// In en, this message translates to: + /// **'Enter Form Name'** + String get enterFormName; + + /// Form description label + /// + /// In en, this message translates to: + /// **'Form Description'** + String get formDescription; + + /// Form description hint + /// + /// In en, this message translates to: + /// **'Enter Form Description'** + String get enterFormDescription; + + /// Related to label + /// + /// In en, this message translates to: + /// **'Select Related To'** + String get selectRelatedTo; + + /// Page event label + /// + /// In en, this message translates to: + /// **'Select Page Event'** + String get selectPageEvent; + + /// Button caption label + /// + /// In en, this message translates to: + /// **'Button Caption'** + String get buttonCaption; + + /// Button caption hint + /// + /// In en, this message translates to: + /// **'Enter Button Caption'** + String get enterButtonCaption; + + /// Components header + /// + /// In en, this message translates to: + /// **'Components Details'** + String get componentsDetails; + + /// Label column + /// + /// In en, this message translates to: + /// **'Label'** + String get colLabel; + + /// Type column + /// + /// In en, this message translates to: + /// **'Type'** + String get colType; + + /// Mapping column + /// + /// In en, this message translates to: + /// **'Mapping'** + String get colMapping; + + /// Mandatory column + /// + /// In en, this message translates to: + /// **'Mandatory'** + String get colMandatory; + + /// Readonly column + /// + /// In en, this message translates to: + /// **'Readonly'** + String get colReadonly; + + /// Drop values column + /// + /// In en, this message translates to: + /// **'Drop Values'** + String get colDropValues; + + /// SP column + /// + /// In en, this message translates to: + /// **'SP'** + String get colSP; + + /// Actions column + /// + /// In en, this message translates to: + /// **'Actions'** + String get colActions; + + /// Type dropdown label + /// + /// In en, this message translates to: + /// **'Select Type'** + String get selectType; + + /// Mapping dropdown label + /// + /// In en, this message translates to: + /// **'Select Mapping'** + String get selectMapping; + + /// Readonly dropdown label + /// + /// In en, this message translates to: + /// **'Select Read Only'** + String get selectReadOnly; + + /// Add row button + /// + /// In en, this message translates to: + /// **'Add Row'** + String get addRow; + + /// Dynamic form title + /// + /// In en, this message translates to: + /// **'Dynamic Form'** + String get dynamicForm; + + /// Empty forms message + /// + /// In en, this message translates to: + /// **'No Services available.'** + String get noServices; + + /// Related to column + /// + /// In en, this message translates to: + /// **'Related To'** + String get relatedTo; + + /// Page event column + /// + /// In en, this message translates to: + /// **'Page Event'** + String get pageEvent; + + /// Build column + /// + /// In en, this message translates to: + /// **'Build'** + String get buildCol; + + /// Build button + /// + /// In en, this message translates to: + /// **'build'** + String get buildBtn; + + /// Delete module confirm + /// + /// In en, this message translates to: + /// **'Are you sure you want to delete this Module?'** + String get deleteModuleConfirm; + + /// Edit form title + /// + /// In en, this message translates to: + /// **'Edit Form'** + String get editForm; + + /// Delete entity failure + /// + /// In en, this message translates to: + /// **'Failed to delete entity: {error}'** + String deleteEntityFailed(String error); + + /// Create bookmarks title + /// + /// In en, this message translates to: + /// **'Create Bookmarks'** + String get createBookmarks; + + /// Create entity failure + /// + /// In en, this message translates to: + /// **'Failed to create entity: {error}'** + String failedCreateEntity(String error); + + /// Update bookmarks title + /// + /// In en, this message translates to: + /// **'Update Bookmarks'** + String get updateBookmarks; + + /// Update entity failure + /// + /// In en, this message translates to: + /// **'Failed to update entity: {error}'** + String failedUpdateEntity(String error); + + /// Bookmarks title + /// + /// In en, this message translates to: + /// **'Bookmarks'** + String get bookmarksTitle; + + /// Empty bookmarks message + /// + /// In en, this message translates to: + /// **'No BookMarks found.'** + String get noBookmarks; + + /// No databases message + /// + /// In en, this message translates to: + /// **'No Databases available'** + String get noDatabases; + + /// Fetch failure + /// + /// In en, this message translates to: + /// **'Failed to fetch entities: {error}'** + String failedFetchEntities(String error); + + /// URL launch failure + /// + /// In en, this message translates to: + /// **'Failed to launch URL: {error}'** + String failedLaunchUrl(String error); + + /// Raised tickets title + /// + /// In en, this message translates to: + /// **'Raised Tickets'** + String get raisedTickets; + + /// Ticket ID row + /// + /// In en, this message translates to: + /// **'Ticket ID: {id}'** + String ticketIdRow(String id); + + /// Ticket name row + /// + /// In en, this message translates to: + /// **'Ticket Name: {name}'** + String ticketNameRow(String name); + + /// Raise ticket title + /// + /// In en, this message translates to: + /// **'Raise a Ticket'** + String get raiseTicket; + + /// Ticket title label + /// + /// In en, this message translates to: + /// **'Title'** + String get ticketTitle; + + /// Ticket title hint + /// + /// In en, this message translates to: + /// **'Enter Title'** + String get enterTicketTitle; + + /// Ticket description label + /// + /// In en, this message translates to: + /// **'Description'** + String get ticketDescription; + + /// Ticket description hint + /// + /// In en, this message translates to: + /// **'Enter Description'** + String get enterTicketDescription; + + /// Project name label + /// + /// In en, this message translates to: + /// **'Project Name'** + String get projectName; + + /// Project name hint + /// + /// In en, this message translates to: + /// **'Enter Project Name'** + String get enterProjectName; + + /// Screenshot picker label + /// + /// In en, this message translates to: + /// **'Pick Screenshot of issue'** + String get pickScreenshot; + + /// Report editor title + /// + /// In en, this message translates to: + /// **'Report Editor'** + String get reportEditor; + + /// Palette header + /// + /// In en, this message translates to: + /// **'Drag and Drop Fields:'** + String get dragDropFields; + + /// Title palette item + /// + /// In en, this message translates to: + /// **'Title'** + String get dragTitle; + + /// Phone palette item + /// + /// In en, this message translates to: + /// **'Phone Number'** + String get dragPhone; + + /// Date palette item + /// + /// In en, this message translates to: + /// **'Date'** + String get dragDate; + + /// Scale bar label + /// + /// In en, this message translates to: + /// **'Scale Bar Report Editor'** + String get scaleBarTitle; + + /// Key field label + /// + /// In en, this message translates to: + /// **'Key'** + String get keyLabel; + + /// Value field label + /// + /// In en, this message translates to: + /// **'Value'** + String get valueLabel; + + /// Drop target label + /// + /// In en, this message translates to: + /// **'Drop Here'** + String get dropHere; + + /// PDF saved message + /// + /// In en, this message translates to: + /// **'PDF saved to {path}'** + String pdfSaved(String path); } class _AppLocalizationsDelegate diff --git a/lib/l10n/app_localizations_en.dart b/lib/l10n/app_localizations_en.dart index d569ab1..5906f5b 100644 --- a/lib/l10n/app_localizations_en.dart +++ b/lib/l10n/app_localizations_en.dart @@ -565,4 +565,340 @@ class AppLocalizationsEn extends AppLocalizations { @override String get barCodeData => 'Bar Code Data'; + + @override + String get sysParamTitle => 'System Parameter'; + + @override + String tooltipFor(String label) { + return 'Tooltip for $label'; + } + + @override + String get schedulerTimer => 'Scheduler Timer'; + + @override + String get leaseTaxCode => 'Lease Tax Code'; + + @override + String get vesselConfProcessLimit => 'Vessel Confirmation Process Limit'; + + @override + String get rowToDisplay => 'Row To Display'; + + @override + String get linkToDisplay => 'Link To Display'; + + @override + String get rowToAdd => 'Row To Add'; + + @override + String get lovRowToDisplay => 'LOV Row To Display'; + + @override + String get lovLinkToDisplay => 'LOV Link To Display'; + + @override + String get oidServerName => 'OID Server Name'; + + @override + String get oidBase => 'OID Base'; + + @override + String get oidAdminUser => 'OID Admin User'; + + @override + String get oidServerPort => 'OID Server Port'; + + @override + String get userDefaultGroup => 'User Default Group'; + + @override + String get defaultDepartment => 'Default Department'; + + @override + String get defaultPosition => 'Default Position'; + + @override + String get singleCharge => 'Single Charge'; + + @override + String get firstDayOfWeek => 'First Day of The Week'; + + @override + String get hourPerShift => 'Hour per Shift'; + + @override + String get cnBillingFrequency => 'CN Billing Frequency'; + + @override + String get billingDepartmentCode => 'Billing Department Code'; + + @override + String get basePriceList => 'Base Price List'; + + @override + String get nonContainerServiceOrder => + 'Non-Container Service Order Auto-Approval Department Code'; + + @override + String get ediMaeScheduler => 'EDI MAE Scheduler ON/OFF'; + + @override + String get ediScheduler => 'EDI Scheduler ON/OFF'; + + @override + String get regAllowed => 'Is Registration Allowed?'; + + @override + String get yes => 'Yes'; + + @override + String get no => 'No'; + + @override + String get pickCompanyLogo => 'Pick a Company Logo'; + + @override + String get logoUploadSuccess => 'Company Logo uploaded Successful'; + + @override + String get mscTooltip => 'Allow customer code for MSC taulia CSV generation'; + + @override + String get miscInfoLabel => 'i'; + + @override + String get saveBtn => 'Save'; + + @override + String failedCreateProject(String error) { + return 'Failed to create project: $error'; + } + + @override + String failedUpdateProject(String error) { + return 'Failed to update project: $error'; + } + + @override + String get setupScreen => 'Setup Screen'; + + @override + String get userMaintenance => 'User Maintenance'; + + @override + String get userGroupMaintenance => 'User Group Maintenance'; + + @override + String get menuMaintenance => 'Menu Maintenance'; + + @override + String get menuAccess => 'Menu Access'; + + @override + String get accessType => 'Access Type'; + + @override + String get dashboardMenu => 'Dashboard'; + + @override + String get createDynamicForm => 'Create Dynamic Form'; + + @override + String get formName => 'Form Name'; + + @override + String get enterFormName => 'Enter Form Name'; + + @override + String get formDescription => 'Form Description'; + + @override + String get enterFormDescription => 'Enter Form Description'; + + @override + String get selectRelatedTo => 'Select Related To'; + + @override + String get selectPageEvent => 'Select Page Event'; + + @override + String get buttonCaption => 'Button Caption'; + + @override + String get enterButtonCaption => 'Enter Button Caption'; + + @override + String get componentsDetails => 'Components Details'; + + @override + String get colLabel => 'Label'; + + @override + String get colType => 'Type'; + + @override + String get colMapping => 'Mapping'; + + @override + String get colMandatory => 'Mandatory'; + + @override + String get colReadonly => 'Readonly'; + + @override + String get colDropValues => 'Drop Values'; + + @override + String get colSP => 'SP'; + + @override + String get colActions => 'Actions'; + + @override + String get selectType => 'Select Type'; + + @override + String get selectMapping => 'Select Mapping'; + + @override + String get selectReadOnly => 'Select Read Only'; + + @override + String get addRow => 'Add Row'; + + @override + String get dynamicForm => 'Dynamic Form'; + + @override + String get noServices => 'No Services available.'; + + @override + String get relatedTo => 'Related To'; + + @override + String get pageEvent => 'Page Event'; + + @override + String get buildCol => 'Build'; + + @override + String get buildBtn => 'build'; + + @override + String get deleteModuleConfirm => + 'Are you sure you want to delete this Module?'; + + @override + String get editForm => 'Edit Form'; + + @override + String deleteEntityFailed(String error) { + return 'Failed to delete entity: $error'; + } + + @override + String get createBookmarks => 'Create Bookmarks'; + + @override + String failedCreateEntity(String error) { + return 'Failed to create entity: $error'; + } + + @override + String get updateBookmarks => 'Update Bookmarks'; + + @override + String failedUpdateEntity(String error) { + return 'Failed to update entity: $error'; + } + + @override + String get bookmarksTitle => 'Bookmarks'; + + @override + String get noBookmarks => 'No BookMarks found.'; + + @override + String get noDatabases => 'No Databases available'; + + @override + String failedFetchEntities(String error) { + return 'Failed to fetch entities: $error'; + } + + @override + String failedLaunchUrl(String error) { + return 'Failed to launch URL: $error'; + } + + @override + String get raisedTickets => 'Raised Tickets'; + + @override + String ticketIdRow(String id) { + return 'Ticket ID: $id'; + } + + @override + String ticketNameRow(String name) { + return 'Ticket Name: $name'; + } + + @override + String get raiseTicket => 'Raise a Ticket'; + + @override + String get ticketTitle => 'Title'; + + @override + String get enterTicketTitle => 'Enter Title'; + + @override + String get ticketDescription => 'Description'; + + @override + String get enterTicketDescription => 'Enter Description'; + + @override + String get projectName => 'Project Name'; + + @override + String get enterProjectName => 'Enter Project Name'; + + @override + String get pickScreenshot => 'Pick Screenshot of issue'; + + @override + String get reportEditor => 'Report Editor'; + + @override + String get dragDropFields => 'Drag and Drop Fields:'; + + @override + String get dragTitle => 'Title'; + + @override + String get dragPhone => 'Phone Number'; + + @override + String get dragDate => 'Date'; + + @override + String get scaleBarTitle => 'Scale Bar Report Editor'; + + @override + String get keyLabel => 'Key'; + + @override + String get valueLabel => 'Value'; + + @override + String get dropHere => 'Drop Here'; + + @override + String pdfSaved(String path) { + return 'PDF saved to $path'; + } } diff --git a/lib/l10n/app_localizations_hi.dart b/lib/l10n/app_localizations_hi.dart index 62779fd..7cf5bd6 100644 --- a/lib/l10n/app_localizations_hi.dart +++ b/lib/l10n/app_localizations_hi.dart @@ -565,4 +565,340 @@ class AppLocalizationsHi extends AppLocalizations { @override String get barCodeData => 'बार कोड डेटा'; + + @override + String get sysParamTitle => 'सिस्टम पैरामीटर'; + + @override + String tooltipFor(String label) { + return '$label के लिए टूलटिप'; + } + + @override + String get schedulerTimer => 'समय सारणी टाइमर'; + + @override + String get leaseTaxCode => 'लीज़ कर कोड'; + + @override + String get vesselConfProcessLimit => 'जहाज पुष्टि प्रक्रिया सीमा'; + + @override + String get rowToDisplay => 'दिखाने के लिए पंक्तियां'; + + @override + String get linkToDisplay => 'दिखाने के लिए लिंक'; + + @override + String get rowToAdd => 'जोड़ने के लिए पंक्तियां'; + + @override + String get lovRowToDisplay => 'दिखाने के लिए LOV पंक्तियां'; + + @override + String get lovLinkToDisplay => 'दिखाने के लिए LOV लिंक'; + + @override + String get oidServerName => 'OID सर्वर नाम'; + + @override + String get oidBase => 'OID बेस'; + + @override + String get oidAdminUser => 'OID व्यवस्थापक उपयोगकर्ता'; + + @override + String get oidServerPort => 'OID सर्वर पोर्ट'; + + @override + String get userDefaultGroup => 'उपयोगकर्ता डिफ़ॉल्ट समूह'; + + @override + String get defaultDepartment => 'डिफ़ॉल्ट विभाग'; + + @override + String get defaultPosition => 'डिफ़ॉल्ट पद'; + + @override + String get singleCharge => 'एकल शुल्क'; + + @override + String get firstDayOfWeek => 'सप्ताह का पहला दिन'; + + @override + String get hourPerShift => 'प्रति पाली घंटा'; + + @override + String get cnBillingFrequency => 'CN बिलिंग आवृत्ति'; + + @override + String get billingDepartmentCode => 'बिलिंग विभाग कोड'; + + @override + String get basePriceList => 'बेस मूल्य सूची'; + + @override + String get nonContainerServiceOrder => + 'गैर-कंटेनर सेवा आदेश स्वतः अनुमोदन विभाग कोड'; + + @override + String get ediMaeScheduler => 'EDI MAE शेड्यूलर चालू/बंद'; + + @override + String get ediScheduler => 'EDI शेड्यूलर चालू/बंद'; + + @override + String get regAllowed => 'क्या पंजीकरण की अनुमति है?'; + + @override + String get yes => 'हां'; + + @override + String get no => 'नहीं'; + + @override + String get pickCompanyLogo => 'कंपनी लोगो चुनें'; + + @override + String get logoUploadSuccess => 'कंपनी लोगो सफलतापूर्वक अपलोड हुआ'; + + @override + String get mscTooltip => + 'MSC तौलिया CSV जनरेशन के लिए ग्राहक कोड की अनुमति दें'; + + @override + String get miscInfoLabel => 'i'; + + @override + String get saveBtn => 'सहेजें'; + + @override + String failedCreateProject(String error) { + return 'प्रोजेक्ट बनाने में विफल: $error'; + } + + @override + String failedUpdateProject(String error) { + return 'प्रोजेक्ट अपडेट करने में विफल: $error'; + } + + @override + String get setupScreen => 'सेटअप स्क्रीन'; + + @override + String get userMaintenance => 'उपयोगकर्ता रखरखाव'; + + @override + String get userGroupMaintenance => 'उपयोगकर्ता समूह रखरखाव'; + + @override + String get menuMaintenance => 'मेनू रखरखाव'; + + @override + String get menuAccess => 'मेनू एक्सेस'; + + @override + String get accessType => 'एक्सेस प्रकार'; + + @override + String get dashboardMenu => 'डैशबोर्ड'; + + @override + String get createDynamicForm => 'डायनामिक फॉर्म बनाएं'; + + @override + String get formName => 'फॉर्म नाम'; + + @override + String get enterFormName => 'फॉर्म नाम दर्ज करें'; + + @override + String get formDescription => 'फॉर्म विवरण'; + + @override + String get enterFormDescription => 'फॉर्म विवरण दर्ज करें'; + + @override + String get selectRelatedTo => 'संबंधित चुनें'; + + @override + String get selectPageEvent => 'पेज इवेंट चुनें'; + + @override + String get buttonCaption => 'बटन कैप्शन'; + + @override + String get enterButtonCaption => 'बटन कैप्शन दर्ज करें'; + + @override + String get componentsDetails => 'कंपोनेंट विवरण'; + + @override + String get colLabel => 'लेबल'; + + @override + String get colType => 'प्रकार'; + + @override + String get colMapping => 'मैपिंग'; + + @override + String get colMandatory => 'अनिवार्य'; + + @override + String get colReadonly => 'केवल-पठन'; + + @override + String get colDropValues => 'ड्रॉप मान'; + + @override + String get colSP => 'SP'; + + @override + String get colActions => 'क्रियाएं'; + + @override + String get selectType => 'प्रकार चुनें'; + + @override + String get selectMapping => 'मैपिंग चुनें'; + + @override + String get selectReadOnly => 'केवल-पठन चुनें'; + + @override + String get addRow => 'पंक्ति जोड़ें'; + + @override + String get dynamicForm => 'डायनामिक फॉर्म'; + + @override + String get noServices => 'कोई सेवा उपलब्ध नहीं।'; + + @override + String get relatedTo => 'संबंधित'; + + @override + String get pageEvent => 'पेज इवेंट'; + + @override + String get buildCol => 'बिल्ड'; + + @override + String get buildBtn => 'बिल्ड करें'; + + @override + String get deleteModuleConfirm => 'क्या आप वाकई यह मॉड्यूल हटाना चाहते हैं?'; + + @override + String get editForm => 'फॉर्म संपादित करें'; + + @override + String deleteEntityFailed(String error) { + return 'एंटिटी हटाने में विफल: $error'; + } + + @override + String get createBookmarks => 'बुकमार्क बनाएं'; + + @override + String failedCreateEntity(String error) { + return 'एंटिटी बनाने में विफल: $error'; + } + + @override + String get updateBookmarks => 'बुकमार्क अपडेट करें'; + + @override + String failedUpdateEntity(String error) { + return 'एंटिटी अपडेट करने में विफल: $error'; + } + + @override + String get bookmarksTitle => 'बुकमार्क'; + + @override + String get noBookmarks => 'कोई बुकमार्क नहीं मिला।'; + + @override + String get noDatabases => 'कोई डेटाबेस उपलब्ध नहीं'; + + @override + String failedFetchEntities(String error) { + return 'एंटिटी लाने में विफल: $error'; + } + + @override + String failedLaunchUrl(String error) { + return 'URL खोलने में विफल: $error'; + } + + @override + String get raisedTickets => 'उठाए गए टिकट'; + + @override + String ticketIdRow(String id) { + return 'टिकट आईडी: $id'; + } + + @override + String ticketNameRow(String name) { + return 'टिकट नाम: $name'; + } + + @override + String get raiseTicket => 'टिकट उठाएं'; + + @override + String get ticketTitle => 'शीर्षक'; + + @override + String get enterTicketTitle => 'शीर्षक दर्ज करें'; + + @override + String get ticketDescription => 'विवरण'; + + @override + String get enterTicketDescription => 'विवरण दर्ज करें'; + + @override + String get projectName => 'प्रोजेक्ट नाम'; + + @override + String get enterProjectName => 'प्रोजेक्ट नाम दर्ज करें'; + + @override + String get pickScreenshot => 'समस्या का स्क्रीनशॉट चुनें'; + + @override + String get reportEditor => 'रिपोर्ट संपादक'; + + @override + String get dragDropFields => 'फ़ील्ड खींचें और छोड़ें:'; + + @override + String get dragTitle => 'शीर्षक'; + + @override + String get dragPhone => 'फ़ोन नंबर'; + + @override + String get dragDate => 'तिथि'; + + @override + String get scaleBarTitle => 'स्केल बार रिपोर्ट संपादक'; + + @override + String get keyLabel => 'कुंजी'; + + @override + String get valueLabel => 'मान'; + + @override + String get dropHere => 'यहां छोड़ें'; + + @override + String pdfSaved(String path) { + return 'PDF यहां सहेजा गया $path'; + } } diff --git a/lib/screens/Bookmarks/Bookmarks_create_entity_screen.dart b/lib/screens/Bookmarks/Bookmarks_create_entity_screen.dart index fc0e735..0c44d91 100644 --- a/lib/screens/Bookmarks/Bookmarks_create_entity_screen.dart +++ b/lib/screens/Bookmarks/Bookmarks_create_entity_screen.dart @@ -1,6 +1,7 @@ import 'package:flutter/material.dart'; import 'package:flutter/services.dart'; +import '../../l10n/app_localizations.dart'; import '../../providers/token_manager.dart'; import 'Bookmarks_api_service.dart'; @@ -24,7 +25,8 @@ class _CreateEntityScreenState extends State { @override Widget build(BuildContext context) { return Scaffold( - appBar: AppBar(title: const Text('Create Bookmarks')), + appBar: AppBar( + title: Text(AppLocalizations.of(context)!.createBookmarks)), body: SingleChildScrollView( child: Padding( padding: const EdgeInsets.all(16), @@ -70,11 +72,14 @@ class _CreateEntityScreenState extends State { context: context, builder: (BuildContext context) { return AlertDialog( - title: const Text('Error'), - content: Text('Failed to create entity: $e'), + title: Text(AppLocalizations.of(context)! + .error), + content: Text(AppLocalizations.of(context)! + .failedCreateEntity(e.toString())), actions: [ TextButton( - child: const Text('OK'), + child: Text(AppLocalizations.of(context)! + .ok), onPressed: () { Navigator.of(context).pop(); }, diff --git a/lib/screens/Bookmarks/Bookmarks_entity_list_screen.dart b/lib/screens/Bookmarks/Bookmarks_entity_list_screen.dart index 16595c3..836ab79 100644 --- a/lib/screens/Bookmarks/Bookmarks_entity_list_screen.dart +++ b/lib/screens/Bookmarks/Bookmarks_entity_list_screen.dart @@ -2,6 +2,7 @@ import 'package:flutter/material.dart'; import 'package:intl/intl.dart'; import '../../Utils/image_constant.dart'; import '../../Utils/size_utils.dart'; +import '../../l10n/app_localizations.dart'; import '../../providers/token_manager.dart'; import '../../theme/app_decoration.dart'; import '../../theme/app_style.dart'; @@ -46,11 +47,12 @@ class _bookmarks_entity_list_screenState context: context, builder: (BuildContext context) { return AlertDialog( - title: const Text('Error'), - content: Text('Failed to fetch entities: $e'), + title: Text(AppLocalizations.of(context)!.error), + content: Text(AppLocalizations.of(context)! + .failedFetchEntities(e.toString())), actions: [ TextButton( - child: const Text('OK'), + child: Text(AppLocalizations.of(context)!.ok), onPressed: () { Navigator.of(context).pop(); }, @@ -74,11 +76,12 @@ class _bookmarks_entity_list_screenState context: context, builder: (BuildContext context) { return AlertDialog( - title: const Text('Error'), - content: Text('Failed to delete entity: $e'), + title: Text(AppLocalizations.of(context)!.error), + content: Text(AppLocalizations.of(context)! + .deleteEntityFailed(e.toString())), actions: [ TextButton( - child: const Text('OK'), + child: Text(AppLocalizations.of(context)!.ok), onPressed: () { Navigator.of(context).pop(); }, @@ -105,10 +108,12 @@ class _bookmarks_entity_list_screenState Navigator.pop(context); }), centerTitle: true, - title: AppbarTitle(text: "Bookmarks")), + title: AppbarTitle( + text: AppLocalizations.of(context)!.bookmarksTitle)), body: entities.isEmpty - ? const Center( - child: Text('No BookMarks found.'), + ? Center( + child: Text( + AppLocalizations.of(context)!.noBookmarks), ) : Container( width: double.maxFinite, @@ -315,8 +320,9 @@ class _bookmarks_entity_list_screenState }) : Container( height: MediaQuery.of(context).size.height, - child: const Center( - child: Text("No Databases available"), + child: Center( + child: Text(AppLocalizations.of(context)! + .noDatabases), )), ) ])) @@ -422,11 +428,12 @@ class _bookmarks_entity_list_screenState context: context, builder: (BuildContext context) { return AlertDialog( - title: const Text('Error'), - content: Text('Failed to launch URL: $e'), + title: Text(AppLocalizations.of(context)!.error), + content: Text(AppLocalizations.of(context)! + .failedLaunchUrl(e.toString())), actions: [ TextButton( - child: const Text('OK'), + child: Text(AppLocalizations.of(context)!.ok), onPressed: () { Navigator.of(context).pop(); }, @@ -519,7 +526,8 @@ class _bookmarks_entity_list_screenState context: context, builder: (BuildContext context) { return AlertDialog( - title: const Text('Additional Fields'), + title: Text( + AppLocalizations.of(context)!.additionalFields), content: Column( crossAxisAlignment: CrossAxisAlignment.start, mainAxisSize: MainAxisSize.min, @@ -535,7 +543,7 @@ class _bookmarks_entity_list_screenState ), actions: [ TextButton( - child: const Text('Close'), + child: Text(AppLocalizations.of(context)!.close), onPressed: () { Navigator.of(context).pop(); }, diff --git a/lib/screens/Bookmarks/Bookmarks_update_entity_screen.dart b/lib/screens/Bookmarks/Bookmarks_update_entity_screen.dart index ccd835a..a776ebd 100644 --- a/lib/screens/Bookmarks/Bookmarks_update_entity_screen.dart +++ b/lib/screens/Bookmarks/Bookmarks_update_entity_screen.dart @@ -3,6 +3,7 @@ import 'dart:math'; import 'package:flutter/services.dart'; +import '../../l10n/app_localizations.dart'; import '../../providers/token_manager.dart'; import 'Bookmarks_api_service.dart'; @@ -27,7 +28,8 @@ class _UpdateEntityScreenState extends State { @override Widget build(BuildContext context) { return Scaffold( - appBar: AppBar(title: const Text('Update Bookmarks')), + appBar: AppBar( + title: Text(AppLocalizations.of(context)!.updateBookmarks)), body: SingleChildScrollView( child: Padding( padding: const EdgeInsets.all(16), @@ -41,7 +43,8 @@ class _UpdateEntityScreenState extends State { const InputDecoration(labelText: 'bookmark_firstletter'), validator: (value) { if (value == null || value.isEmpty) { - return 'Please enter a bookmark_firstletter'; + return AppLocalizations.of(context)!.pleaseEnterThis( + 'bookmark_firstletter'); } return null; }, @@ -55,7 +58,8 @@ class _UpdateEntityScreenState extends State { decoration: const InputDecoration(labelText: 'bookmark_link'), validator: (value) { if (value == null || value.isEmpty) { - return 'Please enter a bookmark_link'; + return AppLocalizations.of(context)!.pleaseEnterThis( + 'bookmark_link'); } return null; }, @@ -70,7 +74,8 @@ class _UpdateEntityScreenState extends State { const InputDecoration(labelText: 'fileupload_field'), validator: (value) { if (value == null || value.isEmpty) { - return 'Please enter a fileupload_field'; + return AppLocalizations.of(context)!.pleaseEnterThis( + 'fileupload_field'); } return null; }, @@ -99,11 +104,14 @@ class _UpdateEntityScreenState extends State { context: context, builder: (BuildContext context) { return AlertDialog( - title: const Text('Error'), - content: Text('Failed to update entity: $e'), + title: Text(AppLocalizations.of(context)! + .error), + content: Text(AppLocalizations.of(context)! + .failedUpdateEntity(e.toString())), actions: [ TextButton( - child: const Text('OK'), + child: Text(AppLocalizations.of(context)! + .ok), onPressed: () { Navigator.of(context).pop(); }, diff --git a/lib/screens/Incident_Ticket/ticket_create.dart b/lib/screens/Incident_Ticket/ticket_create.dart index 6838fff..f38a589 100644 --- a/lib/screens/Incident_Ticket/ticket_create.dart +++ b/lib/screens/Incident_Ticket/ticket_create.dart @@ -7,6 +7,7 @@ import 'dart:convert'; import '../../Utils/image_constant.dart'; import '../../Utils/size_utils.dart'; +import '../../l10n/app_localizations.dart'; import '../../providers/token_manager.dart'; import '../../resources/api_constants.dart'; import '../../theme/app_style.dart'; @@ -95,17 +96,21 @@ class _RaisedTicketScreenState extends State { ) ], centerTitle: true, - title: AppbarTitle(text: "Raised Tickets")), + title: AppbarTitle( + text: AppLocalizations.of(context)!.raisedTickets)), body: ListView.builder( itemCount: tickets.length, itemBuilder: (context, index) { final ticket = tickets[index]; return ListTile( title: Text( - 'Ticket ID: ${ticket['ticketid']}', + AppLocalizations.of(context)! + .ticketIdRow(ticket['ticketid'].toString()), style: const TextStyle(fontSize: 12), ), - subtitle: Text('Ticket Name: ${ticket['ticketname']}', + subtitle: Text( + AppLocalizations.of(context)! + .ticketNameRow(ticket['ticketname'].toString()), style: const TextStyle(fontSize: 10)), // Add more fields as needed ); @@ -210,7 +215,9 @@ class _TicketFormScreenState extends State { Navigator.pop(context); }), centerTitle: true, - title: AppbarTitle(text: "Raise a Ticket")), + title: AppbarTitle( + text: + AppLocalizations.of(context)!.raiseTicket)), body: Padding( padding: const EdgeInsets.all(16.0), child: Column( @@ -221,13 +228,14 @@ class _TicketFormScreenState extends State { crossAxisAlignment: CrossAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.start, children: [ - Text("Title", + Text(AppLocalizations.of(context)!.ticketTitle, overflow: TextOverflow.ellipsis, textAlign: TextAlign.left, style: AppStyle.txtGilroyMedium16Bluegray900), CustomTextFormField( focusNode: FocusNode(), - hintText: "Enter Title", + hintText: AppLocalizations.of(context)! + .enterTicketTitle, controller: titleController, margin: getMargin(top: 6)) ])), @@ -237,13 +245,16 @@ class _TicketFormScreenState extends State { crossAxisAlignment: CrossAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.start, children: [ - Text("Description", + Text( + AppLocalizations.of(context)! + .ticketDescription, overflow: TextOverflow.ellipsis, textAlign: TextAlign.left, style: AppStyle.txtGilroyMedium16Bluegray900), CustomTextFormField( focusNode: FocusNode(), - hintText: "Enter Description", + hintText: AppLocalizations.of(context)! + .enterTicketDescription, controller: descriptionController, margin: getMargin(top: 6)) ])), @@ -253,19 +264,20 @@ class _TicketFormScreenState extends State { crossAxisAlignment: CrossAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.start, children: [ - Text("Project Name", + Text(AppLocalizations.of(context)!.projectName, overflow: TextOverflow.ellipsis, textAlign: TextAlign.left, style: AppStyle.txtGilroyMedium16Bluegray900), CustomTextFormField( focusNode: FocusNode(), - hintText: "Enter Project Name", + hintText: AppLocalizations.of(context)! + .enterProjectName, controller: projectNameController, margin: getMargin(top: 6)) ])), // Adjusted the spacing Row( children: [ - Text('Pick Screenshot of issue'), + Text(AppLocalizations.of(context)!.pickScreenshot), IconButton( onPressed: () { _pickImage(); // Call the function to pick an image @@ -279,7 +291,7 @@ class _TicketFormScreenState extends State { ), CustomButton( height: getVerticalSize(50), - text: "Submit", + text: AppLocalizations.of(context)!.submit, margin: getMargin(top: 24, bottom: 5), onTap: () async { submitTicket(screenshot); diff --git a/lib/screens/LayoutReportBuilder/LayoutReportBuilder.dart b/lib/screens/LayoutReportBuilder/LayoutReportBuilder.dart index eee5fb8..09b222b 100644 --- a/lib/screens/LayoutReportBuilder/LayoutReportBuilder.dart +++ b/lib/screens/LayoutReportBuilder/LayoutReportBuilder.dart @@ -1,6 +1,8 @@ import 'package:flutter/material.dart'; import 'dart:convert'; +import '../../l10n/app_localizations.dart'; + // class ReportEditor extends StatefulWidget { // @override // _ReportEditorState createState() => _ReportEditorState(); @@ -687,7 +689,8 @@ class _ReportEditorState extends State { await pdfFile.writeAsBytes(pdfBytes); ScaffoldMessenger.of(context).showSnackBar( SnackBar( - content: Text('PDF saved to ${pdfFile.path}'), + content: Text(AppLocalizations.of(context)! + .pdfSaved(pdfFile.path)), ), ); } @@ -696,7 +699,8 @@ class _ReportEditorState extends State { Widget build(BuildContext context) { return Scaffold( key: _scaffoldKey, - appBar: AppBar(title: Text('Report Editor')), + appBar: AppBar( + title: Text(AppLocalizations.of(context)!.reportEditor)), body: Row( children: [ Container( @@ -705,21 +709,27 @@ class _ReportEditorState extends State { child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ - Text('Drag and Drop Fields:'), + Text(AppLocalizations.of(context)!.dragDropFields), Draggable( data: 'Title', - child: DragField(text: 'Title'), - feedback: DragField(text: 'Title'), + child: DragField( + text: AppLocalizations.of(context)!.dragTitle), + feedback: DragField( + text: AppLocalizations.of(context)!.dragTitle), ), Draggable( data: 'Phone Number', - child: DragField(text: 'Phone Number'), - feedback: DragField(text: 'Phone Number'), + child: DragField( + text: AppLocalizations.of(context)!.dragPhone), + feedback: DragField( + text: AppLocalizations.of(context)!.dragPhone), ), Draggable( data: 'Date', - child: DragField(text: 'Date'), - feedback: DragField(text: 'Date'), + child: DragField( + text: AppLocalizations.of(context)!.dragDate), + feedback: DragField( + text: AppLocalizations.of(context)!.dragDate), ), ], ), @@ -743,7 +753,8 @@ class _ReportEditorState extends State { ), Align( alignment: Alignment.bottomRight, - child: Text('Scale Bar Report Editor'), + child: Text(AppLocalizations.of(context)! + .scaleBarTitle), ), ...droppedFields.asMap().entries.map((entry) { final index = entry.key; @@ -924,14 +935,17 @@ class _EditableFieldState extends State { children: [ TextFormField( controller: keyController, - decoration: InputDecoration(labelText: 'Key'), + decoration: InputDecoration( + labelText: AppLocalizations.of(context)!.keyLabel), onChanged: (value) { widget.onEdit(value, valueController.text); }, ), TextFormField( controller: valueController, - decoration: InputDecoration(labelText: 'Value'), + decoration: InputDecoration( + labelText: + AppLocalizations.of(context)!.valueLabel), onChanged: (value) { widget.onEdit(keyController.text, value); }, @@ -955,7 +969,8 @@ class DraggableTarget extends StatelessWidget { child: DragTarget( builder: (context, candidateData, rejectedData) { return Center( - child: Text('Drop Here', style: TextStyle(fontSize: 24)), + child: Text(AppLocalizations.of(context)!.dropHere, + style: TextStyle(fontSize: 24)), ); }, onAccept: (String field) { diff --git a/lib/screens/Setup/setup.dart b/lib/screens/Setup/setup.dart index 70a8707..21c100a 100644 --- a/lib/screens/Setup/setup.dart +++ b/lib/screens/Setup/setup.dart @@ -1,6 +1,7 @@ import 'package:flutter/material.dart'; import '../../Utils/image_constant.dart'; import '../../Utils/size_utils.dart'; +import '../../l10n/app_localizations.dart'; import '../../widgets/app_bar/appbar_image.dart'; import '../../widgets/app_bar/appbar_title.dart'; import '../../widgets/app_bar/custom_app_bar.dart'; @@ -24,20 +25,42 @@ class SetupScreen extends StatelessWidget { Navigator.pop(context); }), centerTitle: true, - title: AppbarTitle(text: "Setup Screen")), + title: AppbarTitle( + text: AppLocalizations.of(context)!.setupScreen)), body: SingleChildScrollView( child: Center( child: Column( mainAxisAlignment: MainAxisAlignment.center, children: [ - buildSetupBlock(context, 'User Maintenance', SysParameter()), - buildSetupBlock(context, 'User Group Maintenance', SysParameter()), - buildSetupBlock(context, 'Menu Maintenance', SysParameter()), - buildSetupBlock(context, 'Menu Access', SysParameter()), - buildSetupBlock(context, 'System Parameter', SysParameter()), - buildSetupBlock(context, 'Access Type', SysParameter()), + buildSetupBlock( + context, + AppLocalizations.of(context)!.userMaintenance, + SysParameter()), + buildSetupBlock( + context, + AppLocalizations.of(context)!.userGroupMaintenance, + SysParameter()), + buildSetupBlock( + context, + AppLocalizations.of(context)!.menuMaintenance, + SysParameter()), + buildSetupBlock( + context, + AppLocalizations.of(context)!.menuAccess, + SysParameter()), + buildSetupBlock( + context, + AppLocalizations.of(context)!.sysParamTitle, + SysParameter()), + buildSetupBlock( + context, + AppLocalizations.of(context)!.accessType, + SysParameter()), // buildSetupBlock(context, 'Report', ReportPage()), - buildSetupBlock(context, 'Dashboard', SysParameter()), + buildSetupBlock( + context, + AppLocalizations.of(context)!.dashboardMenu, + SysParameter()), ], ), ), diff --git a/lib/screens/SysParameters/SystemParameterScreen.dart b/lib/screens/SysParameters/SystemParameterScreen.dart index c2a0e40..6080fe6 100644 --- a/lib/screens/SysParameters/SystemParameterScreen.dart +++ b/lib/screens/SysParameters/SystemParameterScreen.dart @@ -5,6 +5,7 @@ import 'package:image_picker/image_picker.dart'; import '../../Utils/image_constant.dart'; import '../../Utils/size_utils.dart'; +import '../../l10n/app_localizations.dart'; import '../../providers/token_manager.dart'; import '../../theme/app_style.dart'; import '../../widgets/app_bar/appbar_image.dart'; @@ -139,11 +140,12 @@ class _SysParameterState extends State { context: context, builder: (BuildContext context) { return AlertDialog( - title: const Text('Error'), - content: Text('Please select an image.'), + title: Text(AppLocalizations.of(context)!.error), + content: Text( + AppLocalizations.of(context)!.selectImage), actions: [ TextButton( - child: const Text('OK'), + child: Text(AppLocalizations.of(context)!.ok), onPressed: () { Navigator.of(context).pop(); }, @@ -171,11 +173,12 @@ class _SysParameterState extends State { context: context, builder: (BuildContext context) { return AlertDialog( - title: const Text('Error'), - content: Text('Failed to upload image: $e'), + title: Text(AppLocalizations.of(context)!.error), + content: Text(AppLocalizations.of(context)! + .failedUploadImage(e.toString())), actions: [ TextButton( - child: const Text('OK'), + child: Text(AppLocalizations.of(context)!.ok), onPressed: () { Navigator.of(context).pop(); }, @@ -201,8 +204,9 @@ class _SysParameterState extends State { onTap: () { Navigator.pop(context); }), - centerTitle: true, - title: AppbarTitle(text: "System Parameter")), + centerTitle: true, + title: AppbarTitle( + text: AppLocalizations.of(context)!.sysParamTitle)), body: Material(child:SingleChildScrollView( // Wrap the form in a SingleChildScrollView scrollDirection: Axis.vertical, // Allow vertical scrolling child:Padding( @@ -211,131 +215,159 @@ class _SysParameterState extends State { crossAxisAlignment: CrossAxisAlignment.start, children: [ _buildFieldWithTooltip( - fieldName: 'Scheduler Timer', + fieldName: AppLocalizations.of(context)!.schedulerTimer, controller: schedulerTimerController, - tooltip: 'Tooltip for Scheduler Timer', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.schedulerTimer), ), _buildFieldWithTooltip( - fieldName: 'Lease Tax Code', + fieldName: AppLocalizations.of(context)!.leaseTaxCode, controller: leaseTaxCodeController, - tooltip: 'Tooltip for Lease Tax Code', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.leaseTaxCode), ), _buildFieldWithTooltip( - fieldName: 'Vessel Confirmation Process Limit', + fieldName: + AppLocalizations.of(context)!.vesselConfProcessLimit, controller: vesselConfirmationController, - tooltip: 'Tooltip for Vessel Confirmation Process Limit', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.vesselConfProcessLimit), ), _buildFieldWithTooltip( - fieldName: 'Row To Display', + fieldName: AppLocalizations.of(context)!.rowToDisplay, controller: rowToDisplayController, - tooltip: 'Tooltip for Row To Display', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.rowToDisplay), ), _buildFieldWithTooltip( - fieldName: 'Link To Display', + fieldName: AppLocalizations.of(context)!.linkToDisplay, controller: linkToDisplayController, - tooltip: 'Tooltip for Link To Display', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.linkToDisplay), ), _buildFieldWithTooltip( - fieldName: 'Row To Add', + fieldName: AppLocalizations.of(context)!.rowToAdd, controller: rowToAddController, - tooltip: 'Tooltip for Row To Add', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.rowToAdd), ), _buildFieldWithTooltip( - fieldName: 'LOV Row To Display', + fieldName: AppLocalizations.of(context)!.lovRowToDisplay, controller: lovRowToDisplayController, - tooltip: 'Tooltip for LOV Row To Display', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.lovRowToDisplay), ), _buildFieldWithTooltip( - fieldName: 'LOV Link To Display', + fieldName: AppLocalizations.of(context)!.lovLinkToDisplay, controller: lovLinkToDisplayController, - tooltip: 'Tooltip for LOV Link To Display', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.lovLinkToDisplay), ), _buildFieldWithTooltip( - fieldName: 'OID Server Name', + fieldName: AppLocalizations.of(context)!.oidServerName, controller: oidServerNameController, - tooltip: 'Tooltip for OID Server Name', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.oidServerName), ), _buildFieldWithTooltip( - fieldName: 'OID Base', + fieldName: AppLocalizations.of(context)!.oidBase, controller: oidBaseController, - tooltip: 'Tooltip for OID Base', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.oidBase), ), _buildFieldWithTooltip( - fieldName: 'OID Admin User', + fieldName: AppLocalizations.of(context)!.oidAdminUser, controller: oidAdminUserController, - tooltip: 'Tooltip for OID Admin User', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.oidAdminUser), ), _buildFieldWithTooltip( - fieldName: 'OID Server Port', + fieldName: AppLocalizations.of(context)!.oidServerPort, controller: oidServerPortController, - tooltip: 'Tooltip for OID Server Port', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.oidServerPort), ), _buildFieldWithTooltip( - fieldName: 'User Default Group', + fieldName: AppLocalizations.of(context)!.userDefaultGroup, controller: userDefaultGroupController, - tooltip: 'Tooltip for User Default Group', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.userDefaultGroup), ), _buildFieldWithTooltip( - fieldName: 'Default Department', + fieldName: AppLocalizations.of(context)!.defaultDepartment, controller: defaultDepartmentController, - tooltip: 'Tooltip for Default Department', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.defaultDepartment), ), _buildFieldWithTooltip( - fieldName: 'Default Position', + fieldName: AppLocalizations.of(context)!.defaultPosition, controller: defaultPositionController, - tooltip: 'Tooltip for Default Position', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.defaultPosition), ), _buildFieldWithTooltip( - fieldName: 'Single Charge', + fieldName: AppLocalizations.of(context)!.singleCharge, controller: singleChargeController, - tooltip: 'Tooltip for Single Charge', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.singleCharge), ), _buildFieldWithTooltip( - fieldName: 'First Day of The Week', + fieldName: AppLocalizations.of(context)!.firstDayOfWeek, controller: firstDayOfWeekController, - tooltip: 'Tooltip for First Day of The Week', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.firstDayOfWeek), ), _buildFieldWithTooltip( - fieldName: 'Hour per Shift', + fieldName: AppLocalizations.of(context)!.hourPerShift, controller: hourPerShiftController, - tooltip: 'Tooltip for Hour per Shift', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.hourPerShift), ), _buildFieldWithTooltip( - fieldName: 'CN Billing Frequency', + fieldName: + AppLocalizations.of(context)!.cnBillingFrequency, controller: cnBillingFrequencyController, - tooltip: 'Tooltip for CN Billing Frequency', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.cnBillingFrequency), ), _buildFieldWithTooltip( - fieldName: 'Billing Department Code', + fieldName: + AppLocalizations.of(context)!.billingDepartmentCode, controller: billingDepartmentCodeController, - tooltip: 'Tooltip for Billing Department Code', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.billingDepartmentCode), ), _buildFieldWithTooltip( - fieldName: 'Base Price List', + fieldName: AppLocalizations.of(context)!.basePriceList, controller: basePriceListController, - tooltip: 'Tooltip for Base Price List', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.basePriceList), ), _buildFieldWithTooltip( - fieldName: 'Non-Container Service Order Auto-Approval Department Code', + fieldName: AppLocalizations.of(context)! + .nonContainerServiceOrder, controller: nonContainerServiceController, - tooltip: 'Tooltip for Non-Container Service Order Auto-Approval Department Code', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.nonContainerServiceOrder), ), _buildFieldWithTooltip( - fieldName: 'EDI MAE Scheduler ON/OFF', + fieldName: AppLocalizations.of(context)!.ediMaeScheduler, controller: ediMaeSchedulerController, - tooltip: 'Tooltip for EDI MAE Scheduler ON/OFF', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.ediMaeScheduler), ), _buildFieldWithTooltip( - fieldName: 'EDI Scheduler ON/OFF', + fieldName: AppLocalizations.of(context)!.ediScheduler, controller: ediSchedulerController, - tooltip: 'Tooltip for EDI Scheduler ON/OFF', + tooltip: AppLocalizations.of(context)!.tooltipFor( + AppLocalizations.of(context)!.ediScheduler), ), _buildFieldWithTooltip( - fieldName: 'Company Name', + fieldName: AppLocalizations.of(context)!.companyName, controller: companynameController, - tooltip: 'Company Name', + tooltip: AppLocalizations.of(context)!.companyName, ), - Text("Is Registration Allowed?", + Text(AppLocalizations.of(context)!.regAllowed, overflow: TextOverflow.ellipsis, textAlign: TextAlign.left, style: AppStyle @@ -351,7 +383,7 @@ class _SysParameterState extends State { }); }, ), - Text("Yes", + Text(AppLocalizations.of(context)!.yes, overflow: TextOverflow.ellipsis, textAlign: TextAlign.left, style: AppStyle @@ -365,7 +397,7 @@ class _SysParameterState extends State { }); }, ), - Text("No", + Text(AppLocalizations.of(context)!.no, overflow: TextOverflow.ellipsis, textAlign: TextAlign.left, style: AppStyle @@ -381,12 +413,13 @@ class _SysParameterState extends State { backgroundColor: _imageBytes==null?MaterialStateProperty.all(Colors.red):MaterialStateProperty.all(Colors.green), // Change to the desired color ), child: _imageBytes == null - ? Text("Pick a Company Logo", + ? Text(AppLocalizations.of(context)!.pickCompanyLogo, overflow: TextOverflow.ellipsis, textAlign: TextAlign.left, style: AppStyle .txtGilroyMedium16Bluegray800) - : Text("Company Logo uploaded Successful", + : Text( + AppLocalizations.of(context)!.logoUploadSuccess, overflow: TextOverflow.ellipsis, textAlign: TextAlign.left, style: AppStyle @@ -394,10 +427,10 @@ class _SysParameterState extends State { ), Tooltip( - message: 'Allow customer code for MSC taulia CSV generation', + message: AppLocalizations.of(context)!.mscTooltip, child: Column( children: [ - Text("i", + Text(AppLocalizations.of(context)!.miscInfoLabel, overflow: TextOverflow.ellipsis, textAlign: TextAlign.left, style: AppStyle @@ -420,7 +453,7 @@ class _SysParameterState extends State { CustomButton( height: getVerticalSize(50), - text: "Save", + text: AppLocalizations.of(context)!.saveBtn, margin: getMargin(top: 24, bottom: 5), onTap: () async { formData['regitrationAllowed'] = isRegistrationAllow; @@ -469,12 +502,17 @@ class _SysParameterState extends State { context: context, builder: (BuildContext context) { return AlertDialog( - title: const Text('Error'), - content: Text( - 'Failed to ${widget.sysparameter == null ? 'create' : 'update'} project: $e'), + title: Text( + AppLocalizations.of(context)!.error), + content: Text(widget.sysparameter == null + ? AppLocalizations.of(context)! + .failedCreateProject(e.toString()) + : AppLocalizations.of(context)! + .failedUpdateProject(e.toString())), actions: [ TextButton( - child: const Text('OK'), + child: Text( + AppLocalizations.of(context)!.ok), onPressed: () { Navigator.of(context).pop(); }, diff --git a/lib/screens/dynamic_form/UpdatedynamicForm.dart b/lib/screens/dynamic_form/UpdatedynamicForm.dart index 94f83ce..d8c9a21 100644 --- a/lib/screens/dynamic_form/UpdatedynamicForm.dart +++ b/lib/screens/dynamic_form/UpdatedynamicForm.dart @@ -1,5 +1,6 @@ import 'package:flutter/material.dart'; +import '../../l10n/app_localizations.dart'; import '../../providers/token_manager.dart'; import 'dynamic_form_service.dart'; @@ -49,7 +50,7 @@ class _EditFormState extends State { Widget build(BuildContext context) { return Scaffold( appBar: AppBar( - title: Text('Edit Form'), + title: Text(AppLocalizations.of(context)!.editForm), ), body: SingleChildScrollView( child: Padding( @@ -58,16 +59,21 @@ class _EditFormState extends State { children: [ TextFormField( controller: formNameController, - decoration: InputDecoration(labelText: 'Form Name'), + decoration: InputDecoration( + labelText: + AppLocalizations.of(context)!.formName), ), TextFormField( controller: formDescController, - decoration: InputDecoration(labelText: 'Form Description'), + decoration: InputDecoration( + labelText: AppLocalizations.of(context)! + .formDescription), ), DropdownButtonFormField( value: relatedToController.text, - decoration: - const InputDecoration(labelText: 'Select Related To'), + decoration: InputDecoration( + labelText: AppLocalizations.of(context)! + .selectRelatedTo), items: [ ...relatedToFixedDropdown.map>( (item) { @@ -86,8 +92,9 @@ class _EditFormState extends State { ), DropdownButtonFormField( value: pageEventController.text, - decoration: - const InputDecoration(labelText: 'Select Page Event'), + decoration: InputDecoration( + labelText: AppLocalizations.of(context)! + .selectPageEvent), items: [ ...pageEventFixedDropdown.map>( (item) { @@ -106,22 +113,41 @@ class _EditFormState extends State { ), TextFormField( controller: buttonCaptionController, - decoration: InputDecoration(labelText: 'Button Caption'), + decoration: InputDecoration( + labelText: AppLocalizations.of(context)! + .buttonCaption), ), - const Text('Components Details'), + Text(AppLocalizations.of(context)!.componentsDetails), SingleChildScrollView( scrollDirection: Axis.horizontal, child: DataTable( - columns: const [ - DataColumn(label: Text('Label')), - DataColumn(label: Text('Type')), - DataColumn(label: Text('Mapping')), - DataColumn(label: Text('Mandatory')), - DataColumn(label: Text('Readonly')), - DataColumn(label: Text('Drop Values')), - DataColumn(label: Text('SP')), - DataColumn(label: Text('Actions'), numeric: false), // Add Actions column + columns: [ + DataColumn( + label: Text( + AppLocalizations.of(context)!.colLabel)), + DataColumn( + label: Text( + AppLocalizations.of(context)!.colType)), + DataColumn( + label: Text( + AppLocalizations.of(context)!.colMapping)), + DataColumn( + label: Text( + AppLocalizations.of(context)!.colMandatory)), + DataColumn( + label: Text( + AppLocalizations.of(context)!.colReadonly)), + DataColumn( + label: Text( + AppLocalizations.of(context)!.colDropValues)), + DataColumn( + label: Text( + AppLocalizations.of(context)!.colSP)), + DataColumn( + label: Text(AppLocalizations.of(context)! + .colActions), + numeric: false), // Add Actions column ], rows: components.asMap().entries.map((entry) { final index = entry.key; @@ -228,7 +254,8 @@ class _EditFormState extends State { components.removeAt(index); }); }, - child: Text('Delete'), + child: Text( + AppLocalizations.of(context)!.delete), ), ), ], @@ -250,7 +277,7 @@ class _EditFormState extends State { }); setState(() {}); // Refresh the UI to show the new row }, - child: Text('Add Row'), + child: Text(AppLocalizations.of(context)!.addRow), ), ElevatedButton( @@ -266,7 +293,7 @@ class _EditFormState extends State { apiService.updateDynamicForm(token!, widget.formData['form_id'], widget.formData); Navigator.of(context).pop(); }, - child: Text('Update'), + child: Text(AppLocalizations.of(context)!.update), ), ], ), diff --git a/lib/screens/dynamic_form/create_dynamicform.dart b/lib/screens/dynamic_form/create_dynamicform.dart index 69952c5..4cfded4 100644 --- a/lib/screens/dynamic_form/create_dynamicform.dart +++ b/lib/screens/dynamic_form/create_dynamicform.dart @@ -2,6 +2,7 @@ import 'package:flutter/material.dart'; import '../../Utils/image_constant.dart'; import '../../Utils/size_utils.dart'; +import '../../l10n/app_localizations.dart'; import '../../providers/token_manager.dart'; import '../../theme/app_style.dart'; import '../../widgets/app_bar/appbar_image.dart'; @@ -51,7 +52,9 @@ class _CreateFormState extends State { Navigator.pop(context); }), centerTitle: true, - title: AppbarTitle(text: "Create Dynamic Form"),), + title: AppbarTitle( + text: AppLocalizations.of(context)! + .createDynamicForm),), body: SingleChildScrollView( child: Padding( padding: const EdgeInsets.all(16.0), @@ -63,14 +66,15 @@ class _CreateFormState extends State { crossAxisAlignment: CrossAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.start, children: [ - Text("Form Name", + Text(AppLocalizations.of(context)!.formName, overflow: TextOverflow.ellipsis, textAlign: TextAlign.left, style: AppStyle .txtGilroyMedium16Bluegray900), CustomTextFormField( focusNode: FocusNode(), - hintText: "Enter Form Name", + hintText: AppLocalizations.of(context)! + .enterFormName, controller: formNameController, margin: getMargin(top: 6)) ])), @@ -80,14 +84,17 @@ class _CreateFormState extends State { crossAxisAlignment: CrossAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.start, children: [ - Text("Form Description", + Text( + AppLocalizations.of(context)! + .formDescription, overflow: TextOverflow.ellipsis, textAlign: TextAlign.left, style: AppStyle .txtGilroyMedium16Bluegray900), CustomTextFormField( focusNode: FocusNode(), - hintText: "Enter Form Description", + hintText: AppLocalizations.of(context)! + .enterFormDescription, controller: formDescController, margin: getMargin(top: 6)) ])), @@ -99,7 +106,7 @@ class _CreateFormState extends State { mainAxisAlignment: MainAxisAlignment.start, children: [ Text( - "Select Related To", + AppLocalizations.of(context)!.selectRelatedTo, overflow: TextOverflow.ellipsis, textAlign: TextAlign.left, style: AppStyle.txtGilroyMedium16Bluegray900, @@ -132,7 +139,7 @@ class _CreateFormState extends State { mainAxisAlignment: MainAxisAlignment.start, children: [ Text( - "Select Page Event", + AppLocalizations.of(context)!.selectPageEvent, overflow: TextOverflow.ellipsis, textAlign: TextAlign.left, style: AppStyle.txtGilroyMedium16Bluegray900, @@ -163,29 +170,46 @@ class _CreateFormState extends State { crossAxisAlignment: CrossAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.start, children: [ - Text("Button Caption", + Text( + AppLocalizations.of(context)! + .buttonCaption, overflow: TextOverflow.ellipsis, textAlign: TextAlign.left, style: AppStyle .txtGilroyMedium16Bluegray900), CustomTextFormField( focusNode: FocusNode(), - hintText: "Enter Button Caption", + hintText: AppLocalizations.of(context)! + .enterButtonCaption, controller: buttonCaptionController, margin: getMargin(top: 6)) ])), - const Text('Components Details'), + Text(AppLocalizations.of(context)!.componentsDetails), SingleChildScrollView( scrollDirection: Axis.horizontal, child: DataTable( - columns: const [ - DataColumn(label: Text('Label')), - DataColumn(label: Text('Type')), - DataColumn(label: Text('Mapping')), - DataColumn(label: Text('Mandatory')), - DataColumn(label: Text('Readonly')), - DataColumn(label: Text('Drop Values')), - DataColumn(label: Text('SP')), + columns: [ + DataColumn( + label: Text( + AppLocalizations.of(context)!.colLabel)), + DataColumn( + label: Text( + AppLocalizations.of(context)!.colType)), + DataColumn( + label: Text( + AppLocalizations.of(context)!.colMapping)), + DataColumn( + label: Text( + AppLocalizations.of(context)!.colMandatory)), + DataColumn( + label: Text( + AppLocalizations.of(context)!.colReadonly)), + DataColumn( + label: Text( + AppLocalizations.of(context)!.colDropValues)), + DataColumn( + label: Text( + AppLocalizations.of(context)!.colSP)), ], rows: components.asMap().entries.map((entry) { final index = entry.key; @@ -201,8 +225,9 @@ class _CreateFormState extends State { )), DataCell( DropdownButtonFormField( - decoration: - const InputDecoration(labelText: 'Select Type'), + decoration: InputDecoration( + labelText: AppLocalizations.of(context)! + .selectType), items: [ ...typeFixedDropdown.map>( (item) { @@ -223,8 +248,9 @@ class _CreateFormState extends State { ), DataCell( DropdownButtonFormField( - decoration: - const InputDecoration(labelText: 'Select Mapping'), + decoration: InputDecoration( + labelText: AppLocalizations.of(context)! + .selectMapping), items: [ ...mappingFixedDropdown.map>( (item) { @@ -251,8 +277,9 @@ class _CreateFormState extends State { )), DataCell( DropdownButtonFormField( - decoration: - const InputDecoration(labelText: 'Select Read Only'), + decoration: InputDecoration( + labelText: AppLocalizations.of(context)! + .selectReadOnly), items: [ ...truefalseFixedDropdown.map>( (item) { @@ -290,7 +317,7 @@ class _CreateFormState extends State { ), CustomButton( height: getVerticalSize(50), - text: "Add Row", + text: AppLocalizations.of(context)!.addRow, margin: getMargin(top: 24, bottom: 5), onTap: () async { components.add({ @@ -308,7 +335,7 @@ class _CreateFormState extends State { CustomButton( height: getVerticalSize(50), - text: "Create Dynamic Form", + text: AppLocalizations.of(context)!.createDynamicForm, margin: getMargin(top: 24, bottom: 5), onTap: () async { final dynamicFormData = { diff --git a/lib/screens/dynamic_form/list_dynamic_form_screen.dart b/lib/screens/dynamic_form/list_dynamic_form_screen.dart index 8f196a0..72d1d04 100644 --- a/lib/screens/dynamic_form/list_dynamic_form_screen.dart +++ b/lib/screens/dynamic_form/list_dynamic_form_screen.dart @@ -3,6 +3,7 @@ import 'package:flutter/rendering.dart'; import '../../Utils/color_constants.dart'; import '../../Utils/image_constant.dart'; import '../../Utils/size_utils.dart'; +import '../../l10n/app_localizations.dart'; import '../../providers/token_manager.dart'; import '../../widgets/app_bar/appbar_image.dart'; import '../../widgets/app_bar/appbar_title.dart'; @@ -58,11 +59,12 @@ class _DynamicFormState extends State { context: context, builder: (BuildContext context) { return AlertDialog( - title: const Text('Error'), - content: Text('Failed to delete entity: $e'), + title: Text(AppLocalizations.of(context)!.error), + content: Text(AppLocalizations.of(context)! + .deleteEntityFailed(e.toString())), actions: [ TextButton( - child: const Text('OK'), + child: Text(AppLocalizations.of(context)!.ok), onPressed: () { Navigator.of(context).pop(); }, @@ -109,12 +111,15 @@ class _DynamicFormState extends State { ) ], centerTitle: true, - title: AppbarTitle(text: "Dynamic Form")), + title: AppbarTitle( + text: + AppLocalizations.of(context)!.dynamicForm)), body: isLoading == false ? const Center(child: CircularProgressIndicator()) : allData.isEmpty - ? const Center( - child: Text('No Services available.'), + ? Center( + child: Text(AppLocalizations.of(context)! + .noServices), ) : Scrollable( viewportBuilder: @@ -125,13 +130,27 @@ class _DynamicFormState extends State { scrollDirection: Axis.horizontal, child: DataTable( columns: [ - DataColumn(label: Text('Form Name')), - DataColumn(label: Text('Form Description')), - DataColumn(label: Text('Related To')), - DataColumn(label: Text('Page Event')), - DataColumn(label: Text('Button Caption')), - DataColumn(label: Text('Build')), - DataColumn(label: Text('Actions')), + DataColumn( + label: Text(AppLocalizations.of(context)! + .formName)), + DataColumn( + label: Text(AppLocalizations.of(context)! + .formDescription)), + DataColumn( + label: Text(AppLocalizations.of(context)! + .relatedTo)), + DataColumn( + label: Text(AppLocalizations.of(context)! + .pageEvent)), + DataColumn( + label: Text(AppLocalizations.of(context)! + .buttonCaption)), + DataColumn( + label: Text(AppLocalizations.of(context)! + .buildCol)), + DataColumn( + label: Text(AppLocalizations.of(context)! + .colActions)), ], rows: allData.map((module) { return DataRow( @@ -156,7 +175,9 @@ class _DynamicFormState extends State { apiService.BuildForms( token!, module['form_id']); }, - child: Text("build"), + child: Text( + AppLocalizations.of(context)! + .buildBtn), style: ElevatedButton.styleFrom( backgroundColor: ColorConstant.blue700, ), @@ -184,19 +205,29 @@ class _DynamicFormState extends State { context: context, builder: (BuildContext context) { return AlertDialog( - title: const Text( - 'Confirm Deletion'), - content: const Text( - 'Are you sure you want to delete this Module?'), + title: Text( + AppLocalizations.of( + context)! + .confirmDeletion), + content: Text( + AppLocalizations.of( + context)! + .deleteModuleConfirm), actions: [ TextButton( - child: const Text('Cancel'), + child: Text( + AppLocalizations.of( + context)! + .cancel), onPressed: () { Navigator.of(context).pop(); }, ), TextButton( - child: const Text('Delete'), + child: Text( + AppLocalizations.of( + context)! + .delete), onPressed: () { Navigator.of(context).pop(); deleteEntity(module); diff --git a/lib/utilities/display_error_alert.dart b/lib/utilities/display_error_alert.dart index 6f466d4..59b69ec 100644 --- a/lib/utilities/display_error_alert.dart +++ b/lib/utilities/display_error_alert.dart @@ -2,6 +2,7 @@ import 'package:flutter/material.dart'; import '../database/login_info_storage.dart'; import '../database/user_data_storage.dart'; +import '../l10n/app_localizations.dart'; import '../screens/Login Screen/login_screen.dart'; Future _deleteLoggedInUserData() async { @@ -27,7 +28,7 @@ void showErrorAlert(BuildContext context, Map error) { barrierDismissible: false, builder: (context) => AlertDialog( title: Text( - "Error", + AppLocalizations.of(context)!.error, textAlign: TextAlign.center, ), content: Column( @@ -56,7 +57,7 @@ void showErrorAlert(BuildContext context, Map error) { ), child: ElevatedButton( onPressed: errorTypes[currentError].onClose, - child: Text('OK'), + child: Text(AppLocalizations.of(context)!.ok), style: ElevatedButton.styleFrom( // OLD: primary: Colors.transparent, // removed in Flutter 3.27 - by Azmat backgroundColor: Colors.transparent, // Flutter 3.27 renamed primary - by Azmat