File tree Expand file tree Collapse file tree 3 files changed +5
-11
lines changed 
views/ProgrammingView/ProgrammingPrescriptionList Expand file tree Collapse file tree 3 files changed +5
-11
lines changed Original file line number Diff line number Diff line change @@ -18,8 +18,8 @@ export const PrescriptionFilters = z.object({
1818  kinds : z . array ( ProgrammingPlanKind ) . nullish ( ) , 
1919  context : ProgrammingPlanContext . nullish ( ) , 
2020  matrixQuery : z . string ( ) . nullish ( ) , 
21-   missingSlaughterhouse : z . boolean ( ) . default ( false ) , 
22-   missingLaboratory : z . boolean ( ) . default ( false ) 
21+   missingSlaughterhouse : z . boolean ( ) . nullish ( ) , 
22+   missingLaboratory : z . boolean ( ) . nullish ( ) 
2323} ) ; 
2424
2525export  type  PrescriptionFilters  =  z . infer < typeof  PrescriptionFilters > ; 
Original file line number Diff line number Diff line change @@ -170,7 +170,7 @@ const ProgrammingPrescriptionListHeader = ({
170170            < ToggleSwitch 
171171              label = { < span  className = "no-wrap" > Abattoir à attribuer</ span > } 
172172              inputTitle = "Filtrer les prélèvements avec abattoir à attribuer" 
173-               checked = { prescriptionFilters . missingSlaughterhouse } 
173+               checked = { prescriptionFilters . missingSlaughterhouse   ??   false } 
174174              onChange = { ( checked )  =>  { 
175175                dispatch ( 
176176                  prescriptionsSlice . actions . changePrescriptionFilters ( { 
@@ -190,7 +190,7 @@ const ProgrammingPrescriptionListHeader = ({
190190                    < span  className = "no-wrap" > Laboratoire à attribuer</ span > 
191191                  } 
192192                  inputTitle = "Filtrer les prélèvements avec laboratoire à attribuer" 
193-                   checked = { prescriptionFilters . missingLaboratory } 
193+                   checked = { prescriptionFilters . missingLaboratory   ??   false } 
194194                  onChange = { ( checked )  =>  { 
195195                    dispatch ( 
196196                      prescriptionsSlice . actions . changePrescriptionFilters ( { 
Original file line number Diff line number Diff line change 77  flow , 
88  isArray , 
99  isDate , 
10-   isEqual , 
11-   isPlainObject , 
12-   pick 
10+   isPlainObject 
1311}  from  'lodash-es' ; 
1412import  {  z  }  from  'zod' ; 
1513
@@ -87,7 +85,3 @@ export const formatWithTz = (date: Date, formatStr: string) =>
8785  format ( toZonedTime ( date ,  'Europe/Paris' ) ,  formatStr ,  { 
8886    locale : fr 
8987  } ) ; 
90- 
91- export  function  isEqualOnKeys < T > ( obj1 : T ,  obj2 : T ,  keys : ( keyof  T ) [ ] ) : boolean  { 
92-   return  isEqual ( pick ( obj1 ,  keys ) ,  pick ( obj2 ,  keys ) ) ; 
93- } 
    
 
   
 
     
   
   
          
     
  
    
     
 
    
      
     
 
     
    You can’t perform that action at this time.
  
 
    
  
     
    
      
        
     
 
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments