V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
Ritter
V2EX  ›  Python

请问各位大牛 用 django 模板系统怎样可以做出这样的评论系统

  •  
  •   Ritter · 2019-01-02 17:54:26 +08:00 · 1414 次点击
    这是一个创建于 1911 天前的主题,其中的信息可能已经有所发展或是发生改变。

    评论 主要是层级关系 感觉用模板语言写不出来 还是我水平不够 望指教 谢谢

    8 条回复    2019-01-03 22:06:50 +08:00
    ntuwang
        1
    ntuwang  
       2019-01-02 19:33:30 +08:00
    写 js 吧
    Ritter
        2
    Ritter  
    OP
       2019-01-03 09:06:36 +08:00
    @ntuwang 想知道层次关系是怎样的
    huisezhiyin
        3
    huisezhiyin  
       2019-01-03 10:24:19 +08:00
    不建议用 django 的模版系统写复杂的前端 第一前后端分离是趋势 第二是这个模版系统也很鸡肋 干脆就做成前后端分离
    xpresslink
        4
    xpresslink  
       2019-01-03 10:51:51 +08:00
    可以,关键是体验不好,每次都要在后端渲染网页返回给前端,页面刷新才能看到。

    建议你还是学个前端框架比较容易的 vue 之类的。哪怕是最基础的 bootstrap 也可以实现你要的这个样式,最起码把 jquery 和 ajax 要搞明白了,不然你根本做不了 web 开发。
    Ritter
        5
    Ritter  
    OP
       2019-01-03 12:21:55 +08:00
    @huisezhiyin T T 准备学 vue 了
    Ritter
        6
    Ritter  
    OP
       2019-01-03 12:24:32 +08:00
    @xpresslink bootstrap jQuery ajax 都学了 只是没有思路 不知道怎么下手
    xpresslink
        7
    xpresslink  
       2019-01-03 14:33:42 +08:00
    @Ritter 推荐你看一本书《 Django By Example 》
    ntuwang
        8
    ntuwang  
       2019-01-03 22:06:50 +08:00
    @Ritter Django 开发的基本不是大项目,会点 bootstrap + jquery 基本能从前干到后
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   5410 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 28ms · UTC 09:10 · PVG 17:10 · LAX 02:10 · JFK 05:10
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.