diff --git a/src/containers/DefaultLayout/DefaultHeader.js b/src/containers/DefaultLayout/DefaultHeader.js index de15875..feaba30 100644 --- a/src/containers/DefaultLayout/DefaultHeader.js +++ b/src/containers/DefaultLayout/DefaultHeader.js @@ -56,7 +56,7 @@ class DefaultHeader extends Component { getLogoHeaderContent = () => { const { configApp } = this.state; - const logoHeaderContent = configApp && configApp.logo_header ? configApp.logo_header.content : null; + const logoHeaderContent = configApp && configApp.logo_header ? configApp.logo_header : null; return logoHeaderContent ? `${BASE_SIMPRO_LUMEN_IMAGE}/${logoHeaderContent}` : logo_ospro; diff --git a/src/views/SimproV2/CreatedProyek/DialogFormProyek.js b/src/views/SimproV2/CreatedProyek/DialogFormProyek.js index 583ed25..42d265a 100644 --- a/src/views/SimproV2/CreatedProyek/DialogFormProyek.js +++ b/src/views/SimproV2/CreatedProyek/DialogFormProyek.js @@ -1,15 +1,12 @@ -import React, { useEffect, useState, useMemo } from "react"; +import React, { useEffect, useState } from "react"; import { Modal, ModalHeader, ModalBody, ModalFooter } from "reactstrap"; import { Button, Form, FormGroup, Label, Input, Col, Row } from "reactstrap"; -import { DatePicker, Tooltip, Select, Divider, Spin } from "antd"; +import { DatePicker, Tooltip, Select, Divider, Spin, message } from "antd"; import axios from "../../../const/interceptorApi"; import moment from "moment"; import { CKEditor } from '@ckeditor/ckeditor5-react'; import ClassicEditor from '@ckeditor/ckeditor5-build-classic'; -import { - NotificationContainer, - NotificationManager, -} from "react-notifications"; +import {NotificationManager} from "react-notifications"; import "antd/dist/antd.css"; import { formatNumber } from "../../../const/CustomFunc"; import { @@ -72,7 +69,7 @@ const DialogFormProyek = ({ const [currencyList, setCurrencyList] = useState(null); const [currency, setCurrency] = useState(""); // merge of code | symbol | name const [currencyCode, setCurrencyCode] = useState(""); - const [currencySymbol, setCurrencySymbol] = useState(null); + const [currencySymbol, setCurrencySymbol] = useState("IDR|Rp|Indonesian rupiah"); const [currencyName, setCurrencyName] = useState(""); const [objectives, setObjectives] = useState(""); const [projectIsConsideredSuccessful, setProjectIsConsideredSuccessful] = useState(""); @@ -213,7 +210,7 @@ const DialogFormProyek = ({ setCompanyId(null) setCurrency(""); setCurrencyCode(""); - setCurrencySymbol(null); + setCurrencySymbol("IDR|Rp|Indonesian rupiah"); setCurrencyName(""); setObjectives(""); setImage(""); @@ -425,6 +422,10 @@ const DialogFormProyek = ({ alert("Currency Symbol cannot be empty!"); return false; } + if (!divisiProject || divisiProject === "") { + alert("Division cannot be empty!"); + return false; + } setStep(2); }; @@ -810,7 +811,7 @@ const DialogFormProyek = ({