first kanban-view integration for client groups
This commit is contained in:
340
dashboard/package-lock.json
generated
340
dashboard/package-lock.json
generated
@@ -8,10 +8,11 @@
|
|||||||
"name": "dashboard",
|
"name": "dashboard",
|
||||||
"version": "0.0.0",
|
"version": "0.0.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-react-buttons": "^29.2.5",
|
"@syncfusion/ej2-react-buttons": "^30.1.37",
|
||||||
"@syncfusion/ej2-react-calendars": "^29.2.11",
|
"@syncfusion/ej2-react-calendars": "^30.1.37",
|
||||||
"@syncfusion/ej2-react-grids": "^29.2.11",
|
"@syncfusion/ej2-react-grids": "^30.1.37",
|
||||||
"@syncfusion/ej2-react-schedule": "^29.2.10",
|
"@syncfusion/ej2-react-kanban": "^30.1.37",
|
||||||
|
"@syncfusion/ej2-react-schedule": "^30.1.37",
|
||||||
"cldr-data": "^36.0.4",
|
"cldr-data": "^36.0.4",
|
||||||
"lucide-react": "^0.522.0",
|
"lucide-react": "^0.522.0",
|
||||||
"react": "^19.1.0",
|
"react": "^19.1.0",
|
||||||
@@ -1637,264 +1638,301 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-base": {
|
"node_modules/@syncfusion/ej2-base": {
|
||||||
"version": "29.2.11",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-base/-/ej2-base-29.2.11.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-base/-/ej2-base-30.1.37.tgz",
|
||||||
"integrity": "sha512-f1yM+6606zde7MR4q4d/q6foR3viHDA1/SkkTbLVwBME7I/0AcMG/i0eeTWJfJS8dgn91DGrsrEl0nZ9IA1CEQ==",
|
"integrity": "sha512-/RXLTid6XaKEyqBttyhO6FsGHhGitOzxPv64qo4AtE+33uU2usCRuBY4QZtGq5SBMQs7tIvjdtwff989jWHgzQ==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-icons": "~29.2.4"
|
"@syncfusion/ej2-icons": "~30.1.37"
|
||||||
},
|
},
|
||||||
"bin": {
|
"bin": {
|
||||||
"syncfusion-license": "bin/syncfusion-license.js"
|
"syncfusion-license": "bin/syncfusion-license.js"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-buttons": {
|
"node_modules/@syncfusion/ej2-buttons": {
|
||||||
"version": "29.2.5",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-buttons/-/ej2-buttons-29.2.5.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-buttons/-/ej2-buttons-30.1.37.tgz",
|
||||||
"integrity": "sha512-FbMi9rUi/7i8mpPA6KRaO7qW/3wIeH759u2/Ag0iMQUEdtdK7NvOCSFF29WESeBjW6GmEJ8zkW0340ymgXZruQ==",
|
"integrity": "sha512-31dPIDSkraFlR8+sCz2NtM1tg9TSBN2YRHC7mBZGDWX6B26ie4zbe63S22l0ytaoMDt3XHqExsk7MLlnG3LR8g==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.4"
|
"@syncfusion/ej2-base": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-calendars": {
|
"node_modules/@syncfusion/ej2-calendars": {
|
||||||
"version": "29.2.11",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-calendars/-/ej2-calendars-29.2.11.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-calendars/-/ej2-calendars-30.1.37.tgz",
|
||||||
"integrity": "sha512-RphIYxXwaDv59QiYjswIntNyDxOqd3oQqi2G9Z3zRD+Ez1u+ybY9koaWbj5Dq/5AsFhdNCwHhyEPX9gACZMsvA==",
|
"integrity": "sha512-9g41zBRizXilbRJWHJgqRYJPpX0WJF5qJwGNpgvsBnyYdolYQy///x6c3oYo9W6YG28N0QDavdbOaxwprj4ghg==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.11",
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-buttons": "~29.2.5",
|
"@syncfusion/ej2-buttons": "~30.1.37",
|
||||||
"@syncfusion/ej2-inputs": "~29.2.5",
|
"@syncfusion/ej2-inputs": "~30.1.37",
|
||||||
"@syncfusion/ej2-lists": "~29.2.4",
|
"@syncfusion/ej2-lists": "~30.1.37",
|
||||||
"@syncfusion/ej2-popups": "~29.2.8"
|
"@syncfusion/ej2-popups": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-compression": {
|
"node_modules/@syncfusion/ej2-compression": {
|
||||||
"version": "29.2.4",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-compression/-/ej2-compression-29.2.4.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-compression/-/ej2-compression-30.1.37.tgz",
|
||||||
"integrity": "sha512-mcgFmgtITGxoX4zV4LrFGAOHOQD8Z7is85vQE+k2Bf4OI6rZsLNIQFm6KEFg+sZMOSrABzKzg49yrktmlus4TQ==",
|
"integrity": "sha512-QA5oAJZDaAONO12zwVCc1IqYTmiwthSoWaMoE0jgQR+mpYR8XmlMi1VOvP8Jtu+HlfQMaEGcMQ++UM5UeZW4+g==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-file-utils": "~29.2.4"
|
"@syncfusion/ej2-file-utils": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-data": {
|
"node_modules/@syncfusion/ej2-data": {
|
||||||
"version": "29.2.4",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-data/-/ej2-data-29.2.4.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-data/-/ej2-data-30.1.37.tgz",
|
||||||
"integrity": "sha512-2R+N65OPq+yfwTXyBz7NdD8MHGoxUbJSEWGT0kNEGMiobiI4AL+hfMYEhXWXE+DqL5Pm0txA4gTXQprFXXbccg==",
|
"integrity": "sha512-UGbF1a95BmdRcgkgekMOdJY0kcNSaOrKWLlnZxFkEl9SSvN+mxPa7ktgXHlEWRc+KY/WeNSV2kmyZ8h/htnAXQ==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.4"
|
"@syncfusion/ej2-base": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-dropdowns": {
|
"node_modules/@syncfusion/ej2-dropdowns": {
|
||||||
"version": "29.2.11",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-dropdowns/-/ej2-dropdowns-29.2.11.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-dropdowns/-/ej2-dropdowns-30.1.37.tgz",
|
||||||
"integrity": "sha512-NtWQexED+1T4Ef/vPkG+C9ANkUD3QPvXelyQaS2+j+mzipOhSBGiDcJYIE1R1wtqC3BhLfMZBPJbuXGc0p+mmQ==",
|
"integrity": "sha512-yk4Pous9P2Ccg/QoX+fmJatn5ypbWWTvptEd5h5p4Wb0qlvwJIPuJo/KkcyK2vUx7kRzN5dzmUX7cKP7Z1ZhPg==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.11",
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-data": "~29.2.4",
|
"@syncfusion/ej2-data": "~30.1.37",
|
||||||
"@syncfusion/ej2-inputs": "~29.2.5",
|
"@syncfusion/ej2-inputs": "~30.1.37",
|
||||||
"@syncfusion/ej2-lists": "~29.2.4",
|
"@syncfusion/ej2-lists": "~30.1.37",
|
||||||
"@syncfusion/ej2-navigations": "~29.2.8",
|
"@syncfusion/ej2-navigations": "~30.1.37",
|
||||||
"@syncfusion/ej2-notifications": "~29.2.4",
|
"@syncfusion/ej2-notifications": "~30.1.37",
|
||||||
"@syncfusion/ej2-popups": "~29.2.8"
|
"@syncfusion/ej2-popups": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-excel-export": {
|
"node_modules/@syncfusion/ej2-excel-export": {
|
||||||
"version": "29.2.4",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-excel-export/-/ej2-excel-export-29.2.4.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-excel-export/-/ej2-excel-export-30.1.37.tgz",
|
||||||
"integrity": "sha512-N3VAdlhP+Wq/Uyl82ZSx6x8zL3slgtEKzWb13nrfas7cdJicYrbx02YZru5/euaeE3yGTlbKmhjjLLbkVFU/kQ==",
|
"integrity": "sha512-AMOTpy/uzb6QzKHgQdofA2P0Ec1KLmfT9vDXPzmF3npsPbqL0a+6K73MaZZKjW8rBrwohnbJV2R+acotpW/Seg==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.4",
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-compression": "~29.2.4"
|
"@syncfusion/ej2-compression": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-file-utils": {
|
"node_modules/@syncfusion/ej2-file-utils": {
|
||||||
"version": "29.2.4",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-file-utils/-/ej2-file-utils-29.2.4.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-file-utils/-/ej2-file-utils-30.1.37.tgz",
|
||||||
"integrity": "sha512-nnvZ+1xVULe418habMciZnDAoMOM+TqFaFpO9kf4Cct9RPYUr22Tsvu84CZI7yzzKj/dLfD4n5TRRCHVo+5vVA==",
|
"integrity": "sha512-1r0rWrXEsXsRJhG0yOs8Hp2nGARLsBCD4u602R4IxLDrockIPVJv4gz0rIw4dDtFW7bpAa8J+yWXtr6fW29Bhw==",
|
||||||
"license": "SEE LICENSE IN license"
|
"license": "SEE LICENSE IN license"
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-grids": {
|
"node_modules/@syncfusion/ej2-grids": {
|
||||||
"version": "29.2.11",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-grids/-/ej2-grids-29.2.11.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-grids/-/ej2-grids-30.1.37.tgz",
|
||||||
"integrity": "sha512-11jI7ve/qxQVsA4kP+v0Y1bEfO7kFCCtBekag80Fy+yio88Wcr5c1Q9SxgsmZtX+Kzk6oSymS497/zNcBDsUJw==",
|
"integrity": "sha512-EG8RzzPCML9UULAN+SZdo/G5j8AsmzKzwQvocvZoL/YOfDPWom8WaGXNbE5pssMmIEnF2YnQkMuwRWg1tLHyog==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.11",
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-buttons": "~29.2.5",
|
"@syncfusion/ej2-buttons": "~30.1.37",
|
||||||
"@syncfusion/ej2-calendars": "~29.2.11",
|
"@syncfusion/ej2-calendars": "~30.1.37",
|
||||||
"@syncfusion/ej2-compression": "~29.2.4",
|
"@syncfusion/ej2-compression": "~30.1.37",
|
||||||
"@syncfusion/ej2-data": "~29.2.4",
|
"@syncfusion/ej2-data": "~30.1.37",
|
||||||
"@syncfusion/ej2-dropdowns": "~29.2.11",
|
"@syncfusion/ej2-dropdowns": "~30.1.37",
|
||||||
"@syncfusion/ej2-excel-export": "~29.2.4",
|
"@syncfusion/ej2-excel-export": "~30.1.37",
|
||||||
"@syncfusion/ej2-file-utils": "~29.2.4",
|
"@syncfusion/ej2-file-utils": "~30.1.37",
|
||||||
"@syncfusion/ej2-inputs": "~29.2.5",
|
"@syncfusion/ej2-inputs": "~30.1.37",
|
||||||
"@syncfusion/ej2-lists": "~29.2.4",
|
"@syncfusion/ej2-lists": "~30.1.37",
|
||||||
"@syncfusion/ej2-navigations": "~29.2.8",
|
"@syncfusion/ej2-navigations": "~30.1.37",
|
||||||
"@syncfusion/ej2-notifications": "~29.2.4",
|
"@syncfusion/ej2-notifications": "~30.1.37",
|
||||||
"@syncfusion/ej2-pdf-export": "~29.2.4",
|
"@syncfusion/ej2-pdf-export": "~30.1.37",
|
||||||
"@syncfusion/ej2-popups": "~29.2.8",
|
"@syncfusion/ej2-popups": "~30.1.37",
|
||||||
"@syncfusion/ej2-splitbuttons": "~29.2.4"
|
"@syncfusion/ej2-splitbuttons": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-icons": {
|
"node_modules/@syncfusion/ej2-icons": {
|
||||||
"version": "29.2.4",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-icons/-/ej2-icons-29.2.4.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-icons/-/ej2-icons-30.1.37.tgz",
|
||||||
"integrity": "sha512-2DYZglxLM++w0S2wB2bcr/Akk1MODdVhfFYLaLqe6mDHDRicFeTEyvnGPx2SHS2EXXlNNFm2GfNWoNNxgs5MhQ==",
|
"integrity": "sha512-bgPklX0jiaLESbWJDNx8f8PqVexwbRJHoz4kDgOJR4VN4JoOtC7Zw47Wb+eFwj13Ped1lTfuPfmU8sI1s5INeQ==",
|
||||||
"license": "SEE LICENSE IN license"
|
"license": "SEE LICENSE IN license"
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-inputs": {
|
"node_modules/@syncfusion/ej2-inputs": {
|
||||||
"version": "29.2.5",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-inputs/-/ej2-inputs-29.2.5.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-inputs/-/ej2-inputs-30.1.37.tgz",
|
||||||
"integrity": "sha512-3ZqMl005qL0tENHcKvBfKUHMYQ/S0FRYjUDQVDPRsg28tE0Lz87oyamrxLYne3zDBEJ7kxWWnaNpgrTVvxsVNw==",
|
"integrity": "sha512-6gOvtZO7ygdPnec8M7cr0TNBkENMmiW4YLnJTgGl5UgogQb+f8D8giE3SKqfWdmlJMBD1lzW96Ig4gW2n4JwMQ==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.4",
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-buttons": "~29.2.5",
|
"@syncfusion/ej2-buttons": "~30.1.37",
|
||||||
"@syncfusion/ej2-popups": "~29.2.4",
|
"@syncfusion/ej2-popups": "~30.1.37",
|
||||||
"@syncfusion/ej2-splitbuttons": "~29.2.4"
|
"@syncfusion/ej2-splitbuttons": "~30.1.37"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@syncfusion/ej2-kanban": {
|
||||||
|
"version": "30.1.37",
|
||||||
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-kanban/-/ej2-kanban-30.1.37.tgz",
|
||||||
|
"integrity": "sha512-JiR7+CrLqaji0OaPx7BsvN/pM5hwWLMnJC9TPk6MbyMmsch8NlHBw+DMPl+0MbssNg2qFAoKmeOR6uNWv+EZvw==",
|
||||||
|
"license": "SEE LICENSE IN license",
|
||||||
|
"dependencies": {
|
||||||
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
|
"@syncfusion/ej2-buttons": "~30.1.37",
|
||||||
|
"@syncfusion/ej2-data": "~30.1.37",
|
||||||
|
"@syncfusion/ej2-dropdowns": "~30.1.37",
|
||||||
|
"@syncfusion/ej2-inputs": "~30.1.37",
|
||||||
|
"@syncfusion/ej2-layouts": "~30.1.37",
|
||||||
|
"@syncfusion/ej2-navigations": "~30.1.37",
|
||||||
|
"@syncfusion/ej2-notifications": "~30.1.37",
|
||||||
|
"@syncfusion/ej2-popups": "~30.1.37"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@syncfusion/ej2-layouts": {
|
||||||
|
"version": "30.1.37",
|
||||||
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-layouts/-/ej2-layouts-30.1.37.tgz",
|
||||||
|
"integrity": "sha512-EPI00OSBMuzxp8od6jTOK2LRlv5IWtN4WmpIklUe34vev0qG9HLo8yT2BKCUIo5TRm4xEUXx0mQM7ZSKw2iHig==",
|
||||||
|
"license": "SEE LICENSE IN license",
|
||||||
|
"dependencies": {
|
||||||
|
"@syncfusion/ej2-base": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-lists": {
|
"node_modules/@syncfusion/ej2-lists": {
|
||||||
"version": "29.2.4",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-lists/-/ej2-lists-29.2.4.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-lists/-/ej2-lists-30.1.37.tgz",
|
||||||
"integrity": "sha512-U64nGdZMjnhHG/+YCTF+WhJ3BoUxFyN2DXxv2qlC+wtayMbfioDRwqSQgxTkH8XE4TgrkRFenRtj5SbYLKliSw==",
|
"integrity": "sha512-Tot/4yjBoBlCPr49EKPL/yDHFoPhHlgp3bK6+LG5jgThQE+guB5sSlqlNl3Noui25oMTRcXlt29SHZwstdpsNg==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.4",
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-buttons": "~29.2.4",
|
"@syncfusion/ej2-buttons": "~30.1.37",
|
||||||
"@syncfusion/ej2-data": "~29.2.4",
|
"@syncfusion/ej2-data": "~30.1.37",
|
||||||
"@syncfusion/ej2-popups": "~29.2.4"
|
"@syncfusion/ej2-popups": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-navigations": {
|
"node_modules/@syncfusion/ej2-navigations": {
|
||||||
"version": "29.2.8",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-navigations/-/ej2-navigations-29.2.8.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-navigations/-/ej2-navigations-30.1.37.tgz",
|
||||||
"integrity": "sha512-u14J+dEocqGIKgWCC1eiATv1nh40dgILsGPpGbYS+h9Y7y4YMBRzL2UCcuNHXgPKL7SiJ5lCaVORFco8cxyh6A==",
|
"integrity": "sha512-FD3hsT4a8fMdS3S7EFu9tnu741980HRK97fDAUgUtLGqDANC6Ee2HyeZZTjVeUpVAHfdomb/n7oYvtDUXZxwYw==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.4",
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-buttons": "~29.2.5",
|
"@syncfusion/ej2-buttons": "~30.1.37",
|
||||||
"@syncfusion/ej2-data": "~29.2.4",
|
"@syncfusion/ej2-data": "~30.1.37",
|
||||||
"@syncfusion/ej2-inputs": "~29.2.5",
|
"@syncfusion/ej2-inputs": "~30.1.37",
|
||||||
"@syncfusion/ej2-lists": "~29.2.4",
|
"@syncfusion/ej2-lists": "~30.1.37",
|
||||||
"@syncfusion/ej2-popups": "~29.2.8"
|
"@syncfusion/ej2-popups": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-notifications": {
|
"node_modules/@syncfusion/ej2-notifications": {
|
||||||
"version": "29.2.4",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-notifications/-/ej2-notifications-29.2.4.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-notifications/-/ej2-notifications-30.1.37.tgz",
|
||||||
"integrity": "sha512-rB9OuGHWVfnl9aBno+4KRH3aESbakLKYT70V7wjTxwS7u11XbxYwLiA4/YKsTQg/zrgOtcr3Ma1sVOeMYW17gQ==",
|
"integrity": "sha512-ksXk9lTf0Iw5+4EarYjxG1rKU+e9ZbCOaxvl/PN+MP1w1BAFwu4jRwpE9mbPF2FQUxcL1xNCxTnspSQaH36f4Q==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.4",
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-buttons": "~29.2.4",
|
"@syncfusion/ej2-buttons": "~30.1.37",
|
||||||
"@syncfusion/ej2-popups": "~29.2.4"
|
"@syncfusion/ej2-popups": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-pdf-export": {
|
"node_modules/@syncfusion/ej2-pdf-export": {
|
||||||
"version": "29.2.4",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-pdf-export/-/ej2-pdf-export-29.2.4.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-pdf-export/-/ej2-pdf-export-30.1.37.tgz",
|
||||||
"integrity": "sha512-Cb5QKYqhuvEb96DzqJT6/nLuan8FkA40mU4Lggg5Ujo1OdIK3Ca5GolM7HStTct4DnU02UKuXTrqoL5umGTfKQ==",
|
"integrity": "sha512-4vtuyp+IhB8FUdxnizwytYFYP7Uxdr0thFCEuT3p7T7v4HzwEIk1uingaO32Z4AD72LUNuzznnRTZNyd59VU7w==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-compression": "~29.2.4"
|
"@syncfusion/ej2-compression": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-popups": {
|
"node_modules/@syncfusion/ej2-popups": {
|
||||||
"version": "29.2.8",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-popups/-/ej2-popups-29.2.8.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-popups/-/ej2-popups-30.1.37.tgz",
|
||||||
"integrity": "sha512-LsXfTiFd6dyoE8XIxFOgC24TeQCqgLdjp3VOg0tWvyuWiZ/skH2sBlF2Y1CWqNJS07OKhtcjLY1h446RTBlalQ==",
|
"integrity": "sha512-royzgtNf2BE330yBySDvLcnMHfDq1xxFKK4YocQJt5PAdYrm5mxIAmxrbbAO0LElI4GN0yQU8Xy4ne7VjqPzJg==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.4",
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-buttons": "~29.2.5"
|
"@syncfusion/ej2-buttons": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-react-base": {
|
"node_modules/@syncfusion/ej2-react-base": {
|
||||||
"version": "29.2.4",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-react-base/-/ej2-react-base-29.2.4.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-react-base/-/ej2-react-base-30.1.37.tgz",
|
||||||
"integrity": "sha512-Yri3M0IU6JJyrdLi+r7Ai1cejRwvOkqTxpZ/TG6gqcf2jaisvbATq0SrrTYXeFsXmHGpjfg6aCUtkRoexYwmrg==",
|
"integrity": "sha512-9Mr+gGR9fb9ywlvXLU/sROH7qcQl/rnITR9wVndKtLP0kCULIAl0QVjaBP4krVIrV5rKIqpL4dEXOJhNVXwgNQ==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.4"
|
"@syncfusion/ej2-base": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-react-buttons": {
|
"node_modules/@syncfusion/ej2-react-buttons": {
|
||||||
"version": "29.2.5",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-react-buttons/-/ej2-react-buttons-29.2.5.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-react-buttons/-/ej2-react-buttons-30.1.37.tgz",
|
||||||
"integrity": "sha512-L7XH6Tr7Eyq99xTpPWdcuCOXs0f6d1EjSO+ppjOcmiskdQMxCJO+Soew4ABzRHVamulmpkzlTzRsqJjtHn75fw==",
|
"integrity": "sha512-QWvVNwfDBk9bZTM1otAmjGK9b8GeA/d1+/Db6skgBDcVzyQUBh26rCJeKMKOnyg/8DratkUG1VdfuhKL5YAMvA==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.4",
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-buttons": "29.2.5",
|
"@syncfusion/ej2-buttons": "30.1.37",
|
||||||
"@syncfusion/ej2-react-base": "~29.2.4"
|
"@syncfusion/ej2-react-base": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-react-calendars": {
|
"node_modules/@syncfusion/ej2-react-calendars": {
|
||||||
"version": "29.2.11",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-react-calendars/-/ej2-react-calendars-29.2.11.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-react-calendars/-/ej2-react-calendars-30.1.37.tgz",
|
||||||
"integrity": "sha512-o6SzmhR9Cuew0y6lijOPniyyJqHzuGoVtDFxp10/x+Tm2Ab1tyXgxpC2jqZLt0SFXcBl2l01h50Xnf0MZnEJSw==",
|
"integrity": "sha512-RDHxN2q1Pj+yIfZIm9qyFMvQdrpWXGXIh51o3CREKViD26R2ykh5WmI6JICvgp+Mru1VS3nEIzzsXEsIDrwoaw==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.11",
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-calendars": "29.2.11",
|
"@syncfusion/ej2-calendars": "30.1.37",
|
||||||
"@syncfusion/ej2-react-base": "~29.2.4"
|
"@syncfusion/ej2-react-base": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-react-grids": {
|
"node_modules/@syncfusion/ej2-react-grids": {
|
||||||
"version": "29.2.11",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-react-grids/-/ej2-react-grids-29.2.11.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-react-grids/-/ej2-react-grids-30.1.37.tgz",
|
||||||
"integrity": "sha512-HHSEb4ZpcncY/8QV+wbsR8ZVArnsGinwv9kLi2sGwJhS3yKm83aXAMojvPYSv1h5jX8ujnR0Y/YSi6MTYL4O+g==",
|
"integrity": "sha512-QNnvwD88GYezX9glpGUEltFmUCKZORXz7w93BS2CfgTxsjJjdaZ8xzDi98J+aAUrUh6I44pMut5Sfb9QOBFH+g==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.11",
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-grids": "29.2.11",
|
"@syncfusion/ej2-grids": "30.1.37",
|
||||||
"@syncfusion/ej2-react-base": "~29.2.4"
|
"@syncfusion/ej2-react-base": "~30.1.37"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"node_modules/@syncfusion/ej2-react-kanban": {
|
||||||
|
"version": "30.1.37",
|
||||||
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-react-kanban/-/ej2-react-kanban-30.1.37.tgz",
|
||||||
|
"integrity": "sha512-lcUwtLNBodSSHYQhYlG4ZiMt4kqQQLjoDBYuFu1GhDimshonwxkXEk+ekgPSHtgJFDJX5YEca/XT5jlm6gxBKw==",
|
||||||
|
"license": "SEE LICENSE IN license",
|
||||||
|
"dependencies": {
|
||||||
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
|
"@syncfusion/ej2-kanban": "30.1.37",
|
||||||
|
"@syncfusion/ej2-react-base": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-react-schedule": {
|
"node_modules/@syncfusion/ej2-react-schedule": {
|
||||||
"version": "29.2.10",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-react-schedule/-/ej2-react-schedule-29.2.10.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-react-schedule/-/ej2-react-schedule-30.1.37.tgz",
|
||||||
"integrity": "sha512-Ud3c5qrjY+NT9VPg3OoQ4YxnVYNj9Xi/12VVJS6cxbs0b91oXzoBSmQpoBVvFefVH0EUaRk7D9ILBs2TZIJj/Q==",
|
"integrity": "sha512-Lw+9CYk6gLobmjWtt5dmsWkAXwgDb8IrNLyfkC9sos6ym0C4skR80gW0BP1n5xTZrWjtZSW1dMUlbMcyknus8w==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.4",
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-react-base": "~29.2.4",
|
"@syncfusion/ej2-react-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-schedule": "29.2.10"
|
"@syncfusion/ej2-schedule": "30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-schedule": {
|
"node_modules/@syncfusion/ej2-schedule": {
|
||||||
"version": "29.2.10",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-schedule/-/ej2-schedule-29.2.10.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-schedule/-/ej2-schedule-30.1.37.tgz",
|
||||||
"integrity": "sha512-PWbxLWfVCNxuEAyZos5c7Ne8lfXhQKR9vN4CNy+yMjRoO+rejI1/sH9iOeKpjCsVmO+ucZuG4IwPCz+qypQtsw==",
|
"integrity": "sha512-1VGVuTYgqPIeVwcAqcbpoT18F+gygX+PP9e+oxDzQzSzi/YVYhNRFxrwzfm4Mhx/JLKArCn7Wr8WSidX+t9xow==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.4",
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-buttons": "~29.2.5",
|
"@syncfusion/ej2-buttons": "~30.1.37",
|
||||||
"@syncfusion/ej2-calendars": "~29.2.10",
|
"@syncfusion/ej2-calendars": "~30.1.37",
|
||||||
"@syncfusion/ej2-data": "~29.2.4",
|
"@syncfusion/ej2-data": "~30.1.37",
|
||||||
"@syncfusion/ej2-dropdowns": "~29.2.10",
|
"@syncfusion/ej2-dropdowns": "~30.1.37",
|
||||||
"@syncfusion/ej2-excel-export": "~29.2.4",
|
"@syncfusion/ej2-excel-export": "~30.1.37",
|
||||||
"@syncfusion/ej2-inputs": "~29.2.5",
|
"@syncfusion/ej2-inputs": "~30.1.37",
|
||||||
"@syncfusion/ej2-lists": "~29.2.4",
|
"@syncfusion/ej2-lists": "~30.1.37",
|
||||||
"@syncfusion/ej2-navigations": "~29.2.8",
|
"@syncfusion/ej2-navigations": "~30.1.37",
|
||||||
"@syncfusion/ej2-popups": "~29.2.8"
|
"@syncfusion/ej2-popups": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@syncfusion/ej2-splitbuttons": {
|
"node_modules/@syncfusion/ej2-splitbuttons": {
|
||||||
"version": "29.2.4",
|
"version": "30.1.37",
|
||||||
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-splitbuttons/-/ej2-splitbuttons-29.2.4.tgz",
|
"resolved": "https://registry.npmjs.org/@syncfusion/ej2-splitbuttons/-/ej2-splitbuttons-30.1.37.tgz",
|
||||||
"integrity": "sha512-sZKs0IZJ6+rDK2OLRl+m5Rs1ai84GE9NV2hpDG5CPFv5uM5WoOf33qYOyp6BSuBerpobpycoXDWH/mh1fZSCDw==",
|
"integrity": "sha512-V4MNbw8qBNumd7B4AlbmndxXGqILcSUoCrA+wBfLt6KZArZnuK8Y2zaD7fN9xoR1c/hoxlgo9sXyIxdPfi9Lyg==",
|
||||||
"license": "SEE LICENSE IN license",
|
"license": "SEE LICENSE IN license",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-base": "~29.2.4",
|
"@syncfusion/ej2-base": "~30.1.37",
|
||||||
"@syncfusion/ej2-popups": "~29.2.4"
|
"@syncfusion/ej2-popups": "~30.1.37"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@tailwindcss/aspect-ratio": {
|
"node_modules/@tailwindcss/aspect-ratio": {
|
||||||
|
|||||||
@@ -10,10 +10,11 @@
|
|||||||
"preview": "vite preview"
|
"preview": "vite preview"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@syncfusion/ej2-react-buttons": "^29.2.5",
|
"@syncfusion/ej2-react-buttons": "^30.1.37",
|
||||||
"@syncfusion/ej2-react-calendars": "^29.2.11",
|
"@syncfusion/ej2-react-calendars": "^30.1.37",
|
||||||
"@syncfusion/ej2-react-grids": "^29.2.11",
|
"@syncfusion/ej2-react-grids": "^30.1.37",
|
||||||
"@syncfusion/ej2-react-schedule": "^29.2.10",
|
"@syncfusion/ej2-react-kanban": "^30.1.37",
|
||||||
|
"@syncfusion/ej2-react-schedule": "^30.1.37",
|
||||||
"cldr-data": "^36.0.4",
|
"cldr-data": "^36.0.4",
|
||||||
"lucide-react": "^0.522.0",
|
"lucide-react": "^0.522.0",
|
||||||
"react": "^19.1.0",
|
"react": "^19.1.0",
|
||||||
|
|||||||
@@ -8,4 +8,9 @@
|
|||||||
@import "../node_modules/@syncfusion/ej2-popups/styles/material.css";
|
@import "../node_modules/@syncfusion/ej2-popups/styles/material.css";
|
||||||
@import "../node_modules/@syncfusion/ej2-splitbuttons/styles/material.css";
|
@import "../node_modules/@syncfusion/ej2-splitbuttons/styles/material.css";
|
||||||
@import "../node_modules/@syncfusion/ej2-react-schedule/styles/material.css";
|
@import "../node_modules/@syncfusion/ej2-react-schedule/styles/material.css";
|
||||||
|
@import "../node_modules/@syncfusion/ej2-kanban/styles/material.css";
|
||||||
|
|
||||||
|
body {
|
||||||
|
font-family: Inter, 'Segoe UI', Roboto, Arial, sans-serif;
|
||||||
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -12,7 +12,8 @@ import {
|
|||||||
User,
|
User,
|
||||||
Settings,
|
Settings,
|
||||||
Monitor,
|
Monitor,
|
||||||
MonitorDotIcon
|
MonitorDotIcon,
|
||||||
|
LogOut,
|
||||||
} from 'lucide-react';
|
} from 'lucide-react';
|
||||||
|
|
||||||
const sidebarItems = [
|
const sidebarItems = [
|
||||||
@@ -20,7 +21,7 @@ const sidebarItems = [
|
|||||||
{ name: 'Termine', path: '/termine', icon: Calendar },
|
{ name: 'Termine', path: '/termine', icon: Calendar },
|
||||||
{ name: 'Ressourcen', path: '/ressourcen', icon: Boxes },
|
{ name: 'Ressourcen', path: '/ressourcen', icon: Boxes },
|
||||||
{ name: 'Infoscreens', path: '/Infoscreens', icon: Monitor },
|
{ name: 'Infoscreens', path: '/Infoscreens', icon: Monitor },
|
||||||
{ name: 'Gruppen', path: '/gruppen', icon: MonitorDotIcon },
|
{ name: 'Gruppen', path: '/infoscr_groups', icon: MonitorDotIcon },
|
||||||
{ name: 'Medien', path: '/medien', icon: Image },
|
{ name: 'Medien', path: '/medien', icon: Image },
|
||||||
{ name: 'Benutzer', path: '/benutzer', icon: User },
|
{ name: 'Benutzer', path: '/benutzer', icon: User },
|
||||||
{ name: 'Einstellungen', path: '/einstellungen', icon: Settings },
|
{ name: 'Einstellungen', path: '/einstellungen', icon: Settings },
|
||||||
@@ -54,9 +55,21 @@ const Layout: React.FC = () => {
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<button
|
<button
|
||||||
className="p-2 focus:outline-none hover:bg-[#d6c3a6] transition-colors"
|
className="p-2 focus:outline-none transition-colors"
|
||||||
|
style={{
|
||||||
|
backgroundColor: '#e5d8c7',
|
||||||
|
color: '#78591c',
|
||||||
|
}}
|
||||||
onClick={() => setCollapsed(!collapsed)}
|
onClick={() => setCollapsed(!collapsed)}
|
||||||
aria-label={collapsed ? 'Sidebar ausklappen' : 'Sidebar einklappen'}
|
aria-label={collapsed ? 'Sidebar ausklappen' : 'Sidebar einklappen'}
|
||||||
|
onMouseEnter={e => {
|
||||||
|
e.currentTarget.style.backgroundColor = '#78591c';
|
||||||
|
e.currentTarget.style.color = '#e5d8c7';
|
||||||
|
}}
|
||||||
|
onMouseLeave={e => {
|
||||||
|
e.currentTarget.style.backgroundColor = '#e5d8c7';
|
||||||
|
e.currentTarget.style.color = '#78591c';
|
||||||
|
}}
|
||||||
>
|
>
|
||||||
<span style={{ fontSize: 20 }}>{collapsed ? '▶' : '◀'}</span>
|
<span style={{ fontSize: 20 }}>{collapsed ? '▶' : '◀'}</span>
|
||||||
</button>
|
</button>
|
||||||
@@ -92,6 +105,38 @@ const Layout: React.FC = () => {
|
|||||||
);
|
);
|
||||||
})}
|
})}
|
||||||
</nav>
|
</nav>
|
||||||
|
{/* Abmelden-Button immer ganz unten */}
|
||||||
|
<div className="mb-4 mt-auto">
|
||||||
|
<button
|
||||||
|
className="flex items-center gap-3 px-6 py-3 w-full transition-colors no-underline"
|
||||||
|
style={{
|
||||||
|
color: '#78591c',
|
||||||
|
backgroundColor: '#e5d8c7',
|
||||||
|
border: 'none',
|
||||||
|
fontWeight: 500,
|
||||||
|
cursor: 'pointer',
|
||||||
|
textAlign: 'left',
|
||||||
|
fontSize: '1.15rem',
|
||||||
|
width: '100%',
|
||||||
|
}}
|
||||||
|
title={collapsed ? 'Abmelden' : undefined}
|
||||||
|
onClick={() => {
|
||||||
|
// Hier ggf. Logout-Logik einfügen
|
||||||
|
window.location.href = '/logout';
|
||||||
|
}}
|
||||||
|
onMouseEnter={e => {
|
||||||
|
e.currentTarget.style.backgroundColor = '#78591c';
|
||||||
|
e.currentTarget.style.color = '#e5d8c7';
|
||||||
|
}}
|
||||||
|
onMouseLeave={e => {
|
||||||
|
e.currentTarget.style.backgroundColor = '#e5d8c7';
|
||||||
|
e.currentTarget.style.color = '#78591c';
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<LogOut size={22} />
|
||||||
|
{!collapsed && 'Abmelden'}
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
</aside>
|
</aside>
|
||||||
{/* Main Content */}
|
{/* Main Content */}
|
||||||
<div className="flex-1 flex flex-col">
|
<div className="flex-1 flex flex-col">
|
||||||
@@ -134,7 +179,7 @@ const App: React.FC = () => (
|
|||||||
<Route path="termine" element={<Appointments />} />
|
<Route path="termine" element={<Appointments />} />
|
||||||
<Route path="ressourcen" element={<Ressourcen />} />
|
<Route path="ressourcen" element={<Ressourcen />} />
|
||||||
<Route path="Infoscreens" element={<Infoscreens />} />
|
<Route path="Infoscreens" element={<Infoscreens />} />
|
||||||
<Route path="gruppen" element={<Gruppen />} />
|
<Route path="infoscr_groups" element={<Infoscreen_groups />} />
|
||||||
<Route path="medien" element={<Medien />} />
|
<Route path="medien" element={<Medien />} />
|
||||||
<Route path="benutzer" element={<Benutzer />} />
|
<Route path="benutzer" element={<Benutzer />} />
|
||||||
<Route path="einstellungen" element={<Einstellungen />} />
|
<Route path="einstellungen" element={<Einstellungen />} />
|
||||||
@@ -150,7 +195,7 @@ import Dashboard from './dashboard';
|
|||||||
import Appointments from './appointments';
|
import Appointments from './appointments';
|
||||||
import Ressourcen from './ressourcen';
|
import Ressourcen from './ressourcen';
|
||||||
import Infoscreens from './clients';
|
import Infoscreens from './clients';
|
||||||
import Gruppen from './gruppen';
|
import Infoscreen_groups from './infoscreen_groups';
|
||||||
import Medien from './medien';
|
import Medien from './medien';
|
||||||
import Benutzer from './benutzer';
|
import Benutzer from './benutzer';
|
||||||
import Einstellungen from './einstellungen';
|
import Einstellungen from './einstellungen';
|
||||||
|
|||||||
@@ -6,6 +6,7 @@ export interface Client {
|
|||||||
hardware_hash: string;
|
hardware_hash: string;
|
||||||
ip_address: string;
|
ip_address: string;
|
||||||
last_alive: string | null;
|
last_alive: string | null;
|
||||||
|
group_id: number; // <--- Dieses Feld ergänzen
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function fetchClients(): Promise<Client[]> {
|
export async function fetchClients(): Promise<Client[]> {
|
||||||
@@ -15,3 +16,13 @@ export async function fetchClients(): Promise<Client[]> {
|
|||||||
}
|
}
|
||||||
return await response.json();
|
return await response.json();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export async function updateClientGroup(clientIds: string[], groupName: string) {
|
||||||
|
const res = await fetch('/api/clients/group', {
|
||||||
|
method: 'PUT',
|
||||||
|
headers: { 'Content-Type': 'application/json' },
|
||||||
|
body: JSON.stringify({ client_ids: clientIds, group_name: groupName }),
|
||||||
|
});
|
||||||
|
if (!res.ok) throw new Error('Fehler beim Aktualisieren der Clients');
|
||||||
|
return await res.json();
|
||||||
|
}
|
||||||
|
|||||||
19
dashboard/src/apiGroups.ts
Normal file
19
dashboard/src/apiGroups.ts
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
export async function createGroup(name: string) {
|
||||||
|
const res = await fetch('/api/groups', {
|
||||||
|
method: 'POST',
|
||||||
|
headers: { 'Content-Type': 'application/json' },
|
||||||
|
body: JSON.stringify({ name }),
|
||||||
|
});
|
||||||
|
if (!res.ok) throw new Error('Fehler beim Erstellen der Gruppe');
|
||||||
|
return await res.json();
|
||||||
|
}
|
||||||
|
|
||||||
|
export async function fetchGroups() {
|
||||||
|
const res = await fetch('/api/groups');
|
||||||
|
if (!res.ok) throw new Error('Fehler beim Laden der Gruppen');
|
||||||
|
return await res.json();
|
||||||
|
}
|
||||||
|
|
||||||
|
// Hier kannst du später weitere Funktionen ergänzen:
|
||||||
|
// export async function deleteGroup(id: number) { ... }
|
||||||
|
// export async function updateGroup(id: number, name: string) { ... }
|
||||||
@@ -13,9 +13,8 @@ const Dashboard: React.FC = () => {
|
|||||||
<div>
|
<div>
|
||||||
<header className="mb-8 pb-4 border-b-2 border-[#d6c3a6]">
|
<header className="mb-8 pb-4 border-b-2 border-[#d6c3a6]">
|
||||||
<h2 className="text-3xl font-extrabold mb-2">Dashboard</h2>
|
<h2 className="text-3xl font-extrabold mb-2">Dashboard</h2>
|
||||||
<p className="text-lg">Willkommen im Infoscreen-Management Dashboard.</p>
|
|
||||||
</header>
|
</header>
|
||||||
<h3 className="text-lg font-semibold mt-6 mb-4">Clients</h3>
|
<h3 className="text-lg font-semibold mt-6 mb-4">Infoscreens</h3>
|
||||||
<div className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6">
|
<div className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6">
|
||||||
{clients.map(client => (
|
{clients.map(client => (
|
||||||
<div key={client.uuid} className="bg-white rounded shadow p-4 flex flex-col items-center">
|
<div key={client.uuid} className="bg-white rounded shadow p-4 flex flex-col items-center">
|
||||||
|
|||||||
@@ -1,8 +0,0 @@
|
|||||||
import React from 'react';
|
|
||||||
const Gruppen: React.FC = () => (
|
|
||||||
<div>
|
|
||||||
<h2 className="text-xl font-bold mb-4">Gruppen</h2>
|
|
||||||
<p>Willkommen im Infoscreen-Management Gruppen.</p>
|
|
||||||
</div>
|
|
||||||
);
|
|
||||||
export default Gruppen;
|
|
||||||
203
dashboard/src/infoscreen_groups.tsx
Normal file
203
dashboard/src/infoscreen_groups.tsx
Normal file
@@ -0,0 +1,203 @@
|
|||||||
|
import React, { useEffect, useState, useRef } from 'react';
|
||||||
|
import { KanbanComponent, ColumnsDirective, ColumnDirective } from '@syncfusion/ej2-react-kanban';
|
||||||
|
import { fetchClients, updateClientGroup } from './apiClients';
|
||||||
|
import { fetchGroups, createGroup } from './apiGroups';
|
||||||
|
import type { Client } from './apiClients';
|
||||||
|
import type { KanbanComponent as KanbanComponentType } from '@syncfusion/ej2-react-kanban';
|
||||||
|
|
||||||
|
interface KanbanClient extends Client {
|
||||||
|
Id: string;
|
||||||
|
Status: string; // Raumgruppe (Gruppenname)
|
||||||
|
Summary: string; // Anzeigename
|
||||||
|
}
|
||||||
|
|
||||||
|
interface Group {
|
||||||
|
id: number;
|
||||||
|
name: string;
|
||||||
|
// weitere Felder möglich
|
||||||
|
}
|
||||||
|
|
||||||
|
interface KanbanDragEventArgs {
|
||||||
|
element: HTMLElement | HTMLElement[];
|
||||||
|
data: KanbanClient | KanbanClient[];
|
||||||
|
event?: { event?: MouseEvent };
|
||||||
|
[key: string]: unknown;
|
||||||
|
}
|
||||||
|
|
||||||
|
const Infoscreen_groups: React.FC = () => {
|
||||||
|
const [clients, setClients] = useState<KanbanClient[]>([]);
|
||||||
|
const [groups, setGroups] = useState<{ keyField: string; headerText: string }[]>([]);
|
||||||
|
const [showDialog, setShowDialog] = useState(false);
|
||||||
|
const [newGroupName, setNewGroupName] = useState('');
|
||||||
|
const [draggedCard, setDraggedCard] = useState<{ id: string; fromColumn: string } | null>(null);
|
||||||
|
const kanbanRef = useRef<KanbanComponentType | null>(null); // Ref für Kanban
|
||||||
|
|
||||||
|
// Lade Gruppen und Clients
|
||||||
|
useEffect(() => {
|
||||||
|
let groupMap: Record<number, string> = {};
|
||||||
|
fetchGroups().then((groupData: Group[]) => {
|
||||||
|
const kanbanGroups = groupData.map(g => ({
|
||||||
|
keyField: g.name,
|
||||||
|
headerText: g.name,
|
||||||
|
id: g.id,
|
||||||
|
}));
|
||||||
|
setGroups(kanbanGroups);
|
||||||
|
|
||||||
|
groupMap = Object.fromEntries(groupData.map(g => [g.id, g.name]));
|
||||||
|
|
||||||
|
fetchClients().then(data => {
|
||||||
|
setClients(
|
||||||
|
data.map((c, i) => ({
|
||||||
|
...c,
|
||||||
|
Id: c.uuid,
|
||||||
|
Status: groupMap[c.group_id] || 'Nicht zugeordnet',
|
||||||
|
Summary: c.location || `Client ${i + 1}`,
|
||||||
|
}))
|
||||||
|
);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}, []);
|
||||||
|
|
||||||
|
// Neue Gruppe anlegen (persistiert per API)
|
||||||
|
const handleAddGroup = async () => {
|
||||||
|
if (!newGroupName.trim()) return;
|
||||||
|
try {
|
||||||
|
const newGroup = await createGroup(newGroupName);
|
||||||
|
setGroups([...groups, { keyField: newGroup.name, headerText: newGroup.name }]);
|
||||||
|
setNewGroupName('');
|
||||||
|
setShowDialog(false);
|
||||||
|
} catch {
|
||||||
|
alert('Fehler beim Erstellen der Gruppe');
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
const handleDragStart = (args: KanbanDragEventArgs) => {
|
||||||
|
const element = Array.isArray(args.element) ? args.element[0] : args.element;
|
||||||
|
const cardId = element.getAttribute('data-id');
|
||||||
|
const fromColumn = element.getAttribute('data-key');
|
||||||
|
setDraggedCard({ id: cardId || '', fromColumn: fromColumn || '' });
|
||||||
|
};
|
||||||
|
|
||||||
|
const handleCardDrop = async (args: KanbanDragEventArgs) => {
|
||||||
|
if (!draggedCard) return;
|
||||||
|
|
||||||
|
const mouseEvent = args.event?.event;
|
||||||
|
let targetGroupName = '';
|
||||||
|
|
||||||
|
if (mouseEvent && mouseEvent.clientX && mouseEvent.clientY) {
|
||||||
|
const targetElement = document.elementFromPoint(mouseEvent.clientX, mouseEvent.clientY);
|
||||||
|
const kanbanColumn =
|
||||||
|
targetElement?.closest('[data-key]') || targetElement?.closest('.e-content-row');
|
||||||
|
if (kanbanColumn) {
|
||||||
|
const columnKey = kanbanColumn.getAttribute('data-key');
|
||||||
|
if (columnKey) {
|
||||||
|
targetGroupName = columnKey;
|
||||||
|
} else {
|
||||||
|
const headerElement = kanbanColumn.querySelector('.e-header-text');
|
||||||
|
targetGroupName = headerElement?.textContent?.trim() || '';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Fallback
|
||||||
|
if (!targetGroupName) {
|
||||||
|
const targetElement = Array.isArray(args.element) ? args.element[0] : args.element;
|
||||||
|
const cardWrapper = targetElement.closest('.e-card-wrapper');
|
||||||
|
const contentRow = cardWrapper?.closest('.e-content-row');
|
||||||
|
const headerText = contentRow?.querySelector('.e-header-text');
|
||||||
|
targetGroupName = headerText?.textContent?.trim() || '';
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!targetGroupName || targetGroupName === draggedCard.fromColumn) {
|
||||||
|
setDraggedCard(null);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
const dropped = Array.isArray(args.data) ? args.data : [args.data];
|
||||||
|
const clientIds = dropped.map((card: KanbanClient) => card.Id);
|
||||||
|
|
||||||
|
try {
|
||||||
|
await updateClientGroup(clientIds, targetGroupName);
|
||||||
|
fetchGroups().then((groupData: Group[]) => {
|
||||||
|
const groupMap = Object.fromEntries(groupData.map(g => [g.id, g.name]));
|
||||||
|
setGroups(
|
||||||
|
groupData.map(g => ({
|
||||||
|
keyField: g.name,
|
||||||
|
headerText: g.name,
|
||||||
|
id: g.id,
|
||||||
|
}))
|
||||||
|
);
|
||||||
|
fetchClients().then(data => {
|
||||||
|
setClients(
|
||||||
|
data.map((c, i) => ({
|
||||||
|
...c,
|
||||||
|
Id: c.uuid,
|
||||||
|
Status: groupMap[c.group_id] || 'Nicht zugeordnet',
|
||||||
|
Summary: c.location || `Client ${i + 1}`,
|
||||||
|
}))
|
||||||
|
);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
} catch {
|
||||||
|
alert('Fehler beim Aktualisieren der Clients');
|
||||||
|
}
|
||||||
|
setDraggedCard(null);
|
||||||
|
};
|
||||||
|
|
||||||
|
return (
|
||||||
|
<div>
|
||||||
|
<h2 className="text-xl font-bold mb-4">Gruppen</h2>
|
||||||
|
<button
|
||||||
|
className="mb-4 px-4 py-2 bg-blue-500 text-white rounded"
|
||||||
|
onClick={() => setShowDialog(true)}
|
||||||
|
>
|
||||||
|
Neue Raumgruppe
|
||||||
|
</button>
|
||||||
|
<KanbanComponent
|
||||||
|
id="kanban"
|
||||||
|
keyField="Status"
|
||||||
|
dataSource={clients}
|
||||||
|
cardSettings={{
|
||||||
|
headerField: 'Summary',
|
||||||
|
selectionType: 'Multiple',
|
||||||
|
}}
|
||||||
|
allowDragAndDrop={true}
|
||||||
|
dragStart={handleDragStart}
|
||||||
|
dragStop={handleCardDrop}
|
||||||
|
ref={kanbanRef} // Ref zuweisen
|
||||||
|
>
|
||||||
|
<ColumnsDirective>
|
||||||
|
{groups.map(group => (
|
||||||
|
<ColumnDirective key={group.keyField} {...group} />
|
||||||
|
))}
|
||||||
|
</ColumnsDirective>
|
||||||
|
</KanbanComponent>
|
||||||
|
{showDialog && (
|
||||||
|
<div className="fixed inset-0 bg-black bg-opacity-30 flex items-center justify-center">
|
||||||
|
<div className="bg-white p-6 rounded shadow">
|
||||||
|
<h3 className="mb-2 font-bold">Neue Raumgruppe</h3>
|
||||||
|
<input
|
||||||
|
className="border p-2 mb-2 w-full"
|
||||||
|
value={newGroupName}
|
||||||
|
onChange={e => setNewGroupName(e.target.value)}
|
||||||
|
placeholder="Raumname"
|
||||||
|
/>
|
||||||
|
<div className="flex gap-2">
|
||||||
|
<button className="bg-blue-500 text-white px-4 py-2 rounded" onClick={handleAddGroup}>
|
||||||
|
Hinzufügen
|
||||||
|
</button>
|
||||||
|
<button
|
||||||
|
className="bg-gray-300 px-4 py-2 rounded"
|
||||||
|
onClick={() => setShowDialog(false)}
|
||||||
|
>
|
||||||
|
Abbrechen
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
export default Infoscreen_groups;
|
||||||
@@ -5,7 +5,7 @@ import App from './App.tsx';
|
|||||||
import { registerLicense } from '@syncfusion/ej2-base';
|
import { registerLicense } from '@syncfusion/ej2-base';
|
||||||
|
|
||||||
// Setze hier deinen Lizenzschlüssel ein
|
// Setze hier deinen Lizenzschlüssel ein
|
||||||
registerLicense('Ngo9BigBOggjHTQxAR8/V1NNaF1cWWhPYVFxWmFZfVtgd19FaFZRQ2Y/P1ZhSXxWdkNhWX5bc3xVQWZUUkF9XUs=');
|
registerLicense('ORg4AjUWIQA/Gnt3VVhhQlJDfV5AQmBIYVp/TGpJfl96cVxMZVVBJAtUQF1hTH5VdENiXX1dcHxUQWNVWkd2');
|
||||||
|
|
||||||
createRoot(document.getElementById('root')!).render(
|
createRoot(document.getElementById('root')!).render(
|
||||||
<StrictMode>
|
<StrictMode>
|
||||||
|
|||||||
@@ -0,0 +1,57 @@
|
|||||||
|
"""Add client_groups table and group_id to clients
|
||||||
|
|
||||||
|
Revision ID: 8a45ec34f84d
|
||||||
|
Revises: c1178d5fa549
|
||||||
|
Create Date: 2025-06-26 18:40:10.988281
|
||||||
|
|
||||||
|
"""
|
||||||
|
from typing import Sequence, Union
|
||||||
|
|
||||||
|
from alembic import op
|
||||||
|
import sqlalchemy as sa
|
||||||
|
|
||||||
|
|
||||||
|
# revision identifiers, used by Alembic.
|
||||||
|
revision: str = '8a45ec34f84d'
|
||||||
|
down_revision: Union[str, None] = 'c1178d5fa549'
|
||||||
|
branch_labels: Union[str, Sequence[str], None] = None
|
||||||
|
depends_on: Union[str, Sequence[str], None] = None
|
||||||
|
|
||||||
|
|
||||||
|
def upgrade() -> None:
|
||||||
|
"""Upgrade schema."""
|
||||||
|
# 1. Neue Tabelle anlegen
|
||||||
|
op.create_table(
|
||||||
|
'client_groups',
|
||||||
|
sa.Column('id', sa.Integer(), autoincrement=True, nullable=False),
|
||||||
|
sa.Column('name', sa.String(length=100), nullable=False),
|
||||||
|
sa.Column('created_at', sa.TIMESTAMP(timezone=True),
|
||||||
|
server_default=sa.text('CURRENT_TIMESTAMP'), nullable=True),
|
||||||
|
sa.Column('is_active', sa.Boolean(), nullable=False),
|
||||||
|
sa.PrimaryKeyConstraint('id'),
|
||||||
|
sa.UniqueConstraint('name')
|
||||||
|
)
|
||||||
|
# 2. Gruppe "Nicht zugeordnet" mit id=0 anlegen
|
||||||
|
op.execute(
|
||||||
|
"INSERT INTO client_groups (id, name, is_active) VALUES (0, 'Nicht zugeordnet', true)")
|
||||||
|
|
||||||
|
# 3. Spalte group_id mit Default 0 hinzufügen
|
||||||
|
op.add_column('clients', sa.Column('group_id', sa.Integer(),
|
||||||
|
nullable=False, server_default='0'))
|
||||||
|
|
||||||
|
# 4. Für alle bestehenden Clients group_id auf 0 setzen (optional, falls Daten vorhanden)
|
||||||
|
op.execute("UPDATE clients SET group_id = 0 WHERE group_id IS NULL")
|
||||||
|
|
||||||
|
# 5. Foreign Key Constraint setzen
|
||||||
|
op.create_foreign_key(None, 'clients', 'client_groups', [
|
||||||
|
'group_id'], ['id'])
|
||||||
|
# ### end Alembic commands ###
|
||||||
|
|
||||||
|
|
||||||
|
def downgrade() -> None:
|
||||||
|
"""Downgrade schema."""
|
||||||
|
# ### commands auto generated by Alembic - please adjust! ###
|
||||||
|
op.drop_constraint(None, 'clients', type_='foreignkey')
|
||||||
|
op.drop_column('clients', 'group_id')
|
||||||
|
op.drop_table('client_groups')
|
||||||
|
# ### end Alembic commands ###
|
||||||
45
server/dummy_clients.py
Normal file
45
server/dummy_clients.py
Normal file
@@ -0,0 +1,45 @@
|
|||||||
|
from sqlalchemy import create_engine
|
||||||
|
from sqlalchemy.orm import sessionmaker
|
||||||
|
from models import Client
|
||||||
|
from dotenv import load_dotenv
|
||||||
|
import os
|
||||||
|
from datetime import datetime, timedelta
|
||||||
|
import random
|
||||||
|
import uuid
|
||||||
|
|
||||||
|
# .env laden
|
||||||
|
load_dotenv()
|
||||||
|
|
||||||
|
DB_USER = os.getenv("DB_USER")
|
||||||
|
DB_PASSWORD = os.getenv("DB_PASSWORD")
|
||||||
|
DB_HOST = os.getenv("DB_HOST")
|
||||||
|
DB_NAME = os.getenv("DB_NAME")
|
||||||
|
|
||||||
|
db_conn_str = f"mysql+pymysql://{DB_USER}:{DB_PASSWORD}@{DB_HOST}/{DB_NAME}"
|
||||||
|
engine = create_engine(db_conn_str)
|
||||||
|
Session = sessionmaker(bind=engine)
|
||||||
|
session = Session()
|
||||||
|
|
||||||
|
# Dummy-Clients erzeugen
|
||||||
|
locations = [
|
||||||
|
"Raum 101",
|
||||||
|
"Raum 102",
|
||||||
|
"Lehrerzimmer",
|
||||||
|
"Aula",
|
||||||
|
"Bibliothek"
|
||||||
|
]
|
||||||
|
|
||||||
|
for i in range(5):
|
||||||
|
client = Client(
|
||||||
|
uuid=str(uuid.uuid4()),
|
||||||
|
hardware_hash=f"dummyhash{i:02d}",
|
||||||
|
location=locations[i],
|
||||||
|
ip_address=f"192.168.0.{100+i}",
|
||||||
|
registration_time=datetime.now() - timedelta(days=random.randint(1, 30)),
|
||||||
|
last_alive=datetime.now(),
|
||||||
|
is_active=True
|
||||||
|
)
|
||||||
|
session.add(client)
|
||||||
|
|
||||||
|
session.commit()
|
||||||
|
print("5 Dummy-Clients wurden angelegt.")
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
from sqlalchemy import create_engine
|
from sqlalchemy import create_engine
|
||||||
from sqlalchemy.orm import sessionmaker
|
from sqlalchemy.orm import sessionmaker
|
||||||
from models import Event, EventMedia, EventType
|
from models import Event, EventMedia, EventType, Client
|
||||||
from dotenv import load_dotenv
|
from dotenv import load_dotenv
|
||||||
import os
|
import os
|
||||||
from datetime import datetime, timedelta
|
from datetime import datetime, timedelta
|
||||||
@@ -19,22 +19,6 @@ engine = create_engine(db_conn_str)
|
|||||||
Session = sessionmaker(bind=engine)
|
Session = sessionmaker(bind=engine)
|
||||||
session = Session()
|
session = Session()
|
||||||
|
|
||||||
# Beispiel-Events (client_uuid und created_by müssen existieren!)
|
|
||||||
client_uuid = "36671351-7a90-44af-bfef-a192c541373b"
|
|
||||||
created_by = 1 # ID eines existierenden Users
|
|
||||||
|
|
||||||
# --- Alte Testdaten löschen ---
|
|
||||||
# Zuerst alle EventMedia zu den Events dieses Clients löschen
|
|
||||||
event_ids = [e.id for e in session.query(
|
|
||||||
Event.id).filter_by(client_uuid=client_uuid).all()]
|
|
||||||
if event_ids:
|
|
||||||
session.query(EventMedia).filter(EventMedia.event_id.in_(
|
|
||||||
event_ids)).delete(synchronize_session=False)
|
|
||||||
# Dann alle Events dieses Clients löschen
|
|
||||||
session.query(Event).filter_by(client_uuid=client_uuid).delete()
|
|
||||||
session.commit()
|
|
||||||
# --- Ende Löschungen ---
|
|
||||||
|
|
||||||
now = datetime.now()
|
now = datetime.now()
|
||||||
|
|
||||||
|
|
||||||
@@ -47,189 +31,33 @@ def random_time_on_day(day_offset: int, duration_hours: int = 1):
|
|||||||
return start, end
|
return start, end
|
||||||
|
|
||||||
|
|
||||||
events = [
|
# Hole alle Clients aus der Datenbank
|
||||||
Event(
|
clients = session.query(Client).all()
|
||||||
client_uuid=client_uuid,
|
created_by = 1 # Passe ggf. an
|
||||||
title="Mathe Präsentation",
|
|
||||||
description="Präsentation zum Thema Algebra.",
|
|
||||||
start=random_time_on_day(1)[0],
|
|
||||||
end=random_time_on_day(1)[1],
|
|
||||||
event_type=EventType.presentation,
|
|
||||||
created_by=created_by,
|
|
||||||
updated_by=None,
|
|
||||||
is_active=True
|
|
||||||
),
|
|
||||||
Event(
|
|
||||||
client_uuid=client_uuid,
|
|
||||||
title="Schulwebsite Update",
|
|
||||||
description="Neue Inhalte auf der Schulwebsite.",
|
|
||||||
start=random_time_on_day(2)[0],
|
|
||||||
end=random_time_on_day(2)[1],
|
|
||||||
event_type=EventType.website,
|
|
||||||
created_by=created_by,
|
|
||||||
updated_by=None,
|
|
||||||
is_active=True
|
|
||||||
),
|
|
||||||
Event(
|
|
||||||
client_uuid=client_uuid,
|
|
||||||
title="Lehrvideo ansehen",
|
|
||||||
description="Video zum Thema Photosynthese.",
|
|
||||||
start=random_time_on_day(3)[0],
|
|
||||||
end=random_time_on_day(3)[1],
|
|
||||||
event_type=EventType.video,
|
|
||||||
created_by=created_by,
|
|
||||||
updated_by=None,
|
|
||||||
is_active=True
|
|
||||||
),
|
|
||||||
Event(
|
|
||||||
client_uuid=client_uuid,
|
|
||||||
title="Nachricht vom Lehrer",
|
|
||||||
description="Wichtige Mitteilung zum Unterricht.",
|
|
||||||
start=random_time_on_day(4)[0],
|
|
||||||
end=random_time_on_day(4)[1],
|
|
||||||
event_type=EventType.message,
|
|
||||||
created_by=created_by,
|
|
||||||
updated_by=None,
|
|
||||||
is_active=True
|
|
||||||
),
|
|
||||||
Event(
|
|
||||||
client_uuid=client_uuid,
|
|
||||||
title="Sonstiges Event",
|
|
||||||
description="Allgemeines Event ohne Kategorie.",
|
|
||||||
start=random_time_on_day(5)[0],
|
|
||||||
end=random_time_on_day(5)[1],
|
|
||||||
event_type=EventType.other,
|
|
||||||
created_by=created_by,
|
|
||||||
updated_by=None,
|
|
||||||
is_active=True
|
|
||||||
),
|
|
||||||
Event(
|
|
||||||
client_uuid=client_uuid,
|
|
||||||
title="WebUntis Termin",
|
|
||||||
description="Termin aus WebUntis importiert.",
|
|
||||||
start=random_time_on_day(6)[0],
|
|
||||||
end=random_time_on_day(6)[1],
|
|
||||||
event_type=EventType.webuntis,
|
|
||||||
created_by=created_by,
|
|
||||||
updated_by=None,
|
|
||||||
is_active=True
|
|
||||||
),
|
|
||||||
Event(
|
|
||||||
client_uuid=client_uuid,
|
|
||||||
title="Englisch Präsentation",
|
|
||||||
description="Präsentation zu Shakespeare.",
|
|
||||||
start=random_time_on_day(8)[0],
|
|
||||||
end=random_time_on_day(8)[1],
|
|
||||||
event_type=EventType.presentation,
|
|
||||||
created_by=created_by,
|
|
||||||
updated_by=None,
|
|
||||||
is_active=True
|
|
||||||
),
|
|
||||||
Event(
|
|
||||||
client_uuid=client_uuid,
|
|
||||||
title="Website Relaunch",
|
|
||||||
description="Vorstellung der neuen Schulwebsite.",
|
|
||||||
start=random_time_on_day(10)[0],
|
|
||||||
end=random_time_on_day(10)[1],
|
|
||||||
event_type=EventType.website,
|
|
||||||
created_by=created_by,
|
|
||||||
updated_by=None,
|
|
||||||
is_active=True
|
|
||||||
),
|
|
||||||
Event(
|
|
||||||
client_uuid=client_uuid,
|
|
||||||
title="Videoanalyse",
|
|
||||||
description="Analyse eines Lehrvideos.",
|
|
||||||
start=random_time_on_day(12)[0],
|
|
||||||
end=random_time_on_day(12)[1],
|
|
||||||
event_type=EventType.video,
|
|
||||||
created_by=created_by,
|
|
||||||
updated_by=None,
|
|
||||||
is_active=True
|
|
||||||
),
|
|
||||||
Event(
|
|
||||||
client_uuid=client_uuid,
|
|
||||||
title="WebUntis Info",
|
|
||||||
description="Weitere Termine aus WebUntis.",
|
|
||||||
start=random_time_on_day(14)[0],
|
|
||||||
end=random_time_on_day(14)[1],
|
|
||||||
event_type=EventType.webuntis,
|
|
||||||
created_by=created_by,
|
|
||||||
updated_by=None,
|
|
||||||
is_active=True
|
|
||||||
),
|
|
||||||
]
|
|
||||||
|
|
||||||
# Events anlegen und speichern
|
all_events = []
|
||||||
for event in events:
|
|
||||||
|
for client in clients:
|
||||||
|
for i in range(10):
|
||||||
|
day_offset = random.randint(0, 13) # Termine in den nächsten 14 Tagen
|
||||||
|
duration = random.choice([1, 2]) # 1 oder 2 Stunden
|
||||||
|
start, end = random_time_on_day(day_offset, duration)
|
||||||
|
event = Event(
|
||||||
|
client_uuid=client.uuid,
|
||||||
|
title=f"Termin {i+1} für {client.location or client.uuid[:8]}",
|
||||||
|
description=f"Automatisch generierter Termin {i+1} für Client {client.uuid}",
|
||||||
|
start=start,
|
||||||
|
end=end,
|
||||||
|
event_type=random.choice(list(EventType)),
|
||||||
|
created_by=created_by,
|
||||||
|
updated_by=None,
|
||||||
|
is_active=True
|
||||||
|
)
|
||||||
|
all_events.append(event)
|
||||||
|
|
||||||
|
# Events speichern
|
||||||
|
for event in all_events:
|
||||||
session.add(event)
|
session.add(event)
|
||||||
session.commit() # Jetzt haben alle Events eine ID
|
|
||||||
|
|
||||||
# EventMedia mit den richtigen event_id-Werten anlegen
|
|
||||||
event_media = [
|
|
||||||
EventMedia(
|
|
||||||
event_id=events[0].id,
|
|
||||||
media_type=EventType.presentation,
|
|
||||||
url="https://example.com/praesentation-mathe.pdf",
|
|
||||||
order=1
|
|
||||||
),
|
|
||||||
EventMedia(
|
|
||||||
event_id=events[1].id,
|
|
||||||
media_type=EventType.website,
|
|
||||||
url="https://schule.example.com/update",
|
|
||||||
order=1
|
|
||||||
),
|
|
||||||
EventMedia(
|
|
||||||
event_id=events[2].id,
|
|
||||||
media_type=EventType.video,
|
|
||||||
url="https://example.com/photosynthese-video.mp4",
|
|
||||||
order=1
|
|
||||||
),
|
|
||||||
EventMedia(
|
|
||||||
event_id=events[3].id,
|
|
||||||
media_type=EventType.message,
|
|
||||||
url="https://example.com/lehrer-nachricht",
|
|
||||||
order=1
|
|
||||||
),
|
|
||||||
EventMedia(
|
|
||||||
event_id=events[4].id,
|
|
||||||
media_type=EventType.other,
|
|
||||||
url="https://example.com/sonstiges-event.pdf",
|
|
||||||
order=1
|
|
||||||
),
|
|
||||||
EventMedia(
|
|
||||||
event_id=events[5].id,
|
|
||||||
media_type=EventType.webuntis,
|
|
||||||
url="https://webuntis.example.com/termin",
|
|
||||||
order=1
|
|
||||||
),
|
|
||||||
EventMedia(
|
|
||||||
event_id=events[6].id,
|
|
||||||
media_type=EventType.presentation,
|
|
||||||
url="https://example.com/praesentation-englisch.pdf",
|
|
||||||
order=1
|
|
||||||
),
|
|
||||||
EventMedia(
|
|
||||||
event_id=events[7].id,
|
|
||||||
media_type=EventType.website,
|
|
||||||
url="https://schule.example.com/relaunch",
|
|
||||||
order=1
|
|
||||||
),
|
|
||||||
EventMedia(
|
|
||||||
event_id=events[8].id,
|
|
||||||
media_type=EventType.video,
|
|
||||||
url="https://example.com/videoanalyse.mp4",
|
|
||||||
order=1
|
|
||||||
),
|
|
||||||
EventMedia(
|
|
||||||
event_id=events[9].id,
|
|
||||||
media_type=EventType.webuntis,
|
|
||||||
url="https://webuntis.example.com/info",
|
|
||||||
order=1
|
|
||||||
),
|
|
||||||
]
|
|
||||||
|
|
||||||
for media in event_media:
|
|
||||||
session.add(media)
|
|
||||||
session.commit()
|
session.commit()
|
||||||
print("Test-Events und EventMedia wurden angelegt.")
|
|
||||||
|
print(f"{len(all_events)} Termine für {len(clients)} Clients wurden angelegt.")
|
||||||
|
|||||||
@@ -6,11 +6,13 @@ import enum
|
|||||||
|
|
||||||
Base = declarative_base()
|
Base = declarative_base()
|
||||||
|
|
||||||
|
|
||||||
class UserRole(enum.Enum):
|
class UserRole(enum.Enum):
|
||||||
user = "user"
|
user = "user"
|
||||||
admin = "admin"
|
admin = "admin"
|
||||||
superadmin = "superadmin"
|
superadmin = "superadmin"
|
||||||
|
|
||||||
|
|
||||||
class User(Base):
|
class User(Base):
|
||||||
__tablename__ = 'users'
|
__tablename__ = 'users'
|
||||||
id = Column(Integer, primary_key=True, autoincrement=True)
|
id = Column(Integer, primary_key=True, autoincrement=True)
|
||||||
@@ -18,8 +20,20 @@ class User(Base):
|
|||||||
password_hash = Column(String(128), nullable=False)
|
password_hash = Column(String(128), nullable=False)
|
||||||
role = Column(Enum(UserRole), nullable=False, default=UserRole.user)
|
role = Column(Enum(UserRole), nullable=False, default=UserRole.user)
|
||||||
is_active = Column(Boolean, default=True, nullable=False)
|
is_active = Column(Boolean, default=True, nullable=False)
|
||||||
created_at = Column(TIMESTAMP(timezone=True), server_default=func.current_timestamp())
|
created_at = Column(TIMESTAMP(timezone=True),
|
||||||
updated_at = Column(TIMESTAMP(timezone=True), server_default=func.current_timestamp(), onupdate=func.current_timestamp())
|
server_default=func.current_timestamp())
|
||||||
|
updated_at = Column(TIMESTAMP(timezone=True), server_default=func.current_timestamp(
|
||||||
|
), onupdate=func.current_timestamp())
|
||||||
|
|
||||||
|
|
||||||
|
class ClientGroup(Base):
|
||||||
|
__tablename__ = 'client_groups'
|
||||||
|
id = Column(Integer, primary_key=True, autoincrement=True)
|
||||||
|
name = Column(String(100), unique=True, nullable=False)
|
||||||
|
created_at = Column(TIMESTAMP(timezone=True),
|
||||||
|
server_default=func.current_timestamp())
|
||||||
|
is_active = Column(Boolean, default=True, nullable=False)
|
||||||
|
|
||||||
|
|
||||||
class Client(Base):
|
class Client(Base):
|
||||||
__tablename__ = 'clients'
|
__tablename__ = 'clients'
|
||||||
@@ -27,9 +41,14 @@ class Client(Base):
|
|||||||
hardware_hash = Column(String(64), nullable=False, index=True)
|
hardware_hash = Column(String(64), nullable=False, index=True)
|
||||||
location = Column(String(100), nullable=True)
|
location = Column(String(100), nullable=True)
|
||||||
ip_address = Column(String(45), nullable=True, index=True)
|
ip_address = Column(String(45), nullable=True, index=True)
|
||||||
registration_time = Column(TIMESTAMP(timezone=True), server_default=func.current_timestamp(), nullable=False)
|
registration_time = Column(TIMESTAMP(
|
||||||
last_alive = Column(TIMESTAMP(timezone=True), server_default=func.current_timestamp(), onupdate=func.current_timestamp(), nullable=False)
|
timezone=True), server_default=func.current_timestamp(), nullable=False)
|
||||||
|
last_alive = Column(TIMESTAMP(timezone=True), server_default=func.current_timestamp(
|
||||||
|
), onupdate=func.current_timestamp(), nullable=False)
|
||||||
is_active = Column(Boolean, default=True, nullable=False)
|
is_active = Column(Boolean, default=True, nullable=False)
|
||||||
|
group_id = Column(Integer, ForeignKey(
|
||||||
|
'client_groups.id'), nullable=False, default=1)
|
||||||
|
|
||||||
|
|
||||||
class EventType(enum.Enum):
|
class EventType(enum.Enum):
|
||||||
presentation = "presentation"
|
presentation = "presentation"
|
||||||
@@ -39,21 +58,26 @@ class EventType(enum.Enum):
|
|||||||
other = "other"
|
other = "other"
|
||||||
webuntis = "webuntis"
|
webuntis = "webuntis"
|
||||||
|
|
||||||
|
|
||||||
class Event(Base):
|
class Event(Base):
|
||||||
__tablename__ = 'events'
|
__tablename__ = 'events'
|
||||||
id = Column(Integer, primary_key=True, autoincrement=True)
|
id = Column(Integer, primary_key=True, autoincrement=True)
|
||||||
client_uuid = Column(String(36), ForeignKey('clients.uuid'), nullable=False, index=True)
|
client_uuid = Column(String(36), ForeignKey(
|
||||||
|
'clients.uuid'), nullable=False, index=True)
|
||||||
title = Column(String(100), nullable=False)
|
title = Column(String(100), nullable=False)
|
||||||
description = Column(Text, nullable=True)
|
description = Column(Text, nullable=True)
|
||||||
start = Column(TIMESTAMP(timezone=True), nullable=False, index=True)
|
start = Column(TIMESTAMP(timezone=True), nullable=False, index=True)
|
||||||
end = Column(TIMESTAMP(timezone=True), nullable=False, index=True)
|
end = Column(TIMESTAMP(timezone=True), nullable=False, index=True)
|
||||||
event_type = Column(Enum(EventType), nullable=False)
|
event_type = Column(Enum(EventType), nullable=False)
|
||||||
created_at = Column(TIMESTAMP(timezone=True), server_default=func.current_timestamp())
|
created_at = Column(TIMESTAMP(timezone=True),
|
||||||
updated_at = Column(TIMESTAMP(timezone=True), server_default=func.current_timestamp(), onupdate=func.current_timestamp())
|
server_default=func.current_timestamp())
|
||||||
|
updated_at = Column(TIMESTAMP(timezone=True), server_default=func.current_timestamp(
|
||||||
|
), onupdate=func.current_timestamp())
|
||||||
created_by = Column(Integer, ForeignKey('users.id'), nullable=False)
|
created_by = Column(Integer, ForeignKey('users.id'), nullable=False)
|
||||||
updated_by = Column(Integer, ForeignKey('users.id'), nullable=True)
|
updated_by = Column(Integer, ForeignKey('users.id'), nullable=True)
|
||||||
is_active = Column(Boolean, default=True, nullable=False)
|
is_active = Column(Boolean, default=True, nullable=False)
|
||||||
|
|
||||||
|
|
||||||
class EventMedia(Base):
|
class EventMedia(Base):
|
||||||
__tablename__ = 'event_media'
|
__tablename__ = 'event_media'
|
||||||
id = Column(Integer, primary_key=True, autoincrement=True)
|
id = Column(Integer, primary_key=True, autoincrement=True)
|
||||||
|
|||||||
108
server/wsgi.py
108
server/wsgi.py
@@ -1,10 +1,12 @@
|
|||||||
# server/wsgi.py
|
# server/wsgi.py
|
||||||
|
from models import Client, ClientGroup
|
||||||
|
from flask import request, jsonify
|
||||||
import glob
|
import glob
|
||||||
import os
|
import os
|
||||||
from flask import Flask, jsonify, send_from_directory, request
|
from flask import Flask, jsonify, send_from_directory, request
|
||||||
from sqlalchemy.orm import sessionmaker
|
from sqlalchemy.orm import sessionmaker
|
||||||
from sqlalchemy import create_engine, and_
|
from sqlalchemy import create_engine, and_
|
||||||
from models import Client, Base, Event
|
from models import Client, Base, Event, ClientGroup
|
||||||
|
|
||||||
DB_USER = os.getenv("DB_USER")
|
DB_USER = os.getenv("DB_USER")
|
||||||
DB_PASSWORD = os.getenv("DB_PASSWORD")
|
DB_PASSWORD = os.getenv("DB_PASSWORD")
|
||||||
@@ -62,7 +64,8 @@ def get_clients():
|
|||||||
"location": c.location,
|
"location": c.location,
|
||||||
"hardware_hash": c.hardware_hash,
|
"hardware_hash": c.hardware_hash,
|
||||||
"ip_address": c.ip_address,
|
"ip_address": c.ip_address,
|
||||||
"last_alive": c.last_alive.isoformat() if c.last_alive else None
|
"last_alive": c.last_alive.isoformat() if c.last_alive else None,
|
||||||
|
"group_id": c.group_id,
|
||||||
}
|
}
|
||||||
for c in clients
|
for c in clients
|
||||||
]
|
]
|
||||||
@@ -96,5 +99,106 @@ def get_events():
|
|||||||
return jsonify(result)
|
return jsonify(result)
|
||||||
|
|
||||||
|
|
||||||
|
@app.route("/api/groups", methods=["POST"])
|
||||||
|
def create_group():
|
||||||
|
data = request.get_json()
|
||||||
|
name = data.get("name")
|
||||||
|
if not name or not name.strip():
|
||||||
|
return jsonify({"error": "Gruppenname erforderlich"}), 400
|
||||||
|
|
||||||
|
session = Session()
|
||||||
|
# Prüfen, ob der Name schon existiert
|
||||||
|
if session.query(ClientGroup).filter_by(name=name).first():
|
||||||
|
session.close()
|
||||||
|
return jsonify({"error": "Gruppe existiert bereits"}), 409
|
||||||
|
|
||||||
|
group = ClientGroup(name=name, is_active=True)
|
||||||
|
session.add(group)
|
||||||
|
session.commit()
|
||||||
|
result = {
|
||||||
|
"id": group.id,
|
||||||
|
"name": group.name,
|
||||||
|
"created_at": group.created_at.isoformat() if group.created_at else None,
|
||||||
|
"is_active": group.is_active,
|
||||||
|
}
|
||||||
|
session.close()
|
||||||
|
return jsonify(result), 201
|
||||||
|
|
||||||
|
|
||||||
|
@app.route("/api/groups", methods=["GET"])
|
||||||
|
def get_groups():
|
||||||
|
"""Liefert alle Raumgruppen als Liste zurück."""
|
||||||
|
session = Session()
|
||||||
|
groups = session.query(ClientGroup).all()
|
||||||
|
result = [
|
||||||
|
{
|
||||||
|
"id": g.id,
|
||||||
|
"name": g.name,
|
||||||
|
"created_at": g.created_at.isoformat() if g.created_at else None,
|
||||||
|
"is_active": g.is_active,
|
||||||
|
}
|
||||||
|
for g in groups
|
||||||
|
]
|
||||||
|
session.close()
|
||||||
|
return jsonify(result)
|
||||||
|
|
||||||
|
|
||||||
|
@app.route("/api/groups/<int:group_id>", methods=["PUT"])
|
||||||
|
def update_group(group_id):
|
||||||
|
"""Ändert den Namen oder Status einer Raumgruppe."""
|
||||||
|
data = request.get_json()
|
||||||
|
session = Session()
|
||||||
|
group = session.query(ClientGroup).filter_by(id=group_id).first()
|
||||||
|
if not group:
|
||||||
|
session.close()
|
||||||
|
return jsonify({"error": "Gruppe nicht gefunden"}), 404
|
||||||
|
if "name" in data:
|
||||||
|
group.name = data["name"]
|
||||||
|
if "is_active" in data:
|
||||||
|
group.is_active = bool(data["is_active"])
|
||||||
|
session.commit()
|
||||||
|
result = {
|
||||||
|
"id": group.id,
|
||||||
|
"name": group.name,
|
||||||
|
"created_at": group.created_at.isoformat() if group.created_at else None,
|
||||||
|
"is_active": group.is_active,
|
||||||
|
}
|
||||||
|
session.close()
|
||||||
|
return jsonify(result)
|
||||||
|
|
||||||
|
|
||||||
|
@app.route("/api/groups/<int:group_id>", methods=["DELETE"])
|
||||||
|
def delete_group(group_id):
|
||||||
|
"""Löscht eine Raumgruppe."""
|
||||||
|
session = Session()
|
||||||
|
group = session.query(ClientGroup).filter_by(id=group_id).first()
|
||||||
|
if not group:
|
||||||
|
session.close()
|
||||||
|
return jsonify({"error": "Gruppe nicht gefunden"}), 404
|
||||||
|
session.delete(group)
|
||||||
|
session.commit()
|
||||||
|
session.close()
|
||||||
|
return jsonify({"success": True})
|
||||||
|
|
||||||
|
|
||||||
|
@app.route("/api/clients/group", methods=["PUT"])
|
||||||
|
def update_clients_group():
|
||||||
|
data = request.get_json()
|
||||||
|
client_ids = data.get("client_ids", [])
|
||||||
|
group_name = data.get("group_name")
|
||||||
|
print(f"Update Clients Group: {group_name}, IDs: {client_ids}")
|
||||||
|
session = Session()
|
||||||
|
group = session.query(ClientGroup).filter_by(name=group_name).first()
|
||||||
|
if not group:
|
||||||
|
session.close()
|
||||||
|
return jsonify({"error": "Gruppe nicht gefunden"}), 404
|
||||||
|
session.query(Client).filter(Client.uuid.in_(client_ids)).update(
|
||||||
|
{Client.group_id: group.id}, synchronize_session=False
|
||||||
|
)
|
||||||
|
session.commit()
|
||||||
|
session.close()
|
||||||
|
return jsonify({"success": True})
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
app.run(host="0.0.0.0", port=8000, debug=True)
|
app.run(host="0.0.0.0", port=8000, debug=True)
|
||||||
|
|||||||
Reference in New Issue
Block a user