Rename layout

This commit is contained in:
Chris Payne
2025-07-08 19:43:33 -04:00
parent 9657fe7133
commit dcfa569a7e
2 changed files with 32 additions and 6 deletions

View File

@@ -1,6 +1,6 @@
<Window xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="InstaProvision - SVS Tools"
Title="InstaClient - SVS Tools"
Height="550" Width="480"
WindowStartupLocation="CenterScreen"
Background="#1e1e2f"
@@ -100,7 +100,7 @@
<Image Source="https://i.ibb.co/vCTJYn2j/svs-logo-nav-wh.png" Height="60" HorizontalAlignment="Center" Margin="0,0,0,10"/>
<!-- Title -->
<TextBlock Text="Provision Company" FontSize="20" FontWeight="SemiBold" Foreground="White" HorizontalAlignment="Center" Margin="0,0,0,10"/>
<TextBlock Text="Provision Client" FontSize="20" FontWeight="SemiBold" Foreground="White" HorizontalAlignment="Center" Margin="0,0,0,10"/>
<!-- Main Content -->
<StackPanel Orientation="Vertical">
@@ -119,7 +119,7 @@
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center" Margin="0,25,0,0">
<Button Name="LoginBtn" Content="Login with Microsoft" Width="180" Height="38" Margin="5" Style="{StaticResource FancyButton}"/>
<Button Name="SubmitBtn" Content="Provision" Width="120" Height="38" Margin="5" Style="{StaticResource FancyButton}"/>
<Button Name="SubmitBtn" Content="Provision Now" Width="120" Height="38" Margin="5" Style="{StaticResource FancyButton}"/>
</StackPanel>
<TextBlock Name="StatusBlock" Foreground="LightGreen" TextAlignment="Center" Margin="0,15,0,0"/>

View File

@@ -14,9 +14,35 @@ Import-Module MSAL.PS
Write-Host "[INFO] MSAL.PS module loaded."
# Load config and tool modules
. "$PSScriptRoot\config.ps1"
. "$PSScriptRoot\tools\autotask.ps1"
. "$PSScriptRoot\tools\dattormm.ps1"
$urls = @{
autotask = "https://git.svstools.com/cpayne/InstaClientPS/raw/branch/main/tools/autotask.ps1"
datto = "https://git.svstools.com/cpayne/InstaClientPS/raw/branch/main/tools/dattormm.ps1"
config = "https://git.svstools.com/cpayne/InstaClientPS/raw/branch/main/config.ps1"
}
$xamlUrl = "https://git.svstools.com/cpayne/InstaClientPS/raw/branch/main/layout.xaml"
try {
$xamlContent = Invoke-WebRequest -Uri $xamlUrl -UseBasicParsing -ErrorAction Stop
[xml]$xaml = $xamlContent.Content
Write-Host "[INFO] XAML loaded from remote URL."
} catch {
Write-Host ("[ERROR] Failed to load XAML from {0}: {1}" -f $xamlUrl, $_.Exception.Message)
exit 1
}
foreach ($name in $urls.Keys) {
try {
$scriptText = Invoke-WebRequest -Uri $urls[$name] -UseBasicParsing
Invoke-Expression $scriptText.Content
Write-Host "[INFO] Loaded $name.ps1 from URL."
} catch {
Write-Host "[ERROR] Failed to load $name.ps1: $($_.Exception.Message)"
exit 1
}
}
Write-Host "[INFO] Config and tool modules loaded."
# Load WPF assemblies