|
From: <txm...@us...> - 2013-04-09 19:37:25
|
Revision: 11367
http://sourceforge.net/p/xoops/svn/11367
Author: txmodxoops
Date: 2013-04-09 19:37:20 +0000 (Tue, 09 Apr 2013)
Log Message:
-----------
Updated
Modified Paths:
--------------
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/about.php
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/admin_header.php
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/building.php
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/fields.php
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/index.php
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/modules.php
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/tables.php
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/class/tdmcreate_modules.php
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/uploads/tables/cat.png
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/include/common.php
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/js/index.html
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/language/english/admin.php
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/xoops_version.php
Added Paths:
-----------
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/css/style.css
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/arrow.gif
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/off.png
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/on.png
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/toggle.png
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/js/functions.js
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/templates/admin/tdmcreate_fields.html
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/templates/admin/tdmcreate_header.html
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/templates/admin/tdmcreate_modules.html
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/templates/admin/tdmcreate_tables.html
Removed Paths:
-------------
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/css/admin.css
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/arrow.gif
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/off.png
XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/on.png
Modified: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/about.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/about.php 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/about.php 2013-04-09 19:37:20 UTC (rev 11367)
@@ -19,6 +19,7 @@
* @version $Id: 1.59 about.php 11297 2013-03-24 10:58:10Z timgno $
*/
include 'admin_header.php';
+xoops_cp_header();
echo $adminMenu->addNavigation('about.php');
echo $adminMenu->renderAbout('YDRUY5QZQHAHS', false);
include 'admin_footer.php';
\ No newline at end of file
Modified: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/admin_header.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/admin_header.php 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/admin_header.php 2013-04-09 19:37:20 UTC (rev 11367)
@@ -40,7 +40,7 @@
$myts =& MyTextSanitizer::getInstance();
if (!isset($xoopsTpl) || !is_object($xoopsTpl)) {
- include_once(XOOPS_ROOT_PATH."/class/template.php");
+ include_once(XOOPS_ROOT_PATH . "/class/template.php");
$xoopsTpl = new XoopsTpl();
}
@@ -57,5 +57,4 @@
}else{
redirect_header("../../../admin.php", 5, _AM_MODULEADMIN_MISSING, false);
}
-xoops_cp_header();
$adminMenu = new ModuleAdmin();
\ No newline at end of file
Modified: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/building.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/building.php 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/building.php 2013-04-09 19:37:20 UTC (rev 11367)
@@ -67,10 +67,9 @@
$fields_arr = $fieldsHandler->getAll($criteria);
unset($criteria);
-echo $adminMenu->addNavigation('building.php');
switch ($op) {
case 'build':
-
+ xoops_cp_header();
//Remove the new module directory if it exists
TDMCreate_clearDir($modPath.'/repository/'.$mod_name);
@@ -209,6 +208,10 @@
case 'default':
default:
+
+ xoops_cp_header();
+
+ echo $adminMenu->addNavigation('building.php');
$mod_arr = $modulesHandler->getall();
$numrowsmod = count( $mod_arr );
// Redirect if there aren't modules
Modified: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/fields.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/fields.php 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/fields.php 2013-04-09 19:37:20 UTC (rev 11367)
@@ -31,14 +31,16 @@
{
case 'list':
default:
+ xoops_cp_header();
echo $adminMenu->addNavigation('fields.php');
- $adminMenu->addItemButton(_AM_TDMCREATE_NEWTABLE, 'tables.php?op=new', 'add');
- $adminMenu->addItemButton(_AM_TDMCREATE_TABLESLIST, 'tables.php', 'list');
+ $adminMenu->addItemButton(_AM_TDMCREATE_ADD_TABLE, 'tables.php?op=new', 'add');
+ $adminMenu->addItemButton(_AM_TDMCREATE_TABLES_LIST, 'tables.php', 'list');
echo $adminMenu->renderButton();
echo '<div class="center errorMsg">Add, Edit or List View in Tables</div><br />';
break;
case 'new':
+ xoops_cp_header();
echo $adminMenu->addNavigation('fields.php');
$obj =& $fieldsHandler->create();
$form = $obj->getForm($table_id, $table_mid, $table_nbfields, $table_fieldname);
@@ -75,7 +77,8 @@
$form->display();
break;
- case 'edit':
+ case 'edit':
+ xoops_cp_header();
echo $adminMenu->addNavigation('fields.php');
$obj = $fieldsHandler->get($field_id);
$form = $obj->getForm($table_id, $table_mid, $table_nbfields, $table_fieldname);
Modified: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/index.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/index.php 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/index.php 2013-04-09 19:37:20 UTC (rev 11367)
@@ -19,6 +19,7 @@
* @version $Id: 1.59 index.php 11297 2013-03-24 10:58:10Z timgno $
*/
include "admin_header.php";
+xoops_cp_header();
//count "total modules"
$count_mods = $modulesHandler->getCount();
//count "total tables"
Modified: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/modules.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/modules.php 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/modules.php 2013-04-09 19:37:20 UTC (rev 11367)
@@ -21,121 +21,69 @@
include 'admin_header.php';
// Recovered the value of the argument op in the URL $
$op = TDMCreate_CleanVars($_REQUEST, 'op', 'list', 'string');
+
switch ($op)
{
case 'list':
- default:
- echo $adminMenu->addNavigation('modules.php');
- $adminMenu->addItemButton(_AM_TDMCREATE_NEWMODULE, 'modules.php?op=new', 'add');
- echo $adminMenu->renderButton();
+ default:
+ $limit = $GLOBALS['xoopsModuleConfig']['adminperpage'];
+ $start = TDMCreate_CleanVars($_REQUEST, 'start', 0);
+ // Define main template
+ $xoopsOption['template_main'] = 'tdmcreate_modules.html';
+ xoops_cp_header();
+ $xoopsTpl->assign('navigation', $adminMenu->addNavigation('modules.php'));
+ $adminMenu->addItemButton(_AM_TDMCREATE_ADD_MODULE, 'modules.php?op=new', 'add');
+ $xoopsTpl->assign('button_new', $adminMenu->renderButton());
+ $xoopsTpl->assign('tdmc_upload_url', TDMC_UPLOAD_URL);
$criteria = new CriteriaCompo();
$criteria->setSort('mod_id ASC, mod_name');
$criteria->setOrder('ASC');
- $numrows = $modulesHandler->getCount();
- if (isset($_REQUEST['limit'])) {
- $criteria->setLimit($_REQUEST['limit']);
- $limit = $_REQUEST['limit'];
- } else {
- $criteria->setLimit($GLOBALS['xoopsModuleConfig']['adminperpage']);
- $limit = $GLOBALS['xoopsModuleConfig']['adminperpage'];
- }
- if (isset($_REQUEST['start'])) {
- $criteria->setStart($_REQUEST['start']);
- $start = $_REQUEST['start'];
- } else {
- $criteria->setStart(0);
- $start = 0;
- }
- $mods_arr = $modulesHandler->getall($criteria);
- if ( $numrows > $limit ) {
- include_once XOOPS_ROOT_PATH . '/class/pagenav.php';
- $pagenav = new XoopsPageNav($numrows, $limit, $start, 'start', 'op=list&limit=' . $limit);
- $pagenav = $pagenav->renderNav(4);
- } else {
- $pagenav = '';
- }
- //Display modules list
+ $numrows = $modulesHandler->getCount();
+ $mods_arr = $modulesHandler->getAll( $criteria );
+ unset($criteria);
+ // Display modules list
if ($numrows>0)
{
$yes = "<img src='../images/icons/16/green.png' alt='"._YES."' title='"._YES."' />";
- $no = "<img src='../images/icons/16/red.png' alt='"._NO."' title='"._NO."' />";
- echo "<table width='100%' cellspacing='1' class='outer'>
- <tr>
- <th class='center'>"._AM_TDMCREATE_MODULE_ID."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_NAME."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_VERSION."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_IMAGE."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_RELEASE."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_STATUS."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_ADMIN_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_USER_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_SUBMENU_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_SEARCH_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_COMMENTS_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_NOTIFICATIONS_LIST."</th>
- <th class='center' width='5%'>"._AM_TDMCREATE_FORMACTION."</th>
- </tr>";
- $class = "odd";
+ $no = "<img src='../images/icons/16/red.png' alt='"._NO."' title='"._NO."' />";
foreach (array_keys($mods_arr) as $i)
- {
- echo "<tr class='".$class."'>";
- $class = ($class == "even") ? "odd" : "even";
- echo "<td class='center'>".$i."</td>";
- echo "<td class='center'>".$mods_arr[$i]->getVar('mod_name')."</td>";
- echo "<td class='center'>".$mods_arr[$i]->getVar('mod_version')."</td>";
- echo "<td class='center'><img src='".TDMC_UPLOAD_URL."/images/modules/".$mods_arr[$i]->getVar('mod_image')."' height='30px' title='mod_image' alt='mod_image'></td>";
- echo "<td class='center'>".$mods_arr[$i]->getVar('mod_release')."</td>";
- echo "<td class='center'>".$mods_arr[$i]->getVar('mod_status')."</td>";
-
- $verif_mod_admin = ( $mods_arr[$i]->getVar('mod_admin') == 1 ) ? $yes : $no;
- echo "<td class='center'>".$verif_mod_admin."</td>";
- $verif_mod_user = ( $mods_arr[$i]->getVar('mod_user') == 1 ) ? $yes : $no;
- echo "<td class='center'>".$verif_mod_user."</td>";
- $verif_mod_submenu = ( $mods_arr[$i]->getVar('mod_submenu') == 1 ) ? $yes : $no;
- echo "<td class='center'>".$verif_mod_submenu."</td>";
- $verif_mod_search = ( $mods_arr[$i]->getVar('mod_search') == 1 ) ? $yes : $no;
- echo "<td class='center'>".$verif_mod_search."</td>";
- $verif_mod_comments = ( $mods_arr[$i]->getVar('mod_comments') == 1 ) ? $yes : $no;
- echo "<td class='center'>".$verif_mod_comments."</td>";
- $verif_mod_notifications = ( $mods_arr[$i]->getVar('mod_notifications') == 1 ) ? $yes : $no;
- echo "<td class='center'>".$verif_mod_notifications."</td>";
-
- echo "<td class='center' width='5%'>
- <a href='modules.php?op=edit&mod_id=".$i."'><img src='".$pathIcon16."/edit.png' alt='"._EDIT."' title='"._EDIT."'></a>
- <a href='modules.php?op=delete&mod_id=".$i."'><img src='".$pathIcon16."/delete.png' alt='"._DELETE."' title='"._DELETE."'></a>
- </td>";
- echo "</tr>";
+ {
+ $mod['mod_id'] = $i;
+ $mod['mod_name'] = $mods_arr[$i]->getVar('mod_name');
+ $mod['mod_version'] = $mods_arr[$i]->getVar('mod_version');
+ $mod['mod_image'] = $mods_arr[$i]->getVar('mod_image');
+ $mod['mod_release'] = $mods_arr[$i]->getVar('mod_release');
+ $mod['mod_status'] = $mods_arr[$i]->getVar('mod_status');
+ $mod['mod_admin'] = ( $mods_arr[$i]->getVar('mod_admin') == 1 ) ? $yes : $no;
+ $mod['mod_user'] = ( $mods_arr[$i]->getVar('mod_user') == 1 ) ? $yes : $no;
+ $mod['mod_submenu'] = ( $mods_arr[$i]->getVar('mod_submenu') == 1 ) ? $yes : $no;
+ $mod['mod_search'] = ( $mods_arr[$i]->getVar('mod_search') == 1 ) ? $yes : $no;
+ $mod['mod_comments'] = ( $mods_arr[$i]->getVar('mod_comments') == 1 ) ? $yes : $no;
+ $mod['mod_notifications'] = ( $mods_arr[$i]->getVar('mod_notifications') == 1 ) ? $yes : $no;
+ $xoopsTpl->append('modules_list', $mod);
+ unset($mod);
}
- echo "</table><br><br>";
- echo "<div class='center'>".$pagenav."</div>";
+ if ( $numrows > $limit ) {
+ include_once XOOPS_ROOT_PATH . '/class/pagenav.php';
+ $pagenav = new XoopsPageNav($numrows, $limit, $start, 'start', 'op=list&limit=' . $limit);
+ $xoopsTpl->assign('pagenav', $pagenav->renderNav(4));
+ }
} else {
- echo "<table width='100%' cellspacing='1' class='outer'>
- <tr>
- <th class='center'>"._AM_TDMCREATE_MODULE_NAME."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_VERSION."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_IMAGE."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_RELEASE."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_STATUS."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_ADMIN_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_USER_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_SUBMENU_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_SEARCH_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_COMMENTS_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_NOTIFICATIONS_LIST."</th>
- <th class='center' width='5%'>"._AM_TDMCREATE_FORMACTION."</th>
- </tr><tr><td class='errorMsg' colspan='12'>No Modules</td></tr>";
- echo "</table><br><br>";
- }
+ $xoopsTpl->assign('error', 'There aren\'t modules');
+ }
break;
- case 'new':
- echo $adminMenu->addNavigation('modules.php');
- $adminMenu->addItemButton(_AM_TDMCREATE_MODULESLIST, 'modules.php', 'list');
- echo $adminMenu->renderButton();
-
+ case 'new':
+ // Define main template
+ $xoopsOption['template_main'] = 'tdmcreate_modules.html';
+ xoops_cp_header();
+ $xoopsTpl->assign('navigation', $adminMenu->addNavigation('modules.php'));
+ $adminMenu->addItemButton(_AM_TDMCREATE_MODULES_LIST, 'modules.php', 'list');
+ $xoopsTpl->assign('button_list', $adminMenu->renderButton());
+
$obj =& $modulesHandler->create();
- $form = $obj->getForm();
- $form->display();
+ $form = $obj->getForm();
+ $xoopsTpl->assign('form', $form->render());
break;
case 'save':
@@ -162,7 +110,7 @@
$uploader = new XoopsMediaUploader($uploaddir, $GLOBALS['xoopsModuleConfig']['mimetypes'],
$GLOBALS['xoopsModuleConfig']['maxsize'], null, null);
if ($uploader->fetchMedia($_POST['xoops_upload_file'][0])) {
- $extension = preg_replace( '/^.+\.([^.]+)$/sU' , '\\1' , $_FILES['mod_image']['name']);
+ $extension = preg_replace( '/^.+\.([^.]+)$/sU' , '\\1' , $_FILES['attaccedFile']['name']);
$name_img = $_GET['mod_name'].'_slogo.'.$extension;
$uploader->setPrefix($name_img);
$uploader->fetchMedia($_POST['xoops_upload_file'][0]);
@@ -194,19 +142,24 @@
redirect_header('modules.php', 2, _AM_TDMCREATE_FORMOK);
}
- echo $obj->getHtmlErrors();
- $form =& $obj->getForm();
- $form->display();
+ $xoopsTpl->assign('error', $obj->getHtmlErrors());
+ $form =& $obj->getForm();
+ $xoopsTpl->assign('form', $form->render());
break;
- case 'edit':
- echo $adminMenu->addNavigation('modules.php');
- $adminMenu->addItemButton(_AM_TDMCREATE_NEWMODULE, 'modules.php?op=new', 'add');
- $adminMenu->addItemButton(_AM_TDMCREATE_MODULESLIST, 'modules.php', 'list');
- echo $adminMenu->renderButton();
+ case 'edit':
+ // Define main template
+ $xoopsOption['template_main'] = 'tdmcreate_modules.html';
+ xoops_cp_header();
+ $xoopsTpl->assign('navigation', $adminMenu->addNavigation('modules.php'));
+ $adminMenu->addItemButton(_AM_TDMCREATE_ADD_MODULE, 'modules.php?op=new', 'add');
+ $adminMenu->addItemButton(_AM_TDMCREATE_MODULES_LIST, 'modules.php', 'list');
+ $xoopsTpl->assign('button_new', $adminMenu->renderButton());
+ $xoopsTpl->assign('button_list', $adminMenu->renderButton());
+
$obj = $modulesHandler->get($_REQUEST['mod_id']);
- $form = $obj->getForm();
- $form->display();
+ $form = $obj->getForm();
+ $xoopsTpl->assign('form', $form->render());
break;
case 'delete':
@@ -218,7 +171,7 @@
if ($modulesHandler->delete($obj)) {
redirect_header('modules.php', 3, _AM_TDMCREATE_FORMDELOK);
} else {
- echo $obj->getHtmlErrors();
+ $xoopsTpl->assign('error', $obj->getHtmlErrors());
}
} else {
xoops_confirm(array('ok' => 1, 'mod_id' => $_REQUEST['mod_id'], 'op' => 'delete'), $_SERVER['REQUEST_URI'], sprintf(_AM_TDMCREATE_FORMSUREDEL, $obj->getVar('mod_name')));
Modified: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/tables.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/tables.php 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/admin/tables.php 2013-04-09 19:37:20 UTC (rev 11367)
@@ -21,13 +21,25 @@
include 'admin_header.php';
// Recovered the value of the argument op in the URL $
$op = TDMCreate_CleanVars($_REQUEST, 'op', 'list', 'string');
+$mod_id = TDMCreate_CleanVars($_REQUEST, 'mod_id', 0);
switch ($op)
{
case 'list':
- default:
- echo $adminMenu->addNavigation('tables.php');
- $adminMenu->addItemButton(_AM_TDMCREATE_NEWTABLE, 'tables.php?op=new', 'add');
- echo $adminMenu->renderButton();
+ default:
+ $limit = $GLOBALS['xoopsModuleConfig']['adminperpage'];
+ $start = TDMCreate_CleanVars($_REQUEST, 'start', 0);
+ // Define main template
+ $xoopsOption['template_main'] = 'tdmcreate_tables.html';
+ xoops_cp_header();
+ $GLOBALS['xoTheme']->addStylesheet( 'modules/TDMCreate/css/style.css' );
+ $GLOBALS['xoTheme']->addScript('modules/TDMCreate/js/functions.js');
+
+ $xoopsTpl->assign('navigation', $adminMenu->addNavigation('tables.php'));
+ $adminMenu->addItemButton(_AM_TDMCREATE_ADD_TABLE, 'tables.php?op=new', 'add');
+ $xoopsTpl->assign('button_new', $adminMenu->renderButton());
+ $xoopsTpl->assign('tdmc_url', TDMC_URL);
+ $xoopsTpl->assign('tdmc_upload_url', TDMC_UPLOAD_URL);
+ $xoopsTpl->assign('pathIcon32', XOOPS_URL.'/Frameworks/moduleclasses/icons/32');
// Get the list of modules
$criteria = new CriteriaCompo();
$criteria->setSort('mod_id ASC, mod_name');
@@ -36,161 +48,80 @@
// Redirect if there aren't modules
if ( $numrows_modules == 0 ) {
redirect_header('modules.php?op=new', 2, _AM_TDMCREATE_NOTMODULES );
- }
- if (isset($_REQUEST['limit'])) {
- $criteria->setLimit($_REQUEST['limit']);
- $limit = $_REQUEST['limit'];
- } else {
- $criteria->setLimit($GLOBALS['xoopsModuleConfig']['adminperpage']);
- $limit = $GLOBALS['xoopsModuleConfig']['adminperpage'];
- }
- if (isset($_REQUEST['start'])) {
- $criteria->setStart($_REQUEST['start']);
- $start = $_REQUEST['start'];
- } else {
- $criteria->setStart(0);
- $start = 0;
- }
+ }
$mods_arr = $modulesHandler->getAll($criteria);
- unset($criteria);
- $xoopsTpl->assign('numrows_modules', $numrows_modules);
- if ( $numrows_modules > $limit ) {
- include_once XOOPS_ROOT_PATH . '/class/pagenav.php';
- $pagenav = new XoopsPageNav($numrows_modules, $limit, $start, 'start', 'op=list&limit=' . $limit);
- $pagenav = $pagenav->renderNav(4);
- } else {
- $pagenav = '';
- }
- // Display the list of modules
+ unset($criteria);
+ // Display modules list
if ( $numrows_modules > 0 )
{
$_yes = "<img src='../images/icons/16/yellow.png' alt='"._YES."' title='"._YES."' />";
- $_no = "<img src='../images/icons/16/red.png' alt='"._NO."' title='"._NO."' />";
- echo "<table width='100%' cellspacing='1' class='outer'>
- <tr>
- <th class='center'>"._AM_TDMCREATE_MODULE_ID."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_NAME."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_IMAGE."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_NBFIELDS."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_BLOCKS."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_ADMIN_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_USER_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_SUBMENU_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_SEARCH_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_COMMENTS_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_NOTIFICATIONS_LIST."</th>
- <th class='center' width='8%'>"._AM_TDMCREATE_FORMACTION."</th>
- </tr>";
- foreach (array_keys($mods_arr) as $m)
- {
- $mods_id = $mods_arr[$m]->getVar('mod_id');
- $mods_name = $mods_arr[$m]->getVar('mod_name');
- $mods_image = $mods_arr[$m]->getVar('mod_image');
- $mods_admin = $mods_arr[$m]->getVar('mod_admin');
- $mods_user = $mods_arr[$m]->getVar('mod_user');
- $mods_submenu = $mods_arr[$m]->getVar('mod_submenu');
- $mods_search = $mods_arr[$m]->getVar('mod_search');
- $mods_comments = $mods_arr[$m]->getVar('mod_comments');
- $mods_notifications = $mods_arr[$m]->getVar('mod_notifications');
- $mods_admin = ($mods_admin == 1) ? $_yes : $_no;
- $mods_user = ($mods_user == 1) ? $_yes : $_no;
- $mods_submenu = ($mods_submenu == 1) ? $_yes : $_no;
- $mods_search = ($mods_search == 1) ? $_yes : $_no;
- $mods_comments = ($mods_comments == 1) ? $_yes : $_no;
- $mods_notifications = ($mods_notifications == 1) ? $_yes : $_no;
- echo "<tr class='odd'>";
- echo "<td class='center'>".$m."</td>";
- echo "<td class='left'><img src='../images/icons/arrow.gif' /> <b>".$mods_name."</b></td>";
- echo "<td class='center'><img src='".TDMC_UPLOAD_URL."/images/modules/".$mods_image."' height='30px'></td>";
- echo "<td class='center'><img src='../images/icons/16/nb_fields.png' /></td>";
- echo "<td class='center'><img src='../images/icons/16/blocks.png' /></td>";
- echo "<td class='center'>".$mods_admin."</td>";
- echo "<td class='center'>".$mods_user."</td>";
- echo "<td class='center'>".$mods_submenu."</td>";
- echo "<td class='center'>".$mods_search."</td>";
- echo "<td class='center'>".$mods_comments."</td>";
- echo "<td class='center'>".$mods_notifications."</td>";
- echo "<td class='center'>";
- echo "<a href='modules.php?op=edit&mod_id=".$m."'><img src='". $pathIcon16 ."/edit.png' alt='"._EDIT."' title='"._EDIT."'></a> <a href='modules.php?op=delete&mod_id=".$m."'><img src='". $pathIcon16 ."/delete.png' alt='"._DELETE."' title='"._DELETE."'></a>";
- echo "</td>";
- echo "</tr>";
+ $_no = "<img src='../images/icons/16/red.png' alt='"._NO."' title='"._NO."' />";
+ foreach (array_keys($mods_arr) as $i)
+ {
+ $mod['id'] = $i;
+ $mod['name'] = $mods_arr[$i]->getVar('mod_name');
+ $mod['image'] = $mods_arr[$i]->getVar('mod_image');
+ $mod['admin'] = ( $mods_arr[$i]->getVar('mod_admin') == 1 ) ? $_yes : $_no;
+ $mod['user'] = ( $mods_arr[$i]->getVar('mod_user') == 1 ) ? $_yes : $_no;
+ $mod['submenu'] = ( $mods_arr[$i]->getVar('mod_submenu') == 1 ) ? $_yes : $_no;
+ $mod['search'] = ( $mods_arr[$i]->getVar('mod_search') == 1 ) ? $_yes : $_no;
+ $mod['comments'] = ( $mods_arr[$i]->getVar('mod_comments') == 1 ) ? $_yes : $_no;
+ $mod['notifications'] = ( $mods_arr[$i]->getVar('mod_notifications') == 1 ) ? $_yes : $_no;
+ $xoopsTpl->append_by_ref('modules_list', $mod);
+ unset($mod);
// Get the list of tables
$criteria = new CriteriaCompo();
- $criteria->add(new Criteria('table_mid', $mods_id));
+ $criteria->add(new Criteria('table_mid', $i));
$criteria->setSort('table_id ASC, table_name');
- $criteria->setOrder('ASC');
+ $criteria->setOrder('ASC');
$numrows_tables = $tablesHandler->getCount();
- $tables_arr = $tablesHandler->getall($criteria);
- unset($criteria);
- // Display the list of tables
+ $tables_arr = $tablesHandler->getAll($criteria);
+ unset($criteria);
+ // Display tables list
if ( $numrows_tables > 0 )
{
- $_yes = "<img src='../images/icons/16/green.png' alt='"._YES."' title='"._YES."' />";
+ $_yes = "<img src='../images/icons/16/green.png' alt='"._YES."' title='"._YES."' />";
foreach (array_keys($tables_arr) as $t)
{
- echo "<tr class='even'>";
- echo "<td class='center'>".$t."</td>";
- echo "<td class='left'><img src='../images/icons/arrow.gif' /> ".$tables_arr[$t]->getVar('table_name')."</td>";
- $table_image = $tables_arr[$t]->getVar('table_image');
- if(!is_dir($pathIcon32)){
- echo "<td class='center'><img src='".$pathIcon32."/".$table_image."' height='20px'></td>";
- }else{
- echo "<td class='center'><img src='".TDMC_UPLOAD_URL."/images/tables/".$table_image."' height='20px'></td>";
- }
- echo "<td class='center'>".$tables_arr[$t]->getVar('table_nbfields')."</td>";
-
- $verif_table_blocks = ( $tables_arr[$t]->getVar('table_blocks') == 1 ) ? $_yes : $_no;
- echo "<td class='center'>".$verif_table_blocks."</td>";
- $verif_table_admin = ( $tables_arr[$t]->getVar('table_admin') == 1 ) ? $_yes : $_no;
- echo "<td class='center'>".$verif_table_admin."</td>";
- $verif_table_user = ( $tables_arr[$t]->getVar('table_user') == 1 ) ? $_yes : $_no;
- echo "<td class='center'>".$verif_table_user."</td>";
- $verif_table_submenu = ( $tables_arr[$t]->getVar('table_submenu') == 1 ) ? $_yes : $_no;
- echo "<td class='center'>".$verif_table_submenu."</td>";
- $verif_table_search = ( $tables_arr[$t]->getVar('table_search') == 1 ) ? $_yes : $_no;
- echo "<td class='center'>".$verif_table_search."</td>";
- $verif_table_comments = ( $tables_arr[$t]->getVar('table_comments') == 1 ) ? $_yes : $_no;
- echo "<td class='center'>".$verif_table_comments."</td>";
- $verif_table_notify = ( $tables_arr[$t]->getVar('table_notifications') == 1 ) ? $_yes : $_no;
- echo "<td class='center'>".$verif_table_notify."</td>";
-
- echo "<td class='center' width='8%'>
- <a href='tables.php?op=edit&table_id=".$t."'><img src='".$pathIcon16."/edit.png' alt='"._EDIT."' title='"._EDIT."'></a>
- <a href='fields.php?op=edit&field_tid=".$t."'><img src='../images/icons/16/editfields.png' alt='"._AM_TDMCREATE_FIELD_EDIT."' title='"._AM_TDMCREATE_FIELD_EDIT."'></a>
- <a href='tables.php?op=delete&table_id=".$t."'><img src='".$pathIcon16."/delete.png' alt='"._DELETE."' title='"._DELETE."'></a>
- </td>";
- echo "</tr>";
+ $table['id'] = $t;
+ $table['mid'] = $tables_arr[$t]->getVar('table_mid');
+ $table['name'] = $tables_arr[$t]->getVar('table_name');
+ $table['image'] = $tables_arr[$t]->getVar('table_image');
+ $table['nbfields'] = $tables_arr[$t]->getVar('table_nbfields');
+ $table['blocks'] = ( $tables_arr[$t]->getVar('table_blocks') == 1 ) ? $_yes : $_no;
+ $table['admin'] = ( $tables_arr[$t]->getVar('mod_admin') == 1 ) ? $_yes : $_no;
+ $table['user'] = ( $tables_arr[$t]->getVar('mod_user') == 1 ) ? $_yes : $_no;
+ $table['submenu'] = ( $tables_arr[$t]->getVar('mod_submenu') == 1 ) ? $_yes : $_no;
+ $table['search'] = ( $tables_arr[$t]->getVar('mod_search') == 1 ) ? $_yes : $_no;
+ $table['comments'] = ( $tables_arr[$t]->getVar('mod_comments') == 1 ) ? $_yes : $_no;
+ $table['notifications'] = ( $tables_arr[$t]->getVar('mod_notifications') == 1 ) ? $_yes : $_no;
+ $xoopsTpl->append_by_ref('tables_list', $table);
+ unset($table);
}
- }
- }
- echo "</table><br /><br />";
- echo "<div class='center'>".$pagenav."</div>";
+ }
+ }
+
+ if ( $numrows_modules > $limit ) {
+ include_once XOOPS_ROOT_PATH . '/class/pagenav.php';
+ $pagenav = new XoopsPageNav($numrows_modules, $limit, $start, 'start', 'op=list&limit=' . $limit);
+ $xoopsTpl->assign('pagenav', $pagenav->renderNav(4));
+ }
} else {
- echo "<table width='100%' cellspacing='1' class='outer'>
- <tr>
- <th class='center'>"._AM_TDMCREATE_MODULE_NAME."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_IMAGE."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_NBFIEDS."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_BLOCKS."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_ADMIN_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_USER_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_SUBMENU_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_SEARCH_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_COMMENTS_LIST."</th>
- <th class='center'>"._AM_TDMCREATE_MODULE_NOTIFICATIONS_LIST."</th>
- <th class='center' width='8%'>"._AM_TDMCREATE_FORMACTION."</th>
- </tr><tr><td class='errorMsg' colspan='14'>No tables</td></tr>";
- echo "</table><br><br>";
- }
+ $xoopsTpl->assign('error', 'There aren\'t modules');
+ }
break;
- case 'new':
- echo $adminMenu->addNavigation('tables.php');
- $adminMenu->addItemButton(_AM_TDMCREATE_TABLESLIST, 'tables.php', 'list');
- echo $adminMenu->renderButton();
+ case 'new':
+ // Define main template
+ $xoopsOption['template_main'] = 'tdmcreate_tables.html';
+ xoops_cp_header();
+ $xoopsTpl->assign('navigation', $adminMenu->addNavigation('tables.php'));
+ $adminMenu->addItemButton(_AM_TDMCREATE_TABLES_LIST, 'tables.php', 'list');
+ $xoopsTpl->assign('button_new', $adminMenu->renderButton());
+
$obj =& $tablesHandler->create();
$form = $obj->getForm();
- $form->display();
+ $xoopsTpl->assign('form', $form->render());
break;
case 'save':
@@ -250,19 +181,24 @@
}
}
- echo $obj->getHtmlErrors();
+ $xoopsTpl->assign('error', $obj->getHtmlErrors());
$form = $obj->getForm();
- $form->display();
+ $xoopsTpl->assign('form', $form->render());
break;
- case 'edit':
- echo $adminMenu->addNavigation('tables.php');
- $adminMenu->addItemButton(_AM_TDMCREATE_NEWTABLE, 'tables.php?op=new', 'add');
- $adminMenu->addItemButton(_AM_TDMCREATE_TABLESLIST, 'tables.php', 'list');
- echo $adminMenu->renderButton();
+ case 'edit':
+ // Define main template
+ $xoopsOption['template_main'] = 'tdmcreate_tables.html';
+ xoops_cp_header();
+ $xoopsTpl->assign('navigation', $adminMenu->addNavigation('tables.php'));
+ $adminMenu->addItemButton(_AM_TDMCREATE_ADD_TABLE, 'tables.php?op=new', 'add');
+ $adminMenu->addItemButton(_AM_TDMCREATE_TABLES_LIST, 'tables.php', 'list');
+ $xoopsTpl->assign('button_new', $adminMenu->renderButton());
+ $xoopsTpl->assign('button_list', $adminMenu->renderButton());
+
$obj = $tablesHandler->get($_REQUEST['table_id']);
$form = $obj->getForm();
- $form->display();
+ $xoopsTpl->assign('form', $form->render());
break;
case 'delete':
Modified: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/class/tdmcreate_modules.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/class/tdmcreate_modules.php 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/class/tdmcreate_modules.php 2013-04-09 19:37:20 UTC (rev 11367)
@@ -91,30 +91,30 @@
$form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULE_AUTHOR, 'mod_author', 50, 255, $this->getVar('mod_author')), true);
$form->addElement(new XoopsFormText(_AM_TDMCREATE_MODULE_LICENSE, 'mod_license', 50, 255, $this->getVar('mod_license')), true);
$option_tray = new XoopsFormElementTray(_OPTIONS, '<br />');
- $mod_display_admin = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['admin'] : $this->getVar('mod_admin');
- $check_mod_display_admin = new XoopsFormCheckBox(' ', 'mod_admin', $mod_display_admin);
- $check_mod_display_admin->addOption(1, _AM_TDMCREATE_MODULE_ADMIN);
- $option_tray->addElement($check_mod_display_admin);
- $mod_display_user = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['user'] : $this->getVar('mod_user');
- $check_mod_display_user = new XoopsFormCheckBox(' ', 'mod_user', $mod_display_user);
- $check_mod_display_user->addOption(1, _AM_TDMCREATE_MODULE_USER);
- $option_tray->addElement($check_mod_display_user);
- $mod_display_submenu = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['submenu'] : $this->getVar('mod_submenu');
- $check_mod_display_submenu = new XoopsFormCheckBox(' ', 'mod_submenu', $mod_display_submenu);
- $check_mod_display_submenu->addOption(1, _AM_TDMCREATE_MODULE_SUBMENU);
- $option_tray->addElement($check_mod_display_submenu);
- $mod_active_search = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['search'] : $this->getVar('mod_search');
- $check_mod_active_search = new XoopsFormCheckBox(' ', 'mod_search', $mod_active_search);
- $check_mod_active_search->addOption(1, _AM_TDMCREATE_MODULE_SEARCH);
- $option_tray->addElement($check_mod_active_search);
- $mod_active_comments = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['comments'] : $this->getVar('mod_comments');
- $check_mod_active_comments = new XoopsFormCheckBox(' ', 'mod_comments', $mod_active_comments);
- $check_mod_active_comments->addOption(1, _AM_TDMCREATE_MODULE_COMMENTS);
- $option_tray->addElement($check_mod_active_comments);
- $mod_active_notifies = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['notifications'] : $this->getVar('mod_notifications');
- $check_mod_active_notifies = new XoopsFormCheckBox(' ', 'mod_notifications', $mod_active_notifies);
- $check_mod_active_notifies->addOption(1, _AM_TDMCREATE_MODULE_NOTIFICATIONS);
- $option_tray->addElement($check_mod_active_notifies);
+ $mod_admin = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['admin'] : $this->getVar('mod_admin');
+ $check_mod_admin = new XoopsFormCheckBox(' ', 'mod_admin', $mod_admin);
+ $check_mod_admin->addOption(1, _AM_TDMCREATE_MODULE_ADMIN);
+ $option_tray->addElement($check_mod_admin);
+ $mod_user = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['user'] : $this->getVar('mod_user');
+ $check_mod_user = new XoopsFormCheckBox(' ', 'mod_user', $mod_user);
+ $check_mod_user->addOption(1, _AM_TDMCREATE_MODULE_USER);
+ $option_tray->addElement($check_mod_user);
+ $mod_submenu = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['submenu'] : $this->getVar('mod_submenu');
+ $check_mod_submenu = new XoopsFormCheckBox(' ', 'mod_submenu', $mod_submenu);
+ $check_mod_submenu->addOption(1, _AM_TDMCREATE_MODULE_SUBMENU);
+ $option_tray->addElement($check_mod_submenu);
+ $mod_search = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['search'] : $this->getVar('mod_search');
+ $check_mod_search = new XoopsFormCheckBox(' ', 'mod_search', $mod_search);
+ $check_mod_search->addOption(1, _AM_TDMCREATE_MODULE_SEARCH);
+ $option_tray->addElement($check_mod_search);
+ $mod_comments = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['comments'] : $this->getVar('mod_comments');
+ $check_mod_comments = new XoopsFormCheckBox(' ', 'mod_comments', $mod_comments);
+ $check_mod_comments->addOption(1, _AM_TDMCREATE_MODULE_COMMENTS);
+ $option_tray->addElement($check_mod_comments);
+ $mod_notifies = $this->isNew() ? $GLOBALS['xoopsModuleConfig']['notifications'] : $this->getVar('mod_notifications');
+ $check_mod_notifies = new XoopsFormCheckBox(' ', 'mod_notifications', $mod_notifies);
+ $check_mod_notifies->addOption(1, _AM_TDMCREATE_MODULE_NOTIFICATIONS);
+ $option_tray->addElement($check_mod_notifies);
$form->addElement($option_tray);
$mod_image = $this->getVar('mod_image') ? $this->getVar('mod_image') : 'default_slogo.png';
@@ -130,7 +130,7 @@
$imgtray1->addElement($imageselect1);
$imgtray1->addElement( new XoopsFormLabel( '', "<br /><img src='".XOOPS_URL."/".$uploadir."/".$mod_image."' name='image1' id='image1' alt='' />" ) );
$fileseltray1 = new XoopsFormElementTray('','<br />');
- $fileseltray1->addElement(new XoopsFormFile(_AM_TDMCREATE_FORMUPLOAD , 'mod_image', $GLOBALS['xoopsModuleConfig']['maxsize']));
+ $fileseltray1->addElement(new XoopsFormFile(_AM_TDMCREATE_FORMUPLOAD , 'attaccedFile', $GLOBALS['xoopsModuleConfig']['maxsize']));
$fileseltray1->addElement(new XoopsFormLabel(''));
$imgtray1->addElement($fileseltray1);
$form->addElement($imgtray1);
Deleted: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/css/admin.css
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/css/admin.css 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/css/admin.css 2013-04-09 19:37:20 UTC (rev 11367)
@@ -1,213 +0,0 @@
-@charset "UTF-8";
-/**
- * MyLinks module
- *
- * You may not change or alter any portion of this comment or credits
- * of supporting developers from this source code or any supporting source code
- * which is considered copyrighted (c) material of the original comment or credit authors.
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
- *
- * @copyright:: The XOOPS Project http://sourceforge.net/projects/xoops/
- * @license:: http://www.fsf.org/copyleft/gpl.html GNU public license
- * @package:: mylinks
- * @since:: 2.5.0
- * @author: kris <http://www.xoofoo.org>
- * @version:: $Id $
-**/
-#Slideshow_Title {
- font-size: 20px;
- color: #393e41;
- height: 50px;
- border-bottom: 1px solid #393e41;
- margin-bottom: 5px;
- line-height: 50px;
- background-position: left top;
- background-repeat: no-repeat;
- /*text-shadow: 0 1px 0 #eee,
- 0 2px 0 #e9e9e9,
- 0 3px 0 #ddd,
- 0 4px 0 #d9d9d9,
- 0 5px 0 #ccc,
- 0 6px 1px rgba(0,0,0,.1),
- 0 0 5px rgba(0,0,0,.1),
- 0 1px 3px rgba(0,0,0,.3),
- 0 3px 5px rgba(0,0,0,.2),
- 0 5px 10px rgba(0,0,0,.35),
- 0 10px 10px rgba(0,0,0,.2);*/
-}
-.Slideshow_MediumTitle {
- font-size: 14px;
- color: #393e41;
- /*text-shadow: 0 1px 0 #eee,
- 0 2px 0 #e9e9e9,
- 0 3px 0 #ddd,
- 0 4px 0 #d9d9d9,
- 0 5px 0 #ccc,
- 0 6px 1px rgba(0,0,0,.1),
- 0 0 5px rgba(0,0,0,.1),
- 0 1px 3px rgba(0,0,0,.3),
- 0 3px 5px rgba(0,0,0,.2),
- 0 5px 10px rgba(0,0,0,.35),
- 0 10px 10px rgba(0,0,0,.2);*/
-}
-/* Index page */
-#Slideshow_Index {
- float: left;
- padding: 0 0 0 60px;
- background-image: url(../images/admin/index.png);
- background-position: left top;
- background-repeat: no-repeat;
-}
-/* Help page */
-#Slideshow_Help {
- float: left;
- padding: 0 0 0 60px;
- background-image: url(../images/admin/help.png);
- background-position: left top;
- background-repeat: no-repeat;
-}
-/* About page */
-#Slideshow_About {
- float: left;
- padding: 0 0 0 60px;
- background-image: url(../images/admin/about.png);
- background-position: left top;
- background-repeat: no-repeat;
-}
-#about fieldset {
- margin: 10px;
- padding: 5px;
-}
-#about legend {
- margin: 0 5px;
- padding: 0 5px 8px 5px;
-}
-#about label, #about text {
- display: block;
- float: left;
- margin-bottom: 12px;
-}
-#about label {
- text-align: right;
- width: 200px;
- padding-right: 20px;
-}
-#about br { clear: both;}
-#about .txtchangelog { height:350px; overflow:auto;}
-
-fieldset p { margin-bottom: .5em;}
-
-#myid {}
-
-/* Buttons style */
-.xo-buttons a, .xo-buttons button{
- display:block-inline;
- margin:0 5px 0 0;
- background: #e4e4e5 url('../images/admin/bg_button.gif') repeat-x;
- border:1px solid #d6d6d6;
- border-top:1px solid #dedede;
- border-left:1px solid #dedede;
- font-family:"Lucida Grande", Tahoma, Arial, Verdana, sans-serif;
- font-size:100%;
- line-height:110%;
- text-decoration:none;
- font-weight:bold;
- color:#454545;
- cursor:pointer;
- padding:3px 8px 4px 5px; /* Links */
-}
-.xo-buttons a:hover, .xo-buttons button:hover {
- border:1px solid #ccc;
- border-top:1px solid #d6d6d6;
- border-left:1px solid #d6d6d6;
-}
-.xo-buttons button{
- width:auto;
- overflow:visible;
- padding:3px 8px 4px 5px; /* IE6 */
-}
-.xo-buttons button[type]{
- padding:3px 5px 4px 5px; /* Firefox */
- line-height:15px; /* Safari */
-}
-*:first-child+html button[type]{
- padding:3px 8px 4px 5px; /* IE7 */
-}
-.xo-buttons button img, .xo-buttons a img{
- margin:0 3px -3px 0 !important;
- padding:0;
- border:none;
- width:16px;
- height:16px;
-}
-.ui-corner-all { -moz-border-radius: 5px; -webkit-border-radius: 5px; }
-/* Buttons style */
-
-/* align */
-.floatright{ float:right; margin:0; padding:2px; border:0; }
-.floatleft{ float:left; margin:0; padding:2px; border:0; }
-.aligncenter{ text-align:center; margin:0; padding:2px; border:0; }
-/* align */
-
-/* label */
-.label{font-size: 16px; color: #2F5376; font-weight: bold;}
-
-/* label */
-
-/* menu */
-div.rmmenuicon{
- margin: 3px;
- font-family: Tahoma, Arial, Helvetica;
- text-align: center;
-}
-div.rmmenuicon a {
- display: block; float: left;
- height: 75px !important;
- height: 75px;
- width: 75px !important;
- width: 75px;
- vertical-align: middle;
- text-decoration : none;
- border: 1px solid #CCCCCC;
- padding: 2px 5px 1px 5px;
- margin: 3px;
- color: #666666;
-
- background-color: #f0f0f0;
- -moz-border-radius: 6px;
- -webkit-border-radius: 6px;
- -khtml-border-radius: 6px;
- border-radius: 6px;
-
-
-}
-div.rmmenuicon img { margin-top: 8px; margin-bottom: 8px; }
-div.rmmenuicon a span {
- font-size: 11px;
- font-weight: bold;
- display: block;
-}
-div.rmmenuicon a:hover{
- background-color: #FFF6C1;
- border: 1px solid #FF9900;
- color: #1E90FF;
-}
-div.rmmenuicon a:hover span{
- text-decoration: none;
-}
-
-div.CPbigTitle{
- font-size: 12px;
- color: #606060;
- background: no-repeat left top;
- font-weight: bold;
- height: 30px;
- vertical-align: middle;
- padding: 5px 0 0 40px;
- border-bottom: 1px solid #393e41;
-}
-/* menu */
-
-.txtchangelog { height:350px; overflow:auto;}
Added: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/css/style.css
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/css/style.css (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/css/style.css 2013-04-09 19:37:20 UTC (rev 11367)
@@ -0,0 +1,30 @@
+@charset "UTF-8";
+/*
+ You may not change or alter any portion of this comment or credits
+ of supporting developers from this source code or any supporting source code
+ which is considered copyrighted (c) material of the original comment or credit authors.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+ */
+/**
+ * tdmcreate module
+ *
+ * @copyright The XOOPS Project http://sourceforge.net/projects/xoops/
+ * @license GNU GPL 2 (http://www.gnu.org/licenses/old-licenses/gpl-2.0.html)
+ * @package tdmcreate
+ * @since 2.5.0
+ * @author Txmod Xoops http://www.txmodxoops.org
+ * @version $Id: style.css 11084 2013-02-23 15:44:20Z timgno $
+ */
+
+tr.toggleTables td {
+ /* display: none;*/
+}
+
+.toggleHidden {
+ display: none;
+}
+
+.width6{ width: 6%; }
\ No newline at end of file
Added: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/arrow.gif
===================================================================
(Binary files differ)
Index: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/arrow.gif
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/arrow.gif 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/arrow.gif 2013-04-09 19:37:20 UTC (rev 11367)
Property changes on: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/arrow.gif
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/off.png
===================================================================
(Binary files differ)
Index: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/off.png
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/off.png 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/off.png 2013-04-09 19:37:20 UTC (rev 11367)
Property changes on: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/off.png
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/on.png
===================================================================
(Binary files differ)
Index: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/on.png
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/on.png 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/on.png 2013-04-09 19:37:20 UTC (rev 11367)
Property changes on: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/on.png
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Added: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/toggle.png
===================================================================
(Binary files differ)
Index: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/toggle.png
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/toggle.png 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/toggle.png 2013-04-09 19:37:20 UTC (rev 11367)
Property changes on: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/16/toggle.png
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Deleted: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/arrow.gif
===================================================================
(Binary files differ)
Deleted: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/off.png
===================================================================
(Binary files differ)
Deleted: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/icons/on.png
===================================================================
(Binary files differ)
Modified: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/images/uploads/tables/cat.png
===================================================================
(Binary files differ)
Modified: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/include/common.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/include/common.php 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/include/common.php 2013-04-09 19:37:20 UTC (rev 11367)
@@ -20,7 +20,7 @@
*/
if( ! defined( 'XOOPS_ROOT_PATH' ) ) exit ;
$dirname = $GLOBALS['xoopsModule']->getVar('dirname');
-if(!defined('TDMC_PATH')) define('TDMC_PATH', XOOPS_ROOT_PATH."/modules/" . $dirname );
-if(!defined('TDMC_URL')) define('TDMC_URL', XOOPS_URL."/modules/" . $dirname );
-if(!defined('TDMC_UPLOAD_PATH')) define( 'TDMC_UPLOAD_PATH', XOOPS_UPLOAD_PATH . "/" . $dirname );
-if(!defined('TDMC_UPLOAD_URL')) define( 'TDMC_UPLOAD_URL', XOOPS_UPLOAD_URL . "/" . $dirname );
\ No newline at end of file
+define('TDMC_PATH', XOOPS_ROOT_PATH."/modules/" . $dirname );
+define('TDMC_URL', XOOPS_URL."/modules/" . $dirname );
+define('TDMC_UPLOAD_PATH', XOOPS_UPLOAD_PATH . "/" . $dirname );
+define('TDMC_UPLOAD_URL', XOOPS_UPLOAD_URL . "/" . $dirname );
\ No newline at end of file
Added: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/js/functions.js
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/js/functions.js (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/js/functions.js 2013-04-09 19:37:20 UTC (rev 11367)
@@ -0,0 +1,68 @@
+function addClick(id) {
+ var xhr = getXMLHttpRequest(); // Pour récupérer un objet XMLHTTPRequest
+ // -- bordel habituel (readyState == 4, etc, etc.)
+ xhr.open('GET', 'click.php?id=' + id, true);
+ xhr.send(null);
+}
+
+function getXMLHttpRequest() {
+ var xhr = null;
+
+ if (window.XMLHttpRequest || window.ActiveXObject) {
+ if (window.ActiveXObject) {
+ try {
+ xhr = new ActiveXObject("Msxml2.XMLHTTP");
+ } catch (e) {
+ xhr = new ActiveXObject("Microsoft.XMLHTTP");
+ }
+ } else {
+ xhr = new XMLHttpRequest();
+ }
+ } else {
+ alert("Votre navigateur ne supporte pas l'objet XMLHTTPRequest...");
+ return null;
+ }
+
+ return xhr;
+}
+
+function displayRowClass(tableId, rowClass, Nb) {
+ var table = document.getElementById(tableId);
+ var display = 'none';
+ var ClassName = rowClass + Nb;
+ for (i in table.rows) {
+ row = table.rows[i];
+ if (row.className == ClassName) {
+ if (row.style.display == 'none') {
+ /**Test si c'est IE ou pas*/
+ display = document.all != undefined ? 'block' : 'table-row';
+ } else {
+ display = 'none';
+ }
+ row.style.display = display;
+ }
+ /*
+ if(rowClass == 'child'){
+ if(row.idName == ClassName){
+ row.style.display = 'none';
+ }
+ }*/
+ }
+}
+
+function swapImg(swap) {
+ obj = document.getElementById(swap);
+ obj.src = !(obj.src == img_minus) ? img_minus : img_plus;
+}
+
+$(document).ready( function() {
+ $('.toggleTables').click( function(e) {
+ e.preventDefault();
+ $(this).nextAll('tr').each( function() {
+ if ($(this).is('.toggleTables')) {
+ return false;
+ }
+ $(this).toggle();
+ });
+ });
+});
\ No newline at end of file
Modified: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/js/index.html
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/js/index.html 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/js/index.html 2013-04-09 19:37:20 UTC (rev 11367)
@@ -1 +1 @@
- <script>history.go(-1);</script>
\ No newline at end of file
+<script>history.go(-1);</script>
\ No newline at end of file
Modified: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/language/english/admin.php
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/language/english/admin.php 2013-04-09 05:43:02 UTC (rev 11366)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/language/english/admin.php 2013-04-09 19:37:20 UTC (rev 11367)
@@ -213,10 +213,10 @@
define('_AM_TDMCREATE_ABOUT_WEBSITE_FORUM', "Forum Web Site");
//------------ new additions: Ver. 1.37 -----------------------
-define('_AM_TDMCREATE_MODULESLIST', "Modules List");
-define('_AM_TDMCREATE_NEWMODULE', "New Module");
-define('_AM_TDMCREATE_TABLESLIST', "Tables List");
-define('_AM_TDMCREATE_NEWTABLE', "New Table");
+define('_AM_TDMCREATE_MODULES_LIST', "Modules List");
+define('_AM_TDMCREATE_ADD_MODULE', "New Module");
+define('_AM_TDMCREATE_TABLES_LIST', "Tables List");
+define('_AM_TDMCREATE_ADD_TABLE', "New Table");
//------------ new additions: Ver. 1.38 -----------------------
define('_AM_TDMCREATE_NOTMODULES', "<span class='red bold'>No module created, must create at least one before</span>");
Added: XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/templates/admin/tdmcreate_fields.html
===================================================================
--- XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/templates/admin/tdmcreate_fields.html (rev 0)
+++ XoopsModules/TDMCreate/branches/timgno/1.59/TDMCreate/templates/admin/tdmcreate_fields.html 2013-04-09 19:37:20 UTC (rev 11367)
@@ -0,0 +1,85 @@
+<!-- Header -->
+<{includeq file="db:tdmcreate_header.html"}>
+<!-- Display modules list -->
+<{if $modules_list}>
+ <table width='100%' cellspacing='1' class='outer'>
+ <tr>
+ <th class='center'><{$smarty.const._AM_TDMCREATE_MODULE_ID}></th>
+ <th class='center'><{$smarty.const._AM_TDMCREATE_MODULE_NAME}></th>
+ <th class='center'><{$smarty.const._AM_TDMCREATE_MODULE_IMAGE}></th>
+ <th class='center'><{$smarty.const._AM_TDMCREATE_MODULE_NBFIELDS}></th>
+ <th class='center'><{$smarty.const._AM_TDMCREATE_MODULE_BLOCKS}></th>
+ <th class='center'><{$smarty.const._AM_TDMCREATE_MODULE_ADMIN_LIST}></th>
+ <th class='center'><{$smarty.const._AM_TDMCREATE_MODULE_USER_LIST}></th>
+ <th class='center'><{$smarty.const._AM_TDMCREATE_MODULE_SUBMENU_LIST}></th>
+ <th class='center'><{$smarty.const._AM_TDMCREATE_MODULE_SEARCH_LIST}></th>
+ <th class='center'><{$smarty.const._AM_TDMCREATE_MODULE_COMMENTS_LIST}></th>
+ <th class='center'><{$smarty.const._AM_TDMCREATE_MODULE_NOTIFICATIONS_LIST}></th>
+ <th class='center width5'><{$smarty.const._AM_TDMCREATE_FORMACTION}></th>
+ </tr>
+ <{foreach item=module from=$modules_list}>
+ <tr class="<{cycle values='even,odd'}>">
+ <td class='center'><{$module.mod_id}></td>
+ <td class='center'><{$module.mod_name}></td>
+ <td class='center'><{$module.mod_version}></td>
+ <td class='center'><img src="<{$tdmc_upload_url}>/images/modules/<{$module.mod_image}>" height="32" /></td>
+ <td class='center'><{$module.mod_release}></td>
+ <td class='center'><{$module.mod_status}></td>
+ <td class='center'><{$module.mod_admin}></td>
+ <td class='center'><{$module.mod_user}></td>
+ <td class='center'><{$module.mod_submenu}></td>
+ <td class='center'><{$module.mod_search}></td>
+ <td class='center'><{$module.mod_comments}></td>
+ <td class='center'><{$module.mod_notifications}></td>
+
+ <td class='xo-actions txtcenter width5'>
+ <a href="modules.php?op=edit&mod_id=<{$module.mod_id}>" title="<{$smarty.const._EDIT}>">
+ <img src="<{xoAdminIcons edit.png}>" alt="<{$smarty.const._EDIT}>" height="16" />
+ </a>
+ <a href="modules.php?op=delete&mod_id=<{$module.mod_id}>" title="<{$smarty.const._DELETE}>">
+ <img src="<{xoAdminIcons delete.png}>" alt="<{$smarty.const._DELETE}>" height="16" />
+ </a>
+ </td>
+ </tr>
+ <{foreach item=table from=$tables_list}>
+ <tr class="<{cycle values='even,odd'}>">
+ <td class='center'><{$table.id}></td>
+ <td class='center'><{$table.name}></td>
+ <td class='center'><img src="<{$tdmc_upload_url}>/images/tables/<{$table.image}>" height="32" /></td>
+ <td class='center'><{$table.nbfield}></td>
+ <td class='center'><{$table.blocks}></td>
+ <td class='center'><{$table.admin}></td>
+ <td class='center'><{$table.user}></td>
+ <td class='center'><{$table.submenu}></td>
+ <td class='center'><{$table.search}></td>
+ <td class='center'><{$table.comments}></td>
+ <td class='center'><{$table.notifications}></td>
+ <td class='xo-actions txtcenter width5'>
+ <a href="tables.php?op=edit&table_id=<{$table.id}>" title="<{$smarty.const._EDIT}>">
+ <img src="<{xoAdminIcons edit.png}>" alt="<{$smarty.const._EDIT}>" height="16" />
+ </a>
+ <a href="fields.php?op=edit&field_tid=<{$table.id}>" title="<{$smarty.const._EDIT}>">
+ <img src="<{xoAdminIcons inserttable.png}>" alt="<{$smarty.const._EDIT}>" height="16" />
+ </a>
+ <a href="tables.php?op=delete&table_id=<{$table.id}>" title="<{$smarty.const._DELETE}>">
+ <img src="<{xoAdminIcons delete.png}>" alt="<{$smarty.const._DELETE}>" height="16" />
+ </a>
+ </td>
+ </tr>
+ <{/foreach}>
+ <{/foreach}>
+ </table><br /><br />
+<!-- Display modules navigation -->
+<div class="clear"> </div>
+<{if $pagenav}><div class="xo-pagenav floatright"><{$pagenav}></div><div class="clear spacer"></div><{/if}>
+<{/if}>
+<{if $error}>
+<div class="errorMsg">
+ <strong><{$error}></strong>
+</div>
+<{/if}>
+<!-- Display module form (add,edit) -->
+<{if $form}>
+<div class="spacer"><{$form}></div>
+<{/if}>
+<!-- Display module images on edit page --...
[truncated message content] |