TYPO3 - Extensions mit Extbase programmieren

Aus Wikizone
Wechseln zu: Navigation, Suche

Links

http://wiki.typo3.org/T3Doc/Extension_Builder/Using_the_Extension_Builder

http://docs.typo3.org/typo3cms/extensions/extension_builder/

http://docs.typo3.org/typo3cms/ExtbaseGuide/Extbase/FirstExtbaseExtension.html

Quickstart

Extension Builder Installieren

Domain Modelling

  • New Model auf Arbeitsfläche ziehen (z.B. Product)
    • Object Setting Aggregate Root für das Hauptobjekt
    • Default Actions z.B. list und show
    • Properties z.b. title, price...
    • Relations z.b. categories 1:n ...
  • New Model (z.b. Category)
    • Diesmal KEIN Aggregate Root
  • Verbindungen von den Relations der Haupt Domain auf die Unterdomains ziehen.
  • Speichern

Extension aktivieren

Extension Manager

Datensätze anlegen

Wie üblich.

Hinweise zum Extension Builder

Welcome to the Extension Builder! This page is intended to give you some overview about the workflow we suggest.

What is this extension builder about?

This extension builder helps you to build and manage applications based on Extbase and Fluid. We also want to provide a learning tool for Domain-Driven Design

=Domain Driven Design

View Putting the Model to Work and Strategic Design by Eric Evans to get an introduction into Domain Driven Design (DDD).

Domain Modelling

At first, you will start creating your Domain Model with a graphical editor. This editor will do the following for you:

Extension Skeleton: will create the extension directory structure needed

Domain Model: Will create basic classes for the Domain Model, residing under Domain/Model/

Database Tables and TCA: Will create Database Tables and TCA definitions which fit to the domain model.

Skeleton Locallang Files: Will create skeleton locallang files

Plugin Configuration: Will create a plugin configuration, so it will work out-of-the-box.

Dynamic Scaffolding: Automatically create all CRUD actions (Create, Read, Update, Delete) for Aggregate Roots!

Have a look at the Wiki Using the Extension Builder for more details.

Go to the Domain Modeller

Iterative model refinement

The first version of the model will usually not be the one you'll use lateron. That's why you should take your time, and improve your model.

Useful things to know

Dynamic Scaffolding: The Scaffolding will automatically adjust the templates needed to render CRUD-functionality for your domain models. That is, if you modify your domain model by adding or removing fields, the standard CRUD actions display the new fields as well.

When you start to modify the generated files, but still want to use the graphical modeler to extend your model, you have to enable the roundtrip feature in the Extension Builder settings in the Extension Manager.

You will find a file in your extension directory

Configuration/ExtensionBuilder/settings.yaml.

There you can configure which files should be overwritten, kept or merged if you save your model.

A good practice would be, to let the Extension Builder generate the Partials for form fields and properties for you and include them in your templates.

At the Wiki http://wiki.typo3.org/T3Doc/Extension_Builder/Modifying_and_extending_the_model Modifying and extending the model you find more details about this feature