conv_bal
chayut.s 2014-10-01 15:58:12 +07:00
commit 005e8be69b
14 changed files with 54 additions and 15 deletions

View File

@ -0,0 +1,6 @@
<action>
<field name="string">Deparments</field>
<field name="view_cls">multi_view</field>
<field name="model">clinic.department</field>
<field name="menu">clinic_menu</field>
</action>

View File

@ -1,5 +1,5 @@
<action>
<field name="string">Doctor</field>
<field name="string">Doctors</field>
<field name="view_cls">multi_view</field>
<field name="model">clinic.doctor</field>
<field name="tabs">[["All",[]],["Draft",[["state","=","draft"]]],["Active",[["state","=","active"]]],["Deactive",[["state","=","deactive"]]]]</field>

View File

@ -1,5 +1,5 @@
<action>
<field name="string">Nurse</field>
<field name="string">Nurses</field>
<field name="view_cls">multi_view</field>
<field name="model">clinic.nurse</field>
<field name="tabs">[["All",[]],["Draft",[["state","=","draft"]]],["Active",[["state","=","active"]]],["Deactive",[["state","=","deactive"]]]]</field>

View File

@ -1,5 +1,5 @@
<action>
<field name="string">Patient</field>
<field name="string">Patients</field>
<field name="view_cls">multi_view</field>
<field name="model">clinic.patient</field>
<field name="tabs">[["All",[]],["Draft",[["state","=","draft"]]],["Active",[["state","=","active"]]],["Deactive",[["state","=","deactive"]]]]</field>

View File

@ -0,0 +1,5 @@
<form model="clinic.department">
<field name="name"/>
<field name="code"/>
<field name="parent_id"/>
</form>

View File

@ -0,0 +1,5 @@
<list model="clinic.department">
<field name="name"/>
<field name="code"/>
<field name="parent_id"/>
</list>

View File

@ -24,8 +24,8 @@
<group span="12" colunm="2">
<field name="telephone"/>
<field name="mobile"/>
<field name="department_id"/>
</group>
<field name="department"/>
<related>
<field name="addresses"/>
</related>

View File

@ -43,10 +43,10 @@
<field name="total"/>
</list>
</field>
<group attrs='{"readonly":[["state","in",["canceled","approved","validate"]]]}'/>
<group attrs='{"readonly":[["state","in",["canceled","approved","validate"]]]}'>
<field name="fee" span="2" offset="7"/>
</group>
<group attrs='{"readonly":[["state","not in",["canceled","approved","validate"]]]}'/>
<group attrs='{"readonly":[["state","not in",["canceled","approved","validate"]]]}'>
<field name="fee" span="2" offset="9"/>
</group>
<field name="total" span="2" offset="9"/>

View File

@ -1,12 +1,15 @@
<menu string="Clinic">
<item string="Dashboard" action="clinic_board"/>
<item string="Doctor" action="clinic_doctor"/>
<item string="Nurse" action="clinic_nurse"/>
<item string="Patient" action="clinic_patient"/>
<item string="Visit" action="clinic_visit"/>
<item string="HD Case Treatment" action="clinic_hd_case"/>
<item string="Dialyzer" action="clinic_dialyzer"/>
<item string="Personal">
<item string="Doctors" action="clinic_doctor"/>
<item string="Nurses" action="clinic_nurse"/>
<item string="Patients" action="clinic_patient"/>
</item>
<item string="Settings">
<item string="Departments" action="clinic_department"/>
<item string="Clinic Setting" action="clinic_setting"/>
</item>
</menu>

View File

@ -5,7 +5,6 @@
<item string="Item1"/>
</button>
</head>
<separator string="Nurse Information"/>
<group span="12" colunm="2">
<field name="number"/>
<field name="date"/>
@ -24,8 +23,8 @@
<group span="12" colunm="2">
<field name="telephone"/>
<field name="mobile"/>
<field name="department_id"/>
</group>
<field name="department"/>
<related>
<field name="addresses"/>
</related>

View File

@ -6,4 +6,5 @@ from . import clinic_hd_case
from . import clinic_hd_case_line
from . import clinic_hd_case_line_detail
from . import clinic_dialyzer
from . import clinic_department
from . import clinic_setting

View File

@ -0,0 +1,14 @@
from netforce.model import Model, fields
class Department(Model):
_name="clinic.department"
_string="Department"
#_name_field="name"
_fields={
"name": fields.Char("Name",required=True,search=True),
"code": fields.Char("Code",search=True),
"parent_id": fields.Many2One("clinic.department", "Parent"),
}
Department.register()

View File

@ -1,7 +1,6 @@
from netforce.model import Model, fields, get_model
from netforce.utils import get_data_path
import time
from netforce.access import get_active_user
from netforce.model import Model, fields, get_model
from netforce.access import get_active_company
class Doctor(Model):
@ -24,6 +23,10 @@ class Doctor(Model):
#"licen" : fields.char("licens medicine No."),
"number2" : fields.Char("Certificate No."),
"licen_issued" : fields.Date("Issued on"),
"birthday": fields.Date("BirthDay",required=True,search=True),
"telephone": fields.Char("Telephone",required=True,search=True),
"department_id": fields.Many2One("clinic.department", "Department",required=True,search=True),
"mobile": fields.Char("Mobile",required=True,search=True),
"state": fields.Selection([("draft","Draft"),("active","Active"),("deactive","Deactive")],"Status",required=True),
"addresses" : fields.One2Many("address","related_id","Addresses"),
"comments" : fields.One2Many("message","related_id","Comments"),
@ -58,5 +61,4 @@ class Doctor(Model):
obj=self.browse(ids)[0]
obj.write({"state":"voided "})
Doctor.register()

View File

@ -24,6 +24,10 @@ class Nurse(Model):
"mobile": fields.Char("Mobile",required=False,search=True),
"number2" : fields.Char("Certificate No."),
"licen_issued" : fields.Date("Issued on"),
"birthday": fields.Date("BirthDay",required=True,search=True),
"telephone": fields.Char("Telephone",required=True,search=True),
"department_id": fields.Many2One("clinic.department", "Department",required=True,search=True),
"mobile": fields.Char("Mobile",required=True,search=True),
"state": fields.Selection([("draft","Draft"),("active","Active"),("deactive","Deactive")],"Status",required=True),
"addresses": fields.One2Many("address","related_id","Addresses"),
"comments": fields.One2Many("message","related_id","Comments"),