Base solution for your next web application

Activities of "ismcagdas"

Hi,

Normally GetScripts request should return script for defining abp.timing on client side. Can you share the response of GetScripts action ? You can check it on google chrome's developer tools -> network section.

Hi,

You can use DocumentFilter for swagger UI, please check this forum post #809@76c014ab-6bfd-4ffb-a317-f14aad11d954

If you want to hide these controllers completely, we dont have a solution for that yet. You can create an issue on aspnetboilerplate github repo <a class="postlink" href="https://github.com/aspnetboilerplate/aspnetboilerplate">https://github.com/aspnetboilerplate/aspnetboilerplate</a> and we can consider that.

Hi,

You can define an interface on your Core module like IApiVersionRetreiver which contains a method GetApiVersion(). Iimplement it on Web project and get api version from Request Header. In application service, just inject IApiVersionRetreiver and use it's GetApiVersion method.

Hi,

We haven't got such an error before. It might be because of referencing different versions of same dll in different projects in your solution.

Can you share your custom repository, domain service and app service methods ? So, we can try to catch same exception.

Yes, you are right. But there might be some errors after upgrade and you need to deal with them which might takes some time.

Hi,

First of all I got this solution from <a class="postlink" href="http://stackoverflow.com/questions/36330675/get-users-email-from-twitter-api-for-external-login-authentication-asp-net-mvc">http://stackoverflow.com/questions/3633 ... sp-net-mvc</a>.

It seems like twitter does not return email address when user authanticates over twitter. You need to get email address from twitter after user allows your app for his/her account.

To do that,

1)Go to <a class="postlink" href="https://apps.twitter.com">https://apps.twitter.com</a> and under Permissions tab of your app, select "Request email addresses from users" checkbox on the bottom of page if you haven't alread done it. (It requires yo to provide Privacy Policy URL and Terms of Service URL but you can provide fake url's for test purposes).

  1. Set Provider property of TwitterAuthenticationOptions like this,
Provider = new TwitterAuthenticationProvider
{
    OnAuthenticated = (context) =>
    {
        context.Identity.AddClaim(new System.Security.Claims.Claim("urn:twitter:access_token", context.AccessToken));
        context.Identity.AddClaim(new System.Security.Claims.Claim("urn:twitter:access_secret", context.AccessTokenSecret));
        return Task.FromResult(0);
    }
}
  1. in AccountController's ExternalLoginCallback action, you need to make a second request to twitter in order to get user's email.
if (loginInfo.Login.LoginProvider.ToLower() == "twitter")
{
    string access_token = loginInfo.ExternalIdentity.Claims.Where(x => x.Type == "urn:twitter:access_token").Select(x => x.Value).FirstOrDefault();
    string access_secret = loginInfo.ExternalIdentity.Claims.Where(x => x.Type == "urn:twitter:access_secret").Select(x => x.Value).FirstOrDefault();
    TwitterDto response = MyHelper.TwitterLogin(access_token, access_secret, ConfigurationManager.AppSettings["ExternalAuth.Twitter.ConsumerKey"], ConfigurationManager.AppSettings["ExternalAuth.Twitter.ConsumerSecret"]);
    loginInfo.Email = response.email;
}
  1. Change Validate method of RegisterViewModel to
var emailRegex = new Regex(@"^\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$");
if (!UserName.IsNullOrEmpty() && !UserName.Equals(EmailAddress) && emailRegex.IsMatch(UserName))
{
    yield return new ValidationResult("Username cannot be an email address unless it's same with your email address !");
}

You can find TwitterDto class and TwitterLogin method to get user's twitter email in related stackoverflow post. You can use a twitter library for getting user's email address. Please let us know if you have any problems while implementing this.

Hi,

v0.10.0.0 and v0.10.3.0 have some breaking changes but it's not hard to manage. You can see breaking changes here

<a class="postlink" href="https://github.com/aspnetboilerplate/aspnetboilerplate/releases/tag/v0.10.0.0">https://github.com/aspnetboilerplate/as ... /v0.10.0.0</a> <a class="postlink" href="https://github.com/aspnetboilerplate/aspnetboilerplate/releases/tag/v0.10.3.0">https://github.com/aspnetboilerplate/as ... /v0.10.3.0</a>

I suggest you to take a closer look at these two issues. <a class="postlink" href="https://github.com/aspnetboilerplate/aspnetboilerplate/issues/1175">https://github.com/aspnetboilerplate/as ... ssues/1175</a> <a class="postlink" href="https://github.com/aspnetboilerplate/aspnetboilerplate/issues/33">https://github.com/aspnetboilerplate/as ... /issues/33</a>

It's always better to update all packages if you have time for it :)

Hi,

AspNet Zero uses metronic admin4 material theme, but this theme is not angular material. It just uses angularjs and material design (css part).

Do you want to use angular material <a class="postlink" href="https://material.angularjs.org/latest/">https://material.angularjs.org/latest/</a> ? If so, you need to include angular material javascript and css files to AspNet Zero solution. You can take a look at here for example <a class="postlink" href="https://material.angularjs.org/latest/getting-started">https://material.angularjs.org/latest/getting-started</a>.

Then you need to include 'ngMaterial' in app.js like below

var appModule = angular.module("app", [
    "ui.router",
    ........
    "ngMaterial"
]);

Then you can use angular material components in your project.

A note: We didn't try angular material with AspNet Zero, there might be some css or javascript errors when you do it. We can also help you with that.

Hi,

You need to generate recaptcha keys and replace them with the ones in your web.config file. you can create it here <a class="postlink" href="https://www.google.com/recaptcha/admin#list">https://www.google.com/recaptcha/admin#list</a>

Hi,

Just build abp on your local machine and replace nuget references on your project with local abp dll references. Of course, the class you want to debug should be opened in visual studio with your project.

Showing 12451 to 12460 of 12723 entries