Skip to content

Commit a4ba6d7

Browse files
committed
change video_cast to videocast
1 parent e52a954 commit a4ba6d7

File tree

7 files changed

+27
-27
lines changed

7 files changed

+27
-27
lines changed

content/context_processors.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
def show_system_content(request):
66
return {
77
'blog_categories': models.BlogCategory.objects.all(),
8-
'video_cast_categories': models.VideocastCategory.objects.all(),
8+
'videocast_categories': models.VideocastCategory.objects.all(),
99
'podcast_categories': models.PodcastCategory.objects.all(),
1010
'podcasts': models.Podcast.objects.order_by('-pk').filter(publish=True)[:2],
1111
'config': config

content/urls.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@
1010
path('create/blog_category/', views.BlogCategoryCreateView.as_view(), name='blog_category_create'),
1111
path('blog/<int:pk>/', views.BlogArchiveByCategoryPK.as_view(), name='blog_archive_by_category_pk'),
1212
path('blog/<str:slug>/', views.BlogSingle.as_view(), name='blog_single'),
13-
path('create/video_cast_category/', views.VideocastCategoryCreateView.as_view(), name='video_cast_category_create'),
14-
path('video_cast/', views.Videocast.as_view(), name='video_cast'),
15-
path('create/video_cast/', views.VideocastCreateView.as_view(), name='video_cast_create'),
16-
path('video_cast/<int:pk>/', views.VideocastArchiveByCategoryPK.as_view(), name='video_cast_archive_by_category_pk'),
17-
path('video_cast/<str:slug>/', views.VideocastSingle.as_view(), name='video_cast_single'),
13+
path('create/videocast_category/', views.VideocastCategoryCreateView.as_view(), name='videocast_category_create'),
14+
path('videocast/', views.Videocast.as_view(), name='videocast'),
15+
path('create/videocast/', views.VideocastCreateView.as_view(), name='videocast_create'),
16+
path('videocast/<int:pk>/', views.VideocastArchiveByCategoryPK.as_view(), name='videocast_archive_by_category_pk'),
17+
path('videocast/<str:slug>/', views.VideocastSingle.as_view(), name='videocast_single'),
1818
path('create/podcast_category/', views.PodcastCategoryCreateView.as_view(), name='podcast_category_create'),
1919
path('podcast/', views.Podcast.as_view(), name='podcast'),
2020
path('create/podcast/', views.PodcastCreateView.as_view(), name='podcast_create'),

content/views.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ def get(self, request, *args, **kwargs):
1717
'last_blog': models.Blog.objects.order_by('-pk').filter(publish=True)[:1],
1818
'skills': models.Skill.objects.all(),
1919
'blogs': models.Blog.objects.order_by('-pk').filter(publish=True)[1:5],
20-
'video_casts': models.Videocast.objects.order_by('-pk').filter(publish=True)[:4]
20+
'videocasts': models.Videocast.objects.order_by('-pk').filter(publish=True)[:4]
2121
}
2222
return render(request, self.template_name, context)
2323

@@ -91,12 +91,12 @@ class VideocastCategoryCreateView(LoginRequiredMixin, SuccessMessageMixin, gener
9191
success_message = 'Video cast category was created successfully'
9292

9393
def get_success_url(self):
94-
return reverse('content:video_cast_category_create')
94+
return reverse('content:videocast_category_create')
9595

9696

9797
class Videocast(generic.ListView):
9898
model = models.Videocast
99-
template_name = 'video_cast_archive.html'
99+
template_name = 'videocast_archive.html'
100100

101101

102102
class VideocastCreateView(LoginRequiredMixin, SuccessMessageMixin, generic.CreateView):
@@ -105,12 +105,12 @@ class VideocastCreateView(LoginRequiredMixin, SuccessMessageMixin, generic.Creat
105105
success_message = 'Video cast was created successfully'
106106

107107
def get_success_url(self):
108-
return reverse('content:video_cast_create')
108+
return reverse('content:videocast_create')
109109

110110

111111
class VideocastArchiveByCategoryPK(generic.ListView):
112112
model = models.Videocast
113-
template_name = 'video_cast_archive.html'
113+
template_name = 'videocast_archive.html'
114114

115115
def get_queryset(self):
116116
return self.model.objects.filter(category=self.kwargs['pk'])

templates/base.html

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -94,12 +94,12 @@ <h2>Menu</h2>
9494
{% endfor %}
9595
</ul>
9696
</li>
97-
<li><a href="{% url 'content:video_cast' %}">{% translate 'Video Cast' %}</a></li>
97+
<li><a href="{% url 'content:videocast' %}">{% translate 'Videocast' %}</a></li>
9898
<li>
99-
<span class="opener">{% translate 'Video Cast Categories' %}</span>
99+
<span class="opener">{% translate 'Videocast Categories' %}</span>
100100
<ul>
101-
{% for video_cast_category in video_cast_categories %}
102-
<li><a href="{% url 'content:video_cast_archive_by_category_pk' video_cast_category.pk %}">{{ video_cast_category.title }}</a></li>
101+
{% for videocast_category in videocast_categories %}
102+
<li><a href="{% url 'content:videocast_archive_by_category_pk' videocast_category.pk %}">{{ videocast_category.title }}</a></li>
103103
{% endfor %}
104104
</ul>
105105
</li>
@@ -122,7 +122,7 @@ <h2>Menu</h2>
122122
<span class="opener">{% translate 'Create New Objects' %}</span>
123123
<ul>
124124
<li><a href="{% url 'content:blog_create' %}">{% translate 'New Blog' %}</a></li>
125-
<li><a href="{% url 'content:video_cast_create' %}">{% translate 'New Video Cast' %}</a></li>
125+
<li><a href="{% url 'content:videocast_create' %}">{% translate 'New Videocast' %}</a></li>
126126
<li><a href="{% url 'content:podcast_create' %}">{% translate 'New Podcast' %}</a></li>
127127
<li><a href="{% url 'content:skill_create' %}">{% translate 'New Skill' %}</a></li>
128128
</ul>
@@ -131,7 +131,7 @@ <h2>Menu</h2>
131131
<span class="opener">{% translate 'Create Category Object' %}</span>
132132
<ul>
133133
<li><a href="{% url 'content:blog_category_create' %}">{% translate 'New Blog Category' %}</a></li>
134-
<li><a href="{% url 'content:video_cast_category_create' %}">{% translate 'New Video Cast Category' %}</a></li>
134+
<li><a href="{% url 'content:videocast_category_create' %}">{% translate 'New Video Cast Category' %}</a></li>
135135
<li><a href="{% url 'content:podcast_category_create' %}">{% translate 'New Podcast Category' %}</a></li>
136136
</ul>
137137
</li>

templates/index.html

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -74,16 +74,16 @@ <h3>{{ blog_post.title }}</h3>
7474
<h2>{% translate 'The latest Video Casts' %}</h2>
7575
</header>
7676
<div class="posts">
77-
{% for video_cast in video_casts %}
77+
{% for videocast in videocasts %}
7878
<article>
79-
<a href="{% url 'content:video_cast_single' video_cast.slug %}" class="image" title="{{ video_cast.title }}">
80-
<img src="{{ video_cast.thumbnail.url }}" alt="{{ video_cast.title }}"/>
79+
<a href="{% url 'content:videocast_single' videocast.slug %}" class="image" title="{{ videocast.title }}">
80+
<img src="{{ videocast.thumbnail.url }}" alt="{{ videocast.title }}"/>
8181
</a>
82-
<h3>{{ video_cast.title }}</h3>
83-
<p>{{ video_cast.content | safe | truncatewords_html:30 }}</p>
82+
<h3>{{ videocast.title }}</h3>
83+
<p>{{ videocast.content | safe | truncatewords_html:30 }}</p>
8484
<ul class="actions">
8585
<li>
86-
<a href="{% url 'content:video_cast_single' video_cast.slug %}" class="button" title="{{ video_cast.title }}">{% translate 'More' %}</a>
86+
<a href="{% url 'content:videocast_single' videocast.slug %}" class="button" title="{{ videocast.title }}">{% translate 'More' %}</a>
8787
</li>
8888
</ul>
8989
</article>

templates/search.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ <h3>{{ blog.title }}</h3>
1818

1919
{% for videocast in videocasts %}
2020
<article>
21-
<a href="{% url 'content:video_cast_single' videocast.slug %}" title="{{ videocast.title }}">
21+
<a href="{% url 'content:videocast_single' videocast.slug %}" title="{{ videocast.title }}">
2222
<h3>{{ videocast.title }}</h3>
2323
</a>
2424
<p>{{ videocast.content | safe | truncatewords_html:10 }}</p>

templates/video_cast_archive.html renamed to templates/videocast_archive.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,20 +6,20 @@
66
<section id="archive">
77
<header class="major">
88
<h2>
9-
{% translate 'Video Cast Archive' %}
9+
{% translate 'Videocast Archive' %}
1010
</h2>
1111
</header>
1212
<div class="posts">
1313
{% for object in object_list %}
1414
<article>
15-
<a href="{% url 'content:video_cast_single' object.slug %}" class="image" title="{{ object.title }}">
15+
<a href="{% url 'content:videocast_single' object.slug %}" class="image" title="{{ object.title }}">
1616
<img src="{{ object.thumbnail.url }}" alt="{{ object.title }}"/>
1717
</a>
1818
<h3>{{ object.title }}</h3>
1919
<p>{{ object.content | safe | truncatewords_html:30 }}</p>
2020
<ul class="actions">
2121
<li>
22-
<a href="{% url 'content:video_cast_single' object.slug %}" class="button" title="{{ object.title }}">
22+
<a href="{% url 'content:videocast_single' object.slug %}" class="button" title="{{ object.title }}">
2323
{% translate 'More' %}
2424
</a>
2525
</li>

0 commit comments

Comments
 (0)