diff --git a/dashboard/templates/dashboard/index.html b/dashboard/templates/dashboard/index.html index 71f2b56..7b6059d 100644 --- a/dashboard/templates/dashboard/index.html +++ b/dashboard/templates/dashboard/index.html @@ -580,12 +580,12 @@ {% endblock %} diff --git a/management/templates/management/news-management-create.html b/management/templates/management/news-management-create.html index bb617ab..912d5e6 100644 --- a/management/templates/management/news-management-create.html +++ b/management/templates/management/news-management-create.html @@ -38,7 +38,7 @@ -
{% csrf_token %} + {% csrf_token %}
@@ -55,16 +55,21 @@
-
+
-
+
+
+ + +
diff --git a/management/views.py b/management/views.py index d83ff05..b20934c 100644 --- a/management/views.py +++ b/management/views.py @@ -1206,11 +1206,24 @@ def news_management_create(request): author = request.POST.get('author') date = request.POST.get('date') content = request.POST.get('content') + source = request.POST.get('source') + t = None + if type == '政策依据': + t = '0' + elif type == "基层动态": + t = '1' + elif type == '外省动态': + t = '2' + elif type == '监测通报': + t = '3' + elif type == '舆情热点': + t = '4' + print(str(title), str(content)) - news = News(type=type, title=title, author=author, date=date, content=content) + news = News(type=t, title=title, author=author, date=date, content=content,source=source) news.save() messages.success(request, '添加成功!!!') - return HttpResponseRedirect('/add/news/') + return HttpResponseRedirect('/management/news/management/create/') type = News.NEWMEDIA_NEWS_CHOICES results = [] for i in type: diff --git a/static/media/groupimage/danweimoren.jpg b/static/media/groupimage/danweimoren.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren.jpg differ diff --git a/static/media/groupimage/danweimoren_8dYatvl.jpg b/static/media/groupimage/danweimoren_8dYatvl.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren_8dYatvl.jpg differ diff --git a/static/media/groupimage/danweimoren_P7MLAnW.jpg b/static/media/groupimage/danweimoren_P7MLAnW.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren_P7MLAnW.jpg differ diff --git a/static/media/groupimage/danweimoren_QedM64t.jpg b/static/media/groupimage/danweimoren_QedM64t.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren_QedM64t.jpg differ diff --git a/static/media/groupimage/danweimoren_SfUqEFP.jpg b/static/media/groupimage/danweimoren_SfUqEFP.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren_SfUqEFP.jpg differ diff --git a/static/media/groupimage/danweimoren_TpnZLV5.jpg b/static/media/groupimage/danweimoren_TpnZLV5.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren_TpnZLV5.jpg differ diff --git a/static/media/groupimage/danweimoren_X0Vanfy.jpg b/static/media/groupimage/danweimoren_X0Vanfy.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren_X0Vanfy.jpg differ diff --git a/static/media/groupimage/danweimoren_bRjShS6.jpg b/static/media/groupimage/danweimoren_bRjShS6.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren_bRjShS6.jpg differ diff --git a/static/media/groupimage/danweimoren_irQkS6L.jpg b/static/media/groupimage/danweimoren_irQkS6L.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren_irQkS6L.jpg differ diff --git a/static/media/groupimage/danweimoren_ivnamGN.jpg b/static/media/groupimage/danweimoren_ivnamGN.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren_ivnamGN.jpg differ diff --git a/static/media/groupimage/danweimoren_kJUCESs.jpg b/static/media/groupimage/danweimoren_kJUCESs.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren_kJUCESs.jpg differ diff --git a/static/media/groupimage/danweimoren_oA97Vmo.jpg b/static/media/groupimage/danweimoren_oA97Vmo.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren_oA97Vmo.jpg differ diff --git a/static/media/groupimage/danweimoren_pkfNZEJ.jpg b/static/media/groupimage/danweimoren_pkfNZEJ.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren_pkfNZEJ.jpg differ diff --git a/static/media/groupimage/danweimoren_sm3Kaes.jpg b/static/media/groupimage/danweimoren_sm3Kaes.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren_sm3Kaes.jpg differ diff --git a/static/media/groupimage/danweimoren_zOw1Xdo.jpg b/static/media/groupimage/danweimoren_zOw1Xdo.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren_zOw1Xdo.jpg differ diff --git a/static/media/groupimage/danweimoren_zYRqsNB.jpg b/static/media/groupimage/danweimoren_zYRqsNB.jpg new file mode 100644 index 0000000..f35e8ff Binary files /dev/null and b/static/media/groupimage/danweimoren_zYRqsNB.jpg differ