CRUD Python Module

Prompt

You will be given starter code that implements a preliminary dashboard and prompts the user for their username and password. You will have to modify the code to add the appropriate calls to MongoDB, using the CRUD Python Module that you completed as a part of Project One.

Important Note: To avoid any possible confusion, the authentication that you are building in this assignment will be passing the username and password through to the MongoDB database. You will not be using the authentication component from the Dash framework itself.

  1. Open the ModuleFiveAssignment.ipynb file, which contains the starter code for the dashboard and the authentication interface. Upload this file into Apporto and open it using the Jupyter Notebook application. Be sure to review all of the starter code that you have been given. Pay special attention to the import commands and the comments describing what each section of code does.

  1. The code that you have been given provides you with a very basic dashboard. Add an HTML component, such as a header, to create a unique identifier for your dashboard. This unique identifier could be your name or a specific handle or image that is unique to you.

  1. Customize the starter code that you have been given by developing connections between the dashboard username/pword interface and your CRUD Python module. The dashboard should prompt the user for their username and pword and return the output of the test query. Be sure to complete each of the following:

    • Import the CRUD Python module that you created for Project One.

    • Add the functionality in the callback routine for instantiation of your CRUD object. Remember to apply the user authentication when creating your CRUD object.

    • Finally, add functionality to test your dashboard connection to MongoDB. To do this, write code that returns the following read query: {“animal_type” : “Dog”,”name” : “Lucy”}.

      IMPORTANT: Use the “aacuser” account and the password that you set up in the Module Three milestone.

SAMPLE ASSIGNMENT
Powered by WordPress