mirror of
https://github.com/Radarr/Radarr.git
synced 2024-10-05 15:47:20 +02:00
New: Default name when adding providers
This commit is contained in:
parent
dd614ac005
commit
8c93123126
@ -47,7 +47,7 @@ function NoDiscoverMovie(props) {
|
|||||||
to="/settings/importlists"
|
to="/settings/importlists"
|
||||||
kind={kinds.PRIMARY}
|
kind={kinds.PRIMARY}
|
||||||
>
|
>
|
||||||
{translate('AddList')}
|
{translate('AddImportList')}
|
||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -41,7 +41,7 @@ function EditSpecificationModalContent(props) {
|
|||||||
return (
|
return (
|
||||||
<ModalContent onModalClose={onCancelPress}>
|
<ModalContent onModalClose={onCancelPress}>
|
||||||
<ModalHeader>
|
<ModalHeader>
|
||||||
{`${id ? 'Edit' : 'Add'} Condition - ${implementationName}`}
|
{id ? translate('EditConditionImplementation', { implementationName }) : translate('AddConditionImplementation', { implementationName })}
|
||||||
</ModalHeader>
|
</ModalHeader>
|
||||||
|
|
||||||
<ModalBody>
|
<ModalBody>
|
||||||
|
@ -58,7 +58,7 @@ class EditDownloadClientModalContent extends Component {
|
|||||||
return (
|
return (
|
||||||
<ModalContent onModalClose={onModalClose}>
|
<ModalContent onModalClose={onModalClose}>
|
||||||
<ModalHeader>
|
<ModalHeader>
|
||||||
{`${id ? translate('Edit') : translate('Add')} ${translate('DownloadClient')} - ${implementationName}`}
|
{id ? translate('EditDownloadClientImplementation', { implementationName }) : translate('AddDownloadClientImplementation', { implementationName })}
|
||||||
</ModalHeader>
|
</ModalHeader>
|
||||||
|
|
||||||
<ModalBody>
|
<ModalBody>
|
||||||
|
@ -16,10 +16,12 @@ class AddImportListItem extends Component {
|
|||||||
|
|
||||||
onImportListSelect = () => {
|
onImportListSelect = () => {
|
||||||
const {
|
const {
|
||||||
implementation
|
implementation,
|
||||||
|
implementationName,
|
||||||
|
minRefreshInterval
|
||||||
} = this.props;
|
} = this.props;
|
||||||
|
|
||||||
this.props.onImportListSelect({ implementation });
|
this.props.onImportListSelect({ implementation, implementationName, minRefreshInterval });
|
||||||
};
|
};
|
||||||
|
|
||||||
//
|
//
|
||||||
@ -29,6 +31,7 @@ class AddImportListItem extends Component {
|
|||||||
const {
|
const {
|
||||||
implementation,
|
implementation,
|
||||||
implementationName,
|
implementationName,
|
||||||
|
minRefreshInterval,
|
||||||
infoLink,
|
infoLink,
|
||||||
presets,
|
presets,
|
||||||
onImportListSelect
|
onImportListSelect
|
||||||
@ -77,6 +80,8 @@ class AddImportListItem extends Component {
|
|||||||
key={preset.name}
|
key={preset.name}
|
||||||
name={preset.name}
|
name={preset.name}
|
||||||
implementation={implementation}
|
implementation={implementation}
|
||||||
|
implementationName={implementationName}
|
||||||
|
minRefreshInterval={minRefreshInterval}
|
||||||
onPress={onImportListSelect}
|
onPress={onImportListSelect}
|
||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
@ -103,6 +108,7 @@ class AddImportListItem extends Component {
|
|||||||
AddImportListItem.propTypes = {
|
AddImportListItem.propTypes = {
|
||||||
implementation: PropTypes.string.isRequired,
|
implementation: PropTypes.string.isRequired,
|
||||||
implementationName: PropTypes.string.isRequired,
|
implementationName: PropTypes.string.isRequired,
|
||||||
|
minRefreshInterval: PropTypes.string.isRequired,
|
||||||
infoLink: PropTypes.string.isRequired,
|
infoLink: PropTypes.string.isRequired,
|
||||||
presets: PropTypes.arrayOf(PropTypes.object),
|
presets: PropTypes.arrayOf(PropTypes.object),
|
||||||
onImportListSelect: PropTypes.func.isRequired
|
onImportListSelect: PropTypes.func.isRequired
|
||||||
|
@ -32,7 +32,7 @@ class AddImportListModalContent extends Component {
|
|||||||
return (
|
return (
|
||||||
<ModalContent onModalClose={onModalClose}>
|
<ModalContent onModalClose={onModalClose}>
|
||||||
<ModalHeader>
|
<ModalHeader>
|
||||||
{translate('AddList')}
|
{translate('AddImportList')}
|
||||||
</ModalHeader>
|
</ModalHeader>
|
||||||
|
|
||||||
<ModalBody>
|
<ModalBody>
|
||||||
|
@ -49,8 +49,8 @@ class AddImportListModalContentConnector extends Component {
|
|||||||
//
|
//
|
||||||
// Listeners
|
// Listeners
|
||||||
|
|
||||||
onImportListSelect = ({ implementation, name }) => {
|
onImportListSelect = ({ implementation, implementationName, name, minRefreshInterval }) => {
|
||||||
this.props.selectImportListSchema({ implementation, presetName: name });
|
this.props.selectImportListSchema({ implementation, implementationName, presetName: name, minRefreshInterval });
|
||||||
this.props.onModalClose({ importListSelected: true });
|
this.props.onModalClose({ importListSelected: true });
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -10,12 +10,16 @@ class AddImportListPresetMenuItem extends Component {
|
|||||||
onPress = () => {
|
onPress = () => {
|
||||||
const {
|
const {
|
||||||
name,
|
name,
|
||||||
implementation
|
implementation,
|
||||||
|
implementationName,
|
||||||
|
minRefreshInterval
|
||||||
} = this.props;
|
} = this.props;
|
||||||
|
|
||||||
this.props.onPress({
|
this.props.onPress({
|
||||||
name,
|
name,
|
||||||
implementation
|
implementation,
|
||||||
|
implementationName,
|
||||||
|
minRefreshInterval
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -26,6 +30,8 @@ class AddImportListPresetMenuItem extends Component {
|
|||||||
const {
|
const {
|
||||||
name,
|
name,
|
||||||
implementation,
|
implementation,
|
||||||
|
implementationName,
|
||||||
|
minRefreshInterval,
|
||||||
...otherProps
|
...otherProps
|
||||||
} = this.props;
|
} = this.props;
|
||||||
|
|
||||||
@ -43,6 +49,8 @@ class AddImportListPresetMenuItem extends Component {
|
|||||||
AddImportListPresetMenuItem.propTypes = {
|
AddImportListPresetMenuItem.propTypes = {
|
||||||
name: PropTypes.string.isRequired,
|
name: PropTypes.string.isRequired,
|
||||||
implementation: PropTypes.string.isRequired,
|
implementation: PropTypes.string.isRequired,
|
||||||
|
implementationName: PropTypes.string.isRequired,
|
||||||
|
minRefreshInterval: PropTypes.string.isRequired,
|
||||||
onPress: PropTypes.func.isRequired
|
onPress: PropTypes.func.isRequired
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -57,7 +57,7 @@ function EditImportListModalContent(props) {
|
|||||||
return (
|
return (
|
||||||
<ModalContent onModalClose={onModalClose}>
|
<ModalContent onModalClose={onModalClose}>
|
||||||
<ModalHeader>
|
<ModalHeader>
|
||||||
{`${id ? translate('Edit') : translate('Add')} ${translate('List')} - ${implementationName}`}
|
{id ? translate('EditImportListImplementation', { implementationName }) : translate('AddImportListImplementation', { implementationName })}
|
||||||
</ModalHeader>
|
</ModalHeader>
|
||||||
|
|
||||||
<ModalBody>
|
<ModalBody>
|
||||||
|
@ -16,10 +16,11 @@ class AddIndexerItem extends Component {
|
|||||||
|
|
||||||
onIndexerSelect = () => {
|
onIndexerSelect = () => {
|
||||||
const {
|
const {
|
||||||
implementation
|
implementation,
|
||||||
|
implementationName
|
||||||
} = this.props;
|
} = this.props;
|
||||||
|
|
||||||
this.props.onIndexerSelect({ implementation });
|
this.props.onIndexerSelect({ implementation, implementationName });
|
||||||
};
|
};
|
||||||
|
|
||||||
//
|
//
|
||||||
@ -77,6 +78,7 @@ class AddIndexerItem extends Component {
|
|||||||
key={preset.name}
|
key={preset.name}
|
||||||
name={preset.name}
|
name={preset.name}
|
||||||
implementation={implementation}
|
implementation={implementation}
|
||||||
|
implementationName={implementationName}
|
||||||
onPress={onIndexerSelect}
|
onPress={onIndexerSelect}
|
||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
|
@ -48,8 +48,8 @@ class AddIndexerModalContentConnector extends Component {
|
|||||||
//
|
//
|
||||||
// Listeners
|
// Listeners
|
||||||
|
|
||||||
onIndexerSelect = ({ implementation, name }) => {
|
onIndexerSelect = ({ implementation, implementationName, name }) => {
|
||||||
this.props.selectIndexerSchema({ implementation, presetName: name });
|
this.props.selectIndexerSchema({ implementation, implementationName, presetName: name });
|
||||||
this.props.onModalClose({ indexerSelected: true });
|
this.props.onModalClose({ indexerSelected: true });
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -10,12 +10,14 @@ class AddIndexerPresetMenuItem extends Component {
|
|||||||
onPress = () => {
|
onPress = () => {
|
||||||
const {
|
const {
|
||||||
name,
|
name,
|
||||||
implementation
|
implementation,
|
||||||
|
implementationName
|
||||||
} = this.props;
|
} = this.props;
|
||||||
|
|
||||||
this.props.onPress({
|
this.props.onPress({
|
||||||
name,
|
name,
|
||||||
implementation
|
implementation,
|
||||||
|
implementationName
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -26,6 +28,7 @@ class AddIndexerPresetMenuItem extends Component {
|
|||||||
const {
|
const {
|
||||||
name,
|
name,
|
||||||
implementation,
|
implementation,
|
||||||
|
implementationName,
|
||||||
...otherProps
|
...otherProps
|
||||||
} = this.props;
|
} = this.props;
|
||||||
|
|
||||||
@ -43,6 +46,7 @@ class AddIndexerPresetMenuItem extends Component {
|
|||||||
AddIndexerPresetMenuItem.propTypes = {
|
AddIndexerPresetMenuItem.propTypes = {
|
||||||
name: PropTypes.string.isRequired,
|
name: PropTypes.string.isRequired,
|
||||||
implementation: PropTypes.string.isRequired,
|
implementation: PropTypes.string.isRequired,
|
||||||
|
implementationName: PropTypes.string.isRequired,
|
||||||
onPress: PropTypes.func.isRequired
|
onPress: PropTypes.func.isRequired
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -55,7 +55,7 @@ function EditIndexerModalContent(props) {
|
|||||||
return (
|
return (
|
||||||
<ModalContent onModalClose={onModalClose}>
|
<ModalContent onModalClose={onModalClose}>
|
||||||
<ModalHeader>
|
<ModalHeader>
|
||||||
{`${id ? translate('EditIndexer') : translate('AddIndexer')} - ${implementationName}`}
|
{id ? translate('EditIndexerImplementation', { implementationName }) : translate('AddIndexerImplementation', { implementationName })}
|
||||||
</ModalHeader>
|
</ModalHeader>
|
||||||
|
|
||||||
<ModalBody>
|
<ModalBody>
|
||||||
|
@ -28,7 +28,7 @@ class AddNotificationModalContent extends Component {
|
|||||||
return (
|
return (
|
||||||
<ModalContent onModalClose={onModalClose}>
|
<ModalContent onModalClose={onModalClose}>
|
||||||
<ModalHeader>
|
<ModalHeader>
|
||||||
{translate('AddNotification')}
|
{translate('AddConnection')}
|
||||||
</ModalHeader>
|
</ModalHeader>
|
||||||
|
|
||||||
<ModalBody>
|
<ModalBody>
|
||||||
|
@ -48,7 +48,7 @@ function EditNotificationModalContent(props) {
|
|||||||
return (
|
return (
|
||||||
<ModalContent onModalClose={onModalClose}>
|
<ModalContent onModalClose={onModalClose}>
|
||||||
<ModalHeader>
|
<ModalHeader>
|
||||||
{`${id ? translate('Edit') : translate('Add')} ${translate('Connection')} - ${implementationName}`}
|
{id ? translate('EditConnectionImplementation', { implementationName }) : translate('AddConnectionImplementation', { implementationName })}
|
||||||
</ModalHeader>
|
</ModalHeader>
|
||||||
|
|
||||||
<ModalBody>
|
<ModalBody>
|
||||||
|
@ -72,7 +72,7 @@ function EditSpecificationModalContent(props) {
|
|||||||
return (
|
return (
|
||||||
<ModalContent onModalClose={onCancelPress}>
|
<ModalContent onModalClose={onCancelPress}>
|
||||||
<ModalHeader>
|
<ModalHeader>
|
||||||
{`${id ? translate('EditCondition') : translate('AddCondition')} - ${implementationName}`}
|
{id ? translate('EditConditionImplementation', { implementationName }) : translate('AddConditionImplementation', { implementationName })}
|
||||||
</ModalHeader>
|
</ModalHeader>
|
||||||
|
|
||||||
<ModalBody>
|
<ModalBody>
|
||||||
|
@ -119,6 +119,7 @@ export default {
|
|||||||
|
|
||||||
[SELECT_DOWNLOAD_CLIENT_SCHEMA]: (state, { payload }) => {
|
[SELECT_DOWNLOAD_CLIENT_SCHEMA]: (state, { payload }) => {
|
||||||
return selectProviderSchema(state, section, payload, (selectedSchema) => {
|
return selectProviderSchema(state, section, payload, (selectedSchema) => {
|
||||||
|
selectedSchema.name = selectedSchema.implementationName;
|
||||||
selectedSchema.enable = true;
|
selectedSchema.enable = true;
|
||||||
|
|
||||||
return selectedSchema;
|
return selectedSchema;
|
||||||
|
@ -120,7 +120,11 @@ export default {
|
|||||||
|
|
||||||
[SELECT_IMPORT_LIST_SCHEMA]: (state, { payload }) => {
|
[SELECT_IMPORT_LIST_SCHEMA]: (state, { payload }) => {
|
||||||
return selectProviderSchema(state, section, payload, (selectedSchema) => {
|
return selectProviderSchema(state, section, payload, (selectedSchema) => {
|
||||||
|
selectedSchema.name = payload.presetName ?? payload.implementationName;
|
||||||
|
selectedSchema.implementationName = payload.implementationName;
|
||||||
|
selectedSchema.minRefreshInterval = payload.minRefreshInterval;
|
||||||
selectedSchema.minimumAvailability = 'released';
|
selectedSchema.minimumAvailability = 'released';
|
||||||
|
selectedSchema.rootFolderPath = '';
|
||||||
|
|
||||||
return selectedSchema;
|
return selectedSchema;
|
||||||
});
|
});
|
||||||
|
@ -124,6 +124,8 @@ export default {
|
|||||||
|
|
||||||
[SELECT_INDEXER_SCHEMA]: (state, { payload }) => {
|
[SELECT_INDEXER_SCHEMA]: (state, { payload }) => {
|
||||||
return selectProviderSchema(state, section, payload, (selectedSchema) => {
|
return selectProviderSchema(state, section, payload, (selectedSchema) => {
|
||||||
|
selectedSchema.name = payload.presetName ?? payload.implementationName;
|
||||||
|
selectedSchema.implementationName = payload.implementationName;
|
||||||
selectedSchema.enableRss = selectedSchema.supportsRss;
|
selectedSchema.enableRss = selectedSchema.supportsRss;
|
||||||
selectedSchema.enableAutomaticSearch = selectedSchema.supportsSearch;
|
selectedSchema.enableAutomaticSearch = selectedSchema.supportsSearch;
|
||||||
selectedSchema.enableInteractiveSearch = selectedSchema.supportsSearch;
|
selectedSchema.enableInteractiveSearch = selectedSchema.supportsSearch;
|
||||||
|
@ -102,6 +102,7 @@ export default {
|
|||||||
|
|
||||||
[SELECT_NOTIFICATION_SCHEMA]: (state, { payload }) => {
|
[SELECT_NOTIFICATION_SCHEMA]: (state, { payload }) => {
|
||||||
return selectProviderSchema(state, section, payload, (selectedSchema) => {
|
return selectProviderSchema(state, section, payload, (selectedSchema) => {
|
||||||
|
selectedSchema.name = selectedSchema.implementationName;
|
||||||
selectedSchema.onGrab = selectedSchema.supportsOnGrab;
|
selectedSchema.onGrab = selectedSchema.supportsOnGrab;
|
||||||
selectedSchema.onDownload = selectedSchema.supportsOnDownload;
|
selectedSchema.onDownload = selectedSchema.supportsOnDownload;
|
||||||
selectedSchema.onUpgrade = selectedSchema.supportsOnUpgrade;
|
selectedSchema.onUpgrade = selectedSchema.supportsOnUpgrade;
|
||||||
|
@ -58,7 +58,6 @@ public virtual IEnumerable<ProviderDefinition> DefaultDefinitions
|
|||||||
|
|
||||||
yield return new ImportListDefinition
|
yield return new ImportListDefinition
|
||||||
{
|
{
|
||||||
Name = GetType().Name,
|
|
||||||
Enabled = config.Validate().IsValid && Enabled,
|
Enabled = config.Validate().IsValid && Enabled,
|
||||||
EnableAuto = true,
|
EnableAuto = true,
|
||||||
Implementation = GetType().Name,
|
Implementation = GetType().Name,
|
||||||
|
@ -53,7 +53,6 @@ public virtual IEnumerable<ProviderDefinition> DefaultDefinitions
|
|||||||
|
|
||||||
yield return new IndexerDefinition
|
yield return new IndexerDefinition
|
||||||
{
|
{
|
||||||
Name = GetType().Name,
|
|
||||||
EnableRss = config.Validate().IsValid && SupportsRss,
|
EnableRss = config.Validate().IsValid && SupportsRss,
|
||||||
EnableAutomaticSearch = config.Validate().IsValid && SupportsSearch,
|
EnableAutomaticSearch = config.Validate().IsValid && SupportsSearch,
|
||||||
EnableInteractiveSearch = config.Validate().IsValid && SupportsSearch,
|
EnableInteractiveSearch = config.Validate().IsValid && SupportsSearch,
|
||||||
|
@ -6,13 +6,19 @@
|
|||||||
"Add": "Add",
|
"Add": "Add",
|
||||||
"AddAutoTag": "Add Auto Tag",
|
"AddAutoTag": "Add Auto Tag",
|
||||||
"AddCondition": "Add Condition",
|
"AddCondition": "Add Condition",
|
||||||
|
"AddConditionImplementation": "Add Condition - {implementationName}",
|
||||||
|
"AddConnection": "Add Connection",
|
||||||
|
"AddConnectionImplementation": "Add Connection - {implementationName}",
|
||||||
"AddCustomFormat": "Add Custom Format",
|
"AddCustomFormat": "Add Custom Format",
|
||||||
"AddDelayProfile": "Add Delay Profile",
|
"AddDelayProfile": "Add Delay Profile",
|
||||||
"AddDownloadClient": "Add Download Client",
|
"AddDownloadClient": "Add Download Client",
|
||||||
|
"AddDownloadClientImplementation": "Add Download Client - {implementationName}",
|
||||||
"AddExclusion": "Add Exclusion",
|
"AddExclusion": "Add Exclusion",
|
||||||
"AddImportExclusionHelpText": "Prevent movie from being added to Radarr by lists",
|
"AddImportExclusionHelpText": "Prevent movie from being added to Radarr by lists",
|
||||||
|
"AddImportList": "Add Import List",
|
||||||
|
"AddImportListImplementation": "Add Import List - {implementationName}",
|
||||||
"AddIndexer": "Add Indexer",
|
"AddIndexer": "Add Indexer",
|
||||||
"AddList": "Add List",
|
"AddIndexerImplementation": "Add Indexer - {implementationName}",
|
||||||
"AddListExclusion": "Add List Exclusion",
|
"AddListExclusion": "Add List Exclusion",
|
||||||
"AddMovie": "Add Movie",
|
"AddMovie": "Add Movie",
|
||||||
"AddMovies": "Add Movies",
|
"AddMovies": "Add Movies",
|
||||||
@ -20,7 +26,6 @@
|
|||||||
"AddNewMessage": "It's easy to add a new movie, just start typing the name of the movie you want to add",
|
"AddNewMessage": "It's easy to add a new movie, just start typing the name of the movie you want to add",
|
||||||
"AddNewMovie": "Add New Movie",
|
"AddNewMovie": "Add New Movie",
|
||||||
"AddNewTmdbIdMessage": "You can also search using TMDb Id of a movie. e.g. 'tmdb:71663'",
|
"AddNewTmdbIdMessage": "You can also search using TMDb Id of a movie. e.g. 'tmdb:71663'",
|
||||||
"AddNotification": "Add Notification",
|
|
||||||
"AddQualityProfile": "Add Quality Profile",
|
"AddQualityProfile": "Add Quality Profile",
|
||||||
"AddRemotePathMapping": "Add Remote Path Mapping",
|
"AddRemotePathMapping": "Add Remote Path Mapping",
|
||||||
"AddRestriction": "Add Restriction",
|
"AddRestriction": "Add Restriction",
|
||||||
@ -307,11 +312,14 @@
|
|||||||
"Edit": "Edit",
|
"Edit": "Edit",
|
||||||
"EditAutoTag": "Edit Auto Tag",
|
"EditAutoTag": "Edit Auto Tag",
|
||||||
"EditCollection": "Edit Collection",
|
"EditCollection": "Edit Collection",
|
||||||
"EditCondition": "Edit Condition",
|
"EditConditionImplementation": "Edit Condition - {implementationName}",
|
||||||
|
"EditConnectionImplementation": "Edit Notification - {implementationName}",
|
||||||
"EditCustomFormat": "Edit Custom Format",
|
"EditCustomFormat": "Edit Custom Format",
|
||||||
"EditDelayProfile": "Edit Delay Profile",
|
"EditDelayProfile": "Edit Delay Profile",
|
||||||
|
"EditDownloadClientImplementation": "Edit Download Client - {implementationName}",
|
||||||
"EditGroups": "Edit Groups",
|
"EditGroups": "Edit Groups",
|
||||||
"EditIndexer": "Edit Indexer",
|
"EditImportListImplementation": "Edit Import List - {implementationName}",
|
||||||
|
"EditIndexerImplementation": "Edit Indexer - {implementationName}",
|
||||||
"EditListExclusion": "Edit List Exclusion",
|
"EditListExclusion": "Edit List Exclusion",
|
||||||
"EditMovie": "Edit Movie",
|
"EditMovie": "Edit Movie",
|
||||||
"EditMovieFile": "Edit Movie File",
|
"EditMovieFile": "Edit Movie File",
|
||||||
|
Loading…
Reference in New Issue
Block a user