@crystaldesign/diva-backoffice 24.2.1 → 24.2.2-beta.0
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/build/esm/index.js
CHANGED
|
@@ -2054,7 +2054,37 @@ function loadConfiguration(t, root, config, lang) {
|
|
|
2054
2054
|
}],
|
|
2055
2055
|
title: t('backoffice.table.allusers.roleselector.title'),
|
|
2056
2056
|
label: t('backoffice.table.allusers.roleselector.features')
|
|
2057
|
-
}
|
|
2057
|
+
}, {
|
|
2058
|
+
actionType: 'Modal',
|
|
2059
|
+
title: t('backoffice.table.allusers.modal.title.aktivateuser'),
|
|
2060
|
+
text: t('backoffice.table.allusers.modal.text11'),
|
|
2061
|
+
label: t('backoffice.table.allusers.modal.label.aktivate'),
|
|
2062
|
+
type: 'Form',
|
|
2063
|
+
id: 'FormActivateUser',
|
|
2064
|
+
mapping: {
|
|
2065
|
+
type: 'body',
|
|
2066
|
+
map: [{
|
|
2067
|
+
sourceField: '_id',
|
|
2068
|
+
targetField: 'id'
|
|
2069
|
+
}, {
|
|
2070
|
+
sourceValue: window.location.origin,
|
|
2071
|
+
targetField: 'redirectTo'
|
|
2072
|
+
}]
|
|
2073
|
+
},
|
|
2074
|
+
rule: [{
|
|
2075
|
+
match: {
|
|
2076
|
+
sourceField: 'isActive',
|
|
2077
|
+
value: false
|
|
2078
|
+
}
|
|
2079
|
+
}]
|
|
2080
|
+
}],
|
|
2081
|
+
createAction: {
|
|
2082
|
+
actionType: 'Detail',
|
|
2083
|
+
type: 'Form',
|
|
2084
|
+
id: 'FormUserDetails',
|
|
2085
|
+
title: t('backoffice.table.allusers.createaction.title.userdetails'),
|
|
2086
|
+
permission: 'backoffice_admin_users'
|
|
2087
|
+
}
|
|
2058
2088
|
},
|
|
2059
2089
|
TableAllOrganizations: {
|
|
2060
2090
|
type: 'Table',
|
|
@@ -3976,6 +4006,15 @@ function loadConfiguration(t, root, config, lang) {
|
|
|
3976
4006
|
targetField: 'organizationId'
|
|
3977
4007
|
}]
|
|
3978
4008
|
},
|
|
4009
|
+
createAction: {
|
|
4010
|
+
actionType: 'Detail',
|
|
4011
|
+
type: 'SelectOrCreate',
|
|
4012
|
+
id: 'SelectOrCreateNewMember',
|
|
4013
|
+
title: t('backoffice.table.allorgusers.createAction.title'),
|
|
4014
|
+
label: t('backoffice.table.allorgusers.createAction.title'),
|
|
4015
|
+
disableOnToggle: true,
|
|
4016
|
+
permission: 'backoffice_create_user'
|
|
4017
|
+
},
|
|
3979
4018
|
downloadAction: {
|
|
3980
4019
|
actionType: 'CsvExport',
|
|
3981
4020
|
fileName: 'benutzer'
|
|
@@ -4007,6 +4046,30 @@ function loadConfiguration(t, root, config, lang) {
|
|
|
4007
4046
|
sourceField: 'phoneNumber'
|
|
4008
4047
|
}]
|
|
4009
4048
|
}
|
|
4049
|
+
}, {
|
|
4050
|
+
actionType: 'Modal',
|
|
4051
|
+
title: t('backoffice.table.allorgusers.rowAction.title.aktivateuser'),
|
|
4052
|
+
text: t('backoffice.table.allorgusers.rowAction.text'),
|
|
4053
|
+
label: t('backoffice.table.allorgusers.rowAction.lable.aktivate'),
|
|
4054
|
+
type: 'Form',
|
|
4055
|
+
id: 'FormActivateUser',
|
|
4056
|
+
permission: 'backoffice_create_user',
|
|
4057
|
+
mapping: {
|
|
4058
|
+
type: 'body',
|
|
4059
|
+
map: [{
|
|
4060
|
+
sourceField: '_id',
|
|
4061
|
+
targetField: 'id'
|
|
4062
|
+
}, {
|
|
4063
|
+
sourceValue: window.location.origin,
|
|
4064
|
+
targetField: 'redirectTo'
|
|
4065
|
+
}]
|
|
4066
|
+
},
|
|
4067
|
+
rule: [{
|
|
4068
|
+
match: {
|
|
4069
|
+
sourceField: 'isActive',
|
|
4070
|
+
value: false
|
|
4071
|
+
}
|
|
4072
|
+
}]
|
|
4010
4073
|
}]
|
|
4011
4074
|
},
|
|
4012
4075
|
TableViewpoints: {
|
|
@@ -5213,8 +5276,7 @@ function loadConfiguration(t, root, config, lang) {
|
|
|
5213
5276
|
}, {
|
|
5214
5277
|
title: t('backoffice.table.idmimports.fullName'),
|
|
5215
5278
|
field: 'fullName',
|
|
5216
|
-
sorter: 6
|
|
5217
|
-
filter: 'advanced'
|
|
5279
|
+
sorter: 6
|
|
5218
5280
|
}, {
|
|
5219
5281
|
title: t('backoffice.table.idmimports.user.name'),
|
|
5220
5282
|
field: 'user.name',
|
|
@@ -5230,13 +5292,14 @@ function loadConfiguration(t, root, config, lang) {
|
|
|
5230
5292
|
field: 'startTime',
|
|
5231
5293
|
sorter: 3,
|
|
5232
5294
|
type: 'unixTimeStamp',
|
|
5233
|
-
filter: '
|
|
5295
|
+
filter: 'interval'
|
|
5234
5296
|
}, {
|
|
5235
5297
|
title: t('backoffice.table.idmimports.endTime'),
|
|
5236
5298
|
field: 'endTime',
|
|
5237
5299
|
type: 'unixTimeStamp',
|
|
5238
5300
|
sorter: 2,
|
|
5239
|
-
dateInSeconds: false
|
|
5301
|
+
dateInSeconds: false,
|
|
5302
|
+
filter: 'interval'
|
|
5240
5303
|
}, {
|
|
5241
5304
|
title: t('backoffice.table.idmimports.lastUpdated'),
|
|
5242
5305
|
field: 'lastUpdated',
|
|
@@ -5288,6 +5351,11 @@ function loadConfiguration(t, root, config, lang) {
|
|
|
5288
5351
|
title: t('backoffice.table.idmimports.fileName'),
|
|
5289
5352
|
field: 'fileName'
|
|
5290
5353
|
}],
|
|
5354
|
+
filter: {
|
|
5355
|
+
search: {
|
|
5356
|
+
fields: ['_id', 'user.name', 'user.familyName', 'state', 'stateMessage', 'fullProgress', 'organizationId', 'serverName', 'fileName']
|
|
5357
|
+
}
|
|
5358
|
+
},
|
|
5291
5359
|
apiInterface: {
|
|
5292
5360
|
read: {
|
|
5293
5361
|
list: '${catalogService}/idmImports',
|
|
@@ -6757,6 +6825,29 @@ function loadConfiguration(t, root, config, lang) {
|
|
|
6757
6825
|
}]
|
|
6758
6826
|
}
|
|
6759
6827
|
},
|
|
6828
|
+
FormActivateUser: {
|
|
6829
|
+
type: 'Form',
|
|
6830
|
+
apiInterface: {
|
|
6831
|
+
create: {
|
|
6832
|
+
url: '${authService}/v2/users/{id}/activate?redirectTo={redirectTo}',
|
|
6833
|
+
method: 'POST'
|
|
6834
|
+
}
|
|
6835
|
+
},
|
|
6836
|
+
items: [{
|
|
6837
|
+
name: 'id',
|
|
6838
|
+
hidden: true,
|
|
6839
|
+
readonly: true
|
|
6840
|
+
}, {
|
|
6841
|
+
name: 'redirectTo',
|
|
6842
|
+
label: t('backoffice.form.activateuser.items.redirectTo'),
|
|
6843
|
+
rules: [{
|
|
6844
|
+
pattern: new RegExp('((https?)://).*'),
|
|
6845
|
+
required: true,
|
|
6846
|
+
message: t('backoffice.form.activateuser.items.redirectTo.rules')
|
|
6847
|
+
}],
|
|
6848
|
+
type: 'input'
|
|
6849
|
+
}]
|
|
6850
|
+
},
|
|
6760
6851
|
FormApplicationTranslationsEdit: {
|
|
6761
6852
|
type: 'Form',
|
|
6762
6853
|
title: t('backoffice.form.applicationtranslationedit.title'),
|
|
@@ -8924,6 +9015,50 @@ function loadConfiguration(t, root, config, lang) {
|
|
|
8924
9015
|
}]
|
|
8925
9016
|
}
|
|
8926
9017
|
},
|
|
9018
|
+
SelectOrCreateNewMember: {
|
|
9019
|
+
type: 'SelectOrCreate',
|
|
9020
|
+
mode: 'single',
|
|
9021
|
+
apiInterface: {
|
|
9022
|
+
create: '${authService}/v2/organizations/{organizationId}/members/{userId}?roleId=seller',
|
|
9023
|
+
read: {
|
|
9024
|
+
list: '${authService}/v2/organizations/${organizationId}/members?all=true',
|
|
9025
|
+
filterServerSide: true,
|
|
9026
|
+
fallBackToParams: false,
|
|
9027
|
+
permissions: {
|
|
9028
|
+
backoffice_admin_users: '${authService}/v2/users'
|
|
9029
|
+
}
|
|
9030
|
+
}
|
|
9031
|
+
},
|
|
9032
|
+
readMapping: {
|
|
9033
|
+
type: 'query',
|
|
9034
|
+
map: [{
|
|
9035
|
+
targetField: 'organizationId',
|
|
9036
|
+
globalValue: 'selectedOrganizationId'
|
|
9037
|
+
}]
|
|
9038
|
+
},
|
|
9039
|
+
selectMapping: {
|
|
9040
|
+
label: 'mainEmail',
|
|
9041
|
+
value: '_id',
|
|
9042
|
+
searchField: [{
|
|
9043
|
+
field: 'mainEmail',
|
|
9044
|
+
filter: 'contains'
|
|
9045
|
+
}]
|
|
9046
|
+
},
|
|
9047
|
+
formId: 'FormUserDetails',
|
|
9048
|
+
actionMapping: {
|
|
9049
|
+
type: 'body',
|
|
9050
|
+
map: [{
|
|
9051
|
+
targetField: 'userId',
|
|
9052
|
+
sourceField: '_id'
|
|
9053
|
+
}, {
|
|
9054
|
+
targetField: 'organizationId',
|
|
9055
|
+
globalValue: 'selectedOrganizationId'
|
|
9056
|
+
}]
|
|
9057
|
+
},
|
|
9058
|
+
onError: {
|
|
9059
|
+
AUTH_0020: t('errorcodes._source.labels.error.AUTH_0020')
|
|
9060
|
+
}
|
|
9061
|
+
},
|
|
8927
9062
|
MediaUploadOrganizationLogoMobile: {
|
|
8928
9063
|
type: 'MediaUpload',
|
|
8929
9064
|
size: 'medium',
|
|
@@ -17673,6 +17808,10 @@ var TableWrapper = function TableWrapper(_ref) {
|
|
|
17673
17808
|
rules: state.configuration.downloadAction.rule
|
|
17674
17809
|
});
|
|
17675
17810
|
}
|
|
17811
|
+
function checkPermission(permission) {
|
|
17812
|
+
if (!permission) return true;
|
|
17813
|
+
return root.actions.userHasPermission(permission);
|
|
17814
|
+
}
|
|
17676
17815
|
return /*#__PURE__*/jsxs(Fragment, {
|
|
17677
17816
|
children: [(state.canDelete || state.configuration.createAction || state.title || state.configuration.canRefresh || state.configuration.clientRelations) && /*#__PURE__*/jsx(Fragment, {
|
|
17678
17817
|
children: /*#__PURE__*/jsx(Descriptions, {
|
|
@@ -17768,7 +17907,7 @@ var TableWrapper = function TableWrapper(_ref) {
|
|
|
17768
17907
|
action: action,
|
|
17769
17908
|
state: state
|
|
17770
17909
|
}, action.id);
|
|
17771
|
-
}), state.configuration.createAction && /*#__PURE__*/jsx(ActionButton, {
|
|
17910
|
+
}), state.configuration.createAction && checkPermission(state.configuration.createAction.permission) && /*#__PURE__*/jsx(ActionButton, {
|
|
17772
17911
|
action: state.configuration.createAction,
|
|
17773
17912
|
callback: function callback(data) {
|
|
17774
17913
|
var _state$onUpdate, _state$configuration$16, _state$configuration$17;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/Table/BaseTable/index.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAE,KAAK,EAAgB,MAAM,UAAU,CAAC;AA6B/C,eAAO,MAAM,UAAU,yCAAoB,CAAC;AAG5C,UAAU,KAAK,CAAC,CAAC;IACf,KAAK,EAAE,KAAK,CAAC,CAAC,CAAC,CAAC;CACjB;;;;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../src/ui/Table/BaseTable/index.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAE,KAAK,EAAgB,MAAM,UAAU,CAAC;AA6B/C,eAAO,MAAM,UAAU,yCAAoB,CAAC;AAG5C,UAAU,KAAK,CAAC,CAAC;IACf,KAAK,EAAE,KAAK,CAAC,CAAC,CAAC,CAAC;CACjB;;;;AAqRD,wBAAsC;AACtC,cAAc,UAAU,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@crystaldesign/diva-backoffice",
|
|
3
|
-
"version": "24.2.
|
|
3
|
+
"version": "24.2.2-beta.0",
|
|
4
4
|
"license": "COMMERCIAL",
|
|
5
5
|
"devDependencies": {
|
|
6
6
|
"@testing-library/jest-dom": "^5.15.0",
|
|
@@ -50,5 +50,5 @@
|
|
|
50
50
|
},
|
|
51
51
|
"module": "build/esm/index.js",
|
|
52
52
|
"types": "./build/types/backoffice/src/index.d.ts",
|
|
53
|
-
"gitHead": "
|
|
53
|
+
"gitHead": "25c4107b8dd5a439e1dbe220e58b756b731a8e30"
|
|
54
54
|
}
|