上一页 1 ··· 11 12 13 14 15 16 17 18 19 ··· 26 下一页
摘要: 1. 点击页面出现双重应用前缀, 观察原因, 模板文件设置指向的时候没有加'/', 导致表单提交时候默认不是从根目录寻找路径, 而是在当前路径的前提下, 再向应用名提交, 则报错.(路径错误则检查数据提交路径.)2. csrftoken,在使用csrftoken的时候,会在页面生成一个隐藏域. 如果 阅读全文
posted @ 2019-10-14 02:30 Jrri 阅读(194) 评论(0) 推荐(0) 编辑
摘要: 一. python-alipay-sdk 安装下载:卸载pycrypto(如有) 安装python-alipay-sdk 二.生成密钥文件1. 使用OpenSSL 2. 生成私钥 3. 生成公钥 4. 退出OpenSSL 三.登录支付宝绑定己方公钥, 获取后方公钥(沙箱):https://sandb 阅读全文
posted @ 2019-10-14 02:04 Jrri 阅读(5080) 评论(5) 推荐(0) 编辑
摘要: 报错信息:render() got an unexpected keyword argument 'renderer'原因分析: django框架版本更新过程中, 与富文本模块之间的数据传输格式产生了出入, 由此引发的问题. 更改富文本模块,或者更改相对应的django源码可解决问题. # 官方说明 阅读全文
posted @ 2019-10-14 01:26 Jrri 阅读(210) 评论(0) 推荐(0) 编辑
摘要: 修改Mysql的事务隔离级别 在位置: 后面添加(读取提交内容): 保存后重启mysql服务: SQL的4种隔离级别Read Uncommitted(读取未提交内容) 在该隔离级别,所有事务都可以看到其他未提交事务的执行结果。本隔离级别很少用于实际应用,因为它的性能也不比其他级别好多少。读取未提交的 阅读全文
posted @ 2019-10-11 04:02 Jrri 阅读(9455) 评论(0) 推荐(0) 编辑
摘要: 1.安装jieba 2.引入jieba cd 到haystack安装目录backends下, 新建文件ChineseAnalyzer.py,键入内容 3.更改haystack的后台文件文件夹下cp并修改whoosh_backend.py, 增加jieba. # 文件名是惯例, 可自行修改修改whoo 阅读全文
posted @ 2019-09-30 19:37 Jrri 阅读(381) 评论(0) 推荐(0) 编辑
摘要: 使用django自带的认证系统, 挪移到django2.X启动服务后报错: TypeError at /index 'bool' object is not callable错误代码: 解决方法,取消调用: 原因分析:此集成模块的is_authenticated方法指向models.auth模块中的 阅读全文
posted @ 2019-09-30 00:44 Jrri 阅读(343) 评论(0) 推荐(0) 编辑
摘要: django2.2版本与 pymysql模块兼容出错, 错误代码:django.core.exceptions.ImproperlyConfigured: mysqlclient 1.3.13 or newer is required; you have 0.9.3要求mysqlclient需要1. 阅读全文
posted @ 2019-09-29 21:11 Jrri 阅读(429) 评论(0) 推荐(0) 编辑
摘要: 将项目迁移至django2.X, 中间件提示错误为:ERRORS:?: (admin.E408) 'django.contrib.auth.middleware.AuthenticationMiddleware' must be in MIDDLEWARE in order to use the a 阅读全文
posted @ 2019-09-29 18:44 Jrri 阅读(1205) 评论(0) 推荐(2) 编辑
摘要: 使用以往框架的项目路由urls文件 报错, 错误信息: Specifying a namespace in include() without providing an app_name is not supported. Set the app_name attribute in the incl 阅读全文
posted @ 2019-09-29 01:34 Jrri 阅读(812) 评论(0) 推荐(0) 编辑
摘要: 模型类引入外键的时候需要添加 on_delete=models.CASCADE 例:以往版本: name = models.ForeignKey('Name') type = models.ForeignKey('Type',verbose_name='类别') 需改为: name = models 阅读全文
posted @ 2019-09-28 21:37 Jrri 阅读(275) 评论(0) 推荐(0) 编辑
上一页 1 ··· 11 12 13 14 15 16 17 18 19 ··· 26 下一页