mirror of https://github.com/abpframework/abp.git
csharpabpc-sharpframeworkblazoraspnet-coredotnet-coreaspnetcorearchitecturesaasdomain-driven-designangularmulti-tenancy
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
37 lines
1.0 KiB
37 lines
1.0 KiB
using Microsoft.AspNetCore.Components;
|
|
using Microsoft.Extensions.Localization;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using Volo.Abp.Data;
|
|
using Volo.Abp.ObjectExtending;
|
|
|
|
namespace Volo.Abp.BlazoriseUI.Components.ObjectExtending
|
|
{
|
|
public partial class TimeExtensionProperty<TEntity, TResourceType> : ComponentBase
|
|
where TEntity : IHasExtraProperties
|
|
{
|
|
[Inject]
|
|
public IStringLocalizerFactory StringLocalizerFactory { get; set; }
|
|
|
|
[Parameter]
|
|
public TEntity Entity { get; set; }
|
|
|
|
[Parameter]
|
|
public ObjectExtensionPropertyInfo PropertyInfo { get; set; }
|
|
|
|
protected TimeSpan? Value
|
|
{
|
|
get
|
|
{
|
|
return PropertyInfo.GetInputValueOrDefault<TimeSpan?>(Entity.GetProperty(PropertyInfo.Name));
|
|
}
|
|
set
|
|
{
|
|
Entity.SetProperty(PropertyInfo.Name, value, false);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|