Advertisement
Guest User

Untitled

a guest
Jan 21st, 2016
148
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
LDIF 0.97 KB | None | 0 0
  1. 88a89
  2. >
  3. 91c92,104
  4. <               $checked = in_array($valueAttribute, $propertyValue);
  5. ---
  6. >               foreach ($propertyValue as $value) {
  7. >                   if (is_object($value)) {
  8. >                       $identifier = $this->persistenceManager->getIdentifierByObject($value);
  9. >                       if ($identifier !== NULL) {
  10. >                           $value = $identifier;
  11. >                       }
  12. >                   }
  13. >                   // Not quite sure if identical or equal operator here; in_array did not use strict version
  14. >                   if ($valueAttribute === $value) {
  15. >                       $checked = TRUE;
  16. >                       break;
  17. >                   }
  18. >               }
  19. 112a126,139
  20. >
  21. >   /**
  22. >    * Get the name of this form element, without prefix.
  23. >    *
  24. >    * This is done to prevent the extra __identity being added for objects
  25. >    * since it leading to property mapping errors and it works without it.
  26. >    *
  27. >    * @return string name
  28. >    */
  29. >   protected function getNameWithoutPrefix()
  30. >   {
  31. >       $name = parent::getNameWithoutPrefix();
  32. >       return str_replace('[__identity]', '', $name);
  33. >   }
  34. 114d140
  35. <
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement