{"id":587,"date":"2023-06-13T13:21:00","date_gmt":"2023-06-13T13:21:00","guid":{"rendered":"https:\/\/automatethemundane.com\/index.php\/2023\/06\/13\/hours-tracker-part-4-building-forms-and-views\/"},"modified":"2023-06-13T13:21:00","modified_gmt":"2023-06-13T13:21:00","slug":"hours-tracker-part-4-building-forms-and-views","status":"publish","type":"post","link":"https:\/\/automatethemundane.com\/index.php\/2023\/06\/13\/hours-tracker-part-4-building-forms-and-views\/","title":{"rendered":"Hours Tracker Part 4-Building Forms and Views"},"content":{"rendered":"\n<h1 class=\"wp-block-heading\">The Why<\/h1>\n\n\n<p class=\"has-text-color\" style=\"color: rgb(0, 0, 0)\">This guide will explain how to create Forms and Views for all tables, as described in the following links: <a href=\"https:\/\/www.notion.so\/Building-a-Model-Driven-App-Part-3-Forms-d5f9789da4eb4b8b9a43d7da9c39bed0\">Forms<\/a> and <a href=\"https:\/\/www.notion.so\/Blog-Post-MDA-Part-5-Views-ae083ce8752d4ae0a2750fd35caea877\">Views<\/a>. This is necessary to build the backend MDA manager. Additionally, building out these forms, views and MDA allow us to ensure our data is structured correctly before building our canvas app. <\/p>\n\n\n<h1 class=\"wp-block-heading\">The How<\/h1>\n\n\n<p class=\"has-text-color\" style=\"color: rgb(0, 0, 0)\">We will go through each table and build a view and a form. Each one of these will then be used in the MDA. <\/p>\n\n\n<p class=\"has-background\" style=\"background-color: rgb(241, 241, 239)\">&#x1f4a1; I will be editing the main form for each of these tables. A new form could have been created, but for simplicity sake I went this path. <\/p>\n\n\n<h2 class=\"wp-block-heading\">Project<\/h2>\n\n\n<ol class=\"wp-block-list\">\n<li>View\n<ol class=\"wp-block-list\">\n<li>Create a new view called All Projects\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-1024x579.png\" alt=\"\"\/><\/figure>\n<\/li>\n\n\n<li>Add the Project Name to the View. Then save and publish the form. <\/li>\n<\/ol>\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-1-1024x348.png\" alt=\"\"\/><\/figure>\n<\/li>\n\n\n\n<li>Form\n<ol class=\"wp-block-list\">\n<li>Create a new Main Form called Project Main Form<\/li>\n\n\n<li>Configure the from as seen below<\/li>\n\n\n<li>Save and Publish the form\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-2-1024x472.png\" alt=\"\"\/><\/figure>\n<\/li>\n<\/ol>\n<\/li>\n<\/ol>\n\n\n<h2 class=\"wp-block-heading\">Team<\/h2>\n\n\n<ol class=\"wp-block-list\">\n<li>View\n<ol class=\"wp-block-list\">\n<li>Create a new view called All Teams<\/li>\n\n\n<li>Add the Team name to the view. <\/li>\n\n\n<li>Save and Publish the Form\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-3-1024x403.png\" alt=\"\"\/><\/figure>\n<\/li>\n<\/ol>\n<\/li>\n\n\n\n<li>Form\n<ol class=\"wp-block-list\">\n<li>Create a new Main Form called Team Main Form<\/li>\n\n\n<li>Configure the from as seen below<\/li>\n\n\n<li>Save and Publish the form\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-4-1024x329.png\" alt=\"\"\/><\/figure>\n<\/li>\n<\/ol>\n<\/li>\n<\/ol>\n\n\n<h2 class=\"wp-block-heading\">Hours<\/h2>\n\n\n<ol class=\"wp-block-list\">\n<li>View\n<ol class=\"wp-block-list\">\n<li>Create a new view called Hours not Approved\n<ol class=\"wp-block-list\">\n<li>Add the Hours Worked, Hours, User, Project and Lead Verify to the View<\/li>\n\n\n<li>Add a filter to the View where Lead Verify equals No<\/li>\n\n\n<li>Save and Publish the view\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-5-1024x482.png\" alt=\"\"\/><\/figure>\n<\/li>\n<\/ol>\n<\/li>\n\n\n<li>Create a new views called Hours Approved\n<ol class=\"wp-block-list\">\n<li>Add the Hours Worked, Hours, User, Project and Lead Verify to the View<\/li>\n\n\n<li>Add a filter to the View where Lead Verify equals Yes<\/li>\n\n\n<li>Save and Publish the view<\/li>\n<\/ol>\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-6-1024x376.png\" alt=\"\"\/><\/figure>\n<\/li>\n<\/ol>\n<\/li>\n\n\n\n<li>Form\n<ol class=\"wp-block-list\">\n<li>Create a new Main Form called Hours Input<\/li>\n\n\n<li>Configure the from as seen below<\/li>\n\n\n<li>Save and Publish the form\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-7-1024x430.png\" alt=\"\"\/><\/figure>\n<\/li>\n<\/ol>\n<\/li>\n<\/ol>\n\n\n<h2 class=\"wp-block-heading\">User<\/h2>\n\n\n<ol class=\"wp-block-list\">\n<li>View\n<ol class=\"wp-block-list\">\n<li>Create a new views called Chargeback Hours Users<\/li>\n\n\n<li>Add the Full Name, Primary Email, Team, and Role to the View<\/li>\n\n\n<li>Filter the Role so that it equals both Lead and Member<\/li>\n\n\n<li>Save and Publish the View\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-8-1024x322.png\" alt=\"\"\/><\/figure>\n<\/li>\n<\/ol>\n<\/li>\n\n\n\n<li>Form\n<ol class=\"wp-block-list\">\n<li>From the Forms view input the managed User form if it is not already there. \n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-9-1024x177.png\" alt=\"\"\/><\/figure>\n<\/li>\n\n\n<li>Open the Form and select Save a copy\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-10-1024x154.png\" alt=\"\"\/><\/figure>\n<\/li>\n\n\n<li>Save the new form as the Chargeback Hours User Form\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-11.png\" alt=\"\"\/><\/figure>\n<\/li>\n\n\n<li>Add a new 2 column tab called Hours\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-12-1024x647.png\" alt=\"\"\/><\/figure>\n<\/li>\n\n\n<li>Name the tab on the left Hours Tracker Team and the one on the right Projects\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-13-1024x652.png\" alt=\"\"\/><\/figure>\n<\/li>\n\n\n<li>Add the Team and the Role to the Hours Tracker Team tab\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-14.png\" alt=\"\"\/><\/figure>\n<\/li>\n\n\n<li>In the Projects Tab add a Subgrid\n<ol class=\"wp-block-list\">\n<li>Select Show related records<\/li>\n\n\n<li>Select the Projects table<\/li>\n\n\n<li>Select the All Projects View<\/li>\n\n\n<li>Press Done<\/li>\n<\/ol>\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-15.png\" alt=\"\"\/><\/figure>\n<\/li>\n\n\n<li>Rename the subgrid to Authorized Projects\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/automatethemundane.com\/wp-content\/uploads\/2023\/07\/untitled-16.png\" alt=\"\"\/><\/figure>\n<\/li>\n\n\n<li>Save and Publish the form<\/li>\n<\/ol>\n<\/li>\n<\/ol>\n\n\n<p class=\"has-text-color\" style=\"color: rgb(0, 0, 0)\">In the next guide we will go over how to add all these forms and views to our Model Driven Application.<\/p>\n\n","protected":false},"excerpt":{"rendered":"<p>The Why This guide will explain how to create Forms and Views for all tables, as described in the following links: Forms and Views. This is necessary to build the backend MDA manager. Additionally, building out these forms, views and MDA allow us to ensure our data is structured correctly before building our canvas app. [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[23,6,35,24],"tags":[25,31,40],"class_list":["post-587","post","type-post","status-publish","format-standard","hentry","category-forms","category-model-driven-app","category-tables","category-views","tag-dataverse","tag-forms","tag-views","entry"],"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/automatethemundane.com\/index.php\/wp-json\/wp\/v2\/posts\/587","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/automatethemundane.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/automatethemundane.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/automatethemundane.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/automatethemundane.com\/index.php\/wp-json\/wp\/v2\/comments?post=587"}],"version-history":[{"count":0,"href":"https:\/\/automatethemundane.com\/index.php\/wp-json\/wp\/v2\/posts\/587\/revisions"}],"wp:attachment":[{"href":"https:\/\/automatethemundane.com\/index.php\/wp-json\/wp\/v2\/media?parent=587"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/automatethemundane.com\/index.php\/wp-json\/wp\/v2\/categories?post=587"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/automatethemundane.com\/index.php\/wp-json\/wp\/v2\/tags?post=587"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}