mirror of
https://github.com/lrnselfreliance/wrolpi.git
synced 2026-11-26 09:56:17 -05:00
Creating missing ChannelDownload when importing channels config.
This commit is contained in:
parent
7a784d7c45
commit
287beabb9c
10 changed files with 135 additions and 32 deletions
|
|
@ -47,7 +47,7 @@ import {Media, ThemeContext} from "../contexts/contexts";
|
|||
import {SortableTable} from "./SortableTable";
|
||||
import {toast} from "react-semantic-toasts-2";
|
||||
import {RecurringDownloadsTable} from "./admin/Downloads";
|
||||
import {TagsSelector, useTags} from "../Tags";
|
||||
import {TagsSelector} from "../Tags";
|
||||
|
||||
|
||||
function ChannelStatistics({statistics}) {
|
||||
|
|
@ -416,10 +416,10 @@ export function ChannelDownloadForm({channel_id, afterSave, closeModal, download
|
|||
const settings = download.settings ? download.settings : {};
|
||||
const oldTagNames = download && download.settings && download.settings.tag_names ? download.settings.tag_names : [];
|
||||
const [state, setState] = React.useState({
|
||||
url: download ? download.url : '',
|
||||
frequency: download.frequency ? download.frequency : 604800,
|
||||
title_match: settings.title_match ? settings.title_match : '',
|
||||
title_exclude: settings.title_exclude ? settings.title_exclude : '',
|
||||
title_match: settings.title_match ? settings.title_match : '',
|
||||
url: download ? download.url : '',
|
||||
})
|
||||
const [disabled, setDisabled] = React.useState(useWROLMode());
|
||||
const [loading, setLoading] = React.useState(false);
|
||||
|
|
|
|||
|
|
@ -117,6 +117,7 @@ export function DownloadEditForm({afterSave, closeModal, download}) {
|
|||
url: download.url || '',
|
||||
frequency: download.frequency,
|
||||
excluded_urls: download.settings ? download.settings.excluded_urls : '',
|
||||
destination: download.settings ? download.settings.destination : '',
|
||||
})
|
||||
const [disabled, setDisabled] = React.useState(useWROLMode());
|
||||
const [loading, setLoading] = React.useState(false);
|
||||
|
|
@ -220,6 +221,15 @@ export function DownloadEditForm({afterSave, closeModal, download}) {
|
|||
onChange={handleInputChange}
|
||||
/>
|
||||
</Grid.Column>
|
||||
<Grid.Column>
|
||||
<FormInput
|
||||
label='Destination'
|
||||
name='destination'
|
||||
type='text'
|
||||
value={state.destination}
|
||||
onChange={handleInputChange}
|
||||
/>
|
||||
</Grid.Column>
|
||||
</Grid.Row>
|
||||
<Grid.Row columns={1}>
|
||||
<Grid.Column textAlign='right'>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue