|
@@ -8,10 +8,13 @@ app.controller('MainCtrl', [ '$rootScope', '$scope', '$timeout', function($rootS
|
|
$scope.hasFirstScore = false;
|
|
$scope.hasFirstScore = false;
|
|
$scope.hasFinalScore = false;
|
|
$scope.hasFinalScore = false;
|
|
|
|
|
|
- $rootScope.can_sc = true;
|
|
|
|
|
|
+ /*$rootScope.can_sc = true;
|
|
$rootScope.can_yxtb = true;
|
|
$rootScope.can_yxtb = true;
|
|
- $rootScope.can_jbyl = true;
|
|
|
|
|
|
+ $rootScope.can_jbyl = true;*/
|
|
$scope.showEnrolFlag = false;
|
|
$scope.showEnrolFlag = false;
|
|
|
|
+ $scope.firstScoreTimeFlag = false;
|
|
|
|
+ $scope.finalScoreTimeFlag = false
|
|
|
|
+
|
|
|
|
|
|
$scope.getEnrolArray2 = function() {
|
|
$scope.getEnrolArray2 = function() {
|
|
$rootScope.ajaxRequest({
|
|
$rootScope.ajaxRequest({
|
|
@@ -19,7 +22,7 @@ app.controller('MainCtrl', [ '$rootScope', '$scope', '$timeout', function($rootS
|
|
}, function(response) {
|
|
}, function(response) {
|
|
$scope.EnrolArray2 = response.array;
|
|
$scope.EnrolArray2 = response.array;
|
|
for(const ea of $scope.EnrolArray2) {
|
|
for(const ea of $scope.EnrolArray2) {
|
|
- if(ea.aspect_id == 20701 || ea.aspect_id == 22001) {
|
|
|
|
|
|
+ if(ea.aspect_id === 20701 || ea.aspect_id === 22001) {
|
|
$scope.showEnrolFlag = true;
|
|
$scope.showEnrolFlag = true;
|
|
break;
|
|
break;
|
|
}
|
|
}
|
|
@@ -27,42 +30,28 @@ app.controller('MainCtrl', [ '$rootScope', '$scope', '$timeout', function($rootS
|
|
});
|
|
});
|
|
}
|
|
}
|
|
|
|
|
|
- $scope.getScoreArray = function() {
|
|
|
|
- var today = $rootScope.shortDateString(new Date());
|
|
|
|
- var now = new Date();
|
|
|
|
-
|
|
|
|
|
|
+ $scope.getScoreArray = function () {
|
|
$rootScope.ajaxRequest({
|
|
$rootScope.ajaxRequest({
|
|
- url : '../enrol/std/score/ym/final/list.htm'
|
|
|
|
- //data : {batch: "first"}
|
|
|
|
- }, function(response) {
|
|
|
|
- $rootScope.ScoreArray = response.array;
|
|
|
|
- for (var i=0;i<response.array.length;i++) {
|
|
|
|
- if (response.array[i].batch == 'first') {
|
|
|
|
|
|
+ url: '../enrol/std/score/ym/final/list.htm'
|
|
|
|
+ }, function (response) {
|
|
|
|
+ for (var i = 0; i < response.array.length; i++) {
|
|
|
|
+ if (response.array[i].batch === 'first') {
|
|
$scope.hasFirstScore = true;
|
|
$scope.hasFirstScore = true;
|
|
- } else if (response.array[i].batch == 'final') {
|
|
|
|
|
|
+ } else if (response.array[i].batch === 'final') {
|
|
$scope.hasFinalScore = true;
|
|
$scope.hasFinalScore = true;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
- /*var qualified_total = 0;
|
|
|
|
- for(var i=0;i<response.array.length;i++){
|
|
|
|
- if(response.array[i].aspect_qualified !='不合格')
|
|
|
|
- qualified_total ++;
|
|
|
|
- }
|
|
|
|
- $rootScope.qualified_total = qualified_total ;*/
|
|
|
|
});
|
|
});
|
|
}
|
|
}
|
|
//初试成绩
|
|
//初试成绩
|
|
$scope.goFirstScore = function(e) {
|
|
$scope.goFirstScore = function(e) {
|
|
- //debugger;
|
|
|
|
$rootScope.goLocation('ym/score/' + e.aspect_name + '/first');//初试成绩
|
|
$rootScope.goLocation('ym/score/' + e.aspect_name + '/first');//初试成绩
|
|
}
|
|
}
|
|
//复试成绩
|
|
//复试成绩
|
|
$scope.goFinalScore = function(e) {
|
|
$scope.goFinalScore = function(e) {
|
|
- //debugger;
|
|
|
|
$rootScope.goLocation('ym/score/' + e.aspect_name + '/final');//复试成绩
|
|
$rootScope.goLocation('ym/score/' + e.aspect_name + '/final');//复试成绩
|
|
}
|
|
}
|
|
$scope.goAddr = function(e) {
|
|
$scope.goAddr = function(e) {
|
|
- //debugger;
|
|
|
|
$rootScope.goLocation('ym/addr');//邮寄地址修改界面
|
|
$rootScope.goLocation('ym/addr');//邮寄地址修改界面
|
|
}
|
|
}
|
|
|
|
|
|
@@ -82,18 +71,38 @@ app.controller('MainCtrl', [ '$rootScope', '$scope', '$timeout', function($rootS
|
|
}, function(response) {
|
|
}, function(response) {
|
|
$scope.Agent = response.map;
|
|
$scope.Agent = response.map;
|
|
var now = $rootScope.parseLongString(response.map.now);
|
|
var now = $rootScope.parseLongString(response.map.now);
|
|
|
|
+
|
|
|
|
+ // 准考证下载
|
|
if ($rootScope.parseLongString(response.map.ticket_start_time) < now
|
|
if ($rootScope.parseLongString(response.map.ticket_start_time) < now
|
|
&& $rootScope.parseLongString(response.map.ticket_end_time) > now) {
|
|
&& $rootScope.parseLongString(response.map.ticket_end_time) > now) {
|
|
- // 判断考点是否开放了预约,只处理当天
|
|
|
|
$scope.showTicket = true;
|
|
$scope.showTicket = true;
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ // 报考按钮显示
|
|
|
|
+ if ($rootScope.parseLongString(response.map.enrol_start_time) < now
|
|
|
|
+ && $rootScope.parseLongString(response.map.enrol_end_time) > now) {
|
|
|
|
+ $scope.enrolTimeFlag = true;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ //初试成绩显示
|
|
|
|
+ if ($rootScope.parseLongString(response.map.first_score_start_time) < now
|
|
|
|
+ && $rootScope.parseLongString(response.map.first_score_end_time) > now) {
|
|
|
|
+ $scope.firstScoreTimeFlag = true;
|
|
|
|
+ $scope.getScoreArray();
|
|
|
|
+ }
|
|
|
|
+ //复试成绩显示
|
|
|
|
+ if ($rootScope.parseLongString(response.map.final_score_start_time) < now
|
|
|
|
+ && $rootScope.parseLongString(response.map.final_score_end_time) > now) {
|
|
|
|
+ $scope.finalScoreTimeFlag = true;
|
|
|
|
+ $scope.getScoreArray();
|
|
|
|
+ }
|
|
});
|
|
});
|
|
}
|
|
}
|
|
|
|
|
|
$scope.getEnrolArray2();
|
|
$scope.getEnrolArray2();
|
|
//$scope.getScoreArray();
|
|
//$scope.getScoreArray();
|
|
$scope.getAgent();
|
|
$scope.getAgent();
|
|
- $scope.enrolTime();
|
|
|
|
|
|
+ //$scope.enrolTime();
|
|
|
|
|
|
|
|
|
|
//进入申请页面
|
|
//进入申请页面
|