|
|
|
@ -487,6 +487,31 @@ function updateShowHideColumn(data)
|
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
function colAjaxReq(type) { |
|
|
|
|
let ajx = $.ajax({ |
|
|
|
|
url: `${base_url}gantt-show-hide/get-column-by-type/${type}`, |
|
|
|
|
type: "GET", |
|
|
|
|
success: function (data) { |
|
|
|
|
let ganttColumnsByType = data.data; |
|
|
|
|
let isFound = false; |
|
|
|
|
x = gantt.config.columns.filter((val) => { |
|
|
|
|
isFound = ganttColumnsByType.find(obj => { |
|
|
|
|
return obj.column_name == val.name; |
|
|
|
|
}); |
|
|
|
|
if(isFound) |
|
|
|
|
return val; |
|
|
|
|
}); |
|
|
|
|
gantt.config.columns = x.filter(item => item); |
|
|
|
|
allColumns = gantt.config.columns; |
|
|
|
|
gantt.render(); |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
async function reRenderColumns(type){ |
|
|
|
|
await colAjaxReq(type); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
function updateProperty(payload){ |
|
|
|
|
if(userToVersionGanttId > 0 && readOnly && parseInt(readOnly)==0){ |
|
|
|
|
$.ajax({ |
|
|
|
|