Flexi as downloads component?

More
9 years 9 months ago - 9 years 9 months ago #61890 by lipatovroman

that
- will join with the files table calculate a sum of download for every item
- and then order items by it ?


It will be great, but I have no right to ask you about this.

Right now I ask for help me to make code, that adds +1 to text extra field.

Explain.

I have created 2 fields



Now I need to inscrease text field "Total downloads" on +1 each time user download any file from File filed.




I tried to write code for this , but I'm not programmer and it does not work..

P.S. There are many downloads components, but I want to create site on FC.
The main requirements to the site - the ability to sort items by ratings, hits and number of downloads.

Problem only in number of downloads, but we can solve this using text extra field that increases after downloading files.
Last edit: 9 years 9 months ago by lipatovroman.

Please Log in or Create an account to join the conversation.

More
9 years 9 months ago #61892 by ggppdk
Hello

(i think) no DB schema changes would be needed for this
- propably it is only needs join with the "flexicontent_files" an SQL aggregation (1 more case in the ordering clause)

it seems to be similar to the "Most rated" order and with similar performance cost ...

(please note that biggest cost of category view SQL is the ORDER clause, so adding a new ordering is not to be taken lightly)
e.g. i estimate that this can add 0.5 seconds if the current category view has 10,000 content items to our optimized SQL query for category view items

if it is like i suspect in both terms of little work to add and with similar performance as "Most rated",
- then will add 1 more ordering option "Most downloaded" in v3.0.15

github.com/FLEXIcontent/flexicontent-cck/issues/538


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star review. Thanks!

Please Log in or Create an account to join the conversation.

More
9 years 9 months ago #61894 by lipatovroman
When you plan to present v3.0.15 ?
Most downloaded order should be based on sum of all files attached to the item.
Thanks!

Please Log in or Create an account to join the conversation.

More
9 years 9 months ago #61926 by ggppdk
Hello

i looked at it , found how to modify SQL query in an optimized way to support this, it seems to work
- it should not have any performance degrade on large listing (10,000 items categories) :)

will be in v3.0.15, but i will give you package to test this before release (that is the least you should do on your side)

both supporting
- a new category default order "Most downloads" + new parameter "Select File field"
- also support in the frontend ORDERING selector


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star review. Thanks!

Please Log in or Create an account to join the conversation.

More
9 years 9 months ago - 9 years 9 months ago #61945 by ggppdk
Please test by downloading and installing via extension manager in test site:

github.com/FLEXIcontent/flexicontent-cck/tree/3.0.x-stable

Please see 4 pictures here:
github.com/FLEXIcontent/flexicontent-cck/issues/538


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star review. Thanks!
Last edit: 9 years 9 months ago by ggppdk.

Please Log in or Create an account to join the conversation.

More
9 years 9 months ago #61946 by lipatovroman
It seems, that it works :cheer:

I have 3 questions.

1, I have configured order by file_filed



And it's ok.

Then I have added new order parameter


And now it does not displays




2. What is the difference in file_hits and hits_total




3. How to configure flexicontent module to display Top Downloads?

It does not work...

Please Log in or Create an account to join the conversation.

More
9 years 9 months ago - 9 years 9 months ago #61954 by ggppdk
Hello

ok the picture of configuration that you posted HELPs

- you forgot the COMMA

You are supposed to seperate multiple choices with ,
(the popup description says this)

e.g. (notice the commma at the end of 1st row)
35:file_hits:desc:Lang_Most_Downloaded,
35:file_hits:asc:Lang_Less_Downloaded


About the popup description saying:
hits_total

thanks,
- i will correct the language string , it is wrong !
the correct is "file_hits"


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star review. Thanks!
Last edit: 9 years 9 months ago by ggppdk.

Please Log in or Create an account to join the conversation.

More
9 years 9 months ago #61955 by lipatovroman
Thanks!
What about module? How to displays items sorted by total_downloads ?

Please Log in or Create an account to join the conversation.

More
9 years 9 months ago #61984 by ggppdk
Hello

yes, it should be in module too, i have re-opened the enhancement issue not to forget (it is little work all mulit-item queries of FLEXIcontent are very similar and use the same ordering code and almost same order parameter ...)


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star review. Thanks!

Please Log in or Create an account to join the conversation.

More
9 years 9 months ago - 9 years 9 months ago #61989 by lipatovroman
Thanks. I'm waiting for module fixing :blush:

I also have issue with total downloads in lists (category view).
How to display only total downloads without files?
Last edit: 9 years 9 months ago by lipatovroman.

Please Log in or Create an account to join the conversation.

Moderators: vistamediajoomlacornerggppdk
Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Essential
These cookies are needed to make the website work correctly. You can not disable them.
Display
Accept
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline
Save