Giter Site home page Giter Site logo

django-crud's Introduction

Django + Python🐍

Clique e instale o python

link

Venv

é uma ferramente q nos ajuda a isolar as dependencias e versoes do projeto, crie uma venv com o comando:

python3 -m venv <nome-da-pasta>

Para ativar, entre na pasta e execute:

source <nome-da-pasta>/bin/activate

Ao ativar o terminal vai ficar assim:

(client1) ➜ django-crud

Instale o Django:

pip install Django

Inicie seu projeto:

django-admin startproject <nome-do-projeto> .

Obs: o ponto nao permite criar o projeto numa subpasta

Execute seu projeto com:

python manage.py runserver

Migrate

Execute antes de criar o superuser ou dps de uma migrations

python3 manage.py migrate

Criar superuser

Escolha senha e username dps de executar:

python3 manage.py createsuperuser

Apos isso faça o login na rota /admin

Criando rotas:

Vc pode criar rotas com o comando

python3 manage.py startapp <nome-da-pasta>

Migrations

A cada alteracao ou criacao de novo model, execute:

python3 manage.py makemigrations

Exemplo de código

https://github.com/jovimoura/django-crud

Título

Texto

  • Lista

django-crud's People

Contributors

jovimoura avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.