1

Inside 'models' directory I've created another called 'mappers'.

I wish to add a mapper there, however I can't find anywhere how to accomplish this with the zend_tool cli.

Does anyone know how to do it, or even if it's possible ?

MEM
  • 30,529
  • 42
  • 121
  • 191

1 Answers1

1

I think mapper isn't a registered name in zend tool like dbtable or form.

So you should simply create another model in model directory and move it to your mapper directory. Don't forget to rename the class to something like

MyModule_Model_Mapper_MyMapper
DarkLeafyGreen
  • 69,338
  • 131
  • 383
  • 601
  • Well, it will create an empty model anyway, so no much advantage of using zf, still, for comfort, it will be a nice feature to add zf create model Foo -d yourDirectoryHere :) Since we have a -m, why not a -d ? Oh well... aspiring newbie. :) Btw, if we create a folder called mappers and then we rename or class with Application_Model_Mapper_MyMapper the Zend will load it correctly because it will recognize mappers directory. (just found out). – MEM May 08 '11 at 11:36