diff --git a/serendipity_event_todolist/UTF-8/lang_de.inc.php b/serendipity_event_todolist/UTF-8/lang_de.inc.php index c7caafd3..84f8dabf 100644 --- a/serendipity_event_todolist/UTF-8/lang_de.inc.php +++ b/serendipity_event_todolist/UTF-8/lang_de.inc.php @@ -40,7 +40,7 @@ @define('PLUGIN_EVENT_TODOLIST_CATEGORY_NAME_CUSTOM','Besondere Formatierung'); @define('PLUGIN_EVENT_TODOLIST_CATEGORY_NAME_DEFAULT','Standard-Formatierung'); @define('PLUGIN_EVENT_TODOLIST_CATDB_WARNING','Die besondere Kategorisierung wurde aktiviert, aber die Kategoriedatenbank besteht nicht. Bitte hier klicken um die Datenbank anzulegen.'); - @define('PLUGIN_EVENT_TODOLIST_ADD_CAT','Kategorien verwalten'); + @define('PLUGIN_EVENT_TODOLIST_ADD_CAT','Kategorie anlegen'); @define('PLUGIN_EVENT_TODOLIST_CAT_NAME','Name der Kategorie'); @define('PLUGIN_EVENT_TODOLIST_PARENT_CATEGORY','Ãœbergeordnete Kategorie'); @define('PLUGIN_EVENT_TODOLIST_ADMINCAT','Kategorien verwalten'); diff --git a/serendipity_event_todolist/lang_de.inc.php b/serendipity_event_todolist/lang_de.inc.php index d860dab5..5096d6ab 100644 --- a/serendipity_event_todolist/lang_de.inc.php +++ b/serendipity_event_todolist/lang_de.inc.php @@ -40,7 +40,7 @@ @define('PLUGIN_EVENT_TODOLIST_CATEGORY_NAME_CUSTOM','Besondere Formatierung'); @define('PLUGIN_EVENT_TODOLIST_CATEGORY_NAME_DEFAULT','Standard-Formatierung'); @define('PLUGIN_EVENT_TODOLIST_CATDB_WARNING','Die besondere Kategorisierung wurde aktiviert, aber die Kategoriedatenbank besteht nicht. Bitte hier klicken um die Datenbank anzulegen.'); - @define('PLUGIN_EVENT_TODOLIST_ADD_CAT','Kategorien verwalten'); + @define('PLUGIN_EVENT_TODOLIST_ADD_CAT','Kategorie anlegen'); @define('PLUGIN_EVENT_TODOLIST_CAT_NAME','Name der Kategorie'); @define('PLUGIN_EVENT_TODOLIST_PARENT_CATEGORY','Übergeordnete Kategorie'); @define('PLUGIN_EVENT_TODOLIST_ADMINCAT','Kategorien verwalten'); diff --git a/serendipity_event_todolist/lang_en.inc.php b/serendipity_event_todolist/lang_en.inc.php index 9583de1f..74252695 100644 --- a/serendipity_event_todolist/lang_en.inc.php +++ b/serendipity_event_todolist/lang_en.inc.php @@ -1,7 +1,7 @@ - * EN-Revision: Revision of lang_en.inc.php */ @@ -63,7 +63,7 @@ @define('PLUGIN_EVENT_TODOLIST_CATEGORY_NAME_CUSTOM','Custom'); @define('PLUGIN_EVENT_TODOLIST_CATEGORY_NAME_DEFAULT','Default'); @define('PLUGIN_EVENT_TODOLIST_CATDB_WARNING','You are configured to use custom categories, but the category database does not exist. Please click here to create the database.'); -@define('PLUGIN_EVENT_TODOLIST_ADD_CAT','Manage categories'); +@define('PLUGIN_EVENT_TODOLIST_ADD_CAT','Add category'); @define('PLUGIN_EVENT_TODOLIST_ADD_COLOR','Add a Color'); @define('PLUGIN_EVENT_TODOLIST_MANAGE_COLORS','Manage Colors'); @define('PLUGIN_EVENT_TODOLIST_CAT_NAME','Category Name'); diff --git a/serendipity_event_todolist/serendipity_event_todolist.php b/serendipity_event_todolist/serendipity_event_todolist.php index 5ba5ca17..db0a52ff 100644 --- a/serendipity_event_todolist/serendipity_event_todolist.php +++ b/serendipity_event_todolist/serendipity_event_todolist.php @@ -37,12 +37,13 @@ class serendipity_event_todolist extends serendipity_event { $propbag->add('description', PLUGIN_EVENT_TODOLIST_DESC); $propbag->add('event_hooks', array('backend_sidebar_entries_event_display_percentagedone' => true, 'external_plugin' => true, - 'backend_sidebar_entries' => true + 'backend_sidebar_entries' => true, + 'css_backend' => true )); - $propbag->add('author', 'Steven Tonnesen'); - $propbag->add('version', '1.24.1'); + $propbag->add('author', 'Steven Tonnesen, Matthias Mees'); + $propbag->add('version', '1.25.0'); $propbag->add('requirements', array( - 'serendipity' => '0.8', + 'serendipity' => '2.0', 'smarty' => '2.6.7', 'php' => '4.1.0' )); @@ -377,10 +378,15 @@ class serendipity_event_todolist extends serendipity_event { break; case 'backend_sidebar_entries': - echo ''; + echo '
  • ' . PLUGIN_EVENT_TODOLIST_ADMINPROJECT . '
  • '; return true; break; + case 'css_backend': + echo file_get_contents(dirname(__FILE__) . '/todolist_backend.css'); + + break; + case 'external_plugin': $parts = explode('_', $eventData); if (!empty($parts[1])) { @@ -1496,17 +1502,21 @@ class serendipity_event_todolist extends serendipity_event { echo '

    '.PLUGIN_EVENT_TODOLIST_ADMINPROJECT.'

    '; ?>
    - - - - - - - - - - tdoutput; ?> - +
    +
     
    + + + + + + + + + + tdoutput; ?> + + +  '; + $moveup = ''; } else { - $moveup = ''; + $moveup = ''; } if ($sort_idx == (count($sql)-1)) { - $movedown = ''; + $movedown = ''; } else { - $movedown = ''; + $movedown = ''; } } @@ -1558,52 +1568,38 @@ class serendipity_event_todolist extends serendipity_event { } ?> - - - - - - - + + + + + + + '; - if ($this->get_config('category') == 'custom') { - $catproject = ''.PLUGIN_EVENT_TODOLIST_ADD_CAT.''; - } - $colorproject = ''.PLUGIN_EVENT_TODOLIST_MANAGE_COLORS.''; - echo ""; - echo '
     
     ' . UP . '' . UP . '  '.($moveup != '' ? ' ' : '') . ''. DOWN .''. DOWN .'
    -
    - -
    -
    -
    %
    -
    - /> - - category_box($id, $categories, $current_category); ?> - - - - - >category_box($id, $categories, $current_category); ?>
     $catproject $colorproject
    '; - echo '
    '; - echo ''; - echo ' '; - echo ''; - echo '
    '; - echo '
    '; } + echo ''; + echo ''; + echo ''; + if ($this->get_config('category') == 'custom') { + $catproject = ' '.PLUGIN_EVENT_TODOLIST_ADD_CAT.''; + } + $colorproject = ' '.PLUGIN_EVENT_TODOLIST_MANAGE_COLORS.''; + echo '
    '; + echo ' ' . "\n"; + echo ' '; + echo $catproject; + echo $colorproject; + echo '
    '; + echo ''; } function category_box($id,$categories,$current_category = 0) { - $x = "\n\n"; foreach ($categories as $k => $v) { $x .= " \n"; } @@ -1631,24 +1627,24 @@ class serendipity_event_todolist extends serendipity_event { $entry = $res['entry']; $hidden = $res['hidden']; } - $button = ''; + $button = ''; } else { $maintitle = PLUGIN_EVENT_TODOLIST_ADDPROJECT; - $button = ''; + $button = ''; } if ($this->get_config('category') == 'custom') { - $catproject = '('.PLUGIN_EVENT_TODOLIST_ADD_CAT.')'; + $catproject = ''.PLUGIN_EVENT_TODOLIST_ADD_CAT.''; } - $colorproject = '('.PLUGIN_EVENT_TODOLIST_MANAGE_COLORS.')'; - echo '

    ' . $maintitle . '

    '; + $colorproject = ''.PLUGIN_EVENT_TODOLIST_MANAGE_COLORS.''; + echo '

    ' . $maintitle . '

    '; $entrytext = $this->getEntrytext($projectentry); if ($this->check_gd()) { $nogdwarning = ''; } else { - $nogdwarning = "
    " . PLUGIN_EVENT_TODOLIST_NOGDLIB; + $nogdwarning = ' ' . PLUGIN_EVENT_TODOLIST_NOGDLIB; } $q = "SELECT * @@ -1666,40 +1662,48 @@ class serendipity_event_todolist extends serendipity_event { } } ?> -
    - - - - - - + + - - - - +
    + + +
    - - - - +
    + + category_box('cat',$categories,$cat); ?> + +
    - - - - +
    + + + +
    - - - - +
    + + +
    - - - - -
    category_box('cat',$categories,$cat); ?>
    %
    -
    +
    + + +
    + +
    + + +
    + +
    + +
    get_config('display'); $categories = $this->build_categories(); $maintitle = PLUGIN_EVENT_TODOLIST_ADD_COLOR; - $button = ''; - echo '

    '.$maintitle.'

    '; + $button = ''; + echo '

    '.$maintitle.'

    '; ?> -
    - - - - - - + + - - - - +
    + + +
    - - - - -
    -
    +
    + + +
    + +
    + + +
    + +
    + +
    '.PLUGIN_EVENT_TODOLIST_MANAGE_COLORS.''; - echo "".PLUGIN_EVENT_TODOLIST_COLORWHEEL.''; + echo "".PLUGIN_EVENT_TODOLIST_COLORWHEEL.''; ?>
    - - - - - - - - +
    +
    + + + + + + + + + + - - + + - - - - - - - - + + + + + + + -
     
    - -
    -
    + +
    + +
    '; - echo ' '; - echo ''; + echo ' '; + echo ' '; ?> -
    +
    '.$color['color_name']."\n"; } $maintitle = PLUGIN_EVENT_TODOLIST_ADD_CAT; - $button = ''; - echo '

    '.$maintitle.'

    '; + $button = ''; + echo '

    '.$maintitle.'

    '; ?> -
    - - - - - - + + - - - - +
    + + +
    - - - - -
    category_box('cat',$categories,$cat); ?>
    -
    +
    + + category_box('cat',$categories,$cat); ?> +
    + +
    + + +
    + +
    + +
    '.PLUGIN_EVENT_TODOLIST_ADMINCAT.''; ?>
    - - - - - - +
    +
    + + + + + + + + - - - - - - - + + + + + -
     
    - - - -
    -
    + + +
    +
    '; - echo ' '; - echo ''; + echo ' '; + echo ' '; ?> -
    +
    tdoutput = ' '; + $this->tdoutput = ' '; break; case 'dateacs': diff --git a/serendipity_event_todolist/todolist_backend.css b/serendipity_event_todolist/todolist_backend.css new file mode 100644 index 00000000..579a6760 --- /dev/null +++ b/serendipity_event_todolist/todolist_backend.css @@ -0,0 +1,60 @@ +.serendipity_todolist_wrap { + min-height: .01%; + -ms-overflow-style: -ms-autohiding-scrollbar; + overflow-x: auto; + overflow-y: hidden; +} + +.serendipity_todolist_wrap table { + border: 1px solid #aaa; + border-bottom: 0; + margin-top: 0; + width: 100%; +} + +.serendipity_todolist_wrap tr { + border-bottom: 1px solid #aaa; +} + +.serendipity_todolist_wrap th, +.serendipity_todolist_wrap td { + padding: .25em; + white-space: nowrap; +} + +.serendipity_todolist_wrap thead tr, +.serendipity_todolist_wrap tbody tr:nth-child(even) { + background-color: #eee; +} + +.serendipity_todolist_wrap input[type='text'], +.serendipity_todolist_wrap select { + width: 100%; +} + +.serendipity_todolist_form label { + display: block; +} + +.serendipity_todolist_form input[type='text'], +.serendipity_todolist_form select { + max-width: 20em; + min-width: 15em; +} + +@media screen and (min-width: 768px) { + .serendipity_todolist_wrap { + overflow-y: auto; + } + + .serendipity_todolist_wrap th, + .serendipity_todolist_wrap td { + white-space: normal; + } + + .serendipity_todolist_form input[type='text'], + .serendipity_todolist_form select { + max-width: 30em; + min-width: 20em; + } +}