未验证 提交 a235c8e9 编写于 作者: O openharmony_ci 提交者: Gitee

!7331 兼容API9接口修改

Merge pull request !7331 from wangchensu/0130
...@@ -19,9 +19,9 @@ import plugin from "../common/plugin_component.js" ...@@ -19,9 +19,9 @@ import plugin from "../common/plugin_component.js"
@Component @Component
struct PluginUserExample { struct PluginUserExample {
@StorageLink("plugincount") plugincount: Object[] = [ @StorageLink("plugincount") plugincount: Object[] = [
{ source: 'plugincomponent1', ability: 'com.example.plugin' }, { source: 'plugincomponent1', bundleName: 'com.example.plugin' },
{ source: 'plugintemplate', ability: 'com.example.myapplication' }, { source: 'plugintemplate', bundleName: 'com.example.myapplication' },
{ source: 'plugintemplate', ability: 'com.example.myapplication' }] { source: 'plugintemplate', bundleName: 'com.example.myapplication' }]
build() { build() {
Flex({ direction: FlexDirection.Column, alignItems: ItemAlign.Center, justifyContent: FlexAlign.Center }) { Flex({ direction: FlexDirection.Column, alignItems: ItemAlign.Center, justifyContent: FlexAlign.Center }) {
...@@ -48,7 +48,7 @@ struct PluginUserExample { ...@@ -48,7 +48,7 @@ struct PluginUserExample {
}) })
ForEach(this.plugincount, item => { ForEach(this.plugincount, item => {
PluginComponent({ PluginComponent({
template: { source: 'plugincomponent1', ability: 'com.example.plugin' }, template: { source: 'plugincomponent1', bundleName: 'com.example.plugin' },
data: { 'countDownStartValue': 'new countDownStartValue' } data: { 'countDownStartValue': 'new countDownStartValue' }
}).size({ width: 500, height: 100 }) }).size({ width: 500, height: 100 })
.onComplete(() => { .onComplete(() => {
......
...@@ -19,9 +19,9 @@ import plugin from "../common/plugin_component.js" ...@@ -19,9 +19,9 @@ import plugin from "../common/plugin_component.js"
@Component @Component
struct PluginUserExample { struct PluginUserExample {
@StorageLink("plugincount") plugincount: Object[] = [ @StorageLink("plugincount") plugincount: Object[] = [
{ source: 'plugincomponent1', ability: 'com.example.plugin' }, { source: 'plugincomponent1', bundleName: 'com.example.plugin' },
{ source: 'plugintemplate', ability: 'com.example.myapplication' }, { source: 'plugintemplate', bundleName: 'com.example.myapplication' },
{ source: 'plugintemplate', ability: 'com.example.myapplication' }] { source: 'plugintemplate', bundleName: 'com.example.myapplication' }]
build() { build() {
Flex({ direction: FlexDirection.Column, alignItems: ItemAlign.Center, justifyContent: FlexAlign.Center }) { Flex({ direction: FlexDirection.Column, alignItems: ItemAlign.Center, justifyContent: FlexAlign.Center }) {
...@@ -48,7 +48,7 @@ struct PluginUserExample { ...@@ -48,7 +48,7 @@ struct PluginUserExample {
}) })
ForEach(this.plugincount, item => { ForEach(this.plugincount, item => {
PluginComponent({ PluginComponent({
template: { source: 'plugincomponent1', ability: 'com.example.plugin' }, template: { source: 'plugincomponent1', bundleName: 'com.example.plugin' },
data: { 'countDownStartValue': 'new countDownStartValue' } data: { 'countDownStartValue': 'new countDownStartValue' }
}).size({ width: 500, height: 100 }) }).size({ width: 500, height: 100 })
.onComplete(() => { .onComplete(() => {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册