diff --git a/angular/src/app/components/user-data-order/user-data-order.component.ts b/angular/src/app/components/user-data-order/user-data-order.component.ts index 9527530..74ceb34 100644 --- a/angular/src/app/components/user-data-order/user-data-order.component.ts +++ b/angular/src/app/components/user-data-order/user-data-order.component.ts @@ -146,7 +146,7 @@ export class UserDataOrderComponent implements OnInit, OnDestroy { const houseValidators = name === 'Доставка' ? [Validators.required, Validators.maxLength(10),] : [] const userDataForm = this.fb.group({ phone: [this.userData.phone], - first_name: [this.userData.first_name, [Validators.required, Validators.minLength(2), Validators.maxLength(255),]], + first_name: [this.userData.first_name, [Validators.required, Validators.minLength(2), Validators.maxLength(255)]], // last_name: [this.userData.last_name, [Validators.required, Validators.minLength(2), Validators.maxLength(255),]], street: [this.userData.street, streetValidators], house: [this.userData.house, houseValidators], @@ -241,7 +241,7 @@ export class UserDataOrderComponent implements OnInit, OnDestroy { return this.fb.group({ selectedTerminal: [{ value: this.selectedTerminal, disabled: true }, []], phone: [this.userData.phone], - first_name: [this.userData.name, [Validators.required, Validators.minLength(2), Validators.maxLength(255),]], + first_name: [{value: this.userData.name, disabled: true}, [Validators.required, Validators.minLength(2), Validators.maxLength(255),]], // last_name: [this.userData.last_name, [Validators.required, Validators.minLength(2), Validators.maxLength(255),]], street: [{ value: this.userData.street, disabled: isSelfDelivery }, isSelfDelivery ?? [Validators.required, Validators.minLength(2), Validators.maxLength(255),]], house: [{ value: this.userData.house, disabled: isSelfDelivery }, isSelfDelivery ?? [Validators.required, Validators.maxLength(10), Validators.pattern('^\\d+[-|\\d]+\\d+$|^\\d*$')]], diff --git a/angular/src/app/services/order.service.ts b/angular/src/app/services/order.service.ts index 07ec98a..11b8910 100644 --- a/angular/src/app/services/order.service.ts +++ b/angular/src/app/services/order.service.ts @@ -171,16 +171,16 @@ export class OrderService { .pipe( tap({ next: (_) => { - this.jsonRpcService - .rpc( - { - method: 'updateAdditionalInfo', - params: [this.order.userData, this.order.deliveryData], - }, - RpcService.authService, - true - ) - .subscribe(); + // this.jsonRpcService + // .rpc( + // { + // method: 'updateAdditionalInfo', + // params: [this.order.userData, this.order.deliveryData], + // }, + // RpcService.authService, + // true + // ) + // .subscribe(); }, }) );