Browse Source

add missing files

pull/10500/head
muhammedaltug 4 years ago
parent
commit
8aed6ce318
  1. 35
      npm/ng-packs/packages/account-core/proxy/src/lib/proxy/account/profile.service.ts

35
npm/ng-packs/packages/account-core/proxy/src/lib/proxy/account/profile.service.ts

@ -0,0 +1,35 @@
import type { ChangePasswordInput, ProfileDto, UpdateProfileDto } from './models';
import { RestService } from '@abp/ng.core';
import { Injectable } from '@angular/core';
@Injectable({
providedIn: 'root',
})
export class ProfileService {
apiName = 'AbpAccount';
changePassword = (input: ChangePasswordInput) =>
this.restService.request<any, void>({
method: 'POST',
url: '/api/account/my-profile/change-password',
body: input,
},
{ apiName: this.apiName });
get = () =>
this.restService.request<any, ProfileDto>({
method: 'GET',
url: '/api/account/my-profile',
},
{ apiName: this.apiName });
update = (input: UpdateProfileDto) =>
this.restService.request<any, ProfileDto>({
method: 'PUT',
url: '/api/account/my-profile',
body: input,
},
{ apiName: this.apiName });
constructor(private restService: RestService) {}
}
Loading…
Cancel
Save