From 84623c73b826d22d9b7b3103796bc754e7433b96 Mon Sep 17 00:00:00 2001
From: eug-vs <eug-vs@keemail.me>
Date: Sun, 21 Mar 2021 12:56:23 +0300
Subject: feat: add Contractor Panel

---
 src/containers/ContractorPanel.tsx | 31 +++++++++++++++++++++++++++++++
 1 file changed, 31 insertions(+)
 create mode 100644 src/containers/ContractorPanel.tsx

(limited to 'src/containers/ContractorPanel.tsx')

diff --git a/src/containers/ContractorPanel.tsx b/src/containers/ContractorPanel.tsx
new file mode 100644
index 0000000..02e11ba
--- /dev/null
+++ b/src/containers/ContractorPanel.tsx
@@ -0,0 +1,31 @@
+import React from 'react';
+import { useHistory } from 'react-router-dom';
+import Button from '../components/Button';
+import { patch, baseURL } from '../requests';
+import { PanelProps } from './Service/ServiceContext';
+
+
+const ContractorPanel: React.FC<PanelProps> = ({ item, mutate }) => {
+  const history = useHistory();
+
+  return (
+    <div className="lg:m-4 p-4 flex flex-col lg:pl-16 lg:border-l">
+      <div className="grid lg:grid-cols-2">
+        <Button route={`/waybills?contractorId=${item._id}`} variant="outlined">
+          Показать накладные
+        </Button>
+        <Button route="/waybills/add">
+          Новая накладная
+        </Button>
+        <Button route={`/transfers?contractorId=${item._id}`} variant="outlined">
+          Показать переводы
+        </Button>
+        <Button route="/transfers/add">
+          Новый перевод
+        </Button>
+      </div>
+    </div>
+  );
+};
+
+export default ContractorPanel;
-- 
cgit v1.2.3

