Merge pull request #2298 from luisfernandosl/BUG-14414
BUG 14414 "No se puede realizar la import,..." SOLVED
This commit is contained in:
@@ -689,7 +689,7 @@ class G
|
||||
* @param string $strClass
|
||||
* @return void
|
||||
*/
|
||||
public function LoadClass ($strClass)
|
||||
public static function LoadClass ($strClass)
|
||||
{
|
||||
$classfile = G::ExpandPath( "classes" ) . 'class.' . $strClass . '.php';
|
||||
if (! file_exists( $classfile )) {
|
||||
@@ -3294,7 +3294,7 @@ class G
|
||||
*
|
||||
* @author Erik A.O. <erik@colosa.com>
|
||||
*/
|
||||
public function json_encode($Json)
|
||||
public static function json_encode($Json)
|
||||
{
|
||||
if ( function_exists('json_encode') ) {
|
||||
return json_encode($Json);
|
||||
|
||||
@@ -198,6 +198,7 @@ class pmTablesProxy extends HttpProxyController
|
||||
//require_once 'classes/model/Fields.php';
|
||||
|
||||
try {
|
||||
$result = new stdClass();
|
||||
ob_start();
|
||||
$data = (array) $httpData;
|
||||
$data['PRO_UID'] = trim( $data['PRO_UID'] );
|
||||
@@ -326,6 +327,7 @@ class pmTablesProxy extends HttpProxyController
|
||||
$result->success = true;
|
||||
$result->message = $result->msg = $buildResult;
|
||||
} catch (Exception $e) {
|
||||
$result = new stdClass();
|
||||
$buildResult = ob_get_contents();
|
||||
ob_end_clean();
|
||||
$result->success = false;
|
||||
@@ -352,6 +354,7 @@ class pmTablesProxy extends HttpProxyController
|
||||
*/
|
||||
public function delete ($httpData)
|
||||
{
|
||||
$result = new stdClass();
|
||||
$rows = G::json_decode( stripslashes( $httpData->rows ) );
|
||||
$errors = '';
|
||||
$count = 0;
|
||||
@@ -735,6 +738,7 @@ class pmTablesProxy extends HttpProxyController
|
||||
{
|
||||
require_once 'classes/model/AdditionalTables.php';
|
||||
try {
|
||||
$result = new stdClass();
|
||||
$errors = '';
|
||||
|
||||
$overWrite = isset( $_POST['form']['OVERWRITE'] ) ? true : false;
|
||||
@@ -962,6 +966,7 @@ class pmTablesProxy extends HttpProxyController
|
||||
|
||||
$result->message = $msg;
|
||||
} catch (Exception $e) {
|
||||
$result = new stdClass();
|
||||
$result->errorType = 'error';
|
||||
$result->buildResult = ob_get_contents();
|
||||
ob_end_clean();
|
||||
@@ -993,6 +998,7 @@ class pmTablesProxy extends HttpProxyController
|
||||
$tablesToExport = G::json_decode( stripslashes( $httpData->rows ) );
|
||||
|
||||
try {
|
||||
$result = new stdClass();
|
||||
G::LoadCLass( 'net' );
|
||||
$net = new NET( G::getIpAddress() );
|
||||
|
||||
@@ -1093,6 +1099,7 @@ class pmTablesProxy extends HttpProxyController
|
||||
$result->link = $link;
|
||||
$result->message = "Generated file: $filenameOnly, size: $size";
|
||||
} catch (Exception $e) {
|
||||
$result = new stdClass();
|
||||
$result->success = false;
|
||||
$result->message = $e->getMessage();
|
||||
}
|
||||
@@ -1225,6 +1232,7 @@ class pmTablesProxy extends HttpProxyController
|
||||
|
||||
public function genDataReport ($httpData)
|
||||
{
|
||||
$result = new stdClass();
|
||||
G::loadClass( 'pmTable' );
|
||||
require_once 'classes/model/AdditionalTables.php';
|
||||
$result->message = '';
|
||||
|
||||
Reference in New Issue
Block a user