Joined data suppressed upon submit

lcollong

FabriKant d'applications web
Hi,

I have a list joined to a 'n-n' table (repeated) and a second join from this 'n-n' table to another one. This is showing the relation between a company, its employees and their jobs (several position for a employee and several employees for a company). At the end I want to show for each company the different "jobs" offered.

This is working very well as a list view. But if I edit one record (a company) without changing anything and then hit "submit", it displays back the list but all the linked records for this company has been suppressed. ie both joined records in the the two joined table are no longer there.

You can check that on the "mysites" test drive. You have to connect to the front. Go to the menu "entreprises", choose whater ever record showing some "m?tiers", edit it and then save it ("enregistrer") with out modifying anything. You'll notice that all "m?tiers" have disappeared.
 
Are the joined rows actually being deleted from the tables? Or are the FK's just getting unset (or set to the wrong values), so the rows get "orphaned"?

--hugh
 
Actually, the first table (first join) remains unchanged. In the second one, the fk of the employee is replaced by the fk of the company. ie, before editing, i had in the first join table : id=9, employee=9, company=229. This remains untouched. In the second table, I had two records. The first one was id=51,employee=9,job=31 and the second one : id=1831, employee=9,job=1296. After the submit theses two records became : first : id=51,employee=229, job=31 and the second : id=1831,employee=229, job=1296. The employee key as been replaced by the company's one.

As a remind I have :

Company (base table)
map_company_employees (first join)
map_employees_jobs (second join)
 
I may need to get you on live chat, and go through your config / usage cases. I've just been unable to duplicate this, and I don't want to start throwing debug code on your site without you around to confirm when / where it's OK to break things!

If I'm awake, I'm responding to Zopim live chats. I'm trying to move away form direct Skype support, although sometimes we may need to use Skype, to avoid some irritating issues with the Zopim chat client.

-- hugh
 
The site "RDVPRO test drive" is dedicated to tests and can be break ! I'll be glad to have a live session on it
 
Yes, I'll be around for the next 8 to 10 hours.

I'm logged in to both Zopim (the web site live chat), and Skype.

--hugh
 
Too bad. I'm in some family trouble these days. I can't really manage my time. I'll try later in the week. Thanks.
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top