|
|
@@ -378,7 +378,6 @@ namespace UAS_LabelMachine
|
|
|
//芯片号需要作为更新盒号的条件
|
|
|
HSSFFont ffont = (HSSFFont)book.CreateFont();
|
|
|
ffont.FontName = "宋体";
|
|
|
- bool ShowChcode = true;
|
|
|
//更新箱号
|
|
|
List<string> pib_id = new List<string>();
|
|
|
//系统打印箱号
|
|
|
@@ -414,6 +413,7 @@ namespace UAS_LabelMachine
|
|
|
NotShowColumn.Add("pib_id");
|
|
|
NotShowColumn.Add("chw_itemname1");
|
|
|
NotShowColumn.Add("chw_itemname2");
|
|
|
+ NotShowColumn.Add("chw_itemname3");
|
|
|
NotShowColumn.Add("pd_ordercode");
|
|
|
NotShowColumn.Add("pr_size");
|
|
|
NotShowColumn.Add("me_desc");
|
|
|
@@ -442,7 +442,7 @@ namespace UAS_LabelMachine
|
|
|
{
|
|
|
if (DataTable.Columns[i].ColumnName.ToLower().Contains("ch_code"))
|
|
|
{
|
|
|
- ShowChcode = true;
|
|
|
+ DataTable.Columns.RemoveAt(i);
|
|
|
break;
|
|
|
}
|
|
|
}
|
|
|
@@ -646,8 +646,14 @@ namespace UAS_LabelMachine
|
|
|
row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname2"].ToString());
|
|
|
}
|
|
|
- else if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ else if (DataTable.Columns[j].ColumnName.ToLower() == "chw_percent3")
|
|
|
+ {
|
|
|
+ showcount = showcount + 1;
|
|
|
+ row1.CreateCell(j - 4);
|
|
|
+ row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
+ row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname3"].ToString());
|
|
|
+ }
|
|
|
+ else if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -677,8 +683,7 @@ namespace UAS_LabelMachine
|
|
|
{
|
|
|
string Data = DataTable.Rows[i][j].ToString();
|
|
|
row1.CreateCell(j - 4);
|
|
|
- if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -755,7 +760,7 @@ namespace UAS_LabelMachine
|
|
|
else if (j == ShowRemarkPiece)
|
|
|
{
|
|
|
row1.CreateCell(j);
|
|
|
- row1.Cells[j].SetCellValue(rowNum + 片);
|
|
|
+ row1.Cells[j].SetCellValue(rowNum + "片");
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
@@ -885,8 +890,14 @@ namespace UAS_LabelMachine
|
|
|
row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname2"].ToString());
|
|
|
}
|
|
|
- else if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ else if (DataTable.Columns[j].ColumnName.ToLower() == "chw_percent3")
|
|
|
+ {
|
|
|
+ showcount = showcount + 1;
|
|
|
+ row1.CreateCell(j - 4);
|
|
|
+ row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
+ row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname3"].ToString());
|
|
|
+ }
|
|
|
+ else if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -916,8 +927,7 @@ namespace UAS_LabelMachine
|
|
|
{
|
|
|
string Data = DataTable.Rows[i][j].ToString();
|
|
|
row1.CreateCell(j - 4);
|
|
|
- if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -985,7 +995,7 @@ namespace UAS_LabelMachine
|
|
|
else if (j == ShowRemarkPiece)
|
|
|
{
|
|
|
row1.CreateCell(j);
|
|
|
- row1.Cells[j].SetCellValue(rowNum + 片);
|
|
|
+ row1.Cells[j].SetCellValue(rowNum + "片");
|
|
|
}
|
|
|
else if (j == 4)
|
|
|
{
|
|
|
@@ -1122,8 +1132,14 @@ namespace UAS_LabelMachine
|
|
|
row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname2"].ToString());
|
|
|
}
|
|
|
- else if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ else if (DataTable.Columns[j].ColumnName.ToLower() == "chw_percent3")
|
|
|
+ {
|
|
|
+ showcount = showcount + 1;
|
|
|
+ row1.CreateCell(j - 4);
|
|
|
+ row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
+ row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname3"].ToString());
|
|
|
+ }
|
|
|
+ else if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -1153,8 +1169,7 @@ namespace UAS_LabelMachine
|
|
|
{
|
|
|
string Data = DataTable.Rows[i][j].ToString();
|
|
|
row1.CreateCell(j - 4);
|
|
|
- if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -1223,7 +1238,7 @@ namespace UAS_LabelMachine
|
|
|
else if (j == ShowRemarkPiece)
|
|
|
{
|
|
|
row1.CreateCell(j);
|
|
|
- row1.Cells[j].SetCellValue(rowNum + 片);
|
|
|
+ row1.Cells[j].SetCellValue(rowNum + "片");
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
@@ -1377,6 +1392,7 @@ namespace UAS_LabelMachine
|
|
|
if (FirstDT.Columns[j].ColumnName == "io_qty")
|
|
|
{
|
|
|
totalCount += int.Parse(Data);
|
|
|
+ row1.Cells[j - 4].SetCellValue(int.Parse(Data));
|
|
|
}
|
|
|
}
|
|
|
//添加总计行
|
|
|
@@ -1469,7 +1485,6 @@ namespace UAS_LabelMachine
|
|
|
//芯片号需要作为更新盒号的条件
|
|
|
HSSFFont ffont = (HSSFFont)book.CreateFont();
|
|
|
ffont.FontName = "宋体";
|
|
|
- bool ShowChcode = true;
|
|
|
//更新箱号
|
|
|
List<string> pib_id = new List<string>();
|
|
|
//系统打印箱号
|
|
|
@@ -1495,6 +1510,7 @@ namespace UAS_LabelMachine
|
|
|
NotShowColumn.Add("pib_id");
|
|
|
NotShowColumn.Add("chw_itemname1");
|
|
|
NotShowColumn.Add("chw_itemname2");
|
|
|
+ NotShowColumn.Add("chw_itemname3");
|
|
|
NotShowColumn.Add("pd_ordercode");
|
|
|
NotShowColumn.Add("pr_size");
|
|
|
NotShowColumn.Add("me_desc");
|
|
|
@@ -1521,7 +1537,7 @@ namespace UAS_LabelMachine
|
|
|
{
|
|
|
if (DataTable.Columns[i].ColumnName.ToLower().Contains("ch_code"))
|
|
|
{
|
|
|
- ShowChcode = true;
|
|
|
+ DataTable.Columns.RemoveAt(i);
|
|
|
break;
|
|
|
}
|
|
|
}
|
|
|
@@ -1762,8 +1778,14 @@ namespace UAS_LabelMachine
|
|
|
row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname2"].ToString());
|
|
|
}
|
|
|
- else if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ else if (DataTable.Columns[j].ColumnName.ToLower() == "chw_percent3")
|
|
|
+ {
|
|
|
+ showcount = showcount + 1;
|
|
|
+ row1.CreateCell(j - 4);
|
|
|
+ row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
+ row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname3"].ToString());
|
|
|
+ }
|
|
|
+ else if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -1793,8 +1815,7 @@ namespace UAS_LabelMachine
|
|
|
{
|
|
|
string Data = DataTable.Rows[i][j].ToString();
|
|
|
row1.CreateCell(j - 4);
|
|
|
- if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -2021,8 +2042,14 @@ namespace UAS_LabelMachine
|
|
|
row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname2"].ToString());
|
|
|
}
|
|
|
- else if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ else if (DataTable.Columns[j].ColumnName.ToLower() == "chw_percent3")
|
|
|
+ {
|
|
|
+ showcount = showcount + 1;
|
|
|
+ row1.CreateCell(j - 4);
|
|
|
+ row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
+ row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname3"].ToString());
|
|
|
+ }
|
|
|
+ else if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -2052,8 +2079,7 @@ namespace UAS_LabelMachine
|
|
|
{
|
|
|
string Data = DataTable.Rows[i][j].ToString();
|
|
|
row1.CreateCell(j - 4);
|
|
|
- if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -2276,8 +2302,14 @@ namespace UAS_LabelMachine
|
|
|
row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname2"].ToString());
|
|
|
}
|
|
|
- else if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ else if (DataTable.Columns[j].ColumnName.ToLower() == "chw_percent3")
|
|
|
+ {
|
|
|
+ showcount = showcount + 1;
|
|
|
+ row1.CreateCell(j - 4);
|
|
|
+ row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
+ row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname3"].ToString());
|
|
|
+ }
|
|
|
+ else if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -2307,8 +2339,7 @@ namespace UAS_LabelMachine
|
|
|
{
|
|
|
string Data = DataTable.Rows[i][j].ToString();
|
|
|
row1.CreateCell(j - 4);
|
|
|
- if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -2531,6 +2562,7 @@ namespace UAS_LabelMachine
|
|
|
if (FirstDT.Columns[j].ColumnName == "io_qty")
|
|
|
{
|
|
|
totalCount += int.Parse(Data);
|
|
|
+ row1.Cells[j - 4].SetCellValue(int.Parse(Data));
|
|
|
}
|
|
|
}
|
|
|
//添加总计行
|
|
|
@@ -2622,7 +2654,6 @@ namespace UAS_LabelMachine
|
|
|
//芯片号需要作为更新盒号的条件
|
|
|
HSSFFont ffont = (HSSFFont)book.CreateFont();
|
|
|
ffont.FontName = "宋体";
|
|
|
- bool ShowChcode = true;
|
|
|
//更新箱号
|
|
|
List<string> pib_id = new List<string>();
|
|
|
//系统打印箱号
|
|
|
@@ -2658,6 +2689,7 @@ namespace UAS_LabelMachine
|
|
|
NotShowColumn.Add("pib_id");
|
|
|
NotShowColumn.Add("chw_itemname1");
|
|
|
NotShowColumn.Add("chw_itemname2");
|
|
|
+ NotShowColumn.Add("chw_itemname3");
|
|
|
NotShowColumn.Add("pd_ordercode");
|
|
|
NotShowColumn.Add("pr_size");
|
|
|
NotShowColumn.Add("me_desc");
|
|
|
@@ -2686,7 +2718,7 @@ namespace UAS_LabelMachine
|
|
|
{
|
|
|
if (DataTable.Columns[i].ColumnName.ToLower().Contains("ch_code"))
|
|
|
{
|
|
|
- ShowChcode = true;
|
|
|
+ DataTable.Columns.RemoveAt(i);
|
|
|
break;
|
|
|
}
|
|
|
}
|
|
|
@@ -2917,8 +2949,14 @@ namespace UAS_LabelMachine
|
|
|
row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname2"].ToString());
|
|
|
}
|
|
|
- else if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ else if (DataTable.Columns[j].ColumnName.ToLower() == "chw_percent3")
|
|
|
+ {
|
|
|
+ showcount = showcount + 1;
|
|
|
+ row1.CreateCell(j - 4);
|
|
|
+ row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
+ row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname3"].ToString());
|
|
|
+ }
|
|
|
+ else if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -2929,7 +2967,6 @@ namespace UAS_LabelMachine
|
|
|
row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
row1.Cells[j - 4].SetCellValue(DataTable.Columns[j].Caption);
|
|
|
}
|
|
|
-
|
|
|
if (DataTable.Columns[j].ColumnName.ToString() == "io_qty")
|
|
|
{
|
|
|
NumIndex = j;
|
|
|
@@ -2949,8 +2986,7 @@ namespace UAS_LabelMachine
|
|
|
{
|
|
|
string Data = DataTable.Rows[i][j].ToString();
|
|
|
row1.CreateCell(j - 4);
|
|
|
- if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -3209,8 +3245,14 @@ namespace UAS_LabelMachine
|
|
|
row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname2"].ToString());
|
|
|
}
|
|
|
- else if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ else if (DataTable.Columns[j].ColumnName.ToLower() == "chw_percent3")
|
|
|
+ {
|
|
|
+ showcount = showcount + 1;
|
|
|
+ row1.CreateCell(j - 4);
|
|
|
+ row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
+ row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname3"].ToString());
|
|
|
+ }
|
|
|
+ else if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -3240,8 +3282,7 @@ namespace UAS_LabelMachine
|
|
|
{
|
|
|
string Data = DataTable.Rows[i][j].ToString();
|
|
|
row1.CreateCell(j - 4);
|
|
|
- if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -3497,8 +3538,14 @@ namespace UAS_LabelMachine
|
|
|
row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname2"].ToString());
|
|
|
}
|
|
|
- else if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ else if (DataTable.Columns[j].ColumnName.ToLower() == "chw_percent3")
|
|
|
+ {
|
|
|
+ showcount = showcount + 1;
|
|
|
+ row1.CreateCell(j - 4);
|
|
|
+ row1.Cells[j - 4].CellStyle = ColumnTitleStyle;
|
|
|
+ row1.Cells[j - 4].SetCellValue(DataTable.Rows[i]["chw_itemname3"].ToString());
|
|
|
+ }
|
|
|
+ else if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -3528,8 +3575,7 @@ namespace UAS_LabelMachine
|
|
|
{
|
|
|
string Data = DataTable.Rows[i][j].ToString();
|
|
|
row1.CreateCell(j - 4);
|
|
|
- if ((DataTable.Rows[i]["chw_itemname1"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent1") ||
|
|
|
- (DataTable.Rows[i]["chw_itemname2"].ToString() == "" && DataTable.Columns[j].ColumnName.ToLower() == "chw_percent2") || (NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())) || (!ShowChcode && DataTable.Columns[j].ColumnName.ToLower().Contains("ch_code")))
|
|
|
+ if ((NotShowColumn.Contains(DataTable.Columns[j].ColumnName.ToLower())))
|
|
|
{
|
|
|
|
|
|
}
|
|
|
@@ -3776,6 +3822,7 @@ namespace UAS_LabelMachine
|
|
|
if (FirstDT.Columns[j].ColumnName == "io_qty")
|
|
|
{
|
|
|
totalCount += int.Parse(Data);
|
|
|
+ row1.Cells[j - 4].SetCellValue(int.Parse(Data));
|
|
|
}
|
|
|
}
|
|
|
//添加总计行
|