Revision fd0c89ad
Von Sven Schöling vor fast 13 Jahren hinzugefügt
SL/DB/Helper/Paginated.pm | ||
---|---|---|
59 | 59 |
sub calc_visibility { |
60 | 60 |
my ($cur, $max, $this) = @_; |
61 | 61 |
any { $_ } abs($cur - $this) < 5, |
62 |
$cur <= 3,
|
|
63 |
$cur == $max,
|
|
64 |
any { ! abs ($cur - $this) % $_ } 10, 50, 100, 500, 1000, 5000;
|
|
62 |
$this <= 3,
|
|
63 |
$this == $max,
|
|
64 |
any { abs ($cur - $this) == $_ } 10, 50, 100, 500, 1000, 5000;
|
|
65 | 65 |
} |
66 | 66 |
|
67 | 67 |
1; |
Auch abrufbar als: Unified diff
Paginating für sehr große Seiten gefixt.