e-xgen extjs scafolding for admin

Sorry, i have another problem, i can get the side bar to load the itens from site/tree/

To get the sidebar load the item, you have to manualy add it to the site controller, on action tree add your previously generated crud with pattern jun."Your model name"Grid, btw I will add edit config after create module base on your input, once again thx for trying my ext

after creating the module, add the module to the config file before running GiixCrudjs… thx for trying the extension…, any input are welcome…

extension page updated on usage section, thx for all, sorry for the delay

Moderator note:

Just wanted to add that MightyMike has been flagged as a spammer as his reply was a direct word by word copy and paste of a previous post in this topic… In case you were wondering where the post went. ;)

thanks, i was wondering indeed… i reply quickly after notification, without read the post first, i didn’t notice it has exact same word as previous post :)

finally get yii working on heroku, stil setting up postgress in heroku, hope i can make the example up and running for today, btw this is the example link http://exgen.herokuapp.com/index.php/site/login, heroku doesn’t allow htaccess so bye bye pretty url :(

Hello, I’m trying version 0.2 of the extension, and I’m really exited to get this working :)

I found it a little hard to get this running so I would like to share my procedure to help anyone else who stumbles here:

First install as described in the extension page, extract zip and place js folder in root, themes folder content in themes, and the other folders in protected/extensions. Enable gii as instructed and add to the imports array ‘ext.giix-components.*’

After installed, you should see in gii a couple new options.

  • Change anything in italics to something you like
  1. Create a Module using gii’s Module generator and name it mymodule

  2. Enable said module in config/main.php: ‘modules’=>array(‘mymodule’, … )

  3. Create a mymodel Model using giix Model Generator (in gii) where you must set module path to: application.modules.mymodule.models

  4. Use the GiixCrudjs Generator with model class: application.modules.mymodule.models.mymodel and Controller ID: mymodule/mymodel . All other settings as default. Remember to change the theme in main.php to make full use of extJS.

Still not newbie friendly but hey, four easy steps :)

Keep up with this extension! It saved my life on a almost dead project.

“add generated controler to site/tree action, with pattern ‘jun.’ + model name + ‘Grid’, automatic site/tree action will be added in the next release”

could you please give me a sample about "site/tree" action file.

hallo maaf baru baca thx untuk tambahan metode nya, please rate it, karena aga susah install nya ada yg ngasih rate negative… :( thx hatur nuhun sebelumnya

aku udah di reply di forum indo :) thx for using it

Hi,

I’ve installed the e-xgen extension and it works well.

BTW - in my setup I had to use the following in config/main.php to make it work (and to allow the use of gii)


'urlManager'=>array(

			'urlFormat'=>'path',

			'rules'=>array(


				'gii'=>'gii',

				'gii/<controller:\w+>'=>'gii/<controller>',

				'gii/<controller:\w+>/<action:\w+>'=>'gii/<controller>/<action>',


				'<controller:\w+>/<id:\d+>'=>'<controller>/view',

				'<controller:\w+>/<action:\w+>/<id:\d+>'=>'<controller>/<action>',

				'<controller:\w+>/<action:\w+>'=>'<controller>/<action>',

			),

		),

		

I’m still a yii and extjs newbie and maybe you could answer me some questions:

I have the tables "Master" and a model "Detail" for which generated the code with GiixModel and GiixCrudjs Generator.

This works so far.

Now I have added the extjs code from the grid "Detail" to the form "Master".

The Detail grid is now displayed in the Master Form.

Now the tricky part…

I’m trying now to filter the Detail-grid in the Master-form to the records which belong to the masterform…

So I’ve changed the code in the DetailController to display only some records.


$model = Faktpos::model()->findAll($criteria);



to


$id=426;

$model = Detail::model()->with('Master')->findAll('MasterID=' . $id)

Question(s):

  • How shall I pass the id of the master record to the detail controller?

  • What do you use for debugging such issues? (How can I see what Yii is doing if I’m clicking on something on the extjs Gui?)

  • Or is there a simpler / better approach?

hi banago, first thx for testing my extension, first get the id of the master from extjs selection model, then reload the detail store like this




var record = this.sm.getSelections();

var id= record[0].json.id; 


detailStore.baseParams = {

	query: id

};


detailStore.reload(); 



i’m debuging with firebug in firefox

hope this help

Hi,

I installed the yii user extension in the default generated webapp and enabled login to be my default controller and it works fine. However when i install e-xgen which is fantastic by the way and enable extjs theme, it doesnt load my login as default. Question:

  1. How can I make login my default controller? In my main config,I did

return array(

	                 'basePath'=>dirname(__FILE__).DIRECTORY_SEPARATOR.'..',

	                 'name'=>'My Web Application',

                         'defaultController' => 'user/login',

                         'theme'=>'extjs',

It works when i disable the theme.

  1. How can I implement the login screen with a custom extjs theme i.e apply e-xgen js?

  2. How do you map/reference a column in a store eg make the grid display name instead of id? It displays o.k when i disable theme.

Thank you.

To make login as a controller default youhave to apply different layout in extjs theme, for my private use, I have login layout and report layout that use yii standard theme it can be set in the controller $this->layout = login, create the layout in the extjs them by coppying standard yii main layout into extjs theme, to map field from I’d to name I have to see it first, currently I’m at the the airport, waiting for my first birth daughter…

Thanks Hening. I did implement the login and it worked. However, I’m still having difficulty mapping id with name in grid. Lucky you have a princess in your life.Enjoy. :)

Hi,

How are you? I was wondering if you managed to map id to name in grip as am still having difficulty with it but am having a great learning experience using e-xgen. I’ve tried

in the store:


{name:'date'},

{name:'rvc_id', mapping: 'rvc.id',type:'int'},

{name:'postingcat_id', mapping: 'postingcat.id', type: 'int'},

{name:'sales'},

where both rvc_id and postingcat_id are foreign keys and

in the grid:


{

      header:'Revenue Centre',

      sortable:true,

      resizable:true,  	             

      dataIndex:'rvc_id',                   

      displayField: 'name',

      value: 'id',

      align: 'left',

      width:140

},

but it still displaying id not name. In the form i.e xtype: combo it shows the name o.k. I been busting my head off with this for sometime now but am still stuck. Attached is my screen shot.

Secondly, how can you relate two dropdowns in a form such that when you pick an option in the first combo, the 2nd selects only related choices?


{

      xtype: 'combo',

      typeAhead: true,

      triggerAction: 'all',

      lazyRender:true,

      mode: 'local',                            

      fieldLabel: 'Revenue Centre',

      store: jun.rztrvc,

      hiddenName:'rvc_id',

      hiddenValue:'rvc_id',

      valueField: 'id',

      editable: false,

      selectOnFocus: true,

      //displayField: 'Rvc::model()->representingColumn()',

      displayField: 'name',

      //allowBlank:false,

      anchor: '100%'

               

 }, 

 {

      xtype: 'combo',

      typeAhead: true,

      triggerAction: 'all',

      lazyRender:true,

      editable: false,

      selectOnFocus: true,

      mode: 'local',                            

      fieldLabel: 'Posting Category',

      store: jun.rztPostingcat,

      hiddenName:'postingcat_id',

      hiddenValue:'postingcat_id',

      valueField: 'id',

      //displayField: Postingcat::model()->representingColumn()',

      displayField: 'postingcat_name',

      //allowBlank:false,

      anchor: '100%'

  }, 

I totally love this extension. everyday is a learning experience. For all yiiers out there wanting to building applications that look more like applications and not sites, this is the extension for you.

Thank you.

hi bosiree, in order to mapping name to id, i guest i have to edit my giix gridjs template, but i can’t promise u to do that in the near time… or you could help me, you can find quick sample in the form template, when i map id to name in the combo.

to make double linked combo create listener or add new method on new combo 1 even on change, pass the id to extjs.ajax to call store combo2 load with combo1 i as parameter

bagaimana ya cara nya membuat user login ?

thanks

Error




Parse error: syntax error, unexpected end of file in C:\xampp\htdocs\testing\protected\extensions\giix-core\giixCrudjs\templates\default\layouts\grid.js on line 126

When generating with giixcrudjs. Any Solution?