From 2ec5cbc2aa2fe992d2cccaf6d160950adef521ef Mon Sep 17 00:00:00 2001 From: steckbrief Date: Sun, 10 Dec 2017 20:22:33 +0100 Subject: create story and character improved --- lib/commons | 2 +- lib/functions.stories.inc.php | 8 ++++++-- lib/new-character-dialog.inc.php | 41 ++++++++++++++++++++++++++++++++++++++++ lib/new-story-dialog.inc.php | 6 ++++++ 4 files changed, 54 insertions(+), 3 deletions(-) create mode 100644 lib/new-character-dialog.inc.php (limited to 'lib') diff --git a/lib/commons b/lib/commons index c906747..eb2e78a 160000 --- a/lib/commons +++ b/lib/commons @@ -1 +1 @@ -Subproject commit c906747e7aef1308b956a62c911d726065a39ad9 +Subproject commit eb2e78a12505b8d41e0ef62cb1b321cdc540e5fd diff --git a/lib/functions.stories.inc.php b/lib/functions.stories.inc.php index a8102c3..b882869 100644 --- a/lib/functions.stories.inc.php +++ b/lib/functions.stories.inc.php @@ -9,8 +9,8 @@ function visibleName($nameWithUnderscore) { return urldecode($nameWithUnderscore); } -function generateDirectoryName($storyName) { - return urlencode($storyName); +function generateDirectoryName($name) { + return urlencode($name); } function createEntity($path, $description, $file, $filename) { @@ -27,7 +27,11 @@ function createEntity($path, $description, $file, $filename) { } } else { // Error on directory creation + // return 'Could not create directory "'.$path; + return 2; } + } else { + return 1; } } ?> diff --git a/lib/new-character-dialog.inc.php b/lib/new-character-dialog.inc.php new file mode 100644 index 0000000..5cf25c0 --- /dev/null +++ b/lib/new-character-dialog.inc.php @@ -0,0 +1,41 @@ + + + + + + + + diff --git a/lib/new-story-dialog.inc.php b/lib/new-story-dialog.inc.php index ee55e4b..73c6abf 100644 --- a/lib/new-story-dialog.inc.php +++ b/lib/new-story-dialog.inc.php @@ -36,3 +36,9 @@ + -- cgit v1.2.3