Author: jablko
Date: Tue Oct 12 11:29:19 2010
New Revision: 8070

Log:
Use $route->resource

Modified:
   
trunk/apps/qubit/modules/informationobject/actions/eventFormComponent.class.php

Modified: 
trunk/apps/qubit/modules/informationobject/actions/eventFormComponent.class.php
==============================================================================
--- 
trunk/apps/qubit/modules/informationobject/actions/eventFormComponent.class.php 
    Tue Oct 12 11:12:01 2010        (r8069)
+++ 
trunk/apps/qubit/modules/informationobject/actions/eventFormComponent.class.php 
    Tue Oct 12 11:29:19 2010        (r8070)
@@ -39,18 +39,11 @@
 
     foreach ($updatedEvents as $item)
     {
-      // Create new event or update an existing one
+      $event = new QubitEvent;
       if (isset($item['id']) && !isset($this->request->sourceId))
       {
         $params = $this->context->routing->parse(Qubit::pathInfo($item['id']));
-        if (!isset($params['id']) || null === $event = 
QubitEvent::getById($params['id']))
-        {
-          continue; // If we can't find the object, then skip this row
-        }
-      }
-      else
-      {
-        $event = new QubitEvent;
+        $event = $params['_sf_route']->resource;
       }
 
       // Use existing actor if one is selected (overrides new actor creation)

-- 
You received this message because you are subscribed to the Google Groups 
"Qubit Toolkit Commits" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/qubit-commits?hl=en.

Reply via email to