Lots of work on Init Wizard. Not complete. NOT DEPLOYABLE.
This commit is contained in:
+1
-1
@@ -1740,7 +1740,7 @@ namespace Activizr
|
||||
int geoId = Int32.Parse(parts[0]);
|
||||
string designation = parts[1].Trim();
|
||||
|
||||
PirateDb.GetDatabase().CreateGeographyOfficialDesignation(geoId, GeographyLevel.Municipality, 1, designation);
|
||||
PirateDb.GetDatabaseForWriting().CreateGeographyOfficialDesignation(geoId, GeographyLevel.Municipality, 1, designation);
|
||||
line = reader.ReadLine();
|
||||
}
|
||||
}
|
||||
|
||||
+15
-12
@@ -5,23 +5,26 @@ using System.Text;
|
||||
|
||||
namespace Activizr.Database
|
||||
{
|
||||
public class Configuration
|
||||
public partial class PirateDb
|
||||
{
|
||||
public bool IsConfigured()
|
||||
public class Configuration
|
||||
{
|
||||
return String.IsNullOrEmpty(DatabaseConnect.Default.Admin);
|
||||
}
|
||||
public static bool IsConfigured()
|
||||
{
|
||||
return String.IsNullOrEmpty(DatabaseConnect.Default.Admin);
|
||||
}
|
||||
|
||||
public bool SetConfiguration (string readConnect, string writeConnect, string adminConnect)
|
||||
{
|
||||
DatabaseConnect.Default["Read"] = readConnect;
|
||||
DatabaseConnect.Default["Write"] = writeConnect;
|
||||
DatabaseConnect.Default["Admin"] = adminConnect;
|
||||
DatabaseConnect.Default.Save();
|
||||
public static bool SetConfiguration(string readConnect, string writeConnect, string adminConnect)
|
||||
{
|
||||
DatabaseConnect.Default["Read"] = readConnect;
|
||||
DatabaseConnect.Default["Write"] = writeConnect;
|
||||
DatabaseConnect.Default["Admin"] = adminConnect;
|
||||
DatabaseConnect.Default.Save();
|
||||
|
||||
// TODO: Test a connect string to see if we can read, and return true only on success
|
||||
// TODO: Test a connect string to see if we can read, and return true only on success
|
||||
|
||||
return true;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,138 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="Init_SidebarActions_None" xml:space="preserve">
|
||||
<value>No other actions are available until setup is completed.</value>
|
||||
</data>
|
||||
<data name="Init_SidebarInfo_Welcome" xml:space="preserve">
|
||||
<value>Welcome to Activizr! This is what the interface looks like, but it's not active yet - first, we'll go through some steps to set up your installation. You'll be up and running in about three minutes.</value>
|
||||
<comment>Info box on database setup screen</comment>
|
||||
</data>
|
||||
<data name="Init_SidebarTodo_CompleteSetup" xml:space="preserve">
|
||||
<value>Complete setup.</value>
|
||||
</data>
|
||||
<data name="Init_UserInfo_InstallingAdmin" xml:space="preserve">
|
||||
<value>Systems Administrator</value>
|
||||
<comment>Displayed in lieu of logged-in-username</comment>
|
||||
</data>
|
||||
<data name="Init_UserInfo_NoOrgsYet" xml:space="preserve">
|
||||
<value>No organizations yet</value>
|
||||
<comment>Displayed in lieu of organization name</comment>
|
||||
</data>
|
||||
</root>
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 884 B |
Binary file not shown.
|
After Width: | Height: | Size: 822 B |
Binary file not shown.
|
After Width: | Height: | Size: 3.1 KiB |
@@ -0,0 +1,383 @@
|
||||
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="Pages_v5_Init_Default" %>
|
||||
<%@ Register Src="~/Controls/v5/Base/LanguageSelector.ascx" TagName="LanguageSelector" TagPrefix="act5" %>
|
||||
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head id="Head1" runat="server">
|
||||
|
||||
<!-- jQuery and plugins -->
|
||||
<script language="javascript" type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js" ></script>
|
||||
<script language="javascript" type="text/javascript" src="/Scripts/jquery.leanModal.min.js" ></script>
|
||||
<script language="javascript" type="text/javascript" src="/Scripts/jquery.smartWizard-2.0.min.js"></script>
|
||||
|
||||
<!-- fonts -->
|
||||
<link href='https://fonts.googleapis.com/css?family=Permanent+Marker' rel='stylesheet' type='text/css' />
|
||||
<link href='https://fonts.googleapis.com/css?family=Ubuntu:light,regular,500,bold' rel='stylesheet' type='text/css' />
|
||||
<link href='https://fonts.googleapis.com/css?family=Arimo:regular,italic,bold,bolditalic' rel='stylesheet' type='text/css' />
|
||||
|
||||
<!-- page title -->
|
||||
<title>Activizr - Initialize Installation</title>
|
||||
|
||||
<!-- telerik style sheet manager, followed by style sheet -->
|
||||
<telerik:RadStyleSheetManager id="RadStyleSheetManager" runat="server" />
|
||||
<link href="/Style/style-v5.css" rel="stylesheet" type="text/css" />
|
||||
<link href="WizardStyle.css" rel="stylesheet" type="text/css" />
|
||||
|
||||
<!-- initialize all modal popups -->
|
||||
<script language="javascript" type="text/javascript">
|
||||
$(function () {
|
||||
$("a[rel*=leanModal]").leanModal();
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<form id="form2" runat="server">
|
||||
<telerik:RadScriptManager ID="RadScriptManager1" runat="server" />
|
||||
<script type="text/javascript">
|
||||
|
||||
|
||||
$(document).ready(function () {
|
||||
// Initialize Smart Wizard
|
||||
$('#wizard').smartWizard({ transitionEffect: 'fade' });
|
||||
});
|
||||
|
||||
</script>
|
||||
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
|
||||
</telerik:RadAjaxManager>
|
||||
|
||||
<telerik:RadSkinManager ID="RadSkinManager1" Runat="server" Skin="WebBlue">
|
||||
</telerik:RadSkinManager>
|
||||
|
||||
<!-- Main menu, dynamically constructed -->
|
||||
|
||||
<div class="center980px">
|
||||
<div class="currentuserinfo"><div style="background-image:url('/Images/Icons/iconshock-user-16px.png');background-repeat:no-repeat;padding-left:16px;float:left"><asp:Label ID="LabelCurrentUserName" runat="server" /> | </div><div style="background-image:url('/Images/Icons/iconshock-workchair-16px.png');background-repeat:no-repeat;padding-left:17px;float:left"><asp:Label ID="LabelCurrentOrganizationName" runat="server" /> | </div><div style="background-image:url('/Images/Icons/iconshock-gamepad-16px.png');background-repeat:no-repeat;padding-left:20px;float:left"><asp:Label ID="LabelPreferences" runat="server" /> | </div><asp:Image ID="ImageCultureIndicator" runat="server" ImageUrl="~/Images/Flags/uk.png" /></div>
|
||||
<div class="logoimage"><a href="/"><img style="border:none" src="/Style/Images/activizr-v5-pirateedition-logo.png" alt="Activizr Logo" /></a></div>
|
||||
<div class="break"></div>
|
||||
<div class="topmenu">
|
||||
<div class="searchbox"><asp:TextBox ID="SearchBox" runat="server" /></div>
|
||||
<telerik:RadMenu ID="MainMenu" runat="server" BackColor="Transparent" Font-Bold="true">
|
||||
<Items>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ People" UserLevel="1" Permission="All" GlobalResourceKey="Menu5_People">
|
||||
<Items>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Log Activism" Permission="All" UserLevel="1" GlobalResourceKey="Menu5_People_LogActivism" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Self-Signup Page" Permission="All" UserLevel="1" GlobalResourceKey="Menu5_People_SelfSignup" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="2" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Add Member" Permission="Members:Write" UserLevel="2" GlobalResourceKey="Menu5_People_AddMember" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ List Members" Permission="Members:Read" UserLevel="2" GlobalResourceKey="Menu5_People_ListMembers" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Manage Volunteers" Permission="Responsibilities:Write" UserLevel="2" GlobalResourceKey="Menu5_People_ManageVolunteers" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="2" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ New conference" Permission="All" UserLevel="2" GlobalResourceKey="Menu5_People_NewConference" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Manage conferences" Permission="All" UserLevel="2" GlobalResourceKey="Menu5_People_ManageConferences" />
|
||||
</Items>
|
||||
</telerik:RadMenuItem>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Communications" Permission="All" UserLevel="2" GlobalResourceKey="Menu5_Communications">
|
||||
<Items>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Mass Mailing" Permission="MemberMail:Write,Newsletter:Write" UserLevel="2" GlobalResourceKey="Menu5_Communications_MassMailing" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Edit Automail Text" Permission="MemberMail:Write" UserLevel="2" GlobalResourceKey="Menu5_Communications_EditAutomailText" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="2" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Received Paper Letter" Permission="All" UserLevel="2" GlobalResourceKey="Menu5_Communications_ReceivedPaperLetter" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Manage Paper Inbox" Permission="All" UserLevel="2" GlobalResourceKey="Menu5_Communications_PaperInbox" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Manage Mail Inbox" Permission="SupportMail:Read" UserLevel="2" GlobalResourceKey="Menu5_Communications_MailInbox" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Manage Text Inbox" Permission="SupportText:Read" UserLevel="2" GlobalResourceKey="Menu5_Communications_TextInbox" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="2" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Text Activists" Permission="ActivistText:Write" UserLevel="2" GlobalResourceKey="Menu5_Communications_TextActivists" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="2" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Manager Reporter List" Permission="ReporterList:Read" UserLevel="2" GlobalResourceKey="Menu5_Communications_ReporterList" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Send Press Release" Permission="PressReleases:Write" UserLevel="2" GlobalResourceKey="Menu5_Communications_SendPressRelease" />
|
||||
</Items>
|
||||
</telerik:RadMenuItem>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Financial" Permission="CanSeeSelf" UserLevel="1" GlobalResourceKey="Menu5_Financial">
|
||||
<Items>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Claim Refund For Expense" Permission="All" UserLevel="1" GlobalResourceKey="Menu5_Financial_ClaimExpense" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Request Cash Advance" Permission="All" UserLevel="1" GlobalResourceKey="Menu5_Financial_RequestCashAdvance" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Create Purchase Order" Permission="All" UserLevel="2" GlobalResourceKey="Menu5_Financial_CreatePurchaseOrder" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="1" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ View Budget, Actuals" Permission="All" UserLevel="1" GlobalResourceKey="Menu5_Financial_ViewBudgetActuals" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ View Liquidity Forecast" Permission="All" UserLevel="2" GlobalResourceKey="Menu5_Financial_ViewLiquidityForecast" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="2" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Manage Budget" Permission="All" UserLevel="2" GlobalResourceKey="Menu5_Financial_ManageBudget" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Attest Costs" Permission="All" UserLevel="2" GlobalResourceKey="Menu5_Financial_AttestCosts" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="2" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Send Invoice" Permission="Economy:Write" UserLevel="2" GlobalResourceKey="Menu5_Financial_SendInvoice" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Received Invoice" Permission="Economy:Write" UserLevel="2" GlobalResourceKey="Menu5_Financial_ReceivedInvoice" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Gigs Assistant" Permission="All" UserLevel="3" GlobalResourceKey="Menu5_Financial_GigsAssistant" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="3" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ List" Permission="Economy:Read" UserLevel="3" GlobalResourceKey="Menu5_Financial_List">
|
||||
<Items>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Expense Claims & Cash Requests" Permission="Economy:Read" UserLevel="3" GlobalResourceKey="Menu5_Financial_List_ExpenseClaims" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Inbound Invoices" Permission="Economy:Read" UserLevel="3" GlobalResourceKey="Menu5_Financial_List_InboundInvoices" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Salaries" Permission="Payroll:Read" UserLevel="3" GlobalResourceKey="Menu5_Financial_List_Salaries" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Outbound Invoices" Permission="Economy:Read" UserLevel="3" GlobalResourceKey="Menu5_Financial_List_OutboundInvoices" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Outstanding Cash Advances" Permission="Economy:Read" UserLevel="3" GlobalResourceKey="Menu5_Financial_List_OutstandingAdvances" />
|
||||
</Items>
|
||||
</telerik:RadMenuItem>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Pay Out Money" Permission="Economy:Write" UserLevel="3" GlobalResourceKey="Menu5_Financial_PayOutMoney" />
|
||||
</Items>
|
||||
</telerik:RadMenuItem>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Ledgers" Permission="All" UserLevel="3" GlobalResourceKey="Menu5_Ledgers">
|
||||
<Items>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Balance Sheet" Permission="All" UserLevel="3" GlobalResourceKey="Menu5_Ledgers_BalanceSheet" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Result Sheet" Permission="All" UserLevel="3" GlobalResourceKey="Menu5_Ledgers_ResultSheet" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="3" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Audit Ledgers" Permission="EconomyDetail:Read" UserLevel="3" GlobalResourceKey="Menu5_Ledgers_AuditLedgers" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Account Plan" Permission="Economy:Read" UserLevel="3" GlobalResourceKey="Menu5_Ledgers_AccountPlan" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Set Budget" NavigateUrl="~/Pages/v5/Ledgers/SetRootBudgets.aspx" ImageUrl="~/Images/PageIcons/iconshock-moneybag-16px.png" Permission="Financial:Write" UserLevel="3" GlobalResourceKey="Menu5_Ledgers_SetBudgets" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="3" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Upload Bank Files" NavigateUrl="~/Pages/v5/Ledgers/UploadBankFiles.aspx" ImageUrl="~/Images/PageIcons/iconshock-bank-16px.png" Permission="Economy:Write" UserLevel="3" GlobalResourceKey="Menu5_Ledgers_UploadBankFiles" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="3" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Debug Ledgers" NavigateUrl="~/Pages/v5/Ledgers/DebugLedgers.aspx" ImageUrl="~/Images/PageIcons/iconshock-tester-16px.png" Permission="EconomyDetail:Read" UserLevel="3" GlobalResourceKey="Menu5_Ledgers_DebugLedgers" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Close Ledgers" NavigateUrl="~/Pages/v5/Ledgers/CloseLedgers.aspx" Template="CloseLedgers" Dynamic="true" ImageUrl="~/Images/PageIcons/iconshock-calculator-lock-16px.png" Permission="EconomyDetail:Write" UserLevel="3" GlobalResourceKey="Menu5_Ledgers_CloseLedgers" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="3" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Payroll" Permission="Payroll:Read" UserLevel="3" GlobalResourceKey="Menu5_Ledgers_Payroll" />
|
||||
</Items>
|
||||
</telerik:RadMenuItem>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Governance" Permission="All" UserLevel="1" GlobalResourceKey="Menu5_Governance">
|
||||
<Items>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Vote" NavigateUrl="~/Pages/v5/Governance/Vote.aspx" ImageUrl="~/Images/PageIcons/iconshock-vote-16px.png" Permission="All" UserLevel="1" GlobalResourceKey="Menu5_Governance_Vote" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Motions" NavigateUrl="~/Pages/v5/Governance/ListMotions.aspx" ImageUrl="~/Images/PageIcons/iconshock-motions-16px.png" Permission="All" UserLevel="1" GlobalResourceKey="Menu5_Governance_Motions" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Candidates" Permission="All" UserLevel="1" GlobalResourceKey="Menu5_Governance_Candidates" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Create Voting List" Permission="All" UserLevel="2" GlobalResourceKey="Menu5_Governance_CreateVotingList" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="3" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Meeting Admin" Permission="Meetings:Read" UserLevel="3" GlobalResourceKey="Menu5_Governance_MeetingAdmin" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Meeting Admin for Board" Permission="MeetingsBoard:Read" UserLevel="3" GlobalResourceKey="Menu5_Governance_MeetingBoardAdmin" />
|
||||
</Items>
|
||||
</telerik:RadMenuItem>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Organization" Permission="All" UserLevel="1" GlobalResourceKey="Menu5_Organization">
|
||||
<Items>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Organization Chart" Permission="All" UserLevel="1" GlobalResourceKey="Menu5_Organization_OrganizationChart" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Available Responsibilities" Permission="All" UserLevel="1" GlobalResourceKey="Menu5_Organization_AvailableResponsibilities" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Member Statistics" Permission="All" UserLevel="1" GlobalResourceKey="Menu5_Organization_MemberStatistics" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="3" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Organization Settings" Permission="Organzation:Read" UserLevel="3" GlobalResourceKey="Menu5_Organization_Settings" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Organization Responsibilities" Permission=":Read" UserLevel="3" GlobalResourceKey="Menu5_Organization_Responsibilities" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Suborganization Tree" Permission=":Read" UserLevel="3" GlobalResourceKey="Menu5_Organization_SuborganizationTree" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="3" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Communication Templates" Permission="Communications:Read" UserLevel="3" GlobalResourceKey="Menu5_Organization_CommunicationTemplates" >
|
||||
<Items>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Press Release" Permission="Communications:Read" UserLevel="3" GlobalResourceKey="Menu5_Organization_CommunicationTemplates_PressRelease" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Mass Mailing" Permission="Communications:Read" UserLevel="3" GlobalResourceKey="Menu5_Organization_CommunicationTemplates_MassMailing" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Newsletter" Permission="Communications:Read" UserLevel="3" GlobalResourceKey="Menu5_Organization_CommunicationTemplates_Newsletter" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Invoice" Permission="Communications:Read" UserLevel="3" GlobalResourceKey="Menu5_Organization_CommunicationTemplates_Invoice" />
|
||||
</Items>
|
||||
</telerik:RadMenuItem>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Communication Feeds" Permission="Communications:Read" UserLevel="3" GlobalResourceKey="Menu5_Organization_Feeds" >
|
||||
<Items>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Newsletters" Permission="Newsletters:Write" UserLevel="3" GlobalResourceKey="Menu5_Organization_Feeds_Newsletter" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Press Releases" Permission="PressReleases:Write" UserLevel="3" GlobalResourceKey="Menu5_Organization_Feeds_PressReleases" />
|
||||
</Items>
|
||||
</telerik:RadMenuItem>
|
||||
</Items>
|
||||
</telerik:RadMenuItem>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Admin" Permission="All" UserLevel="4" GlobalResourceKey="Menu5_Administration">
|
||||
<Items>
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Organization Clusters" Permission="All" UserLevel="4" GlobalResourceKey="Menu5_Administration_OrganizationClusters" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Manage Geography" Permission="All" UserLevel="4" GlobalResourceKey="Menu5_Administration_GeographyTree" />
|
||||
<telerik:RadMenuItem runat="server" Text="XYZ Access Control Lists" Permission="All" UserLevel="4" GlobalResourceKey="Menu5_Administration_AccessControlLists" />
|
||||
<telerik:RadMenuItem runat="server" IsSeparator="true" UserLevel="4" />
|
||||
<telerik:RadMenuItem runat="server" Dynamic="true" Template="Build#" Permission="All" UserLevel="4" NotaBene="This is a special case -- the build number is dynamically inserted for text" />
|
||||
</Items>
|
||||
</telerik:RadMenuItem>
|
||||
</Items>
|
||||
</telerik:RadMenu>
|
||||
</div>
|
||||
|
||||
<div class="mainbar">
|
||||
<div id="page-icon-encaps"><asp:Image ID="IconPage" runat="server" ImageUrl="~/Images/PageIcons/iconshock-ignitionkey-40px.png" /></div><h1><asp:Label ID="LabelPageTitle" Text="Installation" runat="server" /></h1>
|
||||
|
||||
<div class="box">
|
||||
<div class="content">
|
||||
|
||||
<div id="wizard" class="swMain">
|
||||
<ul>
|
||||
<li><a href="#step-1">
|
||||
<label class="stepNumber">1</label>
|
||||
<span class="stepDesc">
|
||||
Step 1<br />
|
||||
<small>Step 1 description</small>
|
||||
</span>
|
||||
</a></li>
|
||||
<li><a href="#step-2">
|
||||
<label class="stepNumber">2</label>
|
||||
<span class="stepDesc">
|
||||
Step 2<br />
|
||||
<small>Step 2 description having some more text</small>
|
||||
</span>
|
||||
</a></li>
|
||||
<li><a href="#step-3">
|
||||
<label class="stepNumber">3</label>
|
||||
<span class="stepDesc">
|
||||
Step 3<br />
|
||||
<small>Step 3 description</small>
|
||||
</span>
|
||||
</a></li>
|
||||
<li><a href="#step-4">
|
||||
<label class="stepNumber">4</label>
|
||||
<span class="stepDesc">
|
||||
Step 4<br />
|
||||
<small>Step 4 description</small>
|
||||
</span>
|
||||
</a></li>
|
||||
</ul>
|
||||
<div id="step-1">
|
||||
<h2 class="StepTitle">Step 1 Content</h2>
|
||||
<ul type="disk">
|
||||
<li>List 1</li>
|
||||
<li>List 2</li>
|
||||
</ul>
|
||||
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit,
|
||||
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
||||
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
|
||||
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
|
||||
Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
||||
</p>
|
||||
<p>
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit,
|
||||
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
||||
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
|
||||
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
|
||||
Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
||||
</p>
|
||||
<p>
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit,
|
||||
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
||||
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
|
||||
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
|
||||
Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
||||
</p>
|
||||
</div>
|
||||
<div id="step-2">
|
||||
<h2 class="StepTitle">Step 2 Content</h2>
|
||||
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit,
|
||||
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
||||
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
|
||||
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
|
||||
Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
||||
</p>
|
||||
<p>
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit,
|
||||
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
||||
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
|
||||
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
|
||||
Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
||||
</p>
|
||||
<p>
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit,
|
||||
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
||||
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
|
||||
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
|
||||
Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
||||
</p>
|
||||
<p>
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit,
|
||||
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
||||
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
|
||||
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
|
||||
Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
||||
</p>
|
||||
<p>
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit,
|
||||
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
||||
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
|
||||
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
|
||||
Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
||||
</p>
|
||||
</div>
|
||||
<div id="step-3">
|
||||
<h2 class="StepTitle">Step 3 Content</h2>
|
||||
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit,
|
||||
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
||||
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
|
||||
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
|
||||
Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
||||
</p>
|
||||
<p>
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit,
|
||||
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
||||
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
|
||||
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
|
||||
Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
||||
</p>
|
||||
</div>
|
||||
<div id="step-4">
|
||||
<h2 class="StepTitle">Step 4 Content</h2>
|
||||
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit,
|
||||
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
||||
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
|
||||
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
|
||||
Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
||||
</p>
|
||||
<p>
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit,
|
||||
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
||||
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
|
||||
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
|
||||
Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
||||
</p>
|
||||
<p>
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit,
|
||||
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
|
||||
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
|
||||
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
|
||||
Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<asp:Label ID="LabelDashboardTemporaryContent" runat="server" /> <a href="/Pages/v5/Governance/Vote.aspx"><asp:Label ID="LabelGoThere2" runat="server" /></a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="sidebar">
|
||||
<h2 class="blue"><asp:Label ID="LabelSidebarInfoHeader" runat="server" /><span class="arrow"></span></h2>
|
||||
|
||||
<div class="box">
|
||||
<div class="content">
|
||||
<asp:Label ID="LabelSidebarInfoContent" runat="server" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h2 class="blue"><asp:Label ID="LabelSidebarActionsHeader" runat="server" /><span class="arrow"></span></h2>
|
||||
|
||||
<div class="box">
|
||||
<div class="content">
|
||||
<asp:Label ID="LabelSidebarActionsContent" runat="server" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h2 class="orange"><asp:Label ID="LabelSidebarTodoHeader" runat="server" /><span class="arrow"></span></h2>
|
||||
|
||||
<div class="box">
|
||||
<div class="content">
|
||||
<div class="link-row-encaps" onclick="return false;" >
|
||||
<div class="link-row-icon" style="background-image:url('/Images/Icons/iconshock-databaseconnect-16px.png')"></div>
|
||||
<asp:Label ID="LabelSidebarTodoConnectDatabase" runat="server" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- language selector popup -->
|
||||
|
||||
<telerik:RadToolTip ID="ToolTip" runat="server" AnimationDuration="150" AutoCloseDelay="200000" ShowDelay="0"
|
||||
EnableShadow="true" HideDelay="1" Width="200px" Height="96px" HideEvent="ManualClose" OffsetX="-4" OffsetY="0"
|
||||
RelativeTo="Element" Animation="Slide" Position="BottomLeft" ShowCallout="true" TargetControlID="ImageCultureIndicator" RenderInPageRoot="true" ShowEvent="OnClick"
|
||||
Skin="Telerik" >
|
||||
<act5:LanguageSelector ID="LanguageSelector" runat="server" />
|
||||
</telerik:RadToolTip>
|
||||
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,223 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Globalization;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Threading;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using Telerik.Web.UI;
|
||||
|
||||
public partial class Pages_v5_Init_Default : System.Web.UI.Page
|
||||
{
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
// Unlock Telerik
|
||||
|
||||
this.Application["Telerik.Web.UI.Key"] = "Activizr";
|
||||
|
||||
this.ImageCultureIndicator.Style[HtmlTextWriterStyle.MarginTop] = "3px";
|
||||
this.ImageCultureIndicator.Style[HtmlTextWriterStyle.MarginRight] = "3px";
|
||||
this.ImageCultureIndicator.Style[HtmlTextWriterStyle.Cursor] = "pointer";
|
||||
|
||||
this.MainMenu.Style[HtmlTextWriterStyle.Position] = "relative";
|
||||
this.MainMenu.Style[HtmlTextWriterStyle.Top] = "7px";
|
||||
this.MainMenu.Style[HtmlTextWriterStyle.Left] = "20px";
|
||||
|
||||
this.LanguageSelector.LanguageChanged += new EventHandler(LanguageSelector_LanguageChanged);
|
||||
|
||||
Localize();
|
||||
}
|
||||
|
||||
protected override void OnPreInit(EventArgs e)
|
||||
{
|
||||
// This OnPreInit is copied from master page base
|
||||
|
||||
// Localization
|
||||
|
||||
// Set default culture (English, United States, but that doesn't work so fake it to GB)
|
||||
|
||||
string preferredCulture = "en-GB";
|
||||
|
||||
// ----------- SET CULTURE ------------
|
||||
|
||||
// Does the user have a culture preference?
|
||||
|
||||
if (Request.Cookies["PreferredCulture"] != null)
|
||||
{
|
||||
// Yes, set it
|
||||
preferredCulture = Request.Cookies["PreferredCulture"].Value;
|
||||
}
|
||||
else
|
||||
{
|
||||
// No, determine from browser
|
||||
string browserPreference = "en-GB";
|
||||
if (Request.UserLanguages != null && Request.UserLanguages.Length > 0)
|
||||
{
|
||||
browserPreference = Request.UserLanguages[0];
|
||||
preferredCulture = browserPreference;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
string[] languages = (string[])Application["Cultures"];
|
||||
for (int index = 0; index < languages.Length; index++)
|
||||
{
|
||||
if (languages[index].StartsWith(browserPreference))
|
||||
{
|
||||
preferredCulture = languages[index];
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
Thread.CurrentThread.CurrentCulture = CultureInfo.CreateSpecificCulture(preferredCulture);
|
||||
}
|
||||
catch (Exception exception)
|
||||
{
|
||||
throw new Exception("Could not set culture \"" + preferredCulture + "\"", exception);
|
||||
// Thread.CurrentThread.CurrentCulture = CultureInfo.InvariantCulture;
|
||||
}
|
||||
|
||||
Thread.CurrentThread.CurrentUICulture = Thread.CurrentThread.CurrentCulture;
|
||||
|
||||
base.OnPreInit(e);
|
||||
}
|
||||
|
||||
public event EventHandler LanguageChanged;
|
||||
|
||||
private void LanguageSelector_LanguageChanged(object sender, EventArgs e)
|
||||
{
|
||||
// Received event from control - refire
|
||||
|
||||
if (LanguageChanged != null)
|
||||
{
|
||||
LanguageChanged(this, new EventArgs());
|
||||
}
|
||||
|
||||
Localize();
|
||||
}
|
||||
|
||||
|
||||
|
||||
private void Localize()
|
||||
{
|
||||
this.LabelCurrentUserName.Text = Resources.Pages.Init.Init_UserInfo_InstallingAdmin;
|
||||
this.LabelCurrentOrganizationName.Text = Resources.Pages.Init.Init_UserInfo_NoOrgsYet;
|
||||
this.LabelPreferences.Text = Resources.Global.CurrentUserInfo_Preferences;
|
||||
this.LabelSidebarInfoHeader.Text = Resources.Global.Sidebar_Information;
|
||||
this.LabelSidebarInfoContent.Text = Resources.Pages.Init.Init_SidebarInfo_Welcome;
|
||||
this.LabelSidebarActionsHeader.Text = Resources.Global.Sidebar_Actions;
|
||||
this.LabelSidebarActionsContent.Text = Resources.Pages.Init.Init_SidebarActions_None;
|
||||
this.LabelSidebarTodoHeader.Text = Resources.Global.Sidebar_Todo;
|
||||
this.LabelSidebarTodoConnectDatabase.Text = Resources.Pages.Init.Init_SidebarTodo_CompleteSetup;
|
||||
|
||||
|
||||
SetupMenuItems();
|
||||
|
||||
string flagName = "uk";
|
||||
|
||||
string cultureString = Thread.CurrentThread.CurrentCulture.ToString();
|
||||
string cultureStringLower = cultureString.ToLowerInvariant();
|
||||
|
||||
if (cultureStringLower != "en-gb" && cultureString.Length > 3)
|
||||
{
|
||||
flagName = cultureStringLower.Substring(3);
|
||||
}
|
||||
this.ImageCultureIndicator.ImageUrl = "~/Images/Flags/" + flagName + ".png";
|
||||
}
|
||||
|
||||
|
||||
// This section is copied from Master-v5.master.cs, except all items are disabled:
|
||||
|
||||
private void SetupMenuItems()
|
||||
{
|
||||
RadMenuItemCollection menuItems = this.MainMenu.Items;
|
||||
SetupMenuItemsRecurse(menuItems, true);
|
||||
}
|
||||
|
||||
private bool SetupMenuItemsRecurse(RadMenuItemCollection menuItems, bool topLevel)
|
||||
{
|
||||
// string thisPageUrl = Request.Url.Segments[Request.Url.Segments.Length - 1].ToLower();
|
||||
bool anyItemEnabled = false;
|
||||
|
||||
foreach (RadMenuItem item in menuItems)
|
||||
{
|
||||
int itemUserLevel = Convert.ToInt32(item.Attributes["UserLevel"]);
|
||||
string authorization = item.Attributes["Permission"];
|
||||
string resourceKey = item.Attributes["GlobalResourceKey"];
|
||||
string url = item.NavigateUrl;
|
||||
string dynamic = item.Attributes["Dynamic"];
|
||||
|
||||
item.Visible = true; // Modified
|
||||
bool enabled = topLevel;
|
||||
|
||||
if (item.IsSeparator)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
if (dynamic == "true")
|
||||
{
|
||||
switch (item.Attributes["Template"])
|
||||
{
|
||||
case "Build#":
|
||||
item.Text = GetBuildIdentity(); // only dynamically constructed atm -- if more, switch on "template" field
|
||||
break;
|
||||
case "CloseLedgers":
|
||||
int year = DateTime.Today.Year;
|
||||
item.Text = String.Format(Resources.Menu5.Menu5_Ledgers_CloseBooks, year - 1); // Modified
|
||||
break;
|
||||
default:
|
||||
throw new InvalidOperationException("No case for dynamic menu item" + item.Attributes["Template"]);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
item.Text = GetGlobalResourceObject("Menu5", resourceKey).ToString();
|
||||
}
|
||||
|
||||
if (item.Visible)
|
||||
{
|
||||
enabled |= SetupMenuItemsRecurse(item.Items, false);
|
||||
enabled |= !String.IsNullOrEmpty(url);
|
||||
}
|
||||
|
||||
item.Enabled = topLevel; // Modified
|
||||
if (enabled)
|
||||
{
|
||||
anyItemEnabled = true;
|
||||
}
|
||||
}
|
||||
|
||||
return anyItemEnabled;
|
||||
}
|
||||
|
||||
private static string _buildIdentity;
|
||||
|
||||
|
||||
private string GetBuildIdentity()
|
||||
{
|
||||
// Read build number if not loaded, or set to "Private" if none
|
||||
|
||||
if (_buildIdentity == null)
|
||||
{
|
||||
try
|
||||
{
|
||||
using (StreamReader reader = File.OpenText(HttpContext.Current.Request.MapPath("~/BuildIdentity.txt")))
|
||||
{
|
||||
_buildIdentity = "Build " + reader.ReadLine();
|
||||
}
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
_buildIdentity = "Private Build";
|
||||
}
|
||||
}
|
||||
|
||||
return _buildIdentity;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,306 @@
|
||||
/*
|
||||
SmartWizard 2.0 plugin
|
||||
jQuery Wizard control Plugin
|
||||
by Dipu
|
||||
|
||||
http://www.techlaboratory.net
|
||||
http://tech-laboratory.blogspot.com
|
||||
*/
|
||||
.swMain {
|
||||
position:relative;
|
||||
display:block;
|
||||
margin:0;
|
||||
padding:0;
|
||||
border: 0px solid #CCC;
|
||||
overflow:visible;
|
||||
float:left;
|
||||
width:980px;/* */
|
||||
}
|
||||
.swMain .stepContainer {
|
||||
display:block;
|
||||
position: relative;
|
||||
margin: 0;
|
||||
padding:0;
|
||||
border: 0px solid #CCC;
|
||||
overflow:hidden;
|
||||
clear:right;
|
||||
height:300px;
|
||||
}
|
||||
|
||||
.swMain .stepContainer div.content {
|
||||
display:block;
|
||||
position: absolute;
|
||||
float:left;
|
||||
margin: 0;
|
||||
padding:5px;
|
||||
border: 1px solid #CCC;
|
||||
font: normal 12px Verdana, Arial, Helvetica, sans-serif;
|
||||
color:#5A5655;
|
||||
background-color:#F8F8F8;
|
||||
height:300px;
|
||||
text-align:left;
|
||||
overflow:auto;
|
||||
z-index:88;
|
||||
-webkit-border-radius: 5px;
|
||||
-moz-border-radius : 5px;
|
||||
width:720px;
|
||||
clear:both;
|
||||
}
|
||||
|
||||
.swMain div.actionBar {
|
||||
display:block;
|
||||
position: relative;
|
||||
clear:right;
|
||||
margin: 3px 0 0 0;
|
||||
border: 1px solid #CCC;
|
||||
padding: 0;
|
||||
color: #5A5655;
|
||||
background-color: #F8F8F8;
|
||||
height:40px;
|
||||
/* width:730px;
|
||||
float:right; */
|
||||
text-align:left;
|
||||
overflow:auto;
|
||||
z-index:88;
|
||||
-webkit-border-radius: 5px;
|
||||
-moz-border-radius : 5px;
|
||||
|
||||
}
|
||||
|
||||
.swMain .stepContainer .StepTitle {
|
||||
display:block;
|
||||
position: relative;
|
||||
margin:0;
|
||||
border:1px solid #E0E0E0;
|
||||
padding:5px;
|
||||
font: bold 16px Verdana, Arial, Helvetica, sans-serif;
|
||||
color:#5A5655;
|
||||
background-color:#E0E0E0;
|
||||
clear:both;
|
||||
text-align:left;
|
||||
z-index:88;
|
||||
-webkit-border-radius: 5px;
|
||||
-moz-border-radius : 5px;
|
||||
}
|
||||
.swMain ul.anchor {
|
||||
position: relative;
|
||||
display:block;
|
||||
float:left;
|
||||
list-style: none;
|
||||
padding: 0px;
|
||||
margin: 5px 10px 0 0;
|
||||
border: 0px solid #CCCCCC;
|
||||
background: transparent; /*#EEEEEE */
|
||||
}
|
||||
.swMain ul.anchor li{
|
||||
position: relative;
|
||||
display:block;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
padding-top:3px;
|
||||
padding-bottom: 3px;
|
||||
border: 0px solid #E0E0E0;
|
||||
float: left;
|
||||
clear:both;
|
||||
}
|
||||
/* Anchor Element Style */
|
||||
.swMain ul.anchor li a {
|
||||
display:block;
|
||||
position:relative;
|
||||
float:left;
|
||||
margin:0;
|
||||
padding:3px;
|
||||
height:70px;
|
||||
width:230px;
|
||||
text-decoration: none;
|
||||
outline-style:none;
|
||||
-moz-border-radius : 5px;
|
||||
-webkit-border-radius: 5px;
|
||||
z-index:99;
|
||||
}
|
||||
.swMain ul.anchor li a .stepNumber{
|
||||
position:relative;
|
||||
float:left;
|
||||
width:30px;
|
||||
text-align: center;
|
||||
padding:5px;
|
||||
padding-top:0;
|
||||
font: bold 45px Verdana, Arial, Helvetica, sans-serif;
|
||||
}
|
||||
.swMain ul.anchor li a .stepDesc{
|
||||
position:relative;
|
||||
display:block;
|
||||
float:left;
|
||||
text-align: left;
|
||||
padding:5px;
|
||||
width:70%;
|
||||
font: bold 20px Verdana, Arial, Helvetica, sans-serif;
|
||||
}
|
||||
.swMain ul.anchor li a .stepDesc small{
|
||||
font: normal 12px Verdana, Arial, Helvetica, sans-serif;
|
||||
}
|
||||
.swMain ul.anchor li a.selected{
|
||||
color:#F8F8F8;
|
||||
background: #EA8511; /* EA8511 */
|
||||
border: 1px solid #EA8511;
|
||||
cursor:text;
|
||||
-moz-box-shadow: 1px 5px 10px #888;
|
||||
-webkit-box-shadow: 1px 5px 10px #888;
|
||||
box-shadow: 1px 5px 10px #888;
|
||||
}
|
||||
.swMain ul.anchor li a.selected:hover {
|
||||
color:#F8F8F8;
|
||||
background: #EA8511;
|
||||
}
|
||||
|
||||
.swMain ul.anchor li a.done {
|
||||
position:relative;
|
||||
color:#FFF;
|
||||
background: #8CC63F;
|
||||
border: 1px solid #8CC63F;
|
||||
z-index:99;
|
||||
}
|
||||
.swMain ul.anchor li a.done:hover {
|
||||
color:#5A5655;
|
||||
background: #8CC63F;
|
||||
border: 1px solid #5A5655;
|
||||
}
|
||||
.swMain ul.anchor li a.disabled {
|
||||
color:#CCCCCC;
|
||||
background: #F8F8F8;
|
||||
border: 1px solid #CCC;
|
||||
cursor:text;
|
||||
}
|
||||
.swMain ul.anchor li a.disabled:hover {
|
||||
color:#CCCCCC;
|
||||
background: #F8F8F8;
|
||||
}
|
||||
|
||||
.swMain ul.anchor li a.error {
|
||||
color:#6c6c6c !important;
|
||||
background: #f08f75 !important;
|
||||
border: 1px solid #fb3500 !important;
|
||||
}
|
||||
.swMain ul.anchor li a.error:hover {
|
||||
color:#000 !important;
|
||||
}
|
||||
|
||||
.swMain .buttonNext {
|
||||
display:block;
|
||||
float:right;
|
||||
margin:5px 3px 0 3px;
|
||||
padding:5px;
|
||||
text-decoration: none;
|
||||
text-align: center;
|
||||
font: bold 13px Verdana, Arial, Helvetica, sans-serif;
|
||||
width:100px;
|
||||
color:#FFF;
|
||||
outline-style:none;
|
||||
background-color: #5A5655;
|
||||
border: 1px solid #5A5655;
|
||||
-moz-border-radius : 5px;
|
||||
-webkit-border-radius: 5px;
|
||||
}
|
||||
.swMain .buttonDisabled {
|
||||
color:#F8F8F8 !important;
|
||||
background-color: #CCCCCC !important;
|
||||
border: 1px solid #CCCCCC !important;
|
||||
cursor:text;
|
||||
}
|
||||
.swMain .buttonPrevious {
|
||||
display:block;
|
||||
float:right;
|
||||
margin:5px 3px 0 3px;
|
||||
padding:5px;
|
||||
text-decoration: none;
|
||||
text-align: center;
|
||||
font: bold 13px Verdana, Arial, Helvetica, sans-serif;
|
||||
width:100px;
|
||||
color:#FFF;
|
||||
outline-style:none;
|
||||
background-color: #5A5655;
|
||||
border: 1px solid #5A5655;
|
||||
-moz-border-radius : 5px;
|
||||
-webkit-border-radius: 5px;
|
||||
}
|
||||
.swMain .buttonFinish {
|
||||
display:block;
|
||||
float:right;
|
||||
margin:5px 10px 0 3px;
|
||||
padding:5px;
|
||||
text-decoration: none;
|
||||
text-align: center;
|
||||
font: bold 13px Verdana, Arial, Helvetica, sans-serif;
|
||||
width:100px;
|
||||
color:#FFF;
|
||||
outline-style:none;
|
||||
background-color: #5A5655;
|
||||
border: 1px solid #5A5655;
|
||||
-moz-border-radius : 5px;
|
||||
-webkit-border-radius: 5px;
|
||||
}
|
||||
|
||||
/* Form Styles */
|
||||
|
||||
.txtBox {
|
||||
border:1px solid #CCCCCC;
|
||||
color:#5A5655;
|
||||
font:13px Verdana,Arial,Helvetica,sans-serif;
|
||||
padding:2px;
|
||||
width:430px;
|
||||
}
|
||||
.txtBox:focus {
|
||||
border:1px solid #EA8511;
|
||||
}
|
||||
|
||||
.swMain .loader {
|
||||
position:relative;
|
||||
display:none;
|
||||
float:left;
|
||||
margin: 2px 0 0 2px;
|
||||
padding:8px 10px 8px 40px;
|
||||
border: 1px solid #FFD700;
|
||||
font: bold 13px Verdana, Arial, Helvetica, sans-serif;
|
||||
color:#5A5655;
|
||||
background: #FFF url(../images/loader.gif) no-repeat 5px;
|
||||
-moz-border-radius : 5px;
|
||||
-webkit-border-radius: 5px;
|
||||
z-index:998;
|
||||
}
|
||||
.swMain .msgBox {
|
||||
position:relative;
|
||||
display:none;
|
||||
float:left;
|
||||
margin: 4px 0 0 5px;
|
||||
padding:5px;
|
||||
border: 1px solid #FFD700;
|
||||
background-color: #FFFFDD;
|
||||
font: normal 12px Verdana, Arial, Helvetica, sans-serif;
|
||||
color:#5A5655;
|
||||
-moz-border-radius : 5px;
|
||||
-webkit-border-radius: 5px;
|
||||
z-index:999;
|
||||
min-width:200px;
|
||||
}
|
||||
.swMain .msgBox .content {
|
||||
font: normal 12px Verdana,Arial,Helvetica,sans-serif;
|
||||
padding: 0px;
|
||||
float:left;
|
||||
}
|
||||
.swMain .msgBox .close {
|
||||
border: 1px solid #CCC;
|
||||
border-radius: 3px;
|
||||
color: #CCC;
|
||||
display: block;
|
||||
float: right;
|
||||
margin: 0 0 0 5px;
|
||||
outline-style: none;
|
||||
padding: 0 2px 0 2px;
|
||||
position: relative;
|
||||
text-align: center;
|
||||
text-decoration: none;
|
||||
}
|
||||
.swMain .msgBox .close:hover{
|
||||
color: #EA8511;
|
||||
border: 1px solid #EA8511;
|
||||
}
|
||||
@@ -0,0 +1,334 @@
|
||||
/*
|
||||
* SmartWizard 2.0 plugin
|
||||
* jQuery Wizard control Plugin
|
||||
* by Dipu
|
||||
*
|
||||
* http://www.techlaboratory.net
|
||||
* http://tech-laboratory.blogspot.com
|
||||
*/
|
||||
|
||||
(function($){
|
||||
$.fn.smartWizard = function(action) {
|
||||
var options = $.extend({}, $.fn.smartWizard.defaults, action);
|
||||
var args = arguments;
|
||||
|
||||
return this.each(function(){
|
||||
var obj = $(this);
|
||||
var curStepIdx = options.selected;
|
||||
var steps = $("ul > li > a", obj); // Get all anchors in this array
|
||||
var contentWidth = 0;
|
||||
var loader,msgBox,elmActionBar,elmStepContainer,btNext,btPrevious,btFinish;
|
||||
|
||||
elmActionBar = $('.actionBar',obj);
|
||||
if(elmActionBar.length == 0){
|
||||
elmActionBar = $('<div></div>').addClass("actionBar");
|
||||
}
|
||||
|
||||
msgBox = $('.msgBox',obj);
|
||||
if(msgBox.length == 0){
|
||||
msgBox = $('<div class="msgBox"><div class="content"></div><a href="#" class="close">X</a></div>');
|
||||
elmActionBar.append(msgBox);
|
||||
}
|
||||
|
||||
$('.close',msgBox).click(function() {
|
||||
msgBox.fadeOut("normal");
|
||||
return false;
|
||||
});
|
||||
|
||||
|
||||
// Method calling logic
|
||||
if (!action || action === 'init' || typeof action === 'object') {
|
||||
init();
|
||||
}else if (action === 'showMessage') {
|
||||
//showMessage(Array.prototype.slice.call( args, 1 ));
|
||||
var ar = Array.prototype.slice.call( args, 1 );
|
||||
showMessage(ar[0]);
|
||||
return true;
|
||||
}else if (action === 'setError') {
|
||||
var ar = Array.prototype.slice.call( args, 1 );
|
||||
setError(ar[0].stepnum,ar[0].iserror);
|
||||
return true;
|
||||
} else {
|
||||
$.error( 'Method ' + action + ' does not exist' );
|
||||
}
|
||||
|
||||
function init(){
|
||||
var allDivs =obj.children('div'); //$("div", obj);
|
||||
obj.children('ul').addClass("anchor");
|
||||
allDivs.addClass("content");
|
||||
// Create Elements
|
||||
loader = $('<div>Loading</div>').addClass("loader");
|
||||
elmActionBar = $('<div></div>').addClass("actionBar");
|
||||
elmStepContainer = $('<div></div>').addClass("stepContainer");
|
||||
btNext = $('<a>'+options.labelNext+'</a>').attr("href","#").addClass("buttonNext");
|
||||
btPrevious = $('<a>'+options.labelPrevious+'</a>').attr("href","#").addClass("buttonPrevious");
|
||||
btFinish = $('<a>'+options.labelFinish+'</a>').attr("href","#").addClass("buttonFinish");
|
||||
|
||||
// highlight steps with errors
|
||||
if(options.errorSteps && options.errorSteps.length>0){
|
||||
$.each(options.errorSteps, function(i, n){
|
||||
setError(n,true);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
elmStepContainer.append(allDivs);
|
||||
elmActionBar.append(loader);
|
||||
obj.append(elmStepContainer);
|
||||
obj.append(elmActionBar);
|
||||
elmActionBar.append(btFinish).append(btNext).append(btPrevious);
|
||||
contentWidth = elmStepContainer.width();
|
||||
|
||||
$(btNext).click(function() {
|
||||
doForwardProgress();
|
||||
return false;
|
||||
});
|
||||
$(btPrevious).click(function() {
|
||||
doBackwardProgress();
|
||||
return false;
|
||||
});
|
||||
$(btFinish).click(function() {
|
||||
if(!$(this).hasClass('buttonDisabled')){
|
||||
if($.isFunction(options.onFinish)) {
|
||||
if(!options.onFinish.call(this,$(steps))){
|
||||
return false;
|
||||
}
|
||||
}else{
|
||||
var frm = obj.parents('form');
|
||||
if(frm && frm.length){
|
||||
frm.submit();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
});
|
||||
|
||||
$(steps).bind("click", function(e){
|
||||
if(steps.index(this) == curStepIdx){
|
||||
return false;
|
||||
}
|
||||
var nextStepIdx = steps.index(this);
|
||||
var isDone = steps.eq(nextStepIdx).attr("isDone") - 0;
|
||||
if(isDone == 1){
|
||||
LoadContent(nextStepIdx);
|
||||
}
|
||||
return false;
|
||||
});
|
||||
|
||||
// Enable keyboard navigation
|
||||
if(options.keyNavigation){
|
||||
$(document).keyup(function(e){
|
||||
if(e.which==39){ // Right Arrow
|
||||
doForwardProgress();
|
||||
}else if(e.which==37){ // Left Arrow
|
||||
doBackwardProgress();
|
||||
}
|
||||
});
|
||||
}
|
||||
// Prepare the steps
|
||||
prepareSteps();
|
||||
// Show the first slected step
|
||||
LoadContent(curStepIdx);
|
||||
}
|
||||
|
||||
function prepareSteps(){
|
||||
if(!options.enableAllSteps){
|
||||
$(steps, obj).removeClass("selected").removeClass("done").addClass("disabled");
|
||||
$(steps, obj).attr("isDone",0);
|
||||
}else{
|
||||
$(steps, obj).removeClass("selected").removeClass("disabled").addClass("done");
|
||||
$(steps, obj).attr("isDone",1);
|
||||
}
|
||||
|
||||
$(steps, obj).each(function(i){
|
||||
$($(this).attr("href"), obj).hide();
|
||||
$(this).attr("rel",i+1);
|
||||
});
|
||||
}
|
||||
|
||||
function LoadContent(stepIdx){
|
||||
var selStep = steps.eq(stepIdx);
|
||||
var ajaxurl = options.contentURL;
|
||||
var hasContent = selStep.data('hasContent');
|
||||
stepNum = stepIdx+1;
|
||||
if(ajaxurl && ajaxurl.length>0){
|
||||
if(options.contentCache && hasContent){
|
||||
showStep(stepIdx);
|
||||
}else{
|
||||
$.ajax({
|
||||
url: ajaxurl,
|
||||
type: "POST",
|
||||
data: ({step_number : stepNum}),
|
||||
dataType: "text",
|
||||
beforeSend: function(){ loader.show(); },
|
||||
error: function(){loader.hide();},
|
||||
success: function(res){
|
||||
loader.hide();
|
||||
if(res && res.length>0){
|
||||
selStep.data('hasContent',true);
|
||||
$($(selStep, obj).attr("href"), obj).html(res);
|
||||
showStep(stepIdx);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
}else{
|
||||
showStep(stepIdx);
|
||||
}
|
||||
}
|
||||
|
||||
function showStep(stepIdx){
|
||||
var selStep = steps.eq(stepIdx);
|
||||
var curStep = steps.eq(curStepIdx);
|
||||
if(stepIdx != curStepIdx){
|
||||
if($.isFunction(options.onLeaveStep)) {
|
||||
if(!options.onLeaveStep.call(this,$(curStep))){
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
elmStepContainer.height($($(selStep, obj).attr("href"), obj).outerHeight());
|
||||
if(options.transitionEffect == 'slide'){
|
||||
$($(curStep, obj).attr("href"), obj).slideUp("fast",function(e){
|
||||
$($(selStep, obj).attr("href"), obj).slideDown("fast");
|
||||
curStepIdx = stepIdx;
|
||||
SetupStep(curStep,selStep);
|
||||
});
|
||||
} else if(options.transitionEffect == 'fade'){
|
||||
$($(curStep, obj).attr("href"), obj).fadeOut("fast",function(e){
|
||||
$($(selStep, obj).attr("href"), obj).fadeIn("fast");
|
||||
curStepIdx = stepIdx;
|
||||
SetupStep(curStep,selStep);
|
||||
});
|
||||
} else if(options.transitionEffect == 'slideleft'){
|
||||
var nextElmLeft = 0;
|
||||
var curElementLeft = 0;
|
||||
if(stepIdx > curStepIdx){
|
||||
nextElmLeft1 = contentWidth + 10;
|
||||
nextElmLeft2 = 0;
|
||||
curElementLeft = 0 - $($(curStep, obj).attr("href"), obj).outerWidth();
|
||||
} else {
|
||||
nextElmLeft1 = 0 - $($(selStep, obj).attr("href"), obj).outerWidth() + 20;
|
||||
nextElmLeft2 = 0;
|
||||
curElementLeft = 10 + $($(curStep, obj).attr("href"), obj).outerWidth();
|
||||
}
|
||||
if(stepIdx == curStepIdx){
|
||||
nextElmLeft1 = $($(selStep, obj).attr("href"), obj).outerWidth() + 20;
|
||||
nextElmLeft2 = 0;
|
||||
curElementLeft = 0 - $($(curStep, obj).attr("href"), obj).outerWidth();
|
||||
}else{
|
||||
$($(curStep, obj).attr("href"), obj).animate({left:curElementLeft},"fast",function(e){
|
||||
$($(curStep, obj).attr("href"), obj).hide();
|
||||
});
|
||||
}
|
||||
|
||||
$($(selStep, obj).attr("href"), obj).css("left",nextElmLeft1);
|
||||
$($(selStep, obj).attr("href"), obj).show();
|
||||
$($(selStep, obj).attr("href"), obj).animate({left:nextElmLeft2},"fast",function(e){
|
||||
curStepIdx = stepIdx;
|
||||
SetupStep(curStep,selStep);
|
||||
});
|
||||
} else{
|
||||
$($(curStep, obj).attr("href"), obj).hide();
|
||||
$($(selStep, obj).attr("href"), obj).show();
|
||||
curStepIdx = stepIdx;
|
||||
SetupStep(curStep,selStep);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
function SetupStep(curStep,selStep){
|
||||
$(curStep, obj).removeClass("selected");
|
||||
$(curStep, obj).addClass("done");
|
||||
|
||||
$(selStep, obj).removeClass("disabled");
|
||||
$(selStep, obj).removeClass("done");
|
||||
$(selStep, obj).addClass("selected");
|
||||
$(selStep, obj).attr("isDone",1);
|
||||
adjustButton();
|
||||
if($.isFunction(options.onShowStep)) {
|
||||
if(!options.onShowStep.call(this,$(selStep))){
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function doForwardProgress(){
|
||||
var nextStepIdx = curStepIdx + 1;
|
||||
if(steps.length <= nextStepIdx){
|
||||
if(!options.cycleSteps){
|
||||
return false;
|
||||
}
|
||||
nextStepIdx = 0;
|
||||
}
|
||||
LoadContent(nextStepIdx);
|
||||
}
|
||||
|
||||
function doBackwardProgress(){
|
||||
var nextStepIdx = curStepIdx-1;
|
||||
if(0 > nextStepIdx){
|
||||
if(!options.cycleSteps){
|
||||
return false;
|
||||
}
|
||||
nextStepIdx = steps.length - 1;
|
||||
}
|
||||
LoadContent(nextStepIdx);
|
||||
}
|
||||
|
||||
function adjustButton(){
|
||||
if(!options.cycleSteps){
|
||||
if(0 >= curStepIdx){
|
||||
$(btPrevious).addClass("buttonDisabled");
|
||||
}else{
|
||||
$(btPrevious).removeClass("buttonDisabled");
|
||||
}
|
||||
if((steps.length-1) <= curStepIdx){
|
||||
$(btNext).addClass("buttonDisabled");
|
||||
}else{
|
||||
$(btNext).removeClass("buttonDisabled");
|
||||
}
|
||||
}
|
||||
// Finish Button
|
||||
if(!steps.hasClass('disabled') || options.enableFinishButton){
|
||||
$(btFinish).removeClass("buttonDisabled");
|
||||
}else{
|
||||
$(btFinish).addClass("buttonDisabled");
|
||||
}
|
||||
}
|
||||
|
||||
function showMessage(msg){
|
||||
$('.content',msgBox).html(msg);
|
||||
msgBox.show();
|
||||
}
|
||||
|
||||
function setError(stepnum,iserror){
|
||||
if(iserror){
|
||||
$(steps.eq(stepnum-1), obj).addClass('error')
|
||||
}else{
|
||||
$(steps.eq(stepnum-1), obj).removeClass("error");
|
||||
}
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
// Default Properties and Events
|
||||
$.fn.smartWizard.defaults = {
|
||||
selected: 0, // Selected Step, 0 = first step
|
||||
keyNavigation: true, // Enable/Disable key navigation(left and right keys are used if enabled)
|
||||
enableAllSteps: false,
|
||||
transitionEffect: 'fade', // Effect on navigation, none/fade/slide/slideleft
|
||||
contentURL:null, // content url, Enables Ajax content loading
|
||||
contentCache:true, // cache step contents, if false content is fetched always from ajax url
|
||||
cycleSteps: false, // cycle step navigation
|
||||
enableFinishButton: false, // make finish button enabled always
|
||||
errorSteps:[], // Array Steps with errors
|
||||
labelNext:'Next',
|
||||
labelPrevious:'Previous',
|
||||
labelFinish:'Finish',
|
||||
onLeaveStep: null, // triggers when leaving a step
|
||||
onShowStep: null, // triggers when showing a step
|
||||
onFinish: null // triggers when Finish button is clicked
|
||||
};
|
||||
|
||||
})(jQuery);
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
(function(a){a.fn.smartWizard=function(k){var c=a.extend({},a.fn.smartWizard.defaults,k),u=arguments;return this.each(function(){function z(){var d=b.children("div");b.children("ul").addClass("anchor");d.addClass("content");l=a("<div>Loading</div>").addClass("loader");i=a("<div></div>").addClass("actionBar");m=a("<div></div>").addClass("stepContainer");n=a("<a>"+c.labelNext+"</a>").attr("href","#").addClass("buttonNext");o=a("<a>"+c.labelPrevious+"</a>").attr("href","#").addClass("buttonPrevious");
|
||||
p=a("<a>"+c.labelFinish+"</a>").attr("href","#").addClass("buttonFinish");c.errorSteps&&c.errorSteps.length>0&&a.each(c.errorSteps,function(a,b){v(b,!0)});m.append(d);i.append(l);b.append(m);b.append(i);i.append(p).append(n).append(o);w=m.width();a(n).click(function(){x();return!1});a(o).click(function(){y();return!1});a(p).click(function(){if(!a(this).hasClass("buttonDisabled"))if(a.isFunction(c.onFinish))c.onFinish.call(this,a(f));else{var d=b.parents("form");d&&d.length&&d.submit()}return!1});
|
||||
a(f).bind("click",function(){if(f.index(this)==h)return!1;var a=f.index(this);f.eq(a).attr("isDone")-0==1&&q(a);return!1});c.keyNavigation&&a(document).keyup(function(a){a.which==39?x():a.which==37&&y()});A();q(h)}function A(){c.enableAllSteps?(a(f,b).removeClass("selected").removeClass("disabled").addClass("done"),a(f,b).attr("isDone",1)):(a(f,b).removeClass("selected").removeClass("done").addClass("disabled"),a(f,b).attr("isDone",0));a(f,b).each(function(d){a(a(this).attr("href"),b).hide();a(this).attr("rel",
|
||||
d+1)})}function q(d){var e=f.eq(d),g=c.contentURL,h=e.data("hasContent");stepNum=d+1;g&&g.length>0?c.contentCache&&h?t(d):a.ajax({url:g,type:"POST",data:{step_number:stepNum},dataType:"text",beforeSend:function(){l.show()},error:function(){l.hide()},success:function(c){l.hide();c&&c.length>0&&(e.data("hasContent",!0),a(a(e,b).attr("href"),b).html(c),t(d))}}):t(d)}function t(d){var e=f.eq(d),g=f.eq(h);if(d!=h&&a.isFunction(c.onLeaveStep)&&!c.onLeaveStep.call(this,a(g)))return!1;m.height(a(a(e,b).attr("href"),
|
||||
b).outerHeight());if(c.transitionEffect=="slide")a(a(g,b).attr("href"),b).slideUp("fast",function(){a(a(e,b).attr("href"),b).slideDown("fast");h=d;r(g,e)});else if(c.transitionEffect=="fade")a(a(g,b).attr("href"),b).fadeOut("fast",function(){a(a(e,b).attr("href"),b).fadeIn("fast");h=d;r(g,e)});else if(c.transitionEffect=="slideleft"){var i=0;d>h?(nextElmLeft1=w+10,nextElmLeft2=0,i=0-a(a(g,b).attr("href"),b).outerWidth()):(nextElmLeft1=0-a(a(e,b).attr("href"),b).outerWidth()+20,nextElmLeft2=0,i=10+
|
||||
a(a(g,b).attr("href"),b).outerWidth());d==h?(nextElmLeft1=a(a(e,b).attr("href"),b).outerWidth()+20,nextElmLeft2=0,i=0-a(a(g,b).attr("href"),b).outerWidth()):a(a(g,b).attr("href"),b).animate({left:i},"fast",function(){a(a(g,b).attr("href"),b).hide()});a(a(e,b).attr("href"),b).css("left",nextElmLeft1);a(a(e,b).attr("href"),b).show();a(a(e,b).attr("href"),b).animate({left:nextElmLeft2},"fast",function(){h=d;r(g,e)})}else a(a(g,b).attr("href"),b).hide(),a(a(e,b).attr("href"),b).show(),h=d,r(g,e);return!0}
|
||||
function r(d,e){a(d,b).removeClass("selected");a(d,b).addClass("done");a(e,b).removeClass("disabled");a(e,b).removeClass("done");a(e,b).addClass("selected");a(e,b).attr("isDone",1);c.cycleSteps||(0>=h?a(o).addClass("buttonDisabled"):a(o).removeClass("buttonDisabled"),f.length-1<=h?a(n).addClass("buttonDisabled"):a(n).removeClass("buttonDisabled"));!f.hasClass("disabled")||c.enableFinishButton?a(p).removeClass("buttonDisabled"):a(p).addClass("buttonDisabled");if(a.isFunction(c.onShowStep)&&!c.onShowStep.call(this,
|
||||
a(e)))return!1}function x(){var a=h+1;if(f.length<=a){if(!c.cycleSteps)return!1;a=0}q(a)}function y(){var a=h-1;if(0>a){if(!c.cycleSteps)return!1;a=f.length-1}q(a)}function B(b){a(".content",j).html(b);j.show()}function v(d,c){c?a(f.eq(d-1),b).addClass("error"):a(f.eq(d-1),b).removeClass("error")}var b=a(this),h=c.selected,f=a("ul > li > a",b),w=0,l,j,i,m,n,o,p;i=a(".actionBar",b);i.length==0&&(i=a("<div></div>").addClass("actionBar"));j=a(".msgBox",b);j.length==0&&(j=a('<div class="msgBox"><div class="content"></div><a href="#" class="close">X</a></div>'),
|
||||
i.append(j));a(".close",j).click(function(){j.fadeOut("normal");return!1});if(!k||k==="init"||typeof k==="object")z();else if(k==="showMessage"){var s=Array.prototype.slice.call(u,1);B(s[0]);return!0}else if(k==="setError")return s=Array.prototype.slice.call(u,1),v(s[0].stepnum,s[0].iserror),!0;else a.error("Method "+k+" does not exist")})};a.fn.smartWizard.defaults={selected:0,keyNavigation:!0,enableAllSteps:!1,transitionEffect:"fade",contentURL:null,contentCache:!0,cycleSteps:!1,enableFinishButton:!1,
|
||||
errorSteps:[],labelNext:"Next",labelPrevious:"Previous",labelFinish:"Finish",onLeaveStep:null,onShowStep:null,onFinish:null}})(jQuery);
|
||||
@@ -0,0 +1,11 @@
|
||||
<?xml version="1.0"?>
|
||||
<!--
|
||||
The only override for the Pages/Public, Style, Images, and Security folders is that no authentication is required.
|
||||
-->
|
||||
<configuration xmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0">
|
||||
<system.web>
|
||||
<authorization>
|
||||
<allow users="*" />
|
||||
</authorization>
|
||||
</system.web>
|
||||
</configuration>
|
||||
@@ -6,6 +6,7 @@ using System.Web.Security;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using Activizr.Basic.Types;
|
||||
using Activizr.Database;
|
||||
using Activizr.Logic.Pirates;
|
||||
|
||||
namespace Activizr.Pages.Security
|
||||
@@ -14,6 +15,13 @@ namespace Activizr.Pages.Security
|
||||
{
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
// Check if this is the first run ever. If so, redirect to Init.
|
||||
|
||||
if (!PirateDb.Configuration.IsConfigured())
|
||||
{
|
||||
Response.Redirect("/Pages/v5/Init/", true);
|
||||
}
|
||||
|
||||
// Unlock Telerik
|
||||
|
||||
this.Application["Telerik.Web.UI.Key"] = "Activizr";
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
<wpf:ResourceDictionary xml:space="preserve" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:s="clr-namespace:System;assembly=mscorlib" xmlns:ss="urn:shemas-jetbrains-com:settings-storage-xaml" xmlns:wpf="http://schemas.microsoft.com/winfx/2006/xaml/presentation">
|
||||
<s:Boolean x:Key="/Default/CodeInspection/NamespaceProvider/NamespaceFoldersToSkip/=Automation/@EntryIndexedValue">True</s:Boolean></wpf:ResourceDictionary>
|
||||
@@ -59,6 +59,13 @@
|
||||
<deny users="?"/>
|
||||
</authorization>
|
||||
</system.web>
|
||||
<location path="Telerik.Web.UI.WebResource.axd">
|
||||
<system.web>
|
||||
<authorization>
|
||||
<allow users ="*" />
|
||||
</authorization>
|
||||
</system.web>
|
||||
</location>
|
||||
<system.data>
|
||||
<DbProviderFactories>
|
||||
<add name="MySQL Data Provider" invariant="MySql.Data.MySqlClient" description=".Net Framework Data Provider for MySQL" type="MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data, Version=6.2.2.0, Culture=neutral"/>
|
||||
|
||||
Reference in New Issue
Block a user