Base solution for your next web application

Activities of "alper"

Hi,

This enhancement has been completed. You can check out how to overcome the issue. Head to the link below <a class="postlink" href="https://github.com/aspnetboilerplate/module-zero/issues/352">https://github.com/aspnetboilerplate/mo ... issues/352</a>

Hi, Answers to your questions;

Question 1) Are multiple app service calls permitted by the ABP template from a modal? Answer 1) Yes! There's no limit to call different app services in the modal.

Question 2) Do i need to wrap all the sections, address, personal and contact into one view model and then use the single save button for the modal to post the data back to each respective app service for each section? Answer 2) If you want to focus on performance, you should create one app service method for all your savings. But if you want reusablity then you should create different app services for your each sub entities. (Btw if the sub entities need to get a parent entity id, you have to consider the priority of ajax calls.)

Hi My answers;

  1. Use the composive Primary Key in EF. I have seen many samples with only one column in TPrimaryKey in Repository.
  • As Entity Framework allows Composite Primary Keys, ABP has also allows it.
[Column(Order = 1), Key, ForeignKey("MyForeignKey")]
    public int Field1 { get; set; }
    [Column(Order = 2), Key, ForeignKey("MyForeignKey")]
    public string Field2 { get; set; }
  1. The column's name of Primary Key is required call "Id".

Id column is required to use some rich features with IRepository<T>... If you don't want to use ABP's built-in repository features then there's no requirement for Id field.

hi,

Using tranlation xml files is not suitable for this kind of development. Because translation files are purposed to localize UI texts not client entry data.

I'd go like this, let's say you have Question entity. I'd create QuestionTranslations with columns (QuestionId, LanguageCode, Text) And you can allow admins to enter translations. (better way is integrating with google translate to help the admins for inspiring) When a new language comes, the problem is still there with the 2 approaches . Somebody must translate the old questions.

hi

Why don't you use DTO. Just create a new class (dto) with the properties you want to update. At your controller or application service method use this dto as parameter. When you map dto to database entity, only the properties in the dto object will be updated and rest will be the same. This is simple and good practise.

Note: I assume you know and use dto mapping (eg: automapper)

can you provide the console log output of IE11?

For MVC project;

Create a new application service and write the method below. On the client

public async Task<GetUserOrganizationOutput> GetUserNotifications()
{

            var userIdentifier = new UserIdentifier(AbpSession.TenantId, AbpSession.UserId.Value);
            var organizationUnits= AsyncHelper.RunSync(() => UserManager.GetOrganizationUnitsAsync(UserManager.GetUser(userIdentifier)));
            var firstOrganization = organizationUnits.FirstOrDefault();

            if (firstOrganization != null)
            {
                //you have to map firstOrganization to dto and send the dto to client.
                return new GetUserOrganizationOutput() {Organization = firstOrganization};
            }

            return null;
}

If you are using MVC project, Call this application service in _Header.js and set to html with jquery. If you are using angular, you can call the service from header.component.ts

Answer

Hi, i guess it's not related to Asp.Net Zero. You can post the problem on DevExtreme forum as they know their product better.

Hi,

I have not any experience on Certificate based authentication. But some folks seem to implement on the following links; Give it a try

how-to-authenticate-with-certificates-instead-of-passwords

custom-authentication-and-authorization-based-on-user-rights

claim-based-authorization-design-for-conditional-edit-operation-in-asp-net-mvc

The response is being wrapped by MvcAjaxResponse for MVC and AjaxResponse for Web API. And the real result object is being sent to client as Result property of the response. You can add a attribute to suppress response wrapping for MVC and Web API . There are 2 attributes for that purpose: WrapResultand DontWrapResult. So basically you have to use DontWrapResult.

Click here to to see the issue for the case

Showing 1 to 10 of 1377 entries