redex-ai / QR-Code_generator

0 stars 0 forks source link

REDEX #18

Open redex-ai opened 11 months ago

redex-ai commented 11 months ago

Fetch input url from user through a webpage and then create QR code based on it. Display it in the same webpage.

redex-ai-karthickmj[bot] commented 11 months ago

Change Summary (Revision: 1)

The changes include creating a new Django view, form, URL patterns, and HTML templates to handle user input and display of the QR code, as well as refactoring the existing QR code generation script to be used by the view.

FilePlan :-

File : views.py

Create a new Django view function to handle the GET request for the webpage where the user can input the URL, and the POST request to receive the URL, generate the QR code, and then display it on the same webpage.

File : urls.py

Add a new URL pattern that maps the URL where the user will input the URL to the view function created in 'views.py'. The changes in this file is dependent on : -

Dependent File : views.py,

File : forms.py

Create a new Django form class to handle the input of the URL from the user.

File : templates/qr_code_input.html

Create a new HTML template file for the webpage where the user inputs the URL. This will include the form created in 'forms.py'. The changes in this file is dependent on : -

Dependent File : forms.py,

File : templates/qr_code_display.html

Create a new HTML template file to display the generated QR code image after the user submits the URL. The changes in this file is dependent on : -

Dependent File : views.py,

File : static/css/styles.css

Add new CSS styles for the QR code input and display pages. The changes in this file is dependent on : -

Dependent File : templates/qr_code_input.html,templates/qr_code_display.html,

File : QR_code_generator.py

Refactor the QR code generation logic into a function that can be called with a URL parameter, so it can be used by the new view function in 'views.py'.

Next steps :-

After implementing the changes, the development team should test the new webpage functionality both locally and on a staging environment. They should also ensure that the QR code generation works as expected and that the user experience is smooth. Once testing is complete, the changes can be deployed to production.

Steps after merging :-

After merging the code, the developer should run 'python manage.py makemigrations' and 'python manage.py migrate' to apply any changes to the database schema (if any). Additionally, the developer should collect static files using 'python manage.py collectstatic' if any static files were added or changed.

Please review the structure and let me know if any modifications are required.

redex-ai-karthickmj[bot] commented 11 months ago

PULL REQUEST : https://github.com/redex-ai/QR-Code_generator/pull/19

redex-ai-karthickmj[bot] commented 11 months ago

UPDATED PULL REQUEST

redex-ai-karthickmj[bot] commented 11 months ago

UPDATED PULL REQUEST