Eine Einführung in Extbase und Fluid mit einer kleinen Demo Extension unter https://github.com/ipf/substaff Vorgetragen im Rahmen der TYPO3 Tagung am RRZN Hannover
technique which focuses on understanding the customer’s problem domain. It not only contains a set of technical ideas, but it also consists of techniques to structure the creativity in the development process.” DDD im TYPO3 Flow Kontext
technique which focuses on understanding the customer’s problem domain. It not only contains a set of technical ideas, but it also consists of techniques to structure the creativity in the development process.” DDD im TYPO3 Flow Kontext
andersherum Model Mitarbeiter => Tabelle tx_extensionname_domain_model_mitarbeiter Datenbankfelder werden als Modelpropertys im lowerCamelCase abgebildet Feld email_adresse wird im Model als Property emailAdresse gemappt
x t e n s i o n N a m e _ D o m a i n _ M o d e l _ P e r s o n e x t e n d s T x _ E x t b a s e _ D o m a i n O b j e c t _ A b s t r a c t E n t i t y { p r o t e c t e d $ n a m e ; p r o t e c t e d $ e m a i l A d d r e s s ; p u b l i c f u n c t i o n g e t N a m e ( ) { r e t u r n $ t h i s - > n a m e ; } p u b l i c f u n c t i o n s e t N a m e ( $ n a m e ) { $ t h i s - > n a m e = $ n a m e ; } } [ . . . ]
_ s u b s t a f f { p e r s i s t e n c e { s t o r a g e P i d = { $ p l u g i n . t x _ s u b s t a f f . p e r s i s t e n c e . s t o r a g e P i d } } v i e w { t e m p l a t e R o o t P a t h = [ . . . ] p a r t i a l R o o t P a t h = [ . . . ] l a y o u t R o o t P a t h = { $ p l u g i n . t x _ s u b s t a f f . v i e w . l a y o u t R o o t P a t h } d e f a u l t P i d = a u t o } f e a t u r e s { s k i p D e f a u l t A r g u m e n t s = 1 } }
x t b a s e _ U t i l i t y _ E x t e n s i o n : : c o n f i g u r e P l u g i n ( $ _ E X T K E Y , ' P l u g i n N a m e ' , a r r a y ( ' C o n t r o l l e r N a m e ' = > ' c o n t r o l l e r A c t i o n ' , ) ) ;
E x t b a s e _ U t i l i t y _ E x t e n s i o n : : r e g i s t e r P l u g i n ( $ _ E X T K E Y , ' P l u g i n N a m e ' , ' P l u g i n T i t e l ' ) ;
o n t r o l l e r T x _ E x t e n s i o n N a m e _ C o n t r o l l e r _ M o d e l N a m e C o n t r o l l e r D o m a i n M o d e l T x _ E x t e n s i o n N a m e _ D o m a i n _ M o d e l _ M o d e l N a m e R e p o s i t o r y T x _ E x t e n s i o n N a m e _ D o m a i n _ R e p o s i t o r y _ M o d e l N a m e R e p o s i t o r y C o n f i g u r a t i o n T y p o S c r i p t T c a R e s o u r c e s P r i v a t e T e m p l a t e s C o n t r o l l e r n a m e A c t i o n N a m e . h t m l P u b l i c T e s t s U n i t
deren Abteilungen dargestellt werden. Mitarbeiter haben einen Namen, eine E-Mail Adresse und gehören einer Abteilung an. Eine Abteilung hat einen Namen.
s s T x _ S u b s t a f f _ D o m a i n _ M o d e l _ A b t e i l u n g e x t e n d s T x _ E x t b a s e _ D o m a i n O b j e c t _ A b s t r a c t E n t i t y { / * * * @ v a r s t r i n g * / p r o t e c t e d $ t i t e l ; / * * * @ r e t u r n s t r i n g $ t i t e l * / p u b l i c f u n c t i o n s e t T i t e l ( $ t i t e l ) { $ t h i s - > t i t e l = $ t i t e l ; } / * * * @ v a r @ r e t u r n s t r i n g * / p u b l i c f u n c t i o n g e t T i t e l ( ) { r e t u r n $ t h i s - > t i t e l ; } ? >
a s s T x _ S u b s t a f f _ D o m a i n _ M o d e l _ M i t a r b e i t e r e x t e n d s T x _ E x t b a s e _ D o m a i n O b j e c t _ A b s t r a c t E n t i t y { / * * * @ v a r s t r i n g * / p r o t e c t e d $ n a m e ; / * * * @ v a r s t r i n g * / p r o t e c t e d $ e m a i l A d r e s s e ; / * * * @ v a r T x _ E x t b a s e _ P e r s i s t e n c e _ O b j e c t S t o r a g e < T x _ S u b s t a f f _ D o m a i n _ M o d e l _ A b t e i l u n g > * / p r o t e c t e d $ a b t e i l u n g ; p u b l i c f u n c t i o n _ _ c o n s t r u c t ( ) { $ t h i s - > i n i t i a l i z e S t o r a g e O b j e c t s ( ) ; } p r o t e c t e d f u n c t i o n i n i t i a l i z e S t o r a g e O b j e c t s ( ) { $ t h i s - > a b t e i l u n g = n e w T x _ E x t b a s e _ P e r s i s t e n c e _ O b j e c t S t o r a g e ( ) ;
a s s T x _ S u b s t a f f _ D o m a i n _ R e p o s i t o r y _ A b t e i l u n g R e p o s i t o r y e x t e n d s T x _ E x t b a s e _ P e r s i s t e n c e _ R e p o s i t o r y { } ? >
a s s T x _ S u b s t a f f _ D o m a i n _ R e p o s i t o r y _ M i t a r b e i t e r R e p o s i t o r y e x t e n d s T x _ E x t b a s e _ P e r s i s t e n c e _ R e p o s i t o r y { } ? >
Resources/Private/Templates/ControllerName/ Jedes Controller Action hat in der Regel ein eigenes Template ActionName.html Action listAction des Controllers Mitarbeiter?
TYPO3 4.7 erstellt. Einige Features sind noch nicht in TYPO3 4.5 oder 4.6 enthalten. Die Benamung der Klassen ist mit TYPO3 6.0 deprecated und wird durch eine Kompatibilitätsschicht noch funktionieren Die Demo-Extension ist verfügbar bei und im Github TER