@punch-in/strapi-admin 1.0.4 → 1.0.5
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/admin/src/app.js +1 -1
- package/admin/src/containers/ApplicationInfosPage/index.js +22 -4
- package/admin/src/containers/HomePage/index.js +0 -1
- package/admin/src/translations/en.json +4 -0
- package/admin/src/translations/fr.json +4 -0
- package/admin/src/translations/it.json +4 -0
- package/controllers/admin.js +2 -1
- package/index.js +1 -1
- package/package.json +1 -1
package/admin/src/app.js
CHANGED
|
@@ -166,7 +166,7 @@ window.strapi = Object.assign(window.strapi || {}, {
|
|
|
166
166
|
node: MODE || 'host',
|
|
167
167
|
env: NODE_ENV,
|
|
168
168
|
remoteURL,
|
|
169
|
-
backendURL:
|
|
169
|
+
backendURL: 'https://' + window.location.hostname.replace('-admin',''),
|
|
170
170
|
notification: {
|
|
171
171
|
// New notification api
|
|
172
172
|
toggle: config => {
|
|
@@ -27,9 +27,27 @@ const ApplicationInfosPage = () => {
|
|
|
27
27
|
selectLatestRealase(state)
|
|
28
28
|
);
|
|
29
29
|
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
:
|
|
30
|
+
let currentPlan =
|
|
31
|
+
switch (appInfos.maxUsers) {
|
|
32
|
+
case 100:
|
|
33
|
+
currentPlan = 'app.components.CurrentPlanModal.giant';
|
|
34
|
+
break;
|
|
35
|
+
case 50:
|
|
36
|
+
currentPlan = 'app.components.CurrentPlanModal.large';
|
|
37
|
+
break;
|
|
38
|
+
case 30:
|
|
39
|
+
currentPlan = 'app.components.CurrentPlanModal.medium';
|
|
40
|
+
break;
|
|
41
|
+
case 10:
|
|
42
|
+
currentPlan = 'app.components.CurrentPlanModal.light';
|
|
43
|
+
break;
|
|
44
|
+
default:
|
|
45
|
+
currentPlan = 'app.components.CurrentPlanModal.giant';
|
|
46
|
+
break;
|
|
47
|
+
}
|
|
48
|
+
// const currentPlan = appInfos.communityEdition
|
|
49
|
+
// ? 'app.components.UpgradePlanModal.text-ce'
|
|
50
|
+
// : 'app.components.UpgradePlanModal.text-ee';
|
|
33
51
|
|
|
34
52
|
const headerProps = {
|
|
35
53
|
title: { label: formatMessage({ id: 'Settings.application.title' }) },
|
|
@@ -67,7 +85,7 @@ const ApplicationInfosPage = () => {
|
|
|
67
85
|
content={`v${appInfos.strapiVersion}`}
|
|
68
86
|
/>
|
|
69
87
|
<Detail
|
|
70
|
-
link={{ label: pricingLabel, href: 'https://
|
|
88
|
+
link={{ label: pricingLabel, href: 'https://www.punch-in.co.uk/#pricing' }}
|
|
71
89
|
title={editionTitle}
|
|
72
90
|
content={formatMessage({ id: currentPlan })}
|
|
73
91
|
/>
|
|
@@ -13,7 +13,6 @@ import { useModels } from '../../hooks';
|
|
|
13
13
|
|
|
14
14
|
import useFetch from './hooks';
|
|
15
15
|
import { ALink, Block, Container, LinkWrapper, P, Wave, Separator } from './components';
|
|
16
|
-
import BlogPost from './BlogPost';
|
|
17
16
|
import SocialLink from './SocialLink';
|
|
18
17
|
|
|
19
18
|
const FIRST_BLOCK_LINKS = [
|
|
@@ -183,6 +183,10 @@
|
|
|
183
183
|
"app.components.Button.cancel": "Cancel",
|
|
184
184
|
"app.components.Button.reset": "Reset",
|
|
185
185
|
"app.components.Button.save": "Save",
|
|
186
|
+
"app.components.CurrentPlanModal.giant":"Giant (max 100 users)",
|
|
187
|
+
"app.components.CurrentPlanModal.large":"Large (max 50 users)",
|
|
188
|
+
"app.components.CurrentPlanModal.medium":"Medium (max 30 users)",
|
|
189
|
+
"app.components.CurrentPlanModal.light":"Light (max 10 users)",
|
|
186
190
|
"app.components.ComingSoonPage.comingSoon": "Coming soon",
|
|
187
191
|
"app.components.DownloadInfo.download": "Download in progress...",
|
|
188
192
|
"app.components.DownloadInfo.text": "This could take a minute. Thanks for your patience.",
|
|
@@ -76,6 +76,10 @@
|
|
|
76
76
|
"app.components.Button.reset": "Annuler",
|
|
77
77
|
"app.components.Button.save": "Sauvegarder",
|
|
78
78
|
"app.components.ComingSoonPage.comingSoon": "Bientôt disponible",
|
|
79
|
+
"app.components.CurrentPlanModal.giant":"Géant (max 100 users)",
|
|
80
|
+
"app.components.CurrentPlanModal.large":"Grand (max 50 users)",
|
|
81
|
+
"app.components.CurrentPlanModal.medium":"Medium (max 30 users)",
|
|
82
|
+
"app.components.CurrentPlanModal.light":"Leger (max 10 users)",
|
|
79
83
|
"app.components.DownloadInfo.download": "Téléchargement en cours...",
|
|
80
84
|
"app.components.DownloadInfo.text": "Cela peut prendre une minute. Merci de patienter.",
|
|
81
85
|
"app.components.EmptyAttributes.title": "Il n'y a pas encore de champ",
|
|
@@ -164,6 +164,10 @@
|
|
|
164
164
|
"app.components.Button.reset": "Ripristina",
|
|
165
165
|
"app.components.Button.save": "Salva",
|
|
166
166
|
"app.components.ComingSoonPage.comingSoon": "In arrivo",
|
|
167
|
+
"app.components.CurrentPlanModal.giant":"Gigante (max 100 utilizzatori)",
|
|
168
|
+
"app.components.CurrentPlanModal.large":"Grande (max 50 utilizzatori)",
|
|
169
|
+
"app.components.CurrentPlanModal.medium":"Medio (max 30 utilizzatori)",
|
|
170
|
+
"app.components.CurrentPlanModal.light":"Leggero (max 10 utilizzatori)",
|
|
167
171
|
"app.components.DownloadInfo.download": "Download in corso...",
|
|
168
172
|
"app.components.DownloadInfo.text": "Potrebbe volerci un minuto. Grazie della pazienza.",
|
|
169
173
|
"app.components.EmptyAttributes.title": "Campi non ancora presenti.",
|
package/controllers/admin.js
CHANGED
|
@@ -28,11 +28,12 @@ module.exports = {
|
|
|
28
28
|
const currentEnvironment = strapi.app.env;
|
|
29
29
|
const autoReload = strapi.config.get('autoReload', false);
|
|
30
30
|
const strapiVersion = strapi.config.get('info.strapi', null);
|
|
31
|
+
const maxUsers = strapi.config.get('info.maxUsers', 100);
|
|
31
32
|
const nodeVersion = process.version;
|
|
32
33
|
const communityEdition = !strapi.EE;
|
|
33
34
|
|
|
34
35
|
return {
|
|
35
|
-
data: { currentEnvironment, autoReload, strapiVersion, nodeVersion, communityEdition },
|
|
36
|
+
data: { currentEnvironment, autoReload, strapiVersion, nodeVersion, maxUsers, communityEdition },
|
|
36
37
|
};
|
|
37
38
|
},
|
|
38
39
|
|
package/index.js
CHANGED
|
@@ -89,7 +89,7 @@ const { languages } = require('./i18n');
|
|
|
89
89
|
|
|
90
90
|
window.strapi = Object.assign(window.strapi || {}, {
|
|
91
91
|
node: MODE || 'host',
|
|
92
|
-
backendURL: BACKEND_URL === '/' ? window.location.
|
|
92
|
+
backendURL: BACKEND_URL === '/' ? window.location.host.replace('-admin','') : BACKEND_URL,
|
|
93
93
|
languages,
|
|
94
94
|
currentLanguage:
|
|
95
95
|
window.localStorage.getItem('strapi-admin-language') ||
|