Zmień limit długości wiadomości zamówienia na 900 znaków oraz popraw sposób wyświetlania błędów walidacji
This commit is contained in:
BIN
autoload/.DS_Store
vendored
Normal file
BIN
autoload/.DS_Store
vendored
Normal file
Binary file not shown.
BIN
autoload/front/.DS_Store
vendored
Normal file
BIN
autoload/front/.DS_Store
vendored
Normal file
Binary file not shown.
9
cron.php
9
cron.php
@@ -465,7 +465,8 @@ if ( $apilo_settings['enabled'] and $apilo_settings['sync_orders'] and $apilo_se
|
||||
$order_message .= '<hr>';
|
||||
}
|
||||
|
||||
if ( strlen( $order_message ) > 1024 )
|
||||
//TODO: ostatnio był problem kiedy wiadomość miała mniej 1024 znaki ale zawierała przeniesienie tekstu '<br>' i do tego jeszcze miała emoji. Wtedy APILO tego nie przepuszczał.
|
||||
if ( strlen( $order_message ) > 900 )
|
||||
$order_message = '<p><strong>Wiadomość do zamówienia była zbyt długa. Sprawdź szczegóły w panelu sklepu</strong></p>';
|
||||
|
||||
// add transport as product
|
||||
@@ -588,8 +589,10 @@ if ( $apilo_settings['enabled'] and $apilo_settings['sync_orders'] and $apilo_se
|
||||
}
|
||||
elseif ( $response['message'] == 'Validation error' )
|
||||
{
|
||||
\S::pre( $response );
|
||||
\S::pre( $postData );
|
||||
echo '<pre>';
|
||||
echo print_r( $response, true );
|
||||
echo print_r( $postData, true );
|
||||
echo '</pre>';
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user