Auftragsliste: Adresse und öffentliche Notiz mitliefern [deploy]
All checks were successful
Deploy netdiag / deploy (push) Successful in 14s
All checks were successful
Deploy netdiag / deploy (push) Successful in 14s
Die App zeigt Aufträge jetzt nach Kunde + Ort statt nach Nummer — dafür liefert orders.php in der Liste zusätzlich s.address und c.note_public. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
2989ec10ed
commit
baa7df88e4
1 changed files with 8 additions and 6 deletions
|
|
@ -75,8 +75,8 @@ if ($id > 0) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// ---- Auftragsliste ----
|
// ---- Auftragsliste ----
|
||||||
$sql = "SELECT c.rowid, c.ref, c.ref_client, c.date_commande, c.fk_statut,";
|
$sql = "SELECT c.rowid, c.ref, c.ref_client, c.date_commande, c.fk_statut, c.note_public,";
|
||||||
$sql .= " s.rowid as socid, s.nom as socname, s.zip, s.town,";
|
$sql .= " s.rowid as socid, s.nom as socname, s.address, s.zip, s.town,";
|
||||||
$sql .= " (SELECT COUNT(*) FROM ".$prefix."netdiag_protocol p WHERE p.fk_commande = c.rowid) as protocolcount";
|
$sql .= " (SELECT COUNT(*) FROM ".$prefix."netdiag_protocol p WHERE p.fk_commande = c.rowid) as protocolcount";
|
||||||
$sql .= " FROM ".$prefix."commande as c";
|
$sql .= " FROM ".$prefix."commande as c";
|
||||||
$sql .= " LEFT JOIN ".$prefix."societe as s ON s.rowid = c.fk_soc";
|
$sql .= " LEFT JOIN ".$prefix."societe as s ON s.rowid = c.fk_soc";
|
||||||
|
|
@ -104,12 +104,14 @@ while ($obj = $db->fetch_object($resql)) {
|
||||||
'date' => $db->jdate($obj->date_commande),
|
'date' => $db->jdate($obj->date_commande),
|
||||||
'status' => (int) $obj->fk_statut,
|
'status' => (int) $obj->fk_statut,
|
||||||
'open' => ((int) $obj->fk_statut >= 0 && (int) $obj->fk_statut < 3),
|
'open' => ((int) $obj->fk_statut >= 0 && (int) $obj->fk_statut < 3),
|
||||||
|
'note' => $obj->note_public,
|
||||||
'protocolCount' => (int) $obj->protocolcount,
|
'protocolCount' => (int) $obj->protocolcount,
|
||||||
'customer' => array(
|
'customer' => array(
|
||||||
'id' => $obj->socid ? (int) $obj->socid : null,
|
'id' => $obj->socid ? (int) $obj->socid : null,
|
||||||
'name' => $obj->socname,
|
'name' => $obj->socname,
|
||||||
'zip' => $obj->zip,
|
'address' => $obj->address,
|
||||||
'town' => $obj->town,
|
'zip' => $obj->zip,
|
||||||
|
'town' => $obj->town,
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue