diff --git a/entry/src/main/ets/common/service/indexService.ts b/entry/src/main/ets/common/service/indexService.ts index 4abacc93..f885899b 100644 --- a/entry/src/main/ets/common/service/indexService.ts +++ b/entry/src/main/ets/common/service/indexService.ts @@ -323,6 +323,7 @@ export async function getSingleCenterTable(param) { console.log('teststet0') upDataZhongxinginitialization(param).then((result) => { if (result === true) { + getChuankouFn() resolve(true) } else { console.log('联网更新失败,请检查网络后重新更新') diff --git a/entry/src/main/ets/common/service/initable.ts b/entry/src/main/ets/common/service/initable.ts index 71f79109..def04b15 100644 --- a/entry/src/main/ets/common/service/initable.ts +++ b/entry/src/main/ets/common/service/initable.ts @@ -32,7 +32,6 @@ import { GlobalConfig } from '../../config/index'; import prompt from '@ohos.promptAction' import DB, { ColumnType } from '../database/DbSql'; import { MA_SYS_SET_COLUMN } from '../../model/Table'; -import { getChuankouFn } from './indexService' // @ts-nocheck //读表 @@ -456,10 +455,6 @@ export async function upDataZhongxinginitialization(param) { resolve(false) } } - // 初始化串口 - if(!globalThis.ChounkouInit){ - getChuankouFn() - } resolve(true) }).catch((Error) => { console.log("init table5", JSON.stringify(Error))