Changeset 11932

Show
Ignore:
Timestamp:
08/31/07 08:24:51 (1 year ago)
Author:
rambo
Message:

backported parenttype fix

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/MidCOM_2_8/org.routamc.photostream/config/mgdschema.xml

    r11031 r11932  
    11<?xml version="1.0" encoding="UTF-8"?> 
    22<Schema xmlns="http://www.midgard-project.org/repligard/1.4"> 
    3     <type name="org_routamc_photostream_photo" table="org_routamc_photostream_photo" parent="midgard_person" parentfield="photographer"> 
     3    <type name="org_routamc_photostream_photo" table="org_routamc_photostream_photo" parent="midgard_topic" parentfield="node"> 
    44        <property name="id" type="integer" primaryfield="id"/> 
    5         <property name="node" link="midgard_topic:id" reverse="no" type="integer"/> 
     5        <property name="node" link="midgard_topic:id" reverse="no" type="integer" parentfield="node"/> 
    66         
    77        <!-- External IDs can be used to store identifier of the image in some external service, like Flickr --> 
  • branches/MidCOM_2_8/org.routamc.photostream/photo.php

    r11138 r11932  
    333333    } 
    334334 
     335    function get_parent_guid_uncached() 
     336    { 
     337        if (!$this->node) 
     338        { 
     339            return null; 
     340        } 
     341        $node = new midcom_db_topic($this->node); 
     342        if (   !is_a($node, 'midgard_topic') 
     343            || !isset($node->guid) 
     344            || empty($node->guid)) 
     345        { 
     346            return null; 
     347        } 
     348        return $node->guid; 
     349    } 
     350 
    335351    /** 
    336352     * Reads EXIF data from the attached image (archival or main)