@@ -84,7 +84,7 @@ const MaterialFormView: React.FC<MaterialFormViewProps> = ({
8484 showCloseButton
8585 >
8686 < Grid container spacing = { 2 } >
87- < Grid item xs = { 7 } >
87+ < Grid item xs = { 12 } >
8888 < FormControl fullWidth >
8989 < Typography
9090 sx = { {
@@ -104,51 +104,6 @@ const MaterialFormView: React.FC<MaterialFormViewProps> = ({
104104 />
105105 </ FormControl >
106106 </ Grid >
107- < Grid item xs = { 5 } >
108- < FormControl fullWidth >
109- < Typography
110- sx = { {
111- fontWeight : 'bold' ,
112- fontSize : '1.75rem' ,
113- color : '#EF4345'
114- } }
115- variant = "h5"
116- >
117- Reimbursement #:
118- </ Typography >
119- < Controller
120- name = "reimbursementRequestId"
121- control = { control }
122- defaultValue = { control . _defaultValues . reimbursementRequestId }
123- render = { ( { field } ) => (
124- < TextField
125- { ...field }
126- select
127- variant = "outlined"
128- error = { ! ! errors . reimbursementRequestId }
129- helperText = { errors . reimbursementRequestId ?. message }
130- SelectProps = { {
131- displayEmpty : true ,
132- renderValue : ( selected ) =>
133- selected ? (
134- reimbursementRequests . find ( ( rr ) => rr . reimbursementRequestId === selected ) ?. identifier
135- ) : (
136- < Typography sx = { { fontSize : '1rem' , color : 'lightgray' , opacity : 0.6 } } >
137- Select Corresponding RR
138- </ Typography >
139- )
140- } }
141- >
142- { reimbursementRequests . map ( ( rr : ReimbursementRequest ) => (
143- < MenuItem key = { rr . reimbursementRequestId } value = { rr . reimbursementRequestId } >
144- { rr . identifier }
145- </ MenuItem >
146- ) ) }
147- </ TextField >
148- ) }
149- />
150- </ FormControl >
151- </ Grid >
152107 < Grid item xs = { 6 } >
153108 < FormControl fullWidth >
154109 < Typography
@@ -208,7 +163,6 @@ const MaterialFormView: React.FC<MaterialFormViewProps> = ({
208163 setValue ( 'materialTypeName' , '' ) ;
209164 onChange ( '' ) ;
210165 } ;
211-
212166 return (
213167 < Box sx = { { alignItems : 'center' } } >
214168 < NERAutocomplete
@@ -241,7 +195,7 @@ const MaterialFormView: React.FC<MaterialFormViewProps> = ({
241195 } }
242196 variant = "h5"
243197 >
244- Manufacturer:*
198+ Manufacturer:
245199 </ Typography >
246200 < Tooltip
247201 title = { 'Make sure not to enter the distributor (e.g. Amazon)' }
@@ -321,17 +275,10 @@ const MaterialFormView: React.FC<MaterialFormViewProps> = ({
321275 } }
322276 variant = "h5"
323277 >
324- Part Details:*
278+ Part Details:
325279 </ Typography >
326280 < Tooltip title = { "Enter 'N/A' if no Manufacturer Part Number" } placement = "right" >
327- < HelpIcon
328- sx = { {
329- fontSize : 'medium' ,
330- ml : 1 ,
331- color : 'lightgray' ,
332- cursor : 'pointer'
333- } }
334- />
281+ < HelpIcon sx = { { marginBottom : '-1.2em' , fontSize : 'medium' , marginLeft : '5px' , color : 'lightgray' } } />
335282 </ Tooltip >
336283 </ Box >
337284 </ Grid >
@@ -460,6 +407,41 @@ const MaterialFormView: React.FC<MaterialFormViewProps> = ({
460407 </ Grid >
461408 </ Grid >
462409 < Grid item xs = { 12 } >
410+ < Grid item xs = { 12 } mt = { 2 } >
411+ < FormControl fullWidth >
412+ < Controller
413+ name = "reimbursementRequestId"
414+ control = { control }
415+ defaultValue = { control . _defaultValues . reimbursementRequestId }
416+ render = { ( { field } ) => (
417+ < TextField
418+ { ...field }
419+ select
420+ variant = "outlined"
421+ error = { ! ! errors . reimbursementRequestId }
422+ helperText = { errors . reimbursementRequestId ?. message }
423+ SelectProps = { {
424+ displayEmpty : true ,
425+ renderValue : ( selected ) =>
426+ selected ? (
427+ reimbursementRequests . find ( ( rr ) => rr . reimbursementRequestId === selected ) ?. identifier
428+ ) : (
429+ < Typography sx = { { fontSize : '1rem' , color : 'lightgray' , opacity : 0.6 } } >
430+ Select Corresponding Reimbursement Request Number
431+ </ Typography >
432+ )
433+ } }
434+ >
435+ { reimbursementRequests . map ( ( rr : ReimbursementRequest ) => (
436+ < MenuItem key = { rr . reimbursementRequestId } value = { rr . reimbursementRequestId } >
437+ { rr . identifier }
438+ </ MenuItem >
439+ ) ) }
440+ </ TextField >
441+ ) }
442+ />
443+ </ FormControl >
444+ </ Grid >
463445 < Box display = { 'flex' } justifyContent = { 'flex-end' } mt = { 2 } >
464446 < FormControl fullWidth >
465447 < Controller
0 commit comments