This commit is contained in:
2018-06-29 19:47:36 +00:00
commit be7f501333
3769 changed files with 1425961 additions and 0 deletions

View File

@@ -0,0 +1,75 @@
using System;
//The AyaNova business object library:
using GZTW.AyaNova.BLL;
//The security library required for
//processing the login
using CSLA.Security;
//Used for login confirmation
using System.Threading;
namespace UnNotifyClients
{
/// <summary>
/// Turn off notification to all clients
///
/// This is a sample console (command line) application showing how to interact with AyaNova api
/// from the command line.
///
/// This was originally developed for a customer who needed to reset a *lot* of clients to turn off notification.
/// </summary>
class Program
{
static void Main(string[] args)
{
try
{
GZTW.AyaNova.BLL.AyaBizUtils.Initialize();
}
catch (Exception ex)
{
//"crack" the exception to get to the innermost exception
while (ex.InnerException != null)
ex = ex.InnerException;
Console.WriteLine("Error initializing AyaNova connection!\r\nAre you running this from the AyaNova program folder?\r\nFull error is:\r\n" + ex.Message);
return;
}
Console.WriteLine("Enter the login name for the administrator:");
string UserName=Console.ReadLine();
Console.WriteLine("Enter the password for the administrator:");
string PassWord = Console.ReadLine();
AyaBizUtils.Login(UserName, PassWord);
//confirm the user is logged in:
if (Thread.CurrentPrincipal.Identity.IsAuthenticated == false)
{
//Nope, they are not authenticated so
//show an error and bail out
Console.WriteLine("Login failed, check the username and password.");
return;
}
//Connected and logged in and ready to roll
ClientPickList cpl = ClientPickList.GetList(false);
Console.WriteLine("Found " + cpl.Count.ToString() + " clients to process.");
foreach (ClientPickList.ClientPickListInfo i in cpl)
{
Client c = Client.GetItem(i.ID);
c.SendNotifications = false;
c.Save();
Console.WriteLine(i.Name + " - notification turned off");
}
Console.WriteLine("All done!");
}//end main
}//end class
}//end namespace

View File

@@ -0,0 +1,36 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("UnNotifyClients")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("UnNotifyClients")]
[assembly: AssemblyCopyright("Copyright © 2010")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("ef772ff6-e31b-43c3-843c-8f48674e86d1")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]

View File

@@ -0,0 +1,84 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProductVersion>9.0.30729</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{6FEB9A17-5C8A-4BB6-A409-5C77AD25A491}</ProjectGuid>
<OutputType>Exe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>UnNotifyClients</RootNamespace>
<AssemblyName>UnNotifyClients</AssemblyName>
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="CSLA, Version=6.1.0.0, Culture=neutral, PublicKeyToken=df66a8d8e49833d3, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\Program Files\Ground Zero Tech-Works Inc\AyaNova\CSLA.dll</HintPath>
</Reference>
<Reference Include="CSLA.Core.Bindablebase, Version=6.1.0.0, Culture=neutral, PublicKeyToken=df66a8d8e49833d3, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\Program Files\Ground Zero Tech-Works Inc\AyaNova\CSLA.Core.Bindablebase.dll</HintPath>
</Reference>
<Reference Include="CSLA.Server.DataPortal, Version=6.1.0.0, Culture=neutral, PublicKeyToken=df66a8d8e49833d3, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\Program Files\Ground Zero Tech-Works Inc\AyaNova\CSLA.Server.DataPortal.dll</HintPath>
</Reference>
<Reference Include="FirebirdSql.Data.FirebirdClient, Version=2.5.0.0, Culture=neutral, PublicKeyToken=3750abcc3150b00c, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\Program Files\Ground Zero Tech-Works Inc\AyaNova\FirebirdSql.Data.FirebirdClient.dll</HintPath>
</Reference>
<Reference Include="GZTW.AyaNova.BLL, Version=6.1.0.0, Culture=neutral, PublicKeyToken=df66a8d8e49833d3, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\Program Files\Ground Zero Tech-Works Inc\AyaNova\GZTW.AyaNova.BLL.dll</HintPath>
</Reference>
<Reference Include="GZTW.Data, Version=6.1.0.0, Culture=neutral, PublicKeyToken=df66a8d8e49833d3, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\Program Files\Ground Zero Tech-Works Inc\AyaNova\GZTW.Data.dll</HintPath>
</Reference>
<Reference Include="GZTW.Profile, Version=6.1.0.0, Culture=neutral, PublicKeyToken=df66a8d8e49833d3, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\Program Files\Ground Zero Tech-Works Inc\AyaNova\GZTW.Profile.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Data.DataSetExtensions">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>

View File

@@ -0,0 +1,20 @@
Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "UnNotifyClients", "UnNotifyClients\UnNotifyClients.csproj", "{6FEB9A17-5C8A-4BB6-A409-5C77AD25A491}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{6FEB9A17-5C8A-4BB6-A409-5C77AD25A491}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{6FEB9A17-5C8A-4BB6-A409-5C77AD25A491}.Debug|Any CPU.Build.0 = Debug|Any CPU
{6FEB9A17-5C8A-4BB6-A409-5C77AD25A491}.Release|Any CPU.ActiveCfg = Release|Any CPU
{6FEB9A17-5C8A-4BB6-A409-5C77AD25A491}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
EndGlobal

Binary file not shown.

View File

@@ -0,0 +1,75 @@
using System;
//The AyaNova business object library:
using GZTW.AyaNova.BLL;
//The security library required for
//processing the login
using CSLA.Security;
//Used for login confirmation
using System.Threading;
namespace UnNotifyClients
{
/// <summary>
/// Turn off notification to all clients
///
/// This is a sample console (command line) application showing how to interact with AyaNova api
/// from the command line.
///
/// This was originally developed for a customer who needed to reset a *lot* of clients to turn off notification.
/// </summary>
class Program
{
static void Main(string[] args)
{
try
{
GZTW.AyaNova.BLL.AyaBizUtils.Initialize();
}
catch (Exception ex)
{
//"crack" the exception to get to the innermost exception
while (ex.InnerException != null)
ex = ex.InnerException;
Console.WriteLine("Error initializing AyaNova connection!\r\nAre you running this from the AyaNova program folder?\r\nFull error is:\r\n" + ex.Message);
return;
}
Console.WriteLine("Enter the login name for the administrator:");
string UserName=Console.ReadLine();
Console.WriteLine("Enter the password for the administrator:");
string PassWord = Console.ReadLine();
AyaBizUtils.Login(UserName, PassWord);
//confirm the user is logged in:
if (Thread.CurrentPrincipal.Identity.IsAuthenticated == false)
{
//Nope, they are not authenticated so
//show an error and bail out
Console.WriteLine("Login failed, check the username and password.");
return;
}
//Connected and logged in and ready to roll
ClientPickList cpl = ClientPickList.GetList(false);
Console.WriteLine("Found " + cpl.Count.ToString() + " clients to process.");
foreach (ClientPickList.ClientPickListInfo i in cpl)
{
Client c = Client.GetItem(i.ID);
c.SendNotifications = false;
c.Save();
Console.WriteLine(i.Name + " - notification turned off");
}
Console.WriteLine("All done!");
}//end main
}//end class
}//end namespace

View File

@@ -0,0 +1,36 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("UnNotifyClients")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("UnNotifyClients")]
[assembly: AssemblyCopyright("Copyright © 2010")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("ef772ff6-e31b-43c3-843c-8f48674e86d1")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]

View File

@@ -0,0 +1,89 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProductVersion>9.0.30729</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{6FEB9A17-5C8A-4BB6-A409-5C77AD25A491}</ProjectGuid>
<OutputType>Exe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>UnNotifyClients</RootNamespace>
<AssemblyName>UnNotifyClients</AssemblyName>
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<FileUpgradeFlags>
</FileUpgradeFlags>
<UpgradeBackupLocation>
</UpgradeBackupLocation>
<OldToolsVersion>3.5</OldToolsVersion>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="CSLA, Version=6.1.0.0, Culture=neutral, PublicKeyToken=df66a8d8e49833d3, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\Program Files\Ground Zero Tech-Works Inc\AyaNova\CSLA.dll</HintPath>
</Reference>
<Reference Include="CSLA.Core.Bindablebase, Version=6.1.0.0, Culture=neutral, PublicKeyToken=df66a8d8e49833d3, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\Program Files\Ground Zero Tech-Works Inc\AyaNova\CSLA.Core.Bindablebase.dll</HintPath>
</Reference>
<Reference Include="CSLA.Server.DataPortal, Version=6.1.0.0, Culture=neutral, PublicKeyToken=df66a8d8e49833d3, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\Program Files\Ground Zero Tech-Works Inc\AyaNova\CSLA.Server.DataPortal.dll</HintPath>
</Reference>
<Reference Include="FirebirdSql.Data.FirebirdClient, Version=2.5.0.0, Culture=neutral, PublicKeyToken=3750abcc3150b00c, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\Program Files\Ground Zero Tech-Works Inc\AyaNova\FirebirdSql.Data.FirebirdClient.dll</HintPath>
</Reference>
<Reference Include="GZTW.AyaNova.BLL, Version=6.1.0.0, Culture=neutral, PublicKeyToken=df66a8d8e49833d3, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\Program Files\Ground Zero Tech-Works Inc\AyaNova\GZTW.AyaNova.BLL.dll</HintPath>
</Reference>
<Reference Include="GZTW.Data, Version=6.1.0.0, Culture=neutral, PublicKeyToken=df66a8d8e49833d3, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\Program Files\Ground Zero Tech-Works Inc\AyaNova\GZTW.Data.dll</HintPath>
</Reference>
<Reference Include="GZTW.Profile, Version=6.1.0.0, Culture=neutral, PublicKeyToken=df66a8d8e49833d3, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\Program Files\Ground Zero Tech-Works Inc\AyaNova\GZTW.Profile.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Data.DataSetExtensions">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>