@galadrim/galadmin 0.0.54 → 0.0.58
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/README.md +11 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/src/front/build/asset-manifest.json +7 -7
- package/src/front/build/index.html +1 -1
- package/src/front/build/static/js/2.88bb9cea.chunk.js +3 -0
- package/src/front/build/static/js/{2.a36e796c.chunk.js.LICENSE.txt → 2.88bb9cea.chunk.js.LICENSE.txt} +0 -0
- package/src/front/build/static/js/2.88bb9cea.chunk.js.map +1 -0
- package/src/front/build/static/js/main.538d60f2.chunk.js +2 -0
- package/src/front/build/static/js/main.538d60f2.chunk.js.map +1 -0
- package/src/front/node_modules/.cache/.eslintcache +1 -1
- package/src/front/node_modules/.cache/babel-loader/1dcc78ab3af52e714586d619c8f1128f.json +1 -0
- package/src/front/node_modules/.cache/babel-loader/4b3b5abfa752c54455d4121d45617b4c.json +1 -0
- package/src/front/node_modules/.cache/babel-loader/8b2e3b7d832114bf8c399abc91f0bbc1.json +1 -0
- package/src/front/node_modules/.cache/babel-loader/f4b762bafa9d1a3fcfbe0c8e214442c1.json +1 -0
- package/src/front/node_modules/.cache/terser-webpack-plugin/content-v2/sha512/02/1c/cd922a30b837866c304e653fd02dc10a713290b65b1a3f8ab96fac6e8d3d8153afdd05cd2f39ac5a2b666bbc7c16e0a5a909a50abc0640d631f50f2d5405 +1 -0
- package/src/front/node_modules/.cache/terser-webpack-plugin/content-v2/sha512/21/93/c3bc4fffd829420b2e1fc2e1161d849042e695144793b2b52b65c973a95539804860e887a81c32ad2434a36361605b9b118c63a16a9a6b7fad8f5532ef5c +1 -0
- package/src/front/node_modules/.cache/terser-webpack-plugin/content-v2/sha512/82/fc/8df03373a80d4d89da5cdad8c280167829cff7b752ad71f51751f340f7fd0ae8ed0c60e608a41f7727e3e09de1ada900ebe5e213e4079167105c53293ed2 +1 -0
- package/src/front/node_modules/.cache/terser-webpack-plugin/index-v5/{36/24/c00eb98248fe79df72f85094ec47404188b5b9bcddb33765321a2cd0f2cf → 32/f1/8264252bcf7c4f98cde13450968b415f55003188f30504894efa85c8e42b} +1 -1
- package/src/front/node_modules/.cache/terser-webpack-plugin/index-v5/3b/6d/4bfed5b8d4522c713b88981d22cf3a01c8070de081205f08d72bde2b624d +1 -1
- package/src/front/node_modules/.cache/terser-webpack-plugin/index-v5/{89/0b/0288e44a6ea8f1f576183f8eaddfd813aa921af4ba454a7841d4dca8315d → 85/32/ce21c9eaef2611fd4fb33689a361ba60bbae4c7f2eaf10a151709b9d4d08} +1 -1
- package/src/front/node_modules/.cache/terser-webpack-plugin/index-v5/87/08/421190bfe6e50816e059da6c33526c9943732ef856ebd2752d0cbfb4a852 +1 -1
- package/src/front/node_modules/.cache/terser-webpack-plugin/index-v5/{a9/2b/f75db8fae988b6420aaee662e604df0969612b2f29af99f9ad3a53ae521b → 94/66/ea374838e414978c9e1d038e6fb5566cfbb76aee4b68c295fa393fa77633} +1 -1
- package/src/front/src/App.js +5 -1
- package/src/front/src/components/RedirectToFirstView.js +24 -0
- package/src/front/src/components/panels/GalleryPanel.js +2 -2
- package/src/front/src/pages/Record.js +2 -2
- package/src/front/build/static/js/2.a36e796c.chunk.js +0 -3
- package/src/front/build/static/js/2.a36e796c.chunk.js.map +0 -1
- package/src/front/build/static/js/main.435f24e1.chunk.js +0 -2
- package/src/front/build/static/js/main.435f24e1.chunk.js.map +0 -1
- package/src/front/node_modules/.cache/babel-loader/01481a0326bb4d10d7fbf09112189b69.json +0 -1
- package/src/front/node_modules/.cache/babel-loader/0f7b4f29f84916ad60dad5d618d38d0f.json +0 -1
- package/src/front/node_modules/.cache/babel-loader/5c2cc169da1cbf30356cdeadda534169.json +0 -1
- package/src/front/node_modules/.cache/babel-loader/bc29475dc0c7d230b3a90bafa0f6db35.json +0 -1
- package/src/front/node_modules/.cache/terser-webpack-plugin/content-v2/sha512/2b/82/e9b727a2449cc6e111c67a06de0af8423807ce8e322bff1af03dbdc1444c2762b43296d5d56289531ae9a6d4629f0487b77318120e4f639a0aa031b9665a +0 -1
- package/src/front/node_modules/.cache/terser-webpack-plugin/content-v2/sha512/40/d3/73dd582bfa224c9cdb6ae66f5209ca58eb21216dbb6184fd38b21f9c31de01ca82a4a6af69d51cf46601043d0b9cee8c89bb01c02f5359e347d87ce45371 +0 -1
- package/src/front/node_modules/.cache/terser-webpack-plugin/content-v2/sha512/80/14/f89b5000136bcab7e841402511e7e2bcbfb08f6605926578ba9a1929f3dd609aa2f82e957a405687e483efe592b680f55e33b414aa640a8f39a59e57b535 +0 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
|
|
2
|
+
3783de34454a1b346cfb4d5d22737bb32297e67c {"key":"{\"terser\":\"5.7.1\",\"terser-webpack-plugin\":\"4.2.3\",\"terser-webpack-plugin-options\":{\"test\":new RegExp(\"\\\\.[cm]?js(\\\\?.*)?$\", \"i\"),\"extractComments\":true,\"sourceMap\":true,\"cache\":true,\"cacheKeys\":defaultCacheKeys => defaultCacheKeys,\"parallel\":true,\"include\":undefined,\"exclude\":undefined,\"minify\":undefined,\"terserOptions\":{\"parse\":{\"ecma\":8},\"compress\":{\"ecma\":5,\"warnings\":false,\"comparisons\":false,\"inline\":2},\"mangle\":{\"safari10\":true},\"keep_classnames\":false,\"keep_fnames\":false,\"output\":{\"ecma\":5,\"comments\":false,\"ascii_only\":true},\"ecma\":5}},\"name\":\"static\\u002Fjs\\u002F2.88bb9cea.chunk.js\",\"contentHash\":\"01567565c347bca09e20\"}","integrity":"sha512-AhzNkiowuDeGbDBOZT/QLcEKcTKQtlsaP4q5b6xujT2BU6/dBc0vOaxaK2ZrvHwW4KWpCaUKvAZA1jH1Dy1UBQ==","time":1640165128702,"size":1866754}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
|
|
2
|
+
9cf0418dac6178aee39190dab670fc1d911d27b3 {"key":"{\"terser\":\"5.7.1\",\"terser-webpack-plugin\":\"4.2.3\",\"terser-webpack-plugin-options\":{\"test\":new RegExp(\"\\\\.[cm]?js(\\\\?.*)?$\", \"i\"),\"extractComments\":true,\"sourceMap\":true,\"cache\":true,\"cacheKeys\":defaultCacheKeys => defaultCacheKeys,\"parallel\":true,\"include\":undefined,\"exclude\":undefined,\"minify\":undefined,\"terserOptions\":{\"parse\":{\"ecma\":8},\"compress\":{\"ecma\":5,\"warnings\":false,\"comparisons\":false,\"inline\":2},\"mangle\":{\"safari10\":true},\"keep_classnames\":false,\"keep_fnames\":false,\"output\":{\"ecma\":5,\"comments\":false,\"ascii_only\":true},\"ecma\":5}},\"name\":\"static\\u002Fjs\\u002F2.a36e796c.chunk.js\",\"contentHash\":\"4352852219d257201775\"}","integrity":"sha512-donmDCnp0J/iv+TWTuiBTgFp2KdqP6CLMt7hXVq0VN/d1RyH3hDGuTXDuJ3ddYqLkQW6Tr0WouFMrZ+s5FT1zg==","time":1639995094971,"size":1863793}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
|
|
2
|
+
e10e87ad399f801a06782eea067b632c70cd7ca4 {"key":"{\"terser\":\"5.7.1\",\"terser-webpack-plugin\":\"4.2.3\",\"terser-webpack-plugin-options\":{\"test\":new RegExp(\"\\\\.[cm]?js(\\\\?.*)?$\", \"i\"),\"extractComments\":true,\"sourceMap\":true,\"cache\":true,\"cacheKeys\":defaultCacheKeys => defaultCacheKeys,\"parallel\":true,\"include\":undefined,\"exclude\":undefined,\"minify\":undefined,\"terserOptions\":{\"parse\":{\"ecma\":8},\"compress\":{\"ecma\":5,\"warnings\":false,\"comparisons\":false,\"inline\":2},\"mangle\":{\"safari10\":true},\"keep_classnames\":false,\"keep_fnames\":false,\"output\":{\"ecma\":5,\"comments\":false,\"ascii_only\":true},\"ecma\":5}},\"name\":\"static\\u002Fjs\\u002Fmain.6ea0ec11.chunk.js\",\"contentHash\":\"54393fc03feaf1b47b07\"}","integrity":"sha512-gvyN8DNzqA1Nidpc2tjCgBZ4Kc/3t1KtcfUXUfNA9/0K6O0MYOYIpB93J+PgneGtqQDr5eIT5AeRZxBcUyk+0g==","time":1639995091589,"size":331696}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
|
|
2
|
+
92e4716997dda5b4d159ebb6f672269d3c81bab9 {"key":"{\"terser\":\"5.7.1\",\"terser-webpack-plugin\":\"4.2.3\",\"terser-webpack-plugin-options\":{\"test\":new RegExp(\"\\\\.[cm]?js(\\\\?.*)?$\", \"i\"),\"extractComments\":true,\"sourceMap\":true,\"cache\":true,\"cacheKeys\":defaultCacheKeys => defaultCacheKeys,\"parallel\":true,\"include\":undefined,\"exclude\":undefined,\"minify\":undefined,\"terserOptions\":{\"parse\":{\"ecma\":8},\"compress\":{\"ecma\":5,\"warnings\":false,\"comparisons\":false,\"inline\":2},\"mangle\":{\"safari10\":true},\"keep_classnames\":false,\"keep_fnames\":false,\"output\":{\"ecma\":5,\"comments\":false,\"ascii_only\":true},\"ecma\":5}},\"name\":\"static\\u002Fjs\\u002Fruntime-main.2084140f.js\",\"contentHash\":\"21b0955fafaa36835c2c\"}","integrity":"sha512-EIHWkk+Hu8omZttNSZyf/dcQREufSs8WYrDS8rrnA4aKRWlIARB00JVPiR1DRsuEMh2l+YSkkh+tpa2nXovJ6g==","time":1639995091640,"size":17514}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
|
|
2
|
-
|
|
2
|
+
f1c685a09562c183a3866232d216b022e7859e5c {"key":"{\"terser\":\"5.7.1\",\"terser-webpack-plugin\":\"4.2.3\",\"terser-webpack-plugin-options\":{\"test\":new RegExp(\"\\\\.[cm]?js(\\\\?.*)?$\", \"i\"),\"extractComments\":true,\"sourceMap\":true,\"cache\":true,\"cacheKeys\":defaultCacheKeys => defaultCacheKeys,\"parallel\":true,\"include\":undefined,\"exclude\":undefined,\"minify\":undefined,\"terserOptions\":{\"parse\":{\"ecma\":8},\"compress\":{\"ecma\":5,\"warnings\":false,\"comparisons\":false,\"inline\":2},\"mangle\":{\"safari10\":true},\"keep_classnames\":false,\"keep_fnames\":false,\"output\":{\"ecma\":5,\"comments\":false,\"ascii_only\":true},\"ecma\":5}},\"name\":\"static\\u002Fjs\\u002Fmain.538d60f2.chunk.js\",\"contentHash\":\"ad1408eaec56cf1b524c\"}","integrity":"sha512-IZPDvE//2ClCCy4fwuEWHYSQQuaVFEeTsrUrZclzqVU5gEhg6IeoHDKtJDSjY2FgW5sRjGOhapprf62PVTLvXA==","time":1640165125795,"size":334780}
|
package/src/front/src/App.js
CHANGED
|
@@ -6,6 +6,7 @@ import {
|
|
|
6
6
|
import { useEffect, useState } from "react";
|
|
7
7
|
import './App.css';
|
|
8
8
|
import Sidebar from './components/Sidebar'
|
|
9
|
+
import RedirectToFirstView from './components/RedirectToFirstView'
|
|
9
10
|
import CreateRecord from './pages/CreateRecord'
|
|
10
11
|
import EditRecord from './pages/EditRecord'
|
|
11
12
|
import Records from './pages/Records'
|
|
@@ -17,7 +18,7 @@ import { ConfigProvider } from './contexts/ConfigContext'
|
|
|
17
18
|
import axios from "axios";
|
|
18
19
|
|
|
19
20
|
axios.defaults.withCredentials = true;
|
|
20
|
-
axios.defaults.baseURL = process.env.NODE_ENV === "development" ? 'http://localhost
|
|
21
|
+
axios.defaults.baseURL = process.env.NODE_ENV === "development" ? 'http://localhost/admin/api' : '/_HOMEPAGE_/api';
|
|
21
22
|
|
|
22
23
|
function App() {
|
|
23
24
|
const [isAuthenticated, setIsAuthenticated] = useState(null);
|
|
@@ -53,6 +54,9 @@ function App() {
|
|
|
53
54
|
<Route path="/customView/:viewIndex">
|
|
54
55
|
<CustomView />
|
|
55
56
|
</Route>
|
|
57
|
+
<Route path="/">
|
|
58
|
+
<RedirectToFirstView />
|
|
59
|
+
</Route>
|
|
56
60
|
</Switch>
|
|
57
61
|
</Router>
|
|
58
62
|
</ConfigProvider>
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { useContext } from "react"
|
|
2
|
+
import {
|
|
3
|
+
Redirect
|
|
4
|
+
} from "react-router-dom";
|
|
5
|
+
import { ConfigContext } from '../contexts/ConfigContext'
|
|
6
|
+
|
|
7
|
+
export default () => {
|
|
8
|
+
const config = useContext(ConfigContext)
|
|
9
|
+
const firstView = config.views[0]
|
|
10
|
+
|
|
11
|
+
if (!firstView) {
|
|
12
|
+
return null
|
|
13
|
+
}
|
|
14
|
+
if (firstView.type === "table") {
|
|
15
|
+
return <Redirect to="/records/0" />
|
|
16
|
+
}
|
|
17
|
+
if (firstView.type === "iframe") {
|
|
18
|
+
return <Redirect to="/iframe/0" />
|
|
19
|
+
}
|
|
20
|
+
if (firstView.type === "custom") {
|
|
21
|
+
return <Redirect to="/customView/0" />
|
|
22
|
+
}
|
|
23
|
+
return null;
|
|
24
|
+
}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { useState, useEffect } from "react"
|
|
2
2
|
import axios from "axios";
|
|
3
3
|
|
|
4
|
-
export default ({ panel }) => {
|
|
4
|
+
export default ({ panel, record, view }) => {
|
|
5
5
|
const [results, setResults] = useState(null);
|
|
6
6
|
|
|
7
7
|
useEffect(() => {
|
|
8
8
|
axios.get("/customQuery", {
|
|
9
9
|
params: {
|
|
10
10
|
query: panel.query,
|
|
11
|
-
primaryValue:
|
|
11
|
+
primaryValue: record[view.primaryId]
|
|
12
12
|
}
|
|
13
13
|
}).then((response) => {
|
|
14
14
|
setResults(response.data)
|
|
@@ -74,7 +74,7 @@ export default () => {
|
|
|
74
74
|
</div>
|
|
75
75
|
</div>
|
|
76
76
|
{panel.type === "table" ? <TablePanel record={record} panel={panel} view={view} /> : null}
|
|
77
|
-
{panel.type === "gallery" ? <GalleryPanel panel={panel} /> : null}
|
|
77
|
+
{panel.type === "gallery" ? <GalleryPanel record={record} panel={panel} view={view} /> : null}
|
|
78
78
|
{panel.type === "map" ? <MapPanel record={record} panel={panel} view={view} /> : null}
|
|
79
79
|
</div>
|
|
80
80
|
))}
|
|
@@ -84,4 +84,4 @@ export default () => {
|
|
|
84
84
|
</div>
|
|
85
85
|
</div>
|
|
86
86
|
)
|
|
87
|
-
}
|
|
87
|
+
}
|