-
+
-
-
-
+
+
diff --git a/Site5/Pages/v5/Ledgers/InspectLedgers.aspx.cs b/Site5/Pages/v5/Ledgers/InspectLedgers.aspx.cs
index 68a401c2..383887f2 100644
--- a/Site5/Pages/v5/Ledgers/InspectLedgers.aspx.cs
+++ b/Site5/Pages/v5/Ledgers/InspectLedgers.aspx.cs
@@ -75,6 +75,7 @@ namespace Swarmops.Frontend.Pages.v5.Ledgers
this.LabelGridHeaderDescription.Text = Global.Global_Description;
this.LabelGridHeaderId.Text = Resources.Pages.Ledgers.InspectLedgers_TransactionId;
+
this.LabelGridHeaderAccountName.Text = Resources.Pages.Ledgers.InspectLedgers_AccountName;
this.LabelGridHeaderDateTimeEntered.Text = Resources.Pages.Ledgers.InspectLedgers_LoggedDate;
this.LabelGridHeaderDeltaNegative2.Text = Global.Ledgers_Credit;
@@ -83,6 +84,7 @@ namespace Swarmops.Frontend.Pages.v5.Ledgers
this.LabelFlagNotAvailable.Text = Resources.Pages.Ledgers.InspectLedgers_FlaggingNotAvailable;
+
this.LabelAddTransactionRowsHeader.Text = Resources.Pages.Ledgers.InspectLedgers_HeaderAddTransactionRow;
this.LabelTrackedTransactionHeader.Text =
Resources.Pages.Ledgers.InspectLedgers_HeaderAutoTransactionTracking;
@@ -93,7 +95,8 @@ namespace Swarmops.Frontend.Pages.v5.Ledgers
CurrentUser.HasAccess (new Access (CurrentOrganization, AccessAspect.BookkeepingDetails,
AccessType.Write)))
{
- this.LiteralEditHeader.Text = Resources.Pages.Ledgers.InspectLedgers_EditingTransactionX;
+ LiteralEditHeader.Text = Resources.Pages.Ledgers.InspectLedgers_EditingTransactionX;
+
this.LabelAddRowAccount.Text = Global.Financial_Account;
this.LabelAddRowAmount.Text = Global.Financial_Amount;
this.LiteralErrorAddRowSelectAccount.Text =
@@ -102,7 +105,7 @@ namespace Swarmops.Frontend.Pages.v5.Ledgers
}
else // read access, at a minimum of AccessAspect.Bookkeeping
{
- this.LiteralEditHeader.Text = Resources.Pages.Ledgers.InspectLedgers_InspectingTransactionX;
+ LiteralEditHeader.Text = Resources.Pages.Ledgers.InspectLedgers_InspectingTransactionX;
}
// Access helpers to JavaScript (these don't actually determine access, but help in UI prettiness)
diff --git a/Site5/Pages/v5/Ledgers/Json-UnbalancedTransactions.aspx b/Site5/Pages/v5/Ledgers/Json-UnbalancedTransactions.aspx
new file mode 100644
index 00000000..4a26b223
--- /dev/null
+++ b/Site5/Pages/v5/Ledgers/Json-UnbalancedTransactions.aspx
@@ -0,0 +1 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Json-UnbalancedTransactions.aspx.cs" Inherits="Swarmops.Frontend.Pages.v5.Ledgers.Json_UnbalancedTransactions" %>
diff --git a/Site5/Pages/v5/Ledgers/Json-UnbalancedTransactions.aspx.cs b/Site5/Pages/v5/Ledgers/Json-UnbalancedTransactions.aspx.cs
new file mode 100644
index 00000000..e3e135d2
--- /dev/null
+++ b/Site5/Pages/v5/Ledgers/Json-UnbalancedTransactions.aspx.cs
@@ -0,0 +1,54 @@
+using System;
+using System.Collections.Generic;
+using Swarmops.Logic.Financial;
+using Swarmops.Logic.Security;
+
+namespace Swarmops.Frontend.Pages.v5.Ledgers
+{
+ public partial class Json_UnbalancedTransactions : DataV5Base
+ {
+ protected void Page_Load (object sender, EventArgs e)
+ {
+ Response.ContentType = "application/json";
+
+ FinancialTransactions unbalancedTransactions = FinancialTransactions.GetUnbalanced (CurrentOrganization);
+ List
rows = new List();
+
+ if (
+ CurrentUser.HasAccess (new Access (CurrentOrganization, AccessAspect.BookkeepingDetails, AccessType.Read)))
+ {
+ foreach (FinancialTransaction transaction in unbalancedTransactions)
+ {
+ string accountName = string.Empty;
+
+ FinancialTransactionRows txRows = transaction.Rows;
+ if (txRows.Count > 1)
+ {
+ accountName = Resources.Global.Global_Several_Display;
+ }
+ else
+ {
+ // one transaction row (we know there's not zero rows, because the transaction is unbalanced, which requires at least one nonzero row)
+ accountName = txRows[0].AccountName;
+ }
+
+ string row =
+ String.Format (
+ "\"id\":\"{0:N0}\",\"description\":\"{1}\",\"accountName\":\"{2}\",\"delta\":\"{3:+#,#.00;-#,#.00}\",\"dateTime\":\"{4:yyyy-MMM-dd HH:mm}\"",
+ transaction.Identity, JsonSanitize (transaction.Description), JsonSanitize (accountName), txRows.AmountCentsTotal / 100.0, transaction.DateTime);
+
+ row +=
+ String.Format (
+ ",\"action\":\"
\"",
+ transaction.Identity);
+
+ rows.Add ("{" + row + "}");
+ }
+ }
+
+ Response.Output.WriteLine("[" + String.Join (",", rows) + "]");
+
+ Response.End();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Site5/Style/style-v5.css b/Site5/Style/style-v5.css
index 40260502..d8ab13b4 100644
--- a/Site5/Style/style-v5.css
+++ b/Site5/Style/style-v5.css
@@ -344,7 +344,7 @@ body.rtl .sidebar {
-.modalcover {
+.modalCover {
position: absolute;
top: 0px;
left: 0px;
@@ -353,23 +353,47 @@ body.rtl .sidebar {
z-index: 9001;
display: none;
background-color: rgba(0, 0, 0, 0.25);
-
}
-.modal
-{
+.modalWrap {
position: absolute;
- height: 80%;
- width: 950px;
- box-shadow: black 0px 0px 30px 2px;
+ height: 70%;
+ width: 980px;
left: 0;
right: 0;
top: 0;
bottom: 0;
margin: auto auto;
+ background: transparent;
+}
+
+.modal
+{
+ box-shadow: black 0px 0px 30px 2px;
overflow-y: auto;
}
+.modal.box {
+ margin-top: inherit;
+}
+
+.modalIconClose { /* copies the close button from Fancybox */
+ position: absolute;
+ top: -15px;
+ right: -15px;
+ width: 30px;
+ height: 30px;
+ background: url("/Scripts/fancybox/fancybox.png") repeat scroll -40px 0px transparent;
+ cursor: pointer;
+ z-index: 9103;
+}
+
+body.rtl .modalIconClose, body.rtl #fancybox-close {
+ right: inherit !important;
+ left: -15px !important;
+}
+
+
.divIconCloseModal {
float:right;