from rest_framework import serializers
from .models import Panel, OneHourElectricity

class PanelSerializer(serializers.ModelSerializer):
    class Meta:
        model = Panel
        fields = ('id', 'brand', 'serial', 'latitude', 'longitude')

class OneHourElectricitySerializer(serializers.ModelSerializer):
    class Meta:
        panel = serializers.PrimaryKeyRelatedField(queryset=Panel.objects.all())
        model = OneHourElectricity
        fields = ('id', 'panel', 'kilo_watt','date_time')
1c2e70115e67f3298bb045490a4624952fd2ea64
<mask token>

<mask token>


class OneHourElectricitySerializer(serializers.ModelSerializer):


    class Meta:
        panel = serializers.PrimaryKeyRelatedField(queryset=Panel.objects.all()
            )
        model = OneHourElectricity
        fields = 'id', 'panel', 'kilo_watt', 'date_time'

<mask token>


class PanelSerializer(serializers.ModelSerializer):


    class Meta:
        model = Panel
        fields = 'id', 'brand', 'serial', 'latitude', 'longitude'


class OneHourElectricitySerializer(serializers.ModelSerializer):


    class Meta:
        panel = serializers.PrimaryKeyRelatedField(queryset=Panel.objects.all()
            )
        model = OneHourElectricity
        fields = 'id', 'panel', 'kilo_watt', 'date_time'

from rest_framework import serializers
from .models import Panel, OneHourElectricity


class PanelSerializer(serializers.ModelSerializer):


    class Meta:
        model = Panel
        fields = 'id', 'brand', 'serial', 'latitude', 'longitude'


class OneHourElectricitySerializer(serializers.ModelSerializer):


    class Meta:
        panel = serializers.PrimaryKeyRelatedField(queryset=Panel.objects.all()
            )
        model = OneHourElectricity
        fields = 'id', 'panel', 'kilo_watt', 'date_time'

from rest_framework import serializers
from .models import Panel, OneHourElectricity

class PanelSerializer(serializers.ModelSerializer):
    class Meta:
        model = Panel
        fields = ('id', 'brand', 'serial', 'latitude', 'longitude')

class OneHourElectricitySerializer(serializers.ModelSerializer):
    class Meta:
        panel = serializers.PrimaryKeyRelatedField(queryset=Panel.objects.all())
        model = OneHourElectricity
        fields = ('id', 'panel', 'kilo_watt','date_time')