Sackgesicht VIP
Total posts: 1,636
13 Oct 2012 20:50

1) Add a parameter to allow user to set the TITLE label. Otherwise they have to manually edit the template code to achieve this.

2) Title is the only column which does not have ICON support (icon picker in parameters)

3) TYPE fields will display the icon depending on the field setting. If someone does not like icon display in list template but on the full article template, he can not do it without creating a customized template -- just add a parameter "No icon display for type fields"

4) Display order of TYPE fields in the list. Now it depends on the field order . A parameter field were we can define the order of fields would be of great help. Example a listing of field ID's (24, 36, 18, 12)

With this we could realize a different display order for intro and full view without creating a new customized template.

Last Modified: 02 Mar 2014


Sergey
Total posts: 13,748
16 Oct 2012 21:52

1) Done

2) Done

3) Done

4) That is not really like this. Although you can operate fields by ID we only work with fields by keys to support multiple types in template. You will have to probably create list of keys. I have runed few tests. And since fields is an array it is very hard to resort. There are too many conditions for stable work. Like you have to enter the same amount of keys as there are fields in array. Otherwise you get inconsistency error. But number of fields is not fixed. On som pages some fields may be missing.

SO, I am not sure that there is good way to do it now except custom template.


Sackgesicht VIP
Total posts: 1,636
16 Oct 2012 23:08

1,2,3 --> Cool. :D

Comment to 4)

Maybe a better way to accomplish this than "sorting" would be:

The parameter is a field wich contains the keys in the sorted order.

Loop through the parameter keys and get from the original array the element which matches and copy it to a new array.

Unset the element from original array

after the loop copy the remaining elements to new array.

The result would be an array with all the fields. First the fields indicated in the parameter and then the rest of the fields.

What do you think?


Sergey
Total posts: 13,748
17 Oct 2012 08:07

What do you think?

Possible. But still parameter is for very advanced users. So advanced that usually those are who can easily edit template. :)

I am stil thinking on how to implement it the right way. Because copy/paste field keys does not looks good to me. But it is at least something which is better than nothing. Let me think some more time may be I'll have some idea.


Sackgesicht VIP
Total posts: 1,636
17 Oct 2012 08:09

Easier to use field ID (see original posting) and then the script will get the key.


Sergey
Total posts: 13,748
17 Oct 2012 08:57

and then the script will get the key.

Right! :) There is no difference, we have array to get keys by id :) So it is safe to type IDs. May be this is the better way.


Sackgesicht VIP
Total posts: 1,636
17 Oct 2012 19:45

Another small improvement could be an option to display the title header for a field.

It could be also an ID listing in a parameter field like "23, 27"

Powered by Cobalt