joomlaboat / custom-tables

The Custom Tables extension allows you to create, manage, and display custom data on your Joomla site. It is helpful if you need to display data that is not part of the standard Joomla content structure. For example, you could use this extension to create a custom table for product information, customer data, or any other type of data that you need to display on your site. The Custom Tables is the CRUD solution for Joomla 3.x and 4.x - CREATE, READ, UPDATE and DELETE. You can add tables, fields, and layouts to create catalogs, forms, or details pages. It has 40 Field Types: Integer (numbers), Decimal, Text String, Time, Email, Color, Image, File, User, Language, etc.
https://joomlaboat.com/custom-tables
GNU General Public License v2.0
35 stars 11 forks source link

Automatic summary #61

Closed rcr54 closed 7 months ago

rcr54 commented 9 months ago

Is your feature request related to a problem? Please describe. A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

Describe the solution you'd like A clear and concise description of what you want to happen.

Describe alternatives you've considered A clear and concise description of any alternative solutions or features you've considered.

Additional context Add any other context or screenshots about the feature request here.

rcr54 commented 9 months ago

I want to automatic sum the values of a column, is that possible. Or display a field with the value of 'select sum(field) from custom.tables.

joomlaboat commented 9 months ago

Hello Rcr54,

Yes, you can:

{{ record.sum }}

Summarizes values of a selected field of all the records that match the filter.

Parameters

Table - The name of the Table to count records from.

Value Field - The field to read the value from.

Filter - Optional filter, ie. fieldname=some value.

{{ record.sum("products","price") }}

joomlaboat commented 7 months ago

Hello Rcr54,

Does it work for you?