From: Andrey Kutejko Date: Thu, 18 Jul 2013 21:55:37 +0000 (+0300) Subject: admin: always stretch table X-Git-Tag: 0.5~160 X-Git-Url: https://git.andy128k.dev/?a=commitdiff_plain;h=67e1de3bce17b275ce4f6459e81363a82eeb6824;p=ipf.git admin: always stretch table --- diff --git a/ipf/admin/static/admin/css/changelists.css b/ipf/admin/static/admin/css/changelists.css index 08aed23..eb0106c 100644 --- a/ipf/admin/static/admin/css/changelists.css +++ b/ipf/admin/static/admin/css/changelists.css @@ -1,14 +1,13 @@ /* CHANGELISTS */ #changelist { position:relative; width:100%; } #changelist table { width:100%; } -.change-list .filtered table { border-right:1px solid #ddd; } -.change-list .filtered { min-height:400px; } -.change-list .filtered { background:white url(../img/changelist-bg.gif) top right repeat-y !important; } -.change-list .filtered table, .change-list .filtered .paginator, .filtered #toolbar, .filtered div.xfull { margin-right:200px !important; width:auto !important; } -.change-list .filtered table tbody th { padding-right:1em; } + +.change-list .filtered #items-grid-container { margin-right: 200px; padding-right: 5px; } +.change-list .filtered table, +.change-list .filtered .paginator { border-right:1px solid #ddd; } + #changelist .toplinks { border-bottom:1px solid #ccc !important; } #changelist .paginator { color:#666; border-top:1px solid #eee; border-bottom:1px solid #eee; background:white url(../img/nav-bg.gif) 0 180% repeat-x; overflow:hidden; } -.change-list .filtered .paginator { border-right:1px solid #ddd; } /* CHANGELIST TABLES */ #changelist table thead th { white-space:nowrap; } @@ -22,7 +21,7 @@ #changelist #changelist-search img { vertical-align:middle; } /* FILTER COLUMN */ -#changelist-filter { position:absolute; top:0; right:0; z-index:1000; width:200px; border-left:1px solid #ddd; background:#efefef; margin:0; } +#changelist-filter { float: right; width:200px; border:1px solid #ddd; background:#efefef; margin:0 -1px 0 0; } #changelist-filter h2 { font-size:11px; padding:2px 5px; border-bottom:1px solid #ddd; } #changelist-filter h3 { font-size:12px; margin-bottom:0; } #changelist-filter ul { padding-left:0;margin-left:10px; } diff --git a/ipf/admin/static/admin/img/changelist-bg.gif b/ipf/admin/static/admin/img/changelist-bg.gif deleted file mode 100644 index 7f46994..0000000 Binary files a/ipf/admin/static/admin/img/changelist-bg.gif and /dev/null differ diff --git a/ipf/admin/templates/admin/items.html b/ipf/admin/templates/admin/items.html index 97368be..f1508f9 100644 --- a/ipf/admin/templates/admin/items.html +++ b/ipf/admin/templates/admin/items.html @@ -1,8 +1,8 @@ {extends "admin/base.html"} {block css} - {superblock} - +{superblock} + {/block} {block bodyclass}change-list{/block} @@ -11,67 +11,75 @@ {block content}
-

{$page_title}

-
-
    {block objecttools}{if array_search('add',$perms)!==false}
  • {$title_add}
  • {/if}
  • Print
  • {/block}
-
- - {if $is_search} -
- -
+

{$page_title}

+
+
    + {block objecttools} + {if array_search('add',$perms)!==false}
  • {$title_add}
  • {/if} +
  • Print
  • + {/block} +
+
+ {if $is_search} +
+ +
+ {/if} - {if $filters} -
-

Filter

- {foreach $filters as $f} -

{$f->title}

-
    - {foreach $f->choices as $ch} - {block filterchoice}{$ch['name']}{/block} - {/foreach} -
+ {if $filters} +
+

Filter

+ {foreach $filters as $f} +

{$f->title}

+
    + {foreach $f->choices as $ch} + {block filterchoice}{$ch['name']}{/block} + {/foreach} +
+ {/foreach} +
+ {/if} + +
+ {block table} + + + + {foreach $header as $h} + + {/foreach} + + + + {foreach $objects as $o} + + {foreach $o.ModelAdmin().ListRow($o) as $v} + + {/foreach} + {/foreach} - - {/if} - {block table} -
{$h.title}
{$v|safe}
- - - {foreach $header as $h} - - {/foreach} - - - - {foreach $objects as $o} - - {foreach $o.ModelAdmin().ListRow($o) as $v} - - {/foreach} - - {/foreach} - -
{$h.title}
{$v|safe}
- {/block} -

- {$pager->display()|safe}{$pager->getPager()->getNumResults()} record(s) of {$classname} -

-
+ + + {/block} +

+ {$pager->display()|safe}{$pager->getPager()->getNumResults()} record(s) of {$classname} +

+
+
-
+
+
{/block}