Does anyone suggested a solution step by step how to manage this situation? I didn’t find any…
Does anyone suggested a solution step by step how to manage this situation? I didn’t find any…
Hi Mentel,
Just started to use giix extension and it looks good so far.
Though I found an issue (at least this is an issue in my case) - when GxActiveRecord.findAllAttributes() is called, attributes aren’t backquoted. In my case it throws an error (as I have some fields that should be backquoted).
I’ll fix it for myself but it may be useful for other implementations as well.
P.S. I’m using latest version from github
Hi yugene,
Thanks for the heads up!
Please feel free to fork and contribute your improvements on GitHub!
Also, I suggest that you use the archive provided instead of the development version.
Awesome extension. I use it by default in all my projects.
Now for the small issue I have.For valueEx documentation says:
Not clear for me how you use the dot. It would suggest something like
GxHtml::valueEx($relatedModel,"id.name")
if I want to show both id and name fields, but this doesn’t work.What am I missing?
Regards!
Thanks, radoo!
Actually, it works the same way as CHtml::value. The dot notation is to get data from related models. Check the documentation linked, it is very well explained there.
And please post again in case you need further instructions.
Got it! Thanks for the pointer. I missinterpreted the documentation.
I took concatenation ad-literam, and I was trying to get 2 attributes at the same depth level, when it’s actually more like:
Just tried to install giix (1.9.1) on a fresh install of yii (yii-1.1.12), and can’t create a model
(GxActiveRecord doesn’t exist)
I have rechecked all setup steps and i can’t find anything wrong.
Any clues?
Hi David, I’m sorry for the delay.
I have just created a new app with Yii 1.1.12 and giix 1.9.1 to test your case. It worked perfectly here.
It may be some other thing creating the issue.
I hope you have it solved by now anyway. If so, please share your fix. Thanks!
The extension does not work when using:
...
'urlManager'=>array(
'caseSensitive'=>false,
...
why?
I can solve this if I change to true the value of caseSensitive, but I would like to keep it non case sensitive!
It is a known issue. It is caused by an incompatibility with the name of the Gii generator.
A workaround is to have it set to true on your dev environment, where you use giix.
Another idea is to experiment with URL rules. Please post here the rules if it works for you. Thanks!
Hello everybody,
i’m testing giix with the the yii-user-extension
i have a table so called user-depndencies which has a foreign key to the tbl_users
when i generate my code with the standard gii.generators everything is fine, when i use the giix-extension, there is this error:
include(Users.php): failed to open stream: No such file or directory
that is correct, bit the file is called User.php
How can i fix them???
Hi,
I think I have found a tiny little bug:
in the admin page, in CGridView’s columns:
array(
'name' => 'related_id',
'value' => 'GxHtml::link($data->related, array("related/view", "id" => $data->id))',
however it’s supposed to be
array(
'name' => 'related_id',
'value' => 'GxHtml::link($data->related, array("related/view", "id" => $data->related_id))',
I hope I’m not wrong, because I’m only a tiny little beginner…
Hello!
Does anyone know how can I fix the "additional fields for MANY to MANY pivot table" issue?
http://www.yiiframework.com/forum/index.php/topic/38347-giix-crud/page__view__findpost__p__188355
It’s really important to me, because otherwise I’ll be blocked.
Thanks,
Lilli
Hello,
First of all thanks for this amazing extension
I was able to install giix and started created CRUDs until I wanted to make my application beautiful and installed yii-bootsrap extension as well. Now when i generate the CRUDs using giix the formatting and alignment of the pages are not correct. When I use bootstrap CRUD generator it is perfect. Am I missing something here? Please help
Thanks
Hi,
has anybody checked if I’m wrong in reply nr. 232?
otherwise, may I ask a question?
in CGridView, in columns section, the following (automatically generated):
array(
'name' => 'rotrszid',
'value' => 'GxHtml::valueEx($data->rotrsz)',
),
I don’t see any “with” functions in (automatically generated) relations. Normally, it should be there in order to be able to access a related tables data, right? How is it possible then, that $data->rotrsz gives back a value from related table (and how does it know what to give back)? Anyway, what informations $data is holding? I can’t really find a good explanation about this variable. I know that it’s a representation of the current object, but what are its properties? What datas can I access through this?
I guess, somehow $data->rotrsz refers to a relation declared in BaseModel’s relations sections, but the weird thing is, that $data->rotrsz is giving back the field “name”… how?! I got it! it gives back the representingColumn from related table! But why? And how…?!
I don’t even see any JOINs in SQL statements in CWebLogRoute.
other question: what is the difference between the two lines? I don’t see any in the resulting page.
'value' => '$data->rotrsz',
'value' => 'GxHtml::valueEx($data->rotrsz)',
thanks a lot!
can somebody please explain, or point to a direction? thanks.
The creator of giix is a grand master wizard! Well done. I just have a quick question. I can’t find the method in the documentation to do what I’m trying to accomplish.
I need to do a select multiple. I’m not having any issues rendering a drop-down, but the select multiple baffles me.
<label><?php echo GxHtml::encode($model->getRelationLabel('recruitColleges')); ?></label>
<?php echo $form->dropDownList($model, 'recruitColleges', GxHtml::encodeEx(
GxHtml::listDataEx(
College::model()->findAllAttributes(null, true)), false, true));
?>
Hi cwhite,
Thanks for your nice words
If your problem is with rendering a select multiple, say no more! You must add to your htmlOptions array:
'multiple' => 'multiple'
Please check this forum post for a working example (without giix; not tested).
I hope it helps!
Is there any way to prevent Giix from flagging things that haven’t really changed? I’ve noticed that when I’ve gone back into Giix after setting up my tables, I get the Base files showing changes like:
The followings are the available model relations:
@property TaxCode $taxcode0
@property Country $country0 (this line has red strikethrough)
@property State $state0
@property Country $country0 (this line is green for new item)
@package application.models.base
@name BaseDestination
*/
Basically one of the relations “jumped”, so it’s now wanting to reset. I’ve seen it actually go back and forth, so if I let it regenerate, then the next time I go back into Giix it will have reverted to the original order and want to regenerate again. Is your query for tables missing an Order By somewhere so it’s getting random orders from SQL?
Hi ktwbc,
This part of the code is actually generated by Gii, not by giix.