Re: [arch-dev-public] Developer reports

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On 30/04/11 08:47, Dan McGee wrote:
> The correct solution to me would be:
> 1. add another custom tablesort ordering; see archweb.js for our
> current listing of them.
> http://projects.archlinux.org/archweb.git/tree/media/archweb.js#n5
> 2. Make the "attribute" template tag itself smarter and always return
> a smartly formatted string rather than the raw attribute value (or
> perhaps make a format_attribute filter or something). hopefully it
> depends more on types than on attribute names for what it does. E.g.
> dates go through the "date" filter, integer fields that end in "size"
> always get filesizeformat treatment, etc. Then the template won't
> change much at all.
> 3. ???
> 4. Profit

Sounds very reasonable. I did however use another solution in place of
(2), and added the formatting to the view. In my opinion, it's simpler
and just as elegant.

Can you please review my patch [1] and see if anything is amiss?

Thanks.

[1]
http://ompldr.org/vOGhtOQ/0001-Add-filesizeformat-filter-to-sizes-in-reports-big.patch


[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux