Hide export in EEC for non european countries

This commit is contained in:
Laurent Destailleur 2019-05-04 12:26:54 +02:00
parent 3ad478c25e
commit 60bf3452c3
2 changed files with 10 additions and 7 deletions

View File

@ -200,7 +200,7 @@ $form = new FormAccounting($db);
// at this time ACCOUNTING_SERVICE_SOLD_ACCOUNT & ACCOUNTING_PRODUCT_SOLD_ACCOUNT are account number not accountingacount rowid
// so we need to get those default value rowid first
$accounting = new AccountingAccount($db);
// TODO: we should need to check if result is a really exist accountaccount rowid.....
// TODO: we should need to check if result is already exists accountaccount rowid.....
$aarowid_servbuy = $accounting->fetch('', $conf->global->ACCOUNTING_SERVICE_BUY_ACCOUNT, 1);
$aarowid_prodbuy = $accounting->fetch('', $conf->global->ACCOUNTING_PRODUCT_BUY_ACCOUNT, 1);
$aarowid_servsell = $accounting->fetch('', $conf->global->ACCOUNTING_SERVICE_SOLD_ACCOUNT, 1);
@ -334,9 +334,12 @@ if ($result)
print '<tr class="oddeven"><td class="titlefield"><input type="radio" name="accounting_product_mode" value="ACCOUNTANCY_SELL"' . ($accounting_product_mode == 'ACCOUNTANCY_SELL' ? ' checked' : '') . '> ' . $langs->trans('OptionModeProductSell') . '</td>';
print '<td>'.$langs->trans('OptionModeProductSellDesc');
print "</td></tr>\n";
print '<tr class="oddeven"><td class="titlefield"><input type="radio" name="accounting_product_mode" value="ACCOUNTANCY_SELL_INTRA"' . ($accounting_product_mode == 'ACCOUNTANCY_SELL_INTRA' ? ' checked' : '') . '> ' . $langs->trans('OptionModeProductSellIntra') . '</td>';
print '<td>'.$langs->trans('OptionModeProductSellIntraDesc');
print "</td></tr>\n";
if ($mysoc->isInEEC())
{
print '<tr class="oddeven"><td class="titlefield"><input type="radio" name="accounting_product_mode" value="ACCOUNTANCY_SELL_INTRA"' . ($accounting_product_mode == 'ACCOUNTANCY_SELL_INTRA' ? ' checked' : '') . '> ' . $langs->trans('OptionModeProductSellIntra') . '</td>';
print '<td>'.$langs->trans('OptionModeProductSellIntraDesc');
print "</td></tr>\n";
}
print '<tr class="oddeven"><td class="titlefield"><input type="radio" name="accounting_product_mode" value="ACCOUNTANCY_SELL_EXPORT"' . ($accounting_product_mode == 'ACCOUNTANCY_SELL_EXPORT' ? ' checked' : '') . '> ' . $langs->trans('OptionModeProductSellExport') . '</td>';
print '<td>'.$langs->trans('OptionModeProductSellExportDesc');
print "</td></tr>\n";

View File

@ -300,12 +300,12 @@ DefaultBindingDesc=This page can be used to set a default account to use to link
DefaultClosureDesc=This page can be used to set parameters to use to enclose a balance sheet.
Options=Options
OptionModeProductSell=Mode sales
OptionModeProductSellIntra=Mode sales in EEC
OptionModeProductSellExport=Mode sales out of EEC
OptionModeProductSellIntra=Mode sales exported in EEC
OptionModeProductSellExport=Mode sales exported in other countries
OptionModeProductBuy=Mode purchases
OptionModeProductSellDesc=Show all products with accounting account for sales.
OptionModeProductSellIntraDesc=Show all products with accounting account for sales in EEC.
OptionModeProductSellExportDesc=Show all products with accounting account for sales out of EEC.
OptionModeProductSellExportDesc=Show all products with accounting account for other foreign sales.
OptionModeProductBuyDesc=Show all products with accounting account for purchases.
CleanFixHistory=Remove accounting code from lines that not exists into charts of account
CleanHistory=Reset all bindings for selected year