diff --git a/External Libraries/Mono.Posix.dll b/External Libraries/Mono.Posix.dll
new file mode 100644
index 00000000..b401f930
Binary files /dev/null and b/External Libraries/Mono.Posix.dll differ
diff --git a/Logic/Logic.csproj b/Logic/Logic.csproj
index 23d5b8a9..9f83d822 100644
--- a/Logic/Logic.csproj
+++ b/Logic/Logic.csproj
@@ -78,6 +78,9 @@
..\packages\Markdig.0.10.3\lib\net40\Markdig.dll
True
+
+ ..\External Libraries\Mono.Posix.dll
+
..\packages\MySql.Data.6.9.9\lib\net45\MySql.Data.dll
True
diff --git a/Logic/Support/Document.cs b/Logic/Support/Document.cs
index 29d14d62..64302ebd 100644
--- a/Logic/Support/Document.cs
+++ b/Logic/Support/Document.cs
@@ -10,6 +10,7 @@ using Swarmops.Database;
using Swarmops.Logic.Communications;
using Swarmops.Logic.Financial;
using Swarmops.Logic.Swarm;
+using Mono.Unix.Native;
namespace Swarmops.Logic.Support
{
@@ -161,9 +162,15 @@ namespace Swarmops.Logic.Support
public void Delete()
{
- // Unlink, actually
+ // If we're not in debug mode, set permissions to allow delete
- SetForeignObject (new TemporaryIdentity (0));
+ if (!Debugger.IsAttached)
+ {
+ Syscall.chmod(StorageRoot + ServerFileName,
+ FilePermissions.S_IRUSR | FilePermissions.S_IWUSR | FilePermissions.S_IRGRP | FilePermissions.S_IROTH);
+ }
+
+ SetForeignObject(new TemporaryIdentity (0));
File.Delete (StorageRoot + ServerFileName);
SwarmDb.GetDatabaseForWriting().SetDocumentDescription (Identity, "Deleted");
}
diff --git a/Site/Automation/UploadFileHandler.ashx b/Site/Automation/UploadFileHandler.ashx
index 561b253c..33746a08 100644
--- a/Site/Automation/UploadFileHandler.ashx
+++ b/Site/Automation/UploadFileHandler.ashx
@@ -252,7 +252,7 @@ namespace Swarmops.Frontend.Automation
file.InputStream.Position = 0;
file.SaveAs(StorageRoot + relativeFileName);
- // Set file permissions to rwxr--r-- if live environment
+ // Set file permissions to -r--r--r-- if live environment
if (!WeAreInDebugEnvironment)
{
diff --git a/Site/Pages/v5/Ledgers/VatReports.aspx b/Site/Pages/v5/Ledgers/VatReports.aspx
new file mode 100644
index 00000000..b1d2d3a0
--- /dev/null
+++ b/Site/Pages/v5/Ledgers/VatReports.aspx
@@ -0,0 +1,7 @@
+<%@ Page Title="" Language="C#" MasterPageFile="~/Master-v5.master" AutoEventWireup="true" CodeBehind="VatReports.aspx.cs" Inherits="Swarmops.Frontend.Pages.v5.Ledgers.VatReports" %>
+
+
+
+
+
+
diff --git a/Site/Pages/v5/Ledgers/VatReports.aspx.cs b/Site/Pages/v5/Ledgers/VatReports.aspx.cs
new file mode 100644
index 00000000..e16f21b2
--- /dev/null
+++ b/Site/Pages/v5/Ledgers/VatReports.aspx.cs
@@ -0,0 +1,17 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace Swarmops.Frontend.Pages.v5.Ledgers
+{
+ public partial class VatReports : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git a/Site/Pages/v5/Ledgers/VatReports.aspx.designer.cs b/Site/Pages/v5/Ledgers/VatReports.aspx.designer.cs
new file mode 100644
index 00000000..f5756de1
--- /dev/null
+++ b/Site/Pages/v5/Ledgers/VatReports.aspx.designer.cs
@@ -0,0 +1,17 @@
+//------------------------------------------------------------------------------
+//
+// This code was generated by a tool.
+//
+// Changes to this file may cause incorrect behavior and will be lost if
+// the code is regenerated.
+//
+//------------------------------------------------------------------------------
+
+namespace Swarmops.Frontend.Pages.v5.Ledgers
+{
+
+
+ public partial class VatReports
+ {
+ }
+}
diff --git a/Site/Site.csproj b/Site/Site.csproj
index 49a351c7..28f3039b 100644
--- a/Site/Site.csproj
+++ b/Site/Site.csproj
@@ -502,6 +502,13 @@
UploadBankFiles.aspx
+
+ VatReports.aspx
+ ASPXCodeBehind
+
+
+ VatReports.aspx
+
ViewOutstandingAccounts.aspx
ASPXCodeBehind
@@ -1108,6 +1115,7 @@
+