Skip to content

Commit

Permalink
Lint
Browse files Browse the repository at this point in the history
  • Loading branch information
adrinr committed Oct 10, 2023
1 parent 29e7501 commit a085589
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions packages/server/src/db/defaultData/datasource_bb_default.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,12 @@ import { employeeImport } from "./employeeImport"
import { jobsImport } from "./jobsImport"
import { expensesImport } from "./expensesImport"
import { db as dbCore } from "@budibase/backend-core"
import { Table, Row, RelationshipType } from "@budibase/types"
import {
Table,
Row,
RelationshipType,
AutoColumnFieldMetadata,
} from "@budibase/types"

export const DEFAULT_JOBS_TABLE_ID = "ta_bb_jobs"
export const DEFAULT_INVENTORY_TABLE_ID = "ta_bb_inventory"
Expand All @@ -27,9 +32,9 @@ export const DEFAULT_BB_DATASOURCE = defaultDatasource

function syncLastIds(table: Table, rowCount: number) {
Object.keys(table.schema).forEach(key => {
const entry = table.schema[key]
const entry = table.schema[key] as AutoColumnFieldMetadata
if (entry.autocolumn && entry.subtype == "autoID") {
;(entry as any).lastID = rowCount
entry.lastID = rowCount
}
})
}
Expand Down

0 comments on commit a085589

Please sign in to comment.