✌️
This commit is contained in:
parent
48341db13d
commit
482c86a25a
5 changed files with 67 additions and 4 deletions
|
|
@ -34,19 +34,20 @@ export default function<T extends object>(data: {
|
|||
}
|
||||
|
||||
this.$watch('props', newProps => {
|
||||
const w = (this as any).os.i.client_settings.mobile_home.find(w => w.id == this.id);
|
||||
if (this.isMobile) {
|
||||
(this as any).api('i/update_mobile_home', {
|
||||
id: this.id,
|
||||
data: newProps
|
||||
}).then(() => {
|
||||
(this as any).os.i.client_settings.mobile_home.find(w => w.id == this.id).data = newProps;
|
||||
w.data = newProps;
|
||||
});
|
||||
} else {
|
||||
(this as any).api('i/update_home', {
|
||||
id: this.id,
|
||||
data: newProps
|
||||
}).then(() => {
|
||||
(this as any).os.i.client_settings.home.find(w => w.id == this.id).data = newProps;
|
||||
w.data = newProps;
|
||||
});
|
||||
}
|
||||
}, {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue