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

Activities of "sampath"

Hi, Thanks for the feedback.I have an one question though.Can you tell me where we have to put below mentioned declarations ? Is that within our *.ts file or somewhere else globally ?

declare var appModule: angular.IModule;
declare var abp: any;
declare var app: any;

Hi, Awesome ! , Thanks a lot.I'll give a try and will let you know :)

Hi, Yes,that is fine.I just need to inform all the registered users about the system down time before it happens (before 1 hour ).Can you give me a small direction how to start this ? Can I set this to host admin to do this job or any dash board kind of thing or else ? Thanks.

Hi, I have a requirement where need to send the emails to all the registered users of the app (including tenants users) to notify about the system downtime due to data migration or something like that.Can I use Abp's Notification System or Hangfire or something like that ? If so please let me know how to do that ? Thanks.

Hi, There is a "IPLegacyDataModule.cs" file also on the Entity framework layer.It's like this.

/// <summary>
        /// Entity framework module of the application.
        /// </summary>
        [DependsOn(typeof(AbpZeroEntityFrameworkModule), typeof(IPCoreModule))]
        public class IPDataModule : AbpModule
        {
            public override void PreInitialize()
            {
                //web.config (or app.config for non-web projects) file should containt a connection string named "Default".
                Configuration.DefaultNameOrConnectionString = "Legacy";
            }

            public override void Initialize()
            {
                IocManager.RegisterAssemblyByConvention(Assembly.GetExecutingAssembly());
            }
        }

Hi, Do you have something to share it with me ? Thanks.

Hi, I have implemented it as shown below.But it gives the same error.May be I have implemented it wrongly. Please see that.

Note : I have tried by giving this also "IpLegacyDbContext" instead of the "IpDbContext" .But the same error.May be fundamental issue where I have implemented this. Hope you'll corrected me.

ILegacyRepository.cs

public interface ILegacyRepository<TEntity, TPrimaryKey> : IRepository<TEntity, TPrimaryKey>
         where TEntity : class, IEntity<TPrimaryKey>
    {

    }

    public interface ILegacyRepository<TEntity> : IRepository<TEntity>
        where TEntity : class, IEntity<int>
    {

    }

IpLegacyRepositoryBase.cs

/// <summary>
    /// Base class for custom repositories of the application.
    /// </summary>
    /// <typeparam name="TEntity">Entity type</typeparam>
    /// <typeparam name="TPrimaryKey">Primary key type of the entity</typeparam>
    public abstract class IpLegacyRepositoryBase<TEntity, TPrimaryKey> : EfRepositoryBase<IpDbContext, TEntity, TPrimaryKey>
        where TEntity : class, IEntity<TPrimaryKey>
    {
        protected IpLegacyRepositoryBase(IDbContextProvider<IpDbContext> dbContextProvider)
            : base(dbContextProvider)
        {

        }

        //add your common methods for all repositories
    }

    /// <summary>
    /// Base class for custom repositories of the application.
    /// This is a shortcut of <see cref="IPRepositoryBase{TEntity,TPrimaryKey}"/> for <see cref="int"/> primary key.
    /// </summary>
    /// <typeparam name="TEntity">Entity type</typeparam>
    public abstract class IpLegacyRepositoryBase<TEntity> : IpLegacyRepositoryBase<TEntity, int>
        where TEntity : class, IEntity<int>
    {
        protected IpLegacyRepositoryBase(IDbContextProvider<IpDbContext> dbContextProvider)
            : base(dbContextProvider)
        {

        }

        //do not add any method here, add to the class above (since this inherits it)!!!
    }

IpLegacyDbContext.cs

[AutoRepositoryTypes(typeof(ILegacyRepository<>), typeof(ILegacyRepository<,>), typeof(IpLegacyRepositoryBase<>), typeof(IpLegacyRepositoryBase<,>))]
    public class IpLegacyDbContext : AbpZeroDbContext<Tenant, Role, User>
    {
        public IpLegacyDbContext()
            : base("Legacy")
        {
        }

        public virtual DbSet<Agent> Agents { get; set; }
        public virtual DbSet<AgentContact> AgentContacts { get; set; }

 protected override void OnModelCreating(DbModelBuilder modelBuilder)
        {
            modelBuilder.Entity<BuyerInformation>()
                .Property(e => e.Buyerpricerangelow)
                .HasPrecision(19, 4);

            modelBuilder.Entity<BuyerInformation>()
                .Property(e => e.Buyerpricerangehigh)
                .HasPrecision(19, 4);
}
}

Hi,

  1. Can you tell me which layers should I use to implement above mentioned class and interface ?

  2. If you can explain about this process or behind the scene things where it'll really help to me.Thanks.

Hi, I'm sorry.Still not clear for me.Could you tell me after the above implementation how about this line ?

public class IpLegacyDbContext : AbpZeroDbContext<Tenant, Role, User>

You have mentioned about this "ILegacyRepository<User, long>".Which place do I inject this ? Thanks.

Note : Actually this is working fine on 'version="0.8.4.0"'.I still have that copy and working fine.But anyway I have to do the changes according to the new version no.Please provide a feedback for the above query.Thanks.

Hi, I do have 1 database for both tenant and host.These contexts are used for both. I'm not using second repository interface type.Can you tell me how to do that ? We're using "IpLegacyDbContext" for retrieving the Access app's data into SQL db. That is the only job of that context.It's kind of one time usage.Thanks.

Showing 81 to 90 of 187 entries