Authorizations: step 1

This commit is contained in:
Vincent Jacques
2012-03-01 17:45:31 +01:00
parent 3b523190a0
commit b53f96bafa
3 changed files with 41 additions and 5 deletions
+16
View File
@@ -3,6 +3,16 @@ import urllib
from GithubObject import *
Authorization = GithubObject(
"Authorization",
BaseUrl( lambda obj: "/authorizations/" + str( obj.id ) ),
InternalSimpleAttributes(
### @todo
),
Editable( [], [] ), ### @todo
Deletable(),
)
AuthenticatedUser = GithubObject(
"AuthenticatedUser",
BaseUrl( lambda obj: "/user" ),
@@ -20,6 +30,12 @@ AuthenticatedUser = GithubObject(
SeveralElementsAddable(),
SeveralElementsRemovable()
),
ExternalListOfObjects( "authorizations", "authorization", Authorization,
ListGetable( [], [] ),
ElementGetable( [ "id" ], [] ),
ElementCreatable( [], [] ), ### @todo
### url = "/authorizations", ### @todo
),
)
NamedUser = GithubObject(