Refactor & Clean up
This commit is contained in:
parent
ba845f5218
commit
60ef3e3563
154 changed files with 438 additions and 481 deletions
|
|
@ -24,12 +24,12 @@ export default define({
|
|||
i18n: i18n('desktop/views/widgets/messaging.vue'),
|
||||
methods: {
|
||||
navigate(user) {
|
||||
(this as any).os.new(MkMessagingRoomWindow, {
|
||||
this.$root.new(MkMessagingRoomWindow, {
|
||||
user: user
|
||||
});
|
||||
},
|
||||
add() {
|
||||
(this as any).os.new(MkMessagingWindow);
|
||||
this.$root.new(MkMessagingWindow);
|
||||
},
|
||||
func() {
|
||||
if (this.props.design == 1) {
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ export default define({
|
|||
this.fetching = true;
|
||||
this.poll = null;
|
||||
|
||||
(this as any).api('notes/polls/recommendation', {
|
||||
this.$root.api('notes/polls/recommendation', {
|
||||
limit: 1,
|
||||
offset: this.offset
|
||||
}).then(notes => {
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@ export default define({
|
|||
post() {
|
||||
this.posting = true;
|
||||
|
||||
(this as any).api('notes/create', {
|
||||
this.$root.api('notes/create', {
|
||||
text: this.text
|
||||
}).then(data => {
|
||||
this.clear();
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ export default define({
|
|||
this.fetching = true;
|
||||
this.note = null;
|
||||
|
||||
(this as any).api('notes/trend', {
|
||||
this.$root.api('notes/trend', {
|
||||
limit: 1,
|
||||
offset: this.offset,
|
||||
renote: false,
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@ export default define({
|
|||
this.fetching = true;
|
||||
this.users = [];
|
||||
|
||||
(this as any).api('users/recommendation', {
|
||||
this.$root.api('users/recommendation', {
|
||||
limit: limit,
|
||||
offset: limit * this.page
|
||||
}).then(users => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue