| | |
| | | using System.Net; |
| | | using System.Text; |
| | | using System.Windows.Forms; |
| | | using DevExpress.Utils.Text.Internal; |
| | | using DevExpress.XtraBars; |
| | | using DevExpress.XtraEditors; |
| | | using DevExpress.XtraGrid; |
| | | using DevExpress.XtraGrid.Columns; |
| | | using DevExpress.XtraGrid.Views.Grid; |
| | | using DevExpress.XtraLayout; |
| | | using Gs.DevApp.DevFrm.Rpt; |
| | |
| | | var dd = UtilityHelper.ReturnToList(strReturn); |
| | | var dt = dd.rtnData; |
| | | |
| | | if (!string.IsNullOrEmpty(defaultActions) && defaultActions.Contains("查询")) { |
| | | if (!string.IsNullOrEmpty(defaultActions) && defaultActions.Contains("查询")) |
| | | { |
| | | if (dt == null || dt.Rows.Count <= 0) |
| | | { |
| | | dt.Columns.Add("guid", typeof(string)); |
| | |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 读取xml配置,目前配置gcMain1,layoutMx1 |
| | | /// 读取xml配置,目前配置gcMain1,layoutMx1,加查询条件 |
| | | /// </summary> |
| | | public void getXmlConfig() |
| | | { |
| | |
| | | |
| | | } |
| | | } |
| | | //设置查询条件beg |
| | | GridControl gcMain = parentForm.Controls.Find("gcMain1", true).OfType<GridControl>().FirstOrDefault(); |
| | | if (gcMain != null) |
| | | { |
| | | GridView gv1 = gcMain.MainView as GridView; |
| | | if (gv1 != null) |
| | | { |
| | | foreach (var a in _job["rtnData"]["list2"]) |
| | | { |
| | | string _gvColName = a["gvColName"].ToString(); |
| | | string _sqlField = a["sqlField"].ToString(); |
| | | var column = gv1.Columns.Cast<DevExpress.XtraGrid.Columns.GridColumn>() |
| | | .FirstOrDefault(c => c.Name == _gvColName); |
| | | if (column != null) |
| | | { |
| | | column.Tag = _sqlField; |
| | | } |
| | | } |
| | | } |
| | | } |
| | | //设置查询条件end |
| | | } |
| | | else |
| | | ToolBox.MsgHelper.Warning("提示:" + _rtn.rtnMsg); |