@openmrs/esm-stock-management-app 1.0.1-pre.453 → 1.0.1-pre.464
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/474.js +1 -0
- package/dist/474.js.map +1 -0
- package/dist/876.js +2 -0
- package/dist/876.js.map +1 -0
- package/dist/main.js +1 -1
- package/dist/main.js.map +1 -1
- package/dist/openmrs-esm-stock-management-app.js +1 -1
- package/dist/openmrs-esm-stock-management-app.js.buildmanifest.json +35 -35
- package/dist/routes.json +1 -1
- package/package.json +1 -1
- package/src/core/components/overlay/overlay.scss +2 -1
- package/src/createDashboardLink.tsx +2 -2
- package/src/dashboard/dashboard-view.component.tsx +17 -0
- package/src/dashboard/home-dashboard.component.tsx +51 -0
- package/src/dashboard/home-dashboard.scss +28 -0
- package/src/index.ts +68 -6
- package/src/root.component.tsx +24 -2
- package/src/routes.json +157 -8
- package/src/side-menu/side-menu.component.tsx +6 -0
- package/src/stock-items/add-stock-item/stock-item-category-selector/stock-item-category-selector.component.tsx +6 -1
- package/src/stock-items/add-stock-item/stock-item-details/stock-item-details.component.tsx +20 -0
- package/src/stock-settings/stock-settings.component.tsx +27 -2
- package/src/stock-settings/stock-settings.scss +23 -0
- package/src/types/index.ts +5 -0
- package/dist/180.js +0 -2
- package/dist/180.js.map +0 -1
- package/dist/457.js +0 -1
- package/dist/457.js.map +0 -1
- package/src/dashboard/stock-management-dashboard-side-nav.component.tsx +0 -54
- package/src/dashboard/stock-management-dashboard.component.tsx +0 -43
- package/src/dashboard/stock-management-dashboard.scss +0 -8
- /package/dist/{180.js.LICENSE.txt → 876.js.LICENSE.txt} +0 -0
@@ -1,54 +0,0 @@
|
|
1
|
-
import React, { useState } from "react";
|
2
|
-
import { useTranslation } from "react-i18next";
|
3
|
-
import { SideNavItem } from "../core/components/side-nav/types";
|
4
|
-
import SideNavItemsList from "../core/components/side-nav/side-nav.component";
|
5
|
-
|
6
|
-
const StockManagementDashboardSideNav = () => {
|
7
|
-
const { t } = useTranslation();
|
8
|
-
const [selectedTab, setSelectedTab] = useState(0);
|
9
|
-
|
10
|
-
const tabs: SideNavItem[] = [
|
11
|
-
{
|
12
|
-
name: t("stockManagementOverview", "Overview"),
|
13
|
-
link: "overview",
|
14
|
-
},
|
15
|
-
{
|
16
|
-
name: t("stockManagementStockItems", "Items"),
|
17
|
-
link: "stock-items",
|
18
|
-
},
|
19
|
-
{
|
20
|
-
name: t("stockManagementOperations", "Operations"),
|
21
|
-
link: "stock-operations",
|
22
|
-
},
|
23
|
-
{
|
24
|
-
name: t("stockManagementStockUserScopes", "User Role Scopes"),
|
25
|
-
link: "stock-user-scopes",
|
26
|
-
},
|
27
|
-
{
|
28
|
-
name: t("stockManagementStockSources", "Sources"),
|
29
|
-
link: "stock-sources",
|
30
|
-
},
|
31
|
-
{
|
32
|
-
name: t("stockManagementLocations", "Locations"),
|
33
|
-
link: "stock-locations",
|
34
|
-
},
|
35
|
-
{
|
36
|
-
name: t("stockManagementReports", "Reports"),
|
37
|
-
link: "stock-reports",
|
38
|
-
},
|
39
|
-
{
|
40
|
-
name: t("stockManagementSettings", "Settings"),
|
41
|
-
link: `admin/maintenance/settings.list?show=Stockmanagement`,
|
42
|
-
},
|
43
|
-
];
|
44
|
-
|
45
|
-
return (
|
46
|
-
<SideNavItemsList
|
47
|
-
tabs={tabs}
|
48
|
-
selectedIndex={selectedTab}
|
49
|
-
onSelectTab={setSelectedTab}
|
50
|
-
/>
|
51
|
-
);
|
52
|
-
};
|
53
|
-
|
54
|
-
export default StockManagementDashboardSideNav;
|
@@ -1,43 +0,0 @@
|
|
1
|
-
import React from "react";
|
2
|
-
import { StockManagementHeader } from "../stock-management-header/stock-management-header.component";
|
3
|
-
import Overlay from "../core/components/overlay/overlay.component";
|
4
|
-
import styles from "./stock-management-dashboard.scss";
|
5
|
-
import StockManagementDashboardSideNav from "./stock-management-dashboard-side-nav.component";
|
6
|
-
import { BrowserRouter, Route, Routes } from "react-router-dom";
|
7
|
-
import StockHomeLandingPage from "../stock-home/stock-home-landing-page-component";
|
8
|
-
import StockUserScopes from "../stock-user-role-scopes/stock-user-role-scopes.component";
|
9
|
-
import StockSources from "../stock-sources/stock-sources.component";
|
10
|
-
import StockOperationsComponent from "../stock-operations/stock-operations.component";
|
11
|
-
import StockItems from "../stock-items/stock-items.component";
|
12
|
-
import StockSettings from "../stock-settings/stock-settings.component";
|
13
|
-
import StockLocations from "../stock-locations/stock-locations.component";
|
14
|
-
import StockReports from "../stock-reports/report-list/stock-reports.component";
|
15
|
-
|
16
|
-
export default function StockManagementDashboard() {
|
17
|
-
const basePath = `${window.getOpenmrsSpaBase()}stock-management`;
|
18
|
-
return (
|
19
|
-
<BrowserRouter basename={basePath}>
|
20
|
-
<div className={styles.container}>
|
21
|
-
<StockManagementDashboardSideNav />
|
22
|
-
<div>
|
23
|
-
<StockManagementHeader />
|
24
|
-
<Routes>
|
25
|
-
<Route path="overview" element={<StockHomeLandingPage />} />
|
26
|
-
<Route path="" element={<StockHomeLandingPage />} />
|
27
|
-
<Route path="stock-items" element={<StockItems />} />
|
28
|
-
<Route
|
29
|
-
path="stock-operations"
|
30
|
-
element={<StockOperationsComponent />}
|
31
|
-
/>
|
32
|
-
<Route path="stock-user-scopes" element={<StockUserScopes />} />
|
33
|
-
<Route path="stock-sources" element={<StockSources />} />
|
34
|
-
<Route path="stock-locations" element={<StockLocations />} />
|
35
|
-
<Route path="stock-reports" element={<StockReports />} />
|
36
|
-
<Route path="stock-settings" element={<StockSettings />} />
|
37
|
-
</Routes>
|
38
|
-
</div>
|
39
|
-
<Overlay />
|
40
|
-
</div>
|
41
|
-
</BrowserRouter>
|
42
|
-
);
|
43
|
-
}
|
File without changes
|