I have an application that i'm writing but i would like some advice on the best of doing it, i'm going to simplify it so it doesn't get to complicated;
The system basically manages projects.
There are Customers, projects, jobs and Tasks.
Tasks have a one to many relationship with Jobs
Jobs have a one to many relationship with Projects
Projects have a one to many relationship with Clients
So i have a clients table, projects table, jobs table and tasks table.
So far so good.
The application is going to be designed with MDI.
What is the best strategy for designing my classes.
I would like to have Client class that i can create when the user picks a client from a list. ie;
Client Cust1 = new Client(ID) // pass in ID
My questions are,
On creation of the object would you return all you columns from the db and set all your fields in the class?
Would you use databinding so you could databind columns directly to controls on your form?
What is the best way to do this entire architecture.
I could for instance just use static methods to return a dataset which i could then use to bind my controls but this doesn't feel very Object Orientated.
Becuase Clients and Projects are related, should i create a Project Class inside my Client class? how do i relate them?
Any views on this?