diff --git a/Data/JSRelationshipData/entry/src/main/config.json b/Data/JSRelationshipData/entry/src/main/config.json index 5cc865c30bb685815bca05676c9f4bfdc91bb4e8..5932ff203782e8864212b2292fdee80505f3c444 100644 --- a/Data/JSRelationshipData/entry/src/main/config.json +++ b/Data/JSRelationshipData/entry/src/main/config.json @@ -13,7 +13,7 @@ "name": ".MyApplication", "mainAbility": ".MainAbility", "deviceType": [ - "phone" + "default" ], "distro": { "deliveryWithInstall": true, diff --git a/Data/JSRelationshipData/entry/src/main/js/model/KvStoreModel.js b/Data/JSRelationshipData/entry/src/main/js/model/KvStoreModel.js index 433fdf756e587e0ef78491bba2b78b7f0335d4d4..1d00e776acf8a750ed6d0973ee1f73a6c7951feb 100644 --- a/Data/JSRelationshipData/entry/src/main/js/model/KvStoreModel.js +++ b/Data/JSRelationshipData/entry/src/main/js/model/KvStoreModel.js @@ -13,8 +13,8 @@ * limitations under the License. */ -import ohos_data_ability from '@ohos.data.dataability' -import ohos_data_rdb from '@ohos.data.rdb' +import dataAbility from '@ohos.data.dataAbility'; +import ohos_data_rdb from '@ohos.data.rdb'; const STORE_CONFIG = { name: "RdbTest.db" } const SQL_CREATE_TABLE = "CREATE TABLE IF NOT EXISTS EMPLOYEE (ID INTEGER PRIMARY KEY AUTOINCREMENT, NAME TEXT NOT NULL, AGE INTEGER, GENDER TEXT NOT NULL)" @@ -25,7 +25,7 @@ export default class KvStoreModel { createKvStore(callback) { if (typeof (this.rdbStore) === 'undefined') { let self = this; - let promise = ohos_data_rdb.getRdbStore(STORE_CONFIG, 1) + let promise = dataAbility.getRdbStore(STORE_CONFIG, 1) promise.then(async (rdbStore) => { self.rdbStore = rdbStore; await rdbStore.executeSql(SQL_CREATE_TABLE, null); diff --git a/Data/JSRelationshipData/package.json b/Data/JSRelationshipData/package.json index b43b7ab1e02f5e0683a583f80ad9b0336fb395ca..6491d51bf4d876934a351388655697d05ee38c07 100644 --- a/Data/JSRelationshipData/package.json +++ b/Data/JSRelationshipData/package.json @@ -11,7 +11,7 @@ "license": "ISC", "dependencies": { "hypium": "^1.0.0", - "@ohos/hvigor": "1.0.6", - "@ohos/hvigor-ohos-plugin": "1.0.6" + "@ohos/hvigor": "1.3.1", + "@ohos/hvigor-ohos-plugin": "1.3.1","@ohos/hypium": "1.0.3" } -} +} \ No newline at end of file diff --git a/Data/JsDistributedData/entry/src/main/config.json b/Data/JsDistributedData/entry/src/main/config.json index 32992ec53c36b1e98e8b671601c71a694d35e1d7..8b8ff9de25e2ce0bd703dd45d64493d01a5ddf9f 100644 --- a/Data/JsDistributedData/entry/src/main/config.json +++ b/Data/JsDistributedData/entry/src/main/config.json @@ -11,7 +11,7 @@ "module": { "mainAbility": ".MainAbility", "deviceType": [ - "phone" + "default" ], "abilities": [ { diff --git a/Data/JsDistributedData/entry/src/main/js/model/KvStoreModel.js b/Data/JsDistributedData/entry/src/main/js/model/KvStoreModel.js index 8f50a12759ab83dd82a12cc96a38512ab036e3dd..299f92d0809ea8ed5f69fc94d745f4926eabcec5 100644 --- a/Data/JsDistributedData/entry/src/main/js/model/KvStoreModel.js +++ b/Data/JsDistributedData/entry/src/main/js/model/KvStoreModel.js @@ -14,7 +14,7 @@ * limitations under the License. */ -import distributedData from '@ohos.data.distributeddata'; +import distributedData from '@ohos.data.distributedData'; const STORE_ID = 'musicplayer_kvstore'; diff --git a/Data/JsDistributedData/package.json b/Data/JsDistributedData/package.json index b43b7ab1e02f5e0683a583f80ad9b0336fb395ca..acf99f1eaa89917f4e4b7e9ff34ce54c39dc26e9 100644 --- a/Data/JsDistributedData/package.json +++ b/Data/JsDistributedData/package.json @@ -11,7 +11,8 @@ "license": "ISC", "dependencies": { "hypium": "^1.0.0", - "@ohos/hvigor": "1.0.6", - "@ohos/hvigor-ohos-plugin": "1.0.6" + "@ohos/hvigor": "1.3.1", + "@ohos/hvigor-ohos-plugin": "1.3.1", + "@ohos/hypium": "1.0.3" } }