Base solution for your next web application

Activities of "alfar_re"

Answer

Hi,

Nothing has changed in locolization.

Question

Hi,

I recently added the timezone code to enable selection of timezone under settings. I also enabled hangfire successfully. However, everything on the system now displays with square brackets like so [Settings header info]

What would be the problem and how do I resolve?

Answer

This actually worked. Thank you.

Question

Hi,

I cannot seem to find the Timezone setting on the Host account. I would like to know how to set this up.

Hi,

Each time I make changes to the entity structure, all changes, including the code added to the services gets lost. How can I prevent this?

Hi,

I actually changed all filter methods and removed the ToString()where the property was a string and it worked well.

Allow me to close this now. Many thanks for the help. Cheers!

Hi,

InvoiceNumber is actually a string. And the same issue is occuring in almost all look up tables.

Here you go. That's the entire code block.

var query = _lookup_rentalInvoiceRepository.GetAll().WhereIf(
		!string.IsNullOrWhiteSpace(input.Filter),
	   e=> e.InvoiceNumber.ToString().Contains(input.Filter)
	);

var totalCount = await query.CountAsync();

var rentalInvoiceList = await query
	.PageBy(input)
	.ToListAsync();

var lookupTableDtoList = new List<TransactionRentalInvoiceLookupTableDto>();
foreach(var rentalInvoice in rentalInvoiceList){
	lookupTableDtoList.Add(new TransactionRentalInvoiceLookupTableDto
	{
		Id = rentalInvoice.Id,
		DisplayName = string.Format(rentalInvoice.InvoiceNumber?.ToString(), " - ", rentalInvoice.Description, "(", rentalInvoice.Status, ")")
	});
}

return new PagedResultDto<TransactionRentalInvoiceLookupTableDto>(
	totalCount,
	lookupTableDtoList
);

Hi,

What I was experiencing is that once I open that specific index page, I get that loading message and it stops there, loads no data. I was able to regenerate the entity and clean the solution and the index now displays the data as it should. However, this was after several attempts.

Previous title: LOOK UP TABLE ISSUE

Hi,

Am getting this error on the filter on look up tables.

System.InvalidOperationException: The LINQ expression 'DbSet<RentalInvoice> .Where(r => __ef_filter__p_0 || !(((ISoftDelete)r).IsDeleted) && __ef_filter__p_1 || (Nullable<int>)((IMustHaveTenant)r).TenantId == __ef_filter__CurrentTenantId_2) .Where(r => r.InvoiceNumber.ToString().Contains(__input_Filter_0))' could not be translated. Either rewrite the query in a form that can be translated, or switch to client evaluation explicitly by inserting a call to either AsEnumerable(), AsAsyncEnumerable(), ToList(), or ToListAsync(). See https://go.microsoft.com/fwlink/?linkid=2101038 for more information. at Microsoft.EntityFrameworkCore.Query.QueryableMethodTranslatingExpressionVisitor.<VisitMethodCall>g__CheckTranslated|8_0(ShapedQueryExpression translated, <>c__DisplayClass8_0& ) at Microsoft.EntityFrameworkCore.Query.QueryableMethodTranslatingExpressionVisitor.VisitMethodCall(MethodCallExpression methodCallExpression) at Microsoft.EntityFrameworkCore.Query.RelationalQueryableMethodTranslatingExpressionVisitor.VisitMethodCall(MethodCallExpression methodCallExpression) at Microsoft.EntityFrameworkCore.Query.QueryableMethodTranslatingExpressionVisitor.VisitMethodCall(MethodCallExpression methodCallExpression) at Microsoft.EntityFrameworkCore.Query.RelationalQueryableMethodTranslatingExpressionVisitor.VisitMethodCall(MethodCallExpression methodCallExpression) at Microsoft.EntityFrameworkCore.Query.QueryCompilationContext.CreateQueryExecutor[TResult](Expression query) at Microsoft.EntityFrameworkCore.Storage.Database.CompileQuery[TResult](Expression query, Boolean async) at Microsoft.EntityFrameworkCore.Query.Internal.QueryCompiler.CompileQueryCore[TResult](IDatabase database, Expression query, IModel model, Boolean async) at Microsoft.EntityFrameworkCore.Query.Internal.QueryCompiler.<>c__DisplayClass12_0`1.

Showing 111 to 120 of 138 entries