Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

win10的项目运行步骤 #12

Open
wing-office opened this issue Oct 6, 2020 · 1 comment
Open

win10的项目运行步骤 #12

wing-office opened this issue Oct 6, 2020 · 1 comment

Comments

@wing-office
Copy link

wing-office commented Oct 6, 2020

大神,我把我在win10上运行的记录发一下哈。
运行环境:win10 winpython3.6.6
django2.1.7(为了减少不必要的报错,安装了和大神的一个版本)
运行 runserver是按照提示安装各种包。
安装django_redis是,需要安装4.11.0以下的。
执行runserver,127.0.0.1:8000/页面正常打开。

但是进入后台管理页面 127.0.0.1:8000/admin 时,报错。
报错内容:
Invalid block tag on line 103: 'translate', expected 'endblock'. Did you forget to register or load this tag?
文件:
\ishare-master\simpleui\templates\admin\login.html, error at line 103

103 | <a href="{% url 'password_reset' %}"><i>{% translate 'Forgotten your password or username?' %}</i></a>

大神可否告知这咋弄?

@jeyrce
Copy link
Owner

jeyrce commented Oct 6, 2020

这个原因是 translate 标签没有注册到simpleui 的上下文模板中, 解决方法有两种:
(1)去simpleui的模板标签中注册translate标签,这需要你对模板标签有一定了解
(2)将translate修改为 trans 标签即可

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants