Base solution for your next web application

Activities of "mhdevelop"

Hello, I want to use non modal page with standard asp.net core validations. When I run this code I get validation error insted of screen updating with error message. I have gone through how to convert model page to standard, but not able to figure out. This is very important in situation where we have complex UI to build and not seen any samples. Here is simple example to create a category.

<div id="details" style="height:100%"> @using (Html.BeginForm()) { @Html.AntiForgeryToken()

    &lt;div class=&quot;form-horizontal&quot;&gt;
        &lt;h4&gt; Category &lt;/h4&gt;
        &lt;hr /&gt;
        @Html.ValidationSummary(true, "", new { @class = "text-danger" })
        @Html.HiddenFor(model => model.CategoryId)

        &lt;div class=&quot;form-group&quot;&gt;
            @Html.LabelFor(model => model.CategoryName, htmlAttributes: new { @class = "control-label col-md-2" })
            &lt;div class=&quot;col-md-10&quot;&gt;
                @Html.EditorFor(model => model.CategoryName, new { htmlAttributes = new { @class = "form-control" } })
                @Html.ValidationMessageFor(model => model.CategoryName, "", new { @class = "text-danger" })
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-group&quot;&gt;
            @Html.LabelFor(model => model.Description, htmlAttributes: new { @class = "control-label col-md-2" })
            &lt;div class=&quot;col-md-10&quot;&gt;
                @Html.EditorFor(model => model.Description, new { htmlAttributes = new { @class = "form-control" } })
                @Html.ValidationMessageFor(model => model.Description, "", new { @class = "text-danger"})
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class=&quot;form-group&quot;&gt;
            &lt;div class=&quot;col-md-offset-2 col-md-10&quot;&gt;
                &lt;input type=&quot;submit&quot; value=&quot;Save&quot; class=&quot;btn btn-default&quot; /&gt;
            &lt;/div&gt;
        &lt;/div&gt;
    &lt;/div&gt;
}

&lt;div&gt;
    @Html.ActionLink("Back to List", "Index")
&lt;/div&gt;

</div>

The Category Class [Key] [Column("CategoryID")] public int CategoryId { get; set; }

    [Required]
    [StringLength(15)]
    public string CategoryName { get; set; }
    
    [Column(TypeName = "ntext")]
    public string Description { get; set; }

Thanks for any help with example insted of pointing to standard documentation, which I have already tried.

Thanks V

Hello, I have a situation where i need to inject or access my EF DbContext from controller, please let me know how to access it . I have tried the below var ctx = IocManager.Instance.Resolve<PLCMDbContext>(); it gives error that it had depedency on options

Also I tried controller construction inject and get same error. public constructor( IDbContextProvider<MyDbContext> dbContextProvider) { _ctx = dbContextProvider.GetDbContext(); }

get same error message.

Thanks

Hello, This document does not tell how to use it from asp.net zero menu system. Netzero has two items in menu

  • Dyamic Parameter
  • Dyanamic Entity Parameter

I create dyamaic parameter color. Then went to Dyanamic entity parameter, the list is showing only "USER" as entity. Why it is not showing other entities. Once i added "color" paramter to "User Entity" and go to User Management and Edit I do not see that parameter to fill it.

Is there documentation showing how to use NON Coding method of Dyanamic Parameters?

Hello,

We are building intranet application which we need to implemEnt ad authentication for employees and forms authentication for temporary users. How can I achieve this with asp.net zero. based on username let us say employees use email Id and teMPorary employees use non email ad, hoe do I authenticate both? One with DB and other with AD.

Thanks V

Seems like two issues are caused when using abp controller as base

  1. When I just read json file and send content, additional fields are getting appended, how to override this functionality only for certail Action Methods?
public IActionResult ChangeOrder\_Read([DataSourceRequest] DataSourceRequest request)
{
    return Ok(System.IO.File.ReadAllText(@"Test.json"));
}
Contents of File:
{
"Data": [
    {
    "CatalogNumber": "Catalog 12345",
    "UsageCode": "Usage Code 1"
    },
    {
    "CatalogNumber": "Catalog 8234758",
    "UsageCode": "Usage Code 2"
    }
],
"Total": 0,
"AggregateResults": null,
"Errors": null
}
The data returned (abp added additional data, which causes kenddo grid not bind")
    {"result":"{\r\n  \"Data\": [\r\n    {\r\n      \"CatalogNumber\": \"Catalog 12345\",\r\n      \"UsageCode\": \"Usage Code 1\"\r\n    },\r\n    {\r\n      \"CatalogNumber\": \"Catalog 8234758\",\r\n                  \"UsageCode\": \"Usage Code 2\"\r\n\r\n    }\r\n\r\n  ],\r\n  \"Total\": 0,\r\n  \"AggregateResults\": null,\r\n  \"Errors\": null\r\n}","targetUrl":null,"success":true,"error":null,"unAuthorizedRequest":false,"__abp":true}
    
Question

Hello,

We have purchased the Enterprise version to develop web application for use within our enterprise. There is lot of things I do not need

like multitenanacy, hosts, subscription etc along with all the themes. It would be nice if there is a way to download clean product without all these features for use in enterprise. It would be helpfull for your other customers if you create a product download with these options removed. There is too much java script libraries and styles.

For enterpise application I use 3rd party controls like Telerik. How do i integrate with Asp Net Zero. here is the link to how to setup. https://docs.telerik.com/aspnet-core/getting-started/first-steps?&_ga=2.42610732.865333513.1583952345-227682398.1578063781#configuration

How can I reduct all this huge amount of CSS and java scripts getting downloaded to client?

Style.bundle.css - is 1.23 mb app-layout-libs.min.js is 4.1 mb

Any help greatly appreciated

Thanks Vee

The getting started guide talks only Visual studio 2017. Will the solution compile and work in 2019. What are steps with 2019?

I have installed Node.js with npm latest Installed yarn latest Earn yarn at mvc folder Changed connecting string Ran update-database the ssolution runs but it seems css and Java script is not applied correctly . The login button does not work and change tenent does not work. I see some errors in npm_node packages list saying some packages not found. Please let me know hoe to solve the issue.

Thanks Vee

Showing 1 to 7 of 7 entries