53@phan-var-force receptionlinebatch $line
54@phan-var-force int $num
56@phan-var-force CommonObject $this
57@phan-var-force Reception $object
62 print
"Error, template page can't be called as URL";
67if (empty($filtertype)) {
72global $forceall, $senderissupplier, $inputalsopricewithtax, $outputalsopricetotalwithtax, $langs;
74if (empty($dateSelector)) {
77if (empty($forceall)) {
83$domData =
' data-element="'.$line->element.
'"';
84$domData .=
' data-id="'.$line->id.
'"';
85$domData .=
' data-qty="'.$line->qty.
'"';
86$domData .=
' data-product_type="'.$line->product_type.
'"';
92print
"<!-- BEGIN PHP TEMPLATE reception/tpl/objectline_view.tpl.php -->\n";
93print
'<tr id="row-'.$line->id.
'" class="drag drop oddeven" '.$domData.
' >';
97 print
'<td class="linecolnum center">'.($i + 1).
'</td>';
102print
'<td class="linecoldescription line minwidth300imp tdoverflowmax300">';
103print
'<div id="line_'.$line->id.
'"></div>';
106if (!empty($line->fk_product)) {
107 $tmpproduct->fetch($line->fk_product);
110if ($line->fk_product > 0) {
111 print $tmpproduct->getNomUrl(1);
112 print
' - '.$tmpproduct->label;
113 if (!empty($tmpproduct->barcode)) {
116 print
'<br><span class="opacitymedium small">'.$langs->trans(
"BarCode").
' : '.
dol_escape_htmltag($tmpproduct->barcode).
'</span>';
120 print $line->description;
125print
'<td class="linecolrefsupplier">';
130 $urlpfp = DOL_URL_ROOT.
'/product/price_suppliers.php?id='.((int) $line->fk_product).
'&socid='.((int)
$object->socid);
131 print
' '.dolButtonToOpenUrlInDialogPopup(
'pfpline'.$line->id, $langs->transnoentitiesnoconv(
'BuyingPrices'), img_picto(
'',
'edit',
'class="paddingleft"'), $urlpfp,
'',
'classlink reposition',
'',
'location.reload();');
134print
'<td class="linecolcostprice nowrap right">'.(!empty($line->cost_price) ?
price($line->cost_price) :
'').
'</td>';
136print
'<td class="linecolqty nowrap right">';
138echo
price($line->qty, 0,
'', 0, 0);
143 print
'<td class="linecoluseunit nowrap">';
147 print $langs->trans($label);
151print
'<td class="linecolwarehouse nowrap right">';
153if (!empty($line->fk_entrepot)) {
154 require_once DOL_DOCUMENT_ROOT.
'/product/stock/class/entrepot.class.php';
156 if ($tmpwarehouse->fetch($line->fk_entrepot) > 0) {
157 print $tmpwarehouse->getNomUrl(1);
162 print
'<td class="linecolbatch">'.dol_escape_htmltag((
string) (!empty($line->batch) ? $line->batch :
'')).
'</td>';
166if ($this->
status == 0 && $user->hasRight(
'reception',
'write') && $action !=
'selectlines') {
167 print
'<td class="linecoledit center">';
169 if (((
int) $line->info_bits & 2) == 2 || !empty($disableedit)) {
171 print
'<a class="editfielda reposition" href="'.$_SERVER[
"PHP_SELF"].
'?id='.$this->
id.
'&action=editline&token='.
newToken().
'&lineid='.$line->id.
'">'.img_edit().
'</a>';
175 print
'<td class="linecoldelete center">';
178 print
'<a class="reposition" href="'.$_SERVER[
"PHP_SELF"].
'?id='.$this->
id.
'&action=deleteline&token='.
newToken().
'&lineid='.$line->id.
'">';
184 if ($num > 1 &&
$conf->browser->layout !=
'phone' && empty($disablemove)) {
185 print
'<td class="linecolmove tdlineupdown center">';
188 print
'<a class="lineupdown" href="'.$_SERVER[
"PHP_SELF"].
'?id='.$this->
id.
'&action=up&token='.
newToken().
'&rowid='.$line->id.
'">';
189 echo
img_up(
'default', 0,
'imgupforline');
193 print
'<a class="lineupdown" href="'.$_SERVER[
"PHP_SELF"].
'?id='.$this->
id.
'&action=down&token='.
newToken().
'&rowid='.$line->id.
'">';
194 echo
img_down(
'default', 0,
'imgdownforline');
199 print
'<td '.(($conf->browser->layout !=
'phone' && empty($disablemove)) ?
' class="linecolmove tdlineupdown center"' :
' class="linecolmove center"').
'></td>';
203 print
'<td colspan="3"></td>';
207if ($action ==
'selectlines') {
208 print
'<td class="linecolcheck center">';
209 print
'<input type="checkbox" class="linecheckbox" name="line_checkbox['.($i + 1).
']" value="'.$line->id.
'" >';
215print
"<!-- END PHP TEMPLATE objectline_view.tpl.php -->\n";
if(! $sortfield) if(! $sortorder) $object
Class to manage warehouses.
Class to manage products or services.
Class to manage receptions.
Class to manage table commandefournisseurdispatch.
print $langs trans("Ref").' m titre as m m statut as status
Or an array listing all the potential status of the object: array: int of the status => translated la...
price($amount, $form=0, $outlangs='', $trunc=1, $rounding=-1, $forcerounding=-1, $currency_code='')
Function to format a value into an amount for visual output Function used into PDF and HTML pages.
getDolGlobalInt($key, $default=0)
Return a Dolibarr global constant int value.
newToken()
Return the value of token currently saved into session with name 'newtoken'.
getDolGlobalString($key, $default='')
Return a Dolibarr global constant string value.
isModEnabled($module)
Is Dolibarr module enabled.
img_down($titlealt='default', $selected=0, $moreclass='')
Show down arrow logo.
img_up($titlealt='default', $selected=0, $moreclass='')
Show top arrow logo.
dol_escape_htmltag($stringtoescape, $keepb=0, $keepn=0, $noescapetags='', $escapeonlyhtmltags=0, $cleanalsojavascript=0)
measuringUnitString($unitid, $measuring_style='', $unitscale=null, $use_short_label=0, $outputlangs=null)
Return translation label of a unit key.