Project

General

Profile

« Previous | Next » 

Revision 1831

Added by Dietmar almost 12 years ago

  1. fixed dragdrop for pages overview

View differences:

index.php
65 65
    $sql .= (PAGE_TRASH != 'inline') ?  'AND `visibility` != \'deleted\' ' : ' ';
66 66
    $sql .= 'ORDER BY `position` ASC';
67 67
	$get_pages = $database->query($sql);
68
	// Work out how many pages there are for this parent
69
	$num_pages = $get_pages->numRows();
68 70

  
69 71
	// Insert values into main page list
70 72
	if($get_pages->numRows() > 0)
71 73
	{
72 74
		while($page = $get_pages->fetchRow())
73 75
		{
76

  
77
			$row   = $row ? 0 : 1;
74 78
			// Get user perms
75 79
			$admin_groups = explode(',', str_replace('_', '', $page['admin_groups']));
76 80
			$admin_users = explode(',', str_replace('_', '', $page['admin_users']));
......
129 133
			} else {
130 134
				$display_plus = false;
131 135
			}
132
			// Work out how many pages there are for this parent
133
			$num_pages = $get_pages->numRows();
134 136

  
135

  
136
			$row   = $row ? 0 : 1;
137

  
138
/*
139
// look and set vars  for first run
140
			$iOldLevel = !isset($iOldLevel) ? $page['level'] : $iOldLevel;
141
			$iOldLevel = $iOldLevel < $page['level'] ? $iOldLevel : $page['level'];
142
// look for new sub
143
			if(!isset($aRowLevel[$page['level']]))
144
			{
145
				$row = !$row ? 0 : $aRowLevel[$iOldLevel];
146
				$aRowLevel[$page['level']] = $row ? $row : 0;
147
				$iOldLevel = $page['level'];
148
// look level before
149
			} elseif($iLevel!=$iOldLevel) {
150
				$aRowLevel[$page['level']] = $aRowLevel[$iOldLevel] ? $aRowLevel[$iOldLevel] : $row ;
151
				$iOldLevel = $page['level'];
152
// normal change
153
			} else {
154
				$aRowLevel[$page['level']] = $aRowLevel[$iLevel] ? $aRowLevel[$iLevel] : $row ;
155
				$iLevel = $page['level'];
156
			}
157
// set and save level
158
			$aRowLevel[$page['level']] = $aRowLevel[$page['level']] ? 0 : 1;
159
// final set $row
160
			$row = $aRowLevel[$page['level']];
161
*/
162 137
			 ?>
163 138
			<li class="p<?php echo $page['parent'];  ?>">
164
			<table summary="<?php echo $TEXT['EXPAND'].'/'.$TEXT['COLLAPSE'];  ?>" class="pages_view" cellpadding="0" cellspacing="0">
139
			<table class="pages_view">
140
            <tbody>
165 141
			<tr class="row_<?php echo $row  ?>">
166 142
				<td valign="middle" width="20" style="padding-left: <?php echo $page['level']==0 ? 0 : ($page['level']*25)-pow($page['level'],2);  ?>px;">
167 143
					<?php
......
321 297
				<?php
322 298
				// end [IC] jeggers 2009/10/14: Add action to add a page as a child
323 299
				 ?>
300
				<td class="list_page_id center">
301
					<?php echo $page['language'];  ?>
302
				</td>
324 303
			</tr>
304
            </tbody>
325 305
			</table>
326 306
			<?php
327 307
			if ( $page['parent'] == 0)
......
343 323
if($admin->get_permission('pages_view') == true) {
344 324
	 ?>
345 325
	<div class="jsadmin hide"></div>
346
	<table summary="<?php echo $HEADING['MODIFY_DELETE_PAGE'];  ?>" cellpadding="0" cellspacing="0" width="100%">
326
	<table>
327
    <tbody>
347 328
	<tr>
348 329
		<td>
349 330
			<h2 class="left"><?php echo $HEADING['MODIFY_DELETE_PAGE'];  ?></h2>
350 331
		</td>
351 332
		<td align="right"></td>
352 333
	</tr>
334
    </tbody>
353 335
	</table>
354 336
	<div class="pages_list">
355
	<table summary="<?php echo $HEADING['MODIFY_DELETE_PAGE'];  ?>" cellpadding="0" cellspacing="0">
337
	<table>
338
    <tbody>
356 339
	<tr class="pages_list_header">
357 340
		<td class="header_list_menu_title">
358 341
			<?php echo $TEXT['VISIBILITY'] .' / ' .$TEXT['MENU_TITLE'];  ?>:
......
366 349
		<td class="header_list_actions">
367 350
			<?php echo $TEXT['ACTIONS'];  ?>:
368 351
		</td>
352
		<td class="list_page_id">
353
		
354
		</td>
369 355
	</tr>
356
    </tbody>
370 357
	</table>
371 358
	<?php
372 359
	// Work-out if we should check for existing page_code

Also available in: Unified diff