feat: Adds purchase-order form only renders a new row rather than whole table.
This commit is contained in:
13
Resources/Views/purchaseOrders/table-row.leaf
Normal file
13
Resources/Views/purchaseOrders/table-row.leaf
Normal file
@@ -0,0 +1,13 @@
|
||||
<tr id="#(id)">
|
||||
<td>#(id)</td>
|
||||
<td>#(workOrder)</td>
|
||||
<td>#(customer)</td>
|
||||
<td>#capitalized(vendorBranch.vendor.name) - #capitalized(vendorBranch.name)</td>
|
||||
<td>#(materials)</td>
|
||||
<td>#capitalized(createdFor.firstName) #capitalized(createdFor.lastName)</td>
|
||||
<td>#(createdBy.username)</td>
|
||||
<td>#capitalized(truckStock)</td>
|
||||
<td>
|
||||
<!-- TODO: add buttons here -->
|
||||
</td>
|
||||
</tr>
|
||||
@@ -2,6 +2,7 @@
|
||||
<tr>
|
||||
<th>PO</th>
|
||||
<th>Work Order</th>
|
||||
<th>Customer</th>
|
||||
<th>Vendor</th>
|
||||
<th>Materials</th>
|
||||
<th>Created For</th>
|
||||
@@ -11,18 +12,7 @@
|
||||
</tr>
|
||||
<tbody id="po-table-body">
|
||||
#for(po in purchaseOrders):
|
||||
<tr id="po_#(po.id)">
|
||||
<td>#(po.id)</td>
|
||||
<td>#(po.workOrder)</td>
|
||||
<td>#capitalized(po.vendorBranch.vendor.name) - #capitalized(po.vendorBranch.name)</td>
|
||||
<td>#(po.materials)</td>
|
||||
<td>#capitalized(po.createdFor.firstName) #capitalized(po.createdFor.lastName)</td>
|
||||
<td>#(po.createdBy.username)</td>
|
||||
<td>#capitalized(po.truckStock)</td>
|
||||
<td>
|
||||
<!-- TODO: add buttons here -->
|
||||
</td>
|
||||
</tr>
|
||||
#extend("purchaseOrders/table-row", po)
|
||||
#endfor
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
Reference in New Issue
Block a user