|
@@ -1,6 +1,8 @@
|
|
using System;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Collections.Generic;
|
|
|
|
+using Avalonia.Media.Imaging; //äëÿ çàãðóçêè èçîáðàæåíèé. Äëÿ Bitmap ïî óìîë÷àíèþ ïîäêëþ÷àåòñÿ System.Draving, ýòî êîñÿê. Íå ïåðåïóòàéòå
|
|
using System.Linq;
|
|
using System.Linq;
|
|
|
|
+using Avalonia.Platform;
|
|
using AvaloniaApplication5.Models;
|
|
using AvaloniaApplication5.Models;
|
|
using Microsoft.EntityFrameworkCore;
|
|
using Microsoft.EntityFrameworkCore;
|
|
using ReactiveUI;
|
|
using ReactiveUI;
|
|
@@ -35,6 +37,12 @@ namespace AvaloniaApplication5.ViewModels
|
|
public bool ChangePass { get => changePass; set =>this.RaiseAndSetIfChanged(ref changePass, value); }
|
|
public bool ChangePass { get => changePass; set =>this.RaiseAndSetIfChanged(ref changePass, value); }
|
|
public string PasswordMatch { get => passwordMatch; set => passwordMatch = value; }
|
|
public string PasswordMatch { get => passwordMatch; set => passwordMatch = value; }
|
|
public string Message { get => message; set =>this.RaiseAndSetIfChanged(ref message,value); }
|
|
public string Message { get => message; set =>this.RaiseAndSetIfChanged(ref message,value); }
|
|
|
|
+ //ïîëó÷àåì ïóòü ê êàðòèíêå â çàâèñèìîñòè îò ïîëà
|
|
|
|
+ public string Imagepath => CurrentUser.User.IdGender == 3 ? "avares://AvaloniaApplication5/Assets/male.png" : "avares://AvaloniaApplication5/Assets/female.png";
|
|
|
|
+ //ñâîéñâî äëÿ ïðèâÿçêè ê image íà ñòðàíèöå
|
|
|
|
+ public Bitmap? ImageBind => new Bitmap(AssetLoader.Open(new Uri(Imagepath)));
|
|
|
|
+
|
|
|
|
+
|
|
|
|
|
|
bool changePass = false;
|
|
bool changePass = false;
|
|
|
|
|