39 print
"Error, template page can't be called as URL";
43 '@phan-var-force CommonObject $this
44 @phan-var-force CommonObject $object';
46 print
"<!-- BEGIN PHP TEMPLATE objectline_title.tpl.php -->\n";
51 print
'<tr class="liste_titre nodrag nodrop">';
55 print
'<th class="linecolnum center"> </th>';
59 print
'<th class="linecoldescription">'.$langs->trans(
'Description');
60 $constant = get_class(
$object).
"::STATUS_DRAFT";
61 if (in_array(
$object->element, array(
'propal',
'commande',
'facture',
'order_supplier',
'invoice_supplier')) && defined($constant) &&
$object->status == constant($constant)) {
62 if (empty($disableedit) &&
GETPOST(
'mode',
'aZ09') !=
'servicedateforalllines') {
63 print
'<a class="reposition" href="'.$_SERVER[
"PHP_SELF"].
'?mode=servicedateforalllines&id='.
$object->id.
'">'.
img_edit($langs->trans(
"UpdateForAllLines"), 0,
'class="clickvatforalllines opacitymedium paddingleft cursorpointer"').
'</a>';
65 if (
GETPOST(
'mode',
'aZ09') ==
'servicedateforalllines') {
66 print
' <div class="classvatforalllines inline-block nowraponall">';
67 $hourmin = (isset($conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE) ? $conf->global->MAIN_USE_HOURMIN_IN_DATE_RANGE :
'');
68 print $langs->trans(
'ServiceLimitedDuration').
' '.$langs->trans(
'From').
' ';
69 print $form->selectDate(
'',
'alldate_start', $hourmin, $hourmin, 1,
"updatealllines", 1, 0);
70 print
' '.$langs->trans(
'to').
' ';
71 print $form->selectDate(
'',
'alldate_end', $hourmin, $hourmin, 1,
"updatealllines", 1, 0);
72 print
'<input class="inline-block button smallpaddingimp" type="submit" name="submitforalllines" value="'.$langs->trans(
"Update").
'">';
79 if ($this->element ==
'supplier_proposal' || $this->element ==
'order_supplier' || $this->element ==
'invoice_supplier' || $this->element ==
'invoice_supplier_rec') {
80 print
'<th class="linerefsupplier maxwidth125"><span id="title_fourn_ref">'.$langs->trans(
"SupplierRef").
'</span></th>';
84 print
'<th class="linecolvat right nowraponall">';
86 print $langs->trans(
'Taxes');
88 print $langs->trans(
'VAT');
92 if (in_array(
$object->element, array(
'propal',
'commande',
'facture',
'supplier_proposal',
'order_supplier',
'invoice_supplier')) &&
$object->status == $object::STATUS_DRAFT) {
95 if (empty($disableedit) &&
GETPOST(
'mode',
'aZ09') !=
'vatforalllines') {
96 print
'<a class="reposition" href="'.$_SERVER[
"PHP_SELF"].
'?mode=vatforalllines&id='.
$object->id.
'">'.
img_edit($langs->trans(
"UpdateForAllLines"), 0,
'class="clickvatforalllines opacitymedium paddingleft cursorpointer"').
'</a>';
99 if (
GETPOST(
'mode',
'aZ09') ==
'vatforalllines') {
100 print
'<div class="classvatforalllines inline-block nowraponall">';
101 print $form->load_tva(
'vatforalllines',
'', $mysoc,
$object->thirdparty, 0, 0,
'',
false, 1);
102 print
'<input class="inline-block button smallpaddingimp" type="submit" name="submitforalllines" value="'.$langs->trans(
"Update").
'">';
109 print
'<th class="linecoluht right nowraponall">'.$langs->trans(
'PriceUHT').
'</th>';
112 if (
isModEnabled(
"multicurrency") && $this->multicurrency_code != $conf->currency) {
113 print
'<th class="linecoluht_currency right" style="width: 80px">'.$langs->trans(
'PriceUHTCurrency', $this->multicurrency_code).
'</th>';
116 if (!empty($inputalsopricewithtax) && !
getDolGlobalInt(
'MAIN_NO_INPUT_PRICE_WITH_TAX')) {
117 print
'<th class="right nowraponall">'.$langs->trans(
'PriceUTTC').
'</th>';
121 print
'<th class="linecolqty right">'.$langs->trans(
'Qty').
'</th>';
125 print
'<th class="linecoluseunit left">'.$langs->trans(
'Unit').
'</th>';
129 print
'<th class="linecoldiscount right nowraponall">';
130 print $langs->trans(
'ReductionShort');
133 if (in_array(
$object->element, array(
'propal',
'commande',
'facture')) &&
$object->status == $object::STATUS_DRAFT) {
136 if (empty($disableedit) &&
GETPOST(
'mode',
'aZ09') !=
'remiseforalllines') {
137 print
'<a class="reposition" href="'.$_SERVER[
"PHP_SELF"].
'?mode=remiseforalllines&id='.
$object->id.
'">'.
img_edit($langs->trans(
"UpdateForAllLines"), 0,
'class="clickvatforalllines opacitymedium paddingleft cursorpointer"').
'</a>';
140 if (
GETPOST(
'mode',
'aZ09') ==
'remiseforalllines') {
141 print
'<div class="remiseforalllines inline-block nowraponall">';
142 print
'<input class="inline-block smallpaddingimp width50 right" name="remiseforalllines" value="" placeholder="%">';
143 print
'<input class="inline-block button smallpaddingimp" type="submit" name="submitforalllines" value="'.$langs->trans(
"Update").
'">';
150 if (isset($this->situation_cycle_ref) && $this->situation_cycle_ref) {
151 print
'<th class="linecolcycleref right">'.$langs->trans(
'Progress').
'</th>';
152 print
'<th class="linecolcycleref2 right">'.$form->textwithpicto($langs->trans(
'TotalHT100Short'), $langs->trans(
'UnitPriceXQtyLessDiscount')).
'</th>';
156 if ($usemargins &&
isModEnabled(
'margin') && empty($user->socid)) {
157 if ($user->hasRight(
'margins',
'creer')) {
159 print
'<th class="linecolmargin1 margininfos right width75">'.$langs->trans(
'BuyingPrice').
'</th>';
161 print
'<th class="linecolmargin1 margininfos right width75">'.$langs->trans(
'CostPrice').
'</th>';
165 if (
getDolGlobalString(
'DISPLAY_MARGIN_RATES') && $user->hasRight(
'margins',
'liretous')) {
166 print
'<th class="linecolmargin2 margininfos right width75">'.$langs->trans(
'MarginRate');
167 if ($user->hasRight(
"propal",
"creer")) {
168 print
'<a class="reposition" href="'.$_SERVER[
"PHP_SELF"].
'?mode=marginforalllines&id='.
$object->id.
'">'.
img_edit($langs->trans(
"UpdateForAllLines"), 0,
'class="clickmarginforalllines opacitymedium paddingleft cursorpointer"').
'</a>';
169 if (
GETPOST(
'mode',
'aZ09') ==
'marginforalllines') {
170 print
'<div class="classmarginforalllines inline-block nowraponall">';
171 print
'<input type="number" name="marginforalllines" min="0" max="999.9" value="20.0" step="0.1" class="width50"><label>%</label>';
172 print
'<input class="inline-block button smallpaddingimp" type="submit" name="submitforallmargins" value="'.$langs->trans(
"Update").
'">';
178 if (
getDolGlobalString(
'DISPLAY_MARK_RATES') && $user->hasRight(
'margins',
'liretous')) {
179 print
'<th class="linecolmargin2 margininfos right width75">'.$langs->trans(
'MarkRate').
'</th>';
184 print
'<th class="linecolht right">'.$langs->trans(
'TotalHTShort').
'</th>';
187 if (
isModEnabled(
"multicurrency") && $this->multicurrency_code != $conf->currency) {
188 print
'<th class="linecoltotalht_currency right">'.$langs->trans(
'TotalHTShortCurrency', $this->multicurrency_code).
'</th>';
191 if ($outputalsopricetotalwithtax) {
192 print
'<th class="right" style="width: 80px">'.$langs->trans(
'TotalTTCShort').
'</th>';
196 print
'<th class="linecolasset"></th>';
199 print
'<th class="linecoledit"></th>';
201 print
'<th class="linecoldelete" style="width: 10px"></th>';
203 print
'<th class="linecolmove" style="width: 10px"></th>';
205 if ($action ==
'selectlines') {
206 print
'<th class="linecolcheckall center">';
207 print
'<input type="checkbox" class="linecheckboxtoggle" />';
208 print
'<script>$(document).ready(function() {$(".linecheckboxtoggle").click(function() {var checkBoxes = $(".linecheckbox");checkBoxes.prop("checked", this.checked);})});</script>';
215 print
"<!-- END PHP TEMPLATE objectline_title.tpl.php -->\n";
if($user->socid > 0) if(! $user->hasRight('accounting', 'chartofaccount')) $object
getDolGlobalInt($key, $default=0)
Return a Dolibarr global constant int value.
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.
getDolGlobalString($key, $default='')
Return dolibarr global constant string value.
isModEnabled($module)
Is Dolibarr module enabled.
img_edit($titlealt='default', $float=0, $other='')
Show logo edit/modify fiche.