소스 검색

Add attachment doc autre

stany.ferer 1 년 전
부모
커밋
485dab44b0
1개의 변경된 파일5개의 추가작업 그리고 4개의 파일을 삭제
  1. 5 4
      core/javascript/cms.document.php

+ 5 - 4
core/javascript/cms.document.php

@@ -33,12 +33,10 @@
         });
 
         if (allFieldsFilled) {
-
             const selectedType = $("#id_type").val();
-            if (selectedType !== "1") {
+            if (selectedType !== "1" || selectedType !== "0") {
                 $("#id_client").val("");
             }
-
             form.submit();
         }
     }
@@ -135,14 +133,17 @@
             max: 5
         });
     });
+
 <?php } ?>
+
     $(document).ready(function() {
         $("#id_type").change(function() {
-            if ($("#id_type").val() === "1") {
+            if ($("#id_type").val() === "1" || $("#id_type").val() === "0") {
                 $("#client-section").show();
             } else {
                 $("#client-section").hide();
             }
         });
     });
+
 </script>