Skip to content

Commit

Permalink
Dk api test (#820)
Browse files Browse the repository at this point in the history
* temp save

* temp save

* temp save

* tabs with multiple datatables implemented

* multi tab data tables completed

* Subsection type "api" added.

* field_page_mode issue resolved.

* BYOR a new option "sub to top" is added to "data convert" option

* Data convert "split" updated

* BYOR "data convert" option "from parameter" added.

* json lines option in BYOR sections component updated
  • Loading branch information
dkjang authored Dec 17, 2024
1 parent 393d5b4 commit 81f182e
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 32 deletions.
1 change: 1 addition & 0 deletions src/components/researchPortal/ResearchHeatmap.vue
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
:sectionId="sectionId"
:utils="utils"
:ref="sectionId + '_heatmap'"
@mousemove="checkPosition($event)"
>
</research-heatmap-vector>
</div>
Expand Down
50 changes: 18 additions & 32 deletions src/components/researchPortal/ResearchSection.vue
Original file line number Diff line number Diff line change
Expand Up @@ -1499,9 +1499,8 @@ export default Vue.component("research-section", {
} else if (!!dataWrappers){
let tempData = []
let headers = [];
let tempData = {}
let headers = {};
dataWrappers.map(dataWrapper => {
Expand All @@ -1511,54 +1510,41 @@ export default Vue.component("research-section", {
dataEntity = dataEntity[w];
})
headers = headers.concat(dataEntity);
//headers = headers.concat(dataEntity);
headers[dataWrapper["stamp"]] = dataEntity;
//headers[dataWrapper["stamp"]].push("stamp");
})
let uniqHeaders = [...new Set(headers)];
uniqHeaders.push("stamp")
dataWrappers.map(dataWrapper => {
let dataEntity = CONTENT;
dataWrapper["headers"].map(w => {
dataEntity = dataEntity[w];
})
let tempHeaders = dataEntity;
dataEntity = CONTENT;
dataWrapper["data"].map(w => {
dataEntity = dataEntity[w];
})
tempData[dataWrapper["stamp"]] = dataEntity;
})
dataEntity.map((item,itemIndex) => {
let tempObj = {}
let mergedData = []
item.map((column, columnIndex) => {
tempObj[headers[columnIndex]] = column;
})
dataWrappers.map(dataWrapper => {
tempObj["stamp"] = dataWrapper["stamp"];
let stamp = dataWrapper["stamp"];
tempData.push(tempObj);
})
tempData[stamp].map(item => {
let tempObj = {};
})
headers[stamp].map((header, hIndex) => {
let mergedData = [];
tempObj[header] = item[hIndex];
})
tempData.map(d => {
let tempObj = {}
uniqHeaders.map(header => {
tempObj[header] = (!!d[header])? d[header]:"";
tempObj["stamp"] = stamp;
mergedData.push(tempObj)
})
mergedData.push(tempObj);
})
data = mergedData;
Expand Down

0 comments on commit 81f182e

Please sign in to comment.