37 lines
985 B
JavaScript
37 lines
985 B
JavaScript
export default OakComponent({
|
|
isList: false,
|
|
properties: {
|
|
applicationId: '',
|
|
isPlatform: false,
|
|
tabKey: '',
|
|
},
|
|
lifetimes: {
|
|
async ready() {
|
|
const { applicationId } = this.props;
|
|
const { data: wechatMenu } = await this.features.cache.refresh('wechatMenu', {
|
|
data: {
|
|
id: 1,
|
|
applicationId: 1,
|
|
wechatPublicTagId: 1,
|
|
},
|
|
filter: {
|
|
applicationId,
|
|
wechatPublicTagId: {
|
|
$exists: false
|
|
}
|
|
}
|
|
});
|
|
if (wechatMenu && wechatMenu[0]) {
|
|
this.setState({
|
|
menuId: wechatMenu[0].id,
|
|
});
|
|
}
|
|
this.setState({
|
|
is_menu_open: true,
|
|
applicationId,
|
|
});
|
|
}
|
|
},
|
|
methods: {},
|
|
});
|