Base solution for your next web application

Activities of "gvb"

Hi,

I'm trying to create an app with Abp.Zero for authentication, but unfortunatly nothing work from your sample.

Taskever -> doesn't build after downloading -> restore nugget... 14 error from DLL...

Is it possible to have a true tutorial or a true sample project that really work... even the web site doesn't work and i receive Internal Server Error....

i really want to make it work but there is no resource that i found that help me to create the basic thing LOGIN / REGISTER / ROLE....

nothing more....

is it possible to have a tutorial or having someone to help to make the basic login-reigster-role work in a new project ?

thx in advance

the project work and i will try to take it as example!

Continue your great work! Can't wait for the documentation :D

thx a lot

Is it possible to know how to configure the setting for the SMTP service?

I know i need to inject the service in the ApplicationService, but how do i configure which server to use and credential or port?

thx in advance!

I didn't find anything usefull in ISettingManager by creating a class then heritate ISettingManager....

The only thing i found usefull is ISmtpEmailSenderConfiguration but i dont know how to use it.... and how to link ISettingManager and ISmtpEmailSenderConfiguration!?

i just found in the doc this part, why configure it there if there is a ISmtpEmailSenderConfiguration?

public override IEnumerable<SettingDefinition> GetSettingDefinitions(SettingDefinitionProviderContext context)
    {
        return new[]
                {
                    new SettingDefinition(
                        "SmtpServerAddress",
                        "127.0.0.1"
                        ),
            ...
    }
Question

hey,

i'm trying to put my initial data in Seed method and the creatorId from IFullAudited nevver get filled with my data.... And I dont understand why my context is getting 0 user from the context when i just saved 3 person in it.... and my db show them....

here is my code in a Seeder class... in the database the CreatorUserId = null .... like WTF? i tried with putting 1.... same result i get null in db... how is it fucking possible that my ID that i put become null ? or why i cant get my users from my context.... i did my SaveChange....

i tried with a _context.Users.First() after the save.... and still it throw no item in the sequence....

and the adminUserForDefaultTenant give me ID 3 when i put a throw new Exception(adminUserForDefaultTenant.Id.ToString()) after the SaveChange... so why it doesn't register as CreatorId 3 when i put it in my NewsCategory?

can anyone help ?

adminUserForDefaultTenant = _context.Users.Add(
                    new User
                    {
                        TenantId = defaultTenant.Id,
                        UserName = "admin",
                        Name = "System",
                        Surname = "Administrator",
                        EmailAddress = "[email protected]",
                        IsEmailConfirmed = true,
                        Password = "AM4OLBpptxBYmM79lGOX9egzZk3vIQU3d/gFCJzaBjAPXzYIK3tQ2N7X4fcrHtElTw==" //123qwe
                    });
                _context.SaveChanges();

                _context.NewsCategory.Add(new NewsCategory
                {
                    Category = "Framework",
                    CreationTime = DateTime.Now,
                    CreatorUserId = adminUserForDefaultTenant.Id,
                    IsDeleted = false,
                });
                _context.SaveChanges();

Ok so i found my solution in the AbpZeroSample

The solution is to create your Entity First then SaveChange and finaly put the CreatorUserId to SaveChange again.

If someone else get this problem!

But someone can explain why i cannot find any user in my _context.Users? i want to be able to get my user created by Seeder in my other Seeding class without keeping them in a SeederDto :S

Here is the modified code :

adminUserForDefaultTenant = _context.Users.Add(
                    new User
                    {
                        TenantId = defaultTenant.Id,
                        UserName = "admin",
                        Name = "System",
                        Surname = "Administrator",
                        EmailAddress = "[email protected]",
                        IsEmailConfirmed = true,
                        Password = "AM4OLBpptxBYmM79lGOX9egzZk3vIQU3d/gFCJzaBjAPXzYIK3tQ2N7X4fcrHtElTw==" //123qwe
                    });
                _context.SaveChanges();

                var category  = _context.NewsCategory.Add(new NewsCategory
                {
                    Category = "Framework",
                    CreationTime = DateTime.Now,
                    IsDeleted = false,
                });
                _context.SaveChanges();

                category.CreatorUserId = adminRoleForDefaultTenant.Id;

                _context.SaveChanges();

Hi,

I'm trying to make a list of my entity and it seem's that i cannot get the entities where the IsDeleted = true

_repoNews.GetAll().Where(x => x.IsDeleted == true).ToList().Count always return 0 but i have at least 1 entity that is Deleted.

Is there a way to get the IsDeleted = true ?

I found that ISoftDelete say ->

/// <summary> /// Used to standardize soft deleting entities. /// Soft-delete entities are not actually deleted, /// marked as IsDeleted = true in the database, /// but can not be retrieved to the application. /// /// </summary>

Is there a way to deactive this for a request?

The thing i wanna make is a list where I see all my entity and see if they are active / inactive (!deleted or deleted) and i want to be able to reactive an entity IsDeleted = true to IsDeleted = false

Any idea on how to remove the filter SoftDelete from IRepository query ?

hey,

I solved this problem with those things :

In BundleConfig.cs Change the code for the Bundle/App/vendor/css by this code, i kept the old code in comment to show what happenned:

//~/Bundles/App/vendor/css
            bundles.Add(
                new StyleBundle("~/Bundles/App/vendor/css")
                    .Include(
                        //"~/Content/themes/base/all.css",
                        "~/Content/bootstrap-cosmo.min.css",
                        "~/Content/toastr.min.css",
                        "~/Scripts/sweetalert/sweet-alert.css"//,
                        //"~/Content/flags/famfamfam-flags.css",
                        //"~/Content/css/font-awesome.min.css"
                    )
                );

            bundles.Add(
                new StyleBundle("~/Content/themes/base/css")
                    .Include(
                        "~/Content/themes/base/all.css"
                    )
                );

            bundles.Add(
                new StyleBundle("~/Content/flags/css")
                .Include(
                    "~/Content/flags/famfamfam-flags.css"
                )
            );

            bundles.Add(
                new StyleBundle("~/fonts/css")
                .Include("~/Content/css/font-awesome.min.css"));

The problem is there is relative reference in those scripts, so we need to keep the same architecture so they can keep their relative path correct. Dont forget to add those new bundle in yours layout.

This will correct so errors but we need to change other things too!

In the WebConfig we need to add a section to tell IIS that we know those MIME type (Font-Awesome) and what they really are...

<system.webServer>
   ....

    <staticContent>
      <remove fileExtension=".svg" />
      <remove fileExtension=".eot" />
      <remove fileExtension=".woff" />
      <mimeMap fileExtension=".svg" mimeType="image/svg+xml" />
      <mimeMap fileExtension=".eot" mimeType="application/vnd.ms-fontobject" />
      <mimeMap fileExtension=".woff" mimeType="application/font-woff" />
      <mimeMap fileExtension=".woff2" mimeType="application/font-woff" />
    </staticContent>

...
  </system.webServer>

And one last thing i've done is adding this line in my layout head:

&lt;base href=&quot;@Url.Content(&quot;~/&quot;)&quot; /&gt;

I think it's all you need to remove those errors!

Just show an other screenshot if something is not working properly i might forgot 1 step :)

Calling dbContext.DisableAllFilters() doesn't work either

i wan't to be able to put the creatorid IN the entity creation....

here is my code and it still doesn't create my entity with my adminId..... plz help me on this....

if (!_dto.Context.NewsCategory.Any())
            {
               _dto.Context.DisableAllFilters();

                var framework = _dto.Context.NewsCategory.Add(new NewsCategory
                {
                    Category = "Framework",
                    CreationTime = DateTime.Now,
                    CreatorUserId = _dto.AdminId.Value,
                    IsDeleted = false
                });

                _dto.Context.SaveChanges();

CreatorUserId = NULL in the DB......

and if i save the entity without the ID and save it after the Context.SaveChanges() then the LastModifiedTime is fullfilled and if i set the LastModifierUserId to the admin while assigning the CreatorId ...... the fucking LastModifierUserId = null

Serious....is there a way to achieve it ..?

Showing 1 to 10 of 53 entries