Skip to content

Commit

Permalink
More fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Webreaper committed Mar 8, 2024
1 parent 6daf990 commit 849e77c
Show file tree
Hide file tree
Showing 7 changed files with 294 additions and 278 deletions.
Binary file modified .DS_Store
Binary file not shown.
3 changes: 3 additions & 0 deletions Damselfly.Core/Services/ExifService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,7 @@ public async Task UpdateFaceDataAsync(Image[] images, List<ImageObject> faces, i
var ops = new List<ExifOperation>();

if ( faces != null )
{
foreach ( var image in images )
ops.AddRange(faces.Select(face => new ExifOperation
{
Expand All @@ -336,6 +337,8 @@ public async Task UpdateFaceDataAsync(Image[] images, List<ImageObject> faces, i
TimeStamp = timestamp,
UserId = userId
}));
changeDesc = $"added {faces.Count} face tags";
}

Logging.LogVerbose($"Bulk inserting {ops.Count()} face exif operations (for {images.Count()}) into queue. ");

Expand Down
10 changes: 9 additions & 1 deletion Damselfly.Web.Client/Pages/PeoplePage.razor
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
{
@foreach( var person in People )
{
<PersonTile Person="person"/>
<PersonTile Person="person" PersonChanged="RefreshData"/>
}
}
else
Expand Down Expand Up @@ -86,6 +86,11 @@

private IEnumerable<Person> People => filteredPeople;

private void RefreshData()
{
_ = LoadData();
}

private void DoSearch(string searchTerm)
{
if( searchText != searchTerm )
Expand Down Expand Up @@ -124,6 +129,9 @@

private async Task LoadData()
{
filteredPeople = null;
StateHasChanged();

var names = await faceService.GetAllPeople();
filteredPeople = names.Where(x => FilterFunc(x))
.ToList();
Expand Down
550 changes: 274 additions & 276 deletions Damselfly.Web.Client/Shared/Config.razor

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions Damselfly.Web.Client/Shared/Config.razor.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.config-tab {
overflow-y: auto;
}
4 changes: 4 additions & 0 deletions Damselfly.Web.Client/Shared/PersonTile.razor
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@

[Parameter]
public Person Person { get; set; }

[Parameter]
public Action? PersonChanged { get; set; }

public string Name
{
Expand Down Expand Up @@ -72,6 +75,7 @@
// Performance hit, of course, but better than showing stale names.
await imageCache.ClearCache();

PersonChanged?.Invoke();
StateHasChanged();

statusService.UpdateStatus($"Name set to '{newName}'");
Expand Down
2 changes: 1 addition & 1 deletion Damselfly.Web.Client/wwwroot/version.js
Original file line number Diff line number Diff line change
@@ -1 +1 @@
const CACHE_VERSION='4.1.0-20240308083351'
const CACHE_VERSION='4.1.0-20240308093934'

0 comments on commit 849e77c

Please sign in to comment.