New: Don't default manual import to move

Closes #7280
Closes #7309

(cherry picked from commit 0d739cd26d3b18d1456444e9ddf7e71d84e40253)
pull/7313/head
Mark McDowall 3 years ago committed by Qstick
parent 79cd2b2346
commit 006c9289de

@ -81,6 +81,7 @@ const filterExistingFilesOptions = {
};
const importModeOptions = [
{ key: 'chooseImportMode', value: translate('ChooseImportMode'), disabled: true },
{ key: 'move', value: translate('MoveFiles') },
{ key: 'copy', value: translate('HardlinkCopyFiles') }
];

@ -1,4 +1,3 @@
import _ from 'lodash';
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { connect } from 'react-redux';
@ -101,9 +100,18 @@ class InteractiveImportModalContentConnector extends Component {
};
onImportSelectedPress = (selected, importMode) => {
const {
items
} = this.props;
const files = [];
_.forEach(this.props.items, (item) => {
if (importMode === 'chooseImportMode') {
this.setState({ interactiveImportErrorMessage: 'An import mode must be selected' });
return;
}
items.forEach((item) => {
const isSelected = selected.indexOf(item.id) > -1;
if (isSelected) {

@ -30,7 +30,7 @@ export const defaultState = {
sortKey: 'quality',
sortDirection: sortDirections.DESCENDING,
recentFolders: [],
importMode: 'move',
importMode: 'chooseImportMode',
sortPredicates: {
relativePath: function(item, direction) {
const relativePath = item.relativePath;

File diff suppressed because it is too large Load Diff
Loading…
Cancel
Save