Compare commits
119 Commits
main
...
prod-with-
| Author | SHA1 | Date |
|---|---|---|
|
|
b181f6b3dd | |
|
|
cde575cb5e | |
|
|
c7b2456a78 | |
|
|
4605ef3aeb | |
|
|
8e2fa0425d | |
|
|
9d028b54d3 | |
|
|
978fd4eb6e | |
|
|
45a63696f4 | |
|
|
f3528fb288 | |
|
|
f2b934db97 | |
|
|
173eb00cd9 | |
|
|
0f863281ec | |
|
|
b0813350d7 | |
|
|
f0205597b5 | |
|
|
fdb3080495 | |
|
|
07a11d83a7 | |
|
|
08d438881c | |
|
|
7b13a09b76 | |
|
|
4f28de0a12 | |
|
|
6346426468 | |
|
|
27098b5373 | |
|
|
fab81ed10b | |
|
|
6871934fe6 | |
|
|
fae207dfb0 | |
|
|
caa82967b5 | |
|
|
a7be72f7f7 | |
|
|
f2bfd3f36a | |
|
|
74acf4d894 | |
|
|
25b0ce301b | |
|
|
f30a6475a4 | |
|
|
cf6feec304 | |
|
|
f90ea2cc9a | |
|
|
4ee30e8bf9 | |
|
|
a0ca095d5b | |
|
|
e03bd4a878 | |
|
|
390fb27001 | |
|
|
5d4ea85934 | |
|
|
3d53652765 | |
|
|
48a18c172f | |
|
|
0ba8138779 | |
|
|
ed5adaced3 | |
|
|
45de7405d2 | |
|
|
49678e91c3 | |
|
|
893ac68240 | |
|
|
d6a419e9b5 | |
|
|
01003616ab | |
|
|
76ab479e2d | |
|
|
8a404b21ed | |
|
|
82d2c19e02 | |
|
|
14e21a3193 | |
|
|
ca5a150015 | |
|
|
f4888db103 | |
|
|
134a2532ee | |
|
|
2099cd1e1c | |
|
|
0ec1ca9297 | |
|
|
a01d77c82a | |
|
|
ae42305e0e | |
|
|
88bbe147e4 | |
|
|
4ec966c9eb | |
|
|
4c74c191cc | |
|
|
15697a30f7 | |
|
|
37ebe1ad12 | |
|
|
c792f5b4b1 | |
|
|
090006fa30 | |
|
|
166c3c8143 | |
|
|
97612d6a71 | |
|
|
f10db99437 | |
|
|
a4bf80482a | |
|
|
12c904d49a | |
|
|
541f9b6004 | |
|
|
fd61c5311b | |
|
|
a8c6087437 | |
|
|
3f2d66c426 | |
|
|
f854cb7385 | |
|
|
d8aad6da43 | |
|
|
ed71982b6c | |
|
|
2fae4027ee | |
|
|
4e1d98d168 | |
|
|
ad4aa1f81e | |
|
|
7d9f23896e | |
|
|
459425a309 | |
|
|
6ac02ba0a9 | |
|
|
3445a932eb | |
|
|
9ae0c9269d | |
|
|
59834d95e7 | |
|
|
dd1479000e | |
|
|
8e3090d6eb | |
|
|
a80585326a | |
|
|
96f16d2b77 | |
|
|
16cbdcff45 | |
|
|
ddd31a46fd | |
|
|
ad13a58ac8 | |
|
|
e0d9b43892 | |
|
|
72b16e21ba | |
|
|
09a27f3807 | |
|
|
47c2fc55df | |
|
|
c44ae46633 | |
|
|
d00956503f | |
|
|
e9fa8f8e93 | |
|
|
5467edc3a7 | |
|
|
1a6919ea5d | |
|
|
471adf85f0 | |
|
|
e2450d4b56 | |
|
|
be9f8649f4 | |
|
|
5e849572a3 | |
|
|
07c7a93b18 | |
|
|
0b420bdef4 | |
|
|
f639a827d4 | |
|
|
007a6d9eec | |
|
|
f3757bcfac | |
|
|
a0b658bbfc | |
|
|
fb1d0fde82 | |
|
|
04a04cfe74 | |
|
|
ac332b7099 | |
|
|
3ed1327707 | |
|
|
b3ab21700a | |
|
|
026eae5cd3 | |
|
|
00aeded4ea | |
|
|
72099c35a6 |
4
.env
4
.env
|
|
@ -1,3 +1,3 @@
|
|||
NEXT_PUBLIC_API=https://netidhub.com/api
|
||||
NEXT_PUBLIC=https://netidhub.com
|
||||
NEXT_PUBLIC_API=https://mediahub.polri.go.id/api/v2
|
||||
NEXT_PUBLIC=https://mediahub.polri.go.id
|
||||
NEXT_PUBLIC_TINYMCE_API_KEY=bhteuja26yz5p0aubxry9b95hs33amgn65kjv5km0fd5iuev
|
||||
|
|
@ -2,12 +2,13 @@ stages:
|
|||
- build
|
||||
- deploy
|
||||
|
||||
build-dev:
|
||||
build-prod:
|
||||
stage: build
|
||||
when: on_success
|
||||
only:
|
||||
- main
|
||||
- dev-landing-v2
|
||||
- prod
|
||||
image:
|
||||
name: docker:25.0.3-cli
|
||||
services:
|
||||
|
|
@ -15,9 +16,11 @@ build-dev:
|
|||
command: ["--insecure-registry=103.82.242.92:8900"]
|
||||
script:
|
||||
- docker logout
|
||||
- docker login -u $DEPLOY_USERNAME -p $DEPLOY_TOKEN 103.82.242.92:8900
|
||||
- docker build -t 103.82.242.92:8900/mediahub/new-mediahub-fe:dev .
|
||||
- docker push 103.82.242.92:8900/mediahub/new-mediahub-fe:dev
|
||||
- echo "Username:$DEPLOY_USERNAME"
|
||||
- echo "Token:$DEPLOY_TOKEN"
|
||||
- echo "$DEPLOY_TOKEN" | docker login 103.82.242.92:8900 --username "$DEPLOY_USERNAME" --password-stdin
|
||||
- docker build -t 103.82.242.92:8900/mediahub/new-mediahub-fe:prod .
|
||||
- docker push 103.82.242.92:8900/mediahub/new-mediahub-fe:prod
|
||||
|
||||
auto-deploy:
|
||||
stage: deploy
|
||||
|
|
|
|||
|
|
@ -118,7 +118,7 @@ export default function AddExpertForm() {
|
|||
};
|
||||
|
||||
const save = async (data: z.infer<typeof FormSchema>) => {
|
||||
console.log("data", data);
|
||||
// console.log("data", data);
|
||||
|
||||
const dataReq = {
|
||||
firstName: data.name,
|
||||
|
|
@ -244,10 +244,10 @@ export default function AddExpertForm() {
|
|||
};
|
||||
|
||||
const handleRemoveRow = (index: number) => {
|
||||
console.log(index);
|
||||
console.log(placementRows);
|
||||
// console.log(index);
|
||||
// console.log(placementRows);
|
||||
const newPlacements = placementRows.filter((row) => row.index != index);
|
||||
console.log(newPlacements);
|
||||
// console.log(newPlacements);
|
||||
setPlacementRows(newPlacements);
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -185,7 +185,7 @@ export default function UpdateExpertForm() {
|
|||
};
|
||||
|
||||
const save = async (data: z.infer<typeof FormSchema>) => {
|
||||
console.log("data", data);
|
||||
// console.log("data", data);
|
||||
|
||||
const dataReq = {
|
||||
id: detail?.id,
|
||||
|
|
@ -245,7 +245,7 @@ export default function UpdateExpertForm() {
|
|||
|
||||
const resExperiences = await getListExperiences();
|
||||
setUserExperiences(resExperiences?.data?.data);
|
||||
console.log("experience", resExperiences?.data?.data);
|
||||
// console.log("experience", resExperiences?.data?.data);
|
||||
|
||||
const resUserLevels = await AdministrationLevelList();
|
||||
const data = resUserLevels?.data?.data;
|
||||
|
|
@ -288,10 +288,10 @@ export default function UpdateExpertForm() {
|
|||
};
|
||||
|
||||
const handleRemoveRow = (index: number) => {
|
||||
console.log(index);
|
||||
console.log(placementRows);
|
||||
// console.log(index);
|
||||
// console.log(placementRows);
|
||||
const newPlacements = placementRows.filter((row) => row.index != index);
|
||||
console.log(newPlacements);
|
||||
// console.log(newPlacements);
|
||||
setPlacementRows(newPlacements);
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -43,8 +43,8 @@ export default function ContentManagement() {
|
|||
const [ticket6, setTicket6] = useState("");
|
||||
const [isInternational, setIsInternational] = useState([false, false, false]);
|
||||
|
||||
const baseUrl = "https://analytic.sitani.info/";
|
||||
const url = "https://analytic.sitani.info/trusted/";
|
||||
const baseUrl = "https://db-mediahub.polri.go.id/";
|
||||
const url = "https://db-mediahub.polri.go.id/trusted/";
|
||||
|
||||
const view1 =
|
||||
levelName == "MABES POLRI"
|
||||
|
|
@ -87,7 +87,7 @@ export default function ContentManagement() {
|
|||
? "views/2023_08_MediaHUB-KtnMgt_Rev100/db-ktn-intl?"
|
||||
: "views/2023_08_MediaHUB-KtnMgt_Rev100/db-ktn-intl?"
|
||||
: `views/2023_08_MediaHUB-KtnMgt_Rev100/db-ktn-intl?provinsi-polda=${poldaState}&`;
|
||||
const param = ":embed=yes&:toolbar=no&:iframeSizedToWindow=true";
|
||||
const param = ":embed=yes&:toolbar=yes&:iframeSizedToWindow=true";
|
||||
|
||||
useEffect(() => {
|
||||
async function initState() {
|
||||
|
|
|
|||
|
|
@ -43,8 +43,8 @@ export default function EmergencyIssue() {
|
|||
const [ticket6, setTicket6] = useState("");
|
||||
const [isInternational, setIsInternational] = useState([false, false, false]);
|
||||
|
||||
const baseUrl = "https://analytic.sitani.info/";
|
||||
const url = "https://analytic.sitani.info/trusted/";
|
||||
const baseUrl = "https://db-mediahub.polri.go.id/";
|
||||
const url = "https://db-mediahub.polri.go.id/trusted/";
|
||||
|
||||
const view1 =
|
||||
levelName == "MABES POLRI"
|
||||
|
|
@ -53,7 +53,7 @@ export default function EmergencyIssue() {
|
|||
: "views/2023_08_MediaHUB-KtnMgt_Rev100/db-emg-issue?"
|
||||
: `views/2023_08_MediaHUB-KtnMgt_Rev100/db-emg-issue?provinsi-polda=${provState}&`;
|
||||
|
||||
const param = ":embed=yes&:toolbar=no&:iframeSizedToWindow=true";
|
||||
const param = ":embed=yes&:toolbar=yes&:iframeSizedToWindow=true";
|
||||
|
||||
useEffect(() => {
|
||||
async function initState() {
|
||||
|
|
|
|||
|
|
@ -43,8 +43,8 @@ export default function FeedbackCenter() {
|
|||
const [ticket6, setTicket6] = useState("");
|
||||
const [isInternational, setIsInternational] = useState([false, false, false]);
|
||||
|
||||
const baseUrl = "https://analytic.sitani.info/";
|
||||
const url = "https://analytic.sitani.info/trusted/";
|
||||
const baseUrl = "https://db-mediahub.polri.go.id/";
|
||||
const url = "https://db-mediahub.polri.go.id/trusted/";
|
||||
|
||||
const view1 =
|
||||
levelName == "MABES POLRI"
|
||||
|
|
@ -53,7 +53,7 @@ export default function FeedbackCenter() {
|
|||
: "views/2023_08_MediaHUB-KtnMgt_Rev100/db-tickets?"
|
||||
: `views/2023_08_MediaHUB-KtnMgt_Rev100/db-tickets?provinsi-polda=${provState}&`;
|
||||
|
||||
const param = ":embed=yes&:toolbar=no&:iframeSizedToWindow=true";
|
||||
const param = ":embed=yes&:toolbar=yes&:iframeSizedToWindow=true";
|
||||
|
||||
useEffect(() => {
|
||||
async function initState() {
|
||||
|
|
|
|||
|
|
@ -38,8 +38,8 @@ export default function ContentManagement() {
|
|||
const [ticket6, setTicket6] = useState("");
|
||||
const [isInternational, setIsInternational] = useState([false, false, false]);
|
||||
|
||||
const baseUrl = "https://analytic.sitani.info/";
|
||||
const url = "https://analytic.sitani.info/trusted/";
|
||||
const baseUrl = "https://db-mediahub.polri.go.id/";
|
||||
const url = "https://db-mediahub.polri.go.id/trusted/";
|
||||
|
||||
const view1 =
|
||||
levelName == "MABES POLRI"
|
||||
|
|
@ -69,7 +69,7 @@ export default function ContentManagement() {
|
|||
: "views/2023_08_MediaHUB-KtnMgt_Rev100/db-ktn-act-jnl?"
|
||||
: `views/2023_08_MediaHUB-KtnMgt_Rev100/db-ktn-act-jnl?provinsi-polda=${poldaState}&`;
|
||||
|
||||
const param = ":embed=yes&:toolbar=no&:iframeSizedToWindow=true";
|
||||
const param = ":embed=yes&:toolbar=yes&:iframeSizedToWindow=true";
|
||||
|
||||
useEffect(() => {
|
||||
async function initState() {
|
||||
|
|
|
|||
|
|
@ -100,7 +100,7 @@ export default function CreateAccountForBroadcast() {
|
|||
emailAddress: data.email,
|
||||
whatsappNumber: data.whatsapp,
|
||||
};
|
||||
console.log("data", data);
|
||||
// console.log("data", data);
|
||||
|
||||
const response = await saveMediaBlastAccount(reqData);
|
||||
if (response?.error) {
|
||||
|
|
|
|||
|
|
@ -157,7 +157,7 @@ export default function EditAccountForBroadcast() {
|
|||
isDefault: false,
|
||||
isAdmin: true,
|
||||
};
|
||||
console.log("data", data);
|
||||
// console.log("data", data);
|
||||
|
||||
const response = await saveUserInternal(reqData);
|
||||
if (response?.error) {
|
||||
|
|
|
|||
|
|
@ -136,7 +136,7 @@ const CampaignListTable = () => {
|
|||
item.no = (page - 1) * 10 + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", data);
|
||||
// console.log("contentData : ", data);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -117,8 +117,8 @@ export default function BroadcastCampaignDetail({
|
|||
|
||||
async function getListPaginationData() {
|
||||
loading();
|
||||
console.log("Type : ", typeFilter);
|
||||
console.log("Date : ", startDateString, endDateString);
|
||||
// console.log("Type : ", typeFilter);
|
||||
// console.log("Date : ", startDateString, endDateString);
|
||||
|
||||
try {
|
||||
const res = await getMediaBlastBroadcastList(
|
||||
|
|
@ -152,7 +152,7 @@ export default function BroadcastCampaignDetail({
|
|||
]);
|
||||
|
||||
function setupData(rawData: PaginatedResponse) {
|
||||
console.log("raw", rawData);
|
||||
// console.log("raw", rawData);
|
||||
if (rawData !== undefined) {
|
||||
const dataContent = rawData?.content;
|
||||
const data: CampaignData[] = [];
|
||||
|
|
@ -251,7 +251,7 @@ export default function BroadcastCampaignDetail({
|
|||
setEndDateString(getOnlyDate(endDate));
|
||||
}
|
||||
}
|
||||
console.log("date range", dateRange);
|
||||
// console.log("date range", dateRange);
|
||||
initState();
|
||||
}, [calenderState, startDate, endDate]);
|
||||
|
||||
|
|
|
|||
|
|
@ -160,7 +160,7 @@ const BroadcastEmailTable = () => {
|
|||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", data);
|
||||
// console.log("contentData : ", data);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -160,7 +160,7 @@ const BroadcastWhatsAppTable = () => {
|
|||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", data);
|
||||
// console.log("contentData : ", data);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -85,7 +85,7 @@ export default function EditUserForm() {
|
|||
const response = await getUserById(String(id));
|
||||
const res = response?.data?.data;
|
||||
close();
|
||||
console.log("res", res);
|
||||
// console.log("res", res);
|
||||
form.setValue("fullname", res?.fullname);
|
||||
form.setValue("username", res?.username);
|
||||
form.setValue("phoneNumber", res?.phoneNumber);
|
||||
|
|
|
|||
|
|
@ -126,7 +126,7 @@ export default function EditUserForm() {
|
|||
const response = await getUserById(String(id));
|
||||
const res = response?.data?.data;
|
||||
close();
|
||||
console.log("res", res);
|
||||
// console.log("res", res);
|
||||
form.setValue("fullname", res?.fullname);
|
||||
form.setValue("username", res?.username);
|
||||
form.setValue("phoneNumber", res?.phoneNumber);
|
||||
|
|
|
|||
|
|
@ -203,7 +203,7 @@ export default function DetailUserForm() {
|
|||
const response = await getUserById(String(id));
|
||||
const res = response?.data?.data;
|
||||
close();
|
||||
console.log("res", res);
|
||||
// console.log("res", res);
|
||||
if (Number(res.roleId) > 4) {
|
||||
form.setValue("fullname", res?.fullname);
|
||||
form.setValue("username", res?.username);
|
||||
|
|
@ -215,7 +215,7 @@ export default function DetailUserForm() {
|
|||
form.setValue("level", String(res?.userLevelId));
|
||||
} else {
|
||||
initFetch();
|
||||
console.log("sadad", res?.role?.code);
|
||||
// console.log("sadad", res?.role?.code);
|
||||
form.setValue("fullname", res?.fullname);
|
||||
form.setValue("username", res?.username);
|
||||
form.setValue("phoneNumber", res?.phoneNumber);
|
||||
|
|
|
|||
|
|
@ -209,7 +209,7 @@ export default function EditUserForm() {
|
|||
const response = await getUserById(String(id));
|
||||
const res = response?.data?.data;
|
||||
close();
|
||||
console.log("res", res);
|
||||
// console.log("res", res);
|
||||
if (Number(res.roleId) > 4) {
|
||||
form.setValue("fullname", res?.fullname);
|
||||
form.setValue("username", res?.username);
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ export default function TrackingMediaModal(props: { triggerFetch: () => void })
|
|||
}
|
||||
|
||||
if (/\s/.test(value)) {
|
||||
console.log("Terdapat spasi dalam input");
|
||||
// console.log("Terdapat spasi dalam input");
|
||||
fecthAll();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -161,11 +161,11 @@ const NewsTable = () => {
|
|||
setCategoryFilter(
|
||||
categorie?.split("&")?.length > 1 ? categorie?.split("&") : [categorie]
|
||||
);
|
||||
console.log(
|
||||
"Kategori",
|
||||
categorie,
|
||||
categorie?.split("&")?.length > 1 ? categorie?.split("&") : [categorie]
|
||||
);
|
||||
// console.log(
|
||||
// "Kategori",
|
||||
// categorie,
|
||||
// categorie?.split("&")?.length > 1 ? categorie?.split("&") : [categorie]
|
||||
// );
|
||||
}
|
||||
}, [categorie]);
|
||||
|
||||
|
|
@ -177,7 +177,7 @@ const NewsTable = () => {
|
|||
} else {
|
||||
filter.splice(categoryFilter.indexOf(id), 1);
|
||||
}
|
||||
console.log("checkbox filter", filter);
|
||||
// console.log("checkbox filter", filter);
|
||||
setCategoryFilter(filter);
|
||||
router.push(`?category=${filter.join("&")}`);
|
||||
};
|
||||
|
|
|
|||
|
|
@ -179,11 +179,11 @@ const ResultTable = () => {
|
|||
setCategoryFilter(
|
||||
categorie?.split("&")?.length > 1 ? categorie?.split("&") : [categorie]
|
||||
);
|
||||
console.log(
|
||||
"Kategori",
|
||||
categorie,
|
||||
categorie?.split("&")?.length > 1 ? categorie?.split("&") : [categorie]
|
||||
);
|
||||
// console.log(
|
||||
// "Kategori",
|
||||
// categorie,
|
||||
// categorie?.split("&")?.length > 1 ? categorie?.split("&") : [categorie]
|
||||
// );
|
||||
}
|
||||
}, [categorie]);
|
||||
|
||||
|
|
@ -195,7 +195,7 @@ const ResultTable = () => {
|
|||
} else {
|
||||
filter.splice(categoryFilter.indexOf(id), 1);
|
||||
}
|
||||
console.log("checkbox filter", filter);
|
||||
// console.log("checkbox filter", filter);
|
||||
setCategoryFilter(filter);
|
||||
router.push(`?category=${filter.join("&")}`);
|
||||
};
|
||||
|
|
|
|||
|
|
@ -151,11 +151,11 @@ const NewsTable = () => {
|
|||
setCategoryFilter(
|
||||
categorie?.split("&")?.length > 1 ? categorie?.split("&") : [categorie]
|
||||
);
|
||||
console.log(
|
||||
"Kategori",
|
||||
categorie,
|
||||
categorie?.split("&")?.length > 1 ? categorie?.split("&") : [categorie]
|
||||
);
|
||||
// console.log(
|
||||
// "Kategori",
|
||||
// categorie,
|
||||
// categorie?.split("&")?.length > 1 ? categorie?.split("&") : [categorie]
|
||||
// );
|
||||
}
|
||||
}, [categorie]);
|
||||
|
||||
|
|
@ -167,7 +167,7 @@ const NewsTable = () => {
|
|||
} else {
|
||||
filter.splice(categoryFilter.indexOf(id), 1);
|
||||
}
|
||||
console.log("checkbox filter", filter);
|
||||
// console.log("checkbox filter", filter);
|
||||
setCategoryFilter(filter);
|
||||
router.push(`?category=${filter.join("&")}`);
|
||||
};
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ export default function PerformancePolda() {
|
|||
return (
|
||||
<div>
|
||||
<SiteBreadcrumb />
|
||||
<p className="font-semibold">PERFORMANCE KUMULATIF PER POLDA</p>
|
||||
{/* <p className="font-semibold">PERFORMANCE KUMULATIF PER POLDA</p> */}
|
||||
<PerformancePoldaViz />
|
||||
</div>
|
||||
);
|
||||
|
|
|
|||
|
|
@ -97,7 +97,7 @@ const BannerListTable = () => {
|
|||
|
||||
const response = await listBanner();
|
||||
const data = response?.data?.data?.content;
|
||||
console.log("banner", data);
|
||||
// console.log("banner", data);
|
||||
setGetData(data);
|
||||
|
||||
close();
|
||||
|
|
|
|||
|
|
@ -176,7 +176,7 @@ const ContentListBanner = () => {
|
|||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", data);
|
||||
// console.log("contentData : ", data);
|
||||
|
||||
setData(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -88,7 +88,7 @@ const columns: ColumnDef<any>[] = [
|
|||
|
||||
const categoryDelete = async (id: number) => {
|
||||
const response = await deleteCategory(id);
|
||||
console.log(response);
|
||||
// console.log(response);
|
||||
if (response?.error) {
|
||||
error(response.message);
|
||||
return false;
|
||||
|
|
|
|||
|
|
@ -68,7 +68,7 @@ const columns: ColumnDef<any>[] = [
|
|||
|
||||
const faqDelete = async (id: string) => {
|
||||
const response = await deleteDataFAQ(id);
|
||||
console.log(response);
|
||||
// console.log(response);
|
||||
if (response?.error) {
|
||||
error(response.message);
|
||||
return false;
|
||||
|
|
|
|||
|
|
@ -110,7 +110,7 @@ const AdminFAQTable = () => {
|
|||
loading();
|
||||
const response = await getListFAQ();
|
||||
const data = response?.data?.data;
|
||||
console.log("respone", response);
|
||||
// console.log("respone", response);
|
||||
data.forEach((item: any, index: number) => {
|
||||
item.no = (page - 1) * 10 + index + 1;
|
||||
});
|
||||
|
|
|
|||
|
|
@ -69,7 +69,7 @@ const columns: ColumnDef<any>[] = [
|
|||
|
||||
const faqDelete = async (id: string) => {
|
||||
const response = await deleteDataFAQ(id);
|
||||
console.log(response);
|
||||
// console.log(response);
|
||||
if (response?.error) {
|
||||
error(response.message);
|
||||
return false;
|
||||
|
|
|
|||
|
|
@ -109,7 +109,7 @@ const AdminFeedbackTable = () => {
|
|||
loading();
|
||||
const response = await getListFeedback();
|
||||
const data = response?.data?.data;
|
||||
console.log("respone", response);
|
||||
// console.log("respone", response);
|
||||
data.forEach((item: any, index: number) => {
|
||||
item.no = (page - 1) * 10 + index + 1;
|
||||
});
|
||||
|
|
|
|||
|
|
@ -97,7 +97,7 @@ const IklanListTable = () => {
|
|||
|
||||
const response = await listBanner();
|
||||
const data = response?.data?.data?.content;
|
||||
console.log("banner", data);
|
||||
// console.log("banner", data);
|
||||
setGetData(data);
|
||||
|
||||
close();
|
||||
|
|
|
|||
|
|
@ -160,7 +160,7 @@ const AdvertisementsList = () => {
|
|||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", data);
|
||||
// console.log("contentData : ", data);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -100,7 +100,7 @@ const PopUpListTable = () => {
|
|||
|
||||
const response = await getListPopUp();
|
||||
const data = response?.data?.data?.content;
|
||||
console.log("banner", data);
|
||||
// console.log("banner", data);
|
||||
setGetData(data);
|
||||
|
||||
close();
|
||||
|
|
|
|||
|
|
@ -178,7 +178,7 @@ const ContentListPopUp = () => {
|
|||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", data);
|
||||
// console.log("contentData : ", data);
|
||||
|
||||
setData(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ export default function DetailSettingTracking(props: {
|
|||
});
|
||||
|
||||
const onSubmit = (values: any) => {
|
||||
console.log("Submitted values:", values);
|
||||
// console.log("Submitted values:", values);
|
||||
setIsOpen(false);
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ export default function UpdateSettingTracking(props: {
|
|||
});
|
||||
|
||||
const onSubmit = (values: any) => {
|
||||
console.log("Submitted values:", values);
|
||||
// console.log("Submitted values:", values);
|
||||
setIsOpen(false);
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -72,7 +72,7 @@ export default function CreateTagModal() {
|
|||
categoryId: Number(data.category),
|
||||
isActive: true,
|
||||
};
|
||||
console.log("reqqq", request);
|
||||
// console.log("reqqq", request);
|
||||
// const response = await postDataFeedback(request);
|
||||
// close();
|
||||
// if (response?.error) {
|
||||
|
|
@ -93,7 +93,7 @@ export default function CreateTagModal() {
|
|||
async function getCategoryParent() {
|
||||
const response = await getCategoriesAll();
|
||||
const res = response?.data?.data.content;
|
||||
console.log("res", res);
|
||||
// console.log("res", res);
|
||||
var levelsArr: { id: number; label: string; value: string }[] = [];
|
||||
res.forEach((levels: { id: number; name: string }) => {
|
||||
levelsArr.push({
|
||||
|
|
|
|||
|
|
@ -145,7 +145,7 @@ export default function EditTagModal(props: {
|
|||
async function getCategoryParent() {
|
||||
const response = await getCategoriesAll();
|
||||
const res = response?.data?.data.content;
|
||||
console.log("res", res);
|
||||
// console.log("res", res);
|
||||
var levelsArr: { id: number; label: string; value: string }[] = [];
|
||||
res.forEach((levels: { id: number; name: string }) => {
|
||||
levelsArr.push({
|
||||
|
|
|
|||
|
|
@ -173,7 +173,7 @@ const SurveyListTable = () => {
|
|||
item.no = (page - 1) * 10 + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", data);
|
||||
// console.log("contentData : ", data);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -178,7 +178,7 @@ const CalendarView = ({ categories }: CalendarViewProps) => {
|
|||
},
|
||||
}));
|
||||
|
||||
console.log("Event Data : ", events);
|
||||
// console.log("Event Data : ", events);
|
||||
setCalendarEvents(events);
|
||||
}
|
||||
} catch (err) {
|
||||
|
|
@ -217,7 +217,7 @@ const CalendarView = ({ categories }: CalendarViewProps) => {
|
|||
|
||||
const filteredEvents = calendarEvents.filter((event) => {
|
||||
if (!selectedCategory.length) return false;
|
||||
console.log("Event category : ", selectedCategory);
|
||||
// console.log("Event category : ", selectedCategory);
|
||||
|
||||
const eventCategories = event.extendedProps.calendar
|
||||
?.split(",")
|
||||
|
|
|
|||
|
|
@ -677,7 +677,7 @@ const EventModal = ({
|
|||
endDate: date?.to ? format(date.to, "yyyy-MM-dd") : null,
|
||||
};
|
||||
|
||||
console.log("Submitted Data:", reqData);
|
||||
// console.log("Submitted Data:", reqData);
|
||||
|
||||
const response = await saveAgendaSettings(reqData);
|
||||
if (response?.error) {
|
||||
|
|
@ -745,9 +745,6 @@ const EventModal = ({
|
|||
};
|
||||
|
||||
useEffect(() => {
|
||||
console.log("Event data:", event);
|
||||
console.log("Selected date:", selectedDate);
|
||||
|
||||
if (selectedDate) {
|
||||
setDate({
|
||||
from: selectedDate.date,
|
||||
|
|
@ -780,7 +777,7 @@ const EventModal = ({
|
|||
};
|
||||
|
||||
const toggleExpand = (poldaId: any) => {
|
||||
console.log("Toogle : ", expandedPolda);
|
||||
// console.log("Toogle : ", expandedPolda);
|
||||
setExpandedPolda((prev: any) => ({
|
||||
...prev,
|
||||
[poldaId]: !prev[poldaId],
|
||||
|
|
@ -841,11 +838,11 @@ const EventModal = ({
|
|||
fileTypeId: string,
|
||||
duration: string
|
||||
) {
|
||||
console.log(idx, id, file, fileTypeId, duration);
|
||||
// console.log(idx, id, file, fileTypeId, duration);
|
||||
|
||||
const resCsrf = await getCsrfToken();
|
||||
const csrfToken = resCsrf?.data?.token;
|
||||
console.log("CSRF TOKEN : ", csrfToken);
|
||||
// console.log("CSRF TOKEN : ", csrfToken);
|
||||
const headers = {
|
||||
"X-XSRF-TOKEN": csrfToken,
|
||||
};
|
||||
|
|
@ -867,7 +864,7 @@ const EventModal = ({
|
|||
xhr.withCredentials = true;
|
||||
},
|
||||
onError: async (e: any) => {
|
||||
console.log("Error upload :", e);
|
||||
// console.log("Error upload :", e);
|
||||
error(e);
|
||||
},
|
||||
onChunkComplete: (
|
||||
|
|
@ -989,7 +986,7 @@ const EventModal = ({
|
|||
}).then(() => {
|
||||
if (redirect === window.location.pathname) {
|
||||
fetch(redirect, { method: "GET", cache: "reload" }).then(() => {
|
||||
console.log("Data diperbarui.");
|
||||
// console.log("Data diperbarui.");
|
||||
});
|
||||
} else {
|
||||
window.location.href = redirect;
|
||||
|
|
@ -1091,7 +1088,7 @@ const EventModal = ({
|
|||
defaultMonth={date?.from}
|
||||
selected={date}
|
||||
onSelect={(newDate) => {
|
||||
console.log("Date selected:", newDate);
|
||||
// console.log("Date selected:", newDate);
|
||||
setDate(newDate);
|
||||
if (newDate?.from && newDate?.to) {
|
||||
setIsDatePickerOpen(false);
|
||||
|
|
|
|||
|
|
@ -22,14 +22,14 @@ const CalenderPage = () => {
|
|||
let valueShowed: string[] = [];
|
||||
if (userLevelNumber == 1) {
|
||||
valueShowed = ["0", "1", "2", "3", "4", "5"];
|
||||
} else if (userLevelNumber == 2 && userLevelId != 761) {
|
||||
} else if (userLevelNumber == 2 && userLevelId != 771) {
|
||||
valueShowed = ["2", "3"];
|
||||
} else if (
|
||||
(userLevelNumber == 2 && userLevelId == 761) ||
|
||||
(userLevelNumber == 3 && userParentLevelId == 761)
|
||||
(userLevelNumber == 2 && userLevelId == 771) ||
|
||||
(userLevelNumber == 3 && userParentLevelId == 771)
|
||||
) {
|
||||
valueShowed = ["4"];
|
||||
} else if (userLevelNumber == 3 && userParentLevelId != 761) {
|
||||
} else if (userLevelNumber == 3 && userParentLevelId != 771) {
|
||||
valueShowed = ["3"];
|
||||
}
|
||||
|
||||
|
|
@ -39,7 +39,7 @@ const CalenderPage = () => {
|
|||
...category,
|
||||
activeClass: "",
|
||||
}));
|
||||
console.log(formattedCategories);
|
||||
// console.log(formattedCategories);
|
||||
setCategories(formattedCategories);
|
||||
}
|
||||
}, []);
|
||||
|
|
|
|||
|
|
@ -127,7 +127,7 @@ const BlogTable = () => {
|
|||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
// console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -105,13 +105,13 @@ const useTableColumns = () => {
|
|||
if (isPublish && !isPublishOnPolda) {
|
||||
displayText = "Mabes";
|
||||
} else if (isPublish && isPublishOnPolda) {
|
||||
if (Number(creatorGroupParentLevelId) == 761) {
|
||||
if (Number(creatorGroupParentLevelId) == 771) {
|
||||
displayText = "Mabes & Satker";
|
||||
} else {
|
||||
displayText = "Mabes & Polda";
|
||||
}
|
||||
} else if (!isPublish && isPublishOnPolda) {
|
||||
if (Number(creatorGroupParentLevelId) == 761) {
|
||||
if (Number(creatorGroupParentLevelId) == 771) {
|
||||
displayText = "Satker";
|
||||
} else {
|
||||
displayText = "Polda";
|
||||
|
|
|
|||
|
|
@ -107,13 +107,13 @@ const useTableColumns = () => {
|
|||
if (isPublish && !isPublishOnPolda) {
|
||||
displayText = "Mabes";
|
||||
} else if (isPublish && isPublishOnPolda) {
|
||||
if (Number(creatorGroupParentLevelId) == 761) {
|
||||
if (Number(creatorGroupParentLevelId) == 771) {
|
||||
displayText = "Mabes & Satker";
|
||||
} else {
|
||||
displayText = "Mabes & Polda";
|
||||
}
|
||||
} else if (!isPublish && isPublishOnPolda) {
|
||||
if (Number(creatorGroupParentLevelId) == 761) {
|
||||
if (Number(creatorGroupParentLevelId) == 771) {
|
||||
displayText = "Satker";
|
||||
} else {
|
||||
displayText = "Polda";
|
||||
|
|
|
|||
|
|
@ -133,7 +133,7 @@ const TableTeks = () => {
|
|||
item.no = (page - 1) * limit + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
// console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -144,7 +144,7 @@ const useTableColumns = () => {
|
|||
|
||||
const handleClick = (e: React.MouseEvent) => {
|
||||
if (e.ctrlKey) {
|
||||
console.log("Ctrl + Click detected");
|
||||
// console.log("Ctrl + Click detected");
|
||||
}
|
||||
// Paksa buka menu meskipun ctrl ditekan
|
||||
setOpen(true);
|
||||
|
|
|
|||
|
|
@ -105,13 +105,13 @@ const useTableColumns = () => {
|
|||
if (isPublish && !isPublishOnPolda) {
|
||||
displayText = "Mabes";
|
||||
} else if (isPublish && isPublishOnPolda) {
|
||||
if (Number(creatorGroupParentLevelId) == 761) {
|
||||
if (Number(creatorGroupParentLevelId) == 771) {
|
||||
displayText = "Mabes & Satker";
|
||||
} else {
|
||||
displayText = "Mabes & Polda";
|
||||
}
|
||||
} else if (!isPublish && isPublishOnPolda) {
|
||||
if (Number(creatorGroupParentLevelId) == 761) {
|
||||
if (Number(creatorGroupParentLevelId) == 771) {
|
||||
displayText = "Satker";
|
||||
} else {
|
||||
displayText = "Polda";
|
||||
|
|
|
|||
|
|
@ -105,13 +105,13 @@ const useTableColumns = () => {
|
|||
if (isPublish && !isPublishOnPolda) {
|
||||
displayText = "Mabes";
|
||||
} else if (isPublish && isPublishOnPolda) {
|
||||
if (Number(creatorGroupParentLevelId) == 761) {
|
||||
if (Number(creatorGroupParentLevelId) == 771) {
|
||||
displayText = "Mabes & Satker";
|
||||
} else {
|
||||
displayText = "Mabes & Polda";
|
||||
}
|
||||
} else if (!isPublish && isPublishOnPolda) {
|
||||
if (Number(creatorGroupParentLevelId) == 761) {
|
||||
if (Number(creatorGroupParentLevelId) == 771) {
|
||||
displayText = "Satker";
|
||||
} else {
|
||||
displayText = "Polda";
|
||||
|
|
|
|||
|
|
@ -65,7 +65,6 @@ const useTableColumns = () => {
|
|||
header: "Status",
|
||||
cell: ({ row }) => {
|
||||
const isActive = row.getValue<boolean>("isActive");
|
||||
console.log("isActive value:", isActive); // TypeScript type is inferred correctly
|
||||
return (
|
||||
<div>
|
||||
{isActive ? (
|
||||
|
|
|
|||
|
|
@ -121,9 +121,6 @@ const MediahubTable = () => {
|
|||
contentData.forEach((item: any, index: number) => {
|
||||
item.no = (page - 1) * limit + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
setTotalPage(data?.totalPages);
|
||||
|
|
|
|||
|
|
@ -65,7 +65,6 @@ const useTableColumns = () => {
|
|||
header: "Status",
|
||||
cell: ({ row }) => {
|
||||
const isActive = row.getValue<boolean>("isActive");
|
||||
console.log("isActive value:", isActive); // TypeScript type is inferred correctly
|
||||
return (
|
||||
<div>
|
||||
{isActive ? (
|
||||
|
|
|
|||
|
|
@ -121,9 +121,6 @@ const MedsosTable = () => {
|
|||
contentData.forEach((item: any, index: number) => {
|
||||
item.no = (page - 1) * limit + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
setTotalPage(data?.totalPages);
|
||||
|
|
|
|||
|
|
@ -170,7 +170,7 @@ const ReportTable = () => {
|
|||
};
|
||||
|
||||
const handlePreview = (id: string) => {
|
||||
const url = `https://new.netidhub.com/api/media/report/view?id=${id}`;
|
||||
const url = `https://mediahub.polri.go.id/api/v2/media/report/view?id=${id}`;
|
||||
setPreviewData({ url });
|
||||
setOpenPreview(true);
|
||||
};
|
||||
|
|
@ -223,9 +223,6 @@ const ReportTable = () => {
|
|||
contentData.forEach((item: any, index: number) => {
|
||||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
setTotalPage(data?.totalPages);
|
||||
|
|
|
|||
|
|
@ -130,9 +130,6 @@ const CalendarPolriTable = () => {
|
|||
contentData.forEach((item: any, index: number) => {
|
||||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
setTotalPage(data?.totalPages);
|
||||
|
|
|
|||
|
|
@ -62,7 +62,6 @@ const useTableColumns = () => {
|
|||
accessorKey: "time",
|
||||
header: t("time", { defaultValue: "Time" }),
|
||||
cell: ({ row }: { row: { original: any } }) => {
|
||||
console.log("Row Original Data:", row.original);
|
||||
const { startTime, endTime } = row.original;
|
||||
return (
|
||||
<span className="whitespace-nowrap">
|
||||
|
|
@ -113,7 +112,6 @@ const useTableColumns = () => {
|
|||
accessorKey: "speaker",
|
||||
header: t("speaker", { defaultValue: "Speaker" }),
|
||||
cell: ({ row }: { row: { original: any } }) => {
|
||||
console.log("Row Original Data:", row.original);
|
||||
const { speakerTitle, speakerName } = row.original;
|
||||
return (
|
||||
<span className="whitespace-nowrap">
|
||||
|
|
|
|||
|
|
@ -114,9 +114,6 @@ const EventTable = () => {
|
|||
contentData.forEach((item: any, index: number) => {
|
||||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
setTotalPage(data?.totalPages);
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ const useTableColumns = (props: { selectedTypeSchedule: string }) => {
|
|||
accessorKey: "time",
|
||||
header: t("time", { defaultValue: "Time" }),
|
||||
cell: ({ row }: { row: { original: any } }) => {
|
||||
console.log("Row Original Data:", row.original);
|
||||
// console.log("Row Original Data:", row.original);
|
||||
const { startTime, endTime } = row.original;
|
||||
return (
|
||||
<span className="whitespace-nowrap">
|
||||
|
|
@ -117,7 +117,7 @@ const useTableColumns = (props: { selectedTypeSchedule: string }) => {
|
|||
accessorKey: "speaker",
|
||||
header: t("speaker", { defaultValue: "Speaker" }),
|
||||
cell: ({ row }: { row: { original: any } }) => {
|
||||
console.log("Row Original Data:", row.original);
|
||||
// console.log("Row Original Data:", row.original);
|
||||
const { speakerTitle, speakerName } = row.original;
|
||||
return (
|
||||
<span className="whitespace-nowrap">
|
||||
|
|
|
|||
|
|
@ -139,7 +139,7 @@ const LiveReportTable = () => {
|
|||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
// console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ const useTableColumns = () => {
|
|||
accessorKey: "time",
|
||||
header: t("time", { defaultValue: "Time" }),
|
||||
cell: ({ row }: { row: { original: any } }) => {
|
||||
console.log("Row Original Data:", row.original);
|
||||
// console.log("Row Original Data:", row.original);
|
||||
const { startTime, endTime } = row.original;
|
||||
return (
|
||||
<span className="whitespace-nowrap">
|
||||
|
|
@ -113,7 +113,7 @@ const useTableColumns = () => {
|
|||
accessorKey: "speaker",
|
||||
header: t("speaker", { defaultValue: "Speaker" }),
|
||||
cell: ({ row }: { row: { original: any } }) => {
|
||||
console.log("Row Original Data:", row.original);
|
||||
// console.log("Row Original Data:", row.original);
|
||||
const { speakerTitle, speakerName } = row.original;
|
||||
return (
|
||||
<span className="whitespace-nowrap">
|
||||
|
|
|
|||
|
|
@ -129,7 +129,7 @@ const PressConferenceTable = () => {
|
|||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
// console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ const useTableColumns = () => {
|
|||
accessorKey: "time",
|
||||
header: t("time", { defaultValue: "Time" }),
|
||||
cell: ({ row }: { row: { original: any } }) => {
|
||||
console.log("Row Original Data:", row.original);
|
||||
// console.log("Row Original Data:", row.original);
|
||||
const { startTime, endTime } = row.original;
|
||||
return (
|
||||
<span className="whitespace-nowrap">
|
||||
|
|
@ -113,7 +113,7 @@ const useTableColumns = () => {
|
|||
accessorKey: "speaker",
|
||||
header: t("speaker", { defaultValue: "Speaker" }),
|
||||
cell: ({ row }: { row: { original: any } }) => {
|
||||
console.log("Row Original Data:", row.original);
|
||||
// console.log("Row Original Data:", row.original);
|
||||
const { speakerTitle, speakerName } = row.original;
|
||||
return (
|
||||
<span className="whitespace-nowrap">
|
||||
|
|
|
|||
|
|
@ -130,7 +130,7 @@ const PressReleaseTable = () => {
|
|||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
// console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -160,7 +160,7 @@ const TaskTable = () => {
|
|||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
// console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ export default function UserFeedback() {
|
|||
}, []);
|
||||
async function initState() {
|
||||
const response = await getUserFeedbacks();
|
||||
console.log("ssss", response?.data?.data);
|
||||
// console.log("ssss", response?.data?.data);
|
||||
setListData(response?.data?.data);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -115,7 +115,7 @@ const MediaTrackingTable = () => {
|
|||
item.no = (page - 1) * limit + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", data);
|
||||
// console.log("contentData : ", data);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -113,13 +113,12 @@ const TaskPlanMediahubTable = (props: {
|
|||
// try {
|
||||
// const res = await ticketingPagination("", limit, page - 1);
|
||||
// const data = res?.data?.data;
|
||||
console.log("datgaa", data);
|
||||
const contentData = data;
|
||||
contentData.forEach((item: any, index: number) => {
|
||||
item.no = (page - 1) * limit + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
// console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
// setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -153,8 +153,6 @@ export default function DetailDaily() {
|
|||
|
||||
if (res?.data?.data != undefined) {
|
||||
const data = res?.data?.data;
|
||||
console.log("data");
|
||||
console.log("Data :", data);
|
||||
form.setValue("title", data.title);
|
||||
form.setValue("detail", data.description);
|
||||
form.setValue("date", new Date(data.date));
|
||||
|
|
@ -205,7 +203,7 @@ export default function DetailDaily() {
|
|||
const editor = useRef(null);
|
||||
|
||||
const onSubmit = async (data: z.infer<typeof FormSchema>) => {
|
||||
console.log("data", data);
|
||||
// console.log("data", data);
|
||||
if (form.getValues("detail") == "") {
|
||||
form.setError("detail", {
|
||||
type: "manual",
|
||||
|
|
@ -234,7 +232,7 @@ export default function DetailDaily() {
|
|||
.filter((key) => selected[key])
|
||||
.join(", ");
|
||||
};
|
||||
console.log("data", data, selected);
|
||||
// console.log("data", data, selected);
|
||||
loading();
|
||||
|
||||
const reqData = {
|
||||
|
|
@ -258,7 +256,7 @@ export default function DetailDaily() {
|
|||
assignmentMainTypeId: 1,
|
||||
};
|
||||
|
||||
console.log("req =>", reqData);
|
||||
// console.log("req =>", reqData);
|
||||
const response = await savePlanning(reqData);
|
||||
|
||||
if (response?.error) {
|
||||
|
|
|
|||
|
|
@ -152,8 +152,6 @@ export default function EditDaily() {
|
|||
|
||||
if (res?.data?.data != undefined) {
|
||||
const data = res?.data?.data;
|
||||
console.log("data");
|
||||
console.log("Data :", data);
|
||||
form.setValue("title", data.title);
|
||||
form.setValue("detail", data.description);
|
||||
form.setValue("date", new Date(data.date));
|
||||
|
|
@ -218,7 +216,7 @@ export default function EditDaily() {
|
|||
const editor = useRef(null);
|
||||
|
||||
const onSubmit = async (data: z.infer<typeof FormSchema>) => {
|
||||
console.log("data", data);
|
||||
// console.log("data", data);
|
||||
if (form.getValues("detail") == "") {
|
||||
form.setError("detail", {
|
||||
type: "manual",
|
||||
|
|
@ -247,7 +245,7 @@ export default function EditDaily() {
|
|||
.filter((key) => selected[key])
|
||||
.join(", ");
|
||||
};
|
||||
console.log("data", data, selected);
|
||||
// console.log("data", data, selected);
|
||||
loading();
|
||||
|
||||
const reqData = {
|
||||
|
|
|
|||
|
|
@ -166,7 +166,7 @@ export default function CreateDaily() {
|
|||
const editor = useRef(null);
|
||||
|
||||
const onSubmit = async (data: z.infer<typeof FormSchema>) => {
|
||||
console.log("data", data);
|
||||
// console.log("data", data);
|
||||
if (form.getValues("detail") == "") {
|
||||
form.setError("detail", {
|
||||
type: "manual",
|
||||
|
|
@ -195,7 +195,7 @@ export default function CreateDaily() {
|
|||
.filter((key) => selected[key])
|
||||
.join(", ");
|
||||
};
|
||||
console.log("data", data, selected);
|
||||
// console.log("data", data, selected);
|
||||
loading();
|
||||
|
||||
const reqData = {
|
||||
|
|
@ -219,7 +219,7 @@ export default function CreateDaily() {
|
|||
assignmentMainTypeId: 1,
|
||||
};
|
||||
|
||||
console.log("req =>", reqData);
|
||||
// console.log("req =>", reqData);
|
||||
const response = await savePlanning(reqData);
|
||||
|
||||
if (response?.error) {
|
||||
|
|
|
|||
|
|
@ -76,11 +76,9 @@ export default function DetailMonthly() {
|
|||
close();
|
||||
if (res?.data?.data != undefined) {
|
||||
const data = res?.data?.data;
|
||||
console.log("Data :", data);
|
||||
form.setValue("title", data?.title);
|
||||
form.setValue("detail", data.description);
|
||||
const date = parseDate(data.date);
|
||||
console.log("date", date);
|
||||
form.setValue(
|
||||
"month",
|
||||
new Date(date.getFullYear(), date.getMonth(), 1)
|
||||
|
|
@ -127,7 +125,7 @@ export default function DetailMonthly() {
|
|||
).getFullYear()}`,
|
||||
status: "Open",
|
||||
};
|
||||
console.log("req", reqData, data.month);
|
||||
// console.log("req", reqData, data.month);
|
||||
const response = await savePlanning(reqData);
|
||||
close();
|
||||
if (response?.error) {
|
||||
|
|
@ -154,7 +152,7 @@ export default function DetailMonthly() {
|
|||
selectedDate.getMonth(),
|
||||
1
|
||||
);
|
||||
console.log("newDate", newDate, selectedDate);
|
||||
// console.log("newDate", newDate, selectedDate);
|
||||
form.setValue("month", newDate);
|
||||
};
|
||||
return (
|
||||
|
|
|
|||
|
|
@ -77,11 +77,9 @@ export default function EditMonthly() {
|
|||
close();
|
||||
if (res?.data?.data != undefined) {
|
||||
const data = res?.data?.data;
|
||||
console.log("Data :", data);
|
||||
form.setValue("title", data?.title);
|
||||
form.setValue("detail", data.description);
|
||||
const date = parseDate(data.date);
|
||||
console.log("date", date);
|
||||
form.setValue(
|
||||
"month",
|
||||
new Date(date.getFullYear(), date.getMonth(), 1)
|
||||
|
|
@ -129,7 +127,7 @@ export default function EditMonthly() {
|
|||
date: `${month.toString().padStart(2, "0")}/${year}`,
|
||||
status: "Open",
|
||||
};
|
||||
console.log("req", reqData, data.month);
|
||||
// console.log("req", reqData, data.month);
|
||||
const response = await savePlanning(reqData);
|
||||
close();
|
||||
if (response?.error) {
|
||||
|
|
@ -156,7 +154,7 @@ export default function EditMonthly() {
|
|||
selectedDate.getMonth(),
|
||||
1
|
||||
);
|
||||
console.log("newDate", newDate, selectedDate);
|
||||
// console.log("newDate", newDate, selectedDate);
|
||||
form.setValue("month", newDate);
|
||||
};
|
||||
return (
|
||||
|
|
|
|||
|
|
@ -97,7 +97,7 @@ export default function CreateMonthly() {
|
|||
date: `${month.toString().padStart(2, "0")}/${year}`,
|
||||
status: "Open",
|
||||
};
|
||||
console.log("req", reqData, data.month);
|
||||
// console.log("req", reqData, data.month);
|
||||
const response = await savePlanning(reqData);
|
||||
close();
|
||||
if (response?.error) {
|
||||
|
|
|
|||
|
|
@ -119,7 +119,7 @@ export default function DetailWeekly() {
|
|||
status: "Open",
|
||||
parentId: parentId,
|
||||
};
|
||||
console.log("req", reqData);
|
||||
// console.log("req", reqData);
|
||||
const response = await savePlanning(reqData);
|
||||
close();
|
||||
if (response?.error) {
|
||||
|
|
@ -147,7 +147,7 @@ export default function DetailWeekly() {
|
|||
close();
|
||||
if (res?.data?.data != undefined) {
|
||||
const data = res?.data?.data;
|
||||
console.log("Data :", data);
|
||||
// console.log("Data :", data);
|
||||
form.setValue("title", data?.title);
|
||||
form.setValue("week", {
|
||||
from: new Date(data?.startDate),
|
||||
|
|
|
|||
|
|
@ -118,7 +118,7 @@ export default function EditWeekly() {
|
|||
status: "Open",
|
||||
parentId: parentId,
|
||||
};
|
||||
console.log("req", reqData);
|
||||
// console.log("req", reqData);
|
||||
const response = await savePlanning(reqData);
|
||||
close();
|
||||
if (response?.error) {
|
||||
|
|
@ -146,7 +146,7 @@ export default function EditWeekly() {
|
|||
close();
|
||||
if (res?.data?.data != undefined) {
|
||||
const data = res?.data?.data;
|
||||
console.log("Data :", data);
|
||||
// console.log("Data :", data);
|
||||
form.setValue("title", data?.title);
|
||||
form.setValue("week", {
|
||||
from: new Date(data?.startDate),
|
||||
|
|
|
|||
|
|
@ -117,7 +117,7 @@ export default function CreateMonthly() {
|
|||
status: "Open",
|
||||
parentId: Number(data.parentId),
|
||||
};
|
||||
console.log("req", reqData);
|
||||
// console.log("req", reqData);
|
||||
const response = await savePlanning(reqData);
|
||||
close();
|
||||
if (response?.error) {
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ export default function DetailTaskPlanMediahub() {
|
|||
|
||||
if (res?.data?.data != undefined) {
|
||||
const data = res?.data?.data;
|
||||
console.log("Data :", data);
|
||||
// console.log("Data :", data);
|
||||
setPlanningData(data);
|
||||
setAssignedTopLevel(data?.assignedToTopLevel);
|
||||
setArrayDestination(data?.assignedToLevel);
|
||||
|
|
@ -112,7 +112,7 @@ export default function DetailTaskPlanMediahub() {
|
|||
label: option.title,
|
||||
value: option.id,
|
||||
}));
|
||||
console.log("res", optionArr);
|
||||
// console.log("res", optionArr);
|
||||
|
||||
setWeeklyList(optionArr);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -113,13 +113,13 @@ const TaskPlanMediahubTable = (props: {
|
|||
// try {
|
||||
// const res = await ticketingPagination("", limit, page - 1);
|
||||
// const data = res?.data?.data;
|
||||
console.log("datgaa", data);
|
||||
// console.log("datgaa", data);
|
||||
const contentData = data;
|
||||
contentData.forEach((item: any, index: number) => {
|
||||
item.no = (page - 1) * limit + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
// console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
// setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -153,8 +153,6 @@ export default function DetailDaily() {
|
|||
|
||||
if (res?.data?.data != undefined) {
|
||||
const data = res?.data?.data;
|
||||
console.log("data");
|
||||
console.log("Data :", data);
|
||||
form.setValue("title", data.title);
|
||||
form.setValue("detail", data.description);
|
||||
form.setValue("date", new Date(data.date));
|
||||
|
|
@ -205,7 +203,7 @@ export default function DetailDaily() {
|
|||
const editor = useRef(null);
|
||||
|
||||
const onSubmit = async (data: z.infer<typeof FormSchema>) => {
|
||||
console.log("data", data);
|
||||
// console.log("data", data);
|
||||
if (form.getValues("detail") == "") {
|
||||
form.setError("detail", {
|
||||
type: "manual",
|
||||
|
|
@ -234,7 +232,7 @@ export default function DetailDaily() {
|
|||
.filter((key) => selected[key])
|
||||
.join(", ");
|
||||
};
|
||||
console.log("data", data, selected);
|
||||
// console.log("data", data, selected);
|
||||
loading();
|
||||
|
||||
const reqData = {
|
||||
|
|
@ -258,7 +256,7 @@ export default function DetailDaily() {
|
|||
assignmentMainTypeId: 1,
|
||||
};
|
||||
|
||||
console.log("req =>", reqData);
|
||||
// console.log("req =>", reqData);
|
||||
const response = await savePlanning(reqData);
|
||||
|
||||
if (response?.error) {
|
||||
|
|
|
|||
|
|
@ -152,8 +152,6 @@ export default function EditDaily() {
|
|||
|
||||
if (res?.data?.data != undefined) {
|
||||
const data = res?.data?.data;
|
||||
console.log("data");
|
||||
console.log("Data :", data);
|
||||
form.setValue("title", data.title);
|
||||
form.setValue("detail", data.description);
|
||||
form.setValue("date", new Date(data.date));
|
||||
|
|
@ -218,7 +216,7 @@ export default function EditDaily() {
|
|||
const editor = useRef(null);
|
||||
|
||||
const onSubmit = async (data: z.infer<typeof FormSchema>) => {
|
||||
console.log("data", data);
|
||||
// console.log("data", data);
|
||||
if (form.getValues("detail") == "") {
|
||||
form.setError("detail", {
|
||||
type: "manual",
|
||||
|
|
@ -247,7 +245,7 @@ export default function EditDaily() {
|
|||
.filter((key) => selected[key])
|
||||
.join(", ");
|
||||
};
|
||||
console.log("data", data, selected);
|
||||
// console.log("data", data, selected);
|
||||
loading();
|
||||
|
||||
const reqData = {
|
||||
|
|
|
|||
|
|
@ -239,7 +239,7 @@ export default function CreateDaily() {
|
|||
assignmentMainTypeId: 2,
|
||||
};
|
||||
|
||||
console.log("req =>", reqData);
|
||||
// console.log("req =>", reqData);
|
||||
const response = await savePlanning(reqData);
|
||||
|
||||
if (response?.error) {
|
||||
|
|
|
|||
|
|
@ -76,11 +76,11 @@ export default function DetailMonthly() {
|
|||
close();
|
||||
if (res?.data?.data != undefined) {
|
||||
const data = res?.data?.data;
|
||||
console.log("Data :", data);
|
||||
// console.log("Data :", data);
|
||||
form.setValue("title", data?.title);
|
||||
form.setValue("detail", data.description);
|
||||
const date = parseDate(data.date);
|
||||
console.log("date", date);
|
||||
// console.log("date", date);
|
||||
form.setValue(
|
||||
"month",
|
||||
new Date(date.getFullYear(), date.getMonth(), 1)
|
||||
|
|
@ -127,7 +127,7 @@ export default function DetailMonthly() {
|
|||
date: `${month.toString().padStart(2, "0")}/${year}`,
|
||||
status: "Open",
|
||||
};
|
||||
console.log("req", reqData, data.month);
|
||||
// console.log("req", reqData, data.month);
|
||||
const response = await savePlanning(reqData);
|
||||
close();
|
||||
if (response?.error) {
|
||||
|
|
@ -154,7 +154,7 @@ export default function DetailMonthly() {
|
|||
selectedDate.getMonth(),
|
||||
1
|
||||
);
|
||||
console.log("newDate", newDate, selectedDate);
|
||||
// console.log("newDate", newDate, selectedDate);
|
||||
form.setValue("month", newDate);
|
||||
};
|
||||
return (
|
||||
|
|
|
|||
|
|
@ -76,11 +76,11 @@ export default function EditMonthly() {
|
|||
close();
|
||||
if (res?.data?.data != undefined) {
|
||||
const data = res?.data?.data;
|
||||
console.log("Data :", data);
|
||||
// console.log("Data :", data);
|
||||
form.setValue("title", data?.title);
|
||||
form.setValue("detail", data.description);
|
||||
const date = parseDate(data.date);
|
||||
console.log("date", date);
|
||||
// console.log("date", date);
|
||||
form.setValue(
|
||||
"month",
|
||||
new Date(date.getFullYear(), date.getMonth(), 1)
|
||||
|
|
@ -128,7 +128,7 @@ export default function EditMonthly() {
|
|||
date: `${month.toString().padStart(2, "0")}/${year}`,
|
||||
status: "Open",
|
||||
};
|
||||
console.log("req", reqData, data.month);
|
||||
// console.log("req", reqData, data.month);
|
||||
const response = await savePlanning(reqData);
|
||||
close();
|
||||
if (response?.error) {
|
||||
|
|
@ -155,7 +155,7 @@ export default function EditMonthly() {
|
|||
selectedDate.getMonth(),
|
||||
1
|
||||
);
|
||||
console.log("newDate", newDate, selectedDate);
|
||||
// console.log("newDate", newDate, selectedDate);
|
||||
form.setValue("month", newDate);
|
||||
};
|
||||
return (
|
||||
|
|
|
|||
|
|
@ -95,7 +95,7 @@ export default function CreateMonthly() {
|
|||
date: `${month.toString().padStart(2, "0")}/${year}`,
|
||||
status: "Open",
|
||||
};
|
||||
console.log("req", reqData, data.month);
|
||||
// console.log("req", reqData, data.month);
|
||||
const response = await savePlanning(reqData);
|
||||
close();
|
||||
if (response?.error) {
|
||||
|
|
|
|||
|
|
@ -119,7 +119,7 @@ export default function DetailWeekly() {
|
|||
status: "Open",
|
||||
parentId: parentId,
|
||||
};
|
||||
console.log("req", reqData);
|
||||
// console.log("req", reqData);
|
||||
const response = await savePlanning(reqData);
|
||||
close();
|
||||
if (response?.error) {
|
||||
|
|
@ -147,7 +147,7 @@ export default function DetailWeekly() {
|
|||
close();
|
||||
if (res?.data?.data != undefined) {
|
||||
const data = res?.data?.data;
|
||||
console.log("Data :", data);
|
||||
// console.log("Data :", data);
|
||||
form.setValue("title", data?.title);
|
||||
form.setValue("week", {
|
||||
from: new Date(data?.startDate),
|
||||
|
|
|
|||
|
|
@ -117,7 +117,7 @@ export default function EditWeekly() {
|
|||
status: "Open",
|
||||
parentId: parentId,
|
||||
};
|
||||
console.log("req", reqData);
|
||||
// console.log("req", reqData);
|
||||
const response = await savePlanning(reqData);
|
||||
close();
|
||||
if (response?.error) {
|
||||
|
|
@ -145,7 +145,7 @@ export default function EditWeekly() {
|
|||
close();
|
||||
if (res?.data?.data != undefined) {
|
||||
const data = res?.data?.data;
|
||||
console.log("Data :", data);
|
||||
// console.log("Data :", data);
|
||||
form.setValue("title", data?.title);
|
||||
form.setValue("week", {
|
||||
from: new Date(data?.startDate),
|
||||
|
|
|
|||
|
|
@ -115,7 +115,7 @@ export default function CreateMonthly() {
|
|||
status: "Open",
|
||||
parentId: Number(data.parentId),
|
||||
};
|
||||
console.log("req", reqData);
|
||||
// console.log("req", reqData);
|
||||
const response = await savePlanning(reqData);
|
||||
close();
|
||||
if (response?.error) {
|
||||
|
|
@ -149,7 +149,7 @@ export default function CreateMonthly() {
|
|||
label: option.title,
|
||||
value: String(option.id),
|
||||
}));
|
||||
console.log("ssss", optionArr);
|
||||
// console.log("ssss", optionArr);
|
||||
setMonthlyList(optionArr);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ export default function DetailTaskPlanMediahub() {
|
|||
|
||||
if (res?.data?.data != undefined) {
|
||||
const data = res?.data?.data;
|
||||
console.log("Data :", data);
|
||||
// console.log("Data :", data);
|
||||
setPlanningData(data);
|
||||
setAssignedTopLevel(data?.assignedToTopLevel);
|
||||
setArrayDestination(data?.assignedToLevel);
|
||||
|
|
@ -113,7 +113,7 @@ export default function DetailTaskPlanMediahub() {
|
|||
label: option.title,
|
||||
value: option.id,
|
||||
}));
|
||||
console.log("res", optionArr);
|
||||
// console.log("res", optionArr);
|
||||
|
||||
setWeeklyList(optionArr);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -48,8 +48,8 @@ export default function ExecutiveDataDashboard() {
|
|||
const [ticket7, setTicket7] = useState("");
|
||||
const [isInternational, setIsInternational] = useState([false, false, false]);
|
||||
|
||||
const baseUrl = "https://analytic.sitani.info/";
|
||||
const url = "https://analytic.sitani.info/trusted/";
|
||||
const baseUrl = "https://db-mediahub.polri.go.id/";
|
||||
const url = "https://db-mediahub.polri.go.id/trusted/";
|
||||
|
||||
const safeLevelName = levelNumber ?? "";
|
||||
|
||||
|
|
@ -116,7 +116,7 @@ export default function ExecutiveDataDashboard() {
|
|||
? `views/2023_09_db-penugasan_rev100/db-penugasan-vertical-bar?polda-selected=${state}&`
|
||||
: `views/2023_09_db-penugasan_rev100/db-penugasan-vertical-bar?polda-selected=${state}&`;
|
||||
|
||||
const param = ":embed=yes&:toolbar=no&:iframeSizedToWindow=true";
|
||||
const param = ":embed=yes&:toolbar=yes&:iframeSizedToWindow=true";
|
||||
|
||||
useEffect(() => {
|
||||
async function initState() {
|
||||
|
|
|
|||
|
|
@ -37,8 +37,8 @@ export default function ExecutiveDashboard() {
|
|||
const [ticket6, setTicket6] = useState("");
|
||||
const [isInternational, setIsInternational] = useState([false, false, false]);
|
||||
|
||||
const baseUrl = "https://analytic.sitani.info/";
|
||||
const url = "https://analytic.sitani.info/trusted/";
|
||||
const baseUrl = "https://db-mediahub.polri.go.id/";
|
||||
const url = "https://db-mediahub.polri.go.id/trusted/";
|
||||
|
||||
const safeLevelName = levelNumber ?? "";
|
||||
|
||||
|
|
@ -55,7 +55,8 @@ export default function ExecutiveDashboard() {
|
|||
levelName == "MABES POLRI"
|
||||
? isInternational[1]
|
||||
? "views/2023_04_MediaHUB-Viz_INTL_Rev202/db-published-produksi?"
|
||||
: "views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-published-produksi-executive?"
|
||||
: // "views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-published-produksi-executive?"
|
||||
"/views/2025_10_MediaHUB-Viz-POLDA_Rev200/db-published-produksi-executive?"
|
||||
: safeLevelName.includes("POLDA")
|
||||
? `views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-published-produksi-polda-executive?polda-selected=${state}&`
|
||||
: `views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-published-produksi-polda-executive?polda-selected=${state}&`;
|
||||
|
|
@ -64,7 +65,8 @@ export default function ExecutiveDashboard() {
|
|||
levelName == "MABES POLRI"
|
||||
? isInternational[2]
|
||||
? "views/2023_04_MediaHUB-Viz_INTL_Rev202/db-waktu-akses-pengguna?"
|
||||
: "views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-waktu-akses-pengguna-executive?"
|
||||
: // "views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-waktu-akses-pengguna-executive?"
|
||||
"/views/2025_10_MediaHUB-Viz-POLDA_Rev200/db-waktu-akses-pengguna-executive?"
|
||||
: safeLevelName.includes("POLDA")
|
||||
? `views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-waktu-akses-pengguna-polda-executive?polda-selected=${state}&`
|
||||
: `views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-waktu-akses-pengguna-polda-executive?polda-selected=${state}&`;
|
||||
|
|
@ -72,8 +74,11 @@ export default function ExecutiveDashboard() {
|
|||
const view4 =
|
||||
levelName == "MABES POLRI"
|
||||
? isInternational[1]
|
||||
? "views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-polda?"
|
||||
: "views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-polda?"
|
||||
?
|
||||
"views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-polda?"
|
||||
:
|
||||
// "views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-polda?"
|
||||
"/views/2025_10_MediaHUB-Viz-POLDA_Rev200/db-konten-header?"
|
||||
: safeLevelName.includes("POLDA")
|
||||
? `views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-polda?polda-selected=${state}&`
|
||||
: `views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-polda?polda-selected=${state}&`;
|
||||
|
|
@ -81,8 +86,10 @@ export default function ExecutiveDashboard() {
|
|||
const view5 =
|
||||
levelName == "MABES POLRI"
|
||||
? isInternational[1]
|
||||
? "views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-polres?"
|
||||
: "views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-polres?"
|
||||
? // "views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-polres?"
|
||||
"views/2025_10_MediaHUB-Viz-POLDA_Rev200/db-konten-header"
|
||||
: // "views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-polres?"
|
||||
"views/2025_10_MediaHUB-Viz-POLDA_Rev200/db-konten-header"
|
||||
: safeLevelName.includes("POLDA")
|
||||
? `views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-polres?provinsi-polda=${state}&`
|
||||
: `views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-polres?provinsi-polda=${state}&`;
|
||||
|
|
@ -90,13 +97,15 @@ export default function ExecutiveDashboard() {
|
|||
const view6 =
|
||||
levelName == "MABES POLRI"
|
||||
? isInternational[1]
|
||||
? "views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-satker?"
|
||||
: "views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-satker?"
|
||||
? // "views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-satker?"
|
||||
"views/2025_10_MediaHUB-Viz-POLDA_Rev200/db-konten-header"
|
||||
: // "views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-satker?"
|
||||
"views/2025_10_MediaHUB-Viz-POLDA_Rev200/db-konten-header"
|
||||
: safeLevelName.includes("POLDA")
|
||||
? `views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-satker?satker-selected=${state}&`
|
||||
: `views/2023_04_MediaHUB-Viz-POLDA_Rev200/db-content-interaction-satker?satker-selected=${state}&`;
|
||||
|
||||
const param = ":embed=yes&:toolbar=no&:iframeSizedToWindow=true";
|
||||
const param = ":embed=yes&:toolbar=yes&:iframeSizedToWindow=true";
|
||||
|
||||
useEffect(() => {
|
||||
async function initState() {
|
||||
|
|
@ -140,8 +149,94 @@ export default function ExecutiveDashboard() {
|
|||
return (
|
||||
<div>
|
||||
<SiteBreadcrumb />
|
||||
<div className="mt-3 flex gap-2 flex-row justify-center">
|
||||
{/* Polda */}
|
||||
<div className="mt-3">
|
||||
<Card className="rounded-sm p-5 w-full">
|
||||
<div className="flex flex-row flex-wrap gap-5 justify-between">
|
||||
{/* ===================== POLDA ===================== */}
|
||||
{(levelNumber === "1" || levelNumber === "2") && (
|
||||
<div className="flex-1 min-w-[350px]">
|
||||
<p className="text-base font-semibold mb-3">
|
||||
Publish Konten Polda
|
||||
</p>
|
||||
|
||||
{ticket1 == "" ? (
|
||||
<iframe
|
||||
src={`${baseUrl + view4 + param}`}
|
||||
width="100%"
|
||||
height="750"
|
||||
frameBorder="0"
|
||||
className="rounded-md"
|
||||
/>
|
||||
) : (
|
||||
<iframe
|
||||
src={`${url + ticket1}/${view4}${param}`}
|
||||
width="100%"
|
||||
height="750"
|
||||
frameBorder="0"
|
||||
className="rounded-md"
|
||||
/>
|
||||
)}
|
||||
</div>
|
||||
)}
|
||||
|
||||
{/* ===================== POLRES ===================== */}
|
||||
{/* {(levelNumber === "1" || levelNumber === "2") && (
|
||||
<div className="flex-1 min-w-[350px]">
|
||||
<p className="text-base font-semibold mb-3">
|
||||
Publish Konten Polres
|
||||
</p>
|
||||
|
||||
{ticket3 == "" ? (
|
||||
<iframe
|
||||
src={`${baseUrl + view5 + param}`}
|
||||
width="100%"
|
||||
height="750"
|
||||
frameBorder="0"
|
||||
className="rounded-md"
|
||||
/>
|
||||
) : (
|
||||
<iframe
|
||||
src={`${url + ticket3}/${view5}${param}`}
|
||||
width="100%"
|
||||
height="750"
|
||||
frameBorder="0"
|
||||
className="rounded-md"
|
||||
/>
|
||||
)}
|
||||
</div>
|
||||
)} */}
|
||||
|
||||
{/* ===================== SATKER ===================== */}
|
||||
{/* {(levelNumber === "1" || levelNumber === "3") && (
|
||||
<div className="flex-1 min-w-[350px]">
|
||||
<p className="text-base font-semibold mb-3">
|
||||
Publish Konten Satker
|
||||
</p>
|
||||
|
||||
{ticket2 == "" ? (
|
||||
<iframe
|
||||
src={`${baseUrl + view6 + param}`}
|
||||
width="100%"
|
||||
height="750"
|
||||
frameBorder="0"
|
||||
className="rounded-md"
|
||||
/>
|
||||
) : (
|
||||
<iframe
|
||||
src={`${url + ticket2}/${view6}${param}`}
|
||||
width="100%"
|
||||
height="750"
|
||||
frameBorder="0"
|
||||
className="rounded-md"
|
||||
/>
|
||||
)}
|
||||
</div>
|
||||
)} */}
|
||||
</div>
|
||||
</Card>
|
||||
</div>
|
||||
|
||||
{/* <div className="mt-3 flex gap-2 flex-row justify-center">
|
||||
{(levelNumber === "1" || levelNumber === "2") && (
|
||||
<Card
|
||||
className={`rounded-sm p-3 ${
|
||||
|
|
@ -200,7 +295,6 @@ export default function ExecutiveDashboard() {
|
|||
</Card>
|
||||
)}
|
||||
|
||||
{/* Satker */}
|
||||
{(levelNumber === "1" || levelNumber === "3") && (
|
||||
<Card
|
||||
className={`rounded-sm p-3 ${
|
||||
|
|
@ -229,7 +323,7 @@ export default function ExecutiveDashboard() {
|
|||
</div>
|
||||
</Card>
|
||||
)}
|
||||
</div>
|
||||
</div> */}
|
||||
<div className="w-full mt-3">
|
||||
<Card className="rounded-sm p-3 h-[750px]">
|
||||
<div className="flex flex-row justify-between">
|
||||
|
|
|
|||
|
|
@ -156,7 +156,7 @@ const ContentTable = () => {
|
|||
item.no = (page - 1) * limit + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
// console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -152,7 +152,7 @@ const CollaborationTable = () => {
|
|||
contentData.forEach((item: any, index: number) => {
|
||||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
console.log("contentData : ", contentData);
|
||||
// console.log("contentData : ", contentData);
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
setTotalPage(data?.totalPages);
|
||||
|
|
|
|||
|
|
@ -42,11 +42,11 @@ export default function CollaborationPage() {
|
|||
const res = await getTicketCollaborationTeams(String(id));
|
||||
|
||||
if (res?.data !== null) {
|
||||
console.log("response teams:", res);
|
||||
// console.log("response teams:", res);
|
||||
|
||||
setDetailTickets(res?.data?.data?.tickets);
|
||||
setTeams(res?.data?.data?.userTeam);
|
||||
console.log("userteam", res?.data?.data?.userTeam);
|
||||
// console.log("userteam", res?.data?.data?.userTeam);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -59,7 +59,7 @@ export default function CollaborationPage() {
|
|||
if (id != undefined) {
|
||||
loading();
|
||||
const responseGet = await getCollabDiscussion(String(id));
|
||||
console.log("get res data", responseGet?.data?.data);
|
||||
// console.log("get res data", responseGet?.data?.data);
|
||||
close();
|
||||
setListDiscussion(responseGet?.data?.data);
|
||||
}
|
||||
|
|
@ -68,7 +68,7 @@ export default function CollaborationPage() {
|
|||
async function deleteDataSuggestion(dataId: string | number) {
|
||||
loading();
|
||||
const response = await deleteCollabDiscussion(dataId);
|
||||
console.log(response);
|
||||
// console.log(response);
|
||||
toast({
|
||||
title: "Sukses hapus",
|
||||
});
|
||||
|
|
|
|||
|
|
@ -155,12 +155,12 @@ const EscalationTable = () => {
|
|||
contentData.forEach((item: any, index: number) => {
|
||||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
console.log("contentData : ", contentData);
|
||||
// console.log("contentData : ", contentData);
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
setTotalPage(data?.totalPages);
|
||||
} catch (error) {
|
||||
console.error("Error fetching tasks:", error);
|
||||
// console.error("Error fetching tasks:", error);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -157,7 +157,7 @@ const InternalTable = () => {
|
|||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
// console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -133,7 +133,7 @@ const TaskTable = () => {
|
|||
item.no = (page - 1) * Number(showData) + index + 1;
|
||||
});
|
||||
|
||||
console.log("contentData : ", contentData);
|
||||
// console.log("contentData : ", contentData);
|
||||
|
||||
setDataTable(contentData);
|
||||
setTotalData(data?.totalElements);
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@ const VideoSliderPage = () => {
|
|||
contentTypeId: "2",
|
||||
};
|
||||
const response = await getListContent(request);
|
||||
console.log("category", response);
|
||||
// console.log("category", response);
|
||||
setNewContent(response?.data?.data?.content);
|
||||
};
|
||||
return (
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ const AudioSliderPage = () => {
|
|||
contentTypeId: "4",
|
||||
};
|
||||
const response = await getListContent(request);
|
||||
console.log("category", response);
|
||||
// console.log("category", response);
|
||||
setNewContent(response?.data?.data?.content);
|
||||
};
|
||||
return (
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ const ImageSliderPage = () => {
|
|||
contentTypeId: "3",
|
||||
};
|
||||
const response = await getListContent(request);
|
||||
console.log("category", response);
|
||||
// console.log("category", response);
|
||||
setNewContent(response?.data?.data?.content);
|
||||
};
|
||||
return (
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ const TeksSliderPage = () => {
|
|||
contentTypeId: "1",
|
||||
};
|
||||
const response = await getListContent(request);
|
||||
console.log("category", response);
|
||||
// console.log("category", response);
|
||||
setNewContent(response?.data?.data?.content);
|
||||
};
|
||||
return (
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue