[eluser]theprodigy[/eluser]
[quote author="maria clara" date="1265710050"][quote author="theprodigy" date="1265709244"]can I assume that:
1. company_access_id is auto_incremented
2. user_id and company_id are both required (not null)[/quote]
yes your assumptions were right.
Quote:If so, you might be in trouble. The user_id is not getting passed with the creation of the company.
And if this is setup the way I think it is, you are trying to create a company in a grid that is showing a list of companies assigned to the user you are viewing.
yes.. im having a hard time to do it because im just enhancing the web app. and even the database isn't cooperating with me... i can't view if have added the data correctly.
Quote:Which means one of two things:
1. You should create the company in a different section of the site, and use this to assign a pre-made company to the user.
2. You can grab the user_id from session, or URL, or where ever you are keeping it stored, and pass it to the savecompany_details method along with the rest of the info.
you mean that i will create another module for the company to call the user and integrate it with the pre-made company module??
how can i call the user_id via session?? thru the uri??[/quote]
Here is how I typically do things:
1. Company management section (add, edit, delete companies)
2. User management section (add, edit, delete users)
In section 2 (user management) is the ability to assign them to a company that was added in section 1 (company management). In the user management section, there is no adding, deleting, or modifying of company data in any way. Only user data.
Here is how it appears you are doing it:
1. User management section
In section 1 is the ability to add, edit, delete companies and assign them to the current user.
Do I have this assumption correct, or am I missing something?