From fd4f1eed9f286bb3133b520ed247c5b11bad3c48 Mon Sep 17 00:00:00 2001 From: Rick Falkvinge Date: Fri, 23 Jan 2015 14:41:58 +0100 Subject: [PATCH] Improvements to Account Plan #1 --- Site5/Pages/v5/Ledgers/AccountPlan.aspx | 19 +++++++++++++++++++ .../v5/Ledgers/Json-AccountPlanData.aspx.cs | 5 +++-- Swarmops.sln | 2 +- 3 files changed, 23 insertions(+), 3 deletions(-) diff --git a/Site5/Pages/v5/Ledgers/AccountPlan.aspx b/Site5/Pages/v5/Ledgers/AccountPlan.aspx index 5c6fd4eb..93fb17eb 100644 --- a/Site5/Pages/v5/Ledgers/AccountPlan.aspx +++ b/Site5/Pages/v5/Ledgers/AccountPlan.aspx @@ -48,6 +48,13 @@ beginEditAccount(); }); + }, + + rowStyler: function (rowData) { + if (rowData.inactive == true) + { + return { class: 'RowInactive', style: { color: '#c0c0c0' } }; + } } }); @@ -523,6 +530,10 @@ .CheckboxContainer { float: right; padding-top: 4px;padding-right: 8px; } + .RowInactive + { + color: #C0C0C0; + } @@ -592,5 +603,13 @@ +

+ +
+
+ +
+
+
diff --git a/Site5/Pages/v5/Ledgers/Json-AccountPlanData.aspx.cs b/Site5/Pages/v5/Ledgers/Json-AccountPlanData.aspx.cs index 4f4c559b..f12b5caa 100644 --- a/Site5/Pages/v5/Ledgers/Json-AccountPlanData.aspx.cs +++ b/Site5/Pages/v5/Ledgers/Json-AccountPlanData.aspx.cs @@ -126,7 +126,7 @@ namespace Swarmops.Frontend.Pages.v5.Ledgers childStrings.Add ('{' + String.Format ( - "\"id\":\"{0}\",\"accountName\":\"{1}\",\"owner\":\"{2}\",\"balance\":\"{3}\",\"budget\":\"{4}\",\"action\":\"{5}\"", + "\"id\":\"{0}\",\"accountName\":\"{1}\",\"owner\":\"{2}\",\"balance\":\"{3}\",\"budget\":\"{4}\",\"action\":\"{5}\",\"inactive\":\"{6}\"", account.Identity, Server.HtmlEncode (JsonSanitize (account.Name)), ownerString, @@ -144,7 +144,8 @@ namespace Swarmops.Frontend.Pages.v5.Ledgers : (this._singleBudgetLookup[account.Identity]/100.0).ToString ("N0", CultureInfo.CurrentCulture) : string.Empty, - editString + editString, + account.Active? "true":"false" ) + grandChildren + '}'); } diff --git a/Swarmops.sln b/Swarmops.sln index 6b265e07..4182ae93 100644 --- a/Swarmops.sln +++ b/Swarmops.sln @@ -32,7 +32,7 @@ Project("{E24C65DC-7377-472B-9ABA-BC803B73C61A}") = "Site5", "Site5\", "{367F36E Release.AspNetCompiler.ForceOverwrite = "true" Release.AspNetCompiler.FixedNames = "false" Release.AspNetCompiler.Debug = "False" - VWDPort = "1109" + VWDPort = "1589" VWDVirtualPath = "/" DefaultWebSiteLanguage = "Visual C#" EndProjectSection