product.html.twig 904 B

12345678910111213141516171819202122232425262728293031323334353637
  1. {% extends "base.html.twig" %}
  2. {% block title %}Product{% endblock %}
  3. {% block body %}
  4. Check out this great product:
  5. <table>
  6. <thead>
  7. <tr>
  8. <th>Attribute</th>
  9. <th>Value</th>
  10. </tr>
  11. </thead>
  12. <tbody>
  13. <tr>
  14. <td>Id</td>
  15. <td>{{ product.id }}</td>
  16. </tr>
  17. <tr>
  18. <td>Name</td>
  19. <td>{{ product.name }}</td>
  20. </tr>
  21. <tr>
  22. <td>Description</td>
  23. <td>{{ product.description }}</td>
  24. </tr>
  25. <tr>
  26. <td>Price</td>
  27. <td>{{ '%10.2f'|format(product.price) }}</td>
  28. </tr>
  29. <tr>
  30. <td>Category</td>
  31. <td>{{ category }}</td>
  32. </tr>
  33. </tbody>
  34. </table>
  35. {% endblock %}