Class RepositoryViewModelBase<TViewModel, TEntity>
- Namespace
- HeBianGu.General.WpfControlLib
- Assembly
- HeBianGu.General.WpfControlLib.dll
直接对接模型的仓储基类
public abstract class RepositoryViewModelBase<TViewModel, TEntity> : RepositoryViewModelBase, INotifyPropertyChanged, IRepositoryViewModelBase<TEntity>, IRepositoryViewModel where TViewModel : SelectViewModel<TEntity> where TEntity : StringEntityBase, new()
Type Parameters
TViewModel
TEntity
- Inheritance
-
RepositoryViewModelBase<TViewModel, TEntity>
- Implements
-
IRepositoryViewModelBase<TEntity>
- Derived
- Inherited Members
- Extension Methods
Properties
AddCommand
public RelayCommand AddCommand { get; }
Property Value
CheckedAll
public bool CheckedAll { get; set; }
Property Value
CheckedAllCommand
public RelayCommand CheckedAllCommand { get; }
Property Value
CheckedAllCurrentPageCommand
public RelayCommand CheckedAllCurrentPageCommand { get; }
Property Value
CheckedAllFilterSourceCommand
public RelayCommand CheckedAllFilterSourceCommand { get; }
Property Value
CheckedNoneCommand
public RelayCommand CheckedNoneCommand { get; }
Property Value
ClearCommand
public RelayCommand ClearCommand { get; }
Property Value
Collection
说明
public IObservableSource<TViewModel> Collection { get; set; }
Property Value
- IObservableSource<TViewModel>
DeleteCheckedCommand
public RelayCommand DeleteCheckedCommand { get; }
Property Value
DeleteCommand
public RelayCommand DeleteCommand { get; }
Property Value
EditCommand
public RelayCommand EditCommand { get; }
Property Value
EditTransactionCommand
public TransactionCommand EditTransactionCommand { get; }
Property Value
ExportCommand
public RelayCommand ExportCommand { get; }
Property Value
GridSetCommand
public RelayCommand GridSetCommand { get; }
Property Value
IsBusy
public bool IsBusy { get; set; }
Property Value
ModelType
public Type ModelType { get; }
Property Value
NextCommand
public RelayCommand NextCommand { get; }
Property Value
PreviousCommand
public RelayCommand PreviousCommand { get; }
Property Value
PrintCommand
public RelayCommand PrintCommand { get; }
Property Value
Repository
public IStringRepository<TEntity> Repository { get; }
Property Value
- IStringRepository<TEntity>
SaveCommand
public RelayCommand SaveCommand { get; }
Property Value
UseMessage
说明
public bool UseMessage { get; set; }
Property Value
ViewCommand
public RelayCommand ViewCommand { get; }
Property Value
Methods
Add(object)
public virtual Task Add(object obj)
Parameters
obj
object
Returns
Add(params TEntity[])
public abstract Task Add(params TEntity[] ms)
Parameters
ms
TEntity[]
Returns
CanClear()
public virtual bool CanClear()
Returns
Clear(object)
public virtual Task Clear(object obj = null)
Parameters
obj
object
Returns
Delete(object)
public virtual Task Delete(object obj)
Parameters
obj
object
Returns
DeleteAllChecked(object)
protected virtual Task DeleteAllChecked(object obj)
Parameters
obj
object
Returns
Edit(object)
public virtual Task Edit(object obj)
Parameters
obj
object
Returns
Export(string)
public virtual Task Export(string path)
Parameters
path
string
Returns
GetAddModel(TEntity)
protected virtual object GetAddModel(TEntity entity)
Parameters
entity
TEntity
Returns
GetEditModel(TEntity)
protected virtual object GetEditModel(TEntity entity)
Parameters
entity
TEntity
Returns
GetIncludes()
protected virtual IEnumerable<string> GetIncludes()
Returns
GetViewModel(TEntity)
protected virtual object GetViewModel(TEntity entity)
Parameters
entity
TEntity
Returns
GridSet(object)
protected void GridSet(object obj)
Parameters
obj
object
Loaded(object)
protected override void Loaded(object obj)
Parameters
obj
object
Next()
public virtual void Next()
OnCollectionChanged(object)
protected virtual void OnCollectionChanged(object obj)
Parameters
obj
object
Previous()
public virtual void Previous()
Print()
protected virtual Task<bool> Print()
Returns
RefreshData(params string[])
public abstract void RefreshData(params string[] includes)
Parameters
includes
string[]
Save()
public virtual Task<int> Save()
Returns
View(object)
public virtual Task View(object obj)
Parameters
obj
object