Closed skoncar closed 8 years ago
Add your attribute to skipped relation when save/load.
I tried to add Published in skipped relations in CRUD generator but it's still same. Do I have to make some changes directly in code?
Please send me your schema.. I'll try it later
I have only one table in my database.
CREATE TABLE Document
(
DocumentID INTEGER NULL,
Title VARCHAR(50),
Published DATE
);
ALTER TABLE Document ADD PRIMARY KEY (DocumentID)
I'll test tommorrow..
Got same problem. Only on fields using Kartiks DateControl.
Whoops, suddenly I got something to do, and not bring my laptop with me. I will fix it on Wednesday.
Thanks! Please try again by updating this package! :grin:
Still doesnt work for me. Same error. But already thanks for trying fix it.
Wait, I'll re-check..
Still same error...
@mootensai Last update is not workable:
PHP Fatal Error – yii\base\ErrorException Call to a member function load() on null
$relObj = (empty($value[$relPKAttr[0]])) ? new $relModelClass : $relModelClass::findOne($value[$relPKAttr[0]]);
$relObj->load($value, '');
$this->populateRelation($relName, $relObj);
Waiting new updates
Ok, I'll fix this issue by this week..
Next step in our project will be CRUDs. So i hope you'll fix at as soon as possible. Already thanks for this powerful generator.
I'll fix it as soon as possible. Thank you for using this extension and for reporting this error everyone!
Please try again.. I've test it, and it works.. Thanks everyone!
@altairdeark : which line is that??
Still got same error. Will some infos about Yiiversion or something be helpful for you?
Have you run composer update
? From your error it shows RelationTrait line 31, The new code line 31 is no getRelation($relName)
Yes i did. On no relation tables it works fine now for me but not on tables with relations. Now the relations didnt works fine looks like. Wanna Chat or Email to find a solution?
Can you send your schema?
Wrote u in chat.
ruffiction's problem is not related to this issue..
Hi,
I have simple table in database:
CREATE TABLE Document ( DocumentID INTEGER NULL, Title VARCHAR(50), Published DATE );
ALTER TABLE Document ADD PRIMARY KEY (DocumentID);
I created model and CRUD, but when I try to create new Document I'm getting error: Invalid Parameter – yii\base\InvalidParamException app\models\Document has no relation named "published-document-published". Caused by: Unknown Method – yii\base\UnknownMethodException Calling unknown method: app\models\Document::getpublished-document-published()
Please help me, I'm getting this error only when I have Date field in database.