Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion src/views/import/Dataset.vue
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@
<b-table-column
v-slot="props"
field="data.obsUnitId"
label="ObsUnitID"
v-bind:label="obsUnitIDLabel"
sortable
searchable
:th-attrs="() => ({scope:'col'})"
Expand Down Expand Up @@ -306,6 +306,7 @@ export default class Dataset extends ProgramsBase {
private paginationController: PaginationController = new PaginationController();
private datasetTableRows: DatasetTableRow[] = [];
private unitDbIdToTraitValues: any = {};
private obsUnitIDLabel :string = "ObsUnitID";

mounted() {
this.load();
Expand Down Expand Up @@ -552,6 +553,10 @@ export default class Dataset extends ProgramsBase {
}
}

setObsUnitIDLabel(){
this.obsUnitIDLabel = this.observationUnit + " ObsUnitID"
}

@Watch('$route')
async load() {
try {
Expand Down Expand Up @@ -581,6 +586,9 @@ export default class Dataset extends ProgramsBase {
// Use this.datasetModel to initialize this.datasetTableRows
this.createDatasetTableRows();

// Set the obsUnitId label to include observation level
this.setObsUnitIDLabel();

//Initialize the paginationController
this.paginationController.totalCount = this.datasetModel.observationUnits.length;
this.paginationController.currentPage = 1;
Expand Down
2 changes: 1 addition & 1 deletion task/serve.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ const port = process.env.PORT || JSON.parse(fs.readFileSync('package.json', 'utf
let spinner = ora({prefixText: ' ', color: 'yellow'});
try {
spinner = spinner.start('sort package.json');
await execa('npx', ['sort-package-json'], {preferLocal: true});
await execa('npx', ['sort-package-json@3.0.0'], {preferLocal: true});
spinner = spinner.clear()
.succeed('package.json sorted');

Expand Down