jamespot-front-business 1.2.12 → 1.2.14
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/cjs.js +45 -1
- package/dist/cjs.js.map +1 -1
- package/dist/esm.js +45 -1
- package/dist/esm.js.map +1 -1
- package/dist/types.d.ts +66 -20
- package/package.json +2 -2
package/dist/esm.js
CHANGED
|
@@ -2347,6 +2347,42 @@ const getModelIconSrc = (model, size) => {
|
|
|
2347
2347
|
};
|
|
2348
2348
|
return formatImgUrl(imgProps);
|
|
2349
2349
|
};
|
|
2350
|
+
const getModelFontAwesomeIcon = (icon) => {
|
|
2351
|
+
var _a;
|
|
2352
|
+
const modelIconToFAIcon = {
|
|
2353
|
+
actionplan: 'fs-actionplan',
|
|
2354
|
+
animatedMeeting: 'fs-animated_meeting',
|
|
2355
|
+
articleWidget: 'star',
|
|
2356
|
+
album: 'images',
|
|
2357
|
+
article: 'file-lines',
|
|
2358
|
+
businessDirectory: 'building',
|
|
2359
|
+
document: 'file-arrow-down',
|
|
2360
|
+
diffgroup: 'group',
|
|
2361
|
+
event: 'calendar-days',
|
|
2362
|
+
goal: 'bullseye-arrow',
|
|
2363
|
+
idea: 'fs-idea',
|
|
2364
|
+
'intranet-page': 'fs-intranet',
|
|
2365
|
+
lab: 'flask',
|
|
2366
|
+
meeting: 'calendar-days',
|
|
2367
|
+
news: 'newspaper',
|
|
2368
|
+
poll: 'square-poll-vertical',
|
|
2369
|
+
process: 'fs-process',
|
|
2370
|
+
question: 'circle-question',
|
|
2371
|
+
search: 'block-question',
|
|
2372
|
+
surveyDate: 'calendar-check',
|
|
2373
|
+
support: 'headset',
|
|
2374
|
+
targetInfo: 'message-exclamation',
|
|
2375
|
+
task: 'list-check',
|
|
2376
|
+
tender: 'bullhorn',
|
|
2377
|
+
url: 'link',
|
|
2378
|
+
'weDoc-docx': 'file-word',
|
|
2379
|
+
'weDoc-xlsx': 'file-excel',
|
|
2380
|
+
'weDoc-pptx': 'file-powerpoint',
|
|
2381
|
+
wiki: 'fs-wiki',
|
|
2382
|
+
workgroup: 'fs-workgroup',
|
|
2383
|
+
};
|
|
2384
|
+
return `icon-${(_a = modelIconToFAIcon[icon]) !== null && _a !== void 0 ? _a : icon}`;
|
|
2385
|
+
};
|
|
2350
2386
|
const slice$2 = createSlice({
|
|
2351
2387
|
name: 'models',
|
|
2352
2388
|
initialState: adapter$1.getInitialState(),
|
|
@@ -2359,6 +2395,7 @@ const slice$2 = createSlice({
|
|
|
2359
2395
|
const selectors$1 = adapter$1.getSelectors((state) => state.entities.models);
|
|
2360
2396
|
const utils = {
|
|
2361
2397
|
getModelIconSrc,
|
|
2398
|
+
getModelFontAwesomeIcon,
|
|
2362
2399
|
};
|
|
2363
2400
|
const selectByIds = (state, types) => types.map((type) => state.entities.models.entities[type]).filter((model) => !!model);
|
|
2364
2401
|
const Model = {
|
|
@@ -4653,7 +4690,7 @@ function renderDisplays(studioApp) {
|
|
|
4653
4690
|
Object.entries(studioApp.views).forEach(([viewName, viewContent]) => {
|
|
4654
4691
|
if (Object.prototype.hasOwnProperty.call(internal2XmlView, viewName)) {
|
|
4655
4692
|
const viewField = Object.entries(viewContent)
|
|
4656
|
-
.filter((a) => a[1].isUsed)
|
|
4693
|
+
.filter((a) => a[1].isUsed && (viewName !== 'view' || a[0] !== 'title'))
|
|
4657
4694
|
.sort((a, b) => a[1].pos - b[1].pos);
|
|
4658
4695
|
toRet += `<display view="${internal2XmlView[viewName]}${viewName === 'view' && studioApp.manifest.displayContentLegacyTable ? 'Disabled' : ''}" mode="${viewName === 'view' ? 'view' : 'form'}">
|
|
4659
4696
|
${viewField.map(([fieldId, view]) => renderDisplayAttr(fieldId, view)).join('')}
|
|
@@ -4956,6 +4993,10 @@ function populateFieldsAndViews(app, appS, state) {
|
|
|
4956
4993
|
function buildView(appS, registeredFields, displayName, displayValue, tables, state) {
|
|
4957
4994
|
const newName = installedToV2ViewNames[displayName];
|
|
4958
4995
|
appS.views[newName] = {};
|
|
4996
|
+
if (newName === 'view') {
|
|
4997
|
+
const [localFieldIdTitle, localFieldTitle] = getTitleToView({ fixedValue: undefined, ref: 'title' });
|
|
4998
|
+
appS.views[newName][localFieldIdTitle] = localFieldTitle;
|
|
4999
|
+
}
|
|
4959
5000
|
displayValue.composants.forEach((viewComponent, index) => {
|
|
4960
5001
|
let field = undefined;
|
|
4961
5002
|
if (viewComponent.name && ignoredFields.includes(viewComponent.name)) {
|
|
@@ -4965,6 +5006,9 @@ function buildView(appS, registeredFields, displayName, displayValue, tables, st
|
|
|
4965
5006
|
if (fieldIdx === -1 && fixedInfo) {
|
|
4966
5007
|
switch (fixedInfo.ref) {
|
|
4967
5008
|
case 'title':
|
|
5009
|
+
if (newName === 'view') {
|
|
5010
|
+
break;
|
|
5011
|
+
}
|
|
4968
5012
|
const [localFieldIdTitle, localFieldTitle] = getTitleToView(fixedInfo);
|
|
4969
5013
|
appS.views[newName][localFieldIdTitle] = localFieldTitle;
|
|
4970
5014
|
break;
|