Commit c3c2e315 authored by suichenguang's avatar suichenguang

页面修改

parent 7c72efd5
......@@ -34,7 +34,7 @@
</span>
</div>
</span>
<span class="col-lg-1" style="margin-left: 1em">
<span class="col-lg-1" style="margin-left: 6em">
<button type="button" class="btn btn-primary" ng-click="task_click()">查询</button>
</span>
</div>
......
app.controller('cycleSheetCtrl', ['$scope', '$rootScope', '$http', '$state', '$filter', '$localStorage', 'HttpService', 'ngDialog', function ($scope, $rootScope, $http, $state, $filter, $localStorage, HttpService, ngDialog) {
app.controller('yieldReportCtrl', ['$scope', '$rootScope', '$http', '$state', '$filter', '$localStorage', 'HttpService', 'ngDialog', function ($scope, $rootScope, $http, $state, $filter, $localStorage, HttpService, ngDialog) {
if ($rootScope.loginData.login === false) {
$state.go("signin")
} else {
$state.go("layout.qualityReport")
$state.go("layout.yieldReport")
}
$scope.userState = $rootScope.loginData.state;
// $scope.userState=5;
if ($rootScope.loginData.login == false) {
$location.path("/login");
}
$scope.date = "date";
......@@ -30,13 +27,13 @@ app.controller('cycleSheetCtrl', ['$scope', '$rootScope', '$http', '$state', '$f
return currentdate;
}
$scope.currentDetailDate = getNowFormatDetailDate();
$scope.nowDate = new Date().format("yyyyMMdd");
$scope.nowMonth = new Date().format("yyyyMM");
$scope.nowDate = new Date("yyyyMMdd");
$scope.nowMonth = new Date("yyyyMM");
var getMonthFirstDay = function () {
var month_first = new Date();
var month_first = new Date("yyyyMMdd");
month_first.setDate(1);
return month_first.format("yyyyMMdd");
return month_first;
}
var getMonthLastDay = function () {
var date = new Date();
......@@ -45,7 +42,7 @@ app.controller('cycleSheetCtrl', ['$scope', '$rootScope', '$http', '$state', '$f
var nextMonthFirstDay = new Date(date.getFullYear(), nextMonth, 1);
var oneDay = 1000 * 60 * 60 * 24;
var month_last = new Date(nextMonthFirstDay - oneDay);
return month_last.format("yyyyMMdd");
return $filter('date')(month_last,'yyyyMMdd');
}
$scope.month_first = getMonthFirstDay();
$scope.month_last = getMonthLastDay();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment