123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210 |
- /* ---------------------------------------------------------------------
- 다학제간환자교육정보통합조회 (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 ="";
-
- if (isPopup()) {
- vPid = opener.javascript.getParameter("SPMRJ00300_pid");
- vOrddd = opener.javascript.getParameter("SPMRJ00300_orddd");
- vCretno = opener.javascript.getParameter("SPMRJ00300_cretno");
- group1.disabled = "true";
- group2.disabled = "true";
- btn_close.visible = "true";
- }else
- {
- // vPid = getParameter("SPMRJ00300_pid");
- // vOrddd = getParameter("SPMRJ00300_orddd");
- // vCretno = getParameter("SPMRJ00300_cretno");
- vPid = opener.javascript.getParameter("SPMRJ00300_pid");
- vOrddd = opener.javascript.getParameter("SPMRJ00300_orddd");
- vCretno = opener.javascript.getParameter("SPMRJ00300_cretno");
- }
- // 임시 처리
- //alert("임시로 인자값 세팅함");
- // vPid = "74";
- // vOrddd = "20071204";
- // vCretno = "800337293";
- if((vPid== "")||(vOrddd=="")||(vCretno=="")){
- alert("전달 인자값이 누락되었습니다.!");
- return;
- }
- model.makeValue("/root/init/pinfo/pid", vPid);
- model.makeValue("/root/init/pinfo/orddd", vOrddd);
- model.makeValue("/root/init/pinfo/cretno",vCretno);
- fSelectEducOrdList();
-
-
- }
- function fSelectEducOrdList(){
- model.makeValue("/root/send/pid", model.getValue("/root/init/pinfo/pid"));
- model.makeValue("/root/send/orddd", model.getValue("/root/init/pinfo/orddd"));
- model.makeValue("/root/send/cretno",model.getValue("/root/init/pinfo/cretno"));
-
- submit("TRMRJ00301"); // 입력화면으로 입력만 가능 하도록 처리 주석 풀면 조회하여 기존 데어터도 처리 가능
- fCheckOtherYn(ipt_eduwho9 ,chk_eduwho9.value);
- fCheckOtherYn(ipt_eduhandcap9 ,chk_eduhandcap9ck.value);
- fCheckOtherYn(ipt_eduway9 ,chk_eduway9ck.value);
- fCheckOtherYn(ipt_eduneed9 ,chk_eduneed9ck.value);
- fCheckOtherYn(ipt_descprocer9 ,chk_descprocer9ck.value);
- fCheckOtherYn(ipt_descplace9 ,chk_descplace9ck.value);
- fCheckOtherYn(ipt_descfcstneed9 ,chk_descfcstneed9ck.value);
- if(rdo_eduwill.value== "999"){
- fCheckOtherYn(ipt_eduwill9,"Y");
- }else{
- fCheckOtherYn(ipt_eduwill9,"N");
- }
- fRdoEduHandCapyn();
- }
- function fRdoEduHandCapyn(){
- if(rdo_eduhandcapyn.value=="N"){
- chk_eduhandcap1.value = "N";
- chk_eduhandcap1.disabled = "true";
- chk_eduhandcap2.value = "N";
- chk_eduhandcap2.disabled = "true";
- chk_eduhandcap3.value = "N";
- chk_eduhandcap3.disabled = "true";
- chk_eduhandcap4.value = "N";
- chk_eduhandcap4.disabled = "true";
- chk_eduhandcap5.value = "N";
- chk_eduhandcap5.disabled = "true";
- chk_eduhandcap6.value = "N";
- chk_eduhandcap6.disabled = "true";
- chk_eduhandcap9ck.value = "N";
- chk_eduhandcap9ck.disabled = "true";
- fCheckOtherYn(ipt_eduhandcap9,"N");
- }else{
- chk_eduhandcap1.disabled = "false";
- chk_eduhandcap2.disabled = "false";
- chk_eduhandcap3.disabled = "false";
- chk_eduhandcap4.disabled = "false";
- chk_eduhandcap5.disabled = "false";
- chk_eduhandcap6.disabled = "false";
- chk_eduhandcap9ck.disabled = "false";
- fCheckOtherYn(ipt_eduhandcap9,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(!(chk_eduwho1.value == "Y" || chk_eduwho2.value == "Y" || chk_eduwho9.value == "Y")){
- messageBox("교육요구 항목이 누락 되었습니다.","I003");
- return;
- }
- if(chk_eduwho9.value == "Y" && ipt_eduwho9.value.getTrim() == "") { // 기타 항목 체크
- messageBox("교육요구의 기타 항목이 누락 되었습니다.","I003");
- return;
- }
- if(rdo_eduwill.value == ""){
- messageBox("교육에 대한 의지 항목이 누락 되었습니다.","I003");
- return;
- }
- if(rdo_eduwill.value == "999" && ipt_eduwill9.value.getTrim() == ""){ // 기타 항목 체크
- messageBox("교육에 대한 의지의 기타 항목이 누락 되었습니다.","I003");
- return;
-
- }
- if((rdo_eduhandcapyn.value == "Y")&&!(chk_eduhandcap1.value == "Y" || chk_eduhandcap2.value == "Y" || chk_eduhandcap3.value == "Y" || chk_eduhandcap4.value == "Y" || chk_eduhandcap5.value == "Y" || chk_eduhandcap6.value == "Y" || chk_eduhandcap9ck.value == "Y")){
- messageBox("교육 장애요인 항목이 누락 되었습니다.","I003");
- return;
- }
- if(chk_eduhandcap9ck.value == "Y" && ipt_eduhandcap9.value.getTrim() == ""){ // 기타 항목 체크
- messageBox("교육 장애요인의 기타 항목이 누락 되었습니다.","I003");
- return;
- }
- if(!(chk_eduway1.value == "Y" || chk_eduway2.value == "Y" || chk_eduway3.value == "Y" || chk_eduway4.value == "Y" || chk_eduway5.value == "Y" || chk_eduway9ck.value == "Y")){
- messageBox("교육방법 항목이 누락 되었습니다.","I003");
- return;
- }
- if(chk_eduway9ck.value == "Y"&& ipt_eduway9.value.getTrim() == ""){ // 기타 항목 체크
- messageBox("교육방법의 기타 항목이 누락 되었습니다.","I003");
- return;
- }
- if(!(chk_eduneed1.value == "Y" || chk_eduneed2.value == "Y" || chk_eduneed3.value == "Y" || chk_eduneed4.value == "Y" || chk_eduneed9ck.value == "Y")){
- messageBox("원하는 교육 내용 항목이 누락 되었습니다.","I003");
- return;
- }
- if(chk_eduneed9ck.value == "Y" && ipt_eduneed9.value.getTrim() == ""){ // 기타 항목 체크
- messageBox("원하는 교육 내용의 기타 항목이 누락 되었습니다.","I003");
- return;
- }
- }
-
- if (group2.visible){ // 퇴원계획 요구도 사정 필수 체크
- if(!(chk_descprocer1.value == "Y" || chk_descprocer2.value == "Y" || chk_descprocer3.value == "Y" || chk_descprocer4.value == "Y" || chk_descprocer5.value == "Y" || chk_descprocer6.value == "Y" || chk_descprocer7.value == "Y" || chk_descprocer8.value == "Y" || chk_descprocer9ck.value == "Y")){
- messageBox("퇴원 후 주 보호자 항목이 누락 되었습니다.","I003");
- return;
- }
- if(chk_descprocer9ck.value == "Y" && ipt_descprocer9.value.getTrim() == ""){
- messageBox("퇴원 후 주 보호자의 기타 항목이 누락 되었습니다.","I003");
- return;
- }
- if(!(chk_descplace1.value == "Y" || chk_descplace2.value == "Y" || chk_descplace3.value == "Y" || chk_descplace4.value == "Y" || chk_descplace5.value == "Y" || chk_descplace9ck.value == "Y")){
- messageBox("퇴원예정지 항목이 누락 되었습니다.","I003");
- return;
- }
- if(chk_descplace9ck.value == "Y" && ipt_descplace9.value.getTrim() == ""){
- messageBox("퇴원예정지의 기타 항목이 누락 되었습니다.","I003");
- return;
- }
- if(!(chk_descfcstneed1.value == "Y" || chk_descfcstneed2.value == "Y" || chk_descfcstneed3.value == "Y" || chk_descfcstneed4.value == "Y" || chk_descfcstneed5.value == "Y" || chk_descfcstneed6.value == "Y" || chk_descfcstneed9ck.value == "Y")){
- messageBox("예상되는 퇴원 시 요구내용 항목이 누락 되었습니다.","I003");
- return;
- }
- if(chk_descfcstneed9ck.value == "Y" && ipt_descfcstneed9.value.getTrim() == ""){
- messageBox("예상되는 퇴원 시 요구내용의 기타 항목이 누락 되었습니다.","I003");
- return;
- }
- }
- if(submit("TXMRJ00301")){
- fSelectEducOrdList();
-
- }else{
- messageBox("교육요구도 저장이 실패하였습니다.", "E");
- return false;
- }
- return true;
- }
- function fClose(){
- window.close();
- }
|