# comment_example **Repository Path**: huang-hongzhe/comment_example ## Basic Information - **Project Name**: comment_example - **Description**: 多级评论的一个demo - **Primary Language**: Python - **License**: Apache-2.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 1 - **Forks**: 0 - **Created**: 2024-02-07 - **Last Updated**: 2024-02-17 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # Comment项目说明 ## 简介 评论app ## 使用方法 ### 一、安装 将comment app放入项目根目录,或者其他Python路径 ### 二、配置 #### 1. 激活app 在settings.py中,将comment加入INSTALLED_APPS ```python ... INSTALLED_APPS = [ "comment", ... ] ``` #### 2. 其他配置 ##### COMMENT_OBJECT_MODEL_CLASS - 配置评论附加的模型路径,会以外键的形式动态给该模型加上评论。 - 默认值:article.models.Article ### 三、依赖库 ```shell pip install -r requirements.txt ``` ### 四、数据库迁移 ```shell python manage.py makemigrations python manage.py migrate ``` ### 五、其他 - 目前只支持给一个模型加入评论,且无法自定义其他外键属性