setEnvironmentUrl method

void setEnvironmentUrl(
  1. String? apiUrl
)

Implementation

void setEnvironmentUrl(String? apiUrl) {
  if (apiUrl != null && apiUrl.isNotEmpty) {
    ApiUtils.nimbblTechUrl = apiUrl;
    String webViewUrl = "";
    String webViewRespUrl = "";

    switch (ApiUtils.nimbblTechUrl) {
      case baseUrlUAT:
        webViewUrl = webViewViewUrlUAT;
        webViewRespUrl = webViewRespCheckUrlUAT;
        break;

      case baseUrlPP:
        webViewUrl = webViewViewUrlPP;
        webViewRespUrl = webViewRespCheckUrlPP;
        break;

      case baseUrlPROD:
        webViewUrl = webViewViewUrlPROD;
        webViewRespUrl = webViewRespCheckUrlPROD;
        break;
    }

    ApiUtils.webViewViewUrl = webViewUrl;
    ApiUtils.webViewRespCheckUrl = webViewRespUrl;
  }
}