|
|
@ -111,13 +111,33 @@ namespace SCP.PlanData |
|
|
|
|
|
|
|
protected void btnOutput_Click(object sender, EventArgs e) |
|
|
|
{ |
|
|
|
int[] _selections = Grid_V_TB_PO.SelectedRowIndexArray; |
|
|
|
if (_selections.Count() == 0) |
|
|
|
{ |
|
|
|
Alert.Show("请选择订单记录导出!"); |
|
|
|
} |
|
|
|
List<string> _ls = new List<string>(); |
|
|
|
for (int i = 0, count = Grid_V_TB_PO.Rows.Count; i < count; i++) |
|
|
|
{ |
|
|
|
object[] rowDataKeys = Grid_V_TB_PO.DataKeys[i]; |
|
|
|
_ls.Add(rowDataKeys[1] as string); |
|
|
|
if (_selections.Contains(i)) |
|
|
|
{ |
|
|
|
|
|
|
|
object[] rowDataKeys = Grid_V_TB_PO.DataKeys[i]; |
|
|
|
_ls.Add(rowDataKeys[1] as string); |
|
|
|
} |
|
|
|
} |
|
|
|
if (_ls.Count == 0) |
|
|
|
{ |
|
|
|
Alert.Show("请选择记录导出!"); |
|
|
|
return; |
|
|
|
} |
|
|
|
DataSet ds=SCP_EXCEL_CONTROLLER.GET_PO_EXECEL(_ls); |
|
|
|
//List<string> _ls = new List<string>();
|
|
|
|
//for (int i = 0, count = Grid_V_TB_PO.Rows.Count; i < count; i++)
|
|
|
|
//{
|
|
|
|
// object[] rowDataKeys = Grid_V_TB_PO.DataKeys[i];
|
|
|
|
// _ls.Add(rowDataKeys[1] as string);
|
|
|
|
//}
|
|
|
|
DataSet ds =SCP_EXCEL_CONTROLLER.GET_PO_EXECEL(_ls); |
|
|
|
PageBase.DataSetToExcel(ds, "采购订单"); |
|
|
|
|
|
|
|
} |
|
|
|