Add default admin tab now set to M&E Data Entry
This commit is contained in:
@@ -9,8 +9,11 @@ import { chakra } from "@chakra-ui/react";
|
|||||||
import Personal from "./views/Personal";
|
import Personal from "./views/Personal";
|
||||||
import Security from "./views/Security";
|
import Security from "./views/Security";
|
||||||
|
|
||||||
|
const ADMIN_DEFAULT = "medataentry";
|
||||||
|
|
||||||
export default function Canvas(props) {
|
export default function Canvas(props) {
|
||||||
const { view } = props;
|
const { view } = props;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<chakra.div width="100%" height="100%">
|
<chakra.div width="100%" height="100%">
|
||||||
{/* Check if view is a tab inside the Home Header */}
|
{/* Check if view is a tab inside the Home Header */}
|
||||||
|
|||||||
@@ -7,11 +7,6 @@ import { SearchBar } from "../CanvasComponents/SearchBar";
|
|||||||
import { SettingsButton } from "../CanvasComponents/SettingsButton";
|
import { SettingsButton } from "../CanvasComponents/SettingsButton";
|
||||||
|
|
||||||
export default function Admin({ view, onChangeView, onEditWidgets, appendWidget }) {
|
export default function Admin({ view, onChangeView, onEditWidgets, appendWidget }) {
|
||||||
// Prop Forwarding
|
|
||||||
// const { view, layout, setLayout, setOriginalLayout, onLayoutChange, onChangeView, onCancel, setOriginalWidgets,
|
|
||||||
// isDelete, setIsDelete, beginEditIfNeeded, isEditable, setIsEditable, widgetArray, setWidgetArray } = props;
|
|
||||||
|
|
||||||
// const MyDashboardProps = { layout, onLayoutChange, isEditable, beginEditIfNeeded, isDelete, DeleteWidget, widgetArray, appendWidget };
|
|
||||||
const settingsButtonProps = { onEditWidgets, appendWidget };
|
const settingsButtonProps = { onEditWidgets, appendWidget };
|
||||||
|
|
||||||
return (
|
return (
|
||||||
@@ -77,68 +72,3 @@ export default function Admin({ view, onChangeView, onEditWidgets, appendWidget
|
|||||||
</Tabs.Root>
|
</Tabs.Root>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// return (
|
|
||||||
// /* HEADER */
|
|
||||||
// <Tabs.Root
|
|
||||||
// width="100%"
|
|
||||||
// height="100%"
|
|
||||||
// lazyMount
|
|
||||||
// value={ view }
|
|
||||||
// variant="line"
|
|
||||||
// // Prevent navigation away from 'My Dashboard' while in Edit mode
|
|
||||||
// onValueChange={(e) => {
|
|
||||||
// const nextView = e.value;
|
|
||||||
// onChangeView(nextView);
|
|
||||||
// }}
|
|
||||||
// >
|
|
||||||
// <Flex
|
|
||||||
// as="header"
|
|
||||||
// position="sticky"
|
|
||||||
// top="0"
|
|
||||||
// zIndex="dropdown" // zIndex: 1100
|
|
||||||
// bg="base200"
|
|
||||||
// px={5}
|
|
||||||
// pt={3}
|
|
||||||
// pb={2}
|
|
||||||
// align="center"
|
|
||||||
// justify="space-between"
|
|
||||||
// width="100%"
|
|
||||||
// >
|
|
||||||
// <Tabs.List>
|
|
||||||
// <Tabs.Trigger value="medataentry" fontSize="lg">
|
|
||||||
// M&E Data Entry
|
|
||||||
// </Tabs.Trigger>
|
|
||||||
// <Tabs.Trigger value="projectcollector" fontSize="lg">
|
|
||||||
// Project Collector
|
|
||||||
// </Tabs.Trigger>
|
|
||||||
// <Tabs.Trigger value="nasapplication" fontSize="lg">
|
|
||||||
// NAS Application
|
|
||||||
// </Tabs.Trigger><Tabs.Trigger value="ivans" fontSize="lg">
|
|
||||||
// IVANS
|
|
||||||
// </Tabs.Trigger>
|
|
||||||
// </Tabs.List>
|
|
||||||
// <HStack width="258px" justifyContent="flex-end">
|
|
||||||
// <SearchBar />
|
|
||||||
// <SettingsButton onEditWidgets={onEditWidgets} appendWidget={appendWidget}/>
|
|
||||||
// </HStack>
|
|
||||||
// </Flex>
|
|
||||||
|
|
||||||
// {/* CANVAS */}
|
|
||||||
// <Tabs.Content value="medataentry">
|
|
||||||
// <MEDataEntry />
|
|
||||||
// </Tabs.Content>
|
|
||||||
// <Tabs.Content value="projectcollector">
|
|
||||||
// <ProjectCollector />
|
|
||||||
// </Tabs.Content>
|
|
||||||
// <Tabs.Content value="nasapplication">
|
|
||||||
// <NASApplication />
|
|
||||||
// </Tabs.Content>
|
|
||||||
// <Tabs.Content value="ivans">
|
|
||||||
// <IVANS />
|
|
||||||
// </Tabs.Content>
|
|
||||||
// </Tabs.Root>
|
|
||||||
// );
|
|
||||||
// }
|
|
||||||
|
|
||||||
@@ -25,7 +25,7 @@ export default function Sidebar({ view, onChangeView, darkMode, setDarkMode }) {
|
|||||||
{icon: FaGlobeAmericas, name: "Global Map", view: "global"},
|
{icon: FaGlobeAmericas, name: "Global Map", view: "global"},
|
||||||
{icon: FaMapMarkerAlt, name: "Regional Map", view: "regional"},
|
{icon: FaMapMarkerAlt, name: "Regional Map", view: "regional"},
|
||||||
{icon: FaVolcano, name: "Volcano", view: "volcano"},
|
{icon: FaVolcano, name: "Volcano", view: "volcano"},
|
||||||
{icon: HiUsers, name: "Admin", view: "admin"}
|
{icon: HiUsers, name: "Admin", view: "medataentry"}
|
||||||
];
|
];
|
||||||
|
|
||||||
// Different Sidebar Button Options for Settings View
|
// Different Sidebar Button Options for Settings View
|
||||||
|
|||||||
Reference in New Issue
Block a user