@@ -69,49 +69,6 @@ function ReportFieldsSettingsPage({
69
69
title = { reportField . name }
70
70
shouldSetModalVisibility = { false }
71
71
/>
72
- < MenuItemWithTopDescription
73
- style = { [ styles . moneyRequestMenuItem ] }
74
- titleStyle = { styles . flex1 }
75
- title = { reportField . name }
76
- description = { translate ( 'common.name' ) }
77
- interactive = { false }
78
- />
79
- < MenuItemWithTopDescription
80
- style = { [ styles . moneyRequestMenuItem ] }
81
- titleStyle = { styles . flex1 }
82
- title = { Str . recapitalize ( translate ( WorkspaceReportFieldUtils . getReportFieldTypeTranslationKey ( reportField . type ) ) ) }
83
- description = { translate ( 'common.type' ) }
84
- interactive = { false }
85
- />
86
- { ! isListFieldEmpty && (
87
- < MenuItemWithTopDescription
88
- style = { [ styles . moneyRequestMenuItem ] }
89
- titleStyle = { styles . flex1 }
90
- title = { WorkspaceReportFieldUtils . getReportFieldInitialValue ( reportField ) }
91
- description = { translate ( 'common.initialValue' ) }
92
- shouldShowRightIcon = { ! isDateFieldType && ! hasAccountingConnections }
93
- interactive = { ! isDateFieldType && ! hasAccountingConnections }
94
- onPress = { ( ) => Navigation . navigate ( ROUTES . WORKSPACE_EDIT_REPORT_FIELDS_INITIAL_VALUE . getRoute ( policyID , reportFieldID ) ) }
95
- />
96
- ) }
97
- { isListFieldType && (
98
- < MenuItemWithTopDescription
99
- style = { [ styles . moneyRequestMenuItem ] }
100
- titleStyle = { styles . flex1 }
101
- description = { translate ( 'workspace.reportFields.listValues' ) }
102
- shouldShowRightIcon
103
- onPress = { ( ) => Navigation . navigate ( ROUTES . WORKSPACE_REPORT_FIELDS_LIST_VALUES . getRoute ( policyID , reportFieldID ) ) }
104
- />
105
- ) }
106
- { ! hasAccountingConnections && (
107
- < View style = { styles . flexGrow1 } >
108
- < MenuItem
109
- icon = { Expensicons . Trashcan }
110
- title = { translate ( 'common.delete' ) }
111
- onPress = { ( ) => setIsDeleteModalVisible ( true ) }
112
- />
113
- </ View >
114
- ) }
115
72
< ConfirmModal
116
73
title = { translate ( 'workspace.reportFields.delete' ) }
117
74
isVisible = { isDeleteModalVisible && ! hasAccountingConnections }
@@ -123,6 +80,51 @@ function ReportFieldsSettingsPage({
123
80
cancelText = { translate ( 'common.cancel' ) }
124
81
danger
125
82
/>
83
+ < View style = { styles . flexGrow1 } >
84
+ < MenuItemWithTopDescription
85
+ style = { [ styles . moneyRequestMenuItem ] }
86
+ titleStyle = { styles . flex1 }
87
+ title = { reportField . name }
88
+ description = { translate ( 'common.name' ) }
89
+ interactive = { false }
90
+ />
91
+ < MenuItemWithTopDescription
92
+ style = { [ styles . moneyRequestMenuItem ] }
93
+ titleStyle = { styles . flex1 }
94
+ title = { Str . recapitalize ( translate ( WorkspaceReportFieldUtils . getReportFieldTypeTranslationKey ( reportField . type ) ) ) }
95
+ description = { translate ( 'common.type' ) }
96
+ interactive = { false }
97
+ />
98
+ { ! isListFieldEmpty && (
99
+ < MenuItemWithTopDescription
100
+ style = { [ styles . moneyRequestMenuItem ] }
101
+ titleStyle = { styles . flex1 }
102
+ title = { WorkspaceReportFieldUtils . getReportFieldInitialValue ( reportField ) }
103
+ description = { translate ( 'common.initialValue' ) }
104
+ shouldShowRightIcon = { ! isDateFieldType && ! hasAccountingConnections }
105
+ interactive = { ! isDateFieldType && ! hasAccountingConnections }
106
+ onPress = { ( ) => Navigation . navigate ( ROUTES . WORKSPACE_EDIT_REPORT_FIELDS_INITIAL_VALUE . getRoute ( policyID , reportFieldID ) ) }
107
+ />
108
+ ) }
109
+ { isListFieldType && (
110
+ < MenuItemWithTopDescription
111
+ style = { [ styles . moneyRequestMenuItem ] }
112
+ titleStyle = { styles . flex1 }
113
+ description = { translate ( 'workspace.reportFields.listValues' ) }
114
+ shouldShowRightIcon
115
+ onPress = { ( ) => Navigation . navigate ( ROUTES . WORKSPACE_REPORT_FIELDS_LIST_VALUES . getRoute ( policyID , reportFieldID ) ) }
116
+ />
117
+ ) }
118
+ { ! hasAccountingConnections && (
119
+ < View style = { styles . flexGrow1 } >
120
+ < MenuItem
121
+ icon = { Expensicons . Trashcan }
122
+ title = { translate ( 'common.delete' ) }
123
+ onPress = { ( ) => setIsDeleteModalVisible ( true ) }
124
+ />
125
+ </ View >
126
+ ) }
127
+ </ View >
126
128
</ ScreenWrapper >
127
129
</ AccessOrNotFoundWrapper >
128
130
) ;
0 commit comments