diff --git a/htdocs/expedition/card.php b/htdocs/expedition/card.php
index 9ef7bdee925..c0daef4cd6b 100644
--- a/htdocs/expedition/card.php
+++ b/htdocs/expedition/card.php
@@ -852,9 +852,10 @@ if ($action == 'create')
if (empty($conf->productbatch->enabled) || ! ($product->hasbatch() && is_object($product->stock_warehouse[$warehouse_id])))
{
// Quantity to send
- print '
';
+ print '
';
if ($line->product_type == 0 || ! empty($conf->global->STOCK_SUPPORTS_SERVICES))
{
+ if (GETPOST('qtyl'.$indiceAsked)) $defaultqty=GETPOST('qtyl'.$indiceAsked);
print '';
print '';
}
@@ -931,7 +932,7 @@ if ($action == 'create')
{
//var_dump($dbatch);
$substock=$dbatch->qty +0 ; // To get a numeric
- print '
';
+ print '
';
print '';
print '
';
diff --git a/htdocs/expedition/class/expedition.class.php b/htdocs/expedition/class/expedition.class.php
index 64436dd8bdd..373cb5f2666 100644
--- a/htdocs/expedition/class/expedition.class.php
+++ b/htdocs/expedition/class/expedition.class.php
@@ -853,6 +853,7 @@ class Expedition extends CommonObject
if (! ($entrepot_id > 0) && empty($conf->global->STOCK_WAREHOUSE_NOT_REQUIRED_FOR_SHIPMENTS))
{
+ $langs->load("errors");
$this->error=$langs->trans("ErrorWarehouseRequiredIntoShipmentLine");
return -1;
}
diff --git a/htdocs/langs/en_US/errors.lang b/htdocs/langs/en_US/errors.lang
index f3efba10999..8b64c97ba34 100755
--- a/htdocs/langs/en_US/errors.lang
+++ b/htdocs/langs/en_US/errors.lang
@@ -172,6 +172,7 @@ ErrorMandatoryParametersNotProvided=Mandatory parameter(s) not provided
ErrorOppStatusRequiredIfAmount=You set an estimated amount for this opportunity/lead. So you must also enter its status
ErrorBadDefinitionOfMenuArrayInModuleDescriptor=Bad Definition Of Menu Array In Module Descriptor (bad value for key fk_menu)
ErrorSavingChanges=An error has ocurred when saving the changes
+ErrorWarehouseRequiredIntoShipmentLine=Warehouse is required on the line to ship
# Warnings
WarningPasswordSetWithNoAccount=A password was set for this member. However, no user account was created. So this password is stored but can't be used to login to Dolibarr. It may be used by an external module/interface but if you don't need to define any login nor password for a member, you can disable option "Manage a login for each member" from Member module setup. If you need to manage a login but don't need any password, you can keep this field empty to avoid this warning. Note: Email can also be used as a login if the member is linked to a user.