Ez most félig kész ...

This commit is contained in:
2025-03-03 13:24:23 +01:00
parent dca4f3ba73
commit 499daa0e17
12 changed files with 1803 additions and 67 deletions
File diff suppressed because it is too large Load Diff
+3
View File
@@ -8,6 +8,7 @@
xmlns:nfc="clr-namespace:WorkFlowCheck.MAUI.Pages.NFC" xmlns:nfc="clr-namespace:WorkFlowCheck.MAUI.Pages.NFC"
xmlns:system="clr-namespace:WorkFlowCheck.MAUI.Pages.System" xmlns:system="clr-namespace:WorkFlowCheck.MAUI.Pages.System"
xmlns:base="clr-namespace:WorkFlowCheck.MAUI.Pages.BaseStock" xmlns:base="clr-namespace:WorkFlowCheck.MAUI.Pages.BaseStock"
xmlns:checklist="clr-namespace:WorkFlowCheck.MAUI.Pages.CheckList"
Shell.FlyoutBehavior="Disabled" Shell.FlyoutBehavior="Disabled"
Title="WorkFlowCheck.MAUI"> Title="WorkFlowCheck.MAUI">
@@ -21,5 +22,7 @@
<ShellContent Title="Equipments" ContentTemplate="{DataTemplate base:EquipmentsPage}" Route="EquipmentsPage" /> <ShellContent Title="Equipments" ContentTemplate="{DataTemplate base:EquipmentsPage}" Route="EquipmentsPage" />
<ShellContent Title="Locations" ContentTemplate="{DataTemplate base:LocationsPage}" Route="LocationsPage" /> <ShellContent Title="Locations" ContentTemplate="{DataTemplate base:LocationsPage}" Route="LocationsPage" />
<ShellContent Title="CheckList" ContentTemplate="{DataTemplate checklist:CheckListPage}" Route="CheckListPage" />
</Shell> </Shell>
+29 -30
View File
@@ -4,35 +4,13 @@
x:Class="WorkFlowCheck.MAUI.MainPage" x:Class="WorkFlowCheck.MAUI.MainPage"
Title="Főmenü"> Title="Főmenü">
<ScrollView> <Grid RowDefinitions="Auto, * , Auto" Padding="30,0">
<VerticalStackLayout
Padding="30,0"
Spacing="25">
<!--<Image
Source="dotnet_bot.png"
HeightRequest="185"
Aspect="AspectFit"
SemanticProperties.Description="dot net bot in a race car number eight" />-->
<!--<Label <ScrollView Grid.Row="1">
Text="Hello, World!" <VerticalStackLayout Spacing="25">
x:Name="WelcomeLabel"
Style="{StaticResource Headline}"
SemanticProperties.HeadingLevel="Level1" />-->
<!--<Label
Text="Welcome to &#10;.NET Multi-platform App UI"
Style="{StaticResource SubHeadline}"
SemanticProperties.HeadingLevel="Level2"
SemanticProperties.Description="Welcome to dot net Multi platform App U I" />-->
<!--<Button
x:Name="CounterBtn"
Text="Hahó II."
SemanticProperties.Hint="Counts the number of times you click"
Clicked="OnCounterClicked"
HorizontalOptions="Fill" />-->
<Frame BorderColor="Gray" Padding="5" Margin="1" HasShadow="True"> <Frame BorderColor="Gray" Padding="5" Margin="1" HasShadow="True">
<VerticalStackLayout> <VerticalStackLayout>
<Label Text="Alapműveletek" FontAttributes="Bold" FontSize="Medium" HorizontalOptions="Center" />
<Button <Button
x:Name="ButtonSync" Margin="5" x:Name="ButtonSync" Margin="5"
Text="Adatok szinkronizálása" Text="Adatok szinkronizálása"
@@ -54,14 +32,35 @@
</VerticalStackLayout> </VerticalStackLayout>
</Frame> </Frame>
<Frame BorderColor="Gray" Padding="5" Margin="1" HasShadow="True"> <Frame BorderColor="Gray" Padding="5" Margin="1" HasShadow="True">
<VerticalStackLayout>
<Label Text="Ellenőrzés" FontAttributes="Bold" FontSize="Medium" HorizontalOptions="Center" />
<Button <Button
x:Name="LogoutBtn" Margin="5" x:Name="ButtonCheckList" Margin="5"
Text="Kijelentkezés" Text="Ellenőrzési feladatok"
SemanticProperties.Hint="Kijelentkezés" SemanticProperties.Hint="Ellenőrzési feadatok"
Clicked="OnButtonLogout" Clicked="OnButtonCheckList"
HorizontalOptions="Fill" /> HorizontalOptions="Fill" />
</VerticalStackLayout>
</Frame> </Frame>
</VerticalStackLayout> </VerticalStackLayout>
</ScrollView> </ScrollView>
<Frame Grid.Row="2" BorderColor="Gray" Padding="5" Margin="1" HasShadow="True">
<Button
x:Name="LogoutBtn" Margin="5"
BackgroundColor="DarkRed"
Text="Kijelentkezés"
SemanticProperties.Hint="Kijelentkezés"
Clicked="OnButtonLogout"
HorizontalOptions="Fill"
VerticalOptions="Center">
<Button.ImageSource>
<FontImageSource FontFamily="FontAwesome" Glyph="" Size="20" />
</Button.ImageSource>
</Button>
</Frame>
</Grid>
</ContentPage> </ContentPage>
+4 -1
View File
@@ -63,7 +63,10 @@ namespace WorkFlowCheck.MAUI
{ {
Shell.Current.GoToAsync("//SyncPage"); Shell.Current.GoToAsync("//SyncPage");
} }
private async void OnButtonCheckList(object sender, EventArgs e)
{
await Shell.Current.GoToAsync("//CheckListPage");
}
} }
} }
+1
View File
@@ -57,6 +57,7 @@ namespace WorkFlowCheck.MAUI
{ {
fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular"); fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold"); fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
fonts.AddFont("FontAwesome.ttf", "FontAwesome");
}) })
.UseMauiCommunityToolkitCore() .UseMauiCommunityToolkitCore()
.UseMauiCommunityToolkit(); .UseMauiCommunityToolkit();
@@ -2,11 +2,33 @@
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui" <ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="WorkFlowCheck.MAUI.Pages.CheckList.CheckListPage" x:Class="WorkFlowCheck.MAUI.Pages.CheckList.CheckListPage"
Title="CheckListPage"> Title="Ellenőrzések">
<Grid RowDefinitions="Auto, * , Auto" Padding="30,0">
<ScrollView Grid.Row="1">
<Frame BorderColor="Gray" Padding="5" Margin="1" HasShadow="True">
<VerticalStackLayout> <VerticalStackLayout>
<Label <Label Text="Megkezdett ellenőrzések" FontAttributes="Bold" FontSize="Medium" HorizontalOptions="Center" />
Text="Welcome to .NET MAUI!"
VerticalOptions="Center"
HorizontalOptions="Center" />
</VerticalStackLayout> </VerticalStackLayout>
</Frame>
</ScrollView>
<ScrollView Grid.Row="2">
<Frame BorderColor="Gray" Padding="5" Margin="1" HasShadow="True">
<VerticalStackLayout>
<Label Text="Új ellenőrzés" FontAttributes="Bold" FontSize="Medium" HorizontalOptions="Center" />
<Button
x:Name="ButtonNewCheck" Margin="5"
BackgroundColor="Green"
Text="Új indítása"
SemanticProperties.Hint="Új indítása"
Clicked="OnButtonNewCheck"
HorizontalOptions="Fill" />
</VerticalStackLayout>
</Frame>
</ScrollView>
</Grid>
</ContentPage> </ContentPage>
@@ -6,4 +6,14 @@ public partial class CheckListPage : ContentPage
{ {
InitializeComponent(); InitializeComponent();
} }
protected override bool OnBackButtonPressed()
{
Shell.Current.GoToAsync("//MainPage");
return true;
}
public async void OnButtonNewCheck(object sender, EventArgs e)
{
}
} }
@@ -6,6 +6,7 @@ using System.Linq;
using System.Text; using System.Text;
using System.Threading.Tasks; using System.Threading.Tasks;
using WorkFlowCheck.MAUI.DataLayer; using WorkFlowCheck.MAUI.DataLayer;
using WorkFlowCheck.MAUI.Services.Interfaces;
namespace WorkFlowCheck.MAUI.Services namespace WorkFlowCheck.MAUI.Services
{ {
@@ -0,0 +1,27 @@
using AutoMapper;
using Microsoft.Extensions.Configuration;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using WorkFlowCheck.Common.DTO;
using WorkFlowCheck.MAUI.DataLayer;
using WorkFlowCheck.MAUI.Services.Interfaces;
namespace WorkFlowCheck.MAUI.Services
{
public class CheckListService : BaseService, ICheckListService
{
private readonly IUserService _userService;
public CheckListService(HttpClient httpClient, IConfiguration configuration, AppDbContext dbContext, IMapper mapper, IUserService userService ) : base(httpClient, configuration, dbContext, mapper)
{
_userService = userService;
}
public async Task StartNew(UserDTO userDTO)
{
}
}
}
@@ -0,0 +1,14 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using WorkFlowCheck.Common.DTO;
namespace WorkFlowCheck.MAUI.Services.Interfaces
{
public interface ICheckListService
{
Task<CheckListHeaderDTO> StartNew();
}
}
@@ -110,8 +110,6 @@ namespace WorkFlowCheck.MAUI.Services
} }
} }
public async Task SyncCheckListTemplates() public async Task SyncCheckListTemplates()
{ {
try try