@brggroup/share-lib 0.0.98 → 0.0.99
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.
|
@@ -6075,7 +6075,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.7", ngImpor
|
|
|
6075
6075
|
}] });
|
|
6076
6076
|
|
|
6077
6077
|
class VscService extends HTTPService {
|
|
6078
|
-
// private readonly currentVersion = '{{POST_BUILD_ENTERS_VERSION_HERE}}';
|
|
6079
6078
|
static feClientVersion = '{{POST_BUILD_ENTERS_VERSION_HERE}}';
|
|
6080
6079
|
static feServerVersion;
|
|
6081
6080
|
static beVersion;
|
|
@@ -6098,8 +6097,6 @@ class VscService extends HTTPService {
|
|
|
6098
6097
|
this.checkFrontendVersion();
|
|
6099
6098
|
if (all) {
|
|
6100
6099
|
this.checkBackendVersion();
|
|
6101
|
-
// this.checkDatabaseVersion();
|
|
6102
|
-
// this.checkJSReportTemplateVersion();
|
|
6103
6100
|
}
|
|
6104
6101
|
}
|
|
6105
6102
|
checkFrontendVersion() {
|
|
@@ -6107,16 +6104,12 @@ class VscService extends HTTPService {
|
|
|
6107
6104
|
return;
|
|
6108
6105
|
}
|
|
6109
6106
|
console.log('current version: ', VscService.feClientVersion);
|
|
6110
|
-
this.get(AppGlobals.versionCheck + '?t=' + new Date().getTime()).then(async (response) => {
|
|
6107
|
+
this.get(AppGlobals.versionCheck + '?t=' + new Date().getTime(), true).then(async (response) => {
|
|
6111
6108
|
VscService.feServerVersion = response.version;
|
|
6112
6109
|
console.log('version check: ', VscService.feServerVersion);
|
|
6113
6110
|
const hashChanged = this.hasVersionChanged(VscService.feClientVersion, VscService.feServerVersion);
|
|
6114
6111
|
if (hashChanged) {
|
|
6115
|
-
// window.location.reload();
|
|
6116
|
-
// window.location.href = window.location.href;
|
|
6117
6112
|
this.isShowingPopup = true;
|
|
6118
|
-
// await this.notiService.warning('Có phiên bản mới', 'Vui lòng ấn "Ctrl + F5" để cập nhật');
|
|
6119
|
-
// this.isShowingPopup = false;
|
|
6120
6113
|
const modalRef = this.modal.warning({
|
|
6121
6114
|
nzTitle: 'Có phiên bản mới',
|
|
6122
6115
|
nzContent: 'Vui lòng ấn "Ctrl + F5" để cập nhật',
|
|
@@ -6138,8 +6131,8 @@ class VscService extends HTTPService {
|
|
|
6138
6131
|
}
|
|
6139
6132
|
}
|
|
6140
6133
|
checkBackendVersion() {
|
|
6141
|
-
this.
|
|
6142
|
-
VscService.beVersion =
|
|
6134
|
+
this.get(AppGlobals.apiEndpoint + '/version', true).then((res) => {
|
|
6135
|
+
VscService.beVersion = res;
|
|
6143
6136
|
}, (err) => {
|
|
6144
6137
|
console.error(err, 'Could not get backend version');
|
|
6145
6138
|
VscService.beVersion = 'Could not get backend version';
|