新增锚定点
This commit is contained in:
parent
b0700e195b
commit
f5b8090e92
|
|
@ -0,0 +1,32 @@
|
||||||
|
using System;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Drawing.Imaging;
|
||||||
|
using System.IO;
|
||||||
|
|
||||||
|
|
||||||
|
public static class BitmapHelper
|
||||||
|
{
|
||||||
|
|
||||||
|
public static Stream ToStream(this Bitmap bitmap)
|
||||||
|
{
|
||||||
|
MemoryStream ms = new MemoryStream();
|
||||||
|
bitmap.Save(ms, System.Drawing.Imaging.ImageFormat.Jpeg);
|
||||||
|
ms.Seek(0, SeekOrigin.Begin);
|
||||||
|
return ms;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public static byte[] Bitmap2Byte(this Bitmap bitmap)
|
||||||
|
{
|
||||||
|
using (MemoryStream stream = new MemoryStream())
|
||||||
|
{
|
||||||
|
bitmap.Save(stream, ImageFormat.Jpeg);
|
||||||
|
byte[] data = new byte[stream.Length];
|
||||||
|
stream.Seek(0, SeekOrigin.Begin);
|
||||||
|
stream.Read(data, 0, Convert.ToInt32(stream.Length));
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -171,7 +171,7 @@ public class CommonUse
|
||||||
|
|
||||||
|
|
||||||
CommonUse commonUse = new CommonUse();
|
CommonUse commonUse = new CommonUse();
|
||||||
string[] postionc = postionCut.Split('^');
|
string[] postionc = postionCut.Split(new string[] { "^" }, StringSplitOptions.RemoveEmptyEntries);
|
||||||
PYPostion = "";
|
PYPostion = "";
|
||||||
Point GrXY;
|
Point GrXY;
|
||||||
int PostionWW = 0;
|
int PostionWW = 0;
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,65 @@
|
||||||
|
using PaddleOCRSharp;
|
||||||
|
using System;
|
||||||
|
using System.Drawing;
|
||||||
|
|
||||||
|
public class OcrHelper
|
||||||
|
{
|
||||||
|
|
||||||
|
//private static TesseractEngine engine = new TesseractEngine("./ocr_models", "chi_sim");
|
||||||
|
//public static OCRResult GetOcrResult(Bitmap bitmap)
|
||||||
|
//{
|
||||||
|
// try
|
||||||
|
// {
|
||||||
|
// using var tempBitmap = new Bitmap(bitmap);
|
||||||
|
// var ocrResult = paddleOCREngine.DetectText(tempBitmap);
|
||||||
|
// return ocrResult;
|
||||||
|
// }
|
||||||
|
// catch (Exception ex)
|
||||||
|
// {
|
||||||
|
// ExceptionNotice.SendAsync(ex, "Ocr文字识别异常!");
|
||||||
|
// throw;
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
|
||||||
|
private static string RootDirectory = EngineBase.GetRootDirectory().TrimEnd('\\') + "\\inference";
|
||||||
|
|
||||||
|
//建议程序全局初始化一次即可,不必每次识别都初始化,容易报错。
|
||||||
|
private static PaddleOCREngine paddleOCREngine = paddleOCREngine = new PaddleOCREngine(new OCRModelConfig()
|
||||||
|
{
|
||||||
|
det_infer = RootDirectory + "\\ch_PP-OCRv3_det_infer",
|
||||||
|
cls_infer= RootDirectory + "\\ch_ppocr_mobile_v2.0_cls_infer",
|
||||||
|
rec_infer = RootDirectory + "\\ch_PP-OCRv3_rec_infer",
|
||||||
|
keys = RootDirectory + "\\ppocr_keys.txt",
|
||||||
|
}, new OCRParameter());
|
||||||
|
|
||||||
|
public static OCRResult GetOcrResult(Bitmap bitmap)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
using (var tempBitmap = new Bitmap(bitmap))
|
||||||
|
{
|
||||||
|
return paddleOCREngine.DetectText(tempBitmap);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
throw;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static OCRResult GetOcrResult(byte[] bytes)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
var ocrResult = paddleOCREngine.DetectText(bytes);
|
||||||
|
return ocrResult;
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
|
||||||
|
throw;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
Binary file not shown.
|
|
@ -70,28 +70,31 @@
|
||||||
<div class="maodian" id="point_2">左下锚点</div>
|
<div class="maodian" id="point_2">左下锚点</div>
|
||||||
<div class="maodian" id="point_3">右下锚点</div>
|
<div class="maodian" id="point_3">右下锚点</div>
|
||||||
</td>
|
</td>
|
||||||
<td style="padding: 0;" valign="top" >
|
<td style="padding: 0;" valign="top">
|
||||||
<% if (PageIndex == "1") { %>
|
<% if (PageIndex == "1")
|
||||||
<div class="tiaomasz_hover">第一页</div>
|
{ %>
|
||||||
|
<div class="pageindex_hover">第一页</div>
|
||||||
<% }
|
<% }
|
||||||
else
|
else
|
||||||
{ %>
|
{ %>
|
||||||
<div class="tiaomasz" onclick="ChangePageNum(<%=AnotherTempID %>)">第一页</div>
|
<div class="pageindex" onclick="ChangePageNum(<%=AnotherTempID %>)">第一页</div>
|
||||||
<% } %>
|
<% } %>
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
<% if (PageCount >1) { %>
|
<% if (PageCount > 1)
|
||||||
<td style="padding: 0;" valign="top" >
|
|
||||||
<% if (PageIndex == "2") { %>
|
|
||||||
<div class="tiaomasz_hover">第二页</div>
|
|
||||||
<% }
|
|
||||||
else
|
|
||||||
{ %>
|
{ %>
|
||||||
<div class="tiaomasz" onclick="ChangePageNum(<%=AnotherTempID %>)">第二页</div>
|
<td style="padding: 0;" valign="top">
|
||||||
|
<% if (PageIndex == "2")
|
||||||
|
{ %>
|
||||||
|
<div class="pageindex_hover">第二页</div>
|
||||||
|
<% }
|
||||||
|
else
|
||||||
|
{ %>
|
||||||
|
<div class="pageindex" onclick="ChangePageNum(<%=AnotherTempID %>)">第二页</div>
|
||||||
<% } %>
|
<% } %>
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
<% } %>
|
<% } %>
|
||||||
<td class="lockHide">
|
<td class="lockHide">
|
||||||
<span>纸张类型:</span>
|
<span>纸张类型:</span>
|
||||||
<select id="selectPageSize" disabled onchange="ChangePageSize(this)" style="font-size: 14px; padding-left: 10px; padding-right: 20px; width: 100px;">
|
<select id="selectPageSize" disabled onchange="ChangePageSize(this)" style="font-size: 14px; padding-left: 10px; padding-right: 20px; width: 100px;">
|
||||||
|
|
@ -99,6 +102,8 @@
|
||||||
<option value="1570">A3</option>
|
<option value="1570">A3</option>
|
||||||
</select>
|
</select>
|
||||||
</td>
|
</td>
|
||||||
|
<% if (PageIndex == "1")
|
||||||
|
{ %>
|
||||||
<th valign="middle" class="lockHide">
|
<th valign="middle" class="lockHide">
|
||||||
<div class="main_select_one">
|
<div class="main_select_one">
|
||||||
<span>准考证号:</span>
|
<span>准考证号:</span>
|
||||||
|
|
@ -116,8 +121,7 @@
|
||||||
</select>
|
</select>
|
||||||
<span class="main_select_set" id="main_select_set" onclick="SetXuehao(this)">设置准考证号</span>
|
<span class="main_select_set" id="main_select_set" onclick="SetXuehao(this)">设置准考证号</span>
|
||||||
</div>
|
</div>
|
||||||
</th>
|
</th>
|
||||||
|
|
||||||
<td style="padding: 0;" valign="top" class="lockHide">
|
<td style="padding: 0;" valign="top" class="lockHide">
|
||||||
<div class="tiaomasz" onclick="SetTiaoMa(this)">设置条码</div>
|
<div class="tiaomasz" onclick="SetTiaoMa(this)">设置条码</div>
|
||||||
</td>
|
</td>
|
||||||
|
|
@ -127,6 +131,11 @@
|
||||||
<td class="lockHide">
|
<td class="lockHide">
|
||||||
<div class="biaozhundian" onclick="SetBiaoZhunDian(this)">标准涂点</div>
|
<div class="biaozhundian" onclick="SetBiaoZhunDian(this)">标准涂点</div>
|
||||||
</td>
|
</td>
|
||||||
|
<td class="lockHide">
|
||||||
|
<div class="maodingdian" onclick="SetMaoDingDian(this)">锚定点</div>
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<% }%>
|
||||||
<td class="lockHide">
|
<td class="lockHide">
|
||||||
<div class="pingbi" onclick="SetHideArea()">增加屏蔽</div>
|
<div class="pingbi" onclick="SetHideArea()">增加屏蔽</div>
|
||||||
</td>
|
</td>
|
||||||
|
|
@ -270,13 +279,16 @@
|
||||||
<br />
|
<br />
|
||||||
<br />
|
<br />
|
||||||
<div style="margin-left: 45px;" class="goPeizhi" onclick="SetZhuguanTi()">开始配置</div>
|
<div style="margin-left: 45px;" class="goPeizhi" onclick="SetZhuguanTi()">开始配置</div>
|
||||||
|
|
||||||
|
<% if (Request.QueryString["ishand"] == "1")
|
||||||
|
{ %>
|
||||||
<div id="isHand_Py" style="float: left; width: 100%; text-align: left; margin-top: 10px; border-bottom: 1px solid #ddd; padding-bottom: 5px;">
|
<div id="isHand_Py" style="float: left; width: 100%; text-align: left; margin-top: 10px; border-bottom: 1px solid #ddd; padding-bottom: 5px;">
|
||||||
先批后阅题号:
|
先批后阅题号:
|
||||||
<select id="py_tihao"></select>
|
<select id="py_tihao"></select>
|
||||||
<input type="button" value="题目配置" id="pytimups" onclick="SetPYPostion(0)" style="width: 90px; margin-right: 10px;" />
|
<input type="button" value="题目配置" id="pytimups" onclick="SetPYPostion(0)" style="width: 90px; margin-right: 10px;" />
|
||||||
<%-- <input onclick="SetPYPostion(1)" style="width:100px;margin-right:10px;" type="button" value="常规题" />--%>
|
<%-- <input onclick="SetPYPostion(1)" style="width:100px;margin-right:10px;" type="button" value="常规题" />--%>
|
||||||
</div>
|
</div>
|
||||||
|
<% } %>
|
||||||
|
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
@ -305,6 +317,16 @@
|
||||||
}
|
}
|
||||||
SelectValueList();
|
SelectValueList();
|
||||||
</script>
|
</script>
|
||||||
|
<script>
|
||||||
|
String.prototype.trim = function (char) {
|
||||||
|
char = char||'\s'
|
||||||
|
char = char.replace("^", "\\^")
|
||||||
|
char = char.replace("+", "\\+")
|
||||||
|
char = char.replace("$", "\\$")
|
||||||
|
return this.replace(new RegExp('^' + char + '*|' + char + '*$', 'g'), '');
|
||||||
|
|
||||||
|
};
|
||||||
|
</script>
|
||||||
<script src="../js/index.js"></script>
|
<script src="../js/index.js"></script>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
|
|
|
||||||
|
|
@ -23,6 +23,7 @@ using Emgu.CV.Flann;
|
||||||
using System.Data.SqlTypes;
|
using System.Data.SqlTypes;
|
||||||
using System.Security.AccessControl;
|
using System.Security.AccessControl;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
|
using PaddleOCRSharp;
|
||||||
|
|
||||||
public partial class 外部答题卡_Default : System.Web.UI.Page
|
public partial class 外部答题卡_Default : System.Web.UI.Page
|
||||||
{
|
{
|
||||||
|
|
@ -385,6 +386,7 @@ public partial class 外部答题卡_Default : System.Web.UI.Page
|
||||||
int PageIndex = Convert.ToInt32(Globals.Request("PageIndex"));
|
int PageIndex = Convert.ToInt32(Globals.Request("PageIndex"));
|
||||||
if (PageIndex == 1)
|
if (PageIndex == 1)
|
||||||
{
|
{
|
||||||
|
//计算标准点
|
||||||
int mx = GetOtherBitmaplist(currentFramext.Mat, 160, PYPostionList.Split(','), GetData[9]);
|
int mx = GetOtherBitmaplist(currentFramext.Mat, 160, PYPostionList.Split(','), GetData[9]);
|
||||||
if (mx == 0)
|
if (mx == 0)
|
||||||
{
|
{
|
||||||
|
|
@ -397,6 +399,18 @@ public partial class 外部答题卡_Default : System.Web.UI.Page
|
||||||
sql = "UPDATE MK_TempleteMain SET option_pixel_options=" + mx + " WHERE ID_bigint=" + MainTempId;
|
sql = "UPDATE MK_TempleteMain SET option_pixel_options=" + mx + " WHERE ID_bigint=" + MainTempId;
|
||||||
new MysqlDBHelper(tenant).ExecuteNoQuery(sql);
|
new MysqlDBHelper(tenant).ExecuteNoQuery(sql);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 存在锚定点数据则判断锚定点内容
|
||||||
|
//if (!string.IsNullOrWhiteSpace(GetData[10]) && GetData[10].Split(',').Length == 6)
|
||||||
|
//{
|
||||||
|
// //计算锚定点
|
||||||
|
// var ocrResultText = string.Empty;
|
||||||
|
// if (!GetMaoDingDian(PictureBoxBitMap, GetData[10], out ocrResultText))
|
||||||
|
// {
|
||||||
|
// Response.Write("未找到匹配的文字,识别结果【" + ocrResultText+"】");
|
||||||
|
// return false;
|
||||||
|
// }
|
||||||
|
//}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -406,7 +420,7 @@ public partial class 外部答题卡_Default : System.Web.UI.Page
|
||||||
new MySqlParameter("@CutWidth_int",oldWidth),
|
new MySqlParameter("@CutWidth_int",oldWidth),
|
||||||
new MySqlParameter("@CutHeight_int",oldHeight),
|
new MySqlParameter("@CutHeight_int",oldHeight),
|
||||||
new MySqlParameter("@PyPPostion_nvarchar",PYPostionList)
|
new MySqlParameter("@PyPPostion_nvarchar",PYPostionList)
|
||||||
};
|
};
|
||||||
|
|
||||||
if (new MysqlDBHelper(tenant).ExecuteNoQuery(sql, sp) > 0)
|
if (new MysqlDBHelper(tenant).ExecuteNoQuery(sql, sp) > 0)
|
||||||
{
|
{
|
||||||
|
|
@ -495,11 +509,12 @@ public partial class 外部答题卡_Default : System.Web.UI.Page
|
||||||
int H = Convert.ToInt32(Convert.ToDouble(quekao[3]));
|
int H = Convert.ToInt32(Convert.ToDouble(quekao[3]));
|
||||||
int xuanXiang = 1;//选项数量
|
int xuanXiang = 1;//选项数量
|
||||||
int tiliang = 1;//题量
|
int tiliang = 1;//题量
|
||||||
string mx = "";
|
//string mx = "";
|
||||||
int wL = Convert.ToInt32(W / xuanXiang);
|
int wL = Convert.ToInt32(W / xuanXiang);
|
||||||
int hL = Convert.ToInt32(H / tiliang);
|
int hL = Convert.ToInt32(H / tiliang);
|
||||||
|
|
||||||
Image<Gray, byte> bytimg = GetMatCutImg(color_mat.Bitmap, X, Y, W, H);
|
Image<Gray, byte> bytimg = GetMatCutImg(color_mat.Bitmap, X, Y, W, H);
|
||||||
|
|
||||||
X = 0; Y = 0;
|
X = 0; Y = 0;
|
||||||
Mat src = bytimg.Mat;
|
Mat src = bytimg.Mat;
|
||||||
Mat mat_threshold = new Mat();
|
Mat mat_threshold = new Mat();
|
||||||
|
|
@ -509,12 +524,66 @@ public partial class 外部答题卡_Default : System.Web.UI.Page
|
||||||
int option_pixel_options = 0;
|
int option_pixel_options = 0;
|
||||||
selected_contours = GetUsefulContoursSelectoOptionQK(mat_dilate, 1, out option_pixel_options);
|
selected_contours = GetUsefulContoursSelectoOptionQK(mat_dilate, 1, out option_pixel_options);
|
||||||
|
|
||||||
mx = GetValueAndDrawGrid_Other(src.Bitmap, selected_contours, X, wL, xuanXiang, Y, hL, tiliang, "");
|
//mx = GetValueAndDrawGrid_Other(src.Bitmap, selected_contours, X, wL, xuanXiang, Y, hL, tiliang, "");
|
||||||
bytimg.Dispose();
|
bytimg.Dispose();
|
||||||
src.Dispose();
|
src.Dispose();
|
||||||
return option_pixel_options;
|
return option_pixel_options;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 获取其他截图
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="color_mat"></param>
|
||||||
|
/// <param name="PYPostion"></param>
|
||||||
|
/// <param name="postiontiaomaX"></param>
|
||||||
|
/// <param name="selected_contours"></param>
|
||||||
|
/// <param name="pageIndex"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
public static bool GetMaoDingDian(Bitmap srcBimap, string positionStr, out string ocrResultText)
|
||||||
|
{
|
||||||
|
ocrResultText = string.Empty;
|
||||||
|
CommonUse commonUse = new CommonUse();
|
||||||
|
string[] ocrText = positionStr.Split(',');
|
||||||
|
|
||||||
|
int X = Convert.ToInt32(Convert.ToDouble(ocrText[0]));
|
||||||
|
int Y = Convert.ToInt32(Convert.ToDouble(ocrText[1]));
|
||||||
|
int W = Convert.ToInt32(Convert.ToDouble(ocrText[2]));
|
||||||
|
int H = Convert.ToInt32(Convert.ToDouble(ocrText[3]));
|
||||||
|
|
||||||
|
Image<Gray, byte> bytimg = GetMatCutImg(srcBimap, X, Y, W, H);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//commonUse.ShowMatWaitKey("maodingdian", bytimg.Mat, 2);
|
||||||
|
|
||||||
|
var ocrResult = OcrHelper.GetOcrResult(bytimg.Bitmap);
|
||||||
|
if (ocrResult == null || string.IsNullOrWhiteSpace(ocrResult.Text))
|
||||||
|
{
|
||||||
|
// 未找到任何文字
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
ocrResultText = ocrResult.Text;
|
||||||
|
|
||||||
|
if (bytimg != null)
|
||||||
|
{
|
||||||
|
bytimg.Dispose();
|
||||||
|
}
|
||||||
|
|
||||||
|
var ocrResultArr = ocrResult.Text.ToCharArray();
|
||||||
|
var ocrTestArr = ocrText[5].ToCharArray();
|
||||||
|
var interList = ocrTestArr.Intersect(ocrResultArr);
|
||||||
|
if (interList.Count() == ocrTestArr.Length)
|
||||||
|
{
|
||||||
|
// 找到输入文字
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
ocrResultText = ocrResult.Text;
|
||||||
|
// 未找到输入文字
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 筛选图中符合给定条件的轮廓
|
/// 筛选图中符合给定条件的轮廓
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
@ -558,6 +627,36 @@ public partial class 外部答题卡_Default : System.Web.UI.Page
|
||||||
return selected_contours;
|
return selected_contours;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public static VectorOfVectorOfPoint GetUsefulContoursForMaoDingDian(Mat mat)
|
||||||
|
{
|
||||||
|
VectorOfVectorOfPoint contours = new VectorOfVectorOfPoint();//所有的轮廓
|
||||||
|
VectorOfVectorOfPoint selected_contours = new VectorOfVectorOfPoint();//用于存储筛选过后的轮廓
|
||||||
|
CvInvoke.FindContours(mat, contours, null, Emgu.CV.CvEnum.RetrType.List,
|
||||||
|
Emgu.CV.CvEnum.ChainApproxMethod.ChainApproxSimple);//提取所有轮廓,操作过程中会对输入图像进行修改
|
||||||
|
|
||||||
|
//筛选轮廓。筛选条件:长宽比大于给定值
|
||||||
|
for (int i = 0; i < contours.Size; i++)
|
||||||
|
{
|
||||||
|
Rectangle rect = CvInvoke.BoundingRectangle(contours[i]);//外接矩形
|
||||||
|
Mat temp = new Mat(mat, rect);//提取ROI矩形区域
|
||||||
|
int pxNums = CvInvoke.CountNonZero(temp);//计算图像内非零像素个数
|
||||||
|
|
||||||
|
double area = CvInvoke.ContourArea(contours[i]);//计算连通轮廓的面积
|
||||||
|
double length = CvInvoke.ArcLength(contours[i], false); //计算连通轮廓的周长
|
||||||
|
|
||||||
|
VectorOfPoint approx_curve = new VectorOfPoint();//用于存放逼近的结果
|
||||||
|
CvInvoke.ApproxPolyDP(contours[i], approx_curve, length * 0.02, true);
|
||||||
|
|
||||||
|
bool bo = ((area > 10 && area < 150000) && rect.Height > 5 && rect.Width > 5);
|
||||||
|
if (bo)
|
||||||
|
{
|
||||||
|
selected_contours.Push(contours[i]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return selected_contours;
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 画出网格并返回填图结果
|
/// 画出网格并返回填图结果
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
@ -1110,7 +1209,7 @@ public partial class 外部答题卡_Default : System.Web.UI.Page
|
||||||
{
|
{
|
||||||
var tempbitmap = new Bitmap(imgRequest.GetResponse().GetResponseStream());
|
var tempbitmap = new Bitmap(imgRequest.GetResponse().GetResponseStream());
|
||||||
|
|
||||||
// 别删!图片和网页中的方向不一致,根据图片中的方向信息,旋转图片后识别
|
// 别删!图片和网页中的方向不一致,根据图片中的方向信息,旋转图片后识别
|
||||||
return new CommonUse().RotateByOrientation(tempbitmap);
|
return new CommonUse().RotateByOrientation(tempbitmap);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
|
||||||
|
|
@ -186,7 +186,8 @@ public partial class Temp_SplitQuestion : System.Web.UI.Page
|
||||||
|
|
||||||
|
|
||||||
//调用接口
|
//调用接口
|
||||||
result r = (result)JavaScriptConvert.DeserializeObject(RequestPost(subjective.ToString(), lt.ToJsonString()), typeof(result));
|
//result r = (result)JsonConvert.DeserializeObject(RequestPost(subjective.ToString(), lt.ToJsonString()), typeof(result));
|
||||||
|
var r =JsonConvert.DeserializeObject<result>(RequestPost(subjective.ToString(), JsonConvert.SerializeObject(lt)));
|
||||||
if (r.code == "200" && r.data)
|
if (r.code == "200" && r.data)
|
||||||
{
|
{
|
||||||
Response.Write("1");
|
Response.Write("1");
|
||||||
|
|
@ -431,8 +432,9 @@ public partial class Temp_SplitQuestion : System.Web.UI.Page
|
||||||
{
|
{
|
||||||
throw new Exception("验证接口调用失败!" + Response.StatusCode + " ||| " + reponse.Html);
|
throw new Exception("验证接口调用失败!" + Response.StatusCode + " ||| " + reponse.Html);
|
||||||
}
|
}
|
||||||
|
|
||||||
return (result)JavaScriptConvert.DeserializeObject(reponse.Html, typeof(result));
|
//return (result)JsonConvert.DeserializeObject(reponse.Html, typeof(result));
|
||||||
|
return JsonConvert.DeserializeObject<result>(reponse.Html);
|
||||||
}
|
}
|
||||||
private string RequestPost(string id, string body)
|
private string RequestPost(string id, string body)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
26
Web.config
26
Web.config
|
|
@ -1,4 +1,4 @@
|
||||||
<?xml version="1.0"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<!--
|
<!--
|
||||||
有关如何配置 ASP.NET 应用程序的详细信息,请访问
|
有关如何配置 ASP.NET 应用程序的详细信息,请访问
|
||||||
http://go.microsoft.com/fwlink/?LinkId=169433
|
http://go.microsoft.com/fwlink/?LinkId=169433
|
||||||
|
|
@ -13,19 +13,31 @@
|
||||||
</system.Web>
|
</system.Web>
|
||||||
-->
|
-->
|
||||||
<system.web>
|
<system.web>
|
||||||
<compilation targetFramework="4.8" debug="true"/>
|
<compilation targetFramework="4.8" debug="true" />
|
||||||
<httpRuntime executionTimeout="600" maxRequestLength="419430400" targetFramework="4.5.2"/>
|
<httpRuntime executionTimeout="600" maxRequestLength="419430400" targetFramework="4.5.2" />
|
||||||
<customErrors mode="Off"/>
|
<customErrors mode="Off" />
|
||||||
</system.web>
|
</system.web>
|
||||||
<system.webServer>
|
<system.webServer>
|
||||||
<security>
|
<security>
|
||||||
<requestFiltering>
|
<requestFiltering>
|
||||||
<requestLimits maxAllowedContentLength="419430400"/>
|
<requestLimits maxAllowedContentLength="419430400" />
|
||||||
</requestFiltering>
|
</requestFiltering>
|
||||||
</security>
|
</security>
|
||||||
<directoryBrowse enabled="true"/>
|
<directoryBrowse enabled="true" />
|
||||||
<modules>
|
<modules>
|
||||||
<remove name="WebDAVModule"/>
|
<remove name="WebDAVModule" />
|
||||||
</modules>
|
</modules>
|
||||||
</system.webServer>
|
</system.webServer>
|
||||||
|
<runtime>
|
||||||
|
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||||
|
<dependentAssembly>
|
||||||
|
<assemblyIdentity name="System.Runtime.CompilerServices.Unsafe" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
|
||||||
|
<bindingRedirect oldVersion="0.0.0.0-5.0.0.0" newVersion="5.0.0.0" />
|
||||||
|
</dependentAssembly>
|
||||||
|
<dependentAssembly>
|
||||||
|
<assemblyIdentity name="System.Memory" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
|
||||||
|
<bindingRedirect oldVersion="0.0.0.0-4.0.1.1" newVersion="4.0.1.1" />
|
||||||
|
</dependentAssembly>
|
||||||
|
</assemblyBinding>
|
||||||
|
</runtime>
|
||||||
</configuration>
|
</configuration>
|
||||||
|
|
@ -156,6 +156,30 @@ a, abbr, address, b, blockquote, body, caption, cite, code, dd, del, dfn, div, d
|
||||||
border: 1px solid #ddd;
|
border: 1px solid #ddd;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.pageindex {
|
||||||
|
width: 90px;
|
||||||
|
height: 20px;
|
||||||
|
font-size: 14px;
|
||||||
|
letter-spacing: 5px;
|
||||||
|
padding: 5px;
|
||||||
|
text-align: center;
|
||||||
|
border: 1px solid #ddd;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.pageindex_hover {
|
||||||
|
width: 90px;
|
||||||
|
height: 20px;
|
||||||
|
font-size: 14px;
|
||||||
|
letter-spacing: 5px;
|
||||||
|
padding: 5px;
|
||||||
|
text-align: center;
|
||||||
|
border: 1px solid #ff3300;
|
||||||
|
cursor: pointer;
|
||||||
|
color: #ff3300;
|
||||||
|
}
|
||||||
|
|
||||||
.tiaomasz_hover {
|
.tiaomasz_hover {
|
||||||
width: 90px;
|
width: 90px;
|
||||||
height: 20px;
|
height: 20px;
|
||||||
|
|
@ -202,6 +226,17 @@ a, abbr, address, b, blockquote, body, caption, cite, code, dd, del, dfn, div, d
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.maodingdian {
|
||||||
|
width: 90px;
|
||||||
|
height: 20px;
|
||||||
|
font-size: 13px;
|
||||||
|
letter-spacing: 5px;
|
||||||
|
padding: 5px;
|
||||||
|
text-align: center;
|
||||||
|
border: 1px solid #ddd;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
.biaozhundian_hover {
|
.biaozhundian_hover {
|
||||||
width: 90px;
|
width: 90px;
|
||||||
height: 20px;
|
height: 20px;
|
||||||
|
|
@ -214,6 +249,18 @@ a, abbr, address, b, blockquote, body, caption, cite, code, dd, del, dfn, div, d
|
||||||
color: #ff3300;
|
color: #ff3300;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.maodingdian_hover {
|
||||||
|
width: 90px;
|
||||||
|
height: 20px;
|
||||||
|
font-size: 14px;
|
||||||
|
letter-spacing: 5px;
|
||||||
|
padding: 5px;
|
||||||
|
text-align: center;
|
||||||
|
border: 1px solid #ff3300;
|
||||||
|
cursor: pointer;
|
||||||
|
color: #ff3300;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -301,7 +348,7 @@ a, abbr, address, b, blockquote, body, caption, cite, code, dd, del, dfn, div, d
|
||||||
margin-top: 5px;
|
margin-top: 5px;
|
||||||
}
|
}
|
||||||
.main_select_set { width:100px; padding:7px; margin-left:5px; border:1px solid #ddd; padding-left:10px; padding-right:10px; cursor:pointer;}
|
.main_select_set { width:100px; padding:7px; margin-left:5px; border:1px solid #ddd; padding-left:10px; padding-right:10px; cursor:pointer;}
|
||||||
.main_select_set_hover { padding:7px; line-height:20px; margin-left:5px; border:1px solid #ff3300; color:#999; padding-left:10px; padding-right:10px; cursor:pointer;}
|
.main_select_set_hover { padding:7px; line-height:20px; margin-left:5px; border:1px solid #ff3300; color: #ff3300; padding-left:10px; padding-right:10px; cursor:pointer;}
|
||||||
.main_select_one select { width:50px; text-align:center; padding:5px; }
|
.main_select_one select { width:50px; text-align:center; padding:5px; }
|
||||||
.main_select_one span { line-height:20px;}
|
.main_select_one span { line-height:20px;}
|
||||||
.xuehaotable_list { width:100%; height:100%; overflow:hidden; border-bottom:1px solid #ddd;border-left:1px solid #ddd; }
|
.xuehaotable_list { width:100%; height:100%; overflow:hidden; border-bottom:1px solid #ddd;border-left:1px solid #ddd; }
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,25 @@
|
||||||
|
{
|
||||||
|
"use_gpu": false,
|
||||||
|
"gpu_id": 0,
|
||||||
|
"gpu_mem": 4000,
|
||||||
|
"cpu_math_library_num_threads": 10,
|
||||||
|
"enable_mkldnn": true,
|
||||||
|
"det": true,
|
||||||
|
"rec": true,
|
||||||
|
"cls": false,
|
||||||
|
"max_side_len": 960,
|
||||||
|
"det_db_thresh": 0.3,
|
||||||
|
"det_db_box_thresh": 0.618,
|
||||||
|
"det_db_unclip_ratio": 1.6,
|
||||||
|
"use_dilation": false,
|
||||||
|
"det_db_score_mode": true,
|
||||||
|
"visualize": false,
|
||||||
|
"use_angle_cls": false,
|
||||||
|
"cls_thresh": 0.9,
|
||||||
|
"cls_batch_num": 1,
|
||||||
|
"rec_batch_num": 6,
|
||||||
|
"rec_img_h": 48,
|
||||||
|
"rec_img_w": 320,
|
||||||
|
"show_img_vis": false,
|
||||||
|
"use_tensorrt": false
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,28 @@
|
||||||
|
{
|
||||||
|
"use_gpu": false,
|
||||||
|
"gpu_id": 0,
|
||||||
|
"gpu_mem": 4000,
|
||||||
|
"cpu_math_library_num_threads": 10,
|
||||||
|
"enable_mkldnn": true,
|
||||||
|
"det": true,
|
||||||
|
"rec": true,
|
||||||
|
"cls": false,
|
||||||
|
"max_side_len": 960,
|
||||||
|
"det_db_thresh": 0.3,
|
||||||
|
"det_db_box_thresh": 0.618,
|
||||||
|
"det_db_unclip_ratio": 1.6,
|
||||||
|
"use_dilation": false,
|
||||||
|
"det_db_score_mode": true,
|
||||||
|
"visualize": false,
|
||||||
|
"use_angle_cls": false,
|
||||||
|
"cls_thresh": 0.9,
|
||||||
|
"cls_batch_num": 1,
|
||||||
|
"rec_batch_num": 6,
|
||||||
|
"rec_img_h": 48,
|
||||||
|
"rec_img_w": 320,
|
||||||
|
"show_img_vis": false,
|
||||||
|
"use_tensorrt": false,
|
||||||
|
"table_max_len": 488,
|
||||||
|
"merge_no_span_structure": true,
|
||||||
|
"table_batch_num": 1
|
||||||
|
}
|
||||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
|
@ -0,0 +1,5 @@
|
||||||
|
text
|
||||||
|
title
|
||||||
|
list
|
||||||
|
table
|
||||||
|
figure
|
||||||
File diff suppressed because it is too large
Load Diff
|
|
@ -0,0 +1,48 @@
|
||||||
|
<thead>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
</tbody>
|
||||||
|
<tr>
|
||||||
|
</tr>
|
||||||
|
<td>
|
||||||
|
<td
|
||||||
|
>
|
||||||
|
</td>
|
||||||
|
colspan="2"
|
||||||
|
colspan="3"
|
||||||
|
colspan="4"
|
||||||
|
colspan="5"
|
||||||
|
colspan="6"
|
||||||
|
colspan="7"
|
||||||
|
colspan="8"
|
||||||
|
colspan="9"
|
||||||
|
colspan="10"
|
||||||
|
colspan="11"
|
||||||
|
colspan="12"
|
||||||
|
colspan="13"
|
||||||
|
colspan="14"
|
||||||
|
colspan="15"
|
||||||
|
colspan="16"
|
||||||
|
colspan="17"
|
||||||
|
colspan="18"
|
||||||
|
colspan="19"
|
||||||
|
colspan="20"
|
||||||
|
rowspan="2"
|
||||||
|
rowspan="3"
|
||||||
|
rowspan="4"
|
||||||
|
rowspan="5"
|
||||||
|
rowspan="6"
|
||||||
|
rowspan="7"
|
||||||
|
rowspan="8"
|
||||||
|
rowspan="9"
|
||||||
|
rowspan="10"
|
||||||
|
rowspan="11"
|
||||||
|
rowspan="12"
|
||||||
|
rowspan="13"
|
||||||
|
rowspan="14"
|
||||||
|
rowspan="15"
|
||||||
|
rowspan="16"
|
||||||
|
rowspan="17"
|
||||||
|
rowspan="18"
|
||||||
|
rowspan="19"
|
||||||
|
rowspan="20"
|
||||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
87
js/index.js
87
js/index.js
|
|
@ -309,6 +309,33 @@ function SetBiaoZhunDian(obj) {
|
||||||
$("#keguan_" + zhuguan_tihao).resizable({ containment: ".main_papermain", handles: 'all' });
|
$("#keguan_" + zhuguan_tihao).resizable({ containment: ".main_papermain", handles: 'all' });
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/////////////////锚定点//////////////////////
|
||||||
|
function SetMaoDingDian(obj) {
|
||||||
|
var zhuguan_tihao = "锚定点";
|
||||||
|
|
||||||
|
if ($(obj).attr("class") == "maodingdian_hover") {
|
||||||
|
$(obj).attr("class", "maodingdian");
|
||||||
|
DeleteKeguanti(zhuguan_tihao);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$(obj).attr("class", "maodingdian_hover");
|
||||||
|
}
|
||||||
|
if (document.getElementById("keguan_" + zhuguan_tihao) != undefined) {
|
||||||
|
alert("锚定点已标记");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
var ocrText = prompt("请输入学科:");
|
||||||
|
if (ocrText == '' || ocrText == null) {
|
||||||
|
alert("请输入学科");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
$(".main_papermain").append("<div id=\"keguan_" + zhuguan_tihao + "\" class='main_tabletop maodingdian_select' wenzimiaoshu='" + zhuguan_tihao + "' style='width:80px;background:none; left:100px; top:200px; height:30px'><div style=\" float:left; width:auto; text-align:center; height:30px; position:absolute; margin-top:-30px;z-index:22; color:#fff; line-height:30px; background:#666;\">" + zhuguan_tihao + "</div><div style='width:100%;height:100%;background:#fff;border:1px solid red;' id='maodingdian'>" + ocrText +"</div></div>");
|
||||||
|
$("#keguan_" + zhuguan_tihao).draggable({ containment: ".main_papermain" });
|
||||||
|
$("#keguan_" + zhuguan_tihao).resizable({ containment: ".main_papermain", handles: 'all' });
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -405,7 +432,11 @@ function GetMaoPostion() {
|
||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
|
|
||||||
return xy.trim('^');;
|
//if (xy.endsWith('^')) {
|
||||||
|
// xy = xy.slice(0, -1);
|
||||||
|
//}
|
||||||
|
|
||||||
|
return xy.trim('^');
|
||||||
}
|
}
|
||||||
|
|
||||||
//获取学号数据
|
//获取学号数据
|
||||||
|
|
@ -436,7 +467,7 @@ function GetZhuguanPostion() {
|
||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
$(".zhuguanti").each(function () {
|
$(".zhuguanti").each(function () {
|
||||||
xy += parseFloat($(this).position().left) + "," + parseFloat($(this).position().top) + "," + parseFloat($(this).width()) + "," + parseFloat($(this).height()) + "," + $(this).attr("tihaovalue") + "," + $(this).attr("zhuguan_xiaoti") + "," + $(this).attr("score") + "," + $(this).attr("scoretype") + "," + $(this).attr("questiontype_zg") + "^";
|
xy += parseFloat($(this).position().left) + "," + parseFloat($(this).position().top) + "," + parseFloat($(this).width()) + "," + parseFloat($(this).height()) + "," + $(this).attr("tihaovalue") + "," + $(this).attr("zhuguan_xiaoti") + "," + $(this).attr("score") + "," + $(this).attr("scoretype") + "," + "主观题" + "^";
|
||||||
})
|
})
|
||||||
return xy.trim('^');
|
return xy.trim('^');
|
||||||
}
|
}
|
||||||
|
|
@ -483,6 +514,21 @@ function GetBiaoZhunDianPostion() {
|
||||||
return xy.trim('^');
|
return xy.trim('^');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//获取锚定点
|
||||||
|
function GetMaoDingDianPostion() {
|
||||||
|
var xy = "";
|
||||||
|
if ($(".maodingdian_select").length == 0) {
|
||||||
|
return "";
|
||||||
|
}
|
||||||
|
|
||||||
|
$(".maodingdian_select").each(function () {
|
||||||
|
var text = $("#maodingdian").text();
|
||||||
|
|
||||||
|
xy += parseFloat($(this).position().left) + "," + parseFloat($(this).position().top) + "," + parseFloat($(this).width()) + "," + parseFloat($(this).height()) + "," + $(this).attr("wenzimiaoshu") + "," + text + "^";
|
||||||
|
})
|
||||||
|
return xy.trim('^');
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
//获取屏蔽区数据
|
//获取屏蔽区数据
|
||||||
function GetHideAreaPostion() {
|
function GetHideAreaPostion() {
|
||||||
|
|
@ -538,7 +584,7 @@ function GetDataTotal(objvalue, tenant) {
|
||||||
var hideArea = GetHideAreaPostion();//获取屏蔽区数据
|
var hideArea = GetHideAreaPostion();//获取屏蔽区数据
|
||||||
var pytiArea = GetPyAreaPostion();//获取批阅条件
|
var pytiArea = GetPyAreaPostion();//获取批阅条件
|
||||||
var biaoZhunDian = GetBiaoZhunDianPostion();//设置标准点
|
var biaoZhunDian = GetBiaoZhunDianPostion();//设置标准点
|
||||||
|
var maoDingDian = GetMaoDingDianPostion();//设置锚定点
|
||||||
|
|
||||||
var selectPageSize = $("#selectPageSize").val();
|
var selectPageSize = $("#selectPageSize").val();
|
||||||
if (selectPageSize == null) {
|
if (selectPageSize == null) {
|
||||||
|
|
@ -552,6 +598,11 @@ function GetDataTotal(objvalue, tenant) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (document.getElementById("keguan_锚定点") == undefined && $("#PageIndex").val() == "1") {
|
||||||
|
alert("您尚未设置锚定点,无法保存数据");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (document.getElementById("keguan_缺考") == undefined && $("#PageIndex").val() == "1") {
|
if (document.getElementById("keguan_缺考") == undefined && $("#PageIndex").val() == "1") {
|
||||||
if (confirm("您尚未设置缺考标记,无需设置点击取消按钮")) {
|
if (confirm("您尚未设置缺考标记,无需设置点击取消按钮")) {
|
||||||
return;
|
return;
|
||||||
|
|
@ -562,7 +613,7 @@ function GetDataTotal(objvalue, tenant) {
|
||||||
var PageIndex = $("#PageIndex").val();
|
var PageIndex = $("#PageIndex").val();
|
||||||
var MainTempId = $("#MainTempId").val();
|
var MainTempId = $("#MainTempId").val();
|
||||||
var WandH = parseFloat($("#SelectImg").width()) + "," + parseFloat($("#SelectImg").height());
|
var WandH = parseFloat($("#SelectImg").width()) + "," + parseFloat($("#SelectImg").height());
|
||||||
var totalHtml = maodian + "$" + xuehao + "$" + keguanti + "$" + zhuguanti + "$" + wenzimiaoshu + "$" + tiaoma + "$" + WandH + "$" + zhunkaozhenghao + "$" + pytiArea + "$" + biaoZhunDian;
|
var totalHtml = maodian + "$" + xuehao + "$" + keguanti + "$" + zhuguanti + "$" + wenzimiaoshu + "$" + tiaoma + "$" + WandH + "$" + zhunkaozhenghao + "$" + pytiArea + "$" + biaoZhunDian + "$" + maoDingDian;
|
||||||
if (maodian == "") {
|
if (maodian == "") {
|
||||||
//alert("必须设置4个锚点");
|
//alert("必须设置4个锚点");
|
||||||
//return;
|
//return;
|
||||||
|
|
@ -598,7 +649,7 @@ function GetDataTotal(objvalue, tenant) {
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|
||||||
alert(res + "或更新失败,定位点错误");
|
alert(res + " 更新失败");
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
@ -643,6 +694,9 @@ function BaseDataBind() {
|
||||||
if (list[9] != undefined) {
|
if (list[9] != undefined) {
|
||||||
biaozhundian = list[9].toString().trim('^');
|
biaozhundian = list[9].toString().trim('^');
|
||||||
}
|
}
|
||||||
|
if (list[10] != undefined) {
|
||||||
|
maodingdian = list[10].toString().trim('^');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pageWidth == 1200 || pageWidth == 1199 || pageWidth == 1198 || pageWidth == 1201) {
|
if (pageWidth == 1200 || pageWidth == 1199 || pageWidth == 1198 || pageWidth == 1201) {
|
||||||
|
|
@ -687,6 +741,7 @@ function BaseDataBind() {
|
||||||
SetPyPostion(piyueList);
|
SetPyPostion(piyueList);
|
||||||
GetZhuguantiScoreList();
|
GetZhuguantiScoreList();
|
||||||
SetBiaoZhunDianPostion(biaozhundian);
|
SetBiaoZhunDianPostion(biaozhundian);
|
||||||
|
SetMaoDingDianPostion(maodingdian);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -994,7 +1049,27 @@ function SetBiaoZhunDianPostion(PostionData) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
////////////////设置文字区域//////////////////////
|
|
||||||
|
////////////////设置锚定点区域//////////////////////
|
||||||
|
function SetMaoDingDianPostion(PostionData) {
|
||||||
|
if (PostionData == "" || PostionData == undefined) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
//左边距,右边距,长,高,题号,小题数量
|
||||||
|
var listdata = PostionData.split('^');
|
||||||
|
for (var i = 0; i < listdata.length; i++) {
|
||||||
|
var zhuguanList = listdata[i].split(',');
|
||||||
|
var zhuguan_tihao = zhuguanList[4];
|
||||||
|
if (document.getElementById("keguan_锚定点") != undefined) {
|
||||||
|
alert("锚定点配置重复");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
$(".main_papermain").append("<div id=\"keguan_锚定点\" class='main_tabletop maodingdian_select' wenzimiaoshu='" + zhuguan_tihao + "' style='left:" + zhuguanList[0] + "px; top:" + zhuguanList[1] + "px;width:" + zhuguanList[2] + "px;height:" + zhuguanList[3] + "px; background:none; '><div style=\" float:left; width:auto; text-align:center; height:30px; position:absolute; margin-top:-30px;z-index:22; color:#fff; line-height:30px; background:#666;\">" + zhuguan_tihao + "</div><div style='width:100%;height:100%;background:#fff;border:1px solid red;' id='maodingdian'>" + zhuguanList[5] +"</div></div>");
|
||||||
|
$("#keguan_" + zhuguan_tihao).draggable({ containment: ".main_papermain" });
|
||||||
|
$("#keguan_" + zhuguan_tihao).resizable({ containment: ".main_papermain", handles: 'all' });
|
||||||
|
$(".maodingdian").attr("class", "maodingdian_hover");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,5 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<packages>
|
||||||
|
<package id="Newtonsoft.Json" version="12.0.1" targetFramework="net48" />
|
||||||
|
<package id="PaddleOCRSharp" version="4.0.1" targetFramework="net48" />
|
||||||
|
</packages>
|
||||||
Loading…
Reference in New Issue