Base solution for your next web application
Starts in:
01 DAYS
01 HRS
01 MIN
01 SEC

Activities of "marble68"

I really want to go to azure - and I know it can be cheap to start - but the pricing calculator seems to be a black art.

I'm curious what real world looks like? 50 users?

Heavy API usage?

I've reviewed: https://aspnetboilerplate.com/Pages/Documents/Navigation, that doesn't really answer my question

I've crawled through abp.nav.menus.App - and I can see the menu items there.

What I can't figure out is how to, once an entity is saved, go back to the entities main menu item.

How is that done?

Currently, I check in my branch, regenerate, then go through the changes to move my modifications into the updated files.

Is this the best way? What do other people do?

is there a easier, faster way?

I have entites that have start and stop times.

Do I store the time zone as a string? timeZoneId?

Using the SubscriptionExpireEmailNotifierWorker as a template, I've created a worker.

When it runs, it tries to call GetAll from a repository and I get an ObjectDisposedException error.

This is my worker:

  public class MyWorker : PeriodicBackgroundWorkerBase, ISingletonDependency
    {

        private const int CheckPeriodAsMilliseconds = 1000 * 1 * 60 * 30; // 30 minutes

        private readonly IWebUrlService _webUrlService;
        private readonly IRepository<Employee, Guid> _employeeRepository;

        public MyWorker(
                AbpTimer timer,
                IRepository<Employee, Guid> employeeRepository
                ) : base(timer)
        {

            _employeeRepository = employeeRepository;

            Timer.Period = CheckPeriodAsMilliseconds;
            Timer.RunOnStart = true;

        }

        protected override void DoWork()
        {
            List<Employee> e = _employeeRepository.GetAll().ToList();

            int c = e.Count();
        }
    }

This is the error I get:

System.ObjectDisposedException: 'Cannot access a disposed object. A common cause of this error is disposing a context that was resolved from dependency injection and then later trying to use the same context instance elsewhere in your application. This may occur if you are calling Dispose() on the context, or wrapping the context in a using statement. If you are using dependency injection, you should let the dependency injection container take care of disposing context instances. Object name: 'workDbContext'.'

This in the MVC startup, I register the worker like this:

workManager.Add(IocManager.Resolve<MyWorker>());

What am I missing?

Thanks!

  1. If I create a domain service, do I put that class in the Application project? If not, where? Core, Core.Shared? Application.Shared?

  2. If I need this domain service to be usable by the Public website (for getting and updating entities), is that still the correct location? If not, where? Web.Core?

  3. If the public website needs to update an entity based on input from a browing user that is NOT logged in, will a simple unit of work allow that to happen?

  4. Does this unit of work need to exist in the Public controller or in the domain service?

Thanks!

I have a controller with a method where the ID of the entity is passed.

In my development environment, I can get the entity with no problems like this:


EmployeeDto employee = _employeesAppService.GetEmployeeForView(_id).Result.Employee;

Everything works great... unless I'm running in production.

In the MVC side, this function is called without issue.

For my public controller, I have:

So I deployed to producdtion, and I get an error saying there's no Entity by the ID.

I've verified I'm passing the correct ID, and I can see the ID in the database.


System.AggregateException: One or more errors occurred. (There is no such an entity. Entity type: okto.work.Survey.Employee, id: c6e010e3-f4d6-4241-c350-08d80a7ba1e1)

 ---> Abp.Domain.Entities.EntityNotFoundException: There is no such an entity. Entity type: okto.work.Survey.Employee, id: c6e010e3-f4d6-4241-c350-08d80a7ba1e1
 
   at Abp.Domain.Repositories.AbpRepositoryBase`2.GetAsync(TPrimaryKey id)
   
   at Abp.Domain.Uow.UnitOfWorkInterceptor.InternalInterceptAsynchronous[TResult](IInvocation invocation)
   
   at okto.work.Survey.EmployeesAppService.GetEmployeeForView(Guid id) in C:\Program Files (x86)\Go Agent\pipelines\StagingPipeline\src\okto.work.Application\Survey\EmployeesAppService.cs:line 101
   
   

Am I missing something simple?

Any suggestions will be helpful.

But in the MVC, I want to get a setting while in a controller.

I'm running 8.7, Jquery

Specifically, I'm after the setting WebSiteRootAddress

somthing like:


string myUrl = "";
string myUrl += <get WebSiteRootAddress from appsettings.json>; // <-- How do I do this?
string myUrl += "/Take/" + employee.Id;
ViewBag.myUrl = myUrl;

Thanks.

So I'm trying to setup a CD on a staging server, and everything is working except my dotnet build doesn't generate bundles.

Obviously - these aren't in source control; but everything needed to do it is.

I've got npm, yarn, gulp, etc. on my staging server.

I'm using GoCD (in case that matters).

Has anyone ever done this, or with ANZ do we have to it manually every time?

Thanks for any advice.

In my solution, when an tenant signs up - I'd like to define 4 roles with predefined permissions.

Level 1 Level 2 (Which has all permissions of level 1 + some) Level 3 (which has all permissiosn of level 2 + some) Level 4 (which is level 3 + some).

So, when a tenant signs up, these roles already exist and permissions already exist and cannot be modified. Then I'd remove the permission to modify roles at the host level.

This way, when users are added, they are, by default, in the Level 1 role.

I've accomplished this to this point.

However, In the event I want to allow a tenant to create new roles so they can name them what they want, how do I hide permissions from them (much like the Editions Features)?

Would I clone the GetUserPermissionsForEdit in UserAppService - and then, based on if the user is a tenant, filter out the permissions I don't want them to be able to see?

Is there a better way?

From a support standpoint, if I did this, if I logged in as host then impersonated the tenant admin, I could check if the host is impersonnating their admin and then show all permissions?

Thanks for suggestions.

Showing 51 to 60 of 68 entries