├── 01-07-2021
├── Screenshot (135)_LI.jpg
├── college
│ ├── college
│ │ ├── __init__.py
│ │ ├── __pycache__
│ │ │ ├── __init__.cpython-36.pyc
│ │ │ ├── __init__.cpython-38.pyc
│ │ │ ├── settings.cpython-36.pyc
│ │ │ ├── settings.cpython-38.pyc
│ │ │ ├── urls.cpython-36.pyc
│ │ │ ├── urls.cpython-38.pyc
│ │ │ ├── wsgi.cpython-36.pyc
│ │ │ └── wsgi.cpython-38.pyc
│ │ ├── settings.py
│ │ ├── urls.py
│ │ └── wsgi.py
│ ├── db.sqlite3
│ ├── manage.py
│ ├── media
│ │ ├── default.png
│ │ └── users
│ │ │ ├── 2.jpg
│ │ │ ├── apssdc_final.jpg
│ │ │ └── apssdc_final_xegs8je.jpg
│ ├── student
│ │ ├── __init__.py
│ │ ├── __pycache__
│ │ │ ├── __init__.cpython-36.pyc
│ │ │ ├── __init__.cpython-38.pyc
│ │ │ ├── admin.cpython-36.pyc
│ │ │ ├── admin.cpython-38.pyc
│ │ │ ├── forms.cpython-36.pyc
│ │ │ ├── forms.cpython-38.pyc
│ │ │ ├── models.cpython-36.pyc
│ │ │ ├── models.cpython-38.pyc
│ │ │ ├── urls.cpython-36.pyc
│ │ │ ├── urls.cpython-38.pyc
│ │ │ ├── views.cpython-36.pyc
│ │ │ └── views.cpython-38.pyc
│ │ ├── admin.py
│ │ ├── apps.py
│ │ ├── forms.py
│ │ ├── migrations
│ │ │ ├── 0001_initial.py
│ │ │ ├── 0002_contactus.py
│ │ │ ├── __init__.py
│ │ │ └── __pycache__
│ │ │ │ ├── 0001_initial.cpython-36.pyc
│ │ │ │ ├── 0001_initial.cpython-38.pyc
│ │ │ │ ├── 0002_contactus.cpython-36.pyc
│ │ │ │ ├── 0002_contactus.cpython-38.pyc
│ │ │ │ ├── __init__.cpython-36.pyc
│ │ │ │ └── __init__.cpython-38.pyc
│ │ ├── models.py
│ │ ├── static
│ │ │ ├── css
│ │ │ │ ├── bootstrap-grid.css
│ │ │ │ ├── bootstrap-grid.css.map
│ │ │ │ ├── bootstrap-grid.min.css
│ │ │ │ ├── bootstrap-grid.min.css.map
│ │ │ │ ├── bootstrap-grid.rtl.css
│ │ │ │ ├── bootstrap-grid.rtl.css.map
│ │ │ │ ├── bootstrap-grid.rtl.min.css
│ │ │ │ ├── bootstrap-grid.rtl.min.css.map
│ │ │ │ ├── bootstrap-reboot.css
│ │ │ │ ├── bootstrap-reboot.css.map
│ │ │ │ ├── bootstrap-reboot.min.css
│ │ │ │ ├── bootstrap-reboot.min.css.map
│ │ │ │ ├── bootstrap-reboot.rtl.css
│ │ │ │ ├── bootstrap-reboot.rtl.css.map
│ │ │ │ ├── bootstrap-reboot.rtl.min.css
│ │ │ │ ├── bootstrap-reboot.rtl.min.css.map
│ │ │ │ ├── bootstrap-utilities.css
│ │ │ │ ├── bootstrap-utilities.css.map
│ │ │ │ ├── bootstrap-utilities.min.css
│ │ │ │ ├── bootstrap-utilities.min.css.map
│ │ │ │ ├── bootstrap-utilities.rtl.css
│ │ │ │ ├── bootstrap-utilities.rtl.css.map
│ │ │ │ ├── bootstrap-utilities.rtl.min.css
│ │ │ │ ├── bootstrap-utilities.rtl.min.css.map
│ │ │ │ ├── bootstrap.css
│ │ │ │ ├── bootstrap.css.map
│ │ │ │ ├── bootstrap.min.css
│ │ │ │ ├── bootstrap.min.css.map
│ │ │ │ ├── bootstrap.rtl.css
│ │ │ │ ├── bootstrap.rtl.css.map
│ │ │ │ ├── bootstrap.rtl.min.css
│ │ │ │ ├── bootstrap.rtl.min.css.map
│ │ │ │ └── mystyles.css
│ │ │ ├── images
│ │ │ │ └── image1.png
│ │ │ ├── js
│ │ │ │ ├── bootstrap.bundle.js
│ │ │ │ ├── bootstrap.bundle.js.map
│ │ │ │ ├── bootstrap.bundle.min.js
│ │ │ │ ├── bootstrap.bundle.min.js.map
│ │ │ │ ├── bootstrap.esm.js
│ │ │ │ ├── bootstrap.esm.js.map
│ │ │ │ ├── bootstrap.esm.min.js
│ │ │ │ ├── bootstrap.esm.min.js.map
│ │ │ │ ├── bootstrap.js
│ │ │ │ ├── bootstrap.js.map
│ │ │ │ ├── bootstrap.min.js
│ │ │ │ └── bootstrap.min.js.map
│ │ │ └── mystyles.css
│ │ ├── templates
│ │ │ └── student
│ │ │ │ ├── base.html
│ │ │ │ ├── contact.html
│ │ │ │ ├── data.html
│ │ │ │ ├── details.html
│ │ │ │ ├── home.html
│ │ │ │ ├── messages.html
│ │ │ │ ├── navbar.html
│ │ │ │ ├── register.html
│ │ │ │ ├── student_data.html
│ │ │ │ ├── student_register.html
│ │ │ │ └── update.html
│ │ ├── tests.py
│ │ ├── urls.py
│ │ └── views.py
│ └── userAuth
│ │ ├── __init__.py
│ │ ├── __pycache__
│ │ ├── __init__.cpython-36.pyc
│ │ ├── admin.cpython-36.pyc
│ │ ├── forms.cpython-36.pyc
│ │ ├── models.cpython-36.pyc
│ │ ├── urls.cpython-36.pyc
│ │ └── views.cpython-36.pyc
│ │ ├── admin.py
│ │ ├── apps.py
│ │ ├── forms.py
│ │ ├── migrations
│ │ ├── 0001_initial.py
│ │ ├── 0002_profiledetails_image.py
│ │ ├── __init__.py
│ │ └── __pycache__
│ │ │ ├── 0001_initial.cpython-36.pyc
│ │ │ ├── 0002_profiledetails_image.cpython-36.pyc
│ │ │ └── __init__.cpython-36.pyc
│ │ ├── models.py
│ │ ├── templates
│ │ ├── authlogin.html
│ │ ├── authlogout.html
│ │ ├── login.html
│ │ ├── profile.html
│ │ ├── profile_details.html
│ │ ├── signup.html
│ │ └── update.html
│ │ ├── tests.py
│ │ ├── urls.py
│ │ └── views.py
└── mysqlclient-2.0.3-cp36-cp36m-win_amd64.whl
├── 10 jun 2021.txt
├── 11-06-2021
├── Python Programming.pptx
├── first.py
├── integers.py
├── note.txt
└── operaters.py
├── 12-06-2021
├── condtional_statments.py
├── divisible_by_10_and_5.py
├── divisible_by_5.py
├── even_odd.py
├── notes.txt
├── operators.py
├── strings.py
└── tasks.txt
├── 14 jun 2021
├── char count.py
├── for_loop.py
├── leap year.py
├── multiple.py
├── string_in_for.py
├── termination.py
└── while loop.py
├── 15 june 2021
├── 1_List.py
├── 1_sample function.py
├── 2_adding.py
├── 2_list_homogeneous.py
├── 3_keyword_arguments.py
├── 3_list methods.py
├── 4_default arguments.py
├── 5_variable_length.py
└── 6_cubes_of_average_evennums.py
├── 16-06-2021
├── Tasks.txt
├── Tuples & Sets.pptx
├── leap_years_in_range.py
├── set_methods.py
├── sets.py
├── tuple_frequency.py
├── tuples.py
├── tuples.txt
└── unique_elements.py
├── 17-06-2021
├── Files & File Handling.pptx
├── Tasks
│ ├── Tasks and Solutions.ipynb
│ └── data.txt
├── data_processing.py
├── dict_methods.py
├── dictionaries.py
├── file1.txt
├── file2.txt
├── files.py
└── notes.txt
├── 18 june 2021
├── 1.dictionary_comprehension.py
├── 2.list_comprehension.py
├── 3.list_comprehension.py
├── generators.py
├── iterator.py
├── list_comprehension.py
└── prime_number.py
├── 19-06-2021
├── Functional Programming.pptx
├── Regular Expressions.pptx
├── Task.md
├── email_validation.py
├── lambda.py
├── notes.txt
└── regex.py
├── 21 june 2021
├── oop1.py
├── oop2_declaring fun inside class.py
├── oop3_local class global variables.py
├── oop4_named objects.py
├── oop5_constructor.py
├── oop6___Str__.py
├── oop7_destructor.py
└── oop8.py
├── 22 june 2021
├── 2.inherintance.py
├── Encapsulation_ getter and setter Example.py
├── Encapsulation_ private attributes Example.py
├── Encapsulation_ private methods_Example.py
├── Hierarchical_inheritance_Example.py
├── Hierarchical_inheritance_syntax.py
├── Inheritance_1.py
├── Inheritance_3.py
├── Polymorphism_1.py
├── __pycache__
│ ├── Inheritance_1.cpython-38.pyc
│ └── multi_level_Example.cpython-38.pyc
├── abstraction class.py
├── multi_level_Example.py
├── multi_level_syntax.py
├── multiple_inheritance_Example.py
├── multiple_inheritance_syntax.py
└── single inheritance.py
├── 23-06-2021
├── Django Introduction.pptx
├── FirstProject
│ ├── FirstProject
│ │ ├── __init__.py
│ │ ├── settings.py
│ │ ├── urls.py
│ │ └── wsgi.py
│ ├── db.sqlite3
│ └── manage.py
├── mvc.png
├── mvt.png
└── notes.txt
├── 24-06-2021
├── Notes.docx
└── myProject
│ ├── db.sqlite3
│ ├── manage.py
│ ├── myApp
│ ├── __init__.py
│ ├── __pycache__
│ │ ├── __init__.cpython-36.pyc
│ │ ├── urls.cpython-36.pyc
│ │ └── views.cpython-36.pyc
│ ├── admin.py
│ ├── apps.py
│ ├── migrations
│ │ └── __init__.py
│ ├── models.py
│ ├── tests.py
│ ├── urls.py
│ └── views.py
│ └── myProject
│ ├── __init__.py
│ ├── __pycache__
│ ├── __init__.cpython-36.pyc
│ ├── settings.cpython-36.pyc
│ ├── urls.cpython-36.pyc
│ └── wsgi.cpython-36.pyc
│ ├── settings.py
│ ├── urls.py
│ └── wsgi.py
├── 26-06-2021
├── college
│ ├── college
│ │ ├── __init__.py
│ │ ├── __pycache__
│ │ │ ├── __init__.cpython-36.pyc
│ │ │ ├── __init__.cpython-38.pyc
│ │ │ ├── settings.cpython-36.pyc
│ │ │ ├── settings.cpython-38.pyc
│ │ │ ├── urls.cpython-36.pyc
│ │ │ ├── urls.cpython-38.pyc
│ │ │ ├── wsgi.cpython-36.pyc
│ │ │ └── wsgi.cpython-38.pyc
│ │ ├── settings.py
│ │ ├── urls.py
│ │ └── wsgi.py
│ ├── db.sqlite3
│ ├── manage.py
│ └── student
│ │ ├── __init__.py
│ │ ├── __pycache__
│ │ ├── __init__.cpython-36.pyc
│ │ ├── __init__.cpython-38.pyc
│ │ ├── admin.cpython-36.pyc
│ │ ├── admin.cpython-38.pyc
│ │ ├── models.cpython-36.pyc
│ │ ├── models.cpython-38.pyc
│ │ ├── urls.cpython-36.pyc
│ │ ├── urls.cpython-38.pyc
│ │ ├── views.cpython-36.pyc
│ │ └── views.cpython-38.pyc
│ │ ├── admin.py
│ │ ├── apps.py
│ │ ├── migrations
│ │ ├── 0001_initial.py
│ │ ├── __init__.py
│ │ └── __pycache__
│ │ │ ├── 0001_initial.cpython-38.pyc
│ │ │ ├── __init__.cpython-36.pyc
│ │ │ └── __init__.cpython-38.pyc
│ │ ├── models.py
│ │ ├── static
│ │ ├── css
│ │ │ └── mystyles.css
│ │ ├── images
│ │ │ └── image1.png
│ │ └── mystyles.css
│ │ ├── templates
│ │ └── student
│ │ │ ├── data.html
│ │ │ ├── home.html
│ │ │ └── register.html
│ │ ├── tests.py
│ │ ├── urls.py
│ │ └── views.py
└── notes.txt
├── 29-06-2021
├── college
│ ├── college
│ │ ├── __init__.py
│ │ ├── __pycache__
│ │ │ ├── __init__.cpython-36.pyc
│ │ │ ├── __init__.cpython-38.pyc
│ │ │ ├── settings.cpython-36.pyc
│ │ │ ├── settings.cpython-38.pyc
│ │ │ ├── urls.cpython-36.pyc
│ │ │ ├── urls.cpython-38.pyc
│ │ │ ├── wsgi.cpython-36.pyc
│ │ │ └── wsgi.cpython-38.pyc
│ │ ├── settings.py
│ │ ├── urls.py
│ │ └── wsgi.py
│ ├── db.sqlite3
│ ├── manage.py
│ └── student
│ │ ├── __init__.py
│ │ ├── __pycache__
│ │ ├── __init__.cpython-36.pyc
│ │ ├── __init__.cpython-38.pyc
│ │ ├── admin.cpython-36.pyc
│ │ ├── admin.cpython-38.pyc
│ │ ├── models.cpython-36.pyc
│ │ ├── models.cpython-38.pyc
│ │ ├── urls.cpython-36.pyc
│ │ ├── urls.cpython-38.pyc
│ │ ├── views.cpython-36.pyc
│ │ └── views.cpython-38.pyc
│ │ ├── admin.py
│ │ ├── apps.py
│ │ ├── migrations
│ │ ├── 0001_initial.py
│ │ ├── __init__.py
│ │ └── __pycache__
│ │ │ ├── 0001_initial.cpython-36.pyc
│ │ │ ├── 0001_initial.cpython-38.pyc
│ │ │ ├── __init__.cpython-36.pyc
│ │ │ └── __init__.cpython-38.pyc
│ │ ├── models.py
│ │ ├── static
│ │ ├── css
│ │ │ └── mystyles.css
│ │ ├── images
│ │ │ └── image1.png
│ │ └── mystyles.css
│ │ ├── templates
│ │ └── student
│ │ │ ├── data.html
│ │ │ ├── home.html
│ │ │ └── register.html
│ │ ├── tests.py
│ │ ├── urls.py
│ │ └── views.py
└── notes.txt
├── 30-06-2021
├── college
│ ├── college
│ │ ├── __init__.py
│ │ ├── __pycache__
│ │ │ ├── __init__.cpython-36.pyc
│ │ │ ├── __init__.cpython-38.pyc
│ │ │ ├── settings.cpython-36.pyc
│ │ │ ├── settings.cpython-38.pyc
│ │ │ ├── urls.cpython-36.pyc
│ │ │ ├── urls.cpython-38.pyc
│ │ │ ├── wsgi.cpython-36.pyc
│ │ │ └── wsgi.cpython-38.pyc
│ │ ├── settings.py
│ │ ├── urls.py
│ │ └── wsgi.py
│ ├── db.sqlite3
│ ├── manage.py
│ └── student
│ │ ├── __init__.py
│ │ ├── __pycache__
│ │ ├── __init__.cpython-36.pyc
│ │ ├── __init__.cpython-38.pyc
│ │ ├── admin.cpython-36.pyc
│ │ ├── admin.cpython-38.pyc
│ │ ├── models.cpython-36.pyc
│ │ ├── models.cpython-38.pyc
│ │ ├── urls.cpython-36.pyc
│ │ ├── urls.cpython-38.pyc
│ │ ├── views.cpython-36.pyc
│ │ └── views.cpython-38.pyc
│ │ ├── admin.py
│ │ ├── apps.py
│ │ ├── migrations
│ │ ├── 0001_initial.py
│ │ ├── __init__.py
│ │ └── __pycache__
│ │ │ ├── 0001_initial.cpython-36.pyc
│ │ │ ├── 0001_initial.cpython-38.pyc
│ │ │ ├── __init__.cpython-36.pyc
│ │ │ └── __init__.cpython-38.pyc
│ │ ├── models.py
│ │ ├── static
│ │ ├── css
│ │ │ └── mystyles.css
│ │ ├── images
│ │ │ └── image1.png
│ │ └── mystyles.css
│ │ ├── templates
│ │ └── student
│ │ │ ├── data.html
│ │ │ ├── home.html
│ │ │ ├── register.html
│ │ │ ├── student_data.html
│ │ │ └── student_register.html
│ │ ├── tests.py
│ │ ├── urls.py
│ │ └── views.py
└── notes.txt
├── FileUpload
├── FileUpload
│ ├── __init__.py
│ ├── __pycache__
│ │ ├── __init__.cpython-36.pyc
│ │ ├── settings.cpython-36.pyc
│ │ ├── urls.cpython-36.pyc
│ │ └── wsgi.cpython-36.pyc
│ ├── settings.py
│ ├── urls.py
│ └── wsgi.py
├── manage.py
├── media
│ └── users
│ │ ├── 2.jpg
│ │ ├── 22-226404_girl-wallpaper-hd-1080p-cute-little-a-sweet.jpg
│ │ ├── 22-226404_girl-wallpaper-hd-1080p-cute-little-a-sweet_I7vlnAO.jpg
│ │ ├── apssdc_final.jpg
│ │ └── apssdc_final_jErWHcl.jpg
└── myApp
│ ├── __init__.py
│ ├── __pycache__
│ ├── __init__.cpython-36.pyc
│ ├── admin.cpython-36.pyc
│ ├── forms.cpython-36.pyc
│ ├── models.cpython-36.pyc
│ ├── urls.cpython-36.pyc
│ └── views.cpython-36.pyc
│ ├── admin.py
│ ├── apps.py
│ ├── forms.py
│ ├── migrations
│ ├── 0001_initial.py
│ ├── __init__.py
│ └── __pycache__
│ │ ├── 0001_initial.cpython-36.pyc
│ │ └── __init__.cpython-36.pyc
│ ├── models.py
│ ├── templates
│ ├── data.html
│ └── profile.html
│ ├── tests.py
│ ├── urls.py
│ └── views.py
├── GreetingCardSender
├── GreetingCardSender
│ ├── __init__.py
│ ├── __pycache__
│ │ ├── __init__.cpython-38.pyc
│ │ ├── settings.cpython-38.pyc
│ │ ├── urls.cpython-38.pyc
│ │ └── wsgi.cpython-38.pyc
│ ├── asgi.py
│ ├── settings.py
│ ├── urls.py
│ └── wsgi.py
├── card
│ ├── __init__.py
│ ├── __pycache__
│ │ ├── __init__.cpython-38.pyc
│ │ ├── admin.cpython-38.pyc
│ │ ├── models.cpython-38.pyc
│ │ └── views.cpython-38.pyc
│ ├── admin.py
│ ├── apps.py
│ ├── migrations
│ │ ├── __init__.py
│ │ └── __pycache__
│ │ │ └── __init__.cpython-38.pyc
│ ├── models.py
│ ├── templates
│ │ └── index.html
│ ├── tests.py
│ └── views.py
├── db.sqlite3
├── manage.py
└── static
│ └── img
│ └── temp_pic.jpg
├── README.md
├── SampleProject
├── SampleProject
│ ├── __init__.py
│ ├── __pycache__
│ │ ├── __init__.cpython-38.pyc
│ │ ├── settings.cpython-38.pyc
│ │ ├── urls.cpython-38.pyc
│ │ └── wsgi.cpython-38.pyc
│ ├── asgi.py
│ ├── settings.py
│ ├── urls.py
│ └── wsgi.py
├── db.sqlite3
├── first_app
│ ├── __init__.py
│ ├── __pycache__
│ │ ├── __init__.cpython-38.pyc
│ │ ├── admin.cpython-38.pyc
│ │ ├── models.cpython-38.pyc
│ │ └── views.cpython-38.pyc
│ ├── admin.py
│ ├── apps.py
│ ├── migrations
│ │ ├── __init__.py
│ │ └── __pycache__
│ │ │ └── __init__.cpython-38.pyc
│ ├── models.py
│ ├── templates
│ │ ├── demo.html
│ │ ├── index.html
│ │ ├── say_hi.html
│ │ └── table.html
│ ├── tests.py
│ └── views.py
└── manage.py
├── Web Development Using Django.pptx
├── day 1 .txt
├── functions.md
├── git branch example.png
├── git branche_sample.png
├── loops.md
└── markdown-practice.md
/01-07-2021/Screenshot (135)_LI.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/Screenshot (135)_LI.jpg
--------------------------------------------------------------------------------
/01-07-2021/college/college/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/college/__init__.py
--------------------------------------------------------------------------------
/01-07-2021/college/college/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/college/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/college/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/college/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/college/__pycache__/settings.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/college/__pycache__/settings.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/college/__pycache__/settings.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/college/__pycache__/settings.cpython-38.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/college/__pycache__/urls.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/college/__pycache__/urls.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/college/__pycache__/urls.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/college/__pycache__/urls.cpython-38.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/college/__pycache__/wsgi.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/college/__pycache__/wsgi.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/college/__pycache__/wsgi.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/college/__pycache__/wsgi.cpython-38.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/college/urls.py:
--------------------------------------------------------------------------------
1 | """college URL Configuration
2 |
3 | The `urlpatterns` list routes URLs to views. For more information please see:
4 | https://docs.djangoproject.com/en/2.2/topics/http/urls/
5 | Examples:
6 | Function views
7 | 1. Add an import: from my_app import views
8 | 2. Add a URL to urlpatterns: path('', views.home, name='home')
9 | Class-based views
10 | 1. Add an import: from other_app.views import Home
11 | 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home')
12 | Including another URLconf
13 | 1. Import the include() function: from django.urls import include, path
14 | 2. Add a URL to urlpatterns: path('blog/', include('blog.urls'))
15 | """
16 | from django.contrib import admin
17 | from django.urls import path,include
18 |
19 | from student import views
20 |
21 | from django.conf import settings
22 | from django.conf.urls.static import static
23 |
24 |
25 | urlpatterns = [
26 | path('admin/', admin.site.urls),
27 | path('',views.home, name= 'home'),
28 |
29 | path("student/",include("student.urls")),
30 |
31 | path("user/",include("userAuth.urls")),
32 | ]
33 |
34 | if settings.DEBUG:
35 | urlpatterns += static(settings.MEDIA_URL,document_root = settings.MEDIA_ROOT)
36 |
--------------------------------------------------------------------------------
/01-07-2021/college/college/wsgi.py:
--------------------------------------------------------------------------------
1 | """
2 | WSGI config for college project.
3 |
4 | It exposes the WSGI callable as a module-level variable named ``application``.
5 |
6 | For more information on this file, see
7 | https://docs.djangoproject.com/en/2.2/howto/deployment/wsgi/
8 | """
9 |
10 | import os
11 |
12 | from django.core.wsgi import get_wsgi_application
13 |
14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'college.settings')
15 |
16 | application = get_wsgi_application()
17 |
--------------------------------------------------------------------------------
/01-07-2021/college/db.sqlite3:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/db.sqlite3
--------------------------------------------------------------------------------
/01-07-2021/college/manage.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | """Django's command-line utility for administrative tasks."""
3 | import os
4 | import sys
5 |
6 |
7 | def main():
8 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'college.settings')
9 | try:
10 | from django.core.management import execute_from_command_line
11 | except ImportError as exc:
12 | raise ImportError(
13 | "Couldn't import Django. Are you sure it's installed and "
14 | "available on your PYTHONPATH environment variable? Did you "
15 | "forget to activate a virtual environment?"
16 | ) from exc
17 | execute_from_command_line(sys.argv)
18 |
19 |
20 | if __name__ == '__main__':
21 | main()
22 |
--------------------------------------------------------------------------------
/01-07-2021/college/media/default.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/media/default.png
--------------------------------------------------------------------------------
/01-07-2021/college/media/users/2.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/media/users/2.jpg
--------------------------------------------------------------------------------
/01-07-2021/college/media/users/apssdc_final.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/media/users/apssdc_final.jpg
--------------------------------------------------------------------------------
/01-07-2021/college/media/users/apssdc_final_xegs8je.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/media/users/apssdc_final_xegs8je.jpg
--------------------------------------------------------------------------------
/01-07-2021/college/student/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/__init__.py
--------------------------------------------------------------------------------
/01-07-2021/college/student/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/__pycache__/admin.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/__pycache__/admin.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/__pycache__/admin.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/__pycache__/admin.cpython-38.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/__pycache__/forms.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/__pycache__/forms.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/__pycache__/forms.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/__pycache__/forms.cpython-38.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/__pycache__/models.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/__pycache__/models.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/__pycache__/models.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/__pycache__/models.cpython-38.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/__pycache__/urls.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/__pycache__/urls.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/__pycache__/urls.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/__pycache__/urls.cpython-38.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/__pycache__/views.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/__pycache__/views.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/__pycache__/views.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/__pycache__/views.cpython-38.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/admin.py:
--------------------------------------------------------------------------------
1 | from django.contrib import admin
2 | from .models import Register
3 |
4 |
5 | admin.site.register(Register)
--------------------------------------------------------------------------------
/01-07-2021/college/student/apps.py:
--------------------------------------------------------------------------------
1 | from django.apps import AppConfig
2 |
3 |
4 | class StudentConfig(AppConfig):
5 | name = 'student'
6 |
--------------------------------------------------------------------------------
/01-07-2021/college/student/forms.py:
--------------------------------------------------------------------------------
1 | from .models import ContactUs
2 | from django import forms
3 |
4 |
5 | class ContactForm(forms.ModelForm):
6 | class Meta:
7 | model = ContactUs
8 | fields = "__all__"
--------------------------------------------------------------------------------
/01-07-2021/college/student/migrations/0001_initial.py:
--------------------------------------------------------------------------------
1 | # Generated by Django 2.2.2 on 2021-06-30 05:20
2 |
3 | from django.db import migrations, models
4 |
5 |
6 | class Migration(migrations.Migration):
7 |
8 | initial = True
9 |
10 | dependencies = [
11 | ]
12 |
13 | operations = [
14 | migrations.CreateModel(
15 | name='Register',
16 | fields=[
17 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
18 | ('first_name', models.CharField(default='', max_length=30)),
19 | ('last_name', models.CharField(max_length=30)),
20 | ('email', models.EmailField(max_length=254, unique=True)),
21 | ('phone_num', models.CharField(max_length=10)),
22 | ('age', models.IntegerField(blank=True, null=True)),
23 | ],
24 | ),
25 | ]
26 |
--------------------------------------------------------------------------------
/01-07-2021/college/student/migrations/0002_contactus.py:
--------------------------------------------------------------------------------
1 | # Generated by Django 3.0.7 on 2021-07-02 05:08
2 |
3 | from django.db import migrations, models
4 |
5 |
6 | class Migration(migrations.Migration):
7 |
8 | dependencies = [
9 | ('student', '0001_initial'),
10 | ]
11 |
12 | operations = [
13 | migrations.CreateModel(
14 | name='ContactUs',
15 | fields=[
16 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
17 | ('name', models.CharField(max_length=10)),
18 | ('mail', models.EmailField(max_length=254)),
19 | ('gender', models.CharField(blank=True, choices=[('Male', 'male'), ('Female', 'female')], max_length=6, null=True)),
20 | ('phone', models.CharField(blank=True, max_length=10, null=True)),
21 | ('dob', models.DateField(blank=True, null=True)),
22 | ],
23 | ),
24 | ]
25 |
--------------------------------------------------------------------------------
/01-07-2021/college/student/migrations/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/migrations/__init__.py
--------------------------------------------------------------------------------
/01-07-2021/college/student/migrations/__pycache__/0001_initial.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/migrations/__pycache__/0001_initial.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/migrations/__pycache__/0001_initial.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/migrations/__pycache__/0001_initial.cpython-38.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/migrations/__pycache__/0002_contactus.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/migrations/__pycache__/0002_contactus.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/migrations/__pycache__/0002_contactus.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/migrations/__pycache__/0002_contactus.cpython-38.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/migrations/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/migrations/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/migrations/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/migrations/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/student/models.py:
--------------------------------------------------------------------------------
1 | from django.db import models
2 |
3 | class Register(models.Model):
4 | first_name = models.CharField(max_length=30,default="")
5 | last_name = models.CharField(max_length=30)
6 | email = models.EmailField(unique=True)
7 | phone_num = models.CharField(max_length = 10)
8 | age = models.IntegerField(null=True,blank=True)
9 |
10 | def __str__(self):
11 | return self.first_name
12 |
13 | class ContactUs(models.Model):
14 | name = models.CharField(max_length=10)
15 | mail = models.EmailField()
16 | Gender_choices = (('Male','male'),
17 | ('Female','female'))
18 | gender = models.CharField(max_length=6, choices=Gender_choices,
19 | blank=True, null=True)
20 | phone = models.CharField(max_length=10,blank=True, null=True)
21 | dob = models.DateField(blank=True, null=True)
22 |
23 | def __str__(self):
24 | return self.name
--------------------------------------------------------------------------------
/01-07-2021/college/student/static/css/mystyles.css:
--------------------------------------------------------------------------------
1 | h3{
2 | color:green;
3 | font-size:20px !important;
4 | }
5 |
6 | .phone{
7 | font-size:40px;
8 | }
9 |
10 | #phone{
11 | font-size:60px;
12 | color:yellow;
13 | }
14 |
15 | #phone{
16 | color:red;
17 | }
--------------------------------------------------------------------------------
/01-07-2021/college/student/static/images/image1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/student/static/images/image1.png
--------------------------------------------------------------------------------
/01-07-2021/college/student/static/mystyles.css:
--------------------------------------------------------------------------------
1 | h3{
2 | color:green;
3 | font-size:20px !important;
4 | }
5 |
6 | .phone{
7 | font-size:40px;
8 | }
9 |
10 | #phone{
11 | font-size:60px;
12 | color:yellow;
13 | }
14 |
15 | #phone{
16 | color:red;
17 | }
18 | .image{
19 | background-color:lightblue;
20 | wid
21 | }
--------------------------------------------------------------------------------
/01-07-2021/college/student/templates/student/base.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Student
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 | {% include 'student/navbar.html' %}
14 | {% include 'student/messages.html' %}
15 | {% block foo %}
16 |
17 | {% endblock %}
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/01-07-2021/college/student/templates/student/contact.html:
--------------------------------------------------------------------------------
1 | {% extends 'student/base.html' %}
2 | {% block foo %}
3 |
14 |
15 | {% endblock %}
16 |
--------------------------------------------------------------------------------
/01-07-2021/college/student/templates/student/data.html:
--------------------------------------------------------------------------------
1 | {% load static %}
2 |
3 |
4 |
5 |
6 |
7 | Data
8 |
9 |
16 |
17 |
18 |
19 |
20 |

21 |
22 | This is Inline CSS
23 | Name : {{ data.name }}
24 | Email : {{ data.mail }}
25 | Phone Number : {{ data.phone}}
26 | Age : {{ data.age }}
27 |
28 |
29 |
--------------------------------------------------------------------------------
/01-07-2021/college/student/templates/student/details.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | {{data.first_name}} Details
5 |
6 |
7 |
8 |
9 |
10 |
{{data.first_name}} Details
11 |
12 |
13 | First Name |
14 | {{ data.first_name }} |
15 |
16 |
17 | Last Name |
18 | {{ data.last_name }} |
19 |
20 |
21 | Email |
22 | {{ data.email }} |
23 |
24 |
25 | Phone Number |
26 | {{ data.phone_num }} |
27 |
28 |
29 | Age |
30 | {{ data.age }} |
31 |
32 |
33 |
34 |
35 |
36 |
--------------------------------------------------------------------------------
/01-07-2021/college/student/templates/student/home.html:
--------------------------------------------------------------------------------
1 | {% extends 'student/base.html' %}
2 |
3 | {% block foo %}
4 |
5 | Welcome {{request.user}}
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |

16 |
17 |
18 |

19 |
20 |
21 |

22 |
23 |
24 |
28 |
32 |
33 |
34 | {% endblock %}
--------------------------------------------------------------------------------
/01-07-2021/college/student/templates/student/messages.html:
--------------------------------------------------------------------------------
1 | {% if messages %}
2 | {% for message in messages %}
3 | {% if message.tags %} {% endif %}
4 |
5 | {% endfor %}
6 |
7 | {% endif %}
--------------------------------------------------------------------------------
/01-07-2021/college/student/templates/student/navbar.html:
--------------------------------------------------------------------------------
1 |
2 |
23 |
--------------------------------------------------------------------------------
/01-07-2021/college/student/templates/student/register.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Student Registration
5 |
6 |
7 |
16 |
17 |
--------------------------------------------------------------------------------
/01-07-2021/college/student/templates/student/student_data.html:
--------------------------------------------------------------------------------
1 |
2 | {% extends 'student/base.html' %}
3 | {% block foo %}
4 | {% load static %}
5 |
6 |
Student Data
7 |
8 |
9 | First Name |
10 | Last Name |
11 | Email |
12 | Phone |
13 | Age |
14 |
15 | {% for i in data %}
16 |
17 | {{i.first_name}} |
18 | {{i.last_name}} |
19 | {{i.email}} |
20 | {{i.phone_num}} |
21 | {{i.age}} |
22 |
23 |
26 | |
27 |
28 |
31 | |
32 |
33 | {% endfor %}
34 |
35 |
36 | {% endblock %}
--------------------------------------------------------------------------------
/01-07-2021/college/student/templates/student/student_register.html:
--------------------------------------------------------------------------------
1 | {% extends 'student/base.html' %}
2 | {% block foo %}
3 |
4 |
Registration Form
5 |
24 |
25 | {% endblock %}
--------------------------------------------------------------------------------
/01-07-2021/college/student/templates/student/update.html:
--------------------------------------------------------------------------------
1 | {% extends 'student/base.html' %}
2 | {% block foo %}
3 |
25 | {% endblock %}
--------------------------------------------------------------------------------
/01-07-2021/college/student/tests.py:
--------------------------------------------------------------------------------
1 | from django.test import TestCase
2 |
3 | # Create your tests here.
4 |
--------------------------------------------------------------------------------
/01-07-2021/college/student/urls.py:
--------------------------------------------------------------------------------
1 | from django.urls import path
2 | from . import views
3 |
4 |
5 | urlpatterns = [
6 | path("register/",views.register),
7 | path("contact_us/", views.contact_us, name='contact'),
8 | path("student_register/",views.StudentRegistration, name='register'),
9 | path("student_data/",views.StudentData,name="all_data"),
10 | path("/",views.student,name="details"),
11 | path("update/",views.update,name="update"),
12 | path("delete/",views.delete,name="delete"),
13 | ]
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/userAuth/__init__.py
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/userAuth/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/__pycache__/admin.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/userAuth/__pycache__/admin.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/__pycache__/forms.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/userAuth/__pycache__/forms.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/__pycache__/models.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/userAuth/__pycache__/models.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/__pycache__/urls.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/userAuth/__pycache__/urls.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/__pycache__/views.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/userAuth/__pycache__/views.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/admin.py:
--------------------------------------------------------------------------------
1 | from django.contrib import admin
2 |
3 | # Register your models here.
4 |
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/apps.py:
--------------------------------------------------------------------------------
1 | from django.apps import AppConfig
2 |
3 |
4 | class UserauthConfig(AppConfig):
5 | name = 'userAuth'
6 |
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/forms.py:
--------------------------------------------------------------------------------
1 | from django.contrib.auth.forms import UserCreationForm
2 | from django.contrib.auth.models import User
3 | from django.forms import ModelForm
4 |
5 | from .models import *
6 |
7 |
8 | class UserReg(UserCreationForm):
9 | class Meta:
10 | model = User
11 | fields = ["first_name","last_name","username","email"]
12 |
13 |
14 |
15 | class ProfileForm(ModelForm):
16 | class Meta:
17 | model = profileDetails
18 | fields = ["branch","phone","roll","image"]
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/migrations/0001_initial.py:
--------------------------------------------------------------------------------
1 | # Generated by Django 2.2.2 on 2021-07-06 04:36
2 |
3 | from django.conf import settings
4 | from django.db import migrations, models
5 | import django.db.models.deletion
6 |
7 |
8 | class Migration(migrations.Migration):
9 |
10 | initial = True
11 |
12 | dependencies = [
13 | migrations.swappable_dependency(settings.AUTH_USER_MODEL),
14 | ]
15 |
16 | operations = [
17 | migrations.CreateModel(
18 | name='profileDetails',
19 | fields=[
20 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
21 | ('branch', models.CharField(choices=[('CSE', 'cse'), ('ECE', 'ece'), ('IT', 'it'), ('CE', 'ce'), ('MECH', 'mech')], max_length=10)),
22 | ('phone', models.CharField(max_length=10)),
23 | ('roll', models.CharField(max_length=20)),
24 | ('user', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
25 | ],
26 | ),
27 | ]
28 |
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/migrations/0002_profiledetails_image.py:
--------------------------------------------------------------------------------
1 | # Generated by Django 2.2.2 on 2021-07-08 05:48
2 |
3 | from django.db import migrations, models
4 |
5 |
6 | class Migration(migrations.Migration):
7 |
8 | dependencies = [
9 | ('userAuth', '0001_initial'),
10 | ]
11 |
12 | operations = [
13 | migrations.AddField(
14 | model_name='profiledetails',
15 | name='image',
16 | field=models.ImageField(default='default.png', upload_to='users/'),
17 | ),
18 | ]
19 |
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/migrations/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/userAuth/migrations/__init__.py
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/migrations/__pycache__/0001_initial.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/userAuth/migrations/__pycache__/0001_initial.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/migrations/__pycache__/0002_profiledetails_image.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/userAuth/migrations/__pycache__/0002_profiledetails_image.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/migrations/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/college/userAuth/migrations/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/models.py:
--------------------------------------------------------------------------------
1 | from django.db import models
2 | from django.contrib.auth.models import User
3 |
4 | # Create your models here.
5 |
6 | class profileDetails(models.Model):
7 | branches = (
8 | ("CSE","cse"),
9 | ("ECE","ece"),
10 | ("IT","it"),
11 | ("CE","ce"),
12 | ("MECH","mech")
13 | )
14 | branch = models.CharField(max_length=10,choices = branches)
15 | phone = models.CharField(max_length=10)
16 | roll = models.CharField(max_length=20)
17 | image = models.ImageField(upload_to="users/",default="default.png")
18 | user = models.OneToOneField(User,on_delete = models.CASCADE)
19 |
20 |
21 | def __str__(self):
22 | return self.user.first_name
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/templates/authlogin.html:
--------------------------------------------------------------------------------
1 | {% extends "student/base.html" %}
2 |
3 |
4 | {% block foo %}
5 |
6 |
Login
7 |
12 |
13 |
14 |
15 | {% endblock %}
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/templates/authlogout.html:
--------------------------------------------------------------------------------
1 | {% extends "student/base.html" %}
2 |
3 |
4 | {% block foo %}
5 |
6 |
User logged out successfully
7 | Click here to login again
Login
8 |
9 |
10 |
11 | {% endblock %}
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/templates/login.html:
--------------------------------------------------------------------------------
1 | {% extends "student/base.html" %}
2 |
3 |
4 | {% block foo %}
5 |
6 |
7 |
8 |
9 |
18 |
19 |
22 |
23 |
24 |
25 |
26 |
27 |
28 | {% endblock %}
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/templates/profile.html:
--------------------------------------------------------------------------------
1 | {% extends "student/base.html" %}
2 |
3 | {% block foo %}
4 |
5 |
6 |
7 |
8 |

9 |
{{u.first_name}} {{u.last_name}}
10 |
11 |
12 |
13 |
14 | First Name |
15 | {{ u.first_name }} |
16 |
17 |
18 | Last Name |
19 | {{ u.last_name }} |
20 |
21 |
22 | Username |
23 | {{ u.username }} |
24 |
25 |
26 | Roll Number |
27 | {{ p.roll }} |
28 |
29 |
30 | Email |
31 | {{ u.email }} |
32 |
33 |
34 | Phone |
35 | {{ p.phone }} |
36 |
37 |
38 | Branch |
39 | {{ p.branch }} |
40 |
41 |
42 |
43 |
46 |
47 |
48 |
49 |
50 | {% endblock %}
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/templates/profile_details.html:
--------------------------------------------------------------------------------
1 | {% extends "student/base.html" %}
2 |
3 |
4 | {% block foo %}
5 |
6 |
7 |
16 |
17 |
18 | {% endblock %}
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/templates/signup.html:
--------------------------------------------------------------------------------
1 | {% extends "student/base.html" %}
2 |
3 |
4 | {% block foo %}
5 |
6 |
12 |
13 |
14 | {% endblock %}
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/templates/update.html:
--------------------------------------------------------------------------------
1 | {% extends "student/base.html" %}
2 |
3 |
4 | {% block foo %}
5 |
6 |
13 |
14 | {% endblock %}
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/tests.py:
--------------------------------------------------------------------------------
1 | from django.test import TestCase
2 |
3 | # Create your tests here.
4 |
--------------------------------------------------------------------------------
/01-07-2021/college/userAuth/urls.py:
--------------------------------------------------------------------------------
1 | from django.urls import path
2 | from . import views
3 | from django.contrib.auth import views as authViews
4 |
5 |
6 | urlpatterns = [
7 | path("signup/",views.signup,name="signup"),
8 | path("signin/",views.signin,name="signin"),
9 | path("singout/",views.signout,name="signout"),
10 |
11 | path("authLogin/",authViews.LoginView.as_view(template_name="authlogin.html"),name="login"),
12 | path("authLogout/",authViews.LogoutView.as_view(template_name="authlogout.html"),name="logout"),
13 |
14 | path("profileDetails/",views.profile_details,name="profile_details"),
15 | path("profile/",views.profile,name="profile"),
16 | path("update/",views.update,name="update"),
17 | ]
18 |
--------------------------------------------------------------------------------
/01-07-2021/mysqlclient-2.0.3-cp36-cp36m-win_amd64.whl:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/01-07-2021/mysqlclient-2.0.3-cp36-cp36m-win_amd64.whl
--------------------------------------------------------------------------------
/10 jun 2021.txt:
--------------------------------------------------------------------------------
1 | Good Morning !!
2 |
3 | topics:
4 | -----------
5 | git commit
6 | undoing the commits
7 | Delete commits
8 |
9 | Markdown syntax
10 |
11 | github pages
12 | ----------------
13 | clone a repository : git clone remote_url
14 |
15 | to convert files into stagging area : git add file_name
16 |
17 | commit is a code shapshot, it will store information regarding
18 | change on our code.
19 | 40 digit unique code (SHA-1) secure Hash Algorithm.
20 |
21 | git checkout sha-Key : we will get that perticualr version of code
22 |
23 | git checkout main: to get back to our latest version from
24 | older version.
25 |
26 | if you want to delete only the commit message
27 | git reset HEAD^ :it will delete our latest commit msg
28 |
29 | git reset --hard HEAD^ : this command can delete files also
30 |
31 |
32 | if you want to delete a specific commit:
33 | git revert SHA-1
34 |
35 | delete a commit without history
36 | git rebase -i sha-Key
37 |
38 |
39 |
--------------------------------------------------------------------------------
/11-06-2021/Python Programming.pptx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/11-06-2021/Python Programming.pptx
--------------------------------------------------------------------------------
/11-06-2021/first.py:
--------------------------------------------------------------------------------
1 | # This is a comment
2 |
3 | # Output
4 | # print(This is my first program)
5 |
6 | print("This is my First Python Program")
7 |
8 | # If we want to print a message in python, we have to enclose the message in
9 | # single/double quotes
10 |
11 |
12 | var = 123
13 | print(var)
14 | print(type(var))
15 |
16 |
17 | college = "SRM AP"
18 |
19 | print(college)
20 | print(type(college))
21 |
22 |
23 |
24 | print(type(9.8))
25 |
26 |
27 | print(type("s"))
28 |
29 |
30 |
31 | print(type(True))
32 | print(type("asdkjfahsdfkjhakjdf"))
33 | print(type(None))
34 |
35 |
36 |
37 |
--------------------------------------------------------------------------------
/11-06-2021/integers.py:
--------------------------------------------------------------------------------
1 | # Integers
2 | # positve, negative and zero excluding decimal values (....-3,-3,-1,0,1,2,3,4......)
3 |
4 | student_1 = 211
5 | print(student_1)
6 |
7 |
8 |
9 | import keyword
10 |
11 | print(keyword.kwlist)
12 |
13 |
14 | var1 = 1
15 | var2 = 2
16 |
17 | print(var1+var2)
18 |
19 | speed_of_light = 3*(10**100)
20 | print(speed_of_light)
21 | print(type(speed_of_light))
22 |
--------------------------------------------------------------------------------
/11-06-2021/note.txt:
--------------------------------------------------------------------------------
1 | Python
2 | -------------
3 | -> Interpreted Language : The execution of the program is line by line. The execution stops where the error occur
4 | -> Hihg level : Programmer frinedly language
5 | -> Dynamic : We don't need to define the data type of variables
6 | and There is automatic memory management and automatic garbage collection.
7 | -> Case sensitve : Var != var
8 | -> Python supports both the programming paradigms
9 | -> Functional Programming
10 | -> Objec oriented Programming
11 | -> Variable : It holds the reference to the value
12 | -> can contain [A-Z] ,[a-z],[0-9] and _
13 | -> should not start with numbers
14 | -> we cannot use keywords as variable names
15 | -> Keywords:
16 | ['False', 'None', 'True', 'and', 'as', 'assert', 'break', 'class', 'continue', 'def', 'del', 'elif', 'else', 'except', 'finally', 'for', 'from', 'global', 'if', 'import', 'in', 'is', 'lambda', 'nonlocal', 'not', 'or', 'pass', 'raise', 'return', 'try', 'while', 'with', 'yield']
17 | -> Data Types :
18 | -> Integer
19 | -> Float
20 | -> String : sequence of characters
21 | -> Boolean : True or False / 1 or 0
22 | -> None Type : None
23 | 4.3
24 | floor(4.3) = 4 -> nearest integer which is less than the float value
25 | ceil(4.3) = 5 -> nearest integer which is greater than the float value
26 |
27 | - round(value,length) => To limit the number of decimal points
28 |
29 | and: Both the inputs true then only output is true
30 | or : True if any one of the inputs is true
31 | a b and or
32 | 0 0 0 0
33 | 0 1 0 1
34 | 1 0 0 1
35 | 1 1 1 1
36 |
37 | not: To invert the input
38 | i/p o/p
39 | 0 1
40 | 1 0
--------------------------------------------------------------------------------
/12-06-2021/condtional_statments.py:
--------------------------------------------------------------------------------
1 | # Conditional Statements
2 | # Condition : It is an expression which returns either True or False
3 | # if, elif, else, nested if
4 |
5 |
6 | if 2==2:
7 | print("This is if block")
8 | print(1+2)
9 |
10 | else:
11 | print("This is else block")
12 | print(1-2)
13 |
14 |
15 | a = 3
16 | b = 2
17 |
18 | if a==b:
19 | print("Equal")
20 | elif a>=b:
21 | print(a)
22 | else:
23 | print(b)
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
--------------------------------------------------------------------------------
/12-06-2021/divisible_by_10_and_5.py:
--------------------------------------------------------------------------------
1 | # Write a program which takes a number from the user
2 | # if number is divisible by 10 : o/p: divisible by 10
3 | # else if number is divisible by 5 : o/p: divisible by 5
4 | # else: print the number
5 |
6 | num = int(input())
7 | if num%10==0:
8 | print("Divisible by 10")
9 | elif num%5==0:
10 | print("Divisible by 5")
11 | else:
12 | print(num)
13 |
--------------------------------------------------------------------------------
/12-06-2021/divisible_by_5.py:
--------------------------------------------------------------------------------
1 | # Write a program to check whether a given number is divisible by 5 or not
2 | # input() :To take the input from the user
3 |
4 | # int() : To convert the value to integer
5 | # float() :To convert the value to float
6 | # str() : To convert the value to string
7 | n = int(input())
8 |
9 | if n%5 == 0:
10 | print("It is Divisible by 5")
11 | else:
12 | print("It is not divisible by 5")
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/12-06-2021/even_odd.py:
--------------------------------------------------------------------------------
1 | c = -13
2 |
3 | if c>0:
4 | if c%2==0:
5 | print("even")
6 | else:
7 | print("odd")
8 | else:
9 | print("Negative")
10 |
--------------------------------------------------------------------------------
/12-06-2021/notes.txt:
--------------------------------------------------------------------------------
1 | Day Objectives:
2 | ===============
3 | ->Bitwise Operators
4 | Itentity Operator
5 | Membership Operators
6 |
7 | ->Strings
8 | ->Conditional Statements
9 |
10 | # Bitwise Operators(|,&, ~, <<, >>, ^)
11 |
12 | 0 000
13 | 1 001
14 | 2 010
15 | 3 011
16 | 4 100
17 | 5 101
18 |
19 |
20 | or: 2 | 3
21 |
22 | 0010
23 | 0011
24 | -----
25 | 0101 ---> 5
26 |
27 |
28 | and : 2 & 3
29 | 0010
30 | 0011
31 | -----
32 | 0010 ---> 2
33 |
34 | 1010
35 | 0101
36 | -----
37 | 1111 ---> 15
38 | 0000 ---> 0
39 |
40 | Bitwise not : It is 1's compliment of the number
41 | ~(a) = ~(1010)
42 | = -(1010+1)
43 | = -(1011)
44 | = -11
45 | Left shift operator(<<): Performs Multiplication
46 |
47 | a<<1 : 10 * 2^1 = 10*2 =20
48 | a<<2 : 10*2^2 = 10*4 = 40
49 | a<<5 : 10*2^5 = 10*32 = 320
50 |
51 |
52 | Right shift Operator(>>) : Performs Division
53 | a>>1 : 10 / 2^1 = 5
54 | a>>3 : 10 / 2^3 = 10/8 = 1
55 |
56 | Bitwise XOR(^): Performs Addition
57 |
58 | a^b
59 |
60 | 1010
61 | 0101
62 | -----
63 | 1111 ---> 15
64 |
65 | # Conditional Statements
66 | # Condition : It is an expression which returns either True or False
67 | # if, elif, else, nested if
68 | if condition:
69 |
70 | statment 1
71 | statement 2
72 | ...
73 |
74 | else:
75 | statements
76 |
77 | # elif : Only execute if the "if" condition is False
78 |
79 |
80 |
81 | #Negative Indexing
82 |
83 | s = "python"
84 | 012345
85 | -6-5-4-3-2-1
86 |
87 | # slicing : To access a group of characters at a time
88 |
89 | string [ start_index : end_index : step ]
90 |
--------------------------------------------------------------------------------
/12-06-2021/operators.py:
--------------------------------------------------------------------------------
1 | # Bitwise Operators(|,&, ~, <<, >>, ^)
2 |
3 | a = 10
4 | b = 5
5 |
6 | print("Bitwise OR(|):",a|b)
7 | print("Bitwise AND(&):",a&b)
8 | print("Bitwise NOT(~):",~(a))
9 | print("Bitwise left shift(<<):",a<<2)
10 | print("Bitwise right shift(>>):",a>>2)
11 | print("Bitwise XOR(^):",a^b)
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/12-06-2021/strings.py:
--------------------------------------------------------------------------------
1 | # Strings : A sequence of characters is called a string
2 | # we represent a string with single/double quotes("",'')
3 | # Strings are ordered and Iterable
4 |
5 | s = "Python"
6 | s1 = "srmap"
7 | s2 = "SrmAP"
8 | a=4
9 |
10 | print(s[3])
11 | # len(): To get the length of the string
12 | print(len(s))
13 | # dir(): To get all the methods available
14 | print(dir(s))
15 | # capitalize()
16 | print("Capitalize():",s1.capitalize())
17 | print("upper():",s.upper())
18 | print("lower():",s.lower())
19 | print("casefold():",s1.casefold()==s2.casefold())
20 | print("isupper():",s.isupper())
21 | print("islower():",s.islower())
22 | print("index():",s.index("h"))
23 | print("replace():",s.replace("t","T"))
24 |
25 | # Negative Indexing:
26 | print(s[-3])
27 | # Slicing
28 |
29 | s = "python Programming srmap"
30 | s1 = ""
31 | s1 = s1+s[0]
32 | s1 = s1+s[1]
33 | s1 = s1+s[2]
34 | s1 +=s[4]
35 | print(s1)
36 |
37 |
38 | s2 = s[0:6]
39 | print(s2)
40 | print(s[1:6])
41 | print("All the chars:",s[:])
42 | print(s[4:])
43 | print(s[5:8])# s[5],s[6],s[7]
44 | print(s[15:])
45 | print(s[-3:])
46 | print(s[0:6:1])
47 | print(s[0:6:2])
48 | print(s[::3]) #ph oai m
49 | print(s[-1:-5:-2])#-1, -1-2 = -3, -3-2 = -5
50 | print(s[-1::-1]) #-1, -1-1=-2,-2-1 = -3,...
51 | print(s[::3]) #ph
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
--------------------------------------------------------------------------------
/14 jun 2021/char count.py:
--------------------------------------------------------------------------------
1 | # take statemengt from input funtion and then calculate count of upper characters
2 | # lower chars, special chars, space
3 |
4 | # input
5 | # 'APSSDC Python Programming'
6 |
7 | #output
8 | # upper chars are 8, lower are 23, spaces are 3, speciacl chars are 0
9 |
10 | u,l,g,s,d = 0,0,0,0,0
11 | string = input('::')
12 | for char in string:
13 | if char.islower():
14 | l += 1
15 | elif char.isupper():
16 | u += 1
17 | elif char.isspace():
18 | g += 1
19 | elif char.isdigit():
20 | d += 1
21 | else:
22 | s += 1
23 | print('upper chars are {}, lower are {}, spaces are {}, speciacl chars are {}and digits are {}'.format(u,l,g,s, d))
24 |
25 |
--------------------------------------------------------------------------------
/14 jun 2021/for_loop.py:
--------------------------------------------------------------------------------
1 | # for loop
2 |
3 | # range(4)
4 |
5 | #for i in range(4):
6 | # print(i)
7 |
8 | #for i in range(2,4+1):
9 | # print(i)
10 |
11 |
12 | for i in range(1,10,3):
13 | print(i)
14 |
--------------------------------------------------------------------------------
/14 jun 2021/leap year.py:
--------------------------------------------------------------------------------
1 | # write a program to find all the leap years between 1900 to 2020
2 | # it should be divisible by 4
3 | # 100 is not a leep year
4 | # the year 400 is a leep year
5 |
6 | for year in range(1900,2020):
7 | if (year % 4 == 0 and year % 100 != 0) or year % 400 == 0:
8 | print(year, end=', ')
9 |
--------------------------------------------------------------------------------
/14 jun 2021/multiple.py:
--------------------------------------------------------------------------------
1 | # create a table based on given input
2 | #n = int(input('Enter a value: '))
3 | #for i in range(1,11):
4 | # print(n,'*', i,'=', n*i)
5 |
6 |
7 | n = int(input('Enter a value: '))
8 | start = int(input('starting value: '))
9 | end= int(input('ending value : '))
10 | for i in range(start,end+1):
11 | print(n,'*', i,'=', n*i)
12 |
--------------------------------------------------------------------------------
/14 jun 2021/string_in_for.py:
--------------------------------------------------------------------------------
1 | # using string in for loop
2 |
3 | string = 'python'
4 | for char in string:
5 | print(char, '!!', end='',sep='&&')
6 | print('----', end='')
7 |
--------------------------------------------------------------------------------
/14 jun 2021/termination.py:
--------------------------------------------------------------------------------
1 | for i in range(10):
2 | if i % 2 == 0:
3 | print('continue')
4 | continue
5 | elif i == 5:
6 | print('break')
7 | break
8 |
--------------------------------------------------------------------------------
/14 jun 2021/while loop.py:
--------------------------------------------------------------------------------
1 | # while loop
2 |
3 | #a = 1
4 | #while a <= 5:
5 | # print(a)
6 | # a += 1
7 |
8 | val = 0
9 | while val <= 10:
10 | if val% 2 == 0:
11 | print(val)
12 | val += 1
13 | continue
14 | elif val == 5:
15 | print('loop is terminated')
16 | break
17 | else: print('this is from else: ')
18 | val += 1
19 |
--------------------------------------------------------------------------------
/15 june 2021/1_List.py:
--------------------------------------------------------------------------------
1 | # define with []
2 | # l = [1,2,3,4,5]
3 | # print(type(l))
4 |
5 | # a = list(1,2,3,4)
6 | # TypeError: list expected at most 1 argument, got 4
7 | # print(type(a),a)
8 |
9 | # a = list([1,2,3,4]) #list((1,2,3,4))
10 | # print(type(a),a)
11 |
12 | # it will create a empty list
13 | #b = list()
14 | #print(type(b),b)
15 |
16 | # we can also create a empty list by using []
17 |
18 |
19 | # converting a string into list
20 | #string = 'python'
21 | #list_str = list(string)
22 | #print('converted string', list_str)
23 |
24 | # we can not convert a string to list
25 | #string = 'python'
26 | #str_to_list = [string]
27 | #print(str_to_list, type(str_to_list))
28 |
29 | # by using string method we can convert string to list
30 | string = 'python'
31 | str_list = string.split('t')
32 | print(str_list, type(str_list))
33 |
34 |
--------------------------------------------------------------------------------
/15 june 2021/1_sample function.py:
--------------------------------------------------------------------------------
1 | # a simple function without arguments and without return
2 | def sample():
3 | print('i\'m from sample function')
4 | #print("i'm from sample function")
5 |
6 |
7 |
8 | print(sample())
9 |
10 |
--------------------------------------------------------------------------------
/15 june 2021/2_adding.py:
--------------------------------------------------------------------------------
1 | # Required arguments
2 | def add_2_values(a,b):
3 | return a+b
4 |
5 | a = int(input("Enter value for a: "))
6 | b = int(input('Enter value for B: '))
7 |
8 | print(add_2_values(a,b))
9 |
--------------------------------------------------------------------------------
/15 june 2021/2_list_homogeneous.py:
--------------------------------------------------------------------------------
1 | #list is not a homogeneous array.
2 | l = [1,2,2.4,5.7, 'a','b',['a',4,6]]
3 | print(l, type(l))
4 |
5 |
6 | # list has type indexing
7 | # positive index: 0,..,n-1 (n - is length of the list)
8 | # negative index:-n,-n-1,..-1
9 | print('l[3] :', l[3]) # 5.7
10 | print('l[-2] :',l[-2])
11 | print('l[-1][1] :',l[-1][1]) # 4
12 |
13 |
14 | # what does mutability in list
15 | l[1] = 1000
16 | print(l)
17 |
18 |
19 | # use slicing for list.
20 | # [start:end:step]
21 | print(l[1::])
22 | print(l[-1::-1])# -1 -2 -3
23 | print(l[::-1])
24 |
--------------------------------------------------------------------------------
/15 june 2021/3_keyword_arguments.py:
--------------------------------------------------------------------------------
1 | # KEy word arguments
2 | def sample_keyword(nm,age):
3 | result = 'after 5 years '+nm+' '+'age is '+str(age+5)
4 | return result
5 |
6 | name = input('Enter Name :')
7 | age = int(input('Enter Age :'))
8 |
9 | print(sample_keyword(name,age))
10 |
11 |
--------------------------------------------------------------------------------
/15 june 2021/3_list methods.py:
--------------------------------------------------------------------------------
1 | #'append', 'clear', 'copy', 'count', 'extend',
2 | #'index', 'insert', 'pop',
3 | #'remove', 'reverse', 'sort'
4 |
5 | L = [1,2,3,4,3]
6 | # append
7 | L.append('from append')
8 | print(L)
9 |
10 | # Count
11 | #print('count of value 2 :',L.count(2))
12 | #print('value is not in our list :',L.count(100))
13 |
14 | # clear is used remove all elements from our list
15 |
16 | #Copy
17 | #Copy_l = L
18 | #print('ID of L: ',id(L))
19 | #print('ID of Copy_l: ',id(Copy_l))
20 | #L.append(10000)
21 | #print('ID of L: ',id(L),L)
22 | #print('ID of Copy_l: ',id(Copy_l),Copy_l)
23 |
24 | #copy2 = L.copy()
25 | #print('ID of L: ',id(L),L)
26 | #print('ID of Copy_2: ',id(copy2),copy2)
27 |
28 | # extend is like concatination
29 | print([1,2]+[3,4])
30 | a = [1,2]
31 | a.extend([3,4])
32 | print(a)
33 |
--------------------------------------------------------------------------------
/15 june 2021/4_default arguments.py:
--------------------------------------------------------------------------------
1 | # Default arguments
2 |
3 | def age_after_5_years(name=' ', age=0):
4 | result = name +' age after 5 years is '+str(age+5)
5 | return result
6 |
7 | name = input("Enter name :")
8 | age = int(input("Enter age :"))
9 |
10 | print(age_after_5_years(name, age))
11 |
--------------------------------------------------------------------------------
/15 june 2021/5_variable_length.py:
--------------------------------------------------------------------------------
1 | # Variable length arguments
2 | # Exmple for Variable length arguments in builtin functions is
3 | # print
4 |
5 | # it can take any number of inputs
6 |
7 | def variable_length(*val):
8 | return val
9 |
10 |
--------------------------------------------------------------------------------
/15 june 2021/6_cubes_of_average_evennums.py:
--------------------------------------------------------------------------------
1 | # write a func to return average of cubes of all even numbers in between range
2 | #upper limit is inclusive
3 |
4 | def cubes_of_avg(lv,uv):
5 | s = 0
6 | c = 0
7 | for i in range(lv,uv+1):
8 | if i%2 == 0:
9 | s = s+i**3
10 | c += 1
11 | return s//c
12 |
13 | lv = int(input('lower limit: '))
14 | uv = int(input('upper limit: '))
15 |
16 | print(cubes_of_avg(lv,uv))
17 |
--------------------------------------------------------------------------------
/16-06-2021/Tasks.txt:
--------------------------------------------------------------------------------
1 | -> Kth largest number in a list
2 |
3 | -> Find all the pairs whose sum is k
4 |
5 | -> Find mean and median of elements in a list
6 |
7 | -> Write a Python program to remove an item from a tuple.
8 |
9 | ->Write a Python program to reverse a tuple.
10 |
11 | -> Write a Python program to find maximum and the minimum value in a set.
12 |
13 | -> Write a Python Program to print multiplication and sum of all the elements in a set.
14 |
--------------------------------------------------------------------------------
/16-06-2021/Tuples & Sets.pptx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/16-06-2021/Tuples & Sets.pptx
--------------------------------------------------------------------------------
/16-06-2021/leap_years_in_range.py:
--------------------------------------------------------------------------------
1 | # Write a program to find all the leap years in a given range
2 | # Gregorian Calender : one year = 365.246..
3 |
4 | def is_leap_year(year):
5 | if year%4==0 and (year%100!=0 or year%400==0):
6 | return True
7 | return False
8 |
9 |
10 |
11 | start_year = int(input())
12 | end_year = int(input())
13 |
14 | for year in range(start_year,end_year+1):
15 | result = is_leap_year(year)
16 | if result:
17 | print(year)
18 |
--------------------------------------------------------------------------------
/16-06-2021/set_methods.py:
--------------------------------------------------------------------------------
1 | # set methods
2 |
3 | print(dir(set()))
4 |
5 | set1 = {1,2,3,4,5}
6 | set2 = {1,2,5,6,7}
7 |
8 |
9 | # union(): To combine all the elements in both sets
10 | # intersection(): The elements common to both sets
11 |
12 | print("Union:",set1.union(set2), set1 | set2)
13 | print("Intersection:", set1.intersection(set2), set1 & set2 )
14 | print("Difference:",set1.difference(set2), set1-set2)
15 | set1.difference_update(set2) #set1 = set1 - set2 #set1 = {3,4}
16 | set2.difference_update(set1) #set2 = set2-set1
17 | print(set1)
18 | print(set2)
19 |
20 | #subset : A set is called as subset when all the elements
21 | # in this set available in another set
22 | # disjoint sets : There is no single common element between both sets
23 | set1 = {1,2,3,4,5}
24 | set2 = {1,2,5,6,7}
25 | set3 = {1,2,3}
26 | set4 = {4,5,6}
27 | print("subset:",set3.issubset(set1)) # True
28 | print("superset:",set1.issuperset(set3)) # True
29 | print("superset(set2):",set2.issuperset(set3)) #False
30 |
31 | print("disjoin:",set4.isdisjoint(set3))
32 |
33 | print(id(set4))
34 | set4.add(1)
35 | print(set4)
36 | print(id(set4))
37 | set4.pop()
38 | print(set4)
39 | set4.pop()
40 | print(set4)
41 |
42 | set4.discard(4)
43 | print(set4)
44 |
45 | set4.remove(4)# if the element is not there in the set, then remove returns error
46 | print(set4)
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
--------------------------------------------------------------------------------
/16-06-2021/sets.py:
--------------------------------------------------------------------------------
1 | # Sets
2 |
3 | # It is a data structure in python
4 | # It is unordered ( There is no indexing )
5 | # Set elements are immutable
6 | # The elements are unique
7 | # {}
8 |
9 | set1 = set() # To create an empty set
10 | print(type(set1))
11 |
12 | set2 = {1,1,1,2,3,5,6,77,6,5,3,3,3,3,5,67,8}
13 |
14 | print(set2)
15 | print(set2[0])
16 |
17 | set3 = {1,2,3,[1,2,3]}
18 | print(set3)
19 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/16-06-2021/tuple_frequency.py:
--------------------------------------------------------------------------------
1 | # Write a Python program to find the repeated items of a tuple.
2 |
3 | tuple1 = (1,2,1,4,5,3,45,8,3,5) # o/p : 1,3,5
4 |
5 | repeated = []
6 | for i in tuple1:
7 | if tuple1.count(i)>1:
8 | if i not in repeated:
9 | repeated.append(i)
10 |
11 | print(repeated)
12 |
--------------------------------------------------------------------------------
/16-06-2021/tuples.py:
--------------------------------------------------------------------------------
1 | # tuple
2 |
3 | # Creating a tuple
4 |
5 | t = ()
6 | t2 = tuple()
7 | print(type(t))
8 | print(t)
9 | print(type(t2))
10 |
11 | tuple_1 = (1,2,3,4,5)
12 |
13 | print(tuple_1)
14 |
15 | #indexing
16 |
17 | print(tuple_1[1])
18 | print(tuple_1[-1])
19 | print(tuple_1[0:3])
20 |
21 | # Methods - count(), index()
22 |
23 | print(dir(tuple_1))
24 |
25 | tuple2 = (1,2,3,1,2,6,7,8)
26 |
27 | c = tuple2.count(6)
28 | print(c)
29 |
30 | print(tuple2.index(2))
31 |
32 | # min, max, sum, sorted
33 |
34 | print(min(tuple2))
35 | print(sum(tuple2))
36 |
37 | # Iterable
38 | for i in tuple2:
39 | print(i)
40 |
41 |
42 |
43 |
44 |
--------------------------------------------------------------------------------
/16-06-2021/tuples.txt:
--------------------------------------------------------------------------------
1 | Array : It is to store homogenious data (all the elements with same data type)
2 | List : We can store different elements with different data types
3 | -> Mutable ( We can modify the list items )
4 | -> Ordered ( We can access the elements with index )
5 | -> Iterable ( We can iterate through each element )
6 | -> []
7 |
8 | Tuples:
9 | -------------------
10 | - We can store different data types
11 | - Immutable
12 | - Ordered
13 | - Iterable
14 | - ()
15 |
--------------------------------------------------------------------------------
/16-06-2021/unique_elements.py:
--------------------------------------------------------------------------------
1 | # To get unique elements
2 | # input : 1,2,1,3,4,53,4,5,6,9
3 | # output : 1 2 3 4 5 6 9 53
4 |
5 | inp = input().split(",")
6 | for i in range(len(inp)):
7 | inp[i] = int(inp[i])
8 |
9 | unique = sorted(set(inp))
10 | print(unique)
11 |
--------------------------------------------------------------------------------
/17-06-2021/Files & File Handling.pptx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/17-06-2021/Files & File Handling.pptx
--------------------------------------------------------------------------------
/17-06-2021/Tasks/data.txt:
--------------------------------------------------------------------------------
1 | Line 1
2 | Line 2
3 | Line 3
4 | Line 4
5 | Line 5
6 | Line 6
7 | Line 7
8 | Line 8
9 | Line 9
10 | Line 10
11 | Line 11
12 | Line 12
13 | Line 13
14 | Line 14
15 | Line 15
16 | Line 16
17 | Line 17
18 | Line 18
19 | Line 19
20 | Line 20
21 |
--------------------------------------------------------------------------------
/17-06-2021/data_processing.py:
--------------------------------------------------------------------------------
1 | # Write a function to count the number of lines in a given file
2 |
3 | f = open("file1.txt","r")
4 |
5 | data = f.read()
6 | lines = data.split("\n")
7 | no_of_lines = len(lines)
8 |
9 | print(no_of_lines)
10 |
11 |
12 | def line_count(filename):
13 | f = open(filename,"r")
14 | lines = f.readlines()
15 | return len(lines)
16 |
17 | filename = "file1.txt"
18 |
19 | result = line_count(filename)
20 | print(result)
21 |
--------------------------------------------------------------------------------
/17-06-2021/dict_methods.py:
--------------------------------------------------------------------------------
1 | # Methods
2 |
3 | print(dir(dict()))
4 |
5 | student = {"Name":"Tejeswar","Id":262}
6 | print(student)
7 |
8 | # dict.keys() # return list of all the keys
9 | print(student.keys())
10 | for i in student.keys():
11 | print(student[i])
12 |
13 | # dict.values() - return all the values
14 |
15 | print(student.values())
16 |
17 | for i in student:
18 | print("{}:{}".format(i,student[i]))
19 |
20 | # dict.items() - return all the key-value pairs
21 |
22 | print(student.items())
23 | for i in student.items():
24 | print("Key:",i[0])
25 | print("Value:",i[1])
26 |
27 | keys = [1,2,3,4]
28 | values = [1,2,3,4]
29 | d = dict.fromkeys(keys,0)
30 | k=0
31 | for i in d:
32 | d[i] = values[k]
33 | k+=1
34 | print(d)
35 |
36 |
37 | # get()
38 | branch = student.get("Branch")
39 | if branch:
40 | print(branch)
41 | else:
42 | print("Key is not available in dict")
43 |
44 |
45 |
46 | #pop() - delete
47 |
48 | print(d.pop(1))
49 | print(d)
50 | d.popitem()
51 | print(d)
52 |
53 | #setdefault()
54 |
55 | d.setdefault(9,0)
56 | print(d)
57 |
58 | # update()
59 | d2 = {"Branch":"CSE","College":"SRM"}
60 | d.update(d2)
61 | print(d)
62 |
63 | # Nested Dictionary
64 |
65 | students = {"student1":{"name":"tejasri","id":33,"marks":[98,67,45,90]},"student2":{"name":'bhavani',"id":46}}
66 | print(students.keys())
67 | print(students.values())
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
--------------------------------------------------------------------------------
/17-06-2021/dictionaries.py:
--------------------------------------------------------------------------------
1 | # Dictionary
2 |
3 | # Create
4 | d = {}
5 | print(type(d))
6 | d = {1:1,2:2,3:5}
7 | print(d)
8 |
9 | # Retrieve/Access
10 |
11 | print(d[2])
12 | print(d[3])
13 |
14 | # Update/ Add
15 | #{4:10}
16 | d[4] = 10
17 | d[2] = 4
18 | print(d)
19 |
20 | # {[1,2,3]:[1,4,9]}
21 | d[(1,2,3)] = [1,4,9]
22 | print(d)
23 |
24 | # delete
25 | del d[4]
26 | print(d)
27 |
28 |
29 |
30 |
31 |
--------------------------------------------------------------------------------
/17-06-2021/file1.txt:
--------------------------------------------------------------------------------
1 | Python Programming
2 | SRMAP
3 | File Handling
4 | 17th June 2021This is the new data
--------------------------------------------------------------------------------
/17-06-2021/file2.txt:
--------------------------------------------------------------------------------
1 | Python Programming
2 | SRM University
--------------------------------------------------------------------------------
/17-06-2021/files.py:
--------------------------------------------------------------------------------
1 | # Files
2 |
3 | # open(filename, mode)
4 |
5 | # create
6 | # open("file1.txt",'x')
7 |
8 | # write() - write data into the given file(if the file is already exist)
9 | # if the file is not there in the location, then write() will create a new file
10 | f = open("file2.txt","w")
11 | f.write("Python Programming\n")
12 | f.write("SRM University")
13 | f.close()
14 |
15 | # read() - to read the data in a file
16 | f = open("file1.txt","r")
17 | data1 = f.read(10)
18 | print(f.tell())
19 | f.seek(2)
20 | print(f.tell())
21 | data2 = f.read()
22 | print(f.tell())
23 | print("Data1:",data1)
24 | print("Data2:",data2)
25 | f.close()
26 |
27 | # readlines()
28 | f = open("file1.txt","r")
29 | lines = f.readlines()
30 | print(lines)
31 | f.close()
32 |
33 | # append
34 | f = open("file1.txt","a")
35 | f.write("This is the new data")
36 | f.close()
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
--------------------------------------------------------------------------------
/17-06-2021/notes.txt:
--------------------------------------------------------------------------------
1 | Day Objectives:
2 | ================
3 |
4 | => Dictionary
5 |
6 | -> It is a collection of Items
7 | -> Mutable
8 | -> Unordered
9 | -> Each item contains a key and a value
10 | -> item = (key:value)
11 | -> {}
12 | -> d = {}, d = dict()
13 | -> keys must be unique. we cannot assign same key to different values
14 | -> Keys must be immutable
15 |
16 |
17 | => File Handling
18 |
19 | CRUD - Create Retrieve Update Delete
20 |
21 | Methods:
22 | ----------------
23 | -open()
24 | -read() - will read the entire data into a string
25 | -readlines() - to read the data line by line (list)
26 | -write()
27 | -close()
28 | -tell() - To know the curser position
29 | -seek() - To move the cursor position
30 |
31 | Modes:
32 | ------------
33 | - x => create mode (This will create a new file)
34 | - r => read mode (Read the data in the file)
35 | - w => write mode ( Write data to the file) (erase the old data)
36 | - a => append mode ( Add data to the file) (new data will be added at the end of the old data)
37 | - r+ => read + write
38 | - w+ => write + read
39 | - a+ => read + append
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
--------------------------------------------------------------------------------
/18 june 2021/1.dictionary_comprehension.py:
--------------------------------------------------------------------------------
1 | # create a dict of n numbers with values squares of that number
2 |
3 | #n = int(input("enter n:"))
4 |
5 | # set comprehension
6 | #result = {i**2 for i in range(1,n+1)}
7 | # dictionary comprehension
8 | #dict_result = {i:i**2 for i in range(1,n+1)}
9 | #print(dict_result)
10 |
11 | #Welcome to Web Development Using Django internship this repository consists of all the files
12 |
13 | n = 'Welcome to Web Development Using Django'
14 |
15 | m = {i.upper():i for i in n.split()}
16 | print(m)
17 |
--------------------------------------------------------------------------------
/18 june 2021/2.list_comprehension.py:
--------------------------------------------------------------------------------
1 | # calculate the sum of squares of n natural numbers
2 |
3 | n = int(input("Enter value for n:"))
4 | # print(sum([i**2 for i in range(1,n)]))
5 |
6 | # calculate the sum of squares of even between n natural numbers
7 |
8 | #result_l = []
9 | #for i in range(1,n+1):
10 | # if i%2 == 0:
11 | # result_l.append(i**2)
12 | #print(sum(result_l))
13 | #print(result_l)
14 |
15 |
16 | #syntax for comprehension with if condition
17 | # [expression_on_loop_variable forloop if condition(loop_varibl)]
18 |
19 | print(sum([i**2 for i in range(1,n+1) if i%2 ==0]))
20 |
--------------------------------------------------------------------------------
/18 june 2021/3.list_comprehension.py:
--------------------------------------------------------------------------------
1 |
2 | #n = int(input('N value:'))
3 | # print([i**2 if i%2 == 0 else i for i in range(1,n+1)])
4 |
5 |
6 | # write a function for prime number
7 | # do it now
8 | #write a function for prime number
9 | n = int(input("Enter a number: "))
10 |
11 | if n > 1:
12 | for i in range(2,n):
13 | if (n % i) == 0:
14 | print(n,"is not a prime number")
15 | print(i,"times",n//i,"is",n)
16 | break
17 | else:
18 | print(n,"is a prime number")
19 |
20 | else:
21 | print(n,"is not a prime number")
22 |
--------------------------------------------------------------------------------
/18 june 2021/generators.py:
--------------------------------------------------------------------------------
1 | # generators
2 |
3 | def generator_object():
4 | yield 1
5 | yield 2
6 | yield 3
7 | yield 4
8 |
9 | def sample():
10 | yield 'apssdc'
11 | yield 'SRM'
12 | yield 'Students'
13 | yield 1
14 | yield [1,3,4]
15 |
16 | # tuple comprehension
17 | result = tuple(i for i in range(10))
18 | print(result)
19 | print(type(result))
20 |
21 | tuple_generator = (i for i in range(10))
22 | print(tuple_generator)
23 | print(type(tuple_generator))
24 |
--------------------------------------------------------------------------------
/18 june 2021/iterator.py:
--------------------------------------------------------------------------------
1 | # iterator
2 |
3 | # iter function
4 | s = 'string'
5 | iter_string = iter(s)
6 | #print(next(iter_string))
7 |
8 | l = [1,2,43,54,5667,212,123,43]
9 | inter_l = iter(l)
10 |
--------------------------------------------------------------------------------
/18 june 2021/list_comprehension.py:
--------------------------------------------------------------------------------
1 | # list comprehension
2 | # calcualte the sum of these 3 digits
3 | # input= 123
4 | # output = 6
5 |
6 | n = input('enter a 3 digit value: ')
7 | #result_list = []
8 | #for digit in n:
9 | # print(type(digit))
10 | # digit_int = int(digit)
11 | # result_list.append(digit_int)
12 |
13 | #print('sum of the 3 digits: ',sum(result_list))
14 |
15 |
16 | # syntax
17 | #[expression(t_var) for t_var in iterator]
18 |
19 | print('sum of the 3 digits: ', sum([int(digit) for digit in n]))
20 |
--------------------------------------------------------------------------------
/18 june 2021/prime_number.py:
--------------------------------------------------------------------------------
1 | # function
2 |
3 | def prime(n):
4 | c = 0
5 | for i in range(2,(n//2)+1):
6 | if n%i == 0:
7 | c += 1
8 | if c >= 1:
9 | return False
10 | return True
11 |
12 | #n = int(input('enter n value:'))
13 | #result = [i for i in range(1,n+1) if prime(i)]
14 | #print(result)
15 |
16 | #result = [i for i in range(1,n+1)if all(i%j !=0 for j in range(2,(i//2)+1))]
17 | #print(result)
18 |
19 | n = int(input())
20 | l = [i for i in range(2,(n)+1) if 0 not in [i%j for j in range(2,int(i/2)+1)]]
21 | print(l)
22 |
--------------------------------------------------------------------------------
/19-06-2021/Functional Programming.pptx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/19-06-2021/Functional Programming.pptx
--------------------------------------------------------------------------------
/19-06-2021/Regular Expressions.pptx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/19-06-2021/Regular Expressions.pptx
--------------------------------------------------------------------------------
/19-06-2021/Task.md:
--------------------------------------------------------------------------------
1 | Task:
2 | ======
3 | 1. Create a text file
4 | 2. Write some random email ids (through python program)(minimum 5)
5 | 3. Write a function which takes the text file and returns all the valid mail ids(include re)
6 |
--------------------------------------------------------------------------------
/19-06-2021/email_validation.py:
--------------------------------------------------------------------------------
1 | import re
2 |
3 |
4 | s = input("Enter your email: ")
5 |
6 | pattern = "^[a-z][a-z0-9._]{7,15}[@](gmail.com)"
7 |
8 |
9 | def emailValidation(s,pattern):
10 | if re.match(pattern,s):
11 | return True
12 | return False
13 |
14 |
15 | print(emailValidation(s,pattern))
16 |
--------------------------------------------------------------------------------
/19-06-2021/lambda.py:
--------------------------------------------------------------------------------
1 | # Lambda : Anonymous function(funtion without name)
2 | # It can contain one or more number of arguments but a single expresion
3 | # lambda arguments(x,y,..):expression
4 |
5 |
6 | # input : n
7 | # output : n**2
8 |
9 |
10 | lam = lambda n,a:n*a
11 |
12 |
13 | print(lam(5,2))
14 |
15 |
16 | # list = [1,2,3,4,5]
17 | # ouput : [2,3,4,5,6]
18 |
19 | x = lambda x:x+1
20 |
21 |
22 | print(list(map(x,[1,2,3,4,5])))
23 | # if n is even : return n**2
24 | # else : return n**3
25 | # [1,2,3,4]
26 | # [1,4,27,16]
27 |
28 | l = list(range(1,11))
29 | # lambda with if-else : lambda n:n if n%2==0 else 0
30 |
31 | even = lambda n: n**2 if n%2==0 else n**3
32 |
33 | evens = list(map(even,l))
34 | print(evens)
35 |
36 |
37 | # Filter
38 | # filter() is a function which takes a funtion and a sequence and return all the true cases
39 |
40 |
41 | #program to get even numbers in a list by using filter
42 |
43 |
44 | l = [12,23,34,10,1]
45 |
46 | def even(n):
47 | if n%2==0:
48 | return True
49 | return False
50 |
51 | result = list(filter(even,l))
52 | print(result)
53 |
54 | print(list(filter(lambda x:True if x%2==0 else False, l)))
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
--------------------------------------------------------------------------------
/19-06-2021/notes.txt:
--------------------------------------------------------------------------------
1 | Day Objectives
2 | ===============
3 |
4 |
5 | =>Regular Expressions
6 |
7 | Meta Characters:
8 | ->"." - Mathces any character
9 | ->[range] - Specify the sequnce the characters to match
10 | ->[a-z] - matches all the lowercase characters
11 | ->[A-Z] - matches all the uppercase characters
12 | ->[a-zA-Z] - matches all the alphabets(lower and upper)
13 | ->[0-9] - mathces all the numbers from 0-9
14 | -> * - zero or one or more than one occurances of the previous character
15 | -> ? - zero or one occurances of the previous character
16 | -> + - one or more occurances of the previous character
17 |
18 | White spaces : space, \n\t
19 |
20 | => Valid Phone Number Rules
21 | - It should contain only digits(0-9)
22 | - It should start with either 9/8/7/6
23 | - Length of the number should be 10
24 | - code : +91 xxxxxxxxxx
25 |
26 | => Pattern to match all the numbers which are divisible by 5
27 |
28 | import re
29 | ----------------
30 | ->match() : It will return a match object if the given pattern is found at the beginning of the string
31 | ->search() : If pattern found, it will match the first occurance
32 | ->findall() : If pattern found, It will match all occurances
33 |
34 |
35 | => Email Validation:
36 | - Should start with alphabet
37 | - It can contain alphabets and numbers and (. _)
38 | - user_id length is (8-15)
39 | - It contains @
40 |
41 |
42 | Taks:
43 | ======
44 | 1. Create a text file
45 | 2. Write some random email ids (through python program)(minimum 5)
46 | 3. Write a function which takes the text file and returns all the valid mail ids(include re)
47 |
48 |
49 | =>Lambda
50 |
51 |
52 |
53 | =>Filter
--------------------------------------------------------------------------------
/19-06-2021/regex.py:
--------------------------------------------------------------------------------
1 | import re
2 |
3 | # re.match(pattern, string)
4 |
5 | s = "Web Development with Python Web Python"
6 |
7 | pattern = "Python"
8 |
9 | m = re.match(pattern,s)
10 |
11 | ser = re.search(pattern, s)
12 |
13 | f = re.findall(pattern,s)
14 |
15 | sp = re.split("e",s)
16 |
17 | sub = re.sub("e","@",s,2)
18 |
19 | print(sub)
20 |
--------------------------------------------------------------------------------
/21 june 2021/oop1.py:
--------------------------------------------------------------------------------
1 | # DEfine a Class
2 | class myclass():
3 | pass
4 |
5 | class myclass1:
6 | pass
7 |
8 | class myclass2(object):
9 | pass
10 |
11 |
12 | print(issubclass(myclass, object))
13 | print(issubclass(myclass1, object))
14 | print(issubclass(myclass2, object))
15 |
--------------------------------------------------------------------------------
/21 june 2021/oop2_declaring fun inside class.py:
--------------------------------------------------------------------------------
1 | # declaring a Functions in side the Calss
2 | # to represent this function is belongs to the class
3 | # - we need to mention self as mendetory perametor.
4 |
5 | class Myclass:
6 | def my_fun(self):
7 | print("hi")
8 | def say_hi(self, name):
9 | print("hi "+ name)
10 |
11 |
12 |
13 | # Declaring the variable inside the class
14 | # to represent class variable always use selfkeyword
15 | class Myclass2:
16 | a = 12 # attributes
17 | b = 10
18 | def my_fun(self):
19 | print(self.a + self.b)
20 | def checking(self):
21 | print(a,b)# NameError: name 'a' is not defind
22 |
23 |
--------------------------------------------------------------------------------
/21 june 2021/oop3_local class global variables.py:
--------------------------------------------------------------------------------
1 | # local variable, class and global variable
2 |
3 | i , j = 10,20 # global variables
4 | a, b = 204, 306 # global variables
5 |
6 | class Variable():
7 | a, b = 2, 4 # class Variables
8 | def add(self, x,y): # loacl Variables
9 | print(x,y)
10 | print(self.a, self.b)
11 | print(i,j)
12 |
13 |
14 | # local variable, class and global variable with same names
15 |
16 | class VariableWithSameNames():
17 | a, b = 88, 99 # class variable
18 | def check(self,a,b):
19 | print(a,b) # local
20 | print(self.a,self.b) # class
21 | print(globals()['a'],globals()['b']) # global
22 |
--------------------------------------------------------------------------------
/21 june 2021/oop4_named objects.py:
--------------------------------------------------------------------------------
1 | # named object
2 | class MyClass():
3 | def disp(self):
4 | print('hello')
5 |
6 |
7 | a = MyClass()
8 | print('named object :',a.disp())
9 | print('name less object :',MyClass().disp())
10 |
--------------------------------------------------------------------------------
/21 june 2021/oop5_constructor.py:
--------------------------------------------------------------------------------
1 | # constructor
2 | # it is method, which is automatically executed when we creating an object
3 | # the function begins double underscore "__" are called as special functions, these special functions have some special meaning
4 |
5 |
6 | class MyClassConstructor():
7 | def __init__(self):
8 | print('i\'m from Constructor')
9 | def Myfun(self):
10 | print('hi from myfun')
11 |
12 |
13 | class Checking():
14 | def Myfun(self):
15 | print('hi from myfun')
16 |
17 | class Apssdc():
18 | def __init__(self, a, b):
19 | self.val_a = a
20 | self.val_b = b
21 |
22 | def display(self):
23 | print(self.val_a, self.val_b)
24 |
25 |
26 | a = Apssdc(1,2)
27 | peinr(a.display())
28 |
29 |
--------------------------------------------------------------------------------
/21 june 2021/oop6___Str__.py:
--------------------------------------------------------------------------------
1 | # __str__
2 |
3 | class SpecialSrtMethod():
4 | def __str__(self):
5 | return 'you are trying to get me'
6 | def add(self, a, b):
7 | print(a+b)
8 |
9 |
10 | class SpecialSrtMethodCheckong():
11 |
12 | def add(self, a, b):
13 | print(a+b)
14 |
15 | normal = SpecialSrtMethodCheckong()
16 | special = SpecialSrtMethod()
17 |
18 | print(normal)
19 | print(special)
20 |
--------------------------------------------------------------------------------
/21 june 2021/oop7_destructor.py:
--------------------------------------------------------------------------------
1 | # __del__
2 | # destructor, will be called when you delete an object
3 |
4 | class ClassDel():
5 | pass
6 |
7 | class SpecialClassDel:
8 | def __del__(self):
9 | print("your object is distroyed")
10 |
11 |
--------------------------------------------------------------------------------
/21 june 2021/oop8.py:
--------------------------------------------------------------------------------
1 | class myclass():
2 | def fun1(x):
3 | print('hi im from function 1.')
4 | x.fun2()
5 | def fun2(x):
6 | print('hi im from function 2')
7 |
--------------------------------------------------------------------------------
/22 june 2021/2.inherintance.py:
--------------------------------------------------------------------------------
1 | from Inheritance_1 import MainClass
2 |
3 | class A(MainClass):
4 | def method_A(self):
5 | return "from sub class A"
6 |
7 |
8 |
9 | obj = A()
10 | print(obj.method_A())
11 |
12 | print(obj.m1())
13 |
--------------------------------------------------------------------------------
/22 june 2021/Encapsulation_ getter and setter Example.py:
--------------------------------------------------------------------------------
1 | # Encapsulation
2 | # Getter and Setter Exmple
3 |
4 | # whhich are used to access the data indirectly
5 |
6 | class Employee():
7 | __id = 1
8 |
9 | def set_eid(self, eid):
10 | self .__id = eid
11 |
12 | def get_eid(self):
13 | return self.__id
14 |
15 |
16 | obj = Employee()
17 |
18 | print(obj.get_eid())
19 |
20 | obj.set_eid(33)
21 | print(obj.get_eid())
22 |
--------------------------------------------------------------------------------
/22 june 2021/Encapsulation_ private attributes Example.py:
--------------------------------------------------------------------------------
1 | # Encapsulation:
2 | # the process of binding the data.(hiding the impleentations)
3 | # for binding the data we need to use the private modifiers (__name)
4 |
5 | # private attribute
6 | class A:
7 | __a = 10
8 |
9 | def disp(self):
10 | print(self.__a)
11 |
12 | a = A()
13 | a.disp()
14 |
15 | print(a.__a) # AttributeError:
16 |
--------------------------------------------------------------------------------
/22 june 2021/Encapsulation_ private methods_Example.py:
--------------------------------------------------------------------------------
1 | # Encapsulation
2 | # creating private methods
3 |
4 | class MyClass():
5 | def __disp(self):
6 | print('it is a private method')
7 |
8 | def normal_method(self):
9 | print('it is from normal_method')
10 | self.__disp()
11 |
--------------------------------------------------------------------------------
/22 june 2021/Hierarchical_inheritance_Example.py:
--------------------------------------------------------------------------------
1 | class Parent():
2 | def method_parent(self):
3 | return "parent method"
4 |
5 | class Child1(Parent):
6 | def method_child1(self):
7 | return "child 1 method"
8 |
9 | class Child2(Parent):
10 | def method_child2(self):
11 | return "child 2 method"
12 |
--------------------------------------------------------------------------------
/22 june 2021/Hierarchical_inheritance_syntax.py:
--------------------------------------------------------------------------------
1 | # hierarchical inheritance
2 |
3 | class Parent():
4 | pass
5 |
6 | class Child1(Parent):
7 | pass
8 |
9 | class Child2(Parent):
10 | pass
11 |
--------------------------------------------------------------------------------
/22 june 2021/Inheritance_1.py:
--------------------------------------------------------------------------------
1 | # Inheritance
2 | # Inheritance is a way of defining newclass using details of existing class.
3 | # We can call newly formed calss as derived class or child class.
4 | # the existing class is called as base class or parent classs.
5 |
6 | # parent class
7 | class MainClass:
8 | def m1(self):
9 | print("Perent class")
10 |
11 |
12 | # child classs
13 | class SubClass(MainClass):
14 | def fun_subclass(self):
15 | print("this is from subclass function")
16 |
17 |
18 | # create an object for both th classes
19 | #main_obj = MainClass()
20 | #child_obj = SubClass()
21 |
22 | #print(main_obj.m1()) # result : Perent class
23 | #print(child_obj.m1())
24 | #print(child_obj.fun_subclass())
25 | #print(main_obj.fun_subclass()) # result it will rise an error AttributeError
26 |
--------------------------------------------------------------------------------
/22 june 2021/Inheritance_3.py:
--------------------------------------------------------------------------------
1 | # define a Base or parent class
2 |
3 | class AClass():
4 | def __init__(self):
5 | print("i\'m a Constructor from class A")
6 | def method_A(self):
7 | return "i\'m a method from class A"
8 |
9 |
10 | # create a derived class or child class
11 |
12 | class B(AClass):
13 | def __init__(self):
14 | print("i\'m a Constructor from class B (child class)")
15 | super().__init__()
16 | def method_B(self):
17 | return "i\'m a method from class B (child class)"
18 |
--------------------------------------------------------------------------------
/22 june 2021/Polymorphism_1.py:
--------------------------------------------------------------------------------
1 | # Polymorphism
2 | # one Functional with miltiple behaviour
3 |
4 | # over riding an attribute
5 | class Parent():
6 | name = 'Lakshman'
7 |
8 | class child(Parent):
9 | # name = 'Lucky'
10 | phone = '123'
11 |
12 |
13 | # over riding methods
14 |
15 | class Parent1():
16 | def career(self):
17 | return 'Engineer'
18 |
19 | class child1(Parent):
20 | def career(self):
21 | return "Photographer"
22 |
23 |
--------------------------------------------------------------------------------
/22 june 2021/__pycache__/Inheritance_1.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/22 june 2021/__pycache__/Inheritance_1.cpython-38.pyc
--------------------------------------------------------------------------------
/22 june 2021/__pycache__/multi_level_Example.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/22 june 2021/__pycache__/multi_level_Example.cpython-38.pyc
--------------------------------------------------------------------------------
/22 june 2021/abstraction class.py:
--------------------------------------------------------------------------------
1 | # abstraction class
2 |
3 | # the implementations are done at child class but the declarartions are
4 | # at abstraction class
5 |
6 | from abc import ABC, abstractmethod
7 |
8 | class A(ABC):
9 | @abstractmethod
10 | def m1(self):
11 | pass
12 |
13 |
14 | class Parent(ABC):
15 | @abstractmethod
16 | def method(self):
17 | pass
18 | @abstractmethod
19 | def disp(self):
20 | pass
21 |
22 | class Child(Parent):
23 | def method(self):
24 | print("apssdc")
25 | def disp(self):
26 | print('displ')
27 |
--------------------------------------------------------------------------------
/22 june 2021/multi_level_Example.py:
--------------------------------------------------------------------------------
1 | # multi Level inheritance
2 |
3 | class GParent():
4 | def methodG(self):
5 | return "from GParent Method"
6 |
7 |
8 | class Parent(GParent):
9 | def methodP(self):
10 | return "from Parent Method"
11 |
12 | class Child(Parent):
13 | def methodChild(self):
14 | return "from child Method"
15 |
16 |
17 | # create instance for child
18 |
19 | c = Child()
20 | #print(c.methodChild())# "from child Method"
21 | #print(c.methodP())# "from Parent Method"
22 | #print(c.methodG()) # from GParent Method
23 |
--------------------------------------------------------------------------------
/22 june 2021/multi_level_syntax.py:
--------------------------------------------------------------------------------
1 | # multi level inheritance
2 |
3 | class GrandParent():
4 | pass
5 | class Parent(GrandParent):
6 | pass
7 | class Child(Parent):
8 | pass
9 |
10 |
11 |
--------------------------------------------------------------------------------
/22 june 2021/multiple_inheritance_Example.py:
--------------------------------------------------------------------------------
1 | from Inheritance_1 import MainClass
2 | from multi_level_Example import GParent
3 |
4 | class Multiple(MainClass,GParent):
5 | def method_Multiple(self):
6 | return "i'm from multiple method"
7 |
--------------------------------------------------------------------------------
/22 june 2021/multiple_inheritance_syntax.py:
--------------------------------------------------------------------------------
1 | # Multiple Inheritance
2 |
3 | class A():
4 | pass
5 |
6 |
7 | class B():
8 | pass
9 |
10 | class c(A,B):
11 | pass
12 |
--------------------------------------------------------------------------------
/22 june 2021/single inheritance.py:
--------------------------------------------------------------------------------
1 | # single inheritance
2 |
3 | class Parent():
4 | pass
5 |
6 |
7 | class Child(Parent):
8 | pass
9 |
--------------------------------------------------------------------------------
/23-06-2021/Django Introduction.pptx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/23-06-2021/Django Introduction.pptx
--------------------------------------------------------------------------------
/23-06-2021/FirstProject/FirstProject/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/23-06-2021/FirstProject/FirstProject/__init__.py
--------------------------------------------------------------------------------
/23-06-2021/FirstProject/FirstProject/urls.py:
--------------------------------------------------------------------------------
1 | """FirstProject URL Configuration
2 |
3 | The `urlpatterns` list routes URLs to views. For more information please see:
4 | https://docs.djangoproject.com/en/2.2/topics/http/urls/
5 | Examples:
6 | Function views
7 | 1. Add an import: from my_app import views
8 | 2. Add a URL to urlpatterns: path('', views.home, name='home')
9 | Class-based views
10 | 1. Add an import: from other_app.views import Home
11 | 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home')
12 | Including another URLconf
13 | 1. Import the include() function: from django.urls import include, path
14 | 2. Add a URL to urlpatterns: path('blog/', include('blog.urls'))
15 | """
16 | from django.contrib import admin
17 | from django.urls import path
18 |
19 | urlpatterns = [
20 | path('admin/', admin.site.urls),
21 | ]
22 |
--------------------------------------------------------------------------------
/23-06-2021/FirstProject/FirstProject/wsgi.py:
--------------------------------------------------------------------------------
1 | """
2 | WSGI config for FirstProject project.
3 |
4 | It exposes the WSGI callable as a module-level variable named ``application``.
5 |
6 | For more information on this file, see
7 | https://docs.djangoproject.com/en/2.2/howto/deployment/wsgi/
8 | """
9 |
10 | import os
11 |
12 | from django.core.wsgi import get_wsgi_application
13 |
14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'FirstProject.settings')
15 |
16 | application = get_wsgi_application()
17 |
--------------------------------------------------------------------------------
/23-06-2021/FirstProject/db.sqlite3:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/23-06-2021/FirstProject/db.sqlite3
--------------------------------------------------------------------------------
/23-06-2021/FirstProject/manage.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | """Django's command-line utility for administrative tasks."""
3 | import os
4 | import sys
5 |
6 |
7 | def main():
8 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'FirstProject.settings')
9 | try:
10 | from django.core.management import execute_from_command_line
11 | except ImportError as exc:
12 | raise ImportError(
13 | "Couldn't import Django. Are you sure it's installed and "
14 | "available on your PYTHONPATH environment variable? Did you "
15 | "forget to activate a virtual environment?"
16 | ) from exc
17 | execute_from_command_line(sys.argv)
18 |
19 |
20 | if __name__ == '__main__':
21 | main()
22 |
--------------------------------------------------------------------------------
/23-06-2021/mvc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/23-06-2021/mvc.png
--------------------------------------------------------------------------------
/23-06-2021/mvt.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/23-06-2021/mvt.png
--------------------------------------------------------------------------------
/23-06-2021/notes.txt:
--------------------------------------------------------------------------------
1 | MVC:
2 | -----------
3 |
4 | M - Model
5 | V - View
6 | C - Controller
7 |
8 | Model:
9 | ------------
10 | It is resposible for managing the data of our application
11 |
12 | View:
13 | --------
14 | It is resposible for designing the user interface
15 |
16 | Controller:
17 | ----------------
18 | It is resposible for request - respose cycle
19 |
20 |
21 | Django follows MVT Architecture
22 | -------------------------------------------------------------
23 | M - Model
24 | V - View
25 | T - Template
26 |
27 |
28 | MVC MVT
29 | data : Model Model
30 | user interface : View Template
31 | request-response cycle : Controller View
--------------------------------------------------------------------------------
/24-06-2021/Notes.docx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/24-06-2021/Notes.docx
--------------------------------------------------------------------------------
/24-06-2021/myProject/db.sqlite3:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/24-06-2021/myProject/db.sqlite3
--------------------------------------------------------------------------------
/24-06-2021/myProject/manage.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | """Django's command-line utility for administrative tasks."""
3 | import os
4 | import sys
5 |
6 |
7 | def main():
8 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'myProject.settings')
9 | try:
10 | from django.core.management import execute_from_command_line
11 | except ImportError as exc:
12 | raise ImportError(
13 | "Couldn't import Django. Are you sure it's installed and "
14 | "available on your PYTHONPATH environment variable? Did you "
15 | "forget to activate a virtual environment?"
16 | ) from exc
17 | execute_from_command_line(sys.argv)
18 |
19 |
20 | if __name__ == '__main__':
21 | main()
22 |
--------------------------------------------------------------------------------
/24-06-2021/myProject/myApp/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/24-06-2021/myProject/myApp/__init__.py
--------------------------------------------------------------------------------
/24-06-2021/myProject/myApp/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/24-06-2021/myProject/myApp/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/24-06-2021/myProject/myApp/__pycache__/urls.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/24-06-2021/myProject/myApp/__pycache__/urls.cpython-36.pyc
--------------------------------------------------------------------------------
/24-06-2021/myProject/myApp/__pycache__/views.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/24-06-2021/myProject/myApp/__pycache__/views.cpython-36.pyc
--------------------------------------------------------------------------------
/24-06-2021/myProject/myApp/admin.py:
--------------------------------------------------------------------------------
1 | from django.contrib import admin
2 |
3 | # Register your models here.
4 |
--------------------------------------------------------------------------------
/24-06-2021/myProject/myApp/apps.py:
--------------------------------------------------------------------------------
1 | from django.apps import AppConfig
2 |
3 |
4 | class MyappConfig(AppConfig):
5 | name = 'myApp'
6 |
--------------------------------------------------------------------------------
/24-06-2021/myProject/myApp/migrations/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/24-06-2021/myProject/myApp/migrations/__init__.py
--------------------------------------------------------------------------------
/24-06-2021/myProject/myApp/models.py:
--------------------------------------------------------------------------------
1 | from django.db import models
2 |
3 | # Create your models here.
4 |
--------------------------------------------------------------------------------
/24-06-2021/myProject/myApp/tests.py:
--------------------------------------------------------------------------------
1 | from django.test import TestCase
2 |
3 | # Create your tests here.
4 |
--------------------------------------------------------------------------------
/24-06-2021/myProject/myApp/urls.py:
--------------------------------------------------------------------------------
1 | from django.urls import path
2 | from myApp import views
3 |
4 | # from . import views
5 |
6 |
7 | urlpatterns = [
8 | path('home/',views.home),
9 | ]
--------------------------------------------------------------------------------
/24-06-2021/myProject/myApp/views.py:
--------------------------------------------------------------------------------
1 | from django.shortcuts import render
2 | from django.http import HttpResponse
3 |
4 | # Create your views here.
5 |
6 |
7 |
8 | def home(request):
9 | return HttpResponse("Welcome to Django")
10 |
11 |
12 | def sample(request):
13 |
14 | return HttpResponse("This is my Sample Page
This is my first project in django
")
15 |
16 | def projectHome(request):
17 | message = "This is my Project Home page
"
18 | return HttpResponse(message)
19 |
20 | def name(request,Django):
21 | return HttpResponse(Django)
22 |
23 |
24 | def roll(request, roll):
25 | message = "Roll Number is " + str(roll)
26 | return HttpResponse(message)
27 |
28 | def table(request,number):
29 | table = ""
30 | for i in range(1,11):
31 | line = "{} x {} = {}".format(number,i,number*i)
32 |
33 |
34 | return HttpResponse(line)
35 |
36 |
37 |
--------------------------------------------------------------------------------
/24-06-2021/myProject/myProject/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/24-06-2021/myProject/myProject/__init__.py
--------------------------------------------------------------------------------
/24-06-2021/myProject/myProject/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/24-06-2021/myProject/myProject/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/24-06-2021/myProject/myProject/__pycache__/settings.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/24-06-2021/myProject/myProject/__pycache__/settings.cpython-36.pyc
--------------------------------------------------------------------------------
/24-06-2021/myProject/myProject/__pycache__/urls.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/24-06-2021/myProject/myProject/__pycache__/urls.cpython-36.pyc
--------------------------------------------------------------------------------
/24-06-2021/myProject/myProject/__pycache__/wsgi.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/24-06-2021/myProject/myProject/__pycache__/wsgi.cpython-36.pyc
--------------------------------------------------------------------------------
/24-06-2021/myProject/myProject/urls.py:
--------------------------------------------------------------------------------
1 | """myProject URL Configuration
2 |
3 | The `urlpatterns` list routes URLs to views. For more information please see:
4 | https://docs.djangoproject.com/en/2.2/topics/http/urls/
5 | Examples:
6 | Function views
7 | 1. Add an import: from my_app import views
8 | 2. Add a URL to urlpatterns: path('', views.home, name='home')
9 | Class-based views
10 | 1. Add an import: from other_app.views import Home
11 | 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home')
12 | Including another URLconf
13 | 1. Import the include() function: from django.urls import include, path
14 | 2. Add a URL to urlpatterns: path('blog/', include('blog.urls'))
15 | """
16 | from django.contrib import admin
17 | from django.urls import path, include
18 | from myApp import views
19 |
20 | urlpatterns = [
21 | path('admin/', admin.site.urls),
22 | path('home/', views.home),
23 | path('sample/',views.sample),
24 | path('myproject/home',views.projectHome),
25 | path('name/',views.name),
26 | path('Roll_Number/',views.roll),
27 | path('table/',views.table),
28 |
29 | path('app/',include("myApp.urls")),
30 | ]
31 |
--------------------------------------------------------------------------------
/24-06-2021/myProject/myProject/wsgi.py:
--------------------------------------------------------------------------------
1 | """
2 | WSGI config for myProject project.
3 |
4 | It exposes the WSGI callable as a module-level variable named ``application``.
5 |
6 | For more information on this file, see
7 | https://docs.djangoproject.com/en/2.2/howto/deployment/wsgi/
8 | """
9 |
10 | import os
11 |
12 | from django.core.wsgi import get_wsgi_application
13 |
14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'myProject.settings')
15 |
16 | application = get_wsgi_application()
17 |
--------------------------------------------------------------------------------
/26-06-2021/college/college/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/college/__init__.py
--------------------------------------------------------------------------------
/26-06-2021/college/college/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/college/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/college/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/college/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/college/__pycache__/settings.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/college/__pycache__/settings.cpython-36.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/college/__pycache__/settings.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/college/__pycache__/settings.cpython-38.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/college/__pycache__/urls.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/college/__pycache__/urls.cpython-36.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/college/__pycache__/urls.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/college/__pycache__/urls.cpython-38.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/college/__pycache__/wsgi.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/college/__pycache__/wsgi.cpython-36.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/college/__pycache__/wsgi.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/college/__pycache__/wsgi.cpython-38.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/college/urls.py:
--------------------------------------------------------------------------------
1 | """college URL Configuration
2 |
3 | The `urlpatterns` list routes URLs to views. For more information please see:
4 | https://docs.djangoproject.com/en/2.2/topics/http/urls/
5 | Examples:
6 | Function views
7 | 1. Add an import: from my_app import views
8 | 2. Add a URL to urlpatterns: path('', views.home, name='home')
9 | Class-based views
10 | 1. Add an import: from other_app.views import Home
11 | 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home')
12 | Including another URLconf
13 | 1. Import the include() function: from django.urls import include, path
14 | 2. Add a URL to urlpatterns: path('blog/', include('blog.urls'))
15 | """
16 | from django.contrib import admin
17 | from django.urls import path,include
18 |
19 | from student import views
20 |
21 |
22 | urlpatterns = [
23 | path('admin/', admin.site.urls),
24 | path('home/',views.home),
25 |
26 | path("student/",include("student.urls")),
27 | ]
28 |
--------------------------------------------------------------------------------
/26-06-2021/college/college/wsgi.py:
--------------------------------------------------------------------------------
1 | """
2 | WSGI config for college project.
3 |
4 | It exposes the WSGI callable as a module-level variable named ``application``.
5 |
6 | For more information on this file, see
7 | https://docs.djangoproject.com/en/2.2/howto/deployment/wsgi/
8 | """
9 |
10 | import os
11 |
12 | from django.core.wsgi import get_wsgi_application
13 |
14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'college.settings')
15 |
16 | application = get_wsgi_application()
17 |
--------------------------------------------------------------------------------
/26-06-2021/college/db.sqlite3:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/db.sqlite3
--------------------------------------------------------------------------------
/26-06-2021/college/manage.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | """Django's command-line utility for administrative tasks."""
3 | import os
4 | import sys
5 |
6 |
7 | def main():
8 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'college.settings')
9 | try:
10 | from django.core.management import execute_from_command_line
11 | except ImportError as exc:
12 | raise ImportError(
13 | "Couldn't import Django. Are you sure it's installed and "
14 | "available on your PYTHONPATH environment variable? Did you "
15 | "forget to activate a virtual environment?"
16 | ) from exc
17 | execute_from_command_line(sys.argv)
18 |
19 |
20 | if __name__ == '__main__':
21 | main()
22 |
--------------------------------------------------------------------------------
/26-06-2021/college/student/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/__init__.py
--------------------------------------------------------------------------------
/26-06-2021/college/student/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/student/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/student/__pycache__/admin.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/__pycache__/admin.cpython-36.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/student/__pycache__/admin.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/__pycache__/admin.cpython-38.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/student/__pycache__/models.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/__pycache__/models.cpython-36.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/student/__pycache__/models.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/__pycache__/models.cpython-38.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/student/__pycache__/urls.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/__pycache__/urls.cpython-36.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/student/__pycache__/urls.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/__pycache__/urls.cpython-38.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/student/__pycache__/views.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/__pycache__/views.cpython-36.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/student/__pycache__/views.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/__pycache__/views.cpython-38.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/student/admin.py:
--------------------------------------------------------------------------------
1 | from django.contrib import admin
2 | from .models import Register
3 |
4 |
5 | admin.site.register(Register)
--------------------------------------------------------------------------------
/26-06-2021/college/student/apps.py:
--------------------------------------------------------------------------------
1 | from django.apps import AppConfig
2 |
3 |
4 | class StudentConfig(AppConfig):
5 | name = 'student'
6 |
--------------------------------------------------------------------------------
/26-06-2021/college/student/migrations/0001_initial.py:
--------------------------------------------------------------------------------
1 | # Generated by Django 3.0.7 on 2021-06-28 05:25
2 |
3 | from django.db import migrations, models
4 |
5 |
6 | class Migration(migrations.Migration):
7 |
8 | initial = True
9 |
10 | dependencies = [
11 | ]
12 |
13 | operations = [
14 | migrations.CreateModel(
15 | name='Register',
16 | fields=[
17 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
18 | ('name', models.CharField(max_length=10)),
19 | ('email', models.EmailField(max_length=254)),
20 | ('phone_num', models.CharField(max_length=20)),
21 | ('age', models.IntegerField()),
22 | ],
23 | ),
24 | ]
25 |
--------------------------------------------------------------------------------
/26-06-2021/college/student/migrations/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/migrations/__init__.py
--------------------------------------------------------------------------------
/26-06-2021/college/student/migrations/__pycache__/0001_initial.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/migrations/__pycache__/0001_initial.cpython-38.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/student/migrations/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/migrations/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/student/migrations/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/migrations/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/26-06-2021/college/student/models.py:
--------------------------------------------------------------------------------
1 | from django.db import models
2 |
3 | class Register(models.Model):
4 | name = models.CharField(max_length=10)
5 | email = models.EmailField()
6 | phone_num = models.CharField(max_length = 20)
7 | age = models.IntegerField()
8 |
9 | def __str__(self):
10 | return self.name +' '+ self.email
--------------------------------------------------------------------------------
/26-06-2021/college/student/static/css/mystyles.css:
--------------------------------------------------------------------------------
1 | h3{
2 | color:green;
3 | font-size:20px !important;
4 | }
5 |
6 | .phone{
7 | font-size:40px;
8 | }
9 |
10 | #phone{
11 | font-size:60px;
12 | color:yellow;
13 | }
14 |
15 | #phone{
16 | color:red;
17 | }
--------------------------------------------------------------------------------
/26-06-2021/college/student/static/images/image1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/26-06-2021/college/student/static/images/image1.png
--------------------------------------------------------------------------------
/26-06-2021/college/student/static/mystyles.css:
--------------------------------------------------------------------------------
1 | h3{
2 | color:green;
3 | font-size:20px !important;
4 | }
5 |
6 | .phone{
7 | font-size:40px;
8 | }
9 |
10 | #phone{
11 | font-size:60px;
12 | color:yellow;
13 | }
14 |
15 | #phone{
16 | color:red;
17 | }
18 | .image{
19 | background-color:lightblue;
20 | wid
21 | }
--------------------------------------------------------------------------------
/26-06-2021/college/student/templates/student/data.html:
--------------------------------------------------------------------------------
1 | {% load static %}
2 |
3 |
4 |
5 |
6 |
7 | Data
8 |
9 |
16 |
17 |
18 |
19 |
20 |

21 |
22 | This is Inline CSS
23 | Name : {{ data.name }}
24 | Email : {{ data.mail }}
25 | Phone Number : {{ data.phone}}
26 | Age : {{ data.age }}
27 |
28 |
29 |
--------------------------------------------------------------------------------
/26-06-2021/college/student/templates/student/home.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Home Page
5 |
6 |
7 | Home Page
8 |
9 |
--------------------------------------------------------------------------------
/26-06-2021/college/student/templates/student/register.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Student Registration
5 |
6 |
7 |
16 |
17 |
--------------------------------------------------------------------------------
/26-06-2021/college/student/tests.py:
--------------------------------------------------------------------------------
1 | from django.test import TestCase
2 |
3 | # Create your tests here.
4 |
--------------------------------------------------------------------------------
/26-06-2021/college/student/urls.py:
--------------------------------------------------------------------------------
1 | from django.urls import path
2 | from . import views
3 |
4 |
5 | urlpatterns = [
6 | path("register/",views.register)
7 | ]
--------------------------------------------------------------------------------
/26-06-2021/college/student/views.py:
--------------------------------------------------------------------------------
1 | from django.shortcuts import render
2 | from django.http import HttpResponse
3 | from .models import Register
4 | # Create your views here.
5 |
6 |
7 | def home(request):
8 |
9 | return render(request,"student/home.html")
10 |
11 |
12 | def register(request):
13 | if request.method=="POST":
14 |
15 | name = request.POST["Name"]
16 | email = request.POST["Mail"]
17 | phone = request.POST["Phone"]
18 | age = request.POST["Age"]
19 |
20 | data_db_table = Register(name= name,
21 | email= email,
22 | phone_num= phone,
23 | age= age)
24 | data_db_table.save()
25 |
26 | data = {"name":name,"mail":email,"phone":phone,"age":age}
27 |
28 | return render(request,"student/data.html",{"data":data})
29 |
30 | return render(request,"student/register.html")
--------------------------------------------------------------------------------
/26-06-2021/notes.txt:
--------------------------------------------------------------------------------
1 | 26th June 2021
2 | ------------------------
3 |
4 | Day Objectives:
5 | =============
6 | render(request, template_name, context)
7 |
8 | Data Rendering from Templates to Views (POST Request)
9 |
10 | CSS:
11 | ------
12 | Inline
13 | Internal
14 | External
15 |
16 | Selectors : !important > Id > class > tag
17 |
18 | Id selector (#)
19 | class selector (.)
20 | tag
21 |
22 | Specificity : !important > inline > external >internal
--------------------------------------------------------------------------------
/29-06-2021/college/college/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/college/__init__.py
--------------------------------------------------------------------------------
/29-06-2021/college/college/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/college/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/college/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/college/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/college/__pycache__/settings.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/college/__pycache__/settings.cpython-36.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/college/__pycache__/settings.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/college/__pycache__/settings.cpython-38.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/college/__pycache__/urls.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/college/__pycache__/urls.cpython-36.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/college/__pycache__/urls.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/college/__pycache__/urls.cpython-38.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/college/__pycache__/wsgi.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/college/__pycache__/wsgi.cpython-36.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/college/__pycache__/wsgi.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/college/__pycache__/wsgi.cpython-38.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/college/urls.py:
--------------------------------------------------------------------------------
1 | """college URL Configuration
2 |
3 | The `urlpatterns` list routes URLs to views. For more information please see:
4 | https://docs.djangoproject.com/en/2.2/topics/http/urls/
5 | Examples:
6 | Function views
7 | 1. Add an import: from my_app import views
8 | 2. Add a URL to urlpatterns: path('', views.home, name='home')
9 | Class-based views
10 | 1. Add an import: from other_app.views import Home
11 | 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home')
12 | Including another URLconf
13 | 1. Import the include() function: from django.urls import include, path
14 | 2. Add a URL to urlpatterns: path('blog/', include('blog.urls'))
15 | """
16 | from django.contrib import admin
17 | from django.urls import path,include
18 |
19 | from student import views
20 |
21 |
22 | urlpatterns = [
23 | path('admin/', admin.site.urls),
24 | path('home/',views.home),
25 |
26 | path("student/",include("student.urls")),
27 | ]
28 |
--------------------------------------------------------------------------------
/29-06-2021/college/college/wsgi.py:
--------------------------------------------------------------------------------
1 | """
2 | WSGI config for college project.
3 |
4 | It exposes the WSGI callable as a module-level variable named ``application``.
5 |
6 | For more information on this file, see
7 | https://docs.djangoproject.com/en/2.2/howto/deployment/wsgi/
8 | """
9 |
10 | import os
11 |
12 | from django.core.wsgi import get_wsgi_application
13 |
14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'college.settings')
15 |
16 | application = get_wsgi_application()
17 |
--------------------------------------------------------------------------------
/29-06-2021/college/db.sqlite3:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/db.sqlite3
--------------------------------------------------------------------------------
/29-06-2021/college/manage.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | """Django's command-line utility for administrative tasks."""
3 | import os
4 | import sys
5 |
6 |
7 | def main():
8 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'college.settings')
9 | try:
10 | from django.core.management import execute_from_command_line
11 | except ImportError as exc:
12 | raise ImportError(
13 | "Couldn't import Django. Are you sure it's installed and "
14 | "available on your PYTHONPATH environment variable? Did you "
15 | "forget to activate a virtual environment?"
16 | ) from exc
17 | execute_from_command_line(sys.argv)
18 |
19 |
20 | if __name__ == '__main__':
21 | main()
22 |
--------------------------------------------------------------------------------
/29-06-2021/college/student/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/__init__.py
--------------------------------------------------------------------------------
/29-06-2021/college/student/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/student/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/student/__pycache__/admin.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/__pycache__/admin.cpython-36.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/student/__pycache__/admin.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/__pycache__/admin.cpython-38.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/student/__pycache__/models.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/__pycache__/models.cpython-36.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/student/__pycache__/models.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/__pycache__/models.cpython-38.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/student/__pycache__/urls.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/__pycache__/urls.cpython-36.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/student/__pycache__/urls.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/__pycache__/urls.cpython-38.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/student/__pycache__/views.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/__pycache__/views.cpython-36.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/student/__pycache__/views.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/__pycache__/views.cpython-38.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/student/admin.py:
--------------------------------------------------------------------------------
1 | from django.contrib import admin
2 | from .models import Register
3 |
4 |
5 | admin.site.register(Register)
--------------------------------------------------------------------------------
/29-06-2021/college/student/apps.py:
--------------------------------------------------------------------------------
1 | from django.apps import AppConfig
2 |
3 |
4 | class StudentConfig(AppConfig):
5 | name = 'student'
6 |
--------------------------------------------------------------------------------
/29-06-2021/college/student/migrations/0001_initial.py:
--------------------------------------------------------------------------------
1 | # Generated by Django 3.0.7 on 2021-06-28 05:25
2 |
3 | from django.db import migrations, models
4 |
5 |
6 | class Migration(migrations.Migration):
7 |
8 | initial = True
9 |
10 | dependencies = [
11 | ]
12 |
13 | operations = [
14 | migrations.CreateModel(
15 | name='Register',
16 | fields=[
17 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
18 | ('name', models.CharField(max_length=10)),
19 | ('email', models.EmailField(max_length=254)),
20 | ('phone_num', models.CharField(max_length=20)),
21 | ('age', models.IntegerField()),
22 | ],
23 | ),
24 | ]
25 |
--------------------------------------------------------------------------------
/29-06-2021/college/student/migrations/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/migrations/__init__.py
--------------------------------------------------------------------------------
/29-06-2021/college/student/migrations/__pycache__/0001_initial.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/migrations/__pycache__/0001_initial.cpython-36.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/student/migrations/__pycache__/0001_initial.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/migrations/__pycache__/0001_initial.cpython-38.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/student/migrations/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/migrations/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/student/migrations/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/migrations/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/29-06-2021/college/student/models.py:
--------------------------------------------------------------------------------
1 | from django.db import models
2 |
3 | class Register(models.Model):
4 | name = models.CharField(max_length=10)
5 | email = models.EmailField()
6 | phone_num = models.CharField(max_length = 20)
7 | age = models.IntegerField()
8 |
9 | def __str__(self):
10 | return self.name +' '+ self.email + self.phone_num
--------------------------------------------------------------------------------
/29-06-2021/college/student/static/css/mystyles.css:
--------------------------------------------------------------------------------
1 | h3{
2 | color:green;
3 | font-size:20px !important;
4 | }
5 |
6 | .phone{
7 | font-size:40px;
8 | }
9 |
10 | #phone{
11 | font-size:60px;
12 | color:yellow;
13 | }
14 |
15 | #phone{
16 | color:red;
17 | }
--------------------------------------------------------------------------------
/29-06-2021/college/student/static/images/image1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/29-06-2021/college/student/static/images/image1.png
--------------------------------------------------------------------------------
/29-06-2021/college/student/static/mystyles.css:
--------------------------------------------------------------------------------
1 | h3{
2 | color:green;
3 | font-size:20px !important;
4 | }
5 |
6 | .phone{
7 | font-size:40px;
8 | }
9 |
10 | #phone{
11 | font-size:60px;
12 | color:yellow;
13 | }
14 |
15 | #phone{
16 | color:red;
17 | }
18 | .image{
19 | background-color:lightblue;
20 | wid
21 | }
--------------------------------------------------------------------------------
/29-06-2021/college/student/templates/student/data.html:
--------------------------------------------------------------------------------
1 | {% load static %}
2 |
3 |
4 |
5 |
6 |
7 | Data
8 |
9 |
16 |
17 |
18 |
19 |
20 |

21 |
22 | This is Inline CSS
23 | Name : {{ data.name }}
24 | Email : {{ data.mail }}
25 | Phone Number : {{ data.phone}}
26 | Age : {{ data.age }}
27 |
28 |
29 |
--------------------------------------------------------------------------------
/29-06-2021/college/student/templates/student/home.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Home Page
5 |
6 |
7 | Home Page
8 |
9 |
--------------------------------------------------------------------------------
/29-06-2021/college/student/templates/student/register.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Student Registration
5 |
6 |
7 |
16 |
17 |
--------------------------------------------------------------------------------
/29-06-2021/college/student/tests.py:
--------------------------------------------------------------------------------
1 | from django.test import TestCase
2 |
3 | # Create your tests here.
4 |
--------------------------------------------------------------------------------
/29-06-2021/college/student/urls.py:
--------------------------------------------------------------------------------
1 | from django.urls import path
2 | from . import views
3 |
4 |
5 | urlpatterns = [
6 | path("register/",views.register)
7 | ]
--------------------------------------------------------------------------------
/29-06-2021/college/student/views.py:
--------------------------------------------------------------------------------
1 | from django.shortcuts import render
2 | from django.http import HttpResponse
3 | from .models import Register
4 | # Create your views here.
5 |
6 |
7 | def home(request):
8 |
9 | return render(request,"student/home.html")
10 |
11 |
12 | def register(request):
13 | if request.method=="POST":
14 |
15 | name = request.POST["Name"]
16 | email = request.POST["Mail"]
17 | phone = request.POST["Phone"]
18 | age = request.POST["Age"]
19 |
20 | data_db_table = Register(name= name,
21 | email= email,
22 | phone_num= phone,
23 | age= age)
24 | data_db_table.save()
25 |
26 | data = {"name":name,"mail":email,"phone":phone,"age":age}
27 |
28 | return render(request,"student/data.html",{"data":data})
29 |
30 | return render(request,"student/register.html")
--------------------------------------------------------------------------------
/30-06-2021/college/college/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/college/__init__.py
--------------------------------------------------------------------------------
/30-06-2021/college/college/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/college/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/college/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/college/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/college/__pycache__/settings.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/college/__pycache__/settings.cpython-36.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/college/__pycache__/settings.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/college/__pycache__/settings.cpython-38.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/college/__pycache__/urls.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/college/__pycache__/urls.cpython-36.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/college/__pycache__/urls.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/college/__pycache__/urls.cpython-38.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/college/__pycache__/wsgi.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/college/__pycache__/wsgi.cpython-36.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/college/__pycache__/wsgi.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/college/__pycache__/wsgi.cpython-38.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/college/urls.py:
--------------------------------------------------------------------------------
1 | """college URL Configuration
2 |
3 | The `urlpatterns` list routes URLs to views. For more information please see:
4 | https://docs.djangoproject.com/en/2.2/topics/http/urls/
5 | Examples:
6 | Function views
7 | 1. Add an import: from my_app import views
8 | 2. Add a URL to urlpatterns: path('', views.home, name='home')
9 | Class-based views
10 | 1. Add an import: from other_app.views import Home
11 | 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home')
12 | Including another URLconf
13 | 1. Import the include() function: from django.urls import include, path
14 | 2. Add a URL to urlpatterns: path('blog/', include('blog.urls'))
15 | """
16 | from django.contrib import admin
17 | from django.urls import path,include
18 |
19 | from student import views
20 |
21 |
22 | urlpatterns = [
23 | path('admin/', admin.site.urls),
24 | path('home/',views.home),
25 |
26 | path("student/",include("student.urls")),
27 | ]
28 |
--------------------------------------------------------------------------------
/30-06-2021/college/college/wsgi.py:
--------------------------------------------------------------------------------
1 | """
2 | WSGI config for college project.
3 |
4 | It exposes the WSGI callable as a module-level variable named ``application``.
5 |
6 | For more information on this file, see
7 | https://docs.djangoproject.com/en/2.2/howto/deployment/wsgi/
8 | """
9 |
10 | import os
11 |
12 | from django.core.wsgi import get_wsgi_application
13 |
14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'college.settings')
15 |
16 | application = get_wsgi_application()
17 |
--------------------------------------------------------------------------------
/30-06-2021/college/db.sqlite3:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/db.sqlite3
--------------------------------------------------------------------------------
/30-06-2021/college/manage.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | """Django's command-line utility for administrative tasks."""
3 | import os
4 | import sys
5 |
6 |
7 | def main():
8 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'college.settings')
9 | try:
10 | from django.core.management import execute_from_command_line
11 | except ImportError as exc:
12 | raise ImportError(
13 | "Couldn't import Django. Are you sure it's installed and "
14 | "available on your PYTHONPATH environment variable? Did you "
15 | "forget to activate a virtual environment?"
16 | ) from exc
17 | execute_from_command_line(sys.argv)
18 |
19 |
20 | if __name__ == '__main__':
21 | main()
22 |
--------------------------------------------------------------------------------
/30-06-2021/college/student/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/__init__.py
--------------------------------------------------------------------------------
/30-06-2021/college/student/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/student/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/student/__pycache__/admin.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/__pycache__/admin.cpython-36.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/student/__pycache__/admin.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/__pycache__/admin.cpython-38.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/student/__pycache__/models.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/__pycache__/models.cpython-36.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/student/__pycache__/models.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/__pycache__/models.cpython-38.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/student/__pycache__/urls.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/__pycache__/urls.cpython-36.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/student/__pycache__/urls.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/__pycache__/urls.cpython-38.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/student/__pycache__/views.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/__pycache__/views.cpython-36.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/student/__pycache__/views.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/__pycache__/views.cpython-38.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/student/admin.py:
--------------------------------------------------------------------------------
1 | from django.contrib import admin
2 | from .models import Register
3 |
4 |
5 | admin.site.register(Register)
--------------------------------------------------------------------------------
/30-06-2021/college/student/apps.py:
--------------------------------------------------------------------------------
1 | from django.apps import AppConfig
2 |
3 |
4 | class StudentConfig(AppConfig):
5 | name = 'student'
6 |
--------------------------------------------------------------------------------
/30-06-2021/college/student/migrations/0001_initial.py:
--------------------------------------------------------------------------------
1 | # Generated by Django 2.2.2 on 2021-06-30 05:20
2 |
3 | from django.db import migrations, models
4 |
5 |
6 | class Migration(migrations.Migration):
7 |
8 | initial = True
9 |
10 | dependencies = [
11 | ]
12 |
13 | operations = [
14 | migrations.CreateModel(
15 | name='Register',
16 | fields=[
17 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
18 | ('first_name', models.CharField(default='', max_length=30)),
19 | ('last_name', models.CharField(max_length=30)),
20 | ('email', models.EmailField(max_length=254, unique=True)),
21 | ('phone_num', models.CharField(max_length=10)),
22 | ('age', models.IntegerField(blank=True, null=True)),
23 | ],
24 | ),
25 | ]
26 |
--------------------------------------------------------------------------------
/30-06-2021/college/student/migrations/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/migrations/__init__.py
--------------------------------------------------------------------------------
/30-06-2021/college/student/migrations/__pycache__/0001_initial.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/migrations/__pycache__/0001_initial.cpython-36.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/student/migrations/__pycache__/0001_initial.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/migrations/__pycache__/0001_initial.cpython-38.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/student/migrations/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/migrations/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/student/migrations/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/migrations/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/30-06-2021/college/student/models.py:
--------------------------------------------------------------------------------
1 | from django.db import models
2 |
3 | class Register(models.Model):
4 | first_name = models.CharField(max_length=30,default="")
5 | last_name = models.CharField(max_length=30)
6 | email = models.EmailField(unique=True)
7 | phone_num = models.CharField(max_length = 10)
8 | age = models.IntegerField(null=True,blank=True)
9 |
10 | def __str__(self):
11 | return self.first_name
--------------------------------------------------------------------------------
/30-06-2021/college/student/static/css/mystyles.css:
--------------------------------------------------------------------------------
1 | h3{
2 | color:green;
3 | font-size:20px !important;
4 | }
5 |
6 | .phone{
7 | font-size:40px;
8 | }
9 |
10 | #phone{
11 | font-size:60px;
12 | color:yellow;
13 | }
14 |
15 | #phone{
16 | color:red;
17 | }
--------------------------------------------------------------------------------
/30-06-2021/college/student/static/images/image1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/30-06-2021/college/student/static/images/image1.png
--------------------------------------------------------------------------------
/30-06-2021/college/student/static/mystyles.css:
--------------------------------------------------------------------------------
1 | h3{
2 | color:green;
3 | font-size:20px !important;
4 | }
5 |
6 | .phone{
7 | font-size:40px;
8 | }
9 |
10 | #phone{
11 | font-size:60px;
12 | color:yellow;
13 | }
14 |
15 | #phone{
16 | color:red;
17 | }
18 | .image{
19 | background-color:lightblue;
20 | wid
21 | }
--------------------------------------------------------------------------------
/30-06-2021/college/student/templates/student/data.html:
--------------------------------------------------------------------------------
1 | {% load static %}
2 |
3 |
4 |
5 |
6 |
7 | Data
8 |
9 |
16 |
17 |
18 |
19 |
20 |

21 |
22 | This is Inline CSS
23 | Name : {{ data.name }}
24 | Email : {{ data.mail }}
25 | Phone Number : {{ data.phone}}
26 | Age : {{ data.age }}
27 |
28 |
29 |
--------------------------------------------------------------------------------
/30-06-2021/college/student/templates/student/home.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Home Page
5 |
6 |
7 | Home Page
8 |
9 |
--------------------------------------------------------------------------------
/30-06-2021/college/student/templates/student/register.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Student Registration
5 |
6 |
7 |
16 |
17 |
--------------------------------------------------------------------------------
/30-06-2021/college/student/templates/student/student_data.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Student Data
5 |
6 |
7 |
8 |
9 |
10 |
Student Data
11 |
12 |
13 | First Name |
14 | Last Name |
15 | Email |
16 | Phone |
17 | Age |
18 |
19 | {% for i in data %}
20 |
21 | {{i.first_name}} |
22 | {{i.last_name}} |
23 | {{i.email}} |
24 | {{i.phone_num}} |
25 | {{i.age}} |
26 |
27 | {% endfor %}
28 |
29 |
30 |
31 |
--------------------------------------------------------------------------------
/30-06-2021/college/student/templates/student/student_register.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Student Registration
5 |
6 |
7 |
8 |
9 |
10 |
Registration Form
11 |
30 |
31 |
32 |
33 |
--------------------------------------------------------------------------------
/30-06-2021/college/student/tests.py:
--------------------------------------------------------------------------------
1 | from django.test import TestCase
2 |
3 | # Create your tests here.
4 |
--------------------------------------------------------------------------------
/30-06-2021/college/student/urls.py:
--------------------------------------------------------------------------------
1 | from django.urls import path
2 | from . import views
3 |
4 |
5 | urlpatterns = [
6 | path("register/",views.register),
7 | path("student_register/",views.StudentRegistration),
8 | path("student_data/",views.StudentData),
9 | ]
--------------------------------------------------------------------------------
/30-06-2021/college/student/views.py:
--------------------------------------------------------------------------------
1 | from django.shortcuts import render
2 | from django.http import HttpResponse
3 | from .models import Register
4 | # Create your views here.
5 |
6 |
7 | def home(request):
8 |
9 | return render(request,"student/home.html")
10 |
11 |
12 | def register(request):
13 | if request.method=="POST":
14 |
15 | name = request.POST["Name"]
16 | email = request.POST["Mail"]
17 | phone = request.POST["Phone"]
18 | age = request.POST["Age"]
19 |
20 | data_db_table = Register(name= name,
21 | email= email,
22 | phone_num= phone,
23 | age= age)
24 | data_db_table.save()
25 |
26 | data = {"name":name,"mail":email,"phone":phone,"age":age}
27 |
28 | return render(request,"student/data.html",{"data":data})
29 |
30 | return render(request,"student/register.html")
31 |
32 | def StudentRegistration(req):
33 | if req.method=="POST":
34 | fname = req.POST["fname"]
35 | lname = req.POST["lname"]
36 | email = req.POST["mail"]
37 | ph = req.POST["phno"]
38 | age = req.POST["age"]
39 |
40 | student = Register(first_name=fname,last_name=lname,email=email,phone_num=ph,age=age)
41 | student.save()
42 |
43 | return HttpResponse("Registration Successful")
44 |
45 |
46 | return render(req,"student/student_register.html")
47 |
48 | def StudentData(request):
49 |
50 | data = Register.objects.all()
51 | return render(request,"student/student_data.html",{"data":data})
--------------------------------------------------------------------------------
/30-06-2021/notes.txt:
--------------------------------------------------------------------------------
1 | Date : 30 June 2021
2 | -----------------------------------
3 |
4 | Day objectives:
5 |
6 | - CRUD Operations
7 |
8 | -> Let's design a Registration Form
9 |
10 | Bootstrap:
11 | -------------------
12 | Margin: m-1,2,3,4,5, mt,mb,ml,mr
13 | Padding: p-1,2,3,4,5
14 | background : bg-(primary,secondary,success,warning,info,danger)
15 | text-color: text-(primary,secondary,success,warning,info,danger)
16 | form fields : form-control
17 | buttons : btn
18 |
19 |
20 | DTL :Django Template Language
--------------------------------------------------------------------------------
/FileUpload/FileUpload/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/FileUpload/__init__.py
--------------------------------------------------------------------------------
/FileUpload/FileUpload/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/FileUpload/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/FileUpload/FileUpload/__pycache__/settings.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/FileUpload/__pycache__/settings.cpython-36.pyc
--------------------------------------------------------------------------------
/FileUpload/FileUpload/__pycache__/urls.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/FileUpload/__pycache__/urls.cpython-36.pyc
--------------------------------------------------------------------------------
/FileUpload/FileUpload/__pycache__/wsgi.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/FileUpload/__pycache__/wsgi.cpython-36.pyc
--------------------------------------------------------------------------------
/FileUpload/FileUpload/urls.py:
--------------------------------------------------------------------------------
1 | """FileUpload URL Configuration
2 |
3 | The `urlpatterns` list routes URLs to views. For more information please see:
4 | https://docs.djangoproject.com/en/2.2/topics/http/urls/
5 | Examples:
6 | Function views
7 | 1. Add an import: from my_app import views
8 | 2. Add a URL to urlpatterns: path('', views.home, name='home')
9 | Class-based views
10 | 1. Add an import: from other_app.views import Home
11 | 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home')
12 | Including another URLconf
13 | 1. Import the include() function: from django.urls import include, path
14 | 2. Add a URL to urlpatterns: path('blog/', include('blog.urls'))
15 | """
16 | from django.contrib import admin
17 | from django.urls import path,include
18 |
19 | from django.conf import settings
20 | from django.conf.urls.static import static
21 |
22 | urlpatterns = [
23 | path('admin/', admin.site.urls),
24 | path("",include("myApp.urls")),
25 | ]
26 |
27 | if settings.DEBUG:
28 | urlpatterns+=static(settings.MEDIA_URL,document_root = settings.MEDIA_ROOT)
29 |
30 |
--------------------------------------------------------------------------------
/FileUpload/FileUpload/wsgi.py:
--------------------------------------------------------------------------------
1 | """
2 | WSGI config for FileUpload project.
3 |
4 | It exposes the WSGI callable as a module-level variable named ``application``.
5 |
6 | For more information on this file, see
7 | https://docs.djangoproject.com/en/2.2/howto/deployment/wsgi/
8 | """
9 |
10 | import os
11 |
12 | from django.core.wsgi import get_wsgi_application
13 |
14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'FileUpload.settings')
15 |
16 | application = get_wsgi_application()
17 |
--------------------------------------------------------------------------------
/FileUpload/manage.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | """Django's command-line utility for administrative tasks."""
3 | import os
4 | import sys
5 |
6 |
7 | def main():
8 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'FileUpload.settings')
9 | try:
10 | from django.core.management import execute_from_command_line
11 | except ImportError as exc:
12 | raise ImportError(
13 | "Couldn't import Django. Are you sure it's installed and "
14 | "available on your PYTHONPATH environment variable? Did you "
15 | "forget to activate a virtual environment?"
16 | ) from exc
17 | execute_from_command_line(sys.argv)
18 |
19 |
20 | if __name__ == '__main__':
21 | main()
22 |
--------------------------------------------------------------------------------
/FileUpload/media/users/2.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/media/users/2.jpg
--------------------------------------------------------------------------------
/FileUpload/media/users/22-226404_girl-wallpaper-hd-1080p-cute-little-a-sweet.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/media/users/22-226404_girl-wallpaper-hd-1080p-cute-little-a-sweet.jpg
--------------------------------------------------------------------------------
/FileUpload/media/users/22-226404_girl-wallpaper-hd-1080p-cute-little-a-sweet_I7vlnAO.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/media/users/22-226404_girl-wallpaper-hd-1080p-cute-little-a-sweet_I7vlnAO.jpg
--------------------------------------------------------------------------------
/FileUpload/media/users/apssdc_final.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/media/users/apssdc_final.jpg
--------------------------------------------------------------------------------
/FileUpload/media/users/apssdc_final_jErWHcl.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/media/users/apssdc_final_jErWHcl.jpg
--------------------------------------------------------------------------------
/FileUpload/myApp/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/myApp/__init__.py
--------------------------------------------------------------------------------
/FileUpload/myApp/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/myApp/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/FileUpload/myApp/__pycache__/admin.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/myApp/__pycache__/admin.cpython-36.pyc
--------------------------------------------------------------------------------
/FileUpload/myApp/__pycache__/forms.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/myApp/__pycache__/forms.cpython-36.pyc
--------------------------------------------------------------------------------
/FileUpload/myApp/__pycache__/models.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/myApp/__pycache__/models.cpython-36.pyc
--------------------------------------------------------------------------------
/FileUpload/myApp/__pycache__/urls.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/myApp/__pycache__/urls.cpython-36.pyc
--------------------------------------------------------------------------------
/FileUpload/myApp/__pycache__/views.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/myApp/__pycache__/views.cpython-36.pyc
--------------------------------------------------------------------------------
/FileUpload/myApp/admin.py:
--------------------------------------------------------------------------------
1 | from django.contrib import admin
2 |
3 | # Register your models here.
4 |
--------------------------------------------------------------------------------
/FileUpload/myApp/apps.py:
--------------------------------------------------------------------------------
1 | from django.apps import AppConfig
2 |
3 |
4 | class MyappConfig(AppConfig):
5 | name = 'myApp'
6 |
--------------------------------------------------------------------------------
/FileUpload/myApp/forms.py:
--------------------------------------------------------------------------------
1 | # from django import forms
2 | from django.forms import ModelForm
3 | from .models import profile
4 |
5 |
6 | class ProfileForm(ModelForm):
7 | class Meta:
8 | model = profile
9 | fields = "__all__"
--------------------------------------------------------------------------------
/FileUpload/myApp/migrations/0001_initial.py:
--------------------------------------------------------------------------------
1 | # Generated by Django 2.2.2 on 2021-07-08 04:58
2 |
3 | from django.db import migrations, models
4 |
5 |
6 | class Migration(migrations.Migration):
7 |
8 | initial = True
9 |
10 | dependencies = [
11 | ]
12 |
13 | operations = [
14 | migrations.CreateModel(
15 | name='profile',
16 | fields=[
17 | ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
18 | ('name', models.CharField(max_length=20)),
19 | ('image', models.ImageField(upload_to='users/')),
20 | ],
21 | ),
22 | ]
23 |
--------------------------------------------------------------------------------
/FileUpload/myApp/migrations/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/myApp/migrations/__init__.py
--------------------------------------------------------------------------------
/FileUpload/myApp/migrations/__pycache__/0001_initial.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/myApp/migrations/__pycache__/0001_initial.cpython-36.pyc
--------------------------------------------------------------------------------
/FileUpload/myApp/migrations/__pycache__/__init__.cpython-36.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/FileUpload/myApp/migrations/__pycache__/__init__.cpython-36.pyc
--------------------------------------------------------------------------------
/FileUpload/myApp/models.py:
--------------------------------------------------------------------------------
1 | from django.db import models
2 |
3 | # Create your models here.
4 |
5 |
6 | class profile(models.Model):
7 | name = models.CharField(max_length=20)
8 | image = models.ImageField(upload_to="users/")
9 |
10 |
11 | def __str__(self):
12 | return self.name
--------------------------------------------------------------------------------
/FileUpload/myApp/templates/data.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Data
5 |
6 |
7 |
8 |
9 | Name |
10 | Image |
11 |
12 | {% for i in d %}
13 |
14 | {{i.name}} |
15 |  |
16 |
17 | {% endfor %}
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/FileUpload/myApp/templates/profile.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Profile
5 |
6 |
7 |
8 |
13 |
14 |
--------------------------------------------------------------------------------
/FileUpload/myApp/tests.py:
--------------------------------------------------------------------------------
1 | from django.test import TestCase
2 |
3 | # Create your tests here.
4 |
--------------------------------------------------------------------------------
/FileUpload/myApp/urls.py:
--------------------------------------------------------------------------------
1 | from django.urls import path
2 |
3 | from . import views
4 |
5 |
6 | urlpatterns = [
7 | path("profile/",views.user,name="profile"),
8 | path("data/",views.data,name="data"),
9 | ]
10 |
--------------------------------------------------------------------------------
/FileUpload/myApp/views.py:
--------------------------------------------------------------------------------
1 | from django.shortcuts import render,redirect
2 | from .forms import ProfileForm
3 | from .models import profile
4 |
5 | from django.http import HttpResponse
6 |
7 |
8 |
9 | def user(request):
10 | form = ProfileForm()
11 | if request.method=="POST":
12 | form = ProfileForm(request.POST,request.FILES)
13 | if form.is_valid():
14 | form.save()
15 | # return HttpResponse("Successfully uploaded
")
16 | return redirect("data")
17 | return render(request,"profile.html",{"form":form})
18 |
19 |
20 |
21 | def data(request):
22 | d = profile.objects.all()
23 | return render(request,"data.html",{"d":d})
--------------------------------------------------------------------------------
/GreetingCardSender/GreetingCardSender/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/GreetingCardSender/GreetingCardSender/__init__.py
--------------------------------------------------------------------------------
/GreetingCardSender/GreetingCardSender/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/GreetingCardSender/GreetingCardSender/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/GreetingCardSender/GreetingCardSender/__pycache__/settings.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/GreetingCardSender/GreetingCardSender/__pycache__/settings.cpython-38.pyc
--------------------------------------------------------------------------------
/GreetingCardSender/GreetingCardSender/__pycache__/urls.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/GreetingCardSender/GreetingCardSender/__pycache__/urls.cpython-38.pyc
--------------------------------------------------------------------------------
/GreetingCardSender/GreetingCardSender/__pycache__/wsgi.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/GreetingCardSender/GreetingCardSender/__pycache__/wsgi.cpython-38.pyc
--------------------------------------------------------------------------------
/GreetingCardSender/GreetingCardSender/asgi.py:
--------------------------------------------------------------------------------
1 | """
2 | ASGI config for GreetingCardSender project.
3 |
4 | It exposes the ASGI callable as a module-level variable named ``application``.
5 |
6 | For more information on this file, see
7 | https://docs.djangoproject.com/en/3.0/howto/deployment/asgi/
8 | """
9 |
10 | import os
11 |
12 | from django.core.asgi import get_asgi_application
13 |
14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'GreetingCardSender.settings')
15 |
16 | application = get_asgi_application()
17 |
--------------------------------------------------------------------------------
/GreetingCardSender/GreetingCardSender/urls.py:
--------------------------------------------------------------------------------
1 | """GreetingCardSender URL Configuration
2 |
3 | The `urlpatterns` list routes URLs to views. For more information please see:
4 | https://docs.djangoproject.com/en/3.0/topics/http/urls/
5 | Examples:
6 | Function views
7 | 1. Add an import: from my_app import views
8 | 2. Add a URL to urlpatterns: path('', views.home, name='home')
9 | Class-based views
10 | 1. Add an import: from other_app.views import Home
11 | 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home')
12 | Including another URLconf
13 | 1. Import the include() function: from django.urls import include, path
14 | 2. Add a URL to urlpatterns: path('blog/', include('blog.urls'))
15 | """
16 | from django.contrib import admin
17 | from django.urls import path
18 | from card import views
19 |
20 | urlpatterns = [
21 | path('admin/', admin.site.urls),
22 | path('greetme/', views.greet_me, name="greet_me"),
23 | ]
24 |
--------------------------------------------------------------------------------
/GreetingCardSender/GreetingCardSender/wsgi.py:
--------------------------------------------------------------------------------
1 | """
2 | WSGI config for GreetingCardSender project.
3 |
4 | It exposes the WSGI callable as a module-level variable named ``application``.
5 |
6 | For more information on this file, see
7 | https://docs.djangoproject.com/en/3.0/howto/deployment/wsgi/
8 | """
9 |
10 | import os
11 |
12 | from django.core.wsgi import get_wsgi_application
13 |
14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'GreetingCardSender.settings')
15 |
16 | application = get_wsgi_application()
17 |
--------------------------------------------------------------------------------
/GreetingCardSender/card/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/GreetingCardSender/card/__init__.py
--------------------------------------------------------------------------------
/GreetingCardSender/card/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/GreetingCardSender/card/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/GreetingCardSender/card/__pycache__/admin.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/GreetingCardSender/card/__pycache__/admin.cpython-38.pyc
--------------------------------------------------------------------------------
/GreetingCardSender/card/__pycache__/models.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/GreetingCardSender/card/__pycache__/models.cpython-38.pyc
--------------------------------------------------------------------------------
/GreetingCardSender/card/__pycache__/views.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/GreetingCardSender/card/__pycache__/views.cpython-38.pyc
--------------------------------------------------------------------------------
/GreetingCardSender/card/admin.py:
--------------------------------------------------------------------------------
1 | from django.contrib import admin
2 |
3 | # Register your models here.
4 |
--------------------------------------------------------------------------------
/GreetingCardSender/card/apps.py:
--------------------------------------------------------------------------------
1 | from django.apps import AppConfig
2 |
3 |
4 | class CardConfig(AppConfig):
5 | name = 'card'
6 |
--------------------------------------------------------------------------------
/GreetingCardSender/card/migrations/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/GreetingCardSender/card/migrations/__init__.py
--------------------------------------------------------------------------------
/GreetingCardSender/card/migrations/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/GreetingCardSender/card/migrations/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/GreetingCardSender/card/models.py:
--------------------------------------------------------------------------------
1 | from django.db import models
2 |
3 | # Create your models here.
4 |
--------------------------------------------------------------------------------
/GreetingCardSender/card/templates/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Greet Me
6 |
7 |
8 |
14 |
15 |
--------------------------------------------------------------------------------
/GreetingCardSender/card/tests.py:
--------------------------------------------------------------------------------
1 | from django.test import TestCase
2 |
3 | # Create your tests here.
4 |
--------------------------------------------------------------------------------
/GreetingCardSender/card/views.py:
--------------------------------------------------------------------------------
1 | from django.shortcuts import render
2 | from django.http import HttpResponse
3 | from django.core.mail import EmailMessage
4 | from GreetingCardSender import settings
5 | from PIL import Image
6 | def greet_me(request):
7 | if request.method == "POST":
8 | name = request.POST.get('name')
9 | email = request.POST.get('email')
10 |
11 |
12 | # sending mail
13 | sub = "Greetings from APSSDC!"
14 | body = "Hey "+ name.title()+ ", you have successfully completed the django code"
15 | receiver_email_id = email
16 | sender_email_id = settings.EMAIL_HOST_USER
17 | email_msg = EmailMessage(sub, body, sender_email_id, [receiver_email_id])
18 |
19 | #image reading
20 | # im = Image.open('static/img/temp_pic.jpg')
21 | # print('\n\n *******', im)
22 | email_msg.attach_file('static/img/temp_pic.jpg')
23 | email_msg.send()
24 | return HttpResponse("mail sent!!")
25 | return render(request, 'index.html',{})
--------------------------------------------------------------------------------
/GreetingCardSender/db.sqlite3:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/GreetingCardSender/db.sqlite3
--------------------------------------------------------------------------------
/GreetingCardSender/manage.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | """Django's command-line utility for administrative tasks."""
3 | import os
4 | import sys
5 |
6 |
7 | def main():
8 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'GreetingCardSender.settings')
9 | try:
10 | from django.core.management import execute_from_command_line
11 | except ImportError as exc:
12 | raise ImportError(
13 | "Couldn't import Django. Are you sure it's installed and "
14 | "available on your PYTHONPATH environment variable? Did you "
15 | "forget to activate a virtual environment?"
16 | ) from exc
17 | execute_from_command_line(sys.argv)
18 |
19 |
20 | if __name__ == '__main__':
21 | main()
22 |
--------------------------------------------------------------------------------
/GreetingCardSender/static/img/temp_pic.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/GreetingCardSender/static/img/temp_pic.jpg
--------------------------------------------------------------------------------
/SampleProject/SampleProject/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/SampleProject/SampleProject/__init__.py
--------------------------------------------------------------------------------
/SampleProject/SampleProject/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/SampleProject/SampleProject/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/SampleProject/SampleProject/__pycache__/settings.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/SampleProject/SampleProject/__pycache__/settings.cpython-38.pyc
--------------------------------------------------------------------------------
/SampleProject/SampleProject/__pycache__/urls.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/SampleProject/SampleProject/__pycache__/urls.cpython-38.pyc
--------------------------------------------------------------------------------
/SampleProject/SampleProject/__pycache__/wsgi.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/SampleProject/SampleProject/__pycache__/wsgi.cpython-38.pyc
--------------------------------------------------------------------------------
/SampleProject/SampleProject/asgi.py:
--------------------------------------------------------------------------------
1 | """
2 | ASGI config for SampleProject project.
3 |
4 | It exposes the ASGI callable as a module-level variable named ``application``.
5 |
6 | For more information on this file, see
7 | https://docs.djangoproject.com/en/3.0/howto/deployment/asgi/
8 | """
9 |
10 | import os
11 |
12 | from django.core.asgi import get_asgi_application
13 |
14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'SampleProject.settings')
15 |
16 | application = get_asgi_application()
17 |
--------------------------------------------------------------------------------
/SampleProject/SampleProject/urls.py:
--------------------------------------------------------------------------------
1 | """SampleProject URL Configuration
2 |
3 | The `urlpatterns` list routes URLs to views. For more information please see:
4 | https://docs.djangoproject.com/en/3.0/topics/http/urls/
5 | Examples:
6 | Function views
7 | 1. Add an import: from my_app import views
8 | 2. Add a URL to urlpatterns: path('', views.home, name='home')
9 | Class-based views
10 | 1. Add an import: from other_app.views import Home
11 | 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home')
12 | Including another URLconf
13 | 1. Import the include() function: from django.urls import include, path
14 | 2. Add a URL to urlpatterns: path('blog/', include('blog.urls'))
15 | """
16 | from django.contrib import admin
17 | from django.urls import path
18 | from first_app import views
19 |
20 | urlpatterns = [
21 | path('admin/', admin.site.urls),
22 | path('index/', views.index),
23 | path('sayhi/', views.say_hi),
24 | path('table/', views.table),
25 | ]
26 |
--------------------------------------------------------------------------------
/SampleProject/SampleProject/wsgi.py:
--------------------------------------------------------------------------------
1 | """
2 | WSGI config for SampleProject project.
3 |
4 | It exposes the WSGI callable as a module-level variable named ``application``.
5 |
6 | For more information on this file, see
7 | https://docs.djangoproject.com/en/3.0/howto/deployment/wsgi/
8 | """
9 |
10 | import os
11 |
12 | from django.core.wsgi import get_wsgi_application
13 |
14 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'SampleProject.settings')
15 |
16 | application = get_wsgi_application()
17 |
--------------------------------------------------------------------------------
/SampleProject/db.sqlite3:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/SampleProject/db.sqlite3
--------------------------------------------------------------------------------
/SampleProject/first_app/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/SampleProject/first_app/__init__.py
--------------------------------------------------------------------------------
/SampleProject/first_app/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/SampleProject/first_app/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/SampleProject/first_app/__pycache__/admin.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/SampleProject/first_app/__pycache__/admin.cpython-38.pyc
--------------------------------------------------------------------------------
/SampleProject/first_app/__pycache__/models.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/SampleProject/first_app/__pycache__/models.cpython-38.pyc
--------------------------------------------------------------------------------
/SampleProject/first_app/__pycache__/views.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/SampleProject/first_app/__pycache__/views.cpython-38.pyc
--------------------------------------------------------------------------------
/SampleProject/first_app/admin.py:
--------------------------------------------------------------------------------
1 | from django.contrib import admin
2 |
3 | # Register your models here.
4 |
--------------------------------------------------------------------------------
/SampleProject/first_app/apps.py:
--------------------------------------------------------------------------------
1 | from django.apps import AppConfig
2 |
3 |
4 | class FirstAppConfig(AppConfig):
5 | name = 'first_app'
6 |
--------------------------------------------------------------------------------
/SampleProject/first_app/migrations/__init__.py:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/SampleProject/first_app/migrations/__init__.py
--------------------------------------------------------------------------------
/SampleProject/first_app/migrations/__pycache__/__init__.cpython-38.pyc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/SampleProject/first_app/migrations/__pycache__/__init__.cpython-38.pyc
--------------------------------------------------------------------------------
/SampleProject/first_app/models.py:
--------------------------------------------------------------------------------
1 | from django.db import models
2 |
3 | # Create your models here.
4 |
--------------------------------------------------------------------------------
/SampleProject/first_app/templates/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 | Sample Project First 1
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/SampleProject/first_app/templates/say_hi.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Say Hi
6 |
7 |
8 | Hi {{name}}, welcome to {{college}}
9 |
10 |
11 |
--------------------------------------------------------------------------------
/SampleProject/first_app/templates/table.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | table
6 |
7 |
8 |
9 | {% for i in list %}
10 |
11 | {{forloop.counter}} * {{num}} = |
12 | {{i}} |
13 |
14 | {% endfor %}
15 |
16 |
17 |
--------------------------------------------------------------------------------
/SampleProject/first_app/tests.py:
--------------------------------------------------------------------------------
1 | from django.test import TestCase
2 |
3 | # Create your tests here.
4 |
--------------------------------------------------------------------------------
/SampleProject/first_app/views.py:
--------------------------------------------------------------------------------
1 | from django.shortcuts import render
2 |
3 |
4 | def index(request):
5 | return render(request, 'demo.html', {})
6 |
7 | def say_hi(request, name):
8 | name_ = name.title()
9 |
10 | return render(request, 'say_hi.html',{'name': name_,
11 | 'college': 'SRM'})
12 |
13 | def table(request, num):
14 | l = []
15 |
16 | for i in range(1,11):
17 | l.append(i*num)
18 | return render(request,'table.html',{'num':num, 'list': l})
--------------------------------------------------------------------------------
/SampleProject/manage.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python
2 | """Django's command-line utility for administrative tasks."""
3 | import os
4 | import sys
5 |
6 |
7 | def main():
8 | os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'SampleProject.settings')
9 | try:
10 | from django.core.management import execute_from_command_line
11 | except ImportError as exc:
12 | raise ImportError(
13 | "Couldn't import Django. Are you sure it's installed and "
14 | "available on your PYTHONPATH environment variable? Did you "
15 | "forget to activate a virtual environment?"
16 | ) from exc
17 | execute_from_command_line(sys.argv)
18 |
19 |
20 | if __name__ == '__main__':
21 | main()
22 |
--------------------------------------------------------------------------------
/Web Development Using Django.pptx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/Web Development Using Django.pptx
--------------------------------------------------------------------------------
/day 1 .txt:
--------------------------------------------------------------------------------
1 | SCM - Git & Github
2 | -------------------
3 |
4 | git bash
5 | or ---- git ---- git Hub
6 | git Gui
7 | | |
8 | | | |
9 | | Software
10 | local A remote folder
11 | system or a cloud
12 |
13 | Today :
14 | -------
15 | Accesing a remote project(repository)
16 |
17 | Repository -- folder -- directory
18 |
19 | to download a remote repository we need to use clone command
20 | syntax:
21 | git clone url
22 | dir -- will display the list of directories
23 | cd folder_name -- to change our working repository
24 |
25 | git log :
26 | by using command we can see the total commints.
27 | git log --oneline : will limit our commit messages
28 | git log -n 2 : display last 2 full commits
--------------------------------------------------------------------------------
/functions.md:
--------------------------------------------------------------------------------
1 | #### 15 june 2021
2 | # Functions
3 |
4 | Function is block of reusablecode that is used to perform a specific action or tasak.
5 |
6 | - User define functions
7 | - syntx
8 | ```python
9 | def function_name():
10 | return True
11 | ```
12 | 1. Required arguments
13 | 2. Keyword arguments
14 | 3. Default arguments
15 | 4. Variable length arguments
16 |
17 | - Built-in functions
18 | to get list of available funtions,
19 | - `import builtins`
20 | - `dir builtins`
21 |
22 |
23 | # python Data Structures
24 | - list
25 | - tuple
26 | - dictionary
27 | - sets
28 | # list
29 | - is array type data structure,
30 | - not a homogeneous array.
31 | - it is mutabile one
32 | - iterable
33 | - like string it is also having 2 types of indexes,+ve and -ve
34 |
--------------------------------------------------------------------------------
/git branch example.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/git branch example.png
--------------------------------------------------------------------------------
/git branche_sample.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/AP-Skill-Development-Corporation/WebDevelopmentUsingDjango-internship-SRM-University/6700256f977e088e942301e9e579527fcf118c74/git branche_sample.png
--------------------------------------------------------------------------------
/loops.md:
--------------------------------------------------------------------------------
1 | ## Day 7 loops
2 |
3 | to execute staments in a given sequence of time.
4 |
5 | in python we have for and while:
6 |
7 | ## for loop syntax
8 | ```
9 | for temp_var in Sequence_of_data:
10 | statements
11 | ```
12 | Example for sequence of data is:
13 | integers
14 | string
15 | List
16 | tuple
17 | Dictionary
18 |
19 | ### for integer sequence we need to use this range()
20 | for generating integers values as a sequence here we have a in built function called `range()`
21 |
22 | range(4) `--> 0,1,2,3` 4 is end value
23 |
24 | range(1,4) `-->1,2,3`
25 |
26 | range(1,10,2) `--> 1,3,5,7,9`
27 |
28 | ### for strings
29 | by default a string is iterable so we can directly generate sequence of characters by strings
30 |
31 | ## While Loop Syntax
32 | ```
33 | init_value
34 | while condition:
35 | statements
36 |
37 | inc/dec
38 | ```
39 |
40 | ### termination conditions
41 | - Break
42 | - Continue
43 |
--------------------------------------------------------------------------------