[IMP]:Change in get_data
bzr revid: dbr@tinyerp.com-20110608133139-g5n8uy1z58nda07c
This commit is contained in:
parent
c998048650
commit
ff45483f72
|
@ -42,7 +42,8 @@ class google_import(import_framework):
|
|||
gd_client = False
|
||||
calendars = False
|
||||
DATETIME_FORMAT = "%Y-%m-%d %H:%M:%S"
|
||||
TABLE_CONTACT = 'contact'
|
||||
TABLE_CONTACT = 'Contact'
|
||||
TABLE_ADDRESS ='Address'
|
||||
TABLE_EVENT = 'Events'
|
||||
|
||||
def initialize(self):
|
||||
|
@ -63,10 +64,14 @@ class google_import(import_framework):
|
|||
}
|
||||
|
||||
def get_data(self, table):
|
||||
val = {
|
||||
self.TABLE_EVENT: self.get_events(),
|
||||
self.TABLE_CONTACT: self.get_contact(),
|
||||
}
|
||||
if table == "Contact" or table == "Address":
|
||||
val = {
|
||||
self.TABLE_CONTACT: self.get_contact(),
|
||||
}
|
||||
elif table == "Events":
|
||||
val = {
|
||||
self.TABLE_EVENT: self.get_events(),
|
||||
}
|
||||
return val.get(table)
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue