PMC-149
This commit is contained in:
committed by
Julio Cesar Laura Avendaño
parent
c95280fe2a
commit
3e7aa8be5b
@@ -438,6 +438,7 @@ class Ajax
|
||||
$oHeadPublisher->addExtJsScript('cases/caseHistory', true); //adding a javascript file .js
|
||||
$oHeadPublisher->addContent('cases/caseHistory'); //adding a html file .html.
|
||||
$oHeadPublisher->assign('pageSize', $conf->getEnvSetting('casesListRowNumber'));
|
||||
$oHeadPublisher->assign('FORMATS', $conf->getFormats());
|
||||
G::RenderPage('publish', 'extJs');
|
||||
}
|
||||
|
||||
|
||||
@@ -212,14 +212,21 @@
|
||||
)
|
||||
});
|
||||
|
||||
|
||||
startDateRender = function(v){
|
||||
var dateString = "-";
|
||||
if(v != "-" && v != null){
|
||||
dateString = _DF(v,"m/d/Y H:i:s");
|
||||
}
|
||||
/**
|
||||
* This applies the date format from the global configuration.
|
||||
* @param {String} value
|
||||
* @return {String}
|
||||
*/
|
||||
startDateRender = function (value) {
|
||||
var dateString,
|
||||
date;
|
||||
dateString = "-";
|
||||
if (value !== "-" && value !== null) {
|
||||
date = convertDate(value);
|
||||
dateString = date.dateFormat(FORMATS.casesListDateFormat);
|
||||
}
|
||||
return dateString;
|
||||
}
|
||||
}
|
||||
|
||||
actionRenderingTranslation = function(v){
|
||||
var actionTranslate = "";
|
||||
|
||||
@@ -545,23 +545,6 @@ Ext.onReady ( function() {
|
||||
return String.format("<a href='#' onclick='unpauseCaseFunction(\"{0}\",\"{1}\")'>" + _('ID_UNPAUSE') + "</a>", r.data['APP_UID'], r.data['DEL_INDEX'] );
|
||||
}
|
||||
|
||||
function convertDate ( value ) {
|
||||
myDate = new Date( 1900,0,1,0,0,0);
|
||||
try{
|
||||
if(!Ext.isDate( value )){
|
||||
var myArray = value.split(' ');
|
||||
var myArrayDate = myArray[0].split('-');
|
||||
if ( myArray.length > 1 )
|
||||
var myArrayHour = myArray[1].split(':');
|
||||
else
|
||||
var myArrayHour = new Array('0','0','0');
|
||||
var myDate = new Date( myArrayDate[0], myArrayDate[1]-1, myArrayDate[2], myArrayHour[0], myArrayHour[1], myArrayHour[2] );
|
||||
}
|
||||
}
|
||||
catch(e){};
|
||||
|
||||
return myDate;
|
||||
}
|
||||
function showDate (value,p,r) {
|
||||
var myDate = convertDate( value );
|
||||
return String.format("{0}", myDate.dateFormat( FORMATS.casesListDateFormat ));
|
||||
|
||||
Reference in New Issue
Block a user