From 142b1acfdcd10e5221e2a7bcd08b8fdf32758a76 Mon Sep 17 00:00:00 2001 From: wahyu Date: Fri, 3 Nov 2023 09:23:51 +0700 Subject: [PATCH] update report analysis --- .../SimproV2/CreatedProyek/ReportAnalysis.js | 46 +++++++++++++++---- 1 file changed, 38 insertions(+), 8 deletions(-) diff --git a/src/views/SimproV2/CreatedProyek/ReportAnalysis.js b/src/views/SimproV2/CreatedProyek/ReportAnalysis.js index 94e24cf..b89298b 100644 --- a/src/views/SimproV2/CreatedProyek/ReportAnalysis.js +++ b/src/views/SimproV2/CreatedProyek/ReportAnalysis.js @@ -90,14 +90,14 @@ const ReportAnalysis = ({ openDialog, closeDialog, toggleDialog, projectId }) => {title: "Actual Start", dataIndex: "actual_start", key: "actual_start", render: (text, record) => ( <> - {moment(record.actual_start).format("DD-MM-YY")} + {record.actual_start ? moment(record.actual_start).format("DD-MM-YY") : ""} ), }, {title: "Actual Finish", dataIndex: "actual_end", key: "actual_end", render: (text, record) => ( <> - {moment(record.end_date).format("DD-MM-YY")} + {record.actual_end ? moment(record.actual_end).format("DD-MM-YY") : ""} ), }, @@ -152,17 +152,45 @@ const ReportAnalysis = ({ openDialog, closeDialog, toggleDialog, projectId }) => const columnActivityToHr = [ {title: "Activity", dataIndex: "join_second_name", key: "join_second_name"}, {title: "Gantt", dataIndex: "join_fourth_name_version", key: "join_fourth_name_version"}, - {title: "Start Date", dataIndex: "start_date", key: "start_date", + {title: "Baseline Start", dataIndex: "join_second_planned_start", key: "join_second_planned_start", + render: (text, record) => ( + <> + {moment(record.join_second_planned_start).format("DD-MM-YY")} + + ), + }, + {title: "Baseline Finish", dataIndex: "join_second_planned_end", key: "join_second_planned_end", + render: (text, record) => ( + <> + {moment(record.join_second_planned_end).format("DD-MM-YY")} + + ), + }, + {title: "Early Start", dataIndex: "join_second_start_date", key: "join_second_start_date", + render: (text, record) => ( + <> + {moment(record.join_second_start_date).format("DD-MM-YY")} + + ), + }, + {title: "Early Finish", dataIndex: "join_second_end_date", key: "join_second_end_date", + render: (text, record) => ( + <> + {moment(record.join_second_end_date).format("DD-MM-YY")} + + ), + }, + {title: "Actual Start", dataIndex: "join_second_actual_start", key: "join_second_actual_start", render: (text, record) => ( <> - {moment(record.start_date).format("DD-MM-YYYY")} + {record.join_second_actual_start ? moment(record.join_second_actual_start).format("DD-MM-YY") : ""} ), }, - {title: "End Date", dataIndex: "end_date", key: "end_date", + {title: "Actual Finish", dataIndex: "join_second_actual_end", key: "join_second_actual_end", render: (text, record) => ( <> - {moment(record.end_date).format("DD-MM-YYYY")} + {record.join_second_actual_end ? moment(record.join_second_actual_end).format("DD-MM-YY") : ""} ), }, @@ -331,7 +359,7 @@ const ReportAnalysis = ({ openDialog, closeDialog, toggleDialog, projectId }) => { name: "m_activity", column_join: "activity_id", - column_results: ["name", "persentase_progress", "start_date", "end_date", "duration"] + column_results: ["name", "persentase_progress", "actual_start", "actual_end", "planned_start", "planned_end", "start_date", "end_date", "duration"] }, { name1: "m_activity", @@ -529,7 +557,8 @@ const ReportAnalysis = ({ openDialog, closeDialog, toggleDialog, projectId }) => - + +
pagination={false} rowKey={"id"} /> +