| | |
| | | { |
| | | setSrm(); |
| | | }; |
| | | |
| | | #region 2025-10-10 向下复制beg |
| | | btnDown.Click += (s, e) => |
| | | { |
| | | // 获取当前选中行的行号 |
| | | int focusedRowHandle = gvMx1.FocusedRowHandle; |
| | | if (focusedRowHandle < 0) return; |
| | | |
| | | // 获取当前行的时长 |
| | | DataRow currentRow = gvMx1.GetDataRow(focusedRowHandle); |
| | | if (currentRow == null) return; |
| | | var hourValue = currentRow["depotId"]; |
| | | var hourValue2 = currentRow["depotName"]; |
| | | if (hourValue == null || string.IsNullOrEmpty(hourValue.ToString())) |
| | | { |
| | | MsgHelper.ShowError("当前选中的行无仓库,复制失败!"); |
| | | return; |
| | | } |
| | | if (hourValue2 == null) |
| | | { |
| | | MsgHelper.ShowError("当前选中的行无仓库,复制失败!"); |
| | | return; |
| | | } |
| | | // 批量设置下面所有行的时长 |
| | | for (int i = focusedRowHandle + 1; i < gvMx1.DataRowCount; i++) |
| | | { |
| | | var row = gvMx1.GetDataRow(i); |
| | | if (row != null) |
| | | { |
| | | row["depotId"] = hourValue; |
| | | row["depotName"] = hourValue2; |
| | | } |
| | | } |
| | | gvMx1.RefreshData(); |
| | | }; |
| | | #endregion |
| | | } |
| | | |
| | | |
| | | |
| | | private async void GridView1_ColumnFilterChanged(object sender, EventArgs e) |
| | | { |
| | | _filterList = Gs.DevApp.ToolBox.UtilityHelper.GetDilter(gridView1.Columns, gridView1); |