def getPatients(doctorId): patients = Diagnose.getPatientListByDoctorId(doctorId) patientsDict = object2dict.objects2dicts(patients) resultStatus = rs.ResultStatus(rs.SUCCESS.status, rs.SUCCESS.msg, patientsDict) resultDict = resultStatus.__dict__ return json.dumps(resultDict, ensure_ascii=False)
def getPatients(doctorId): patients=Diagnose.getPatientListByDoctorId(doctorId) patientsDict=object2dict.objects2dicts(patients) resultStatus=rs.ResultStatus(rs.SUCCESS.status,rs.SUCCESS.msg,patientsDict) resultDict=resultStatus.__dict__ return json.dumps(resultDict,ensure_ascii=False)