增加图片验证码

This commit is contained in:
2021-01-11 16:02:17 +08:00
parent 269fd4a6fe
commit 9623fb033b
7 changed files with 372 additions and 9 deletions
@@ -179,8 +179,8 @@ namespace COMCMS.Web.Areas.AdminCP.Controllers
{
if (!string.IsNullOrWhiteSpace(model.WaterMarkImg))
{
string imgPath = _env.WebRootPath + model.WaterMarkImg.Replace("/", "\\");
NewLife.Log.XTrace.WriteLine(_env.WebRootPath + "|" + Path.Combine(_env.WebRootPath, model.WaterMarkImg) + "|" + imgPath);
string imgPath = _env.WebRootPath + model.WaterMarkImg.Replace("/", Path.DirectorySeparatorChar.ToString());
//NewLife.Log.XTrace.WriteLine(_env.WebRootPath + "|" + Path.Combine(_env.WebRootPath, model.WaterMarkImg) + "|" + imgPath);
if (!System.IO.File.Exists(imgPath))
{
tip.Message = "水印图片不存在,请重新上传!";
@@ -12,7 +12,7 @@ using COMCMS.Web.Models;
using Newtonsoft.Json;
using System.IO;
using COMCMS.Core.Models;
using System.DrawingCore;
using System.Drawing;
using System.Text;
using Microsoft.AspNetCore.Http;
using Microsoft.Extensions.Primitives;