| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091 |
- using System;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.Data;
- using System.Drawing;
- using System.Linq;
- using System.Text;
- using System.Windows.Forms;
- using CoreFS.CA06;
- using Core.Mes.Client.Comm.Tool;
- using Infragistics.Win.UltraWinGrid;
- using Core.Mes.Client.Comm.Format;
- using System.Collections;
- using Core.Mes.Client.Comm.Server;
- namespace Core.StlMes.Client.SaleOrder
- {
- public partial class frmDesignLength : FrmBase
- {
- /// <summary>
- /// 合同行号
- /// </summary>
- private String designKey;
- public String DesignKey
- {
- get { return designKey; }
- set { designKey = value; }
- }
- private OpeBase ob;
- public OpeBase Ob
- {
- get { return ob; }
- set { ob = value; }
- }
- public frmDesignLength(string designKey, OpeBase ob)
- {
- this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
- InitializeComponent();
- this.designKey = designKey;
- this.ob = ob;
- }
- private void frmDesignLength_Load(object sender, EventArgs e)
- {
- EntityHelper.ShowGridCaption<SlmOrdDesignLengthEntity>(ultraGrid1.DisplayLayout.Bands[0]);
- DoQuery();
- setColumnReadOnly(ultraGrid1);
- }
- private void DoQuery()
- {
- ///ordLnPk = "EFD0A935A9C94724BA60F7AA7C580619001";
- List<SlmOrdDesignLengthEntity> listSource = EntityHelper.GetData<SlmOrdDesignLengthEntity>(
- "com.steering.pss.sale.order.CoreDesignLength.getDesingLenth", new object[] { designKey }, ob);
- slmOrdDesignLengthEntityBindingSource.DataSource = listSource;
- }
- /// <summary>
- /// 设置列只可读
- /// </summary>
- /// <param name="ugr">UltraGrid</param>
- /// <param name="columns">列数组</param>
- private void setColumnReadOnly(UltraGrid ugr)
- {
- foreach (UltraGridColumn ugc in ugr.DisplayLayout.Bands[0].Columns)
- {
- if (!ugc.Key.Equals("CHC"))
- {
- ugc.CellActivation = Activation.ActivateOnly;
- }
- }
- }
- private void buttonCommit_Click(object sender, EventArgs e)
- {
- this.DialogResult = DialogResult.OK;
- }
- private void buttonCancel_Click(object sender, EventArgs e)
- {
- this.DialogResult = DialogResult.Cancel;
- }
-
- }
- }
|