EngincanV的活动

Hi @repunjay, you can find the users login date and time by checking the Action (LoginSucceded) field of the Security Logs page.

You can use IIdentitySecurityLogRepository to list it in your application service.

Also you can use the IIdentitySecurityLogRepository to get your inactive (dormant) users in specified time-range. (Maybe you can get the logged out users (by specifying the action as Logout) and check the user logged in 'x' days)

Hi @zsanhong, in your case the url should be => @page "/Cms/Pages/ViewModel/{id:guid}" Because you need the Id parameter.

Please check the razor page documentation.

Hi, you can override the modal you want by creating the same .cshtml file under the same path and replace the code-blocks by your needs.

For example, lets assume you want to change the save button's text of the Identity/User/EditModal.cshtml. You need to create the cshtml file in the same path (Pages/Identity/Users/EditModal.cshtml) and copy the original .cshtml file of the module and paste it into your page, then make the necessary changes.

...
        <div class="modal-footer">
            <button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>
            <button type="button" class="btn btn-primary">Submit</button> @* Save button text changed as Submit *@
        </div>
...

For more information about Customizing UI, please check the documentation.

Can you add the [UnitOfWork] attribute to above of your method and try it again?

Hi @zsanhong, please check your View.cshtml file's @page attribute for routing path.

  • If you define the path like this => @page "/Cms/Pages/View" You should be able to navigate the page.

  • If you want to click the view button and redirected to the page in public web-site application. You can access the page via /pages/{slug} URL.

{
   text: l('View'),
   visible: abp.auth.isGranted('CmsKit.Pages.Update'),
   action: function (data) 
   {
      var publicWebSiteBaseUrl = "<your-public-web-site-url>"; // like "https://localhost:44304"
      window.location.href = publicWebSiteBaseUrl + `/Pages/${data.record.slug}`;
   }
},

Hi @Mohammad, can you share where you used the repository (for example, your application service method)?

Hi again @commitdeveloper1, you can not access directly to precompanyname property because you are keeping Employment as collection instead of class. In other words, you need to iterate to collection to reach its properties.

public async Task<List<EmploymentEducation>> GetListAsync(int skipCount, int maxResultCount, string sorting, string filter = null)
        {
            var queryable = await GetMongoQueryableAsync();
            return await queryable
                .WhereIf<EmploymentEducation, IMongoQueryable<EmploymentEducation>>(
                            !filter.IsNullOrWhiteSpace(),
                            //you need to iterate collection to reach its properties(prevcompanyname)
                            employment => employment.Employments.Any(x => x.PrevCompanyName.Contains(filter))
                        )
                        .OrderBy(sorting)
                        .As<IMongoQueryable<EmploymentEducation>>()
                                //.Skip(skipCount)
                                //.Take(maxResultCount)
                                .ToListAsync();
        }

Can you share your EmploymentEducationRepository class?

Yes,,here it is:

Thanks,

Can you also check your EmploymentEducationRepository class? Is it both inherit from MongoDbRepository<IMyMongoDbContext, EmploymentEducation, Guid> and IEmploymentRepository?

It's recommended.

Can you share your EmploymentEducationRepository class?

Did you add your Employment, EmploymentEducation and Education classes into your dbcontext class? (Like below)

...

public DbSet<Employment> Employments {get; set;}
public DbSet<EmploymentEducation> EmploymentEducations {get; set;}
public DbSet<Education> Educations {get; set;}

...
显示 647 个条目中的 621 到 630 个.
Made with ❤️ on ABP v8.2.0-preview Updated on 三月 25, 2024, 15:11