123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172 |
- app.controller('YmAspectInfoCtrl', [ '$rootScope', '$scope', '$stateParams', '$timeout', function($rootScope, $scope, $stateParams, $timeout) {
- if ($stateParams == undefined || $stateParams.enrol_id == undefined) {
- $.alert('参数错误,无法获取准考证详细信息', function() {
- $rootScope.goWechat();
- });
- return;
- }
- $scope.getEnrol = function(autopay) {
- $rootScope.ajaxRequest({
- url : '../enrol/std/enrol/find.htm',
- data : {
- enrol_id : $stateParams.enrol_id,
- aspect_batch : 1
- }
- }, function(response) {
- $scope.curStep = 'info';
- $scope.EnrolMap = response.map;
- $scope.EnrolMap.StdEnrol.std_ems_code = $scope.EnrolMap.StdEnrol.std_ems_id
- });
- }
- $scope.getEnrol();
- $scope.goConfirm = function() {
- $.confirm("确认收到了校方邮寄的EMS卷袋吗?请确保收件的EMS单号和微信系统查看到的单号一致", "信息确认", function() {
- $.showLoading("正在提交确认信息...")
- $rootScope.ajaxRequest({
- url : '../enrol/std/enrol/ems/confirm.htm',
- data : {
- enrol_id : $stateParams.enrol_id
- }
- }, function(response) {
- $.hideLoading();
- $scope.getEnrol();
- });
- }, function() {
- // 取消操作
- });
- }
-
- $scope.goReturn = function(enrol) {
- var std_ems_id = $scope.EnrolMap.StdEnrol.std_ems_code;
- std_ems_id = $.trim(std_ems_id);
- if(std_ems_id.length == 0) {
- $.alert('请输入发件EMS单号');
- return;
- }
- if(std_ems_id.length != 13) {
- $.alert('请输入正确的EMS单号');
- return;
- }
-
- $.confirm("请确定发件EMS号码无误!", "信息确认", function() {
- $.showLoading("正在提交确认信息...")
- $rootScope.ajaxRequest({
- url : '../enrol/std/enrol/ems/return.htm',
- data : {
- enrol_id : $stateParams.enrol_id,
- std_ems_id:std_ems_id
- }
- }, function(response) {
- $.hideLoading();
- $scope.getEnrol();
- $.alert('发件EMS单号已保存!');
- });
- }, function() {
- // 取消操作
- });
- }
- } ])
|