1 Star 0 Fork 22

ryan_ke / chemlab

forked from zcystart / chemlab 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README

###在线演示环境 http://101.34.18.118:8002/
(图片未压缩,所以加载有点慢)

1. 学生端
学生账号:19001234
学生密码:xm123456
2. 管理员端/教师端
管理员账号:admin
管理员密码:admin123

教师账号: x100x
教师密码: x100x123

运行环境

在Python3.7,Django2.2,MySQL8.0 版本下测试运行成功,windows,linux平台。

运行步骤

首先安装好运行环境,配置好python虚拟环境

1.安装requirements.txt依赖包(环境)
pip install -r requirements.txt

2.修改settings.py下的数据库配置
DATABASES = {
    'default': {
        'ENGINE': 'django.db.backends.mysql',
        # 'NAME': os.path.join(BASE_DIR, 'db.sqlite3'),
        'NAME': 'lms',
        'HOST': '127.0.0.1',
        'PORT': '3306',
        'USER': 'root',
        'PASSWORD': 'root'
    }
}

3.导入数据库文件lms.sql

python manage.py makemigrations
python manage.py migrate
#上面两步进行迁移,完成数据库表的建立


4.命令行输入
python manage.py runserver
#默认端口开在127.0.0.1:8000


PS:#创建超级管理员用户
python manage.py createsuperuser

5.然后浏览器打开localhost:8080/127.0.0.1:8000/进入管理系统

###页面展示 image text

学生端 image text image text image text image text image text image text image text image text image text image text image text image text

管理端 image text image text image text image text image text image text image text

###导入药品列表说明 文件 lms/static/lms/example/xls/Medicine-2022-01-27.xls

采用了开源的simpleui








2022-6-21更新 #错误提示

query = query.decode(errors='replace')
AttributeError: 'str' object has no attribute 'decode'

点击最后一条链接, 将decode改为encode

def last_executed_query(self, cursor, sql, params):
    # With MySQLdb, cursor objects have an (undocumented) "_executed"
    # attribute where the exact query sent to the database is saved.
    # See MySQLdb/cursors.py in the source distribution.
    query = getattr(cursor, '_executed', None)
    if query is not None:
        query = query.decode(errors='replace')
    return query

query = query.encode(errors='replace')

空文件

简介

实验室药品管理和预警系统django实现 展开 收起
Python
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
Python
1
https://gitee.com/ryan_ke_admin/chemlab.git
git@gitee.com:ryan_ke_admin/chemlab.git
ryan_ke_admin
chemlab
chemlab
master

搜索帮助