Ignore:
Timestamp:
Jan 20, 2011, 2:32:34 PM (13 years ago)
Author:
plg
Message:

bug 937 fixed: makes sure a user won't see the thumbnail of a photo that has a
higher privacy level than user privacy level.

For an acceptable solution at performance level, I have implemented a cache:
for a given user, each album has a representative_picture_id. This cache also
avoids to perform numerous "order by rand()" SQL queries which is the case
when $confallow_random_representative = true;

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/install/piwigo_structure-mysql.sql

    r8651 r8802  
    369369  `count_images` mediumint(8) unsigned default '0',
    370370  `count_categories` mediumint(8) unsigned default '0',
     371  `user_representative_picture_id` mediumint(8) unsigned default NULL,
    371372  PRIMARY KEY  (`user_id`,`cat_id`)
    372373) TYPE=MyISAM;
Note: See TracChangeset for help on using the changeset viewer.