123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237 |
- <?xml version="1.0" encoding="utf-8"?>
- <Script type="xscript4.0"><![CDATA[/* ---------------------------------------------------------------------
- 다학제간환자교육정보통합조회 (SMMRJ00200_다학제간환자교육정보통합조회.xrw - JScript )
- - Version :
- 1) : Ver.1.00.01
- : Create By taebum
- : 2009-12-07 오전 10:05:51
- ---------------------------------------------------------------------- */
- /* --------------------------------------------------*/
- /* type : function */
- /* access : public */
- /* desc : xforms-ready시 수행한다 */
- /* return : */
- /* --------------------------------------------------*/
- function fInit() {
- var vPid ="";
- var vOrddd ="";
- var vCretno ="";
- var vID = "";
- if (frmf_isPopup() && sysf_getObjType(this) == "Form") {
- vPid = SPMRJ00300_oOpener.frmf_getParameter("SPMRJ00300_pid");
- vOrddd = SPMRJ00300_oOpener.frmf_getParameter("SPMRJ00300_orddd");
- vCretno = SPMRJ00300_oOpener.frmf_getParameter("SPMRJ00300_cretno");
- group1.enable = false;
- group2.enable = false;
- btn_close.visible = true;
- }else
- {
- vPid = SPMRJ00300_oOpener.frmf_getParameter("SPMRJ00300_pid");
- vOrddd = SPMRJ00300_oOpener.frmf_getParameter("SPMRJ00300_orddd");
- vCretno = SPMRJ00300_oOpener.frmf_getParameter("SPMRJ00300_cretno");
- Id = SPMRJ00300_oOpener.frmf_getParameter("SPMRJ00300_ID");
- if(Id == "SMMNE04300")
- {
- group2.visible = false;
- }
- }
- if((utlf_isNull(vPid))||(utlf_isNull(vOrddd))||(utlf_isNull(vCretno))){
- alert("전달 인자값이 누락되었습니다.!");
- return;
- }
-
- dsf_makeValue(ds_init_pinfo,"pid", "string", vPid);
- dsf_makeValue(ds_init_pinfo,"orddd", "string",vOrddd);
- dsf_makeValue(ds_init_pinfo,"cretno","string",vCretno);
-
- fSelectEducOrdList();
- }
- function fSelectEducOrdList(){
-
- dsf_makeValue(ds_send,"pid", "string", ds_init_pinfo.getColumn(0,"pid"));
- dsf_makeValue(ds_send,"orddd", "string",ds_init_pinfo.getColumn(0,"orddd"));
- dsf_makeValue(ds_send,"cretno","string",ds_init_pinfo.getColumn(0,"cretno"));
-
- var oParam = {};
- oParam.id = "TRMRJ00301";
- oParam.service = "jcimngtapp.JcimngtBase";
- oParam.method = "reqGetEducOrdList";
- oParam.inds = "req=ds_send";
- oParam.outds = "ds_educordlist=educordlist";
- oParam.async = true;
- oParam.callback = "cf_TRMRJ00301";
- tranf_submit(oParam); // 입력화면으로 입력만 가능 하도록 처리 주석 풀면 조회하여 기존 데어터도 처리 가능
-
- if(utlf_isNull(ds_educordlist.getColumnInfo("eduhandcapyn")))
- {
- dsf_makeValue(ds_educordlist, "eduhandcapyn", "string", "");
- }
- }
- function cf_TRMRJ00301(sSvcId, nErrorCode, sErrorMsg) {
- if(nErrorCode < 0) return;
- fCheckOtherYn(group1.ipt_eduwho9 ,group1.chk_eduwho9.value);
- fCheckOtherYn(group1.ipt_eduhandcap9 ,group1.chk_eduhandcap9ck.value);
- fCheckOtherYn(group1.ipt_eduway9 ,group1.chk_eduway9ck.value);
- fCheckOtherYn(group1.ipt_eduneed9 ,group1.chk_eduneed9ck.value);
- fCheckOtherYn(group2.ipt_descprocer9 ,group2.chk_descprocer9ck.value);
- fCheckOtherYn(group2.ipt_descplace9 ,group2.chk_descplace9ck.value);
- fCheckOtherYn(group2.ipt_descfcstneed9 ,group2.chk_descfcstneed9ck.value);
- if(group1.rdo_eduwill.value== "999"){
- fCheckOtherYn(group1.ipt_eduwill9,"Y");
- }else{
- fCheckOtherYn(group1.ipt_eduwill9,"N");
- }
- fRdoEduHandCapyn();
- }
- function fRdoEduHandCapyn(){
- if(group1.rdo_eduhandcapyn.value=="N"){
- group1.chk_eduhandcap1.value = "N";
- group1.chk_eduhandcap1.enable = false;
- group1.chk_eduhandcap2.value = "N";
- group1.chk_eduhandcap2.enable = false;
- group1.chk_eduhandcap3.value = "N";
- group1.chk_eduhandcap3.enable = false;
- group1.chk_eduhandcap4.value = "N";
- group1.chk_eduhandcap4.enable = false;
- group1.chk_eduhandcap5.value = "N";
- group1.chk_eduhandcap5.enable = false;
- group1.chk_eduhandcap6.value = "N";
- group1.chk_eduhandcap6.enable = false;
- group1.chk_eduhandcap9ck.value = "N";
- group1.chk_eduhandcap9ck.enable = false;
- fCheckOtherYn(group1.ipt_eduhandcap9,"N");
- }else{
- group1.chk_eduhandcap1.enable = true;
- group1.chk_eduhandcap2.enable = true;
- group1.chk_eduhandcap3.enable = true;
- group1.chk_eduhandcap4.enable = true;
- group1.chk_eduhandcap5.enable = true;
- group1.chk_eduhandcap6.enable = true;
- group1.chk_eduhandcap9ck.enable = true;
- fCheckOtherYn(group1.ipt_eduhandcap9,group1.chk_eduhandcap9ck.value);
- }
- }
- function fCheckOtherYn(ipt, param){
-
- if(param=="Y"){
- ipt.visible = true;
- }else{
- ipt.visible = false;
- ipt.value = "";
- }
-
- }
- function fSave(){
- if (group1.visible){ // 교육요구도 사정 필수 체크
- if(!(group1.chk_eduwho1.value == "Y" || group1.chk_eduwho2.value == "Y" || group1.chk_eduwho9.value == "Y")){
- sysf_messageBox("교육요구 항목이 누락 되었습니다.","I003");
- return;
- }
- if(group1.chk_eduwho9.value == "Y" && utlf_isNull(group1.ipt_eduwho9.value.getTrim())) { // 기타 항목 체크
- sysf_messageBox("교육요구의 기타 항목이 누락 되었습니다.","I003");
- return;
- }
- if(utlf_isNull(group1.rdo_eduwill.value)){
- sysf_messageBox("교육에 대한 의지 항목이 누락 되었습니다.","I003");
- return;
- }
- if(group1.rdo_eduwill.value == "999" && utlf_isNull(group1.ipt_eduwill9.value.getTrim())){ // 기타 항목 체크
- sysf_messageBox("교육에 대한 의지의 기타 항목이 누락 되었습니다.","I003");
- return;
-
- }
- if((group1.rdo_eduhandcapyn.value == "Y")&&!(group1.chk_eduhandcap1.value == "Y" || group1.chk_eduhandcap2.value == "Y" || group1.chk_eduhandcap3.value == "Y" || group1.chk_eduhandcap4.value == "Y" || group1.chk_eduhandcap5.value == "Y" || group1.chk_eduhandcap6.value == "Y" || group1.chk_eduhandcap9ck.value == "Y")){
- sysf_messageBox("교육 장애요인 항목이 누락 되었습니다.","I003");
- return;
- }
- if(group1.chk_eduhandcap9ck.value == "Y" && utlf_isNull(group1.ipt_eduhandcap9.value.getTrim())){ // 기타 항목 체크
- sysf_messageBox("교육 장애요인의 기타 항목이 누락 되었습니다.","I003");
- return;
- }
- if(!(group1.chk_eduway1.value == "Y" || group1.chk_eduway2.value == "Y" || group1.chk_eduway3.value == "Y" || group1.chk_eduway4.value == "Y" || group1.chk_eduway5.value == "Y" || group1.chk_eduway9ck.value == "Y")){
- sysf_messageBox("교육방법 항목이 누락 되었습니다.","I003");
- return;
- }
- if(group1.chk_eduway9ck.value == "Y"&& utlf_isNull(group1.ipt_eduway9.value.getTrim())){ // 기타 항목 체크
- sysf_messageBox("교육방법의 기타 항목이 누락 되었습니다.","I003");
- return;
- }
- if(!(group1.chk_eduneed1.value == "Y" || group1.chk_eduneed2.value == "Y" || group1.chk_eduneed3.value == "Y" || group1.chk_eduneed4.value == "Y" || group1.chk_eduneed9ck.value == "Y")){
- sysf_messageBox("원하는 교육 내용 항목이 누락 되었습니다.","I003");
- return;
- }
- if(group1.chk_eduneed9ck.value == "Y" && utlf_isNull(group1.ipt_eduneed9.value.getTrim())){ // 기타 항목 체크
- sysf_messageBox("원하는 교육 내용의 기타 항목이 누락 되었습니다.","I003");
- return;
- }
- }
-
- if (group2.visible){ // 퇴원계획 요구도 사정 필수 체크
- if(!(group2.chk_descprocer1.value == "Y" || group2.chk_descprocer2.value == "Y" || group2.chk_descprocer3.value == "Y" || group2.chk_descprocer4.value == "Y" || group2.chk_descprocer5.value == "Y" || group2.chk_descprocer6.value == "Y" || group2.chk_descprocer7.value == "Y" || group2.chk_descprocer8.value == "Y" || group2.chk_descprocer9ck.value == "Y")){
- sysf_messageBox("퇴원 후 주 보호자 항목이 누락 되었습니다.","I003");
- return;
- }
- if(group2.chk_descprocer9ck.value == "Y" && utlf_isNull(group2.ipt_descprocer9.value.getTrim())){
- sysf_messageBox("퇴원 후 주 보호자의 기타 항목이 누락 되었습니다.","I003");
- return;
- }
- if(!(group2.chk_descplace1.value == "Y" || group2.chk_descplace2.value == "Y" || group2.chk_descplace3.value == "Y" || group2.chk_descplace4.value == "Y" || group2.chk_descplace5.value == "Y" || group2.chk_descplace9ck.value == "Y")){
- sysf_messageBox("퇴원예정지 항목이 누락 되었습니다.","I003");
- return;
- }
- if(group2.chk_descplace9ck.value == "Y" && utlf_isNull(group2.ipt_descplace9.value.getTrim())){
- sysf_messageBox("퇴원예정지의 기타 항목이 누락 되었습니다.","I003");
- return;
- }
- if(!(group2.chk_descfcstneed1.value == "Y" || group2.chk_descfcstneed2.value == "Y" || group2.chk_descfcstneed3.value == "Y" || group2.chk_descfcstneed4.value == "Y" || group2.chk_descfcstneed5.value == "Y" || group2.chk_descfcstneed6.value == "Y" || group2.chk_descfcstneed9ck.value == "Y")){
- sysf_messageBox("예상되는 퇴원 시 요구내용 항목이 누락 되었습니다.","I003");
- return;
- }
- if(group2.chk_descfcstneed9ck.value == "Y" && utlf_isNull(group2.ipt_descfcstneed9.value.getTrim())){
- sysf_messageBox("예상되는 퇴원 시 요구내용의 기타 항목이 누락 되었습니다.","I003");
- return;
- }
- }
-
- var oParam = {};
- oParam.id = "TXMRJ00301";
- oParam.service = "jcimngtapp.JcimngtBase";
- oParam.method = "reqSetEducOrdLists";
- oParam.inds = "educordlists=ds_educordlist";
- oParam.outds = "ds_msglist=msglist";
- oParam.async = false;
- oParam.callback = "cf_TXMRJ00301";
- tranf_submit(oParam);
- if(arErrorCode.pop("TXMRJ00301") > -1){
- fSelectEducOrdList();
-
- }else{
- sysf_messageBox("교육요구도 저장이 실패하였습니다.", "E");
- return false;
- }
- return true;
- }
- function cf_TXMRJ00301(sSvcId, nErrorCode, sErrorMsg) {
- arErrorCode.push(sSvcId, nErrorCode);
- }
- function fClose(){
- close();
- }
- ]]></Script>
|