|
@@ -2,7 +2,10 @@ using OASystem.Domain.AesEncryption;
|
|
|
using OASystem.Domain.Entities.Customer;
|
|
|
using OASystem.Domain.Entities.Financial;
|
|
|
using OASystem.Domain.Entities.Groups;
|
|
|
+using SqlSugar;
|
|
|
using System.Collections;
|
|
|
+using System.Data;
|
|
|
+using static NPOI.HSSF.Util.HSSFColor;
|
|
|
using static OASystem.API.OAMethodLib.GeneralMethod;
|
|
|
using static OASystem.API.OAMethodLib.JWTHelper;
|
|
|
|
|
@@ -3047,5 +3050,70 @@ And u.UId = {0} And u.FId = 1 ", dto.UserId);
|
|
|
return Ok(JsonView(false));
|
|
|
}
|
|
|
#endregion
|
|
|
+
|
|
|
+ #region backups
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ [HttpGet)]
|
|
|
+ [ProducesResponseType(typeof(JsonView), StatusCodes.Status200OK)]
|
|
|
+ public async Task<IActionResult> SQLServerBackups()
|
|
|
+ {
|
|
|
+ var now = DateTime.Now;
|
|
|
+
|
|
|
+ var folderPath = $"D:\\数据备份\\{now.ToString("yyyyMMdd")}\\SQLServerBackups";
|
|
|
+ if (!Directory.Exists(folderPath)) Directory.CreateDirectory(folderPath);
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ return Ok(JsonView(false));
|
|
|
+ }
|
|
|
+
|
|
|
+ #endregion
|
|
|
}
|
|
|
}
|