fix : tampilan
Deskripsi: - input time pada kalender divisi - api dokumen divisi >> blm selesai No Issues
This commit is contained in:
@@ -28,7 +28,7 @@ export default function HeaderRightDocument({ path }: { path: string }) {
|
||||
async function handleCreateFolder() {
|
||||
try {
|
||||
const hasil = await decryptToken(String(token?.current))
|
||||
const response = await apiCreateFolderDocument({ user: hasil, name, path, idDivision: id })
|
||||
const response = await apiCreateFolderDocument({ data: { user: hasil, name, path, idDivision: id } })
|
||||
if (response.success) {
|
||||
Toast.show({ type: 'small', text1: 'Berhasil membuat folder baru', })
|
||||
dispatch(setUpdateDokumen(!update))
|
||||
|
||||
@@ -27,7 +27,7 @@ type Props = {
|
||||
export function InputDate({ label, value, placeholder, onChange, info, disable, error, errorText, required, mode, round, width, }: Props) {
|
||||
const [modal, setModal] = useState(false);
|
||||
|
||||
const onChangeDate = ({ type }: { type: string }, selectedDate: any) => {
|
||||
const onChangeDate = (type: string, selectedDate: any) => {
|
||||
if (type === "set") {
|
||||
if (mode == "date") {
|
||||
onChange(dayjs(selectedDate).format("DD-MM-YYYY"))
|
||||
@@ -60,10 +60,10 @@ export function InputDate({ label, value, placeholder, onChange, info, disable,
|
||||
{
|
||||
modal && (
|
||||
<DateTimePicker
|
||||
value={value ? stringToDate(value) : new Date()}
|
||||
value={new Date()}
|
||||
mode={mode}
|
||||
display="default"
|
||||
onChange={onChangeDate}
|
||||
onChange={(event, date) => { onChangeDate(event.type, date) }}
|
||||
onTouchCancel={() => setModal(false)}
|
||||
/>
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user