Advertisement
Guest User

Untitled

a guest
May 22nd, 2017
49
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.25 KB | None | 0 0
  1. Just a short note. The configuration of the record type is now mandatory for every concrete class. Instead of
  2.  
  3. > <pre>
  4. > config.tx_extbase.persistence.classes {
  5. >    Organization {
  6. >      mapping {
  7. >        tableName = party
  8. >      }
  9. >      subclasses {
  10. >        Company = Company
  11. >        ScientificInstitution = ScientificInstitution
  12. >      }
  13. >    }
  14. >    Person {
  15. >      mapping {
  16. >        tableName = party
  17. >      }
  18. >    }
  19. >    Company {
  20. >      mapping {
  21. >        tableName = party
  22. >      }
  23. >    }
  24. >    ScientificInstitution {
  25. >      mapping {
  26. >        tableName = party
  27. >      }
  28. >    }
  29. > }
  30. > </pre>
  31.  
  32. it has to be
  33.  
  34. <pre>
  35. config.tx_extbase.persistence.classes {
  36.   Organization {
  37.     mapping {
  38.       tableName = party
  39.       recordType = Organization
  40.     }
  41.     subclasses {
  42.       Company = Company
  43.       ScientificInstitution = ScientificInstitution
  44.     }
  45.   }
  46.   Person {
  47.     mapping {
  48.       tableName = party
  49.       recordType = Person
  50.     }
  51.   }
  52.   Company {
  53.     mapping {
  54.       tableName = party
  55.       recordType = Company
  56.     }
  57.   }
  58.   ScientificInstitution {
  59.     mapping {
  60.       tableName = party
  61.       recordType = ScientificInstitution
  62.     }
  63.   }
  64. }
  65. </pre>
  66.  
  67. I use STI in a complex domain and it works quite well.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement