This commit is contained in:
こぴなたみぽ
2018-02-15 17:24:52 +09:00
parent 0766a76348
commit 9fd00d1179
51 changed files with 93 additions and 93 deletions

View File

@@ -31,7 +31,7 @@
this.user = this.opts.user;
this.on('mount', () => {
this.api('aggregation/users/activity', {
this.$root.$data.os.api('aggregation/users/activity', {
user_id: this.user.id
}).then(data => {
data.forEach(d => d.total = d.posts + d.replies + d.reposts);

View File

@@ -25,7 +25,7 @@
this.fetching = true;
this.on('mount', () => {
this.api('i/authorized_apps').then(apps => {
this.$root.$data.os.api('i/authorized_apps').then(apps => {
this.apps = apps;
this.fetching = false;
this.update();

View File

@@ -19,7 +19,7 @@
this.fetching = true;
this.on('mount', () => {
this.api('i/signin_history').then(history => {
this.$root.$data.os.api('i/signin_history').then(history => {
this.update({
fetching: false,
history: history

View File

@@ -30,15 +30,15 @@
this.form = null;
this.on('mount', () => {
this.I.on('updated', this.onMeUpdated);
this.$root.$data.os.i.on('updated', this.onMeUpdated);
});
this.on('unmount', () => {
this.I.off('updated', this.onMeUpdated);
this.$root.$data.os.i.off('updated', this.onMeUpdated);
});
this.onMeUpdated = () => {
if (this.I.twitter) {
if (this.$root.$data.os.i.twitter) {
if (this.form) this.form.close();
}
};

View File

@@ -47,7 +47,7 @@
},
vote(id) {
if (this.poll.choices.some(c => c.is_voted)) return;
this.api('posts/polls/vote', {
this.$root.$data.os.api('posts/polls/vote', {
post_id: this.post.id,
choice: id
}).then(() => {