示例#1
0
        private UserResponse UserResponseError(Constants.ErrorCodes error)
        {
            string errorMessage = String.Format(
                AppGlobal.Language.GetText(this, error.ToString(),
                                           "Log in failed for DfE Secure Access. Invalid log in - error code {0}. If you believe you should have access to the Post 16 Provider Portal please contact the DfE Support Team on <a href='tel:08448115028'>0844 8115 028</a> or <a href='mailto:[email protected]'>[email protected]</a>."),
                (int)error);

            return(new UserResponse(null, errorMessage));
        }
示例#2
0
        private WebProviderError CreateProviderError(Constants.ErrorCodes errorCode)
        {
            string message = Constants.UnknownError;

            switch (errorCode)
            {
            case Constants.ErrorCodes.InvalidPassword:
                message = Constants.InvalidPassword;
                break;

            case Constants.ErrorCodes.Unknown:
                break;

            case Constants.ErrorCodes.AddAccountFailed:
                message = Constants.AddAccountFailed;
                break;

            default:
                Debug.Assert(false);
                break;
            }
            return(new WebProviderError((uint)errorCode, message));
        }