File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed
src/apps/admin/src/lib/utils Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -46,7 +46,7 @@ export const formAddDefaultReviewerSchema: Yup.ObjectSchema<FormAddDefaultReview
4646 memberReviewerCount : Yup . number ( )
4747 . optional ( )
4848 . when ( 'isMemberReview' , {
49- is : true ,
49+ is : false ,
5050 otherwise : schema => schema . optional ( ) ,
5151 then : schema => schema
5252 . required ( 'Member Reviewer Count is required when Is Member Review is checked' )
@@ -59,7 +59,13 @@ export const formAddDefaultReviewerSchema: Yup.ObjectSchema<FormAddDefaultReview
5959 phaseName : Yup . string ( )
6060 . required ( 'Phase Name is required' ) ,
6161 scorecardId : Yup . string ( )
62- . required ( 'Scorecard is required' ) ,
62+ . optional ( )
63+ . when ( 'isMemberReview' , {
64+ is : false ,
65+ otherwise : schema => schema . optional ( ) ,
66+ then : schema => schema
67+ . required ( 'Scorecard is required' ) ,
68+ } ) ,
6369 shouldOpenOpportunity : Yup . boolean ( )
6470 . required ( ) ,
6571 timelineTemplateId : Yup . string ( )
You can’t perform that action at this time.
0 commit comments