# -*- coding: utf-8 -*-
from __future__ import unicode_literals

from django.shortcuts import render
from rest_framework import viewsets
from rest_framework.permissions import IsAuthenticated,IsAdminUser

from .models import *

from .serializers import *

# Create your views here.
class ProductoLista(viewsets.ModelViewSet):
	serializer_class = CatalogoProductoSerializer
	permission_classes = (IsAdminUser,)

	def get_queryset(self):
		queryset = Producto.objects.all()
		return queryset

class InsumoLista(viewsets.ModelViewSet):
	serializer_class = InsumoSerializer
	permission_classes = (IsAdminUser,)

	def get_queryset(self):
		queryset = Insumo.objects.all()
		return queryset

class TipoInsumoLista(viewsets.ModelViewSet):
	serializer_class = TipoInsumoSerializer
	queryset = TipoInsumo.objects.all()
207e87b6c0c18bdcfd9ad34b0cf84d5d0b6c7ed6
<mask token>


class InsumoLista(viewsets.ModelViewSet):
    <mask token>
    <mask token>

    def get_queryset(self):
        queryset = Insumo.objects.all()
        return queryset


class TipoInsumoLista(viewsets.ModelViewSet):
    serializer_class = TipoInsumoSerializer
    queryset = TipoInsumo.objects.all()

<mask token>


class ProductoLista(viewsets.ModelViewSet):
    <mask token>
    <mask token>
    <mask token>


class InsumoLista(viewsets.ModelViewSet):
    serializer_class = InsumoSerializer
    permission_classes = IsAdminUser,

    def get_queryset(self):
        queryset = Insumo.objects.all()
        return queryset


class TipoInsumoLista(viewsets.ModelViewSet):
    serializer_class = TipoInsumoSerializer
    queryset = TipoInsumo.objects.all()

<mask token>


class ProductoLista(viewsets.ModelViewSet):
    <mask token>
    <mask token>

    def get_queryset(self):
        queryset = Producto.objects.all()
        return queryset


class InsumoLista(viewsets.ModelViewSet):
    serializer_class = InsumoSerializer
    permission_classes = IsAdminUser,

    def get_queryset(self):
        queryset = Insumo.objects.all()
        return queryset


class TipoInsumoLista(viewsets.ModelViewSet):
    serializer_class = TipoInsumoSerializer
    queryset = TipoInsumo.objects.all()

from __future__ import unicode_literals
from django.shortcuts import render
from rest_framework import viewsets
from rest_framework.permissions import IsAuthenticated, IsAdminUser
from .models import *
from .serializers import *


class ProductoLista(viewsets.ModelViewSet):
    serializer_class = CatalogoProductoSerializer
    permission_classes = IsAdminUser,

    def get_queryset(self):
        queryset = Producto.objects.all()
        return queryset


class InsumoLista(viewsets.ModelViewSet):
    serializer_class = InsumoSerializer
    permission_classes = IsAdminUser,

    def get_queryset(self):
        queryset = Insumo.objects.all()
        return queryset


class TipoInsumoLista(viewsets.ModelViewSet):
    serializer_class = TipoInsumoSerializer
    queryset = TipoInsumo.objects.all()

# -*- coding: utf-8 -*-
from __future__ import unicode_literals

from django.shortcuts import render
from rest_framework import viewsets
from rest_framework.permissions import IsAuthenticated,IsAdminUser

from .models import *

from .serializers import *

# Create your views here.
class ProductoLista(viewsets.ModelViewSet):
	serializer_class = CatalogoProductoSerializer
	permission_classes = (IsAdminUser,)

	def get_queryset(self):
		queryset = Producto.objects.all()
		return queryset

class InsumoLista(viewsets.ModelViewSet):
	serializer_class = InsumoSerializer
	permission_classes = (IsAdminUser,)

	def get_queryset(self):
		queryset = Insumo.objects.all()
		return queryset

class TipoInsumoLista(viewsets.ModelViewSet):
	serializer_class = TipoInsumoSerializer
	queryset = TipoInsumo.objects.all()