-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/namecard comment #96
base: develop
Are you sure you want to change the base?
Conversation
그리고 방명록 조회할 때, isMine만 같이 내려주면 해당 댓글이 사용자가 작성한 것인지 아닌건지에 대한 것에 따라 서버에서 따로 처리할 것 없이 클라쪽에서 이후에 해당 사용자가 작성한 것이 아니면 댓글에 대한 수정 작업을 할 수 없게한다던가 해서 처리해주는 것 아닌가용? |
@ApiProperty({ example: '공개여부' }) | ||
@IsString() | ||
@IsNotEmpty() | ||
@Column({ default: false }) | ||
isPrivate: boolean; | ||
|
||
@ApiProperty({ example: '고정여부' }) | ||
@IsString() | ||
@IsNotEmpty() | ||
@Column({ default: false }) | ||
isFix: boolean; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
boolean type인데 @IsString()
이 걸려있네욜
@Column() | ||
nameCardId: number; | ||
|
||
isMine?: boolean; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
요거는 별도의 데코레이터 사용이 안되어있는 이유가 있나요?
HttpStatus, | ||
Injectable, | ||
} from '@nestjs/common'; | ||
import { HttpErrorByCode } from '@nestjs/common/utils/http-error-by-code.util'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
build warning 안뜨게 제거해주세요
if (fixedComments.length >= 3) { | ||
throw new HttpException( | ||
{ | ||
status: HttpStatus.NOT_ACCEPTABLE, | ||
error: '명함의 방명록은 3개까지만 상단 고정이 가능합니다.', | ||
}, | ||
HttpStatus.NOT_FOUND, | ||
); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
3개까지니까 > 로 해야하지 않나용? 그리고 status code를 다른 걸로 수정해야 할 것 같어요
makeFirstNameCard: userOnboardingStatusType; | ||
makeFirstNameCard: 'WAIT' | 'DONE_WAIT' | 'DONE'; | ||
|
||
@IsNotEmpty() | ||
@IsString() | ||
@Column({ default: 'WAIT' }) | ||
saveMeetuMyAlbum: userOnboardingStatusType; | ||
saveMeetuMyAlbum: 'WAIT' | 'DONE_WAIT' | 'DONE'; | ||
|
||
@IsNotEmpty() | ||
@IsString() | ||
@Column({ default: 'WAIT' }) | ||
addFriendNameCard: userOnboardingStatusType; | ||
addFriendNameCard: 'WAIT' | 'DONE_WAIT' | 'DONE'; | ||
|
||
// @IsNotEmpty() | ||
// @IsString() | ||
// @Column({ default: 'WAIT' }) | ||
// makeNewCollection: userOnboardingStatusType; | ||
// makeNewCollection: 'WAIT' | 'DONE_WAIT' | 'DONE'; | ||
|
||
@IsNotEmpty() | ||
@IsString() | ||
@Column({ default: 'WAIT' }) | ||
makeThreeNameCards: userOnboardingStatusType; | ||
makeThreeNameCards: 'WAIT' | 'DONE_WAIT' | 'DONE'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
왜 enum에서 가져오는 거에서 이걸루 바꾼거야?!
@@ -13,6 +13,8 @@ export interface NameCardSchema { | |||
contacts: ContactSchema[]; | |||
tmis: TmiSchema[]; | |||
personalSkills: PersonalSkillSchema[]; | |||
commentCount?: number; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
optional이 필요한가?? 없는 건 걍 0주면 될 것 같은데
@@ -3,6 +3,7 @@ import { createParamDecorator, ExecutionContext } from '@nestjs/common'; | |||
export const AuthUser = createParamDecorator( | |||
(data: unknown, ctx: ExecutionContext) => { | |||
const request = ctx.switchToHttp().getRequest(); | |||
request.user = { id: 1 }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
아 그리고 이 코드는 왜 들어가있는거지???(궁금)
위 5가지 API를 작업하였습니다