@chat21/chat21-ionic 3.0.60-rc1 → 3.0.60-rc2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +3 -0
- package/package.json +1 -1
- package/src/app/services/app-config.ts +14 -14
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
# chat21-ionic ver 3.0
|
|
2
2
|
|
|
3
|
+
### 3.0.60-rc2
|
|
4
|
+
- Fixes the bug: in AppConfigProvider the "wsUrl" is incorrect (window.location.port is missing)
|
|
5
|
+
|
|
3
6
|
### 3.0.60-rc1
|
|
4
7
|
- Adds the ability to view canned responses by clicking on the button with the "flash" icon located to the left of the "Enter a message" text area
|
|
5
8
|
|
package/package.json
CHANGED
|
@@ -29,9 +29,9 @@ export class AppConfigProvider {
|
|
|
29
29
|
|
|
30
30
|
|
|
31
31
|
return this.http.get(this.appConfig.remoteConfigUrl)
|
|
32
|
-
.toPromise().then((data: any
|
|
32
|
+
.toPromise().then((data: any) => {
|
|
33
33
|
// console.log('AppConfigService loadAppConfig data: ', data);
|
|
34
|
-
|
|
34
|
+
|
|
35
35
|
const allconfig = data
|
|
36
36
|
// console.log('[APP-CONFIG-SERVICE] - loadAppConfig allconfig: ', allconfig);
|
|
37
37
|
|
|
@@ -59,22 +59,22 @@ export class AppConfigProvider {
|
|
|
59
59
|
|
|
60
60
|
// // console.log('AppConfigService loadAppConfig allconfig !!!! exist - SERVER_BASE_URL protocol is HTTPS - wsUrl', ws_url);
|
|
61
61
|
// } else {
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
// console.log('AppConfigService loadAppConfig allconfig !!!! exist - SERVER_BASE_URL !!! IS RELATIVE - window.location ', window.location);
|
|
65
62
|
|
|
66
|
-
// console.log(window.location)
|
|
67
63
|
|
|
68
|
-
|
|
69
|
-
|
|
64
|
+
// console.log('AppConfigService loadAppConfig allconfig !!!! exist - SERVER_BASE_URL !!! IS RELATIVE - window.location ', window.location);
|
|
65
|
+
|
|
66
|
+
// console.log(window.location)
|
|
70
67
|
|
|
71
|
-
|
|
68
|
+
if (window.location.protocol === 'http:') {
|
|
69
|
+
allconfig.wsUrl = 'ws://' + window.location.hostname + ':' + window.location.port + allconfig.wsUrlRel
|
|
72
70
|
|
|
73
|
-
|
|
74
|
-
} else {
|
|
71
|
+
} else if (window.location.protocol === 'https:') {
|
|
75
72
|
|
|
76
|
-
|
|
77
|
-
|
|
73
|
+
allconfig.wsUrl = 'wss://' + window.location.hostname + ':' + window.location.port + allconfig.wsUrlRel
|
|
74
|
+
} else {
|
|
75
|
+
|
|
76
|
+
allconfig.wsUrl = 'ws://' + window.location.hostname + ':' + window.location.port + allconfig.wsUrlRel
|
|
77
|
+
}
|
|
78
78
|
// }
|
|
79
79
|
|
|
80
80
|
} else {
|
|
@@ -87,7 +87,7 @@ export class AppConfigProvider {
|
|
|
87
87
|
}
|
|
88
88
|
|
|
89
89
|
this.appConfig = allconfig;
|
|
90
|
-
|
|
90
|
+
|
|
91
91
|
|
|
92
92
|
}).catch(err => {
|
|
93
93
|
console.error('error loadAppConfig' + err);
|