public ImageEditorViewModel() { File = new File(); FileId = 0; DataUrl = string.Empty; FileName = string.Empty; }
public async Task SaveFileAsync(File file) { if (file.Id == 0) { await _fileRepository.InsertAsync(file); } else { await _fileRepository.UpdateAsync(file); } }
public void SaveFile(File file) { if (file.Id == 0) { _fileRepository.Insert(file); } else { _fileRepository.Update(file); } }
public ImageEditorViewModel(File file, string dataUrl) { File = file; DataUrl = dataUrl; }