Changeset 27242


Ignore:
Timestamp:
02/06/14 15:03:57 (5 years ago)
Author:
mistic100
Message:

import privacy level

Location:
extensions/flickr2piwigo
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • extensions/flickr2piwigo/admin/template/import.list_all.tpl

    r26180 r27242  
    133133      <label><input type="checkbox" name="fill_description" checked="checked"> {'Description'|@translate}</label> 
    134134      <label><input type="checkbox" name="fill_geotag" checked="checked"> {'Geolocalization'|@translate}</label> 
     135      <label><input type="checkbox" name="fill_level" checked="checked"> {'Privacy level'|@translate}</label> 
    135136    </p> 
    136137 
  • extensions/flickr2piwigo/admin/template/import.list_photos.tpl

    r26180 r27242  
    372372      <label><input type="checkbox" name="fill_description" checked="checked"> {'Description'|@translate}</label> 
    373373      <label><input type="checkbox" name="fill_geotag" checked="checked"> {'Geolocalization'|@translate}</label> 
     374      <label><input type="checkbox" name="fill_level" checked="checked"> {'Privacy level'|@translate}</label> 
    374375    </p> 
    375376 
  • extensions/flickr2piwigo/include/ws_functions.inc.php

    r26180 r27242  
    9898    $photo['category'] = array($photo['category']); 
    9999  } 
     100   
     101  // level 
     102  $level = 0; 
     103  if (in_array('level', $photo['fills']) && !$photo['visibility']['ispublic']) 
     104  { 
     105    $level = 8; 
     106    if ($photo['visibility']['isfamily']) $level = 4; 
     107    if ($photo['visibility']['isfriend']) $level = 2; 
     108  } 
    100109 
    101110  // add photo 
    102   $photo['image_id'] = add_uploaded_file($photo['path'], basename($photo['path']), $photo['category']); 
     111  $photo['image_id'] = add_uploaded_file($photo['path'], basename($photo['path']), $photo['category'], $level); 
    103112 
    104113  // do some updates 
Note: See TracChangeset for help on using the changeset viewer.