แก้ชื่อสิท
This commit is contained in:
parent
828dd2a37d
commit
ab138c2e04
23 changed files with 77 additions and 67 deletions
|
|
@ -63,7 +63,7 @@ export class ProfileAvatarController extends Controller {
|
|||
|
||||
@Post()
|
||||
public async newAvatar(@Request() req: RequestWithUser, @Body() body: CreateProfileAvatar) {
|
||||
await new permission().PermissionCreate(req,"SYS_REGISTRY");
|
||||
await new permission().PermissionCreate(req, "SYS_REGISTRY_OFFICER");
|
||||
const profile = await this.profileRepository.findOne({
|
||||
where: { id: body.profileId },
|
||||
});
|
||||
|
|
@ -115,7 +115,7 @@ export class ProfileAvatarController extends Controller {
|
|||
|
||||
@Delete("{avatarId}")
|
||||
public async deleteAvatar(@Path() avatarId: string, @Request() req: RequestWithUser) {
|
||||
await new permission().PermissionDelete(req,"SYS_REGISTRY");
|
||||
await new permission().PermissionDelete(req, "SYS_REGISTRY_OFFICER");
|
||||
const result = await this.avatarRepository.delete({ id: avatarId });
|
||||
|
||||
if (result.affected == undefined || result.affected <= 0) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue