내 프로젝트에 coleifer/Django-Relationships 패키지를 사용하고 있습니다. 나는 그 일을하는 데 거친 시간을 보냈습니다.장고 관계 - TemplateSyntaxerror
사용자 프로필 템플릿에 'relationship_add.html'템플릿이 포함되어있어 사용자가 다른 사용자를 찾고 서로가 따르지 않을 경우 사용자가 팔로우 버튼을 클릭하기가 쉽습니다. 서로 따르십시오.
사용자의 템플릿을 포함하면 프로필 템플릿 : 나는/정보/picomon에서 TemplateSyntaxError을 얻고있다
{% include 'relationships/relationship_add.html' %}
/아래
RelationshipStatus not found
Request Method: GET
Request URL: http://127.0.0.1:8000/profiles/picomon/
Django Version: 1.3.1
Exception Type: TemplateSyntaxError
Exception Value:
RelationshipStatus not found
Exception Location: build\bdist.win32\egg\relationships\templatetags\relationship_tags.py in render, line 32
Python Executable: C:\Python27\python.exe
Python Version: 2.7.2
Template error
In template c:\python27\scripts\myweb\templates\relationships\relationship_add.html, error at line 9
관계/relationship_add.html의 코드입니다
{% load relationship_tags %}
{% if request.user != profile.user %}
{# decide whether or not the current user is following this user #}
{% if_relationship request.user profile.user "following" %}
{# they are following them, so show a "remove" url #}
<a href="{{ profile.user|remove_relationship_url:"following" }}">Unfollow</a>
{% else %}
{# they are not following them, so show a link to start following #}
<a href="{{ profile.user|add_relationship_url:"following" }}">Follow</a>
{% endif_relationship %}
{% else %}
<p>This is you!</p>
{% endif %}
이 작업을 수행하기 위해 어떤 조정을해야합니까? 친절하게 제발 나를 통해 넣어.
나는 모든 것을 시도했다. 나는 그것을 꼬집어도 아직 성공하지 못했습니다! 사용자가 서로 따라 가게 만드는 다른 패키지는 무엇입니까? 정말 고마워! – picomon