1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-06 14:46:56 +02:00

Issue #75 Media-Manager Category SEF field added.

This commit is contained in:
Cameron
2013-01-15 23:19:34 -08:00
parent b33a298067
commit 1d6905ea5d
4 changed files with 4 additions and 1 deletions

View File

@@ -160,6 +160,7 @@ class media_cat_ui extends e_admin_ui
'media_cat_category' => array('title'=> LAN_CATEGORY, 'type' => 'text', 'data'=>'str', 'width' => 'auto', 'thclass' => 'left', 'readonly'=>TRUE), 'media_cat_category' => array('title'=> LAN_CATEGORY, 'type' => 'text', 'data'=>'str', 'width' => 'auto', 'thclass' => 'left', 'readonly'=>TRUE),
'media_cat_title' => array('title'=> LAN_TITLE, 'type' => 'text', 'width' => 'auto', 'thclass' => 'left', 'readonly'=>FALSE), 'media_cat_title' => array('title'=> LAN_TITLE, 'type' => 'text', 'width' => 'auto', 'thclass' => 'left', 'readonly'=>FALSE),
'media_cat_sef' => array('title'=> LAN_SEFURL, 'type' => 'text', 'width' => 'auto', 'thclass' => 'left', 'readonly'=>FALSE),
'media_cat_diz' => array('title'=> LAN_DESCRIPTION, 'type' => 'bbarea', 'width' => '30%', 'readParms' => 'expand=...&truncate=150&bb=1','readonly'=>FALSE), // Display name 'media_cat_diz' => array('title'=> LAN_DESCRIPTION, 'type' => 'bbarea', 'width' => '30%', 'readParms' => 'expand=...&truncate=150&bb=1','readonly'=>FALSE), // Display name
'media_cat_class' => array('title'=> LAN_VISIBILITY, 'type' => 'userclass', 'width' => 'auto', 'data' => 'int'), 'media_cat_class' => array('title'=> LAN_VISIBILITY, 'type' => 'userclass', 'width' => 'auto', 'data' => 'int'),
'media_cat_order' => array('title'=> LAN_ORDER, 'type' => 'text', 'width' => '5%', 'thclass' => 'right', 'class'=> 'right' ), 'media_cat_order' => array('title'=> LAN_ORDER, 'type' => 'text', 'width' => '5%', 'thclass' => 'right', 'class'=> 'right' ),

View File

@@ -148,6 +148,7 @@ CREATE TABLE core_media_cat (
media_cat_owner varchar(255) NOT NULL default '', media_cat_owner varchar(255) NOT NULL default '',
media_cat_category varchar(255) NOT NULL default '', media_cat_category varchar(255) NOT NULL default '',
media_cat_title text NOT NULL, media_cat_title text NOT NULL,
media_cat_sef varchar(255) NOT NULL default '',
media_cat_diz text NOT NULL, media_cat_diz text NOT NULL,
media_cat_class int(5) default '0', media_cat_class int(5) default '0',
media_cat_image varchar(255) NOT NULL default '', media_cat_image varchar(255) NOT NULL default '',

View File

@@ -1839,6 +1839,7 @@ class e107plugin
$data['owner'] = $folder; $data['owner'] = $folder;
$data['category'] = $folder."_".$type; $data['category'] = $folder."_".$type;
$data['title'] = $v['@value']; $data['title'] = $v['@value'];
$data['sef'] = vartrue($v['@attributes']['sef']);
// $data['type'] = $v['@attributes']['type']; //TODO // $data['type'] = $v['@attributes']['type']; //TODO
$data['class'] = 253; $data['class'] = 253;
$status = e107::getMedia()->createCategory($data) ? E_MESSAGE_SUCCESS : E_MESSAGE_ERROR; $status = e107::getMedia()->createCategory($data) ? E_MESSAGE_SUCCESS : E_MESSAGE_ERROR;

View File

@@ -12,7 +12,7 @@
<mainPrefs> <mainPrefs>
</mainPrefs> </mainPrefs>
<mediaCategories> <mediaCategories>
<category type="image">Gallery 1</category> <category type="image" sef="gallery-1">Gallery 1</category>
</mediaCategories> </mediaCategories>
<pluginPrefs> <pluginPrefs>
<pref name="popup_w">800</pref> <pref name="popup_w">800</pref>