ming 3 år sedan
förälder
incheckning
e09f234f95
3 ändrade filer med 41 tillägg och 25 borttagningar
  1. 4 0
      css/common.css
  2. 25 25
      funcAdd.html
  3. 12 0
      funcReport.html

+ 4 - 0
css/common.css

@@ -195,6 +195,10 @@ textarea {
     user-modify: read-only;
 }
 
+input[type="text"][readonly] {
+    background-color: #fff
+}
+
 *:not(input) {
     -webkit-touch-callout: none;
     -webkit-user-select: none;

+ 25 - 25
funcAdd.html

@@ -49,7 +49,7 @@
                 </select>
             </div>
 
-            <div class="select1 select2 select3">
+            <div class="retype2And3">
                 <span><i>*</i>设备类型:</span>
                 <select name="deviceType" id="">
                         <option value="">请选择</option>
@@ -69,24 +69,24 @@
                     </select>
             </div>
 
-            <div class="select1">
+            <div class="retypeAll">
                 <span><i>*</i>开始时间:</span>
                 <input type="text" class="span2" value="" id="checkIn" placeHolder="请选择开始时间" readonly="readonly">
             </div>
-            <div class="select1">
+            <div class="retypeAll">
                 <span><i>*</i>结束时间:</span>
                 <input type="text" class="span2" value="" id="dpd2" placeHolder="请选择结束时间" readonly="readonly">
             </div>
-            <div class="select1">
+            <div class="retypeAll">
                 <span><i> </i>备注:</span>
                 <input type="text" name="remarks">
             </div>
-            <div class="select6">
+            <div class="deviceTypeIs6">
                 <span><i>*</i>端口号:</span>
                 <input type="text" name="portId">
             </div>
 
-            <div class="select6">
+            <div class="deviceTypeIs6">
                 <span><i>*</i>端口类型:</span>
                 <select name="portType">
                         <option value="">请选择</option>
@@ -95,7 +95,7 @@
                     </select>
             </div>
 
-            <div class="selectOther">
+            <div class="deviceTypeOthers">
                 <span><i>*</i>设备编号:</span>
                 <select name="deviceType" id="">
                         <option value="">请选择</option>
@@ -141,29 +141,29 @@
 
     <script>
         // 下拉逻辑联动start
-        $('.select1,.select2,.select3,.select6,.selectOther').css('display', 'none')
+        $('.retypeAll,.retype2And3,.deviceTypeIs6,.deviceTypeOthers').css('display', 'none')
         $('select[name=repType]').change(function() {
             if ($('select[name=repType]').val() == 1) {
-                $('.select1').show()
-                $('.select2,.select3,.select6,.selectOther').hide()
+                $('.retypeAll').show()
+                $('.retype2And3,.deviceTypeIs6,.deviceTypeOthers').hide()
             } else if ($('select[name=repType]').val() == 2) {
-                $('.select2,.select3,.select1').css('display', 'block')
-                $('.select6,.selectOther').hide()
+                $('.retypeAll,.retype2And3').css('display', 'block')
+                $('.deviceTypeIs6,.deviceTypeOthers').hide()
             } else if ($('select[name=repType]').val() == 3) {
-                $('.select2,.select3,.select1').css('display', 'block')
+                $('.retypeAll,.retype2And3').css('display', 'block')
                 if ($('select[name=deviceType]').val()) {
                     if ($('select[name=deviceType]').val() == 6) {
-                        $('.select6').show()
-                        $('.selectOther').hide()
+                        $('.deviceTypeIs6').show()
+                        $('.deviceTypeOthers').hide()
                     } else {
-                        $('.selectOther').show()
-                        $('.select6').hide()
+                        $('.deviceTypeOthers').show()
+                        $('.deviceTypeIs6').hide()
                     }
                 } else {
-                    $('.select6,.selectOther').hide()
+                    $('.deviceTypeIs6,.deviceTypeOthers').hide()
                 }
             } else {
-                $('.select1,.select2,.select3,.select6,.selectOther').css('display', 'none')
+                $('.retypeAll,.retype2And3,.deviceTypeIs6,.deviceTypeOthers').css('display', 'none')
             }
         })
 
@@ -172,18 +172,18 @@
                     if ($('select[name=repType]').val() == 3) {
                         if ($('select[name=deviceType]').val()) {
                             if ($('select[name=deviceType]').val() == 6) {
-                                $('.select6').show()
-                                $('.selectOther').hide()
+                                $('.deviceTypeIs6').show()
+                                $('.deviceTypeOthers').hide()
                             } else {
-                                $('.selectOther').show()
-                                $('.select6').hide()
+                                $('.deviceTypeOthers').show()
+                                $('.deviceTypeIs6').hide()
                             }
                         } else {
-                            $('.select6,.selectOther').hide()
+                            $('.deviceTypeIs6,.deviceTypeOthers').hide()
                         }
                     }
                 } else {
-                    $('.select6,.selectOther').css('display', 'none')
+                    $('.deviceTypeIs6,.deviceTypeOthers').css('display', 'none')
                 }
             })
             // 下拉逻辑联动end

+ 12 - 0
funcReport.html

@@ -276,6 +276,18 @@
             }
         }).on('changeDate', function(ev) {
             checkout.hide();
+            // console.log($('#checkIn').val())
+            if (!$('#checkIn').val()) {
+                alert('请选选择开始时间')
+                return
+            } else {
+                alert('请求数据')
+            }
+
+
+
+
+
         }).data('datepicker');
 
         // $("#checkOut").focus(function() {