Kaynağa Gözat

时间弹出框

wangcz 8 yıl önce
ebeveyn
işleme
6988bad902

+ 1 - 1
src/main/webapp/resources/js/vendor/controllers/b2b/saleOrderCtrl.js

@@ -365,7 +365,7 @@ define(['app/app'], function (app) {
                 };
 
                 // 搜索框回车
-                $scope.onSearch = function (keyword) {
+                $scope.onSearch = function () {
                     // 每次搜索重置获取数据方法
                     $scope.tableParams.page(1);
                     $scope.tableParams.reload();

+ 14 - 12
src/main/webapp/resources/view/vendor/b2b/sale_order.html

@@ -232,28 +232,30 @@
 			<div class="sreach fr">
 				<div ng-show="autoMonth" class="date fl">
 					<div class="data-input">
-						<input id="start" type="text" ng-model="startDate" readonly="readonly"
+						<input type="text" ng-model="startDate"
 							   class="form-control select-adder" placeholder="起始时间"
 							   datepicker-popup="yyyy-MM-dd"
-							   is-open="condition[0].open"
-							   current-text="今天" clear-text="清除" close-text="关闭"
+							   is-open="condition.startDateOpen"
+							   max-date="endDate" current-text="今天" clear-text="清除" close-text="关闭"
+							   ng-click="openDatePicker($event, condition, 'startDateOpen',1)"
 							   datepicker-options="{formatDayTitle: 'yyyy年M月', formatMonth: 'M月', showWeeks: false}"
-							   ng-click="openChooseDatePicker($event, condition, 0, 1)"
-							   ng-change="onDateCondition(1)"/>
-						<button class="open" ng-click="openChooseDatePicker($event, condition, 0)"></button>
+							   ng-change="vaildDate(true)"
+						/>
+						<button class="open" ng-click="openDatePicker($event, condition, 'startDateOpen')"></button>
 					</div>
 
 					<em>–</em>
 					<div class="data-input">
-						<input id="end" type="text" ng-model="endDate" readonly="readonly"
+						<input type="text" ng-model="endDate"
 							   class="form-control select-adder" placeholder="结束时间"
 							   datepicker-popup="yyyy-MM-dd"
-							   is-open="condition[1].open"
-							   current-text="今天" clear-text="清除" close-text="关闭"
+							   is-open="condition.endDateOpen"
+							   min-date="startDate" current-text="今天" clear-text="清除" close-text="关闭"
+							   ng-click="openDatePicker($event, condition, 'endDateOpen',2)"
 							   datepicker-options="{formatDayTitle: 'yyyy年M月', formatMonth: 'M月', showWeeks: false}"
-							   ng-click="openChooseDatePicker($event, condition, 1, 2)"
-							   ng-change="onDateCondition(2)"/>
-						<button class="open" ng-click="openChooseDatePicker($event, condition, 1)"></button>
+							   ng-change="changeEndDate()"
+						/>
+						<button class="open" ng-click="openDatePicker($event, condition, 'endDateOpen')"></button>
 					</div>
 				</div>
 				<div class="sreach-input fr">