From 7eb3544ab0f4be065fd843cb07c5f2879dda7a39 Mon Sep 17 00:00:00 2001 From: cpf <1105965053@qq.com> Date: Thu, 4 Nov 2021 10:18:21 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E8=AF=B7=E6=B1=82=E5=A4=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/app/service/babylon/building-basic-infos.service.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/app/service/babylon/building-basic-infos.service.ts b/src/app/service/babylon/building-basic-infos.service.ts index 5562801..ab0cd05 100644 --- a/src/app/service/babylon/building-basic-infos.service.ts +++ b/src/app/service/babylon/building-basic-infos.service.ts @@ -38,9 +38,11 @@ export class BuildingBasicInfosService { postBuildingBasicInfos(name: string, data: any): Observable { let params = { name: name, - // content: JSON.stringify(data), } - return this.http.post(this.baseUrl + this.c_post, JSON.stringify(data), { params }) + let headers = { + "Content-Type": "application/json" + } + return this.http.post(this.baseUrl + this.c_post, `'${JSON.stringify(data)}'`, { headers,params }) .pipe( catchError((err) => this.handleError(err)) );