Can't add a product. I was going to do the patch but this late at night I can't tell which is correct: "nid" or "xid, pid". Will follow up.

CommentFileSizeAuthor
nid_xid_pid.gif7.72 KBsime

Comments

sime’s picture

That should read: "can't add a project"

Souvent22’s picture

Sime,

I'm a little confused as to what you were going to do with nid,xid,pid? Would you like me to write up a little explination of the tables and the keys?

- Earnest

sime’s picture

Hi there, sorry about that.

You can see in the image attached that the SQL statement is insert into timesheet_times(nid, ... however the actual table doesn't have a nid key, it has xid, pid instead.

Souvent22’s picture

Patch please. :).

sime’s picture

Hi Earnest

See OP. It is not clear to me which way it's supposed to be - hence I'm asking.

Also I was discussing this with you on IRC. Why would you suggest I patch this version when it is unclear what additional code you intend to put in your sandbox? :-/

Souvent22’s picture

Sime,

I agree. I'm sorry for being delayed again. My hard-drive failed during Drupal-Con :( . So I am without my dev. enviroment for a few days still. But, I will be back in touch soon.

onionweb’s picture

This is still broken.

If you change nid to xid you still get the foreign key error.

nichyati’s picture

The xid is an autogenerated field. To fix this problem, replace nid by pid, it seems to me. The table needs project id, labor id and onsite flag. Iit did work for me, with this change.