$(document).on('click', '#addCiWorkBtn', function (){ getCiWorkEditModal(null); }) $(document).on('click', '#arrestType1', function (){ getArrestType2Option(this.value); }) function getCiWorkEditModal(ciwKey){ $.ajax({ url: '/counterIntelligence/ciWorkEditModal', data: {ciwKey: ciwKey}, type: 'GET', dataType:"html", success: function(html){ $("#ciWorkEditModalContent").empty().append(html) $(".dateSelector").datepicker({ format: "yyyy-mm-dd", language: "ko", autoclose: true }); setUploadDiv(); setEditor('editor', '400'); $("#ciWorkEditModal").modal('show'); }, error:function(){ } }); } function getArrestType2Option(categoryCd){ $.ajax({ url: '/selectBoxOptions', data: {categoryCd: categoryCd}, type: 'GET', dataType:"html", success: function(html){ const arrestType2 = $("#arrestType2"); arrestType2.empty().append(html); }, error:function(){ } }); }