From 5805eba8cce5c467cd9044def064a96ca9c4b1d3 Mon Sep 17 00:00:00 2001 From: = Date: Fri, 17 Jul 2020 10:39:28 +0200 Subject: [PATCH 1/3] fix auth --- Thermo.Active/wwwroot/src/services/recipeService.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Thermo.Active/wwwroot/src/services/recipeService.ts b/Thermo.Active/wwwroot/src/services/recipeService.ts index 28089abb..a6ff7c6b 100644 --- a/Thermo.Active/wwwroot/src/services/recipeService.ts +++ b/Thermo.Active/wwwroot/src/services/recipeService.ts @@ -54,12 +54,12 @@ export class RecipeService extends baseRestService { } async Confirm(section: string) { - let result = await this.Put((await this.BASE_URL()) + "confirm?section=" + section, true); + let result = await this.Put((await this.BASE_URL()) + "confirm?section=" + section, null, true); return result; } async Cancel() { - let result = await this.Put((await this.BASE_URL()) + "cancel", true); + let result = await this.Put((await this.BASE_URL()) + "cancel", null, true); return result; } From a45b1b8f5ea6777209386144f436470b667758bf Mon Sep 17 00:00:00 2001 From: = Date: Fri, 17 Jul 2020 10:49:31 +0200 Subject: [PATCH 2/3] fix service auth --- .../wwwroot/src/_base/baseRestService.ts | 20 +++++++++---------- .../wwwroot/src/services/warmersService.ts | 6 +++--- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/Thermo.Active/wwwroot/src/_base/baseRestService.ts b/Thermo.Active/wwwroot/src/_base/baseRestService.ts index c5503312..8e0fd247 100644 --- a/Thermo.Active/wwwroot/src/_base/baseRestService.ts +++ b/Thermo.Active/wwwroot/src/_base/baseRestService.ts @@ -105,7 +105,7 @@ export class baseRestService { transitionIn: "fadeIn", transitionOut: "fadeOut", }) - + } if (!r) { @@ -133,13 +133,13 @@ export class baseRestService { let response = await this.http.post(uri, data, { headers: headers, - params :params + params: params } as AxiosRequestConfig); return response; } - protected async get(uri: string, sendAuthenticationToken: boolean = false, params: object = {}): Promise { + protected async get(uri: string, sendAuthenticationToken: boolean = true, params: object = {}): Promise { let response = await this.http.get(this.baseUrl + uri, { headers: this.prepareHeaders(this.allwaysSendAuthenticationToken || sendAuthenticationToken, false), @@ -149,46 +149,46 @@ export class baseRestService { return response; }; - protected async Get(uri: string, sendAuthenticationToken: boolean = false, params: object = {}): Promise { + protected async Get(uri: string, sendAuthenticationToken: boolean = true, params: object = {}): Promise { let result = await this.get(uri, sendAuthenticationToken, params); if (result.status == 200) return result.data as TResult; return null; } - protected async post(uri: string, data: any, sendAuthenticationToken: boolean = false): Promise { + protected async post(uri: string, data: any, sendAuthenticationToken: boolean = true): Promise { let response = await this.http.post(this.baseUrl + uri, data, { headers: this.prepareHeaders(this.allwaysSendAuthenticationToken || sendAuthenticationToken, true) }); return response; }; - protected async Post(uri: string, data: any, sendAuthenticationToken: boolean = false): Promise { + protected async Post(uri: string, data: any, sendAuthenticationToken: boolean = true): Promise { let result = await this.post(uri, data, sendAuthenticationToken); if (result.status == 200) return result.data as TResult; return null; } - protected async put(uri: string, data: any, sendAuthenticationToken: boolean = false): Promise { + protected async put(uri: string, data: any, sendAuthenticationToken: boolean = true): Promise { let response = await this.http.put(this.baseUrl + uri, JSON.stringify(data), { headers: this.prepareHeaders(this.allwaysSendAuthenticationToken || sendAuthenticationToken, true) }); return response; } - protected async Put(uri: string, data: any, sendAuthenticationToken: boolean = false): Promise { + protected async Put(uri: string, data: any, sendAuthenticationToken: boolean = true): Promise { let result = await this.put(uri, data, sendAuthenticationToken); if (result.status == 200) return result.data as TResult; return null; } - protected async delete(uri: string, sendAuthenticationToken: boolean = false): Promise { + protected async delete(uri: string, sendAuthenticationToken: boolean = true): Promise { let response = await this.http.delete(this.baseUrl + uri, { headers: this.prepareHeaders(this.allwaysSendAuthenticationToken || sendAuthenticationToken, false) }); return response; } - protected async Delete(uri: string, sendAuthenticationToken: boolean = false): Promise { + protected async Delete(uri: string, sendAuthenticationToken: boolean = true): Promise { let result = await this.delete(uri, sendAuthenticationToken); if (result.status == 200) return result.data as TResult; diff --git a/Thermo.Active/wwwroot/src/services/warmersService.ts b/Thermo.Active/wwwroot/src/services/warmersService.ts index 24a8007b..f43cb0b8 100644 --- a/Thermo.Active/wwwroot/src/services/warmersService.ts +++ b/Thermo.Active/wwwroot/src/services/warmersService.ts @@ -26,17 +26,17 @@ export class WarmersService extends baseRestService { } async Confirm() { - let result = await this.Put((await this.BASE_URL()) + "confirm", true); + let result = await this.Put((await this.BASE_URL()) + "confirm", null, true); return result; } async Cancel() { - let result = await this.Put((await this.BASE_URL()) + "cancel", true); + let result = await this.Put((await this.BASE_URL()) + "cancel", null, true); return result; } async SetConfig() { - let result = await this.Put((await this.BASE_URL()) + "setConfig", true); + let result = await this.Put((await this.BASE_URL()) + "setConfig", null, true); return result; } From 61afcc2d01e9c5c4bebc8a7c6bd1c228e7a2a6ac Mon Sep 17 00:00:00 2001 From: = Date: Fri, 17 Jul 2020 11:17:14 +0200 Subject: [PATCH 3/3] fix visualizzazione durata stimata --- .../processo/components/gantt/gantt-component.vue | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/Thermo.Active/wwwroot/src/app_modules_thermo/processo/components/gantt/gantt-component.vue b/Thermo.Active/wwwroot/src/app_modules_thermo/processo/components/gantt/gantt-component.vue index 11f8d735..e32579c2 100644 --- a/Thermo.Active/wwwroot/src/app_modules_thermo/processo/components/gantt/gantt-component.vue +++ b/Thermo.Active/wwwroot/src/app_modules_thermo/processo/components/gantt/gantt-component.vue @@ -18,7 +18,7 @@ - + {{value.label | localize(value.label)}} - +