Esempio n. 1
0
def save_profile_in_our_db(dict_profile_from_tpa):
    tpa = Tpa.objects.get(name=dict_profile_from_tpa['tpa'])
    u = ChatUser()
    u.user_id = dict_profile_from_tpa['user_id']
    u.name = dict_profile_from_tpa['name']
    u.birthday = dict_profile_from_tpa['birthday']
    u.country = dict_profile_from_tpa['country']
    u.city = dict_profile_from_tpa['city']
    u.culture = dict_profile_from_tpa['culture']
    u.profile_url = dict_profile_from_tpa['profile_url']
    u.image = dict_profile_from_tpa['image']
    u.gender = dict_profile_from_tpa['gender']
    u.tpa = tpa
    u.save()