1
0
mirror of https://github.com/Radarr/Radarr.git synced 2026-04-27 22:57:09 -04:00

New: Movie Editor in Movie Index (#3606)

* Fixed: Movie Editor in Movie Index

* Fixed: CSS Style Issues

* Fixed: Ensure only items shown are selected

* Fixed: Cleanup and Rename from Editor
This commit is contained in:
Qstick
2019-07-12 20:40:37 -04:00
committed by GitHub
parent b8f7ca0749
commit a20222fbef
78 changed files with 823 additions and 962 deletions
@@ -3,7 +3,7 @@
font-weight: bold;
}
.episodeFormat {
.standardMovieFormat {
margin-left: 5px;
font-family: $monoSpaceFontFamily;
}
@@ -75,7 +75,7 @@ class OrganizePreviewModalContent extends Component {
error,
items,
renameEpisodes,
episodeFormat,
standardMovieFormat,
path,
onModalClose
} = this.props;
@@ -129,8 +129,8 @@ class OrganizePreviewModalContent extends Component {
<div>
Naming pattern:
<span className={styles.episodeFormat}>
{episodeFormat}
<span className={styles.standardMovieFormat}>
{standardMovieFormat}
</span>
</div>
</Alert>
@@ -140,11 +140,11 @@ class OrganizePreviewModalContent extends Component {
items.map((item) => {
return (
<OrganizePreviewRow
key={item.episodeFileId}
id={item.episodeFileId}
key={item.movieFileId}
id={item.movieFileId}
existingPath={item.existingPath}
newPath={item.newPath}
isSelected={selectedState[item.episodeFileId]}
isSelected={selectedState[item.movieFileId]}
onSelectedChange={this.onSelectedChange}
/>
);
@@ -190,10 +190,9 @@ OrganizePreviewModalContent.propTypes = {
isPopulated: PropTypes.bool.isRequired,
error: PropTypes.object,
items: PropTypes.arrayOf(PropTypes.object).isRequired,
seasonNumber: PropTypes.string.isRequired,
path: PropTypes.string.isRequired,
renameEpisodes: PropTypes.bool,
episodeFormat: PropTypes.string,
standardMovieFormat: PropTypes.string,
onOrganizePress: PropTypes.func.isRequired,
onModalClose: PropTypes.func.isRequired
};
@@ -14,14 +14,14 @@ function createMapStateToProps() {
(state) => state.organizePreview,
(state) => state.settings.naming,
createMovieSelector(),
(organizePreview, naming, series) => {
(organizePreview, naming, movie) => {
const props = { ...organizePreview };
props.isFetching = organizePreview.isFetching || naming.isFetching;
props.isPopulated = organizePreview.isPopulated && naming.isPopulated;
props.error = organizePreview.error || naming.error;
props.renameEpisodes = naming.item.renameEpisodes;
props.episodeFormat = naming.item.episodeFormat;
props.path = series.path;
props.standardMovieFormat = naming.item.standardMovieFormat;
props.path = movie.path;
return props;
}
@@ -41,13 +41,11 @@ class OrganizePreviewModalContentConnector extends Component {
componentDidMount() {
const {
seriesId,
seasonNumber
movieId
} = this.props;
this.props.fetchOrganizePreview({
seriesId,
seasonNumber
movieId
});
this.props.fetchNamingSettings();
@@ -59,7 +57,7 @@ class OrganizePreviewModalContentConnector extends Component {
onOrganizePress = (files) => {
this.props.executeCommand({
name: commandNames.RENAME_FILES,
seriesId: this.props.seriesId,
movieId: this.props.movieId,
files
});
@@ -80,8 +78,7 @@ class OrganizePreviewModalContentConnector extends Component {
}
OrganizePreviewModalContentConnector.propTypes = {
seriesId: PropTypes.number.isRequired,
seasonNumber: PropTypes.number,
movieId: PropTypes.number.isRequired,
fetchOrganizePreview: PropTypes.func.isRequired,
fetchNamingSettings: PropTypes.func.isRequired,
executeCommand: PropTypes.func.isRequired,