File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -2,8 +2,9 @@ import { deepFreeze } from '@douglasneuroinformatics/libjs';
22import type { CreateGroupData } from '@opendatacapture/schemas/group' ;
33import type { User } from '@opendatacapture/schemas/user' ;
44
5- type DemoUser = Pick < User , 'basePermissionLevel' | 'firstName' | 'lastName' | 'password' | ' username'> & {
5+ type DemoUser = Pick < User , 'basePermissionLevel' | 'firstName' | 'lastName' | 'username' > & {
66 groupNames : readonly string [ ] ;
7+ password : string ;
78} ;
89
910type DemoGroup = CreateGroupData & { dummyIdPrefix ?: string } ;
Original file line number Diff line number Diff line change @@ -23,7 +23,6 @@ export const $User = $BaseModel.extend({
2323 firstName : z . string ( ) . min ( 1 ) ,
2424 groupIds : z . array ( z . string ( ) ) ,
2525 lastName : z . string ( ) . min ( 1 ) ,
26- password : z . string ( ) . min ( 1 ) ,
2726 sex : $Sex . nullish ( ) ,
2827 username : z . string ( ) . min ( 1 )
2928} ) ;
@@ -35,11 +34,11 @@ export const $CreateUserData = $User
3534 firstName : true ,
3635 groupIds : true ,
3736 lastName : true ,
38- password : true ,
3937 username : true
4038 } )
4139 . extend ( {
4240 dateOfBirth : z . coerce . date ( ) . optional ( ) ,
41+ password : z . string ( ) . min ( 1 ) ,
4342 sex : $Sex . optional ( )
4443 } ) ;
4544
You can’t perform that action at this time.
0 commit comments