Giter VIP home page Giter VIP logo

2018dbdesign's Introduction

Build Status

2018数据库原理课程设计

Author: LuoD

Time: 2018/01/04

This is my curriculum Design of Database Princeple. Based on Python and Django, thanks to the wellknown EChat.js, it is great for data visualization.


运行效果 View Result

信息概览 basic

车辆管理 carmanange

使用方法 Usage

  1. clone this repo
$ git clone https://github.com/RonDen/2018DBDesign.git
  1. check dependencies 运行需要Django(2.1.7),推荐使用conda管理。MySQL8.0。
$ conda activate envname
$ pip install Django==2.1.7 # if not installed
$ # or use the requirement.txt
$ pip install -r requirement.txt
  1. 删除迁移文件,删除APP下面migrations文件夹下除__init__.py文件的所有文件
  2. 根据settings.py配置数据库连接。
  3. 重新生成迁移文件
$ cd DBDesign
$ python manage.py makemigrations
$ python manage.py migrate
  1. use the scripts in utils/ to generate some dummy data in the database for better view. I recommend use the django shell with ipython enchance. Or you can use the transportation.sql to quick start(heavily recommanded!).

Start DB Method 1:

$ python manage.py shell
$ %cd utils # 使用utils文件夹下的脚本生成数据库中数据
$ run createUser.py
$ run insert2.py  # you can modify the num in this script for your prefer.
$ run insert_record.py
$ run addGroup.py
$ run changetime.py  # change time to make it more random

Start DB Method 2:

$ mysql -uroot -ppassword
mysql> use transportation; # if not exists, create it.
mysql> source transportation.sql;
  1. runserver and open your browser view the result
$ python manage.py runserver

if these no errors and warnings, just open http://127.0.0.1:8000 in your browser to see the result.

2018dbdesign's People

Contributors

ronden avatar

Watchers

James Cloos 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.