SMMNH00001.js 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. /*
  2. 호스피스 코드 조회
  3. - Version :
  4. 1) : Ver.1.00.01
  5. 2) : 2008.05. 26
  6. 3) : 김진명
  7. */
  8. var zbcResultRef = "/root/temp/code/resultref";
  9. var gvZBCCodeCachePath="/root/hidden/zbccode"
  10. var removeNodePath = "/root/init/";
  11. function makeZbcResultRef(){ model.makeNode(zbcResultRef); }
  12. function removeZbcResultRef(){ model.removeNode(zbcResultRef); }
  13. // 공통코드 조회(Cache 방식)
  14. function fGetCodeList(cd_grup_id_list, rslt_ref_list) {
  15. fGetCodeListSubmit(cd_grup_id_list, rslt_ref_list);
  16. }
  17. function fGetCodeListSubmit(cd_grup_id_list, rslt_ref_list){
  18. makeZbcResultRef();
  19. for (key in cd_grup_id_list){
  20. addParameter("cdgrupid", cd_grup_id_list[key]);
  21. }
  22. var success = submit("TRMNH00001", "false", getParameterPath(), zbcResultRef);
  23. for(key in cd_grup_id_list){
  24. var target_path = rslt_ref_list[key];
  25. if(target_path==null){
  26. target_path = rslt_ref_list[key-1];
  27. }
  28. var source_path = zbcResultRef+"/"+cd_grup_id_list[key]+"/"+cd_grup_id_list[key];
  29. var sourceNode = instance1.selectNodes(zbcResultRef+"/"+cd_grup_id_list[key]+"/"+cd_grup_id_list[key]);
  30. for(i=0; i<sourceNode.length; i++){
  31. model.duplicate(target_path, sourceNode.item(i));
  32. }
  33. }
  34. removeZbcResultRef();
  35. clearParameter("cdgrupid");
  36. }
  37. /* --------------------------------------------------*/
  38. /* type : function */
  39. /* access : public */
  40. /* desc : 그리드 콤보 아이템 제거(공백) */
  41. /* param : */
  42. /* return : */
  43. /* --------------------------------------------------*/
  44. function fRemoveNode(path_list){
  45. for(key in path_list){
  46. var target_path = path_list[key];
  47. model.destroy( removeNodePath + target_path + "[1]" );
  48. }
  49. }