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

Activities of "farhantufail"

Thank you page was initializing before server response.

Thanks alot

Yes Sure Brother. I'm sharing two screenshots with you.

ngOnInit(): void {
        const saleInvoiceId = this.route.snapshot.params.id;
        if (!saleInvoiceId) {
            this.getCreate();
        } else {
            this._saleInvoicesServiceProxy.getSaleInvoiceForEdit(saleInvoiceId).subscribe(result => {
                this.saleInvoice = result.saleInvoice;
                if (this.saleInvoice.dueDate) {
                    this.dueDate = this.saleInvoice.dueDate.toDate();
                }
                if (this.saleInvoice.approvedDate) {
                    this.approvedDate = this.saleInvoice.approvedDate.toDate();
                }
            });
        }
    }
    
    this is the code . and one thing more is I'm getting this error only when I open form for edit.
    Please reply @maliming

Dear I'm gettting this error for unknow reason.Please help me in this regard. identifier '_d' is not defined.'Moment' does not contain such a member Angular. ____

we are using product version of 7.2.3. Thanks

yes

_timeCardDetailCustomRepository variable an ITimeCardDetailRepository interface

` public interface ITimeCardDetailRepository : IRepository

    decimal CalculateDaysremoval(DateTime startDate, DateTime endDate, int employeeCode);
  
}

**Above is the Interface and blew is the implimentation **


public class TimeCardDetailRepository : ApplicationRepositoryBase

    public TimeCardDetailRepository(IDbContextProvider<ApplicationlDbContext> dbContextProvider)
            : base(dbContextProvider)
    {
        
    }
    
     public decimal CalculateDaysremoval(DateTime startDate,DateTime endDate,int employeeCode)
    {
       
        string sql = "SELECT ISNULL(SUM(CASE WHEN mark = 1 and TotalHours >= 4  THEN 0.5 WHEN mark = 1 and TotalHours < 4  THEN 1  end),0)as removalDays  FROM dbo.tabel WHERE EID = @employeeId";
    
        decimal result = 0;
        using (var con=GetDbContext().Database.GetDbConnection())
        {
              using (var command = con.CreateCommand())
                {

                    command.CommandText = sql;
                  
                 
                    command.Parameters.Add(new SqlParameter("@employeeId", employeeCode));
                    command.Parameters.Add(new SqlParameter("@fromDate", startDate));
                    command.Parameters.Add(new SqlParameter("@toDate", endDate));

                  
                    using (var dr = command.ExecuteReader())
                    {

                        if (dr.Read())
                        {
                            result = Convert.ToDecimal(dr["removalDays"]);
                        }
                    }
                }
               
            
           
        }
       
        return result;
    }
}

}

      public class PayrollManager : ApplicationServiceBase, IDomainService
        {
        public SalarySheet CreateSalary(int employeeCode,int periodId, int month, int year)
            {

              SalaryPeriod salaryPeriod = _salaryPeriodRepository.FirstOrDefault(x => x.Id == periodId);
                int startDay = salaryPeriod.FromDate.Day;
                int endDay = salaryPeriod.ToDate.Day;
             decimal daysRemoval = _timeCardDetailCustomRepository.CalculateDaysremoval(startDate, endDate, employeeCode);
            }
          }

//Custom Repository

            public class TimeCardDetailRepository : ApplicationRepositoryBase&lt;TimeCardDetail&gt;,ITimeCardDetailRepository
        {
            IConfigurationRoot configuration = AppConfigurations.Get(WebContentDirectoryFinder.CalculateContentRootFolder(), addUserSecrets: true);



            public TimeCardDetailRepository(IDbContextProvider&lt;ApplicationContext&gt; dbContextProvider)
                    : base(dbContextProvider)
            {

            }


            public decimal CalculateDaysremoval(DateTime startDate,DateTime endDate,int employeeCode)
            {

                string sql = "SELECT ISNULL(SUM(CASE WHEN mark = 1 and TotalHours >= 4  THEN 0.5 WHEN mark = 1 and TotalHours < 4  THEN 1  end),0)as removalDays  FROM dbo.tabel WHERE EID = @employeeId";

                decimal result = 0;
                using (var con=GetDbContext().Database.GetDbConnection())
                {
                      using (var command = con.CreateCommand())
                        {

                            command.CommandText = sql;

                            command.Parameters.Add(new SqlParameter("@employeeId", employeeCode));



                            using (var dr = command.ExecuteReader())
                            {

                                if (dr.Read())
                                {
                                    result = Convert.ToDecimal(dr["removalDays"]);
                                }
                            }
                        }



                }

                return result;
            }




        }
        
        
        
        
        

It throws this exception.

My Question is that how can we Pass the transection from Domain Service to Custom repository Method ? In Cutome repository method we want to use Pure Ado.net because we have a alot of views from getting data and we can not map every view to EF Core keyless Entity type.

As Domain Services already Implemnet UnitOfWork by default in ABP and we jsut want to pass the transection used by UnitOfWork in Cutom repo methods or any work around to implement this behaviour?

Question

I encountered this problem when I tried to update service proxies class in my angular project.

Please guide me to solvemy problem.

Thanks.Issue solved.

work around

I've solved issue by changing .min.css to .css in dynamicresourceHelper.ts of these files.

  1. metronic-customize-angular.min.css -> to -> metronic-customize-angular.css
  2. /styles/metronic-customize.min.css' -> to -> /styles/metronic-customize.css'
  3. /css/style.bundle.min.css -> to -> /css/style.bundle.css
  4. themes/' + theme + '/metronic-customize.min.css -> to -> themes/' + theme + '/metronic-customize.css

Hi,Ive downloaded new angular project of latest version that is 7.2.3. when i run my project, I'm getting this error.Please guide me solve this problem.Thanks

It worked & That's great.Thanks alot dear .

Showing 11 to 20 of 28 entries