File tree 1 file changed +4
-12
lines changed
specifyweb/frontend/js_src/lib/components/Interactions
1 file changed +4
-12
lines changed Original file line number Diff line number Diff line change @@ -38,7 +38,8 @@ import { AutoGrowTextArea } from '../Molecules/AutoGrowTextArea';
38
38
import { Dialog } from '../Molecules/Dialog' ;
39
39
import { userPreferences } from '../Preferences/userPreferences' ;
40
40
import { RecordSetsDialog } from '../Toolbar/RecordSets' ;
41
- import type {
41
+ import {
42
+ interactionsWithPrepTables ,
42
43
InteractionWithPreps ,
43
44
PreparationData ,
44
45
PreparationRow ,
@@ -288,20 +289,11 @@ export function InteractionDialog({
288
289
>
289
290
{ interactionsText . addUnassociated ( ) }
290
291
</ Button . Info >
291
- ) : actionTable . name === 'Loan' &&
292
- ! (
293
- state . type === 'MissingState' && prepsData ?. length === 0
294
- ) ? (
295
- < Link . Info href = { getResourceViewUrl ( 'Loan' ) } >
292
+ ) : interactionsWithPrepTables . includes ( actionTable . name ) ? (
293
+ < Link . Info href = { getResourceViewUrl ( actionTable . name ) } >
296
294
{ interactionsText . withoutPreparations ( ) }
297
295
</ Link . Info >
298
296
) : undefined }
299
- { actionTable . name === 'Gift' &&
300
- itemCollection === undefined && (
301
- < Link . Info href = { getResourceViewUrl ( 'Gift' ) } >
302
- { interactionsText . withoutPreparations ( ) }
303
- </ Link . Info >
304
- ) }
305
297
{ state . type === 'MissingState' &&
306
298
prepsData ?. length !== 0 &&
307
299
prepsData ? (
You can’t perform that action at this time.
0 commit comments