fix
Desc: - Perubahan minor
This commit is contained in:
BIN
public/img/5481c365-3f7d-47af-bb0d-82fcbb064f92.png
Normal file
BIN
public/img/5481c365-3f7d-47af-bb0d-82fcbb064f92.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 103 KiB |
@@ -6,7 +6,7 @@ export default async function Page() {
|
||||
return (
|
||||
<>
|
||||
{/* {JSON.stringify(data)} */}
|
||||
<KatalogView />
|
||||
<KatalogView data={data} />
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -14,18 +14,15 @@ import toast from "react-simple-toasts";
|
||||
import { gs_profile } from "../state/global_state";
|
||||
import { loadDataProfile } from "../fun/fun_get_profile";
|
||||
|
||||
export default function EditProfile({data}: {data: any}) {
|
||||
export default function EditProfile({ data }: { data: any }) {
|
||||
const router = useRouter();
|
||||
|
||||
//Get data profile
|
||||
const [profile, setProfile] = useAtom(gs_profile);
|
||||
const [profile, setProfile] = useState(data);
|
||||
useShallowEffect(() => {
|
||||
loadDataProfile(setProfile);
|
||||
}, []);
|
||||
|
||||
|
||||
|
||||
|
||||
async function onUpdate() {
|
||||
const body = profile;
|
||||
if (_.values(body).includes("")) return toast("Lengkapi data");
|
||||
|
||||
@@ -33,11 +33,11 @@ import { loadDataProfile } from "../profile/fun/fun_get_profile";
|
||||
import { getFotoProfile } from "../profile/fun/get_foto_profile";
|
||||
import { ApiHipmi } from "@/app/lib/api";
|
||||
|
||||
export default function KatalogView() {
|
||||
export default function KatalogView({data}: {data: any}) {
|
||||
const router = useRouter();
|
||||
|
||||
//Get data profile
|
||||
const [profile, setProfile] = useAtom(gs_profile);
|
||||
const [profile, setProfile] = useState(data)
|
||||
useShallowEffect(() => {
|
||||
loadDataProfile(setProfile);
|
||||
}, []);
|
||||
|
||||
Reference in New Issue
Block a user