Compare commits
19 Commits
06bda7c881
...
v2.0.2(9)
| Author | SHA1 | Date | |
|---|---|---|---|
| 5981691815 | |||
| f4621f48c8 | |||
| ff36b1cdab | |||
| 36fe05e3c3 | |||
| 0fe1b90417 | |||
| 7359310c48 | |||
| 860a25471e | |||
| 0fab8058f3 | |||
| 2e51420b2c | |||
| fab2836a0e | |||
| 4521b2a02d | |||
| ec7bedeff6 | |||
| ea2f2d47c3 | |||
| 149eb27628 | |||
| 8b331d5824 | |||
| 31db52d0d7 | |||
| ce56e9e57d | |||
| c61093a942 | |||
| 4645b2660e |
@@ -8,7 +8,9 @@ public class AttachedService : IAttachedService
|
|||||||
public async Task<AttachedDTO?> SelectImageFromCamera()
|
public async Task<AttachedDTO?> SelectImageFromCamera()
|
||||||
{
|
{
|
||||||
var cameraPerm = await Permissions.RequestAsync<Permissions.Camera>();
|
var cameraPerm = await Permissions.RequestAsync<Permissions.Camera>();
|
||||||
if (cameraPerm != PermissionStatus.Granted)
|
var storagePerm = await Permissions.RequestAsync<Permissions.StorageWrite>();
|
||||||
|
|
||||||
|
if (cameraPerm != PermissionStatus.Granted || storagePerm != PermissionStatus.Granted)
|
||||||
return null;
|
return null;
|
||||||
|
|
||||||
FileResult? result = null;
|
FileResult? result = null;
|
||||||
@@ -20,6 +22,7 @@ public class AttachedService : IAttachedService
|
|||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
Console.WriteLine($"Errore cattura foto: {ex.Message}");
|
Console.WriteLine($"Errore cattura foto: {ex.Message}");
|
||||||
|
SentrySdk.CaptureException(ex);
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -41,13 +44,13 @@ public class AttachedService : IAttachedService
|
|||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
Console.WriteLine($"Errore selezione galleria: {ex.Message}");
|
Console.WriteLine($"Errore selezione galleria: {ex.Message}");
|
||||||
|
SentrySdk.CaptureException(ex);
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
return result is null ? null : await ConvertToDto(result, AttachedDTO.TypeAttached.Image);
|
return result is null ? null : await ConvertToDto(result, AttachedDTO.TypeAttached.Image);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public async Task<AttachedDTO?> SelectFile()
|
public async Task<AttachedDTO?> SelectFile()
|
||||||
{
|
{
|
||||||
var perm = await Permissions.RequestAsync<Permissions.StorageRead>();
|
var perm = await Permissions.RequestAsync<Permissions.StorageRead>();
|
||||||
@@ -115,6 +118,7 @@ public class AttachedService : IAttachedService
|
|||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
Console.WriteLine($"Errore durante il salvataggio dello stream: {e.Message}");
|
Console.WriteLine($"Errore durante il salvataggio dello stream: {e.Message}");
|
||||||
|
SentrySdk.CaptureException(e);
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
finally
|
finally
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
using AutoMapper;
|
using AutoMapper;
|
||||||
using IntegryApiClient.Core.Domain.Abstraction.Contracts.Storage;
|
|
||||||
using salesbook.Shared.Core.Dto;
|
using salesbook.Shared.Core.Dto;
|
||||||
using salesbook.Shared.Core.Dto.Activity;
|
using salesbook.Shared.Core.Dto.Activity;
|
||||||
using salesbook.Shared.Core.Dto.Contact;
|
using salesbook.Shared.Core.Dto.Contact;
|
||||||
|
using salesbook.Shared.Core.Dto.PageState;
|
||||||
using salesbook.Shared.Core.Entity;
|
using salesbook.Shared.Core.Entity;
|
||||||
using salesbook.Shared.Core.Helpers;
|
using salesbook.Shared.Core.Helpers;
|
||||||
using salesbook.Shared.Core.Helpers.Enum;
|
using salesbook.Shared.Core.Helpers.Enum;
|
||||||
@@ -10,7 +10,7 @@ using salesbook.Shared.Core.Interface;
|
|||||||
using salesbook.Shared.Core.Interface.IntegryApi;
|
using salesbook.Shared.Core.Interface.IntegryApi;
|
||||||
using salesbook.Shared.Core.Interface.System.Network;
|
using salesbook.Shared.Core.Interface.System.Network;
|
||||||
using System.Linq.Expressions;
|
using System.Linq.Expressions;
|
||||||
using salesbook.Shared.Core.Dto.PageState;
|
using IntegryApiClient.Core.Domain.Abstraction.Contracts.Account;
|
||||||
|
|
||||||
namespace salesbook.Maui.Core.Services;
|
namespace salesbook.Maui.Core.Services;
|
||||||
|
|
||||||
@@ -19,7 +19,8 @@ public class ManageDataService(
|
|||||||
IMapper mapper,
|
IMapper mapper,
|
||||||
UserListState userListState,
|
UserListState userListState,
|
||||||
IIntegryApiService integryApiService,
|
IIntegryApiService integryApiService,
|
||||||
INetworkService networkService
|
INetworkService networkService,
|
||||||
|
IUserSession userSession
|
||||||
) : IManageDataService
|
) : IManageDataService
|
||||||
{
|
{
|
||||||
public Task<List<T>> GetTable<T>(Expression<Func<T, bool>>? whereCond = null) where T : new() =>
|
public Task<List<T>> GetTable<T>(Expression<Func<T, bool>>? whereCond = null) where T : new() =>
|
||||||
@@ -232,7 +233,7 @@ public class ManageDataService(
|
|||||||
return await MapActivity(activities);
|
return await MapActivity(activities);
|
||||||
}
|
}
|
||||||
|
|
||||||
private async Task<List<ActivityDTO>> MapActivity(List<StbActivity>? activities)
|
public async Task<List<ActivityDTO>> MapActivity(List<StbActivity>? activities)
|
||||||
{
|
{
|
||||||
if (activities == null) return [];
|
if (activities == null) return [];
|
||||||
|
|
||||||
@@ -260,6 +261,11 @@ public class ManageDataService(
|
|||||||
var returnDto = activities
|
var returnDto = activities
|
||||||
.Select(activity =>
|
.Select(activity =>
|
||||||
{
|
{
|
||||||
|
if (activity.CodJcom is "0000" && userSession.ProfileDb != null && userSession.ProfileDb.Equals("smetar", StringComparison.OrdinalIgnoreCase))
|
||||||
|
{
|
||||||
|
activity.CodJcom = null;
|
||||||
|
}
|
||||||
|
|
||||||
var dto = mapper.Map<ActivityDTO>(activity);
|
var dto = mapper.Map<ActivityDTO>(activity);
|
||||||
|
|
||||||
if (activity is { AlarmTime: not null, EstimatedTime: not null })
|
if (activity is { AlarmTime: not null, EstimatedTime: not null })
|
||||||
@@ -291,7 +297,7 @@ public class ManageDataService(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
dto.Commessa = jtbComtList.LastOrDefault();
|
dto.Commessa = jtbComtList.Find(x => x.CodJcom.Equals(dto.CodJcom));
|
||||||
return dto;
|
return dto;
|
||||||
})
|
})
|
||||||
.ToList();
|
.ToList();
|
||||||
|
|||||||
4
salesbook.Maui/ILLink.Descriptors.xml
Normal file
4
salesbook.Maui/ILLink.Descriptors.xml
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8" ?>
|
||||||
|
<linker>
|
||||||
|
<assembly fullname="salesbook.Shared" preserve="all" />
|
||||||
|
</linker>
|
||||||
@@ -1,27 +1,57 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="it.integry.salesbook">
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
<application android:allowBackup="true" android:icon="@mipmap/appicon" android:usesCleartextTraffic="true" android:supportsRtl="true">
|
package="it.integry.salesbook">
|
||||||
<receiver android:name="com.google.firebase.iid.FirebaseInstanceIdInternalReceiver" android:exported="false" />
|
|
||||||
<receiver android:name="com.google.firebase.iid.FirebaseInstanceIdReceiver" android:exported="true" android:permission="com.google.android.c2dm.permission.SEND">
|
<application
|
||||||
|
android:allowBackup="true"
|
||||||
|
android:icon="@mipmap/appicon"
|
||||||
|
android:usesCleartextTraffic="true"
|
||||||
|
android:supportsRtl="true">
|
||||||
|
|
||||||
|
<!-- Firebase push -->
|
||||||
|
<receiver android:name="com.google.firebase.iid.FirebaseInstanceIdInternalReceiver"
|
||||||
|
android:exported="false" />
|
||||||
|
<receiver android:name="com.google.firebase.iid.FirebaseInstanceIdReceiver"
|
||||||
|
android:exported="true"
|
||||||
|
android:permission="com.google.android.c2dm.permission.SEND">
|
||||||
<intent-filter>
|
<intent-filter>
|
||||||
<action android:name="com.google.android.c2dm.intent.RECEIVE" />
|
<action android:name="com.google.android.c2dm.intent.RECEIVE" />
|
||||||
<action android:name="com.google.android.c2dm.intent.REGISTRATION" />
|
<action android:name="com.google.android.c2dm.intent.REGISTRATION" />
|
||||||
<category android:name="${applicationId}" />
|
<category android:name="${applicationId}" />
|
||||||
</intent-filter>
|
</intent-filter>
|
||||||
</receiver>
|
</receiver>
|
||||||
|
|
||||||
</application>
|
</application>
|
||||||
|
|
||||||
|
<!-- Rete -->
|
||||||
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
|
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
|
||||||
<uses-permission android:name="android.permission.INTERNET" />
|
<uses-permission android:name="android.permission.INTERNET" />
|
||||||
|
|
||||||
|
<!-- Geolocalizzazione -->
|
||||||
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
|
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
|
||||||
<uses-permission android:name="android.permission.ACCESS_MEDIA_LOCATION" />
|
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
|
||||||
|
|
||||||
|
<!-- Fotocamera -->
|
||||||
<uses-permission android:name="android.permission.CAMERA" />
|
<uses-permission android:name="android.permission.CAMERA" />
|
||||||
|
|
||||||
|
<!-- Storage / Media -->
|
||||||
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
|
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
|
||||||
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" android:maxSdkVersion="28" />
|
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
|
||||||
|
|
||||||
|
<!-- Android 10+ -->
|
||||||
|
<uses-permission android:name="android.permission.ACCESS_MEDIA_LOCATION" />
|
||||||
|
|
||||||
|
<!-- Android 13+ -->
|
||||||
<uses-permission android:name="android.permission.READ_MEDIA_IMAGES" />
|
<uses-permission android:name="android.permission.READ_MEDIA_IMAGES" />
|
||||||
|
<uses-permission android:name="android.permission.READ_MEDIA_VIDEO" />
|
||||||
|
<uses-permission android:name="android.permission.READ_MEDIA_AUDIO" />
|
||||||
|
|
||||||
|
<!-- Background / Notifiche -->
|
||||||
<uses-permission android:name="android.permission.BATTERY_STATS" />
|
<uses-permission android:name="android.permission.BATTERY_STATS" />
|
||||||
<uses-permission android:name="android.permission.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS" />
|
<uses-permission android:name="android.permission.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS" />
|
||||||
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
|
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
|
||||||
<uses-permission android:name="android.permission.POST_NOTIFICATIONS" />
|
<uses-permission android:name="android.permission.POST_NOTIFICATIONS" />
|
||||||
<uses-permission android:name="android.permission.WAKE_LOCK" />
|
<uses-permission android:name="android.permission.WAKE_LOCK" />
|
||||||
<uses-permission android:name="android.permission.VIBRATE" />
|
<uses-permission android:name="android.permission.VIBRATE" />
|
||||||
|
|
||||||
</manifest>
|
</manifest>
|
||||||
@@ -29,8 +29,8 @@
|
|||||||
<ApplicationId>it.integry.salesbook</ApplicationId>
|
<ApplicationId>it.integry.salesbook</ApplicationId>
|
||||||
|
|
||||||
<!-- Versions -->
|
<!-- Versions -->
|
||||||
<ApplicationDisplayVersion>1.1.0</ApplicationDisplayVersion>
|
<ApplicationDisplayVersion>2.0.2</ApplicationDisplayVersion>
|
||||||
<ApplicationVersion>5</ApplicationVersion>
|
<ApplicationVersion>9</ApplicationVersion>
|
||||||
|
|
||||||
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'ios'">14.2</SupportedOSPlatformVersion>
|
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'ios'">14.2</SupportedOSPlatformVersion>
|
||||||
<!--<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'maccatalyst'">
|
<!--<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'maccatalyst'">
|
||||||
@@ -105,6 +105,20 @@
|
|||||||
<MauiIcon Include="Resources\AppIcon\appicon.svg" ForegroundFile="Resources\AppIcon\appiconfg.svg" />
|
<MauiIcon Include="Resources\AppIcon\appicon.svg" ForegroundFile="Resources\AppIcon\appiconfg.svg" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<BlazorWebAssemblyLazyLoad Include="salesbook.Shared.dll" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
<PropertyGroup Condition="'$(Configuration)' == 'Release'">
|
||||||
|
<PublishTrimmed>true</PublishTrimmed>
|
||||||
|
<RunAOTCompilation>true</RunAOTCompilation>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<TrimmerRootAssembly Include="salesbook.Shared" RootMode="All" />
|
||||||
|
<TrimmerRootDescriptor Include="ILLink.Descriptors.xml" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<!-- Splash Screen -->
|
<!-- Splash Screen -->
|
||||||
<MauiSplashScreen Include="Resources\Splash\splash.svg" Color="#dff2ff" BaseSize="128,128" />
|
<MauiSplashScreen Include="Resources\Splash\splash.svg" Color="#dff2ff" BaseSize="128,128" />
|
||||||
@@ -139,11 +153,12 @@
|
|||||||
<PackageReference Include="Microsoft.Maui.Controls.Compatibility" Version="9.0.110" />
|
<PackageReference Include="Microsoft.Maui.Controls.Compatibility" Version="9.0.110" />
|
||||||
<PackageReference Include="Microsoft.AspNetCore.Components.WebView.Maui" Version="9.0.110" />
|
<PackageReference Include="Microsoft.AspNetCore.Components.WebView.Maui" Version="9.0.110" />
|
||||||
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="9.0.9" />
|
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="9.0.9" />
|
||||||
<PackageReference Include="Sentry.Maui" Version="5.15.0" />
|
<PackageReference Include="Sentry.Maui" Version="5.15.1" />
|
||||||
<PackageReference Include="Shiny.Hosting.Maui" Version="3.3.4" />
|
<PackageReference Include="Shiny.Hosting.Maui" Version="3.3.4" />
|
||||||
<PackageReference Include="Shiny.Notifications" Version="3.3.4" />
|
<PackageReference Include="Shiny.Notifications" Version="3.3.4" />
|
||||||
<PackageReference Include="Shiny.Push" Version="3.3.4" />
|
<PackageReference Include="Shiny.Push" Version="3.3.4" />
|
||||||
<PackageReference Include="sqlite-net-pcl" Version="1.9.172" />
|
<PackageReference Include="SourceGear.sqlite3" Version="3.50.4.2" />
|
||||||
|
<PackageReference Include="sqlite-net-e" Version="1.10.0-beta2" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
|||||||
@@ -80,13 +80,12 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.day {
|
.day {
|
||||||
background: var(--mud-palette-surface);
|
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
transition: background 0.3s ease, transform 0.2s ease;
|
transition: background 0.3s ease, transform 0.2s ease;
|
||||||
font-size: 0.95rem;
|
font-size: 0.95rem;
|
||||||
box-shadow: var(--custom-box-shadow);
|
background: var(--mud-palette-background-gray);
|
||||||
width: 38px;
|
width: 38px;
|
||||||
height: 38px;
|
height: 38px;
|
||||||
display: flex;
|
display: flex;
|
||||||
@@ -94,7 +93,7 @@
|
|||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
color: var(--mud-palette-text-primary);
|
color: var(--mud-palette-text-primary);
|
||||||
border: 1px solid var(--mud-palette-surface);
|
border: 1px solid var(--mud-palette-background-gray);
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -25,7 +25,7 @@
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
<div class="container content">
|
<div class="container content pb-safe-area">
|
||||||
@if (CommessaModel == null)
|
@if (CommessaModel == null)
|
||||||
{
|
{
|
||||||
<NoDataAvailable Text="Nessuna commessa trovata"/>
|
<NoDataAvailable Text="Nessuna commessa trovata"/>
|
||||||
@@ -149,8 +149,7 @@ else
|
|||||||
await Task.Run(async () =>
|
await Task.Run(async () =>
|
||||||
{
|
{
|
||||||
var activities = await IntegryApiService.RetrieveActivity(new CRMRetrieveActivityRequestDTO { CodJcom = CodJcom });
|
var activities = await IntegryApiService.RetrieveActivity(new CRMRetrieveActivityRequestDTO { CodJcom = CodJcom });
|
||||||
ActivityList = Mapper.Map<List<ActivityDTO>>(activities)
|
ActivityList = (await ManageData.MapActivity(activities)).OrderByDescending(x =>
|
||||||
.OrderBy(x =>
|
|
||||||
(x.EffectiveTime ?? x.EstimatedTime) ?? x.DataInsAct
|
(x.EffectiveTime ?? x.EstimatedTime) ?? x.DataInsAct
|
||||||
).ToList();
|
).ToList();
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -118,7 +118,7 @@
|
|||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
width: -webkit-fill-available;
|
width: -webkit-fill-available;
|
||||||
box-shadow: var(--custom-box-shadow);
|
background: var(--light-card-background);
|
||||||
border-radius: 16px;
|
border-radius: 16px;
|
||||||
overflow: clip;
|
overflow: clip;
|
||||||
margin-bottom: 1rem;
|
margin-bottom: 1rem;
|
||||||
@@ -135,7 +135,6 @@
|
|||||||
display: flex;
|
display: flex;
|
||||||
position: relative;
|
position: relative;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
background: var(--mud-palette-surface);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* la lineetta */
|
/* la lineetta */
|
||||||
|
|||||||
@@ -1,11 +1,8 @@
|
|||||||
@page "/login"
|
@page "/login"
|
||||||
@using salesbook.Shared.Components.Layout.Spinner
|
@using salesbook.Shared.Components.Layout.Spinner
|
||||||
@using salesbook.Shared.Core.Interface
|
|
||||||
@using salesbook.Shared.Core.Interface.System.Network
|
|
||||||
@using salesbook.Shared.Core.Services
|
@using salesbook.Shared.Core.Services
|
||||||
@inject IUserAccountService UserAccountService
|
@inject IUserAccountService UserAccountService
|
||||||
@inject AppAuthenticationStateProvider AuthenticationStateProvider
|
@inject AppAuthenticationStateProvider AuthenticationStateProvider
|
||||||
@inject INetworkService NetworkService
|
|
||||||
|
|
||||||
@if (Spinner)
|
@if (Spinner)
|
||||||
{
|
{
|
||||||
@@ -29,7 +26,7 @@ else
|
|||||||
<MudTextField @bind-Value="UserData.CodHash" Label="Profilo azienda" Variant="Variant.Outlined"/>
|
<MudTextField @bind-Value="UserData.CodHash" Label="Profilo azienda" Variant="Variant.Outlined"/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<MudButton Disabled="@(!NetworkService.ConnectionAvailable)" OnClick="SignInUser" Color="Color.Primary" Variant="Variant.Filled">Login</MudButton>
|
<MudButton OnClick="SignInUser" Color="Color.Primary" Variant="Variant.Filled">Login</MudButton>
|
||||||
@if (_attemptFailed)
|
@if (_attemptFailed)
|
||||||
{
|
{
|
||||||
<MudAlert Class="my-3" Dense="true" Severity="Severity.Error" Variant="Variant.Filled">@ErrorMessage</MudAlert>
|
<MudAlert Class="my-3" Dense="true" Severity="Severity.Error" Variant="Variant.Filled">@ErrorMessage</MudAlert>
|
||||||
|
|||||||
@@ -13,7 +13,7 @@
|
|||||||
|
|
||||||
@if (IsLoggedIn)
|
@if (IsLoggedIn)
|
||||||
{
|
{
|
||||||
<div class="container content">
|
<div class="container content pb-safe-area">
|
||||||
<div class="container-primary-info">
|
<div class="container-primary-info">
|
||||||
<div class="section-primary-info">
|
<div class="section-primary-info">
|
||||||
<MudAvatar Style="height: 70px; width: 70px; font-size: 2rem; font-weight: bold" Color="Color.Secondary">
|
<MudAvatar Style="height: 70px; width: 70px; font-size: 2rem; font-weight: bold" Color="Color.Secondary">
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
.container-primary-info {
|
.container-primary-info {
|
||||||
box-shadow: var(--custom-box-shadow);
|
background: var(--light-card-background);
|
||||||
width: 100%;
|
width: 100%;
|
||||||
margin-bottom: 2rem;
|
margin-bottom: 2rem;
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
|
|||||||
@@ -32,7 +32,7 @@
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
<div class="container content" style="overflow: auto;" id="topPage">
|
<div class="container content pb-safe-area" style="overflow: auto;" id="topPage">
|
||||||
<div class="container-primary-info">
|
<div class="container-primary-info">
|
||||||
<div class="section-primary-info">
|
<div class="section-primary-info">
|
||||||
<MudAvatar Style="height: 70px; width: 70px; font-size: 2rem; font-weight: bold" Variant="@(IsContact ? Variant.Filled : Variant.Outlined)" Color="Color.Secondary">
|
<MudAvatar Style="height: 70px; width: 70px; font-size: 2rem; font-weight: bold" Variant="@(IsContact ? Variant.Filled : Variant.Outlined)" Color="Color.Secondary">
|
||||||
@@ -97,6 +97,7 @@ else
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="tab-section">
|
||||||
<input type="radio" class="tab-toggle" name="tab-toggle" id="tab1" checked="@(ActiveTab == 0)">
|
<input type="radio" class="tab-toggle" name="tab-toggle" id="tab1" checked="@(ActiveTab == 0)">
|
||||||
<input type="radio" class="tab-toggle" name="tab-toggle" id="tab2" checked="@(ActiveTab == 1)">
|
<input type="radio" class="tab-toggle" name="tab-toggle" id="tab2" checked="@(ActiveTab == 1)">
|
||||||
<input type="radio" class="tab-toggle" name="tab-toggle" id="tab3" checked="@(ActiveTab == 2)">
|
<input type="radio" class="tab-toggle" name="tab-toggle" id="tab3" checked="@(ActiveTab == 2)">
|
||||||
@@ -133,9 +134,12 @@ else
|
|||||||
}
|
}
|
||||||
|
|
||||||
<div class="container-button">
|
<div class="container-button">
|
||||||
|
<div class="divider"></div>
|
||||||
|
|
||||||
<MudButton Class="button-settings infoText"
|
<MudButton Class="button-settings infoText"
|
||||||
FullWidth="true"
|
FullWidth="true"
|
||||||
Size="Size.Medium"
|
Size="Size.Medium"
|
||||||
|
StartIcon="@Icons.Material.Rounded.Add"
|
||||||
OnClick="OpenPersRifForm"
|
OnClick="OpenPersRifForm"
|
||||||
Variant="Variant.Outlined">
|
Variant="Variant.Outlined">
|
||||||
Aggiungi contatto
|
Aggiungi contatto
|
||||||
@@ -156,11 +160,13 @@ else
|
|||||||
else if (Commesse != null)
|
else if (Commesse != null)
|
||||||
{
|
{
|
||||||
<!-- Filtri e ricerca -->
|
<!-- Filtri e ricerca -->
|
||||||
<div class="input-card clearButton">
|
<div class="input-card clearButton custom-border-bottom">
|
||||||
<MudTextField T="string?"
|
<MudTextField T="string?"
|
||||||
Placeholder="Cerca..."
|
Placeholder="Cerca..."
|
||||||
Variant="Variant.Text"
|
Variant="Variant.Text"
|
||||||
@bind-Value="SearchTermCommesse"
|
@bind-Value="SearchTermCommesse"
|
||||||
|
AdornmentIcon="@Icons.Material.Rounded.Search"
|
||||||
|
Adornment="Adornment.Start"
|
||||||
OnDebounceIntervalElapsed="() => ApplyFiltersCommesse()"
|
OnDebounceIntervalElapsed="() => ApplyFiltersCommesse()"
|
||||||
DebounceInterval="500"/>
|
DebounceInterval="500"/>
|
||||||
</div>
|
</div>
|
||||||
@@ -226,10 +232,12 @@ else
|
|||||||
else if (ActivityList != null)
|
else if (ActivityList != null)
|
||||||
{
|
{
|
||||||
<!-- Filtri e ricerca -->
|
<!-- Filtri e ricerca -->
|
||||||
<div class="input-card clearButton">
|
<div class="input-card clearButton custom-border-bottom">
|
||||||
<MudTextField T="string?"
|
<MudTextField T="string?"
|
||||||
Placeholder="Cerca..."
|
Placeholder="Cerca..."
|
||||||
Variant="Variant.Text"
|
Variant="Variant.Text"
|
||||||
|
AdornmentIcon="@Icons.Material.Rounded.Search"
|
||||||
|
Adornment="Adornment.Start"
|
||||||
@bind-Value="SearchTermActivity"
|
@bind-Value="SearchTermActivity"
|
||||||
OnDebounceIntervalElapsed="() => ApplyFiltersActivity()"
|
OnDebounceIntervalElapsed="() => ApplyFiltersActivity()"
|
||||||
DebounceInterval="500"/>
|
DebounceInterval="500"/>
|
||||||
@@ -270,6 +278,7 @@ else
|
|||||||
<MudFab Size="Size.Small" Color="Color.Primary" StartIcon="@Icons.Material.Rounded.KeyboardArrowUp"/>
|
<MudFab Size="Size.Small" Color="Color.Primary" StartIcon="@Icons.Material.Rounded.KeyboardArrowUp"/>
|
||||||
</MudScrollToTop>
|
</MudScrollToTop>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
}
|
}
|
||||||
|
|
||||||
@code {
|
@code {
|
||||||
@@ -527,8 +536,7 @@ else
|
|||||||
await Task.Run(async () =>
|
await Task.Run(async () =>
|
||||||
{
|
{
|
||||||
var activities = await IntegryApiService.RetrieveActivity(new CRMRetrieveActivityRequestDTO { CodAnag = Anag.CodContact });
|
var activities = await IntegryApiService.RetrieveActivity(new CRMRetrieveActivityRequestDTO { CodAnag = Anag.CodContact });
|
||||||
ActivityList = Mapper.Map<List<ActivityDTO>>(activities)
|
ActivityList = (await ManageData.MapActivity(activities)).OrderByDescending(x =>
|
||||||
.OrderByDescending(x =>
|
|
||||||
(x.EffectiveTime ?? x.EstimatedTime) ?? x.DataInsAct
|
(x.EffectiveTime ?? x.EstimatedTime) ?? x.DataInsAct
|
||||||
).ToList();
|
).ToList();
|
||||||
});
|
});
|
||||||
@@ -794,4 +802,5 @@ else
|
|||||||
}
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -1,5 +1,11 @@
|
|||||||
|
.tab-section {
|
||||||
|
width: 100%;
|
||||||
|
border-radius: var(--mud-default-borderradius);
|
||||||
|
background: var(--light-card-background);
|
||||||
|
}
|
||||||
|
|
||||||
.container-primary-info {
|
.container-primary-info {
|
||||||
box-shadow: var(--custom-box-shadow);
|
background: var(--light-card-background);
|
||||||
width: 100%;
|
width: 100%;
|
||||||
margin-bottom: 2rem;
|
margin-bottom: 2rem;
|
||||||
border-radius: 16px;
|
border-radius: 16px;
|
||||||
@@ -85,8 +91,9 @@
|
|||||||
|
|
||||||
.container-button {
|
.container-button {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
box-shadow: var(--custom-box-shadow);
|
background: var(--light-card-background);
|
||||||
padding: .25rem 0;
|
padding: 0 !important;
|
||||||
|
padding-bottom: .5rem !important;
|
||||||
border-radius: 16px;
|
border-radius: 16px;
|
||||||
margin-bottom: 0 !important;
|
margin-bottom: 0 !important;
|
||||||
}
|
}
|
||||||
@@ -138,8 +145,7 @@
|
|||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
gap: 1rem;
|
gap: 1rem;
|
||||||
margin-bottom: 1rem;
|
background: var(--light-card-background);
|
||||||
box-shadow: var(--custom-box-shadow);
|
|
||||||
border-radius: 16px;
|
border-radius: 16px;
|
||||||
max-height: 32vh;
|
max-height: 32vh;
|
||||||
overflow: auto;
|
overflow: auto;
|
||||||
@@ -147,7 +153,12 @@
|
|||||||
padding: 1rem 0;
|
padding: 1rem 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.container-pers-rif::-webkit-scrollbar { display: none; }
|
.container-pers-rif::-webkit-scrollbar { width: 3px; }
|
||||||
|
|
||||||
|
.container-pers-rif::-webkit-scrollbar-thumb {
|
||||||
|
background: #bbb;
|
||||||
|
border-radius: 2px;
|
||||||
|
}
|
||||||
|
|
||||||
.container-pers-rif .divider {
|
.container-pers-rif .divider {
|
||||||
margin: 0 0 0 3.5rem;
|
margin: 0 0 0 3.5rem;
|
||||||
@@ -176,12 +187,14 @@
|
|||||||
/*--------------
|
/*--------------
|
||||||
TabPanel
|
TabPanel
|
||||||
----------------*/
|
----------------*/
|
||||||
|
|
||||||
.box {
|
.box {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
width: -webkit-fill-available;
|
width: -webkit-fill-available;
|
||||||
box-shadow: var(--custom-box-shadow);
|
background: var(--light-card-background);
|
||||||
border-radius: 16px;
|
border-radius: 20px 20px 0 0;
|
||||||
|
border-bottom: .1rem solid var(--card-border-color);
|
||||||
overflow: clip;
|
overflow: clip;
|
||||||
margin-bottom: 1rem;
|
margin-bottom: 1rem;
|
||||||
}
|
}
|
||||||
@@ -197,7 +210,6 @@
|
|||||||
display: flex;
|
display: flex;
|
||||||
position: relative;
|
position: relative;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
background: var(--mud-palette-surface);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* la lineetta */
|
/* la lineetta */
|
||||||
@@ -268,9 +280,7 @@
|
|||||||
|
|
||||||
#tab1:checked ~ .tab-container .tab-content:nth-child(1),
|
#tab1:checked ~ .tab-container .tab-content:nth-child(1),
|
||||||
#tab2:checked ~ .tab-container .tab-content:nth-child(2),
|
#tab2:checked ~ .tab-container .tab-content:nth-child(2),
|
||||||
#tab3:checked ~ .tab-container .tab-content:nth-child(3) {
|
#tab3:checked ~ .tab-container .tab-content:nth-child(3) { display: block; }
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes fade {
|
@keyframes fade {
|
||||||
from {
|
from {
|
||||||
@@ -286,10 +296,6 @@
|
|||||||
|
|
||||||
.custom-pagination ::deep ul { padding-left: 0 !important; }
|
.custom-pagination ::deep ul { padding-left: 0 !important; }
|
||||||
|
|
||||||
.SelectedPageSize {
|
.SelectedPageSize { width: 100%; }
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.FilterSection {
|
.FilterSection { display: flex; }
|
||||||
display: flex;
|
|
||||||
}
|
|
||||||
@@ -5,14 +5,23 @@
|
|||||||
padding: .5rem .5rem;
|
padding: .5rem .5rem;
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
line-height: normal;
|
line-height: normal;
|
||||||
box-shadow: var(--custom-box-shadow);
|
/*box-shadow: var(--custom-box-shadow);*/
|
||||||
}
|
}
|
||||||
|
|
||||||
.activity-card.memo { border-left: 5px solid var(--mud-palette-info-darken); }
|
.activity-card.memo {
|
||||||
|
border-left: 5px solid var(--mud-palette-info-darken);
|
||||||
|
background-color: hsl(from var(--mud-palette-info-darken) h s 99%);
|
||||||
|
}
|
||||||
|
|
||||||
.activity-card.interna { border-left: 5px solid var(--mud-palette-success-darken); }
|
.activity-card.interna {
|
||||||
|
border-left: 5px solid var(--mud-palette-success-darken);
|
||||||
|
background-color: hsl(from var(--mud-palette-success-darken) h s 99%);
|
||||||
|
}
|
||||||
|
|
||||||
.activity-card.commessa { border-left: 5px solid var(--mud-palette-warning); }
|
.activity-card.commessa {
|
||||||
|
border-left: 5px solid var(--mud-palette-warning);
|
||||||
|
background-color: hsl(from var(--mud-palette-warning) h s 99%);
|
||||||
|
}
|
||||||
|
|
||||||
.activity-left-section {
|
.activity-left-section {
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
padding: .5rem .5rem;
|
padding: .5rem .5rem;
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
line-height: normal;
|
line-height: normal;
|
||||||
box-shadow: var(--custom-box-shadow);
|
background: var(--light-card-background);
|
||||||
}
|
}
|
||||||
|
|
||||||
.activity-card.memo { border-left: 5px solid var(--mud-palette-info-darken); }
|
.activity-card.memo { border-left: 5px solid var(--mud-palette-info-darken); }
|
||||||
|
|||||||
@@ -5,15 +5,11 @@
|
|||||||
padding: .5rem .5rem;
|
padding: .5rem .5rem;
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
line-height: normal;
|
line-height: normal;
|
||||||
box-shadow: var(--custom-box-shadow);
|
|
||||||
|
border-left: 5px solid var(--card-border-color);
|
||||||
|
background-color: hsl(from var(--card-border-color) h s 99%);
|
||||||
}
|
}
|
||||||
|
|
||||||
.activity-card.memo { border-left: 5px solid var(--mud-palette-info-darken); }
|
|
||||||
|
|
||||||
.activity-card.interna { border-left: 5px solid var(--mud-palette-success-darken); }
|
|
||||||
|
|
||||||
.activity-card.commessa { border-left: 5px solid var(--mud-palette-warning); }
|
|
||||||
|
|
||||||
.activity-left-section {
|
.activity-left-section {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
|||||||
@@ -2,8 +2,7 @@
|
|||||||
width: 100%;
|
width: 100%;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
padding: 0 .75rem;
|
padding: 0 .5rem;
|
||||||
border-radius: 16px;
|
|
||||||
line-height: normal;
|
line-height: normal;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
|||||||
@@ -1,3 +1,4 @@
|
|||||||
|
@using Java.Sql
|
||||||
@using salesbook.Shared.Components.Layout.Spinner
|
@using salesbook.Shared.Components.Layout.Spinner
|
||||||
@using salesbook.Shared.Core.Dto.Activity
|
@using salesbook.Shared.Core.Dto.Activity
|
||||||
@using salesbook.Shared.Core.Entity
|
@using salesbook.Shared.Core.Entity
|
||||||
@@ -92,6 +93,9 @@
|
|||||||
|
|
||||||
var difference = DateTime.Now - timestamp.Value;
|
var difference = DateTime.Now - timestamp.Value;
|
||||||
|
|
||||||
|
if (DateTime.Now.Day != timestamp.Value.Day)
|
||||||
|
return timestamp.Value.ToString("dd/MM/yyyy");
|
||||||
|
|
||||||
switch (difference.TotalMinutes)
|
switch (difference.TotalMinutes)
|
||||||
{
|
{
|
||||||
case < 1:
|
case < 1:
|
||||||
|
|||||||
@@ -2,7 +2,6 @@
|
|||||||
position: relative;
|
position: relative;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
border-radius: var(--mud-default-borderradius);
|
border-radius: var(--mud-default-borderradius);
|
||||||
box-shadow: var(--custom-box-shadow);
|
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -39,7 +38,7 @@
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
padding: 12px;
|
padding: 12px;
|
||||||
gap: 12px;
|
gap: 12px;
|
||||||
background: var(--mud-palette-background);
|
background: var(--light-card-background);
|
||||||
transition: transform .2s ease;
|
transition: transform .2s ease;
|
||||||
touch-action: pan-y;
|
touch-action: pan-y;
|
||||||
will-change: transform;
|
will-change: transform;
|
||||||
|
|||||||
@@ -39,6 +39,12 @@
|
|||||||
<div class="form-container">
|
<div class="form-container">
|
||||||
<span class="disable-full-width">Commessa</span>
|
<span class="disable-full-width">Commessa</span>
|
||||||
|
|
||||||
|
@if (ActivityModel.CodJcom != null && SelectedComessa == null)
|
||||||
|
{
|
||||||
|
<MudSkeleton />
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
<MudAutocomplete
|
<MudAutocomplete
|
||||||
Disabled="ActivityModel.Cliente.IsNullOrEmpty()"
|
Disabled="ActivityModel.Cliente.IsNullOrEmpty()"
|
||||||
T="JtbComt?" ReadOnly="IsView"
|
T="JtbComt?" ReadOnly="IsView"
|
||||||
@@ -47,10 +53,12 @@
|
|||||||
SearchFunc="SearchCommesseAsync"
|
SearchFunc="SearchCommesseAsync"
|
||||||
ToStringFunc="@(c => c == null ? string.Empty : $"{c.CodJcom} - {c.Descrizione}")"
|
ToStringFunc="@(c => c == null ? string.Empty : $"{c.CodJcom} - {c.Descrizione}")"
|
||||||
Clearable="true"
|
Clearable="true"
|
||||||
|
OnClearButtonClick="OnCommessaClear"
|
||||||
ShowProgressIndicator="true"
|
ShowProgressIndicator="true"
|
||||||
DebounceInterval="300"
|
DebounceInterval="300"
|
||||||
MaxItems="50"
|
MaxItems="50"
|
||||||
Class="customIcon-select" AdornmentIcon="@Icons.Material.Filled.Code"/>
|
Class="customIcon-select" AdornmentIcon="@Icons.Material.Filled.Code"/>
|
||||||
|
}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -90,6 +98,12 @@
|
|||||||
<div class="form-container">
|
<div class="form-container">
|
||||||
<span class="disable-full-width">Assegnata a</span>
|
<span class="disable-full-width">Assegnata a</span>
|
||||||
|
|
||||||
|
@if (ActivityModel.UserName != null && SelectedUser == null)
|
||||||
|
{
|
||||||
|
<MudSkeleton />
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
<MudAutocomplete
|
<MudAutocomplete
|
||||||
Disabled="Users.IsNullOrEmpty()" ReadOnly="IsView"
|
Disabled="Users.IsNullOrEmpty()" ReadOnly="IsView"
|
||||||
T="StbUser"
|
T="StbUser"
|
||||||
@@ -98,11 +112,13 @@
|
|||||||
SearchFunc="SearchUtentiAsync"
|
SearchFunc="SearchUtentiAsync"
|
||||||
ToStringFunc="@(u => u == null ? string.Empty : u.FullName)"
|
ToStringFunc="@(u => u == null ? string.Empty : u.FullName)"
|
||||||
Clearable="true"
|
Clearable="true"
|
||||||
|
OnClearButtonClick="OnUserClear"
|
||||||
ShowProgressIndicator="true"
|
ShowProgressIndicator="true"
|
||||||
DebounceInterval="300"
|
DebounceInterval="300"
|
||||||
MaxItems="50"
|
MaxItems="50"
|
||||||
Class="customIcon-select"
|
Class="customIcon-select"
|
||||||
AdornmentIcon="@Icons.Material.Filled.Code"/>
|
AdornmentIcon="@Icons.Material.Filled.Code"/>
|
||||||
|
}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="divider"></div>
|
<div class="divider"></div>
|
||||||
@@ -110,12 +126,19 @@
|
|||||||
<div class="form-container">
|
<div class="form-container">
|
||||||
<span class="disable-full-width">Tipo</span>
|
<span class="disable-full-width">Tipo</span>
|
||||||
|
|
||||||
|
@if (ActivityType.IsNullOrEmpty())
|
||||||
|
{
|
||||||
|
<MudSkeleton />
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
<MudSelectExtended ReadOnly="IsView" FullWidth="true" T="string?" Variant="Variant.Text" @bind-Value="ActivityModel.ActivityTypeId" @bind-Value:after="OnAfterChangeValue" Class="customIcon-select" AdornmentIcon="@Icons.Material.Filled.Code">
|
<MudSelectExtended ReadOnly="IsView" FullWidth="true" T="string?" Variant="Variant.Text" @bind-Value="ActivityModel.ActivityTypeId" @bind-Value:after="OnAfterChangeValue" Class="customIcon-select" AdornmentIcon="@Icons.Material.Filled.Code">
|
||||||
@foreach (var type in ActivityType)
|
@foreach (var type in ActivityType)
|
||||||
{
|
{
|
||||||
<MudSelectItemExtended Class="custom-item-select" Value="@type.ActivityTypeId">@type.ActivityTypeId</MudSelectItemExtended>
|
<MudSelectItemExtended Class="custom-item-select" Value="@type.ActivityTypeId">@type.ActivityTypeId</MudSelectItemExtended>
|
||||||
}
|
}
|
||||||
</MudSelectExtended>
|
</MudSelectExtended>
|
||||||
|
}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="divider"></div>
|
<div class="divider"></div>
|
||||||
@@ -370,14 +393,14 @@
|
|||||||
{
|
{
|
||||||
return Task.Run(async () =>
|
return Task.Run(async () =>
|
||||||
{
|
{
|
||||||
if (!IsNew && Id != null)
|
SelectedComessa = ActivityModel.Commessa;
|
||||||
ActivityFileList = await IntegryApiService.GetActivityFile(Id);
|
|
||||||
|
|
||||||
Users = await ManageData.GetTable<StbUser>();
|
Users = await ManageData.GetTable<StbUser>();
|
||||||
if (!ActivityModel.UserName.IsNullOrEmpty())
|
if (!ActivityModel.UserName.IsNullOrEmpty())
|
||||||
SelectedUser = Users.FindLast(x => x.UserName.Equals(ActivityModel.UserName));
|
SelectedUser = Users.FindLast(x => x.UserName.Equals(ActivityModel.UserName));
|
||||||
|
|
||||||
SelectedComessa = ActivityModel.Commessa;
|
if (!IsNew && Id != null)
|
||||||
|
ActivityFileList = await IntegryApiService.GetActivityFile(Id);
|
||||||
|
|
||||||
ActivityResult = await ManageData.GetTable<StbActivityResult>();
|
ActivityResult = await ManageData.GetTable<StbActivityResult>();
|
||||||
Clienti = await ManageData.GetClienti(new WhereCondContact { FlagStato = "A" });
|
Clienti = await ManageData.GetClienti(new WhereCondContact { FlagStato = "A" });
|
||||||
@@ -510,6 +533,20 @@
|
|||||||
OnAfterChangeValue();
|
OnAfterChangeValue();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private async Task OnCommessaClear()
|
||||||
|
{
|
||||||
|
ActivityModel.Commessa = null;
|
||||||
|
ActivityModel.CodJcom = null;
|
||||||
|
StateHasChanged();
|
||||||
|
}
|
||||||
|
|
||||||
|
private async Task OnUserClear()
|
||||||
|
{
|
||||||
|
ActivityModel.UserName = null;
|
||||||
|
ActivityType = [];
|
||||||
|
StateHasChanged();
|
||||||
|
}
|
||||||
|
|
||||||
private void OnAfterChangeTimeBefore()
|
private void OnAfterChangeTimeBefore()
|
||||||
{
|
{
|
||||||
if (ActivityModel.EstimatedTime is not null)
|
if (ActivityModel.EstimatedTime is not null)
|
||||||
|
|||||||
@@ -4,9 +4,9 @@
|
|||||||
@using salesbook.Shared.Components.Layout.Overlay
|
@using salesbook.Shared.Components.Layout.Overlay
|
||||||
@inject IAttachedService AttachedService
|
@inject IAttachedService AttachedService
|
||||||
|
|
||||||
<MudDialog Class="customDialog-form">
|
<MudDialog Class="customDialog-form disable-safe-area">
|
||||||
<DialogContent>
|
<DialogContent>
|
||||||
<HeaderLayout ShowProfile="false" SmallHeader="true" Cancel="true" OnCancel="() => MudDialog.Cancel()" Title="Aggiungi allegati"/>
|
<HeaderLayout ShowProfile="false" SmallHeader="true" Cancel="true" OnCancel="() => MudDialog.Cancel()" Title="@TitleModal"/>
|
||||||
|
|
||||||
@if (RequireNewName)
|
@if (RequireNewName)
|
||||||
{
|
{
|
||||||
@@ -71,9 +71,21 @@
|
|||||||
|
|
||||||
private AttachedDTO? Attached { get; set; }
|
private AttachedDTO? Attached { get; set; }
|
||||||
|
|
||||||
private bool RequireNewName { get; set; }
|
private bool _requireNewName;
|
||||||
|
private bool RequireNewName
|
||||||
|
{
|
||||||
|
get => _requireNewName;
|
||||||
|
set
|
||||||
|
{
|
||||||
|
_requireNewName = value;
|
||||||
|
TitleModal = _requireNewName ? "Nome allegato" : "Aggiungi allegati";
|
||||||
|
StateHasChanged();
|
||||||
|
}
|
||||||
|
}
|
||||||
private bool SelectTypePicture { get; set; }
|
private bool SelectTypePicture { get; set; }
|
||||||
|
|
||||||
|
private string TitleModal { get; set; } = "Aggiungi allegati";
|
||||||
|
|
||||||
private string? _newName;
|
private string? _newName;
|
||||||
private string? NewName
|
private string? NewName
|
||||||
{
|
{
|
||||||
@@ -102,17 +114,23 @@
|
|||||||
{
|
{
|
||||||
Attached = await AttachedService.SelectImageFromCamera();
|
Attached = await AttachedService.SelectImageFromCamera();
|
||||||
|
|
||||||
|
if (Attached != null)
|
||||||
|
{
|
||||||
RequireNewName = true;
|
RequireNewName = true;
|
||||||
StateHasChanged();
|
StateHasChanged();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private async Task OnGallery()
|
private async Task OnGallery()
|
||||||
{
|
{
|
||||||
Attached = await AttachedService.SelectImageFromGallery();
|
Attached = await AttachedService.SelectImageFromGallery();
|
||||||
|
|
||||||
|
if (Attached != null)
|
||||||
|
{
|
||||||
RequireNewName = true;
|
RequireNewName = true;
|
||||||
StateHasChanged();
|
StateHasChanged();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private async Task OnFile()
|
private async Task OnFile()
|
||||||
{
|
{
|
||||||
@@ -124,9 +142,12 @@
|
|||||||
{
|
{
|
||||||
Attached = await AttachedService.SelectPosition();
|
Attached = await AttachedService.SelectPosition();
|
||||||
|
|
||||||
|
if (Attached != null)
|
||||||
|
{
|
||||||
RequireNewName = true;
|
RequireNewName = true;
|
||||||
StateHasChanged();
|
StateHasChanged();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private void OnNewName()
|
private void OnNewName()
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -18,6 +18,7 @@ public class ActivityDTO : StbActivity
|
|||||||
|
|
||||||
public bool Deleted { get; set; }
|
public bool Deleted { get; set; }
|
||||||
|
|
||||||
|
[JsonPropertyName("stbPosizioni")]
|
||||||
public PositionDTO? Position { get; set; }
|
public PositionDTO? Position { get; set; }
|
||||||
|
|
||||||
public ActivityDTO Clone()
|
public ActivityDTO Clone()
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ public class PositionDTO
|
|||||||
[JsonPropertyName("id")]
|
[JsonPropertyName("id")]
|
||||||
public long? Id { get; set; }
|
public long? Id { get; set; }
|
||||||
|
|
||||||
[JsonPropertyName("description")]
|
[JsonPropertyName("descrizione")]
|
||||||
public string? Description { get; set; }
|
public string? Description { get; set; }
|
||||||
|
|
||||||
[JsonPropertyName("lat")]
|
[JsonPropertyName("lat")]
|
||||||
|
|||||||
@@ -25,5 +25,7 @@ public interface IManageDataService
|
|||||||
Task Delete<T>(T objectToDelete);
|
Task Delete<T>(T objectToDelete);
|
||||||
Task DeleteActivity(ActivityDTO activity);
|
Task DeleteActivity(ActivityDTO activity);
|
||||||
|
|
||||||
|
Task<List<ActivityDTO>> MapActivity(List<StbActivity>? activities);
|
||||||
|
|
||||||
Task ClearDb();
|
Task ClearDb();
|
||||||
}
|
}
|
||||||
@@ -72,8 +72,15 @@ public class IntegryApiService(IIntegryApiRestClient integryApiRestClient, IUser
|
|||||||
return integryApiRestClient.AuthorizedGet<object>($"activity/delete", queryParams);
|
return integryApiRestClient.AuthorizedGet<object>($"activity/delete", queryParams);
|
||||||
}
|
}
|
||||||
|
|
||||||
public Task<List<StbActivity>?> SaveActivity(ActivityDTO activity) =>
|
public Task<List<StbActivity>?> SaveActivity(ActivityDTO activity)
|
||||||
integryApiRestClient.AuthorizedPost<List<StbActivity>?>("crm/saveActivity", activity);
|
{
|
||||||
|
if (activity.CodJcom is null && userSession.ProfileDb != null && userSession.ProfileDb.Equals("smetar", StringComparison.OrdinalIgnoreCase))
|
||||||
|
{
|
||||||
|
activity.CodJcom = "0000";
|
||||||
|
}
|
||||||
|
|
||||||
|
return integryApiRestClient.AuthorizedPost<List<StbActivity>?>("crm/saveActivity", activity);
|
||||||
|
}
|
||||||
|
|
||||||
public Task<CRMCreateContactResponseDTO?> SaveContact(CRMCreateContactRequestDTO request) =>
|
public Task<CRMCreateContactResponseDTO?> SaveContact(CRMCreateContactRequestDTO request) =>
|
||||||
integryApiRestClient.AuthorizedPost<CRMCreateContactResponseDTO>("crm/createContact", request);
|
integryApiRestClient.AuthorizedPost<CRMCreateContactResponseDTO>("crm/createContact", request);
|
||||||
|
|||||||
@@ -4,8 +4,10 @@ namespace salesbook.Shared.Core.Utility;
|
|||||||
|
|
||||||
public static class UtilityString
|
public static class UtilityString
|
||||||
{
|
{
|
||||||
public static string ExtractInitials(string fullname)
|
public static string ExtractInitials(string? fullname)
|
||||||
{
|
{
|
||||||
|
if (fullname == null) return "";
|
||||||
|
|
||||||
return string.Concat(fullname
|
return string.Concat(fullname
|
||||||
.Split(' ', StringSplitOptions.RemoveEmptyEntries)
|
.Split(' ', StringSplitOptions.RemoveEmptyEntries)
|
||||||
.Take(3)
|
.Take(3)
|
||||||
|
|||||||
@@ -22,12 +22,13 @@
|
|||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="AutoMapper" Version="14.0.0" />
|
<PackageReference Include="AutoMapper" Version="14.0.0" />
|
||||||
<PackageReference Include="CodeBeam.MudBlazor.Extensions" Version="8.2.2" />
|
<PackageReference Include="CodeBeam.MudBlazor.Extensions" Version="8.2.4" />
|
||||||
<PackageReference Include="CommunityToolkit.Mvvm" Version="8.4.0" />
|
<PackageReference Include="CommunityToolkit.Mvvm" Version="8.4.0" />
|
||||||
<PackageReference Include="IntegryApiClient.Core" Version="1.2.1" />
|
<PackageReference Include="IntegryApiClient.Core" Version="1.2.1" />
|
||||||
<PackageReference Include="Microsoft.AspNetCore.Components.Authorization" Version="9.0.9" />
|
<PackageReference Include="Microsoft.AspNetCore.Components.Authorization" Version="9.0.9" />
|
||||||
<PackageReference Include="Microsoft.Maui.Essentials" Version="9.0.110" />
|
<PackageReference Include="Microsoft.Maui.Essentials" Version="9.0.110" />
|
||||||
<PackageReference Include="sqlite-net-pcl" Version="1.9.172" />
|
<PackageReference Include="SourceGear.sqlite3" Version="3.50.4.2" />
|
||||||
|
<PackageReference Include="sqlite-net-e" Version="1.10.0-beta2" />
|
||||||
<PackageReference Include="System.IdentityModel.Tokens.Jwt" Version="8.14.0" />
|
<PackageReference Include="System.IdentityModel.Tokens.Jwt" Version="8.14.0" />
|
||||||
<PackageReference Include="Microsoft.AspNetCore.Components.Web" Version="9.0.9" />
|
<PackageReference Include="Microsoft.AspNetCore.Components.Web" Version="9.0.9" />
|
||||||
<PackageReference Include="MudBlazor" Version="8.12.0" />
|
<PackageReference Include="MudBlazor" Version="8.12.0" />
|
||||||
|
|||||||
@@ -268,8 +268,7 @@ h1:focus { outline: none; }
|
|||||||
|
|
||||||
#app {
|
#app {
|
||||||
margin-top: env(safe-area-inset-top);
|
margin-top: env(safe-area-inset-top);
|
||||||
margin-bottom: env(safe-area-inset-bottom);
|
height: calc(100vh - env(safe-area-inset-top));
|
||||||
height: calc(100vh - env(safe-area-inset-top) - env(safe-area-inset-bottom));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.flex-column, .navbar-brand { padding-left: env(safe-area-inset-left); }
|
.flex-column, .navbar-brand { padding-left: env(safe-area-inset-left); }
|
||||||
|
|||||||
@@ -8,4 +8,6 @@
|
|||||||
--mud-default-borderradius: 20px !important;
|
--mud-default-borderradius: 20px !important;
|
||||||
--m-page-x: 1rem;
|
--m-page-x: 1rem;
|
||||||
--mh-header: 4rem;
|
--mh-header: 4rem;
|
||||||
|
|
||||||
|
--light-card-background: hsl(from var(--mud-palette-background-gray) h s 97%);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,6 +5,10 @@
|
|||||||
margin-bottom: 1rem;
|
margin-bottom: 1rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.customDialog-form.disable-safe-area .mud-dialog-content { margin-top: unset !important; }
|
||||||
|
|
||||||
|
.customDialog-form.disable-safe-area .content { height: 100% !important; }
|
||||||
|
|
||||||
.customDialog-form .content {
|
.customDialog-form .content {
|
||||||
height: calc(100vh - (.6rem + 40px));
|
height: calc(100vh - (.6rem + 40px));
|
||||||
overflow: auto;
|
overflow: auto;
|
||||||
@@ -12,6 +16,14 @@
|
|||||||
scrollbar-width: none;
|
scrollbar-width: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@supports (-webkit-touch-callout: none) {
|
||||||
|
.customDialog-form .content { height: calc(100vh - (.6rem + 40px) - env(safe-area-inset-top)) !important; }
|
||||||
|
|
||||||
|
.customDialog-form.disable-safe-area .content { height: 100% !important; }
|
||||||
|
|
||||||
|
.customDialog-form.disable-safe-area .mud-dialog-content { margin-top: unset !important; }
|
||||||
|
}
|
||||||
|
|
||||||
.customDialog-form .header { padding: 0 !important; }
|
.customDialog-form .header { padding: 0 !important; }
|
||||||
|
|
||||||
.customDialog-form .content::-webkit-scrollbar { display: none; }
|
.customDialog-form .content::-webkit-scrollbar { display: none; }
|
||||||
@@ -31,6 +43,8 @@
|
|||||||
padding: .4rem 1rem !important;
|
padding: .4rem 1rem !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.input-card.clearButton.custom-border-bottom { border-bottom: .1rem solid var(--card-border-color); }
|
||||||
|
|
||||||
.input-card > .divider { margin: 0 !important; }
|
.input-card > .divider { margin: 0 !important; }
|
||||||
|
|
||||||
.form-container {
|
.form-container {
|
||||||
@@ -92,7 +106,7 @@
|
|||||||
|
|
||||||
.container-button {
|
.container-button {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
box-shadow: var(--custom-box-shadow);
|
background: var(--light-card-background);
|
||||||
padding: .5rem 0;
|
padding: .5rem 0;
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
margin-bottom: 2rem;
|
margin-bottom: 2rem;
|
||||||
|
|||||||
@@ -29,11 +29,6 @@ public class ManageDataService : IManageDataService
|
|||||||
throw new NotImplementedException();
|
throw new NotImplementedException();
|
||||||
}
|
}
|
||||||
|
|
||||||
public Task<List<ContactDTO>> GetContact(WhereCondContact whereCond)
|
|
||||||
{
|
|
||||||
throw new NotImplementedException();
|
|
||||||
}
|
|
||||||
|
|
||||||
public Task<ContactDTO?> GetSpecificContact(string codAnag, bool IsContact)
|
public Task<ContactDTO?> GetSpecificContact(string codAnag, bool IsContact)
|
||||||
{
|
{
|
||||||
throw new NotImplementedException();
|
throw new NotImplementedException();
|
||||||
@@ -74,6 +69,11 @@ public class ManageDataService : IManageDataService
|
|||||||
throw new NotImplementedException();
|
throw new NotImplementedException();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Task<List<ActivityDTO>> MapActivity(List<StbActivity>? activities)
|
||||||
|
{
|
||||||
|
throw new NotImplementedException();
|
||||||
|
}
|
||||||
|
|
||||||
public Task ClearDb()
|
public Task ClearDb()
|
||||||
{
|
{
|
||||||
throw new NotImplementedException();
|
throw new NotImplementedException();
|
||||||
|
|||||||
Reference in New Issue
Block a user