fix bug of pargar
This commit is contained in:
@@ -666,6 +666,13 @@ class ProductController extends SuperController
|
||||
unset($data['inventory']);
|
||||
}
|
||||
|
||||
if (!Product::hasDescriptionColumn()) {
|
||||
unset($data['description']);
|
||||
} elseif (array_key_exists('description', $data)) {
|
||||
$desc = is_string($data['description']) ? trim($data['description']) : '';
|
||||
$data['description'] = $desc === '' ? null : $desc;
|
||||
}
|
||||
|
||||
if (!Product::hasOverrideTradingHoursColumn()) {
|
||||
unset($data['override_trading_hours']);
|
||||
} elseif (array_key_exists('override_trading_hours', $data)) {
|
||||
|
||||
Reference in New Issue
Block a user