Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop
This commit is contained in:
commit
28d1dc6a74
4 changed files with 35 additions and 6 deletions
|
|
@ -1044,6 +1044,8 @@ class Entrepot extends CommonObject
|
|||
*/
|
||||
public function getKanbanView($option = '', $arraydata = null)
|
||||
{
|
||||
global $langs;
|
||||
|
||||
$selected = (empty($arraydata['selected']) ? 0 : $arraydata['selected']);
|
||||
|
||||
$return = '<div class="box-flex-item box-flex-grow-zero">';
|
||||
|
|
@ -1059,9 +1061,12 @@ class Entrepot extends CommonObject
|
|||
if (property_exists($this, 'lieu') && (!empty($this->lieu))) {
|
||||
$return .= '<br><span class="info-box-label opacitymedium">'.$this->lieu.'</span>';
|
||||
}
|
||||
if (property_exists($this, 'sellvalue') && $this->sellvalue != 0) { // @phan-suppress-current-line PhanUndeclaredProperty
|
||||
// @phan-suppress-next-line PhanUndeclaredProperty
|
||||
$return .= '<br><span class="info-box-label amount">'.price($this->sellvalue).'</span>';
|
||||
if ($arraydata['sellvalue'] != 0) {
|
||||
if ($arraydata['isMultiPrices']) {
|
||||
$return .= '<br><span class="info-box-label opacitymedium">'.$langs->trans("Variable").' '.$langs->trans('EstimatedStockValueSell').'</span>';
|
||||
} else {
|
||||
$return .= '<br><span class="info-box-label amount">'.price($arraydata['sellvalue']).'</span>';
|
||||
}
|
||||
}
|
||||
if (method_exists($this, 'getLibStatut')) {
|
||||
$return .= '<br><div class="info-box-status">'.$this->getLibStatut(3).'</div>';
|
||||
|
|
|
|||
|
|
@ -714,7 +714,6 @@ while ($i < $imaxinloop) {
|
|||
$warehouse->setVarsFromFetchObj($obj);
|
||||
|
||||
$warehouse->label = $warehouse->ref;
|
||||
$warehouse->sellvalue = $obj->sellvalue;
|
||||
|
||||
$object = $warehouse;
|
||||
|
||||
|
|
@ -731,7 +730,7 @@ while ($i < $imaxinloop) {
|
|||
$selected = 1;
|
||||
}
|
||||
}
|
||||
print $object->getKanbanView('', array('selected' => $selected));
|
||||
print $object->getKanbanView('', array('selected' => $selected, 'sellvalue' => $obj->sellvalue, 'isMultiPrices' => getDolGlobalString('PRODUIT_MULTIPRICES')));
|
||||
if ($i == ($imaxinloop - 1)) {
|
||||
print '</div>';
|
||||
print '</td></tr>';
|
||||
|
|
|
|||
|
|
@ -251,7 +251,7 @@ if ($action == 'create' || $object->fetch($id, $ref) > 0) {
|
|||
print '$(document).ready(function () {
|
||||
$("#selectcountry_id").change(function() {
|
||||
console.log("selectcountry_id change");
|
||||
document.formresource.action.value="create";
|
||||
document.formresource.action.value="' . ($action == 'create' ? 'create' : 'edit') . '";
|
||||
document.formresource.submit();
|
||||
});
|
||||
});';
|
||||
|
|
|
|||
|
|
@ -459,6 +459,12 @@ print '<table class="tagtable liste">'."\n";
|
|||
// Fields title search
|
||||
|
||||
print '<tr class="liste_titre_filter">';
|
||||
if (getDolGlobalString('MAIN_CHECKBOX_LEFT_COLUMN')) {
|
||||
print '<td class="liste_titre center maxwidthsearch">';
|
||||
$searchpicto = $form->showFilterButtons();
|
||||
print $searchpicto;
|
||||
print '</td>';
|
||||
}
|
||||
if (!empty($arrayfields['t.ref']['checked'])) {
|
||||
print '<td class="liste_titre">';
|
||||
print '<input type="text" class="flat" name="search_ref" value="'.$search_ref.'" size="8">';
|
||||
|
|
@ -532,6 +538,9 @@ $totalarray['nbfield'] = 0;
|
|||
// Fields title label
|
||||
|
||||
print '<tr class="liste_titre">';
|
||||
if (getDolGlobalString('MAIN_CHECKBOX_LEFT_COLUMN')) {
|
||||
print_liste_field_titre($selectedfields, $_SERVER["PHP_SELF"], "", '', '', '', $sortfield, $sortorder, 'center maxwidthsearch ');
|
||||
}
|
||||
if (!empty($arrayfields['t.ref']['checked'])) {
|
||||
// @phan-suppress-next-line PhanTypeInvalidDimOffset
|
||||
print_liste_field_titre($arrayfields['t.ref']['label'], $_SERVER["PHP_SELF"], "t.ref", "", $param, "", $sortfield, $sortorder);
|
||||
|
|
@ -598,6 +607,22 @@ while ($i < $imaxinloop) {
|
|||
|
||||
print '<tr class="oddeven">';
|
||||
|
||||
// Action column
|
||||
if (getDolGlobalString('MAIN_CHECKBOX_LEFT_COLUMN')) {
|
||||
print '<td class="nowrap center">';
|
||||
if ($massactionbutton || $massaction) { // If we are in select mode (massactionbutton defined) or if we have already selected and sent an action ($massaction) defined
|
||||
$selected = 0;
|
||||
if (in_array($obj->rowid, $arrayofselected)) {
|
||||
$selected = 1;
|
||||
}
|
||||
print '<input id="cb'.$obj->rowid.'" class="flat checkforselect" type="checkbox" name="toselect[]" value="'.$obj->rowid.'"'.($selected ? ' checked="checked"' : '').'>';
|
||||
}
|
||||
print '</td>';
|
||||
if (!$i) {
|
||||
$totalarray['nbfield']++;
|
||||
}
|
||||
}
|
||||
|
||||
if (!empty($arrayfields['t.ref']['checked'])) {
|
||||
print '<td>'.$objectstatic->getNomUrl(5).'</td>';
|
||||
if (!$i) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue