trocotronic / edistribucion

API para e-distribución (Endesa distribución)
GNU General Public License v3.0
25 stars 29 forks source link

New funtion to get data between two dates. #28

Closed dmachadol closed 10 months ago

dmachadol commented 10 months ago

please add to EdistribucionAPI.py

def  get_meas_dates(self, cont, start, end):
    action = EdistribucionMessageAction(
        965,
        "WP_Measure_v3_CTRL/ACTION$getChartPointsByRange",
        "WP_Measure_Detail_Filter_Advanced_v3",
        {"contId":""+cont['Id']+"","type":"4","startDate":""+start+"","endDate":""+end+""}
    )
    r = self.__run_action_command(action)
    if 'data' in r.keys():
        if 'lstData' in r['data'].keys():
            return r['data']['lstData']
    return []
trocotronic commented 10 months ago

Can you send a PR?

dmachadol commented 10 months ago

I'm sorry, that's a PR? I'm not used to using github

@.***>

@.> @.> @.***>

Daniel Machado Lopez @.***

@.>@. @.***>

C/ Oviedo, 46 - 17005 Girona (Spain) 902 733 822 -  @.***>www.aerisnavigo.com http://www.aerisnavigo.com/

El 31 oct 2023, a les 14:13, Trocotronic @.***> va escriure:

Can you send a PR?

— Reply to this email directly, view it on GitHub https://github.com/trocotronic/edistribucion/issues/28#issuecomment-1787193870, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAWV2YORBMNUPYRMNFDFIM3YCD2ODAVCNFSM6AAAAAA6XVERXSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTOOBXGE4TGOBXGA. You are receiving this because you authored the thread.

[ { @.": "http://schema.org", @.": "EmailMessage", "potentialAction": { @.": "ViewAction", "target": "https://github.com/trocotronic/edistribucion/issues/28#issuecomment-1787193870", "url": "https://github.com/trocotronic/edistribucion/issues/28#issuecomment-1787193870", "name": "View Issue" }, "description": "View this Issue on GitHub", "publisher": { @.": "Organization", "name": "GitHub", "url": "https://github.com" } } ]

trocotronic commented 10 months ago

PR=Pull Request. You first fork this repo onto your account, create a new branch, push your changes to that branch and Github will let you to send a PR to the original repo.

dmachadol commented 10 months ago

ok, I not sure if I do a gitclone or download directly. I try to do a PR in new request.

--

@.***>

@.> @.> @.***>

Daniel Machado Lopez @.***

@.>@. @.***>

C/ Oviedo, 46 - 17005 Girona (Spain) 902 733 822 -  @.***>www.aerisnavigo.com http://www.aerisnavigo.com/

El 31 oct 2023, a les 14:19, Trocotronic @.***> va escriure:

PR=Pull Request. You first fork this repo onto your account, create a new branch, push your changes to that branch and Github will let you to send a PR to the original repo.

— Reply to this email directly, view it on GitHub https://github.com/trocotronic/edistribucion/issues/28#issuecomment-1787204259, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAWV2YPXWFA57BFL2JD763LYCD3FTAVCNFSM6AAAAAA6XVERXSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTOOBXGIYDIMRVHE. You are receiving this because you authored the thread.

[ { @.": "http://schema.org", @.": "EmailMessage", "potentialAction": { @.": "ViewAction", "target": "https://github.com/trocotronic/edistribucion/issues/28#issuecomment-1787204259", "url": "https://github.com/trocotronic/edistribucion/issues/28#issuecomment-1787204259", "name": "View Issue" }, "description": "View this Issue on GitHub", "publisher": { @.": "Organization", "name": "GitHub", "url": "https://github.com" } } ]

dmachadol commented 10 months ago

PR=Pull Request. You first fork this repo onto your account, create a new branch, push your changes to that branch and Github will let you to send a PR to the original repo.

Done, I close this issue, there are included into PR. Thanks.