Fix mock load.

This commit is contained in:
Paulo Gustavo Veiga 2024-02-11 20:46:20 -08:00
parent 2a4ee9cb69
commit 8cf2016028
2 changed files with 3 additions and 4 deletions

View File

@ -1,4 +1,3 @@
<!-- This is a temporal hack only with the purpose to allow the transition with Spring MVC-->
<!DOCTYPE html> <!DOCTYPE html>
<html lang="en"> <html lang="en">
@ -28,7 +27,7 @@
<meta property="og:site_name" content="WiseMapping" /> <meta property="og:site_name" content="WiseMapping" />
<script> <script>
if ('<%=CLIENT_TYPE%>' === 'rest'); if ('<%=CLIENT_TYPE%>' === 'rest')
{ {
window.serverconfig = { window.serverconfig = {
apiBaseUrl: 'http://localhost:3000', apiBaseUrl: 'http://localhost:3000',

View File

@ -80,9 +80,9 @@ class _AppConfig {
} }
buildClient(): Client { buildClient(): Client {
const config = this.getInstance();
let result: Client; let result: Client;
if (config.clientType == 'rest') { if (this.isRestClient()) {
const config = this.getInstance();
result = new RestClient(this.getBaseUrl()); result = new RestClient(this.getBaseUrl());
console.log('Service using rest client. ' + JSON.stringify(config)); console.log('Service using rest client. ' + JSON.stringify(config));
} else { } else {