Re: [Dhis2-users] [Dhis2-devs] signing up for google earth engine for dhis

2016-08-07 Thread Lars Helge Øverland
I have updated the tutorial now.

Lars

On Sun, Aug 7, 2016 at 1:59 PM, Bjørn Sandvik  wrote:

> Hi Calle,
>
> Yes, you need to attach the service account to a project - we will update
> the documentation about this.
>
> If you already have a Google account, click on this link:
> https://console.developers.google.com/iam-admin/projects
>
> Click on "Create project" and name the project.
>
> When the project is created (it takes around 30 seconds), click on this
> link:
> https://console.developers.google.com/iam-admin/serviceaccounts/
> serviceaccounts-zero
>
> You should now be able to select the project you just created, and create
> your service account.
>
> Bjørn
>
>
> On Sun, Aug 7, 2016 at 1:19 PM, Calle Hedberg 
> wrote:
>
>> Lars,
>>
>> Your step-by-step description don't fit what I get for Step 3 onwards - I
>> see not "Create account' etc, just "Create project" and then it deviates
>> completely from there.
>>
>> Regards
>> calle
>>
>> On 6 August 2016 at 19:32, Lars Helge Øverland  wrote:
>>
>>> Hi all,
>>>
>>> in DHIS 2.24 we introduced GIS layers based on Google Earth Engine
>>> . This platform is still
>>> invitation-only so there are a few steps to go through in order to enable
>>> it. I have written a tutorial here which explains the steps:
>>>
>>> 
>>> https://www.dhis2.org/signing-up-for-google-earth-engine-for-dhis2
>>>
>>>
>>> If you are getting in trouble we are of course willing to help.
>>>
>>>
>>> best regards,
>>>
>>> Lars
>>>
>>>
>>>
>>>
>>>
>>> --
>>> Lars Helge Øverland
>>> Lead developer, DHIS 2
>>> University of Oslo
>>> Skype: larshelgeoverland
>>> l...@dhis2.org
>>> http://www.dhis2.org 
>>>
>>>
>>> ___
>>> Mailing list: https://launchpad.net/~dhis2-devs
>>> Post to : dhis2-d...@lists.launchpad.net
>>> Unsubscribe : https://launchpad.net/~dhis2-devs
>>> More help   : https://help.launchpad.net/ListHelp
>>>
>>>
>>
>>
>> --
>>
>> ***
>>
>> Calle Hedberg
>>
>> 46D Alma Road, 7700 Rosebank, SOUTH AFRICA
>>
>> Tel/fax (home): +27-21-685-6472
>>
>> Cell: +27-82-853-5352
>>
>> Iridium SatPhone: +8816-315-19119
>>
>> Email: calle.hedb...@gmail.com
>>
>> Skype: calle_hedberg
>>
>> ***
>>
>>
>> ___
>> Mailing list: https://launchpad.net/~dhis2-devs
>> Post to : dhis2-d...@lists.launchpad.net
>> Unsubscribe : https://launchpad.net/~dhis2-devs
>> More help   : https://help.launchpad.net/ListHelp
>>
>>
>
>
> --
> Bjørn Sandvik
> GIS developer, DHIS 2
> University of Oslo
> www.dhis2.org
>



-- 
Lars Helge Øverland
Lead developer, DHIS 2
University of Oslo
Skype: larshelgeoverland
l...@dhis2.org
http://www.dhis2.org 
___
Mailing list: https://launchpad.net/~dhis2-users
Post to : dhis2-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-users
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-users] [Dhis2-devs] DHIS2 based App http.post and put (403 error)

2016-08-07 Thread Mark Polak
Hey Michael,

Are you developing the app using CORS? If you're doing CORS requests you
will need to include the header yes. If your app is running from within the
dhis2 context (as in you installed it) you won't need to do so.

Generally when the Authorization header is not send the API would 302 you
to the login page, so perhaps something else is the matter. When POSTing to
the dataStore api you need to POST to /api/dataStore//
If you could share a piece of the code where you do the request, perhaps i
can give you some more detailed feedback. :)


On Sun, Aug 7, 2016 at 11:18 AM, Michael Mwebaze 
wrote:

> Hi,
>
> I am developing a DHIS2 based app using AngularJS. The $http.get is
> successful but I am getting 403 (Forbidden) with the POST and PUT when I
> try to add a new item to the dataStore. Am I supposed to include
> Authorization: Basic base64encode(username:password) in the header as
> well? Is there an example I can follow for DHIS2 based apps?
>
> Thanks,
>
> Michael
>
> ___
> Mailing list: https://launchpad.net/~dhis2-devs
> Post to : dhis2-d...@lists.launchpad.net
> Unsubscribe : https://launchpad.net/~dhis2-devs
> More help   : https://help.launchpad.net/ListHelp
>
>


-- 
Regards,


Mark Polak
Software developer, DHIS 2
University of Oslo
http://www.dhis2.org 
m...@dhis2.org
___
Mailing list: https://launchpad.net/~dhis2-users
Post to : dhis2-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-users
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-users] [Dhis2-devs] DHIS2 based App http.post and put (403 error)

2016-08-07 Thread Michael Mwebaze
Hi Mark,

The app I am developing is running with-in a DHIS2 context. Below is the
error from the console. I have also included the code fragment causing the
error.

[image: Inline images 1]

var data = {
"dashlets" : dashlets
}

$http.put('/api/dataStore/rbcdashboard/HIV', data, {
headers : {
'Content-Type' : 'application/json'
}
})
.success(function (data, status, headers) {
console.debug(data)
});
Thanks,

Michael

On 7 August 2016 at 10:50, Mark Polak  wrote:

> Hey Michael,
>
> Are you developing the app using CORS? If you're doing CORS requests you
> will need to include the header yes. If your app is running from within the
> dhis2 context (as in you installed it) you won't need to do so.
>
> Generally when the Authorization header is not send the API would 302 you
> to the login page, so perhaps something else is the matter. When POSTing to
> the dataStore api you need to POST to /api/dataStore//
> If you could share a piece of the code where you do the request, perhaps i
> can give you some more detailed feedback. :)
>
>
> On Sun, Aug 7, 2016 at 11:18 AM, Michael Mwebaze <
> michael.mweb...@gmail.com> wrote:
>
>> Hi,
>>
>> I am developing a DHIS2 based app using AngularJS. The $http.get is
>> successful but I am getting 403 (Forbidden) with the POST and PUT when I
>> try to add a new item to the dataStore. Am I supposed to include
>> Authorization: Basic base64encode(username:password) in the header as
>> well? Is there an example I can follow for DHIS2 based apps?
>>
>> Thanks,
>>
>> Michael
>>
>> ___
>> Mailing list: https://launchpad.net/~dhis2-devs
>> Post to : dhis2-d...@lists.launchpad.net
>> Unsubscribe : https://launchpad.net/~dhis2-devs
>> More help   : https://help.launchpad.net/ListHelp
>>
>>
>
>
> --
> Regards,
>
>
> Mark Polak
> Software developer, DHIS 2
> University of Oslo
> http://www.dhis2.org 
> m...@dhis2.org
>
___
Mailing list: https://launchpad.net/~dhis2-users
Post to : dhis2-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-users
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-users] [Dhis2-devs] signing up for google earth engine for dhis

2016-08-07 Thread Bjørn Sandvik
Hi Calle,

Yes, you need to attach the service account to a project - we will update
the documentation about this.

If you already have a Google account, click on this link:
https://console.developers.google.com/iam-admin/projects

Click on "Create project" and name the project.

When the project is created (it takes around 30 seconds), click on this
link:
https://console.developers.google.com/iam-admin/serviceaccounts/serviceaccounts-zero

You should now be able to select the project you just created, and create
your service account.

Bjørn


On Sun, Aug 7, 2016 at 1:19 PM, Calle Hedberg 
wrote:

> Lars,
>
> Your step-by-step description don't fit what I get for Step 3 onwards - I
> see not "Create account' etc, just "Create project" and then it deviates
> completely from there.
>
> Regards
> calle
>
> On 6 August 2016 at 19:32, Lars Helge Øverland  wrote:
>
>> Hi all,
>>
>> in DHIS 2.24 we introduced GIS layers based on Google Earth Engine
>> . This platform is still
>> invitation-only so there are a few steps to go through in order to enable
>> it. I have written a tutorial here which explains the steps:
>>
>> 
>> https://www.dhis2.org/signing-up-for-google-earth-engine-for-dhis2
>>
>>
>> If you are getting in trouble we are of course willing to help.
>>
>>
>> best regards,
>>
>> Lars
>>
>>
>>
>>
>>
>> --
>> Lars Helge Øverland
>> Lead developer, DHIS 2
>> University of Oslo
>> Skype: larshelgeoverland
>> l...@dhis2.org
>> http://www.dhis2.org 
>>
>>
>> ___
>> Mailing list: https://launchpad.net/~dhis2-devs
>> Post to : dhis2-d...@lists.launchpad.net
>> Unsubscribe : https://launchpad.net/~dhis2-devs
>> More help   : https://help.launchpad.net/ListHelp
>>
>>
>
>
> --
>
> ***
>
> Calle Hedberg
>
> 46D Alma Road, 7700 Rosebank, SOUTH AFRICA
>
> Tel/fax (home): +27-21-685-6472
>
> Cell: +27-82-853-5352
>
> Iridium SatPhone: +8816-315-19119
>
> Email: calle.hedb...@gmail.com
>
> Skype: calle_hedberg
>
> ***
>
>
> ___
> Mailing list: https://launchpad.net/~dhis2-devs
> Post to : dhis2-d...@lists.launchpad.net
> Unsubscribe : https://launchpad.net/~dhis2-devs
> More help   : https://help.launchpad.net/ListHelp
>
>


-- 
Bjørn Sandvik
GIS developer, DHIS 2
University of Oslo
www.dhis2.org
___
Mailing list: https://launchpad.net/~dhis2-users
Post to : dhis2-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-users
More help   : https://help.launchpad.net/ListHelp


Re: [Dhis2-users] [Dhis2-devs] signing up for google earth engine for dhis

2016-08-07 Thread Calle Hedberg
Lars,

Your step-by-step description don't fit what I get for Step 3 onwards - I
see not "Create account' etc, just "Create project" and then it deviates
completely from there.

Regards
calle

On 6 August 2016 at 19:32, Lars Helge Øverland  wrote:

> Hi all,
>
> in DHIS 2.24 we introduced GIS layers based on Google Earth Engine
> . This platform is still invitation-only
> so there are a few steps to go through in order to enable it. I have
> written a tutorial here which explains the steps:
>
> 
> https://www.dhis2.org/signing-up-for-google-earth-engine-for-dhis2
>
>
> If you are getting in trouble we are of course willing to help.
>
>
> best regards,
>
> Lars
>
>
>
>
>
> --
> Lars Helge Øverland
> Lead developer, DHIS 2
> University of Oslo
> Skype: larshelgeoverland
> l...@dhis2.org
> http://www.dhis2.org 
>
>
> ___
> Mailing list: https://launchpad.net/~dhis2-devs
> Post to : dhis2-d...@lists.launchpad.net
> Unsubscribe : https://launchpad.net/~dhis2-devs
> More help   : https://help.launchpad.net/ListHelp
>
>


-- 

***

Calle Hedberg

46D Alma Road, 7700 Rosebank, SOUTH AFRICA

Tel/fax (home): +27-21-685-6472

Cell: +27-82-853-5352

Iridium SatPhone: +8816-315-19119

Email: calle.hedb...@gmail.com

Skype: calle_hedberg

***
___
Mailing list: https://launchpad.net/~dhis2-users
Post to : dhis2-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-users
More help   : https://help.launchpad.net/ListHelp


[Dhis2-users] DHIS2 based App http.post and put (403 error)

2016-08-07 Thread Michael Mwebaze
Hi,

I am developing a DHIS2 based app using AngularJS. The $http.get is
successful but I am getting 403 (Forbidden) with the POST and PUT when I
try to add a new item to the dataStore. Am I supposed to include
Authorization: Basic base64encode(username:password) in the header as well?
Is there an example I can follow for DHIS2 based apps?

Thanks,

Michael
___
Mailing list: https://launchpad.net/~dhis2-users
Post to : dhis2-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-users
More help   : https://help.launchpad.net/ListHelp