|
|
|
|
class URLs {
|
|
|
|
|
URLs._();
|
|
|
|
|
|
|
|
|
|
// static const host1 = "https://atomsm.hmg.com"; // production url
|
|
|
|
|
static const host1 = "https://atomsmdev.hmg.com"; // local UAT url
|
|
|
|
|
|
|
|
|
|
static String _baseUrl = "$_host/mobile";
|
|
|
|
|
|
|
|
|
|
static String _host = host1;
|
|
|
|
|
|
|
|
|
|
set host(String value) => _host = value;
|
|
|
|
|
|
|
|
|
|
static String getFileUrl(String file) => (file == null || file.isEmpty) ? null : (file.contains("/") ? file : "$_baseUrl/Files/DownloadFile?fileName=$file");
|
|
|
|
|
|
|
|
|
|
// static String getFileUrl(String file) => (file == null || file.isEmpty) ? null :1 (file.contains("/") ? file : "$_host/attachment/$file");
|
|
|
|
|
|
|
|
|
|
// API Routes
|
|
|
|
|
static get login => "$_baseUrl/MobileAuth/Login"; // web login
|
|
|
|
|
static get checkLoginValidation => "$_baseUrl/Account/Authenticate"; // web login
|
|
|
|
|
// static get login => "$_baseUrl/MobileAuth/LoginIntegration"; // mobile login
|
|
|
|
|
static get register => "$_baseUrl/handle/create/user"; // post
|
|
|
|
|
static get updateProfile => "$_baseUrl/update/user/profile"; // post
|
|
|
|
|
static get updateProfileImage => "$_baseUrl/Account/ChangeImageEmployee"; // post
|
|
|
|
|
static get getSites => "$_baseUrl/Customer/GetCustomers"; // get
|
|
|
|
|
static get getSitesAutoComplete => "$_baseUrl/Customer/GetCustomersAutoComplete"; // get
|
|
|
|
|
static get getSiteAutoCompleteWithoutConditionSites => "$_baseUrl/Customer/GetCustomersAutoCompleteWithoutConditionSites"; // get
|
|
|
|
|
|
|
|
|
|
static get getDepartments => "$_baseUrl/Customer/GetDepartmentLookup"; // get
|
|
|
|
|
static get getAssets => "$_baseUrl/Asset/GetAssets"; // get
|
|
|
|
|
static get getAssetById => "$_baseUrl/Asset/GetAssetById?assetId="; // get
|
|
|
|
|
static get getModels => "$_baseUrl/ModelDefinition/GetModelDefinitionAsset"; // get ?client=2
|
|
|
|
|
|
|
|
|
|
static get getAllRequestsAndCount => "$_baseUrl/CallRequest/GetAllRequestsAndCount"; // get
|
|
|
|
|
// 08051
|
|
|
|
|
static get getServiceRequests => "$_baseUrl/CallRequest/GetCallRequests"; // get
|
|
|
|
|
static get getServiceRequestById => "$_baseUrl/CallRequest/GetCallRequestById"; // get
|
|
|
|
|
static get getServiceRequestThrough => "$_baseUrl/Lookups/GetLookup?lookupEnum=603"; // get
|
|
|
|
|
static get getServiceLoanAvailability => "$_baseUrl/Lookups/GetLookup?lookupEnum=4"; // get
|
|
|
|
|
static get getServiceFirstAction => "$_baseUrl/Lookups/GetLookup?lookupEnum=700"; // get
|
|
|
|
|
static get getServiceRequestTypes => "$_baseUrl/Lookups/GetLookup?lookupEnum=604"; // get
|
|
|
|
|
static get getServiceRequestStatus => "$_baseUrl/Lookups/GetLookup?lookupEnum=503";
|
|
|
|
|
|
|
|
|
|
static get getRepairLocation => "$_baseUrl/Lookups/GetLookup?lookupEnum=504";
|
|
|
|
|
|
|
|
|
|
static get equipmentStatus => "$_baseUrl/Lookups/GetLookup?lookupEnum=601";
|
|
|
|
|
|
|
|
|
|
static get commissioningStatus => "$_baseUrl/Lookups/GetLookup?lookupEnum=601";
|
|
|
|
|
|
|
|
|
|
static get getDateOperators => "$_baseUrl/Lookups/GetLookup?lookupEnum=200";
|
|
|
|
|
|
|
|
|
|
static get getMaintenanceSituation => "$_baseUrl/Lookups/GetLookup?lookupEnum=502";
|
|
|
|
|
|
|
|
|
|
static get getPreventiveMaintenanceVisits => "$_baseUrl/return/user/calibrations"; // get
|
|
|
|
|
static get updatePreventiveMaintenanceVisits => "$_baseUrl/Visit/UpdateVisits"; // get
|
|
|
|
|
|
|
|
|
|
static get getRegularVisits => "$_baseUrl/Visit/GetVisits"; // get
|
|
|
|
|
static get updateRegularVisits => "$_baseUrl/Visit/UpdateVisits"; // get
|
|
|
|
|
|
|
|
|
|
static get getSingleServiceRequest => "$_baseUrl/return/call/information"; // get
|
|
|
|
|
static get getSuppliersAutoComplete => "$_baseUrl/Supplier/GetSuppliersAutoComplete";
|
|
|
|
|
|
|
|
|
|
static get getSystemNotifications => "$_baseUrl/SystemNotification/GetSystemNotifications"; // get
|
|
|
|
|
static get getRecentNotifications => "$_baseUrl/return/user/recent/notification"; // get
|
|
|
|
|
static get createRequest => "$_baseUrl/CallRequest/AddCallRequest"; // get
|
|
|
|
|
static get CheckIfAssetHasAnotherServiceRequest => "$_baseUrl/CallRequest/CheckIfAssetHasAnotherServiceRequest"; // get
|
|
|
|
|
static get createReport => "$_baseUrl/handle/create/report/issue"; // get
|
|
|
|
|
static get updateRequestDate => "$_baseUrl/CallRequest/UpdateCallRequest"; // get
|
|
|
|
|
|
|
|
|
|
// service report
|
|
|
|
|
static get createServiceReport => "$_baseUrl/WorkOrder/AddWorkOrder"; // get
|
|
|
|
|
static get updateServiceReport => "$_baseUrl/WorkOrder/UpdateWorkOrder"; // get
|
|
|
|
|
static get getServiceReport => "$_baseUrl/WorkOrder/GetWorkOrderById"; // get
|
|
|
|
|
static get createDuplicatedReport => "$_baseUrl/handle/duplicate/request"; // get
|
|
|
|
|
static get searchWorkOrders => "$_baseUrl/WorkOrder/SearchWorkOrders";
|
|
|
|
|
|
|
|
|
|
static get getSubWorkerInfoAccordingToPreviousStep => "$_baseUrl/WorkOrder/GetDataPreviousStep";
|
|
|
|
|
|
|
|
|
|
static get getPpmReasons => "$_baseUrl/Lookups/GetLookup?lookupEnum=522"; // get for ppm po reason, in mobile there is no use of it.
|
|
|
|
|
static get getPpmAssetAvailability => "$_baseUrl/Lookups/GetLookup?lookupEnum=1205"; // get for ppm po reason, in mobile there is no use of it.
|
|
|
|
|
static get getPpmElectricalSafety => "$_baseUrl/Lookups/GetLookup?lookupEnum=480"; // get for ppm po reason, in mobile there is no use of it.
|
|
|
|
|
static get getPpmTaskStatus => "$_baseUrl/Lookups/GetLookup?lookupEnum=403"; // get for ppm po reason, in mobile there is no use of it.
|
|
|
|
|
static get getPpmService => "$_baseUrl/Lookups/GetLookup?lookupEnum=34"; // get for ppm po reason, in mobile there is no use of it.
|
|
|
|
|
static get getServiceReportReasons => "$_baseUrl/Lookups/GetLookupReason?lookupEnum=505"; // get // for service
|
|
|
|
|
static get getServiceReportTypes => "$_baseUrl/Lookups/GetLookup?lookupEnum=501"; // get
|
|
|
|
|
static get getServiceReportTypesForWO => "$_baseUrl/Lookups/GetLookup?lookupEnum=34"; // get
|
|
|
|
|
static get getServiceReportStatus => "$_baseUrl/Lookups/GetLookup?lookupEnum=521"; // get
|
|
|
|
|
static get getServiceReportLastCalls => "$_baseUrl/WorkOrder/GetLookupCallLastSituationBasedOnCase"; // get
|
|
|
|
|
static get getAssetTypes => "$_baseUrl/Lookups/GetLookup?lookupEnum=500"; // get
|
|
|
|
|
static get getPartNumber => "$_baseUrl/PartCatalog/GetPartAutoComplete"; // get
|
|
|
|
|
static get getServiceReportPriority => "$_baseUrl/Lookups/GetLookup?lookupEnum=4"; // get
|
|
|
|
|
static get getServiceReportDefectTypes => "$_baseUrl/Lookups/GetLookup?lookupEnum=601"; // get
|
|
|
|
|
static get getCallRequestForWorkOrder => "$_baseUrl/CallRequest/GetCallRequestForWorkOrder"; // get
|
|
|
|
|
|
|
|
|
|
//gas refill
|
|
|
|
|
static get getGasTypes => "$_baseUrl/Lookups/GetLookup?lookupEnum=606"; // get
|
|
|
|
|
// todo check edits with backend
|
|
|
|
|
static get getGasCylinderSize => "$_baseUrl/Lookups/GetLookup?lookupEnum=608"; // get
|
|
|
|
|
static get getGasCylinderType => "$_baseUrl/Lookups/GetLookup?lookupEnum=607"; // get
|
|
|
|
|
static get getGasStatus => "$_baseUrl/Lookups/GetLookup?lookupEnum=609"; // get
|
|
|
|
|
static get requestGasRefill => "$_baseUrl/GazRefill/AddGazRefill"; // get
|
|
|
|
|
static get updateGasRefill => "$_baseUrl/GazRefill/UpdateGazRefill"; // get
|
|
|
|
|
static get getGasRefill => "$_baseUrl/GazRefill/GetGazRefills"; // get
|
|
|
|
|
static get getGasRefillById => "$_baseUrl/GazRefill/GetGazRefillById"; // get
|
|
|
|
|
static get getGazRefillComments => "$_baseUrl/GazRefill/GetHistoryComments"; // get
|
|
|
|
|
static get addGazRefillComment => "$_baseUrl/GazRefill/AddHistoryComment"; // add
|
|
|
|
|
|
|
|
|
|
//device transfer
|
|
|
|
|
static get requestDeviceTransfer => "$_baseUrl/AssetTransfer/AddAssetTransfer"; // get
|
|
|
|
|
static get updateDeviceTransfer => "$_baseUrl/AssetTransfer/UpdateAssetTransfer"; // get
|
|
|
|
|
static get getDeviceTransfer => "$_baseUrl/AssetTransfer/GetAssetTransfers"; // get
|
|
|
|
|
static get getAssetTransferById => "$_baseUrl/AssetTransfer/GetAssetTransferById"; // get
|
|
|
|
|
static get getAssetTransferStatus => "$_baseUrl/Lookups/GetLookup?lookupEnum=406"; // get
|
|
|
|
|
|
|
|
|
|
// employee
|
|
|
|
|
static get getEmployees => "$_baseUrl/Lookups/GetLookup?lookupEnum=33"; // get
|
|
|
|
|
static get getEngineers => "$_baseUrl/Account/GetUserByRoleValue?value=R-6"; // get
|
|
|
|
|
static get getNurses => "$_baseUrl/Account/GetUserByRoleValue?value=R-7"; // get
|
|
|
|
|
static get getNursesBySiteId => "$_baseUrl/Account/GetUserByRoleValueSiteAndAssetGroupBySiteId?value=R-7"; // get
|
|
|
|
|
|
|
|
|
|
// pentry
|
|
|
|
|
static get getPentry => "$_baseUrl/return/pentry/details"; // get
|
|
|
|
|
static get updatePentry => "$_baseUrl/Visit/UpdateVisit"; // get
|
|
|
|
|
static get getPentryTaskStatus => "$_baseUrl/Lookups/GetLookup?lookupEnum=403"; // get
|
|
|
|
|
static get getPentryVisitStatus => "$_baseUrl/Lookups/GetLookup?lookupEnum=402"; // get
|
|
|
|
|
static get getPentryStatus => "$_baseUrl/Lookups/GetLookup?lookupEnum=401"; // get
|
|
|
|
|
// contacts
|
|
|
|
|
static get getPentryContacts => "$_baseUrl/handle/return/all/contacts"; // get
|
|
|
|
|
//comments
|
|
|
|
|
static get getComments => "$_baseUrl/CallRequest/GetHistoryComments"; // get
|
|
|
|
|
static get addComment => "$_baseUrl/CallRequest/AddHistoryComment"; // add
|
|
|
|
|
}
|