PM 798-1 "la descripcióe pmtables..." SOLVED

Code Issue:
La descripcióe pmtables en Audit Log es muy generica.
Solution:
Se coloca el caracter de separacion "," para comprender mejor los mensajes.
This commit is contained in:
Luis Fernando Saisa Lopez
2014-11-07 13:43:52 -04:00
parent 712deb478d
commit e6b882e16e
5 changed files with 18 additions and 11 deletions

View File

@@ -201,7 +201,8 @@ class AdditionalTables extends BaseAdditionalTables
'SHD_DATE' => date('Y-m-d H:i:s'))); 'SHD_DATE' => date('Y-m-d H:i:s')));
*/ */
G::auditLog("CreatePmtable", "PM Table Name: ".$aData['ADD_TAB_NAME']); $addTabDescription = ($aData["ADD_TAB_DESCRIPTION"] != "")? ", Description: " . $aData["ADD_TAB_DESCRIPTION"] : "";
G::auditLog("CreatePmtable", "PM Table Name: " . $aData['ADD_TAB_NAME'] . $addTabDescription);
return $aData['ADD_TAB_UID']; return $aData['ADD_TAB_UID'];
} else { } else {
$sMessage = ''; $sMessage = '';
@@ -228,7 +229,8 @@ class AdditionalTables extends BaseAdditionalTables
$oConnection->begin(); $oConnection->begin();
$iResult = $oAdditionalTables->save(); $iResult = $oAdditionalTables->save();
$oConnection->commit(); $oConnection->commit();
G::auditLog("UpdatePmtable", "PM Table Name: ".$aData['ADD_TAB_NAME']." PM Table ID: (".$aData['ADD_TAB_UID'].") "); $addTabDescription = ($aData["ADD_TAB_DESCRIPTION"] != "")? ", Description: " . $aData["ADD_TAB_DESCRIPTION"] : "";
G::auditLog("UpdatePmtable", "PM Table Name: ".$aData['ADD_TAB_NAME'] . $addTabDescription . ", PM Table ID: (".$aData['ADD_TAB_UID'].") ");
} else { } else {
$sMessage = ''; $sMessage = '';
$aValidationFailures = $oAdditionalTables->getValidationFailures(); $aValidationFailures = $oAdditionalTables->getValidationFailures();

View File

@@ -248,14 +248,15 @@ class CalendarDefinition extends BaseCalendarDefinition
} }
$CalendarWorkDays = isset( $aData['CALENDAR_WORK_DAYS'] ) ? implode( "|", $aData['CALENDAR_WORK_DAYS'] ) : ""; $CalendarWorkDays = isset( $aData['CALENDAR_WORK_DAYS'] ) ? implode( "|", $aData['CALENDAR_WORK_DAYS'] ) : "";
$msgCalendarDescriptionStatus = ($aData["CALENDAR_DESCRIPTION"] != "")? ", Description: " . $aData["CALENDAR_DESCRIPTION"] . ", Status: " . ucwords(strtolower($aData["CALENDAR_STATUS"])) : ", Status: " . ucwords(strtolower($aData["CALENDAR_STATUS"]));
//if exists the row in the database propel will update it, otherwise will insert. //if exists the row in the database propel will update it, otherwise will insert.
$tr = CalendarDefinitionPeer::retrieveByPK( $CalendarUid ); $tr = CalendarDefinitionPeer::retrieveByPK( $CalendarUid );
if (! (is_object( $tr ) && get_class( $tr ) == 'CalendarDefinition')) { if (! (is_object( $tr ) && get_class( $tr ) == 'CalendarDefinition')) {
$tr = new CalendarDefinition(); $tr = new CalendarDefinition();
$tr->setCalendarCreateDate( 'now' ); $tr->setCalendarCreateDate( 'now' );
G::auditLog("CreateCalendar", "Calendar Name: ".$aData['CALENDAR_NAME']); G::auditLog("CreateCalendar", "Calendar Name: ".$aData['CALENDAR_NAME'] . $msgCalendarDescriptionStatus);
} else { } else {
G::auditLog("UpdateCalendar", "Calendar Name: ".$aData['CALENDAR_NAME']." Calendar ID: (".$CalendarUid.") "); G::auditLog("UpdateCalendar", "Calendar Name: ".$aData['CALENDAR_NAME'] . $msgCalendarDescriptionStatus . ", Calendar ID: (".$CalendarUid.") ");
} }
$tr->setCalendarUid( $CalendarUid ); $tr->setCalendarUid( $CalendarUid );

View File

@@ -48,7 +48,6 @@ class adminProxy extends HttpProxyController
} }
$sysConf = System::getSystemConfiguration($envFile); $sysConf = System::getSystemConfiguration($envFile);
$updatedConf = array(); $updatedConf = array();
if ($sysConf['default_lang'] != $httpData->default_lang) { if ($sysConf['default_lang'] != $httpData->default_lang) {
@@ -123,10 +122,10 @@ class adminProxy extends HttpProxyController
$this->message = 'Saved Successfully'; $this->message = 'Saved Successfully';
$msg = ""; $msg = "";
if ($httpData->proxy_host != '' || $httpData->proxy_port != '' || $httpData->proxy_user != '') { if ($httpData->proxy_host != '' || $httpData->proxy_port != '' || $httpData->proxy_user != '') {
$msg = " Host -> ".$httpData->proxy_host." Port -> ".$httpData->proxy_port." User -> ".$httpData->proxy_user; $msg = ", Host -> " . $httpData->proxy_host . ", Port -> " . $httpData->proxy_port . ", User -> " . $httpData->proxy_user;
} }
G::auditLog("UploadSystemSettings", "Time Zone -> ".$httpData->time_zone." Memory Limit -> ".$httpData->memory_limit." Cookie lifetime -> ".$httpData->max_life_time." Default Skin -> ".$httpData->default_skin." Default Language -> ". $httpData->default_lang. $msg); G::auditLog("UploadSystemSettings", "Time Zone -> " . $httpData->time_zone . ", Memory Limit -> " . $httpData->memory_limit . ", Cookie lifetime -> " . $httpData->max_life_time . ", Default Skin -> " . $httpData->default_skin . ", Default Language -> " . $httpData->default_lang . $msg);
} }
public function uxUserUpdate($httpData) public function uxUserUpdate($httpData)
@@ -722,6 +721,9 @@ class adminProxy extends HttpProxyController
$UsrUid=''; $UsrUid='';
$AppUid=''; $AppUid='';
$messEnabled = (isset($aFields["MESS_ENABLED"]) && $aFields["MESS_ENABLED"] == "1")? G::LoadTranslation("ID_YES") : G::LoadTranslation("ID_NO");
$messRauth = (isset($aFields["MESS_RAUTH"]) && $aFields["MESS_RAUTH"] == "1")? G::LoadTranslation("ID_YES") : G::LoadTranslation("ID_NO");
if ($oConfiguration->exists($CfgUid, $ObjUid, $ProUid, $UsrUid, $AppUid)) { if ($oConfiguration->exists($CfgUid, $ObjUid, $ProUid, $UsrUid, $AppUid)) {
$oConfiguration->update( $oConfiguration->update(
array ( array (
@@ -735,7 +737,7 @@ class adminProxy extends HttpProxyController
); );
$this->success='true'; $this->success='true';
$this->msg='Saved'; $this->msg='Saved';
G::auditLog("UpdateEmailSettings", "EnableEmailNotifications->".$aFields['MESS_ENABLED']." EmailEngine->".$aFields['MESS_ENGINE']." Server->".$aFields['MESS_SERVER']." Port->".$aFields['MESS_PORT']." RequireAuthentication->".$aFields['MESS_RAUTH']." FromMail->".$aFields['MESS_ACCOUNT']." FromName->".$aFields['MESS_FROM_NAME']." Use Secure Connection->".$aFields['SMTPSecure']); G::auditLog("UpdateEmailSettings", "EnableEmailNotifications-> " . $messEnabled . ", EmailEngine-> " . $aFields['MESS_ENGINE'] . ", Server-> " . $aFields['MESS_SERVER'] . ", Port-> " . $aFields['MESS_PORT'] . ", RequireAuthentication-> " . $messRauth . ", FromMail-> " . $aFields['MESS_ACCOUNT'] . ", FromName-> " . $aFields['MESS_FROM_NAME'] . ", Use Secure Connection-> " . $aFields['SMTPSecure']);
} else { } else {
$oConfiguration->create( $oConfiguration->create(
array( array(
@@ -749,7 +751,7 @@ class adminProxy extends HttpProxyController
); );
$this->success='true'; $this->success='true';
$this->msg='Saved'; $this->msg='Saved';
G::auditLog("CreateEmailSettings", "EnableEmailNotifications->".$aFields['MESS_ENABLED']." EmailEngine->".$aFields['MESS_ENGINE']." Server->".$aFields['MESS_SERVER']." Port->".$aFields['MESS_PORT']." RequireAuthentication->".$aFields['MESS_RAUTH']." FromMail->".$aFields['MESS_ACCOUNT']." FromName->".$aFields['MESS_FROM_NAME']." Use Secure Connection->".$aFields['SMTPSecure']); G::auditLog("CreateEmailSettings", "EnableEmailNotifications-> " . $messEnabled . ", EmailEngine-> " . $aFields['MESS_ENGINE'] . ", Server-> " . $aFields['MESS_SERVER'] . ", Port-> " . $aFields['MESS_PORT'] . ", RequireAuthentication-> " . $messRauth . ", FromMail-> " . $aFields['MESS_ACCOUNT'] . ", FromName-> " . $aFields['MESS_FROM_NAME'] . ", Use Secure Connection-> " . $aFields['SMTPSecure']);
} }
} catch (Exception $e) { } catch (Exception $e) {
$this->success= false; $this->success= false;

View File

@@ -46,7 +46,7 @@ switch ($request) {
$conf->aConfig = $config; $conf->aConfig = $config;
$conf->saveConfig( "ENVIRONMENT_SETTINGS", "" ); $conf->saveConfig( "ENVIRONMENT_SETTINGS", "" );
G::auditLog("UpdateEnvironmentSettings", "UserNameDisplayFormat -> ".$_POST["userFormat"]." GlobalDateFormat -> ".$_POST["dateFormat"]." HideProcessInformation -> ".(string)isset($_POST["hideProcessInf"])." DateFormat -> ".$_POST["casesListDateFormat"]." NumberOfRowsPerPage -> ".$_POST["casesListRowNumber"]." RefreshTimeSeconds -> ".$_POST["txtCasesRefreshTime"]); G::auditLog("UpdateEnvironmentSettings", "UserNameDisplayFormat -> ".$_POST["userFormat"].", GlobalDateFormat -> ".$_POST["dateFormat"].", HideProcessInformation -> ".(string)isset($_POST["hideProcessInf"]).", DateFormat -> ".$_POST["casesListDateFormat"].", NumberOfRowsPerPage -> ".$_POST["casesListRowNumber"].", RefreshTimeSeconds -> ".$_POST["txtCasesRefreshTime"]);
$response = new stdclass(); $response = new stdclass();
$response->success = true; $response->success = true;

View File

@@ -36,7 +36,9 @@ switch ($request) {
$response = new stdclass(); $response = new stdclass();
$response->success = true; $response->success = true;
G::auditLog("UpdateLoginSettings", "DefaultLanguage->".$lang." EnableForgotPassword->".$conf->aConfig['login_enableForgotPassword']);
$messEnableForgotPassword = (isset($conf->aConfig["login_enableForgotPassword"]) && $conf->aConfig["login_enableForgotPassword"] == "1")? G::LoadTranslation("ID_YES") : G::LoadTranslation("ID_NO");
G::auditLog("UpdateLoginSettings", "DefaultLanguage-> " . $lang . " EnableForgotPassword-> " . $messEnableForgotPassword);
echo G::json_encode( $response ); echo G::json_encode( $response );