2017-02-21 10 views
0

私はこの問題を解決しようとしていましたが、できませんでした。このボタンをクリックすると、btnVerifyWhoYou私はこの500の内部サーバーエラーを取得します。私はここで何か間違っていますか?Angular JS 500 Internal Serverエラー

これは私のAngularjsファイルです:

var myApp = angular.module('ValidateSecureEmailApp', ['ui.mask', 'ui.event', 'ui.validate']) 
.config(['$httpProvider', function ($httpProvider) { 
    $httpProvider.defaults.withCredentials = true; 
}]); 

// Config to on blur event still with the values 
myApp.config(['uiMask.ConfigProvider', function (uiMaskConfigProvider) { 
    uiMaskConfigProvider.clearOnBlur(false); 
}]); 

myApp.controller('ValidateController', ["$scope", "$http", "$window", function ($scope, $http, $window) { 

    $scope.sendForm = function() { 

     $('#btnVerifyWhoYouAre').attr('disabled', true); 
     $http(
      { 
       method: 'POST', 
       url: 'Index', 
       data: { borrower: JSON.stringify($scope.borrower) } 

      } 
      ).then(function (response) { 
       if (response.data == "Error") { 
        $scope.showfail = true; 
        $('#btnVerifyWhoYouAre').attr('disabled', false); 
      } else { 

        if (response.data == "dr") 
        { 
         $window.location.href = '/DocumentUpload/Index' 
        } 
        if (response.data == "qs") 
        { 
         $window.location.href = '/Payment/Index' 
        } 
        if (response.data == "pc") 
        { 
         $window.location.href = '/ConsentDoc/Index' 
        } 

       }  
      }, function (response) { 
       $scope.showfail = true; 
       $('#btnVerifyWhoYouAre').attr('disabled', false); 
      }); 

    }; 

これは私のルーティングファイル

最後に
namespace eMortgageApp 
{ 
    public class RouteConfig 
    { 
     public static void RegisterRoutes(RouteCollection routes) 
     { 
      routes.IgnoreRoute("{resource}.axd/{*pathInfo}"); 

      //routes.MapRoute(
      // name: "DocUploadLogin", 
      // url: "{controller}/{action}/{pc}", 
      // defaults: new { controller = "DocUploadLogin", action = "Index", id=UrlParameter.Optional } 
      //); 

      routes.MapRoute(
       name: "Default", 
       url: "{controller}/{action}/{id}", 
       defaults: new { controller = "Home", action = "Index", id = UrlParameter.Optional } 
      ); 
     } 
    } 
} 

答えて

0

では、解決策を見つけました。 AngularJSは特定のエラーを投げません。関連するすべてのフォルダとBinフォルダのすべてのファイルを更新する必要があります。

関連する問題