on 06-02-2020 5:30 PM
Hello.
The default option for displaying in the table a field of type DateTime (OData) does not suit me. Is it possible to replace the default format for this value not at the level of each column with a DateTime type, but for the entire table or component? (For example there is a table with more than 50 columns and 15 columns have DataTime type.)
You can use type "Date" and "formatOptions" in your binding to change the format of the date, here an example of a binding:
value="{path: 'datevalue', type: 'sap.ui.model.type.Date', formatOptions: { pattern: 'dd/MM/YYYY' , UTC:true}}"
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello sap.dev.sam
Have a look at this tutorial: https://inui.io/sap-ui5-format-odata-date-time-value/
Or these examples with formatters:
https://answers.sap.com/answers/12229098/view.html
https://stackoverflow.com/questions/23537581/formatting-a-date-from-an-odatamodel-in-a-sapui5-table
Kind regards,
Mateusz
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
74 | |
8 | |
8 | |
8 | |
7 | |
6 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.