avatar allenzhao
allenzhao
23 Jul 2014

Now I'm testing edit and issue and save on my machine's vagrant env.
Currently this line will throw an exception as in title. I didn't find where is the test. It's not on the template file either.
I thought it's a problem
I added $data['tests'] = $item->tests; after this line, got another exception:

8 Whoops\Exception\ErrorException
Undefined property: stdClass::$tests
avatar allenzhao allenzhao - open - 23 Jul 2014
avatar b2z
b2z - comment - 23 Jul 2014

Have you updated your installation to the latest master? There were changes to the database also.

avatar allenzhao
allenzhao - comment - 23 Jul 2014

I’ve merged. And I’ve tested on http://issues.joomla.org, same problem.
I’ve checked the code, not sure what the ‘test’ means...
And the No GitHub credentials are always ‘wrong’ if you have some exception.

On Jul 23, 2014, at 12:30 PM, Dmitry Rekun notifications@github.com wrote:

Have you updated your installation to the latest master? There were changes to the database also.


Reply to this email directly or view it on GitHub.

avatar b2z
b2z - comment - 23 Jul 2014

Seems like we forgot to remove tests :( Here it was removed from the table, so it should be removed from the Controller here and from the Model here also.

Can you check it? Should work, thanks :)

P.S.
My bad, poor testing :(

avatar allenzhao
allenzhao - comment - 23 Jul 2014

Sure, it’s good now. But seems like I got another exception saying user not set… I will look into it and make a fix branch;)
On Jul 23, 2014, at 2:15 PM, Dmitry Rekun notifications@github.com wrote:

Seems like we forgot to remove tests :( Here it was removed from the table, so it should be removed from the Controller here and from the Model here also.

Can you check it? Thanks :)


Reply to this email directly or view it on GitHub.

avatar allenzhao
allenzhao - comment - 23 Jul 2014

Hmm, here
It called the getUser method, but actually the user is not set in the IssuesTable when calling here by the controller here , which never passed the user object to the model, and the model doesn't have the user as a member object.
So I guess I need to add getUser, setUser methods for IssueModel and then pass it to the table?

avatar allenzhao allenzhao - reference | - 23 Jul 14
avatar b2z
b2z - comment - 23 Jul 2014

Good catch! The same problem I had in #353 ...

I am not sure about setting user object to the model as a property. I feel that something is not right here, like having getUser() and setUser() in the Table class. May be we can set modified_by earlier in the Controller and simply remove all this staff with the user from the Table class?

Does this make sense?

avatar allenzhao
allenzhao - comment - 23 Jul 2014

Yes, and actually I found that the only use of getUser() is the modified_by. But I’m not sure how to set eailer in the controller. Can you be more specific?

-- 
Allen Zhao
Sent with Airmail

On July 23, 2014 at 3:32:36 PM, Dmitry Rekun (notifications@github.com) wrote:

Good catch! The same problem I had in #353 ...

I am not sure about setting user object to the model as a property. I feel that something is not right here, like having getUser() and setUser() in the Table class. May be we can set modified_by earlier in the Controller and simply remove all this staff with the user from the Table class?

Does this make sense?


Reply to this email directly or view it on GitHub.

avatar b2z
b2z - comment - 23 Jul 2014

For example set it in Submit here, and in Save here.

I am not sure about the new item - do we set modified_by for the new item currently?

avatar allenzhao allenzhao - reference | - 24 Jul 14
avatar elkuku elkuku - change - 25 Jul 2014
Status New Closed
Closed_Date 0000-00-00 00:00:00 2014-07-25 01:38:45
avatar elkuku elkuku - close - 25 Jul 2014

Add a Comment

Login with GitHub to post a comment