feat: tambah dependensi 'jose' versi 5.9.2 pada package.json
refactor: rapikan identasi dan buat field 'expires' opsional di model UserSession pada schema prisma chore: bersihkan import tidak terpakai di route login dan register API
This commit is contained in:
@@ -1,20 +1,19 @@
|
||||
import { funGetUserProfile } from "@/app_modules/fun_global/get_user_profile";
|
||||
import { CheckCookies_UiView } from "@/app_modules/check_cookies";
|
||||
import { user_funGetOneUserId } from "@/app_modules/fun_global/get_user_token";
|
||||
import { DetailInvestasi } from "@/app_modules/investasi";
|
||||
import getOneInvestasiById from "@/app_modules/investasi/fun/get_one_investasi_by_id";
|
||||
import { user_funGetOneUserId } from "@/app_modules/fun_global/get_user_token";
|
||||
import funProgressBar from "@/app_modules/investasi/fun/fun_progress_bar";
|
||||
import funTotalInvestorByIdInvestasi from "@/app_modules/investasi/fun/fun_total_investor_by_id";
|
||||
|
||||
export default async function Page({ params }: { params: { id: string } }) {
|
||||
const investasiId = params.id
|
||||
const investasiId = params.id;
|
||||
const dataInvestasi = await getOneInvestasiById(investasiId);
|
||||
const loginUserId = await user_funGetOneUserId();
|
||||
const userLoginId = await user_funGetOneUserId();
|
||||
if (!userLoginId) return <CheckCookies_UiView />;
|
||||
|
||||
return (
|
||||
<>
|
||||
<DetailInvestasi
|
||||
dataInvestasi={dataInvestasi as any}
|
||||
loginUserId={loginUserId}
|
||||
loginUserId={userLoginId}
|
||||
/>
|
||||
</>
|
||||
);
|
||||
|
||||
@@ -15,6 +15,7 @@ import {
|
||||
|
||||
export default async function Page() {
|
||||
const userId = await user_funGetOneUserId();
|
||||
if (!userId) return <div>{"User Tidak ditemukan"}</div>;
|
||||
const listStatus = await getStatusInvestasi();
|
||||
const dataDraft = await getPortoByStatusId(userId, 1);
|
||||
const dataReview = await getPortoByStatusId(userId, 2);
|
||||
@@ -30,12 +31,10 @@ export default async function Page() {
|
||||
page: 1,
|
||||
statusId: "3",
|
||||
});
|
||||
const listDataReject = await investasi_funGetAllInvestasiNonPublishByUserId({
|
||||
page: 1,
|
||||
statusId: "4",
|
||||
});
|
||||
|
||||
|
||||
const listDataReject = await investasi_funGetAllInvestasiNonPublishByUserId({
|
||||
page: 1,
|
||||
statusId: "4",
|
||||
});
|
||||
|
||||
return (
|
||||
<>
|
||||
|
||||
@@ -4,11 +4,14 @@ import getMaster_StatusTransaksiInvestasi from "@/app_modules/investasi/fun/mast
|
||||
import { user_funGetOneUserId } from "@/app_modules/fun_global/get_user_token";
|
||||
import { investasi_funGetTransaksiByUserId } from "@/app_modules/investasi/_fun";
|
||||
import { Investasi_UiDaftarTransaksi } from "@/app_modules/investasi/_ui";
|
||||
import { CheckCookies_UiView } from "@/app_modules/check_cookies";
|
||||
|
||||
export default async function Page() {
|
||||
const userId = await user_funGetOneUserId();
|
||||
const userLoginId = await user_funGetOneUserId();
|
||||
if (!userLoginId) return <CheckCookies_UiView />;
|
||||
|
||||
const statusTransaksi = await getMaster_StatusTransaksiInvestasi();
|
||||
const listTransaksi = await getListAllTransaksiById_Investasi(userId);
|
||||
const listTransaksi = await getListAllTransaksiById_Investasi(userLoginId);
|
||||
|
||||
// NEW
|
||||
const dataTransaksi = await investasi_funGetTransaksiByUserId({ page: 1 });
|
||||
|
||||
@@ -3,9 +3,12 @@ import getOneInvestasiById from "@/app_modules/investasi/fun/get_one_investasi_b
|
||||
import getMaster_NamaBank from "@/app_modules/investasi/fun/master/get_nama_bank";
|
||||
|
||||
import { user_funGetOneUserId } from "@/app_modules/fun_global";
|
||||
import { CheckCookies_UiView } from "@/app_modules/check_cookies";
|
||||
|
||||
export default async function Page({ params }: { params: { id: string } }) {
|
||||
const authorId = await user_funGetOneUserId();
|
||||
const userLoginId = await user_funGetOneUserId();
|
||||
if (!userLoginId) return <CheckCookies_UiView />;
|
||||
|
||||
const dataInvestasi = await getOneInvestasiById(params.id);
|
||||
const namaBank = await getMaster_NamaBank();
|
||||
// console.log(namaBank)
|
||||
@@ -14,7 +17,7 @@ export default async function Page({ params }: { params: { id: string } }) {
|
||||
<MetodeTransferInvestasi
|
||||
dataInvestasi={dataInvestasi as any}
|
||||
namaBank={namaBank as any}
|
||||
authorId={authorId}
|
||||
authorId={userLoginId}
|
||||
/>
|
||||
</>
|
||||
);
|
||||
|
||||
@@ -1,11 +1,14 @@
|
||||
import { CheckCookies_UiView } from "@/app_modules/check_cookies";
|
||||
import { user_funGetOneUserId } from "@/app_modules/fun_global";
|
||||
import { funGetUserProfile } from "@/app_modules/fun_global/get_user_profile";
|
||||
import { ProsesTransaksiInvestasi } from "@/app_modules/investasi";
|
||||
import getOneInvestasiById from "@/app_modules/investasi/fun/get_one_investasi_by_id";
|
||||
|
||||
export default async function Page({ params }: { params: { id: string } }) {
|
||||
const authorId = await user_funGetOneUserId();
|
||||
const userLogin = await funGetUserProfile(authorId);
|
||||
const userLoginId = await user_funGetOneUserId();
|
||||
if (!userLoginId) return <CheckCookies_UiView />;
|
||||
|
||||
const userLogin = await funGetUserProfile(userLoginId);
|
||||
const dataInvestasi = await getOneInvestasiById(params.id);
|
||||
|
||||
// console.log(dataInvestasi);
|
||||
|
||||
Reference in New Issue
Block a user