alwary share doctor for every location after created by anyone
parent
92604cd73e
commit
fc4eb27a94
|
@ -203,6 +203,13 @@ class Staff(Model):
|
|||
|
||||
def _get_departments(self,context={}):
|
||||
res=get_model('select.company').get_select()
|
||||
type=context.get("type")
|
||||
if type=='doctor':
|
||||
user_id=get_active_user()
|
||||
set_active_user(1)
|
||||
dpts=get_model("clinic.department").search([])
|
||||
set_active_user(user_id)
|
||||
return dpts
|
||||
if res:
|
||||
if res.get("department_ids"):
|
||||
return res['department_ids']
|
||||
|
|
Loading…
Reference in New Issue