v 1.3.3 grocery CRUD - an automatic Codeigniter CRUD |
[eluser]WCDi[/eluser]
[quote author="fabgonber" date="1308642473"]If it's "B" your model is right BUT you need ProductEanProductId to ProductId. ¿Are you trying select it from product crud? It's easier do it from ean crud: Code: function blah() You can make new eans with one product.[/quote] Tnx for your reply ![]() ![]() @web-johnny > Thank you for the example, that really helps ![]()
[eluser]web-johnny[/eluser]
[quote author="dodulz" date="1308682875"]I'M newbie use grocery CRUD ... it's great plugin for CRUD, but I'Have problem with function set_model in my model I use this code Code: <?php and in controller I use Code: $this->load->library('grocery_Exceptions'); Error in Output : Code: Fatal error: Class 'grocery_Model' not found in C:\XXXX\XXX\application\models\MAsset.php on line 2 How to Fix this problem ?[/quote] For your CRUD that you say you don't need any model. Forgot the models. The set_model is for more complicated projects. For your example you can do it like this: Code: function my_newsletter(){ Hope I help. Now if you want to use models in the future for your reasons - you will do it like this: Code: $crud = new grocery_CRUD(); Code: class MAsset extends CI_Model { Code: class MAsset extends grocery_Model {
[eluser]fabgonber[/eluser]
Web-Jhony i'm having some problems with mysql stricted mode... the methods works fine in my laptop (ubuntu + mysql server + php5) but not in my server (debian + mysql + php5). In debian when i make a "add" i only see the "clock" rounding.... i can note the problem is because Grocery don't make a insert with all the "campos", example table person(id,dni,name,age) and i put $crud->fields(dni,name) grocery do insert into person(id,dni,name) values(x,y,z) but mysql fails because age is not defined in the insert stament. I feel is a problem in the mode of mysql... but i don't know how i can change it.
[eluser]web-johnny[/eluser]
[quote author="fabgonber" date="1308729099"]Web-Jhony i'm having some problems with mysql stricted mode... the methods works fine in my laptop (ubuntu + mysql server + php5) but not in my server (debian + mysql + php5). In debian when i make a "add" i only see the "clock" rounding.... i can note the problem is because Grocery don't make a insert with all the "campos", example table person(id,dni,name,age) and i put $crud->fields(dni,name) grocery do insert into person(id,dni,name) values(x,y,z) but mysql fails because age is not defined in the insert stament. I feel is a problem in the mode of mysql... but i don't know how i can change it.[/quote] This is probably a mysql problem as you said. But I still don't know what. Can you do a php info and see : What Apache version do you use? What PHP version and what mysql?
[eluser]fabgonber[/eluser]
[quote author="web-johnny" date="1308744289"] This is probably a mysql problem as you said. But I still don't know what. Can you do a php info and see : What Apache version do you use? What PHP version and what mysql? [/quote] Debian http://dl.dropbox.com/u/2891468/phpinfo-debian.pdf (dont't work) Ubuntu http://dl.dropbox.com/u/2891468/phpinfo-ubuntu.pdf (works!) when i do in phpmyadmin debian "insert into table(x,y,z) values(1,2,3)" and the table definition has (x,y,z,w) don't work. BUT when i do the same in ubuntu the insert was done and w has a default value.
[eluser]web-johnny[/eluser]
[quote author="fabgonber" date="1308783791"][quote author="web-johnny" date="1308744289"] This is probably a mysql problem as you said. But I still don't know what. Can you do a php info and see : What Apache version do you use? What PHP version and what mysql? [/quote] Debian http://dl.dropbox.com/u/2891468/phpinfo-debian.pdf (dont't work) Ubuntu http://dl.dropbox.com/u/2891468/phpinfo-ubuntu.pdf (works!) when i do in phpmyadmin debian "insert into table(x,y,z) values(1,2,3)" and the table definition has (x,y,z,w) don't work. BUT when i do the same in ubuntu the insert was done and w has a default value.[/quote] Perhaps is the Suhosin Extension . Try to disable it and try again , then try to disable only the features of the sql .I am not sure but is the only thing that it seems wrong. With a quick google search I find that this extension blocks some queries to avoid SQl injections. In CI there is not such a problem, because every query goes first to the validation check of the active record.
[eluser]mrwbsn[/eluser]
hello.. i've this error after i install to try this awesome timesaving stuff.. Code: Fatal error: Call to a member function query() on a non-object in C:\xampp\htdocs\grocery\application\third_party\grocery_crud\models\grocery_model.php on line 12 how to fix it?! thx. ![]()
[eluser]web-johnny[/eluser]
[quote author="mrwbsn" date="1308843214"]hello.. i've this error after i install to try this awesome timesaving stuff.. Code: Fatal error: Call to a member function query() on a non-object in C:\xampp\htdocs\grocery\application\third_party\grocery_crud\models\grocery_model.php on line 12 how to fix it?! thx. ![]()
[eluser]mrwbsn[/eluser]
i also have my config and autoload configured. but strange this error is happen. now its solved after i add some tweaks on it.thx for fast reply dude. ![]()
[eluser]javidhb[/eluser]
hi, web-johnny I have a mysterious problem!!! Grocery CRUD doesn't show the data in my table. all the DB's configs are ok, and when I use a table-name that doesn't exist in my db it shows FATAL error! but when i use a existing table-name, it doesn't show the data ONLY the bottom menu of the grocery CRUD. and I used your examples, and I followed every thing correctly but still have the problem. I really am sorry for me being newbie! is there any way to help me, please? I must say it again that i do every thing right(I've checked it many times). I really don't know where is the problem! tnks |
Welcome Guest, Not a member yet? Register Sign In |