- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-24-2020 05:04 AM
I have a quantity field in a custom table. I create a field style with the table name, field name, no value, and the style of 'text-align: left;'.
In the form, the field aligns left. In the list, it aligns right. I expected both to align left.
If I add the value 'javascript:current.quantity > 0', then the list aligns left, and the form does not. What I would expect from the documentation.
Any guesses as to why the list doesn't align without a 'value' statement?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-24-2020 07:57 AM
this is my analysis
1) by default all list field values are left aligned so you may not differentiate whether the field style is working or not
2) this can be verified by adding text-align:right to the style
I believe there is some bug. I kept the value field empty but it aligned on right only for form but not for list
if we add this in the value then the text-align:right works on list only
So I consider value is required for making it work on list
javascript:1==1
List
Form - not applied
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-24-2020 07:57 AM
this is my analysis
1) by default all list field values are left aligned so you may not differentiate whether the field style is working or not
2) this can be verified by adding text-align:right to the style
I believe there is some bug. I kept the value field empty but it aligned on right only for form but not for list
if we add this in the value then the text-align:right works on list only
So I consider value is required for making it work on list
javascript:1==1
List
Form - not applied
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-24-2020 08:07 AM
Thanks. I would disagree on your statement that all fields align left in a list. For my Paris dev box, integer fields align right. That's what has taken me down this path.
I do agree there is a bug. I like your javascript solution.
I marked as correct for all your help!