@dashadmin/dash-admin 1.3.50 → 1.3.52
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/avatar/Avatar.js +10 -1
- package/dist/components/currency/Format.js +3 -1
- package/dist/components/i18n/BridgedLocalesMenuButton.js +4 -2
- package/dist/components/misc/NoResults.js +3 -1
- package/dist/components/permission/PermissionsSelector.js +34 -14
- package/dist/components/permission/PermissionsSelectorList.js +11 -1
- package/dist/components/selects/RASearchableSelect.js +8 -6
- package/dist/components/selects/RASearchableSelectChips.js +8 -6
- package/dist/components/selects/SearchableSelect.js +8 -6
- package/dist/components/subscription/PlanAddonsSettings.js +88 -17
- package/dist/components/subscription/PlanAuditLog.js +41 -21
- package/dist/components/subscription/PlanFeaturesSettings.js +35 -6
- package/dist/components/subscription/PlanMetadataSettings.js +78 -42
- package/dist/components/subscription/PlanPricesSettings.js +20 -8
- package/dist/components/tenant/TenantSelector.js +8 -6
- package/dist/components/user/UserPreferences.js +77 -22
- package/dist/default-theme/DashThemeContext.js +3 -8
- package/dist/pages/DASHLightWeightLogin.js +7 -5
- package/dist/pages/Profile.js +5 -3
- package/dist/pages/RecoverPassword.js +28 -14
- package/dist/schemas/subscription/components/SubscriptionPaymentHistory.js +14 -2
- package/dist/schemas/subscription/components/SubscriptionPlanFeatures.js +37 -25
- package/dist/schemas/subscription/components/SubscriptionPlanPreview.js +47 -28
- package/dist/schemas/subscription/components/SubscriptionPlanStats.js +127 -37
- package/package.json +3 -3
- package/src/DASHAdmin.tsx +1 -0
- package/src/components/avatar/Avatar.tsx +8 -4
- package/src/components/currency/Format.tsx +8 -6
- package/src/components/i18n/BridgedLocalesMenuButton.tsx +4 -2
- package/src/components/misc/DASHGlobalErrorHandler.tsx +1 -1
- package/src/components/misc/NoResults.tsx +7 -4
- package/src/components/permission/AvailablePermissionsContext.tsx +1 -1
- package/src/components/permission/PermissionsSelector.tsx +48 -33
- package/src/components/permission/PermissionsSelectorList.tsx +7 -2
- package/src/components/selects/RASearchableSelect.tsx +22 -19
- package/src/components/selects/RASearchableSelectChips.tsx +23 -19
- package/src/components/selects/SearchableSelect.tsx +22 -18
- package/src/components/subscription/PlanAddonsSettings.tsx +61 -20
- package/src/components/subscription/PlanAuditLog.tsx +22 -8
- package/src/components/subscription/PlanFeaturesSettings.tsx +28 -8
- package/src/components/subscription/PlanMetadataSettings.tsx +29 -7
- package/src/components/subscription/PlanPricesSettings.tsx +30 -18
- package/src/components/tenant/TenantAttributesContext.tsx +1 -1
- package/src/components/tenant/TenantSelector.tsx +20 -17
- package/src/components/tenant/TenantSettingsContext.tsx +1 -1
- package/src/components/user/UserPreferences.tsx +56 -21
- package/src/contexts/SystemRequestsCache.tsx +1 -1
- package/src/default-theme/DASHAppProviders.tsx +1 -1
- package/src/default-theme/DashThemeContext.tsx +5 -14
- package/src/default-theme/menu/AppMenuComponents/expanded/CollapsableSidebarMenu.tsx +3 -3
- package/src/default-theme/menu/SidebarActions.tsx +6 -6
- package/src/pages/DASHLightWeightLogin.tsx +8 -7
- package/src/pages/Profile.tsx +10 -9
- package/src/pages/RecoverPassword.tsx +15 -6
- package/src/schemas/subscription/components/SubscriptionPaymentHistory.tsx +9 -2
- package/src/schemas/subscription/components/SubscriptionPlanFeatures.tsx +10 -3
- package/src/schemas/subscription/components/SubscriptionPlanPreview.tsx +25 -12
- package/src/schemas/subscription/components/SubscriptionPlanStats.tsx +64 -14
- package/src/theme/AppSidebarLogo.tsx +7 -7
|
@@ -94,7 +94,9 @@ const PermissionsSelectorView: React.FC<IDashAutoAdminCustomFieldComponent> = ({
|
|
|
94
94
|
if (!record?.permissions || record.permissions.length === 0) {
|
|
95
95
|
return (
|
|
96
96
|
<Box sx={{ p: 2, textAlign: 'center' }}>
|
|
97
|
-
<Typography variant="body2"
|
|
97
|
+
<Typography variant="body2" sx={{
|
|
98
|
+
color: "text.secondary"
|
|
99
|
+
}}>
|
|
98
100
|
No permissions assigned
|
|
99
101
|
</Typography>
|
|
100
102
|
</Box>
|
|
@@ -109,7 +111,7 @@ const PermissionsSelectorView: React.FC<IDashAutoAdminCustomFieldComponent> = ({
|
|
|
109
111
|
<Grid container spacing={3}>
|
|
110
112
|
{permissions?.map((tab, index) => (
|
|
111
113
|
/* @ts-ignore */
|
|
112
|
-
<Grid item xs={12} sm={6} md={4} lg={3} key={index}>
|
|
114
|
+
(<Grid item xs={12} sm={6} md={4} lg={3} key={index}>
|
|
113
115
|
<Card
|
|
114
116
|
variant="outlined"
|
|
115
117
|
sx={{
|
|
@@ -138,7 +140,7 @@ const PermissionsSelectorView: React.FC<IDashAutoAdminCustomFieldComponent> = ({
|
|
|
138
140
|
</Stack>
|
|
139
141
|
</CardContent>
|
|
140
142
|
</Card>
|
|
141
|
-
</Grid>
|
|
143
|
+
</Grid>)
|
|
142
144
|
))}
|
|
143
145
|
</Grid>
|
|
144
146
|
</Box>
|
|
@@ -533,19 +535,21 @@ const PermissionsSelectorBase: React.FC<IDashAutoAdminCustomFieldComponent & { r
|
|
|
533
535
|
placeholder="e.g., user, admin, system..."
|
|
534
536
|
value={groupSearchTerm}
|
|
535
537
|
onChange={e => setGroupSearchTerm(e.target.value)}
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
<
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
<
|
|
545
|
-
<
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
538
|
+
slotProps={{
|
|
539
|
+
input: {
|
|
540
|
+
startAdornment: (
|
|
541
|
+
<InputAdornment position="start">
|
|
542
|
+
<SearchIcon color="action" />
|
|
543
|
+
</InputAdornment>
|
|
544
|
+
),
|
|
545
|
+
endAdornment: groupSearchTerm && (
|
|
546
|
+
<InputAdornment position="end">
|
|
547
|
+
<IconButton size="small" onClick={handleClearGroupSearch}>
|
|
548
|
+
<ClearIcon fontSize="small" />
|
|
549
|
+
</IconButton>
|
|
550
|
+
</InputAdornment>
|
|
551
|
+
)
|
|
552
|
+
}
|
|
549
553
|
}}
|
|
550
554
|
/>
|
|
551
555
|
</Grid>
|
|
@@ -558,26 +562,30 @@ const PermissionsSelectorBase: React.FC<IDashAutoAdminCustomFieldComponent & { r
|
|
|
558
562
|
placeholder="e.g., create, edit, delete, view..."
|
|
559
563
|
value={itemSearchTerm}
|
|
560
564
|
onChange={e => setItemSearchTerm(e.target.value)}
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
<
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
<
|
|
570
|
-
<
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
565
|
+
slotProps={{
|
|
566
|
+
input: {
|
|
567
|
+
startAdornment: (
|
|
568
|
+
<InputAdornment position="start">
|
|
569
|
+
<SearchIcon color="action" />
|
|
570
|
+
</InputAdornment>
|
|
571
|
+
),
|
|
572
|
+
endAdornment: itemSearchTerm && (
|
|
573
|
+
<InputAdornment position="end">
|
|
574
|
+
<IconButton size="small" onClick={handleClearItemSearch}>
|
|
575
|
+
<ClearIcon fontSize="small" />
|
|
576
|
+
</IconButton>
|
|
577
|
+
</InputAdornment>
|
|
578
|
+
)
|
|
579
|
+
}
|
|
574
580
|
}}
|
|
575
581
|
/>
|
|
576
582
|
</Grid>
|
|
577
583
|
</Grid>
|
|
578
584
|
{hasActiveSearch && (
|
|
579
585
|
<Box sx={{ mt: 2, p: 2, bgcolor: 'action.hover', borderRadius: 1 }}>
|
|
580
|
-
<Typography variant="body2"
|
|
586
|
+
<Typography variant="body2" sx={{
|
|
587
|
+
color: "text.secondary"
|
|
588
|
+
}}>
|
|
581
589
|
<strong>Search Results:</strong> {filteredGroupsCount} group{filteredGroupsCount !== 1 ? 's' : ''}
|
|
582
590
|
{' '}({totalFilteredItems} permission{totalFilteredItems !== 1 ? 's' : ''})
|
|
583
591
|
{' '}of {permissionsData.length} total groups ({totalPermissions} total permissions)
|
|
@@ -606,10 +614,17 @@ const PermissionsSelectorBase: React.FC<IDashAutoAdminCustomFieldComponent & { r
|
|
|
606
614
|
borderColor: 'divider'
|
|
607
615
|
}}>
|
|
608
616
|
<SearchIcon sx={{ fontSize: 48, color: 'text.disabled', mb: 2 }} />
|
|
609
|
-
<Typography variant="h6"
|
|
617
|
+
<Typography variant="h6" gutterBottom sx={{
|
|
618
|
+
color: "text.secondary"
|
|
619
|
+
}}>
|
|
610
620
|
No permissions found
|
|
611
621
|
</Typography>
|
|
612
|
-
<Typography
|
|
622
|
+
<Typography
|
|
623
|
+
variant="body2"
|
|
624
|
+
sx={{
|
|
625
|
+
color: "text.disabled",
|
|
626
|
+
mb: 2
|
|
627
|
+
}}>
|
|
613
628
|
No permissions match your search criteria
|
|
614
629
|
{debouncedGroupSearch && ` for group "${debouncedGroupSearch}"`}
|
|
615
630
|
{debouncedItemSearch && ` for permission "${debouncedItemSearch}"`}
|
|
@@ -638,7 +653,7 @@ const PermissionsSelectorBase: React.FC<IDashAutoAdminCustomFieldComponent & { r
|
|
|
638
653
|
const visibleItems = isExpanded ? group : group.slice(0, INITIAL_ITEMS_COUNT);
|
|
639
654
|
const remainingCount = group.length - INITIAL_ITEMS_COUNT;
|
|
640
655
|
return (
|
|
641
|
-
/* @ts-ignore */
|
|
656
|
+
/* @ts-ignore */
|
|
642
657
|
<Grid item xs={12} md={4} key={groupIndex}>
|
|
643
658
|
<Card variant="outlined" sx={{
|
|
644
659
|
height: '100%',
|
|
@@ -305,7 +305,7 @@ const PermissionsSelectorListBase: React.FC<IDashAutoAdminCustomFieldComponent &
|
|
|
305
305
|
|
|
306
306
|
return (
|
|
307
307
|
<Box sx={{ p: 2 }}>
|
|
308
|
-
|
|
308
|
+
|
|
309
309
|
{/* Global Toolbar */}
|
|
310
310
|
<Paper elevation={1} sx={{ mb: 3, p: 2 }}>
|
|
311
311
|
<Box sx={{ display: 'flex', justifyContent: 'space-between', alignItems: 'center', mb: 2 }}>
|
|
@@ -418,7 +418,12 @@ const PermissionsSelectorListBase: React.FC<IDashAutoAdminCustomFieldComponent &
|
|
|
418
418
|
) : (
|
|
419
419
|
<TableRow>
|
|
420
420
|
<TableCell colSpan={4} align="center">
|
|
421
|
-
<Typography
|
|
421
|
+
<Typography
|
|
422
|
+
variant="body2"
|
|
423
|
+
sx={{
|
|
424
|
+
color: "text.secondary",
|
|
425
|
+
py: 3
|
|
426
|
+
}}>
|
|
422
427
|
No permissions found
|
|
423
428
|
</Typography>
|
|
424
429
|
</TableCell>
|
|
@@ -128,8 +128,8 @@ const SearchableSelect: React.FC<ISearchableSelect> = ({
|
|
|
128
128
|
};
|
|
129
129
|
|
|
130
130
|
return (
|
|
131
|
-
|
|
132
|
-
|
|
131
|
+
<>
|
|
132
|
+
{parsedOptions && (
|
|
133
133
|
<Autocomplete
|
|
134
134
|
key={'autocomplete-' + attribute.attribute}
|
|
135
135
|
multiple={isMultiple}
|
|
@@ -215,7 +215,7 @@ const SearchableSelect: React.FC<ISearchableSelect> = ({
|
|
|
215
215
|
renderInput={(params) => {
|
|
216
216
|
console.log('renderInput', params.id);
|
|
217
217
|
return (
|
|
218
|
-
|
|
218
|
+
<TextField
|
|
219
219
|
key={params.id}
|
|
220
220
|
{...params}
|
|
221
221
|
label={selectLabel}
|
|
@@ -236,26 +236,29 @@ const SearchableSelect: React.FC<ISearchableSelect> = ({
|
|
|
236
236
|
setQ(ev.target.value);
|
|
237
237
|
}*/
|
|
238
238
|
}}
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
239
|
+
slotProps={{
|
|
240
|
+
...params.slotProps,
|
|
241
|
+
|
|
242
|
+
input: {
|
|
243
|
+
...params.slotProps.input,
|
|
244
|
+
autoComplete: 'new-password',
|
|
245
|
+
endAdornment: (
|
|
246
|
+
<>
|
|
247
|
+
{isLoading ? (
|
|
248
|
+
<CircularProgress color='inherit' size={20} />
|
|
249
|
+
) : null}
|
|
250
|
+
{params.slotProps.input.endAdornment}
|
|
251
|
+
</>
|
|
252
|
+
),
|
|
253
|
+
}
|
|
254
|
+
}}
|
|
252
255
|
/>
|
|
253
|
-
|
|
256
|
+
);
|
|
254
257
|
}}
|
|
255
258
|
/>
|
|
256
259
|
)}
|
|
257
|
-
|
|
258
|
-
|
|
260
|
+
</>
|
|
261
|
+
);
|
|
259
262
|
};
|
|
260
263
|
|
|
261
264
|
const RASearchableSelect = ({
|
|
@@ -195,8 +195,8 @@ export const SearchableSelectChipsControl: React.FC<
|
|
|
195
195
|
}, [parsedOptions])*/
|
|
196
196
|
|
|
197
197
|
return (
|
|
198
|
-
|
|
199
|
-
|
|
198
|
+
<>
|
|
199
|
+
{parsedOptions ? (
|
|
200
200
|
<Autocomplete
|
|
201
201
|
key={'autocomplete-' + attribute.attribute}
|
|
202
202
|
multiple={isMultiple}
|
|
@@ -232,7 +232,7 @@ export const SearchableSelectChipsControl: React.FC<
|
|
|
232
232
|
}}
|
|
233
233
|
renderInput={(params) => {
|
|
234
234
|
return (
|
|
235
|
-
|
|
235
|
+
<TextField
|
|
236
236
|
key={params.id}
|
|
237
237
|
{...params}
|
|
238
238
|
label={selectLabel}
|
|
@@ -246,35 +246,39 @@ export const SearchableSelectChipsControl: React.FC<
|
|
|
246
246
|
)
|
|
247
247
|
debounce(() => setQ(searchValue), timerSearch);
|
|
248
248
|
}}
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
249
|
+
slotProps={{
|
|
250
|
+
...params.slotProps,
|
|
251
|
+
|
|
252
|
+
input: {
|
|
253
|
+
...params.slotProps.input,
|
|
254
|
+
autoComplete: 'new-password',
|
|
255
|
+
endAdornment: (
|
|
256
|
+
<>
|
|
257
|
+
{isResourceSearchLoading ? (
|
|
258
|
+
<CircularProgress color='inherit' size={20} />
|
|
259
|
+
) : null}
|
|
260
|
+
{params.slotProps.input.endAdornment}
|
|
261
|
+
</>
|
|
262
|
+
),
|
|
263
|
+
}
|
|
264
|
+
}}
|
|
261
265
|
/>
|
|
262
|
-
|
|
266
|
+
);
|
|
263
267
|
}}
|
|
264
268
|
/>
|
|
265
269
|
) : (
|
|
266
270
|
<LoadingIndicator />
|
|
267
271
|
)}
|
|
268
272
|
|
|
269
|
-
|
|
273
|
+
{!isMultiple && parsedOptions && _defaultValues && (
|
|
270
274
|
<>
|
|
271
275
|
<Chip
|
|
272
276
|
label={renderText(_transformOption(_defaultValues, 'chip'), 'chip')}
|
|
273
277
|
/>
|
|
274
278
|
</>
|
|
275
279
|
)}
|
|
276
|
-
|
|
277
|
-
|
|
280
|
+
</>
|
|
281
|
+
);
|
|
278
282
|
};
|
|
279
283
|
|
|
280
284
|
const RASearchableSelectChips: React.FC<
|
|
@@ -59,10 +59,10 @@ const SearchableSelect: React.FC<any> = ({
|
|
|
59
59
|
// console.log(field.field.value);
|
|
60
60
|
|
|
61
61
|
return (
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
62
|
+
<>
|
|
63
|
+
<InputLabel>{title}</InputLabel>
|
|
64
|
+
{/*<SearchBar />*/}
|
|
65
|
+
{TrendingUpRounded && (
|
|
66
66
|
<Autocomplete
|
|
67
67
|
multiple={isMultiple}
|
|
68
68
|
loading={isLoading && open}
|
|
@@ -112,24 +112,28 @@ const SearchableSelect: React.FC<any> = ({
|
|
|
112
112
|
}
|
|
113
113
|
}}
|
|
114
114
|
onBlur={() => setQ('')}
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
115
|
+
slotProps={{
|
|
116
|
+
...params.slotProps,
|
|
117
|
+
|
|
118
|
+
input: {
|
|
119
|
+
...params.slotProps.input,
|
|
120
|
+
autoComplete: 'new-password',
|
|
121
|
+
endAdornment: (
|
|
122
|
+
<>
|
|
123
|
+
{isLoading ? (
|
|
124
|
+
<CircularProgress color='inherit' size={20} />
|
|
125
|
+
) : null}
|
|
126
|
+
{params.slotProps.input.endAdornment}
|
|
127
|
+
</>
|
|
128
|
+
),
|
|
129
|
+
}
|
|
130
|
+
}}
|
|
127
131
|
/>
|
|
128
132
|
)}
|
|
129
133
|
/>
|
|
130
134
|
)}
|
|
131
|
-
|
|
132
|
-
|
|
135
|
+
</>
|
|
136
|
+
);
|
|
133
137
|
};
|
|
134
138
|
|
|
135
139
|
export default SearchableSelect;
|
|
@@ -128,7 +128,9 @@ const AddonRow: React.FC<AddonRowProps> = ({ addonId, entry, plan, mode }) => {
|
|
|
128
128
|
transition: 'border-color 0.3s'
|
|
129
129
|
}}
|
|
130
130
|
>
|
|
131
|
-
<Grid container spacing={2}
|
|
131
|
+
<Grid container spacing={2} sx={{
|
|
132
|
+
alignItems: "flex-start"
|
|
133
|
+
}}>
|
|
132
134
|
{/* Toggle and Label */}
|
|
133
135
|
<Grid item xs={12} md={4}>
|
|
134
136
|
<Controller
|
|
@@ -150,12 +152,16 @@ const AddonRow: React.FC<AddonRowProps> = ({ addonId, entry, plan, mode }) => {
|
|
|
150
152
|
}
|
|
151
153
|
label={
|
|
152
154
|
<Box>
|
|
153
|
-
<Typography variant="subtitle1"
|
|
155
|
+
<Typography variant="subtitle1" sx={{
|
|
156
|
+
fontWeight: "medium"
|
|
157
|
+
}}>
|
|
154
158
|
{entry.icon && <span style={{ marginRight: 8 }}>{entry.icon}</span>}
|
|
155
159
|
{entry.label}
|
|
156
160
|
</Typography>
|
|
157
161
|
{entry.description && (
|
|
158
|
-
<Typography variant="caption"
|
|
162
|
+
<Typography variant="caption" sx={{
|
|
163
|
+
color: "text.secondary"
|
|
164
|
+
}}>
|
|
159
165
|
{entry.description}
|
|
160
166
|
</Typography>
|
|
161
167
|
)}
|
|
@@ -195,17 +201,19 @@ const AddonRow: React.FC<AddonRowProps> = ({ addonId, entry, plan, mode }) => {
|
|
|
195
201
|
type="text"
|
|
196
202
|
size="small"
|
|
197
203
|
disabled={isReadOnly}
|
|
198
|
-
InputProps={{
|
|
199
|
-
startAdornment: (
|
|
200
|
-
<InputAdornment position="start">
|
|
201
|
-
{config.symbol}
|
|
202
|
-
</InputAdornment>
|
|
203
|
-
),
|
|
204
|
-
}}
|
|
205
204
|
sx={{ width: 150 }}
|
|
206
205
|
value={formatPrice(field.value ?? 0, currency)}
|
|
207
206
|
onChange={(e) => handlePriceChange(currency, e.target.value)}
|
|
208
207
|
helperText={config.name}
|
|
208
|
+
slotProps={{
|
|
209
|
+
input: {
|
|
210
|
+
startAdornment: (
|
|
211
|
+
<InputAdornment position="start">
|
|
212
|
+
{config.symbol}
|
|
213
|
+
</InputAdornment>
|
|
214
|
+
),
|
|
215
|
+
}
|
|
216
|
+
}}
|
|
209
217
|
/>
|
|
210
218
|
)}
|
|
211
219
|
/>
|
|
@@ -213,7 +221,13 @@ const AddonRow: React.FC<AddonRowProps> = ({ addonId, entry, plan, mode }) => {
|
|
|
213
221
|
})}
|
|
214
222
|
</Box>
|
|
215
223
|
{plan?.flow_addon_items?.[addonId] && (
|
|
216
|
-
<Typography
|
|
224
|
+
<Typography
|
|
225
|
+
variant="caption"
|
|
226
|
+
sx={{
|
|
227
|
+
color: "text.secondary",
|
|
228
|
+
mt: 1,
|
|
229
|
+
display: 'block'
|
|
230
|
+
}}>
|
|
217
231
|
Flow Item ID: {plan.flow_addon_items[addonId]}
|
|
218
232
|
</Typography>
|
|
219
233
|
)}
|
|
@@ -279,13 +293,23 @@ const PlanAddonsSettingsEdit: React.FC<IDashAutoAdminCustomFieldComponent> = ({
|
|
|
279
293
|
<Typography variant="h6" gutterBottom>
|
|
280
294
|
Plan Add-ons Configuration
|
|
281
295
|
</Typography>
|
|
282
|
-
<Typography
|
|
296
|
+
<Typography
|
|
297
|
+
variant="body2"
|
|
298
|
+
sx={{
|
|
299
|
+
color: "text.secondary",
|
|
300
|
+
mb: 3
|
|
301
|
+
}}>
|
|
283
302
|
Enable add-ons and set prices per currency. Prices are in the smallest currency unit (e.g., cents for USD, pesos for CLP).
|
|
284
303
|
</Typography>
|
|
285
|
-
|
|
304
|
+
|
|
286
305
|
{Object.entries(groupedByTab).map(([tabName, entries]) => (
|
|
287
306
|
<Box key={tabName} sx={{ mb: 4 }}>
|
|
288
|
-
<Typography
|
|
307
|
+
<Typography
|
|
308
|
+
variant="subtitle1"
|
|
309
|
+
sx={{
|
|
310
|
+
fontWeight: "bold",
|
|
311
|
+
mb: 2
|
|
312
|
+
}}>
|
|
289
313
|
{tabName}
|
|
290
314
|
</Typography>
|
|
291
315
|
<Divider sx={{ mb: 2 }} />
|
|
@@ -360,13 +384,23 @@ const PlanAddonsSettingsCreate: React.FC<IDashAutoAdminCustomFieldComponent> = (
|
|
|
360
384
|
<Typography variant="h6" gutterBottom>
|
|
361
385
|
Plan Add-ons Configuration
|
|
362
386
|
</Typography>
|
|
363
|
-
<Typography
|
|
387
|
+
<Typography
|
|
388
|
+
variant="body2"
|
|
389
|
+
sx={{
|
|
390
|
+
color: "text.secondary",
|
|
391
|
+
mb: 3
|
|
392
|
+
}}>
|
|
364
393
|
Enable add-ons and set prices per currency. Prices are in the smallest currency unit.
|
|
365
394
|
</Typography>
|
|
366
|
-
|
|
395
|
+
|
|
367
396
|
{Object.entries(groupedByTab).map(([tabName, entries]) => (
|
|
368
397
|
<Box key={tabName} sx={{ mb: 4 }}>
|
|
369
|
-
<Typography
|
|
398
|
+
<Typography
|
|
399
|
+
variant="subtitle1"
|
|
400
|
+
sx={{
|
|
401
|
+
fontWeight: "bold",
|
|
402
|
+
mb: 2
|
|
403
|
+
}}>
|
|
370
404
|
{tabName}
|
|
371
405
|
</Typography>
|
|
372
406
|
<Divider sx={{ mb: 2 }} />
|
|
@@ -416,10 +450,15 @@ const PlanAddonsSettingsView: React.FC<IDashAutoAdminCustomFieldComponent> = ({
|
|
|
416
450
|
<Typography variant="h6" gutterBottom>
|
|
417
451
|
Plan Add-ons
|
|
418
452
|
</Typography>
|
|
419
|
-
|
|
453
|
+
|
|
420
454
|
{Object.entries(groupedByTab).map(([tabName, entries]) => (
|
|
421
455
|
<Box key={tabName} sx={{ mb: 3 }}>
|
|
422
|
-
<Typography
|
|
456
|
+
<Typography
|
|
457
|
+
variant="subtitle1"
|
|
458
|
+
sx={{
|
|
459
|
+
fontWeight: "bold",
|
|
460
|
+
mb: 2
|
|
461
|
+
}}>
|
|
423
462
|
{tabName}
|
|
424
463
|
</Typography>
|
|
425
464
|
<Divider sx={{ mb: 2 }} />
|
|
@@ -468,7 +507,9 @@ const PlanAddonsSettingsView: React.FC<IDashAutoAdminCustomFieldComponent> = ({
|
|
|
468
507
|
);
|
|
469
508
|
})}
|
|
470
509
|
{flowItemId && (
|
|
471
|
-
<Typography variant="caption"
|
|
510
|
+
<Typography variant="caption" sx={{
|
|
511
|
+
color: "text.secondary"
|
|
512
|
+
}}>
|
|
472
513
|
Flow ID: {flowItemId}
|
|
473
514
|
</Typography>
|
|
474
515
|
)}
|
|
@@ -114,7 +114,12 @@ const JsonDialog: React.FC<JsonDialogProps> = ({ open, log, onClose }) => {
|
|
|
114
114
|
aria-labelledby="audit-log-dialog-title"
|
|
115
115
|
>
|
|
116
116
|
<DialogTitle id="audit-log-dialog-title">
|
|
117
|
-
<Box
|
|
117
|
+
<Box
|
|
118
|
+
sx={{
|
|
119
|
+
display: "flex",
|
|
120
|
+
justifyContent: "space-between",
|
|
121
|
+
alignItems: "center"
|
|
122
|
+
}}>
|
|
118
123
|
<Typography variant="h6">
|
|
119
124
|
Audit Log Details - {log.event || log.description}
|
|
120
125
|
</Typography>
|
|
@@ -129,7 +134,9 @@ const JsonDialog: React.FC<JsonDialogProps> = ({ open, log, onClose }) => {
|
|
|
129
134
|
</Box>
|
|
130
135
|
</DialogTitle>
|
|
131
136
|
<DialogContent dividers>
|
|
132
|
-
<Box
|
|
137
|
+
<Box sx={{
|
|
138
|
+
mb: 2
|
|
139
|
+
}}>
|
|
133
140
|
<Typography variant="subtitle2" color="textSecondary">
|
|
134
141
|
Event Information
|
|
135
142
|
</Typography>
|
|
@@ -318,7 +325,9 @@ const PlanAuditLogView: React.FC<IDashAutoAdminCustomFieldComponent> = ({ resour
|
|
|
318
325
|
return (
|
|
319
326
|
<Paper variant="outlined" sx={{ p: 3, textAlign: 'center' }}>
|
|
320
327
|
<HistoryIcon sx={{ fontSize: 48, color: 'text.secondary', mb: 1 }} />
|
|
321
|
-
<Typography variant="body1"
|
|
328
|
+
<Typography variant="body1" sx={{
|
|
329
|
+
color: "text.secondary"
|
|
330
|
+
}}>
|
|
322
331
|
Save the record first to view audit logs
|
|
323
332
|
</Typography>
|
|
324
333
|
</Paper>
|
|
@@ -343,7 +352,9 @@ const PlanAuditLogView: React.FC<IDashAutoAdminCustomFieldComponent> = ({ resour
|
|
|
343
352
|
return (
|
|
344
353
|
<Paper variant="outlined" sx={{ p: 3, textAlign: 'center' }}>
|
|
345
354
|
<HistoryIcon sx={{ fontSize: 48, color: 'text.secondary', mb: 1 }} />
|
|
346
|
-
<Typography variant="body1"
|
|
355
|
+
<Typography variant="body1" sx={{
|
|
356
|
+
color: "text.secondary"
|
|
357
|
+
}}>
|
|
347
358
|
No audit logs available for this record
|
|
348
359
|
</Typography>
|
|
349
360
|
</Paper>
|
|
@@ -402,9 +413,10 @@ const PlanAuditLogList: React.FC<IDashAutoAdminCustomFieldComponent> = () => {
|
|
|
402
413
|
// For list mode, we just show a placeholder
|
|
403
414
|
// Audit logs are typically viewed in the detail/edit view
|
|
404
415
|
return (
|
|
405
|
-
<Typography variant="body2"
|
|
406
|
-
|
|
407
|
-
|
|
416
|
+
<Typography variant="body2" sx={{
|
|
417
|
+
color: "text.secondary"
|
|
418
|
+
}}>—
|
|
419
|
+
</Typography>
|
|
408
420
|
);
|
|
409
421
|
};
|
|
410
422
|
|
|
@@ -426,7 +438,9 @@ const PlanAuditLog: React.FC<IDashAutoAdminCustomFieldComponent> = (props) => {
|
|
|
426
438
|
return (
|
|
427
439
|
<Paper variant="outlined" sx={{ p: 3, textAlign: 'center' }}>
|
|
428
440
|
<HistoryIcon sx={{ fontSize: 48, color: 'text.secondary', mb: 1 }} />
|
|
429
|
-
<Typography variant="body1"
|
|
441
|
+
<Typography variant="body1" sx={{
|
|
442
|
+
color: "text.secondary"
|
|
443
|
+
}}>
|
|
430
444
|
Audit logs will be available after the record is created
|
|
431
445
|
</Typography>
|
|
432
446
|
</Paper>
|