2
0
forked from Wavyzz/dolibarr

translations and help

This commit is contained in:
frederic34
2015-11-22 14:11:33 +01:00
parent bfd97d5226
commit 6b4b70bdbb
3 changed files with 44 additions and 16 deletions

View File

@@ -286,6 +286,7 @@ if ($mode == 'config' && $user->admin)
print '<tr class="liste_titre">';
print '<th>'.$langs->trans("Name").'</th>';
print '<th>'.$langs->trans("Type").'</th>';
print '<th>'.$langs->trans("Profile").'</th>';
print '<th>'.$langs->trans("Parameters").'</th>';
print '<th></th>';
print '<th></th>';
@@ -315,13 +316,24 @@ if ($mode == 'config' && $user->admin)
print '<div><p></div>';
dol_fiche_head();
print $langs->trans("ReceiptPrinterTypeDesc")."<br><br>\n";
print '<table class="noborder" width="100%">'."\n";
$var=true;
print '<tr><td>'.$langs->trans("CONNECTOR_DUMMY").':</td><td>'.$langs->trans("CONNECTOR_DUMMY_HELP").'</td></tr>';
print '<td>'.$langs->trans("CONNECTOR_NETWORK_PRINT").':</td><td>'.$langs->trans("CONNECTOR_NETWORK_PRINT_HELP").'</td></tr>';
print '<td>'.$langs->trans("CONNECTOR_FILE_PRINT").':</td><td>'.$langs->trans("CONNECTOR_FILE_PRINT_HELP").'</td></tr>';
print '<td>'.$langs->trans("CONNECTOR_WINDOWS_PRINT").':</td><td>'.$langs->trans("CONNECTOR_WINDOWS_PRINT_HELP").'</td></tr>';
//print '<td>'.$langs->trans("CONNECTOR_JAVA").':</td><td>'.$langs->trans("CONNECTOR_JAVA_HELP").'</td></tr>';
print '<tr '.$bc[1].'><td>'.$langs->trans("CONNECTOR_DUMMY").':</td><td>'.$langs->trans("CONNECTOR_DUMMY_HELP").'</td></tr>';
print '<tr '.$bc[0].'><td>'.$langs->trans("CONNECTOR_NETWORK_PRINT").':</td><td>'.$langs->trans("CONNECTOR_NETWORK_PRINT_HELP").'</td></tr>';
print '<tr '.$bc[1].'><td>'.$langs->trans("CONNECTOR_FILE_PRINT").':</td><td>'.$langs->trans("CONNECTOR_FILE_PRINT_HELP").'</td></tr>';
print '<tr '.$bc[0].'><td>'.$langs->trans("CONNECTOR_WINDOWS_PRINT").':</td><td>'.$langs->trans("CONNECTOR_WINDOWS_PRINT_HELP").'</td></tr>';
//print '<tr '.$bc[1].'><td>'.$langs->trans("CONNECTOR_JAVA").':</td><td>'.$langs->trans("CONNECTOR_JAVA_HELP").'</td></tr>';
print '</table>';
dol_fiche_end();
print '<div><p></div>';
dol_fiche_head();
print $langs->trans("ReceiptPrinterProfileDesc")."<br><br>\n";
print '<table class="noborder" width="100%">'."\n";
print '<tr '.$bc[1].'><td>'.$langs->trans("PROFILE_DEFAULT").':</td><td>'.$langs->trans("PROFILE_DEFAULT_HELP").'</td></tr>';
print '<tr '.$bc[0].'><td>'.$langs->trans("PROFILE_SIMPLE").':</td><td>'.$langs->trans("PROFILE_SIMPLE_HELP").'</td></tr>';
print '<tr '.$bc[1].'><td>'.$langs->trans("PROFILE_EPOSTEP").':</td><td>'.$langs->trans("PROFILE_EPOSTEP_HELP").'</td></tr>';
print '<tr '.$bc[0].'><td>'.$langs->trans("PROFILE_P822D").':</td><td>'.$langs->trans("PROFILE_P822D_HELP").'</td></tr>';
print '<tr '.$bc[1].'><td>'.$langs->trans("PROFILE_STAR").':</td><td>'.$langs->trans("PROFILE_STAR_HELP").'</td></tr>';
print '</table>';
dol_fiche_end();
}

View File

@@ -234,19 +234,19 @@ class dolReceiptPrinter extends Escpos
}
switch ($row['fk_profile']) {
case 0:
$row['fk_profile_name'] = 'DEFAULT';
$row['fk_profile_name'] = 'PROFILE_DEFAULT';
break;
case 1:
$row['fk_profile_name'] = 'SIMPLE';
$row['fk_profile_name'] = 'PROFILE_SIMPLE';
break;
case 2:
$row['fk_profile_name'] = 'EPOSTEP';
$row['fk_profile_name'] = 'PROFILE_EPOSTEP';
break;
case 3:
$row['fk_profile_name'] = 'P822D';
$row['fk_profile_name'] = 'PROFILE_P822D';
break;
default:
$row['fk_profile_name'] = 'STAR';
$row['fk_profile_name'] = 'PROFILE_STAR';
break;
}
$obj[] = $row;
@@ -326,11 +326,11 @@ class dolReceiptPrinter extends Escpos
global $langs;
$error = 0;
$html = '<select class="flat" name="'.$htmlname.'">';
$html.= '<option value="0" '.($selected==0?'selected="selected"':'').'>'.$langs->trans('DEFAULT').'</option>';
$html.= '<option value="1" '.($selected==1?'selected="selected"':'').'>'.$langs->trans('SIMPLE').'</option>';
$html.= '<option value="2" '.($selected==2?'selected="selected"':'').'>'.$langs->trans('EPOSTEP').'</option>';
$html.= '<option value="3" '.($selected==3?'selected="selected"':'').'>'.$langs->trans('P822D').'</option>';
$html.= '<option value="4" '.($selected==4?'selected="selected"':'').'>'.$langs->trans('STAR').'</option>';
$html.= '<option value="0" '.($selected==0?'selected="selected"':'').'>'.$langs->trans('PROFILE_DEFAULT').'</option>';
$html.= '<option value="1" '.($selected==1?'selected="selected"':'').'>'.$langs->trans('PROFILE_SIMPLE').'</option>';
$html.= '<option value="2" '.($selected==2?'selected="selected"':'').'>'.$langs->trans('PROFILE_EPOSTEP').'</option>';
$html.= '<option value="3" '.($selected==3?'selected="selected"':'').'>'.$langs->trans('PROFILE_P822D').'</option>';
$html.= '<option value="4" '.($selected==4?'selected="selected"':'').'>'.$langs->trans('PROFILE_STAR').'</option>';
$html.= '</select>';
$this->profileresprint = $html;

View File

@@ -3,6 +3,12 @@ PrinterAdded=Printer %s added
PrinterUpdated=Printer %s updated
PrinterDeleted=Printer %s deleted
TestSentToPrinter=Test Sent To Printer %s
ReceiptPrinterDesc=Setup of printers
ReceiptPrinterTemplateDesc=Setup of Templates
ReceiptPrinterTypeDesc=Description of Receipt Printer's type
ReceiptPrinterProfileDesc=Description of Receipt Printer's Profile
ListPrinters=List of Printers
SetupReceiptTemplate=Template Setup
CONNECTOR_DUMMY=Dummy Printer
CONNECTOR_NETWORK_PRINT=Network Printer
CONNECTOR_FILE_PRINT=Local Printer
@@ -11,6 +17,16 @@ CONNECTOR_DUMMY_HELP=Fake Printer for test, does nothing
CONNECTOR_NETWORK_PRINT_HELP=10.x.x.x:9100
CONNECTOR_FILE_PRINT_HELP=/dev/usb/lp0, /dev/usb/lp1
CONNECTOR_WINDOWS_PRINT_HELP=LPT1, COM1, smb://FooUser:secret@computername/workgroup/Receipt Printer
PROFILE_DEFAULT=Default Profile
PROFILE_SIMPLE=Simple Profile
PROFILE_EPOSTEP=Epos Tep Profile
PROFILE_P822D=P822D Profile
PROFILE_STAR=Star Profile
PROFILE_DEFAULT_HELP=Default Profile suitable for Epson printers
PROFILE_SIMPLE_HELP=Simple Profile No Graphics
PROFILE_EPOSTEP_HELP=Epos Tep Profile Help
PROFILE_P822D_HELP=P822D Profile No Graphics
PROFILE_STAR_HELP=Star Profile
DOL_ALIGN_LEFT=Left align text
DOL_ALIGN_CENTER=Center text
DOL_ALIGN_RIGHT=Right align text