Solved

ExtJS - DateTime Format question

Posted on 2012-04-04
2
2,982 Views
Last Modified: 2012-08-14
Hello all,

I have a column model and I am trying to format a Oracle timestamp as shortdate with the time.  My Column Model has the following how do I format it as this:
Example current return in the cell: 2012-04-04 14:54:32.275556

I want to show it just as:  04/04/2012 14:54 for example
{
                  header : "Last Updated",
                  dataIndex : 'modifytime',
                  width: 200,
                  sortable: true,
                  renderer: function renderFoo(value, p, record){
                        return value;
                  }
0
Comment
Question by:sbornstein2
2 Comments
 
LVL 82

Accepted Solution

by:
leakim971 earned 245 total points
ID: 37814985
Try :
{
                  header : "Last Updated",
                  dataIndex : 'modifytime',
                  width: 200,
                  sortable: true,
                  renderer: renderer: Ext.util.Format.dateRenderer('m/d/Y H:i'),

Open in new window


http://www.objis.com/formationextjs/lib/extjs-4.0.0/docs/api/Ext.util.Format.html
0
 

Author Closing Comment

by:sbornstein2
ID: 37817346
thanks
0

Featured Post

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

DOM Attributes and Properties treatment with jQuery 1.6 by Ivo Stoykov jQuery (http://jquery.com/) 1.6 introduces .prop() (http://api.jquery.com/prop/) and .removeProp() (http://api.jquery.com/removeProp/) methods which allow modifying or removi…
Introduction Chart.js, used properly, can visually add a difference to your charting applications. It engages your visitors and allows them to interact with data they otherwise wouldn't be able to without expensive and complicated systems. For this…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

713 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question