delete qsv

This commit is contained in:
2025-11-05 13:47:25 +08:00
parent 5ce98df631
commit 649d44f001

View File

@@ -84,7 +84,7 @@ namespace TetraPackOCR
/// <summary>
/// 共印依据 QSV Design, Layers, Colours,产品规格
/// </summary>
string QSV, ProductStandard;
string ProductStandard;
/// <summary>
/// 幅数 包材宽 梯度 X距离 Y距离
/// </summary>
@@ -686,16 +686,17 @@ namespace TetraPackOCR
sheet1 = package.Workbook.Worksheets["P2生成数据"];
sheet2 = package.Workbook.Worksheets["QSV对应产品规格和梯度"];
sheet3 = package.Workbook.Worksheets["产品规格对应排布方式"];
//根据订单遍历sheet1 找Sequence QSV NumOFLanes 字符
//根据订单遍历sheet1 找Sequence QSV NumOFLanes 字符
string currentQSV = "";
for (int i = 1; i < sheet1.Dimension.Rows; i++)
{
if (sheet1.GetValue(i, 3) != null)
{
if (sheet1.Cells[i, 3].Value.ToString() == order)
{
QSV = sheet1.Cells[i, 4].Value.ToString();
lbl_QSVShow.Text = QSV;
log.Info("当前订单QSV:" + QSV);
currentQSV = sheet1.Cells[i, 4].Value.ToString();
lbl_QSVShow.Text = currentQSV;
log.Info("当前订单QSV:" + currentQSV);
NumberOfLanes = Convert.ToInt32(sheet1.Cells[i, 5].Value.ToString());
log.Info("当前订单Number Of Lanes:" + NumberOfLanes);
lbl_NOFShow.Text = sheet1.Cells[i, 5].Value.ToString();
@@ -726,14 +727,14 @@ namespace TetraPackOCR
}
}
if (!string.IsNullOrEmpty(QSV))
if (!string.IsNullOrEmpty(currentQSV))
{
string qsv;
//根据得到的QSV遍历sheet2 找产品规格和宽度梯度
for (int j = 1; j <= sheet2.Dimension.Rows; j++)
{
qsv = sheet2.Cells[j, 1].Value.ToString();
if (qsv == QSV)
if (qsv == currentQSV)
{
ProductStandard = sheet2.Cells[j, 2].Value.ToString();
lbl_ProductStandardShow.Text = ProductStandard;
@@ -1023,7 +1024,7 @@ namespace TetraPackOCR
/// </summary>
void ClearData()
{
QSV = null; ProductStandard = null;
ProductStandard = null;
NumberOfLanes = 0; width = 0; Gradient = 0; DistX = 0; DistY = 0;
}
/// <summary>
@@ -2024,7 +2025,6 @@ namespace TetraPackOCR
log.Info("当前订单OCR区域共" + nol + "组:");
for (int item = 0; item < nol; item++)
{
if (item == 0)
{
ocrx = xx - ((float)DistX) * ((float)Math.Cos((rr * Math.PI) / 180)) - ((float)DistY) * ((float)Math.Sin((rr * Math.PI) / 180));
@@ -2042,7 +2042,6 @@ namespace TetraPackOCR
l.Add(ocry);
ocrxx.Add(ocrx);
ocryy.Add(ocry);
}
log.Info("第" + (item + 1) + "组坐标为X" + ocrxx[item] + ",Y:" + ocryy[item] + "。");