mirror of
https://github.com/laurent22/joplin.git
synced 2025-01-11 18:24:43 +02:00
parent
c90865c4d2
commit
f5fc1f2f22
@ -63,6 +63,10 @@ class FolderScreenComponent extends BaseScreenComponent {
|
|||||||
async saveFolderButton_press() {
|
async saveFolderButton_press() {
|
||||||
let folder = Object.assign({}, this.state.folder);
|
let folder = Object.assign({}, this.state.folder);
|
||||||
|
|
||||||
|
if (this.props.navigation.state.parentFolderId) {
|
||||||
|
folder.parent_id = this.props.navigation.state.parentFolderId;
|
||||||
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
folder = await Folder.save(folder, { userSideValidation: true });
|
folder = await Folder.save(folder, { userSideValidation: true });
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
@ -138,6 +138,19 @@ const SideMenuContentComponent = (props: Props) => {
|
|||||||
'',
|
'',
|
||||||
_('Notebook: %s', folder.title),
|
_('Notebook: %s', folder.title),
|
||||||
[
|
[
|
||||||
|
{
|
||||||
|
text: _('New sub-notebook'),
|
||||||
|
onPress: () => {
|
||||||
|
props.dispatch({ type: 'SIDE_MENU_CLOSE' });
|
||||||
|
|
||||||
|
props.dispatch({
|
||||||
|
type: 'NAV_GO',
|
||||||
|
routeName: 'Folder',
|
||||||
|
folderId: null,
|
||||||
|
parentFolderId: folder.id,
|
||||||
|
});
|
||||||
|
},
|
||||||
|
},
|
||||||
{
|
{
|
||||||
text: _('Rename'),
|
text: _('Rename'),
|
||||||
onPress: () => {
|
onPress: () => {
|
||||||
|
Loading…
Reference in New Issue
Block a user