diff --git a/src/App/Container/Assets/Css/main.css b/src/App/Container/Assets/Css/main.css index ef6823f..351e8f3 100644 --- a/src/App/Container/Assets/Css/main.css +++ b/src/App/Container/Assets/Css/main.css @@ -1050,10 +1050,22 @@ video { background-color: #162f42; } +.bg-bluepindad-300 { + background-color: #0078a9 +} + .bg-yellowpindad-100 { background-color: #D4AF37; } +.bg-orangepindad-100 { + background-color: #EC971F +} + +.bg-greenpindad-100 { + background-color: #449D44 +} + .hover\:bg-transparent:hover { background-color: transparent; } diff --git a/src/App/Container/Components/MainApp/View.tsx b/src/App/Container/Components/MainApp/View.tsx index 243cfbb..07bbe90 100644 --- a/src/App/Container/Components/MainApp/View.tsx +++ b/src/App/Container/Components/MainApp/View.tsx @@ -1,25 +1,35 @@ import React from "react"; -export const MainApp = ({ title, children }) => { +export const MainApp = ({ title, children, button = "" }) => { return ( -
-
-
- {title} -
-
-
-
{children}
-
+
-
-

Perhatian :

-

- This program is protected by copyright law and international - treaties. Unauthorized reproduction or distribution of the program, - or any portion, may result in civil and criminal penalties, and will - be prosecuted to the maximum extent under the law. -

+
+
+
+ {title} +
+ {button} +
+
+
+
+
{children}
+
+
+
+
+
+

Perhatian :

+

+ This program is protected by copyright law and international + treaties. Unauthorized reproduction or distribution of the + program, or any portion, may result in civil and criminal + penalties, and will be prosecuted to the maximum extent under + the law. +

+
+
diff --git a/src/App/Container/Views/Private/VendorProfile/Component/General/Component/General.tsx b/src/App/Container/Views/Private/VendorProfile/Component/General/Component/General.tsx index 3b5f13a..515f966 100644 --- a/src/App/Container/Views/Private/VendorProfile/Component/General/Component/General.tsx +++ b/src/App/Container/Views/Private/VendorProfile/Component/General/Component/General.tsx @@ -1,21 +1,92 @@ -import React from "react"; +import React, { useContext } from "react"; import Table from "./Table"; +import { Modal } from "../../../../../../Components"; +import { GeneralContext } from "../Controller"; +import { MainApp } from "../../../../../../Components"; +import ModalComponent from "./Modal"; const GeneralComponent = () => { - return ( -
-
-
- - -
+ const { open, setOpen, _handleSubmit } = useContext(GeneralContext); + + const ButtonMainApp = () => { + return ( +
- + + + {/* */} + + + + ); + }; + + return ( + }> +
+
+
+ + +
+
+
+ + { + setOpen(false); + }} + onActionOne={() => { + setOpen(false); + }} + onActionTwo={async () => _handleSubmit()} + textOne="Batal" + textTwo="Simpan" + > + + - + ); }; diff --git a/src/App/Container/Views/Private/VendorProfile/Component/General/Component/Modal.tsx b/src/App/Container/Views/Private/VendorProfile/Component/General/Component/Modal.tsx new file mode 100644 index 0000000..edb6faf --- /dev/null +++ b/src/App/Container/Views/Private/VendorProfile/Component/General/Component/Modal.tsx @@ -0,0 +1,526 @@ +import React, { useContext } from "react"; +import { useFormContext } from "react-hook-form"; +import Select from "react-select"; +import { GeneralContext } from "../Controller"; + +const ModalComponent = () => { + const { + customStyles, + setBranchName, + setAddress, + country, + setCountry, + province, + setProvince, + city, + setCity, + setDistrict, + setPostalCode, + setPhoneNumber, + setPhoneNumberExt, + setFaxNumber, + setFaxNumberExt, + setWebsite, + setCompanyEmail, + optionsCompanyType, + Indonesia, + Yogya, + Sleman, + register, + } = useContext(GeneralContext); + const { errors } = useFormContext(); + + return ( +
+
+
+ Use as Branch Office +
+
+
+
+
+
+
+ +
+
+ setBranchName(val.target.value)} + className="w-full bg-white border border-gray-400 rounded hover:border-gray-500 py-1 px-2" + placeholder="Nama Cabang/Lokasi Cabang" + /> +
+
+
+
+
+ {errors.branchName && ( +

+ {errors.branchName && errors.branchName.message} +

+ )} +
+
+
+
+ +
+
+