Last post Jul 22, 2018 01:20 PM by mgebhard
Jul 21, 2018 09:54 PM|kmcnet|LINK
Hello everyone and thanks for your help in advance. I am developing and application that utilizes approximately 14 textboxes that allows the user freeform input. Each textbox with be input using a modal dialog. Some of the textboxes will be logically
grouped together depending on their subject matter. Not all textboxes will have input. I need to decide if each logical grouping should be placed inside its own table, or should each entry be placed in one table with a column used to designate the textbox
it is associated with. Once a row is input into the table (either design) I need the ajax script to return the updated view for the recently input data. Also, the updated view needs to be displayed on the page near where the modal resides, so I think that
makes the return view for the controller more complicated. On the flip side, only one table and one controller would need to be maintained. Any insight would be appreciated.
Jul 22, 2018 01:20 PM|mgebhard|LINK
This design question is far too open to answer. The first step is designing the table schema. A good way to approach the problem is thinking about how to report on the data or what fields are needed in a report. From there follow standard normalization
rules to build the schema. Once you have the tables schema then you also know the fields required to populate the table(s).
The next step is designing the CRUD operations or domain logic. Build methods that insert data according to the schema using whatever data access layer; EF or ADO.NET or Procs etc... Test all methods and make sure the methods work as expected.
Next, build AJAX integration tests that hit the HTTP endpoint (action methods or Web API) and invoke the business logic.
The final step is designing the UI. At this point the table schema is known and tested. The business logic and data access is known and tested. The AJAX function are wired up and tested. And you know exactly what parameters must be passed to the CRUD
All you have to do is determine what the user should see on the screen.