Commit 6e36aac0 authored by ardiansyah's avatar ardiansyah

Merge branch 'ENV-DEV' into 'ENV-STAGING'

Env dev

See merge request !2408
parents 249be92e b68b4a89
...@@ -56,10 +56,10 @@ ...@@ -56,10 +56,10 @@
"build": "react-scripts --max_old_space_size=4096 build", "build": "react-scripts --max_old_space_size=4096 build",
"build_dev": "copy .env_dev .env && react-scripts --max_old_space_size=4096 build", "build_dev": "copy .env_dev .env && react-scripts --max_old_space_size=4096 build",
"build_staging": "copy .env_staging .env && react-scripts --max_old_space_size=4096 build", "build_staging": "copy .env_staging .env && react-scripts --max_old_space_size=4096 build",
"build_prod": "copy .env_prod .env && react-scripts --max_old_space_size=8192 build", "build_prod": "copy .env_prod .env && react-scripts --max_old_space_size=4096 build",
"build_dev_linux": "cp .env_dev .env && react-scripts --max_old_space_size=4096 build", "build_dev_linux": "cp .env_dev .env && react-scripts --max_old_space_size=4096 build",
"build_staging_linux": "cp .env_staging .env && react-scripts --max_old_space_size=4096 build", "build_staging_linux": "cp .env_staging .env && react-scripts --max_old_space_size=4096 build",
"build_prod_linux": "cp .env_prod .env && react-scripts --max_old_space_size=8192 build", "build_prod_linux": "cp .env_prod .env && react-scripts --max_old_space_size=4096 build",
"test": "react-scripts test", "test": "react-scripts test",
"eject": "react-scripts eject", "eject": "react-scripts eject",
"dev": "copy .env_dev .env && react-scripts start", "dev": "copy .env_dev .env && react-scripts start",
......
...@@ -165,6 +165,7 @@ const create = (type = "") => { ...@@ -165,6 +165,7 @@ const create = (type = "") => {
const getApprovedByAM = () => api.get('approval_matrix/get_all_approver') const getApprovedByAM = () => api.get('approval_matrix/get_all_approver')
const getTypeAM = () => api.get('approval_type/get_all_approval_type') const getTypeAM = () => api.get('approval_type/get_all_approval_type')
const getOperatorAM = () => api.get('operator_type/get_all_operator_type') const getOperatorAM = () => api.get('operator_type/get_all_operator_type')
const getMasterReportType = () => api.get('masterreporttype/get_all_master_report_type')
const getDetailAM = (id) => api.get(`approval_matrix/get_approval_matrix_by_id/${id}`) const getDetailAM = (id) => api.get(`approval_matrix/get_approval_matrix_by_id/${id}`)
const searchAM = (body) => api.post('/approval_matrix/search_approval_matrix', body) const searchAM = (body) => api.post('/approval_matrix/search_approval_matrix', body)
const createAM = (body) => api.post('/approval_matrix/create_approval_matrix', body) const createAM = (body) => api.post('/approval_matrix/create_approval_matrix', body)
...@@ -633,6 +634,7 @@ const create = (type = "") => { ...@@ -633,6 +634,7 @@ const create = (type = "") => {
getApprovedByAM, getApprovedByAM,
getTypeAM, getTypeAM,
getOperatorAM, getOperatorAM,
getMasterReportType,
getDetailAM, getDetailAM,
searchAM, searchAM,
createAM, createAM,
......
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -175,7 +175,8 @@ class ReportProgress extends Component { ...@@ -175,7 +175,8 @@ class ReportProgress extends Component {
let data = response.data.data let data = response.data.data
data.map((item,index) => { data.map((item,index) => {
let report = [] let report = []
let statusSubmission = String(item.submission_status).toLocaleUpperCase() let statusSubmissionCAT = String(item.submission_status_cat).toLocaleUpperCase()
let statusSubmissionFinance = String(item.submission_status_finance).toLocaleUpperCase()
let statusOI = String(item.operating_indicator).toLocaleUpperCase() let statusOI = String(item.operating_indicator).toLocaleUpperCase()
item.report.map((items,index) => { item.report.map((items,index) => {
let statusReport = String(items.status_report).toLocaleUpperCase() let statusReport = String(items.status_report).toLocaleUpperCase()
...@@ -183,7 +184,9 @@ class ReportProgress extends Component { ...@@ -183,7 +184,9 @@ class ReportProgress extends Component {
}) })
report.push( report.push(
{report_name: 'Operating Indicator', status_report: statusOI}, {report_name: 'Operating Indicator', status_report: statusOI},
{report_name: 'Submission Status', status_report: (statusSubmission == 'APPROVED' || statusSubmission == 'REVISION' || statusSubmission == 'COMPLETED') ? (statusSubmission + ' - ' + item.submissionStatusDate) : statusSubmission}) {report_name: 'Report Finance Status', status_report: (statusSubmissionFinance == 'APPROVED' || statusSubmissionFinance == 'REVISION' || statusSubmissionFinance == 'COMPLETED') ? (statusSubmissionFinance + ' - ' + item.submissionStatusDate) : statusSubmissionFinance},
{report_name: 'Report CAT Status', status_report: (statusSubmissionCAT == 'APPROVED' || statusSubmissionCAT == 'REVISION' || statusSubmissionCAT == 'COMPLETED') ? (statusSubmissionCAT + ' - ' + item.submissionStatusDate) : statusSubmissionCAT}
)
dataTable.push([ dataTable.push([
item.company_name, item.company_name,
report, report,
...@@ -239,7 +242,11 @@ class ReportProgress extends Component { ...@@ -239,7 +242,11 @@ class ReportProgress extends Component {
let data = response.data.data let data = response.data.data
data.map((item,index) => { data.map((item,index) => {
let report = item.report let report = item.report
report.push({report_name: 'Operating Indicator', status_report: item.operating_indicator}, {report_name: 'Monthly Status', status_report: item.monthly_status}) report.push(
{report_name: 'Operating Indicator', status_report: item.operating_indicator},
{report_name: 'Report Finance Status', status_report: item.monthly_status_finance},
{report_name: 'Report CAT Status', status_report: item.monthly_status_cat}
)
dataTable.push([ dataTable.push([
item.company_name, item.company_name,
report, report,
...@@ -277,7 +284,11 @@ class ReportProgress extends Component { ...@@ -277,7 +284,11 @@ class ReportProgress extends Component {
let data = response.data.data let data = response.data.data
data.map((item,index) => { data.map((item,index) => {
let report = item.report let report = item.report
report.push({report_name: 'Operating Indicator', status_report: item.operating_indicator}, {report_name: 'Rolling Status', status_report: item.rolling_status}) report.push(
{report_name: 'Operating Indicator', status_report: item.operating_indicator},
{report_name: 'Report Finance Status', status_report: item.rolling_status_finance},
{report_name: 'Report CAT Status', status_report: item.rolling_status_cat}
)
dataTable.push([ dataTable.push([
item.company_name, item.company_name,
report, report,
...@@ -315,7 +326,8 @@ class ReportProgress extends Component { ...@@ -315,7 +326,8 @@ class ReportProgress extends Component {
let data = response.data.data let data = response.data.data
data.map((item,index) => { data.map((item,index) => {
let report = [] let report = []
let statusSubmission = String(item.outlook_status).toLocaleUpperCase() let statusSubmissionFinance = String(item.outlook_status_finance).toLocaleUpperCase()
let statusSubmissionCAT = String(item.outlook_status_cat).toLocaleUpperCase()
let statusOI = String(item.operating_indicator).toLocaleUpperCase() let statusOI = String(item.operating_indicator).toLocaleUpperCase()
item.report.map((items,index) => { item.report.map((items,index) => {
let statusReport = String(items.status_report).toLocaleUpperCase() let statusReport = String(items.status_report).toLocaleUpperCase()
...@@ -323,7 +335,9 @@ class ReportProgress extends Component { ...@@ -323,7 +335,9 @@ class ReportProgress extends Component {
}) })
report.push( report.push(
{report_name: 'Operating Indicator', status_report: statusOI}, {report_name: 'Operating Indicator', status_report: statusOI},
{report_name: 'OLPA Status', status_report: (statusSubmission == 'APPROVED' || statusSubmission == 'REVISION' || statusSubmission == 'COMPLETED') ? (statusSubmission + ' - ' + item.submissionStatusDate) : statusSubmission}) {report_name: 'Report Finance Status', status_report: (statusSubmissionFinance == 'APPROVED' || statusSubmissionFinance == 'REVISION' || statusSubmissionFinance == 'COMPLETED') ? (statusSubmissionFinance + ' - ' + item.submissionStatusDate) : statusSubmissionFinance},
{report_name: 'Report CAT Status', status_report: (statusSubmissionCAT == 'APPROVED' || statusSubmissionCAT == 'REVISION' || statusSubmissionCAT == 'COMPLETED') ? (statusSubmissionCAT + ' - ' + item.submissionStatusDate) : statusSubmissionCAT}
)
dataTable.push([ dataTable.push([
item.company_name, item.company_name,
report, report,
......
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -27,21 +27,29 @@ const AutocompleteField = ({ ...@@ -27,21 +27,29 @@ const AutocompleteField = ({
multiple = false, multiple = false,
showCheckbox = false, showCheckbox = false,
isLoading = false, isLoading = false,
minSizeBox = false,
...props ...props
}) => { }) => {
const defaultRenderInput = (params) => ( const defaultRenderInput = (params) => (
<TextField <TextField
{...params} {...params}
label={label} label={label}
margin={margin} margin={minSizeBox ? 'none' : margin}
style={{ marginTop: 7 }} style={minSizeBox ? {} : { marginTop: 7 }}
disabled={disabled} disabled={disabled}
required={required} required={required}
error={error} error={error}
helperText={helperText} helperText={helperText}
fullWidth fullWidth
InputLabelProps={minSizeBox ? {
style: {
fontSize: 11,
color: '#7e8085'
}
} : {}}
InputProps={{ InputProps={{
...params.InputProps, ...params.InputProps,
style: minSizeBox ? { fontSize: 11 } : {},
endAdornment: ( endAdornment: (
<> <>
{isLoading ? ( {isLoading ? (
......
...@@ -72,4 +72,12 @@ export const createMonthData = (item, startIdx, formatFn) => { ...@@ -72,4 +72,12 @@ export const createMonthData = (item, startIdx, formatFn) => {
months[month] = formatFn(item[startIdx + idx]); months[month] = formatFn(item[startIdx + idx]);
}); });
return months; return months;
};
export const convertSelect = (id, name) => {
const obj = id ? {
id,
name,
} : null
return obj
}; };
\ No newline at end of file
...@@ -68,4 +68,5 @@ export const fetchPLID = (payload) => wrapService(api.create().getPLID(payload)) ...@@ -68,4 +68,5 @@ export const fetchPLID = (payload) => wrapService(api.create().getPLID(payload))
export const fetchHierarkiCreateReportPLMB = (payload) => wrapService(api.create().getHierarkiCreateReportPLMB(payload)); export const fetchHierarkiCreateReportPLMB = (payload) => wrapService(api.create().getHierarkiCreateReportPLMB(payload));
export const fetchFRID = (payload) => wrapService(api.create().getFRID(payload)); export const fetchFRID = (payload) => wrapService(api.create().getFRID(payload));
export const fetchDownloadFile = (payload) => wrapService(api.create().createDownloadFile(payload)); export const fetchDownloadFile = (payload) => wrapService(api.create().createDownloadFile(payload));
export const fetchZipReport = (downloadedFileReportId) => wrapService(api.create().createZipReport(downloadedFileReportId)); export const fetchZipReport = (downloadedFileReportId) => wrapService(api.create().createZipReport(downloadedFileReportId));
\ No newline at end of file export const fetchMasterReportType = () => wrapService(api.create().getMasterReportType());
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment