Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ======================= NeOn / Nette format =======================
- parameters:
- odbc:
- dns: "some dsn"
- username: "some username"
- password: "some password"
- mailer
- transport: smtp
- host: some.smtp.server
- user: null
- password: null
- services:
- sage:
- myMailer: SomeMailer(%mailer.transport%, %mailer.host%)
- # ^-- note that this is impossible in YAML and you have to devise your classes around it
- # (= config.yml has to respect the class design, and cannot be flexibile)
- # DibiConnection for accessing sage database
- database: Dibi\Connection(%odbc%)
- # Models
- models:
- customer_order_model: Bundles\SageBundle\Model\Db\CustomerOrderModel(@sage.database)
- invoice_model: Bundles\SageBundle\Model\Db\InvoiceModel(@sage.database)
- product_model: Bundles\SageBundle\Model\Db\ProductModel(@sage.database)
- purchase_order_model: Bundles\SageBundle\Model\Db\PurchaseOrderModel(@sage.database)
- # Generators
- generators:
- odbc_entities: Bundles\SageBundle\Generators\OdbcEntitiesGenerator("@sage.database", "@twig")
- # DIC Controllers
- controllers:
- lookup:
- class: Bundles\SageBundle\Controller\LookupController
- arguments: [@sage.models.invoice_model, @sage.models.customer_order_model, @sage.generators.odbc_entities]
- startup:
- - setContainer(@service_container)
- reporting:
- class: Bundles\SageBundle\Controller\ReportingController
- arguments: []
- startup:
- - setContainer(@service_container)
Add Comment
Please, Sign In to add comment