|
@@ -1,3 +1,18 @@
|
|
|
from django.shortcuts import render
|
|
|
|
|
|
-# Create your views here.
|
|
|
+from .models import Service, Cost, Good
|
|
|
+
|
|
|
+
|
|
|
+def list_services(request):
|
|
|
+ context = {
|
|
|
+ 'services': Service.objects.all(),
|
|
|
+ }
|
|
|
+ return render(request, 'costs/services_list.html', context)
|
|
|
+
|
|
|
+
|
|
|
+def list_resources(request):
|
|
|
+ context = {
|
|
|
+ 'goods': Good.objects.all(),
|
|
|
+ 'costs': Cost.objects.all(),
|
|
|
+ }
|
|
|
+ return render(request, 'costs/resources_list.html', context)
|