Fix manual rss
This commit is contained in:
parent
36ca216e80
commit
2a00a88a3e
@ -13,9 +13,6 @@
|
|||||||
<script>
|
<script>
|
||||||
import { NcAppNavigationNewItem } from '@nextcloud/vue'
|
import { NcAppNavigationNewItem } from '@nextcloud/vue'
|
||||||
import Plus from 'vue-material-design-icons/Plus.vue'
|
import Plus from 'vue-material-design-icons/Plus.vue'
|
||||||
import axios from '@nextcloud/axios'
|
|
||||||
import { generateUrl } from '@nextcloud/router'
|
|
||||||
import { showError } from '@nextcloud/dialogs'
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'AddRss',
|
name: 'AddRss',
|
||||||
@ -30,17 +27,8 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
async addSubscription(feedUrl) {
|
addSubscription(feedUrl) {
|
||||||
try {
|
this.$router.push(btoa(feedUrl))
|
||||||
this.loading = true
|
|
||||||
await axios.post(generateUrl('/apps/gpoddersync/subscription_change/create'), { add: [feedUrl], remove: [] })
|
|
||||||
} catch (e) {
|
|
||||||
console.error(e)
|
|
||||||
showError(t('Error while adding the feed'))
|
|
||||||
} finally {
|
|
||||||
this.loading = false
|
|
||||||
this.$store.dispatch('subscriptions/fetch')
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<ul>
|
<ul>
|
||||||
<NcListItem v-for="feed in feeds"
|
<NcListItem v-for="feed in feeds"
|
||||||
:key="`${feed.link}`"
|
:key="feed.link"
|
||||||
:details="formatTimeAgo(new Date(feed.fetchedAtUnix*1000))"
|
:details="formatTimeAgo(new Date(feed.fetchedAtUnix*1000))"
|
||||||
:name="feed.title"
|
:name="feed.title"
|
||||||
:to="toUrl(feed.link)">
|
:to="toUrl(feed.link)">
|
||||||
|
Loading…
Reference in New Issue
Block a user