SVN r935
SVN-Revision: r935
This commit is contained in:
@@ -30,6 +30,7 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.panelControl2 = new DevExpress.XtraEditors.PanelControl();
|
||||
this.btnInsert = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.but_delete = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.but_increase = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.simpleButton1 = new DevExpress.XtraEditors.SimpleButton();
|
||||
@@ -54,7 +55,6 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.pllzbzsz = new System.Windows.Forms.Panel();
|
||||
this.PlAdd = new System.Windows.Forms.Panel();
|
||||
this.btnInsert = new DevExpress.XtraEditors.SimpleButton();
|
||||
((System.ComponentModel.ISupportInitialize)(this.panelControl2)).BeginInit();
|
||||
this.panelControl2.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.panelControl3)).BeginInit();
|
||||
@@ -83,6 +83,18 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
this.panelControl2.Size = new System.Drawing.Size(1050, 40);
|
||||
this.panelControl2.TabIndex = 3;
|
||||
//
|
||||
// btnInsert
|
||||
//
|
||||
this.btnInsert.Appearance.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.btnInsert.Appearance.Options.UseFont = true;
|
||||
this.btnInsert.Location = new System.Drawing.Point(263, 6);
|
||||
this.btnInsert.Name = "btnInsert";
|
||||
this.btnInsert.Size = new System.Drawing.Size(80, 28);
|
||||
this.btnInsert.TabIndex = 24;
|
||||
this.btnInsert.TabStop = false;
|
||||
this.btnInsert.Text = "插入";
|
||||
this.btnInsert.Click += new System.EventHandler(this.btnInsert_Click);
|
||||
//
|
||||
// but_delete
|
||||
//
|
||||
this.but_delete.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||
@@ -360,18 +372,6 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
this.PlAdd.Size = new System.Drawing.Size(104, 15);
|
||||
this.PlAdd.TabIndex = 3;
|
||||
//
|
||||
// btnInsert
|
||||
//
|
||||
this.btnInsert.Appearance.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.btnInsert.Appearance.Options.UseFont = true;
|
||||
this.btnInsert.Location = new System.Drawing.Point(263, 6);
|
||||
this.btnInsert.Name = "btnInsert";
|
||||
this.btnInsert.Size = new System.Drawing.Size(80, 28);
|
||||
this.btnInsert.TabIndex = 24;
|
||||
this.btnInsert.TabStop = false;
|
||||
this.btnInsert.Text = "插入";
|
||||
this.btnInsert.Click += new System.EventHandler(this.btnInsert_Click);
|
||||
//
|
||||
// FrmWork
|
||||
//
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
|
||||
@@ -401,25 +401,4 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
private DevExpress.XtraEditors.SimpleButton btnAdd;
|
||||
private DevExpress.XtraEditors.SimpleButton btnSave;
|
||||
private DevExpress.XtraEditors.PanelControl panelControl3;
|
||||
private System.Windows.Forms.Panel panel2;
|
||||
private System.Windows.Forms.Panel panel1;
|
||||
private System.Windows.Forms.Label label4;
|
||||
private System.Windows.Forms.Label label3;
|
||||
private System.Windows.Forms.Panel plzsht;
|
||||
private System.Windows.Forms.Panel plxllzsz;
|
||||
private System.Windows.Forms.Label label2;
|
||||
private System.Windows.Forms.Panel plxlsz;
|
||||
private System.Windows.Forms.Label label1;
|
||||
private System.Windows.Forms.Panel pllzbzsz;
|
||||
private System.Windows.Forms.Panel PlAdd;
|
||||
private DevExpress.XtraEditors.PanelControl panelControl5;
|
||||
public DevExpress.XtraEditors.PanelControl panelControl1;
|
||||
private StepPage4 stepPage41;
|
||||
private StepPage3 stepPage31;
|
||||
private StepPage2 stepPage21;
|
||||
private StepPage1 stepPage11;
|
||||
private DevExpress.XtraEditors.SimpleButton but_delete;
|
||||
private DevExpress.XtraEditors.SimpleButton but_increase;
|
||||
private DevExpress.XtraEditors.SimpleButton btnInsert;
|
||||
}
|
||||
}
|
||||
private System.Windows.Forms.Panel panel
|
||||
@@ -108,6 +108,7 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
break;
|
||||
case StepEnum.StepPage2:
|
||||
this.btnReset.Visible = false;
|
||||
this.btnInsert.Visible = false;
|
||||
this.stepPage11.Visible = false;
|
||||
this.stepPage21.Visible = true;
|
||||
this.stepPage31.Visible = false;
|
||||
@@ -120,6 +121,7 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
break;
|
||||
case StepEnum.StepPage3:
|
||||
this.btnReset.Visible = true;
|
||||
this.btnInsert.Visible = false;
|
||||
this.stepPage11.Visible = false;
|
||||
this.stepPage21.Visible = false;
|
||||
this.stepPage31.Visible = true;
|
||||
@@ -131,7 +133,7 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
this.btnAdd.Text = "生成(&A)";
|
||||
break;
|
||||
case StepEnum.StepPage4:
|
||||
this.btnReset.Visible = this.btnAdd.Visible = this.btnInsert.Visible = false;
|
||||
this.btnReset.Visible = this.btnInsert.Visible = false;
|
||||
this.stepPage11.Visible = false;
|
||||
this.stepPage21.Visible = false;
|
||||
this.stepPage31.Visible = false;
|
||||
@@ -142,6 +144,8 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
this.plxlsz.BackgroundImage = Lskj.PubUserTomodule.Properties.Resources.icon_xlsz_gray_2x;
|
||||
this.plxllzsz.BackgroundImage = Lskj.PubUserTomodule.Properties.Resources.icon_lzbzsz_gray_2x;
|
||||
this.plzsht.BackgroundImage = Lskj.PubUserTomodule.Properties.Resources.icon_lzbzsz_2x;
|
||||
//this.btnAdd.Visible = false;
|
||||
this.btnAdd.Text = "生成Sql(&A)";
|
||||
break;
|
||||
|
||||
}
|
||||
@@ -211,6 +215,7 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
this.btnAdd.Enabled = this.btnReset.Enabled =this.btnInsert.Enabled = false;
|
||||
stepPage11.SerpPagePower = true;
|
||||
stepPage21.SerpPage2Power = true;
|
||||
stepPage31.SerpPage3Power = true;
|
||||
}
|
||||
// 设置默认显示第一个界面
|
||||
this.SetStepPage(StepEnum.StepPage1);
|
||||
@@ -326,6 +331,12 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
this.stepPage31.CreateFlowTypeStep();
|
||||
}
|
||||
break;
|
||||
case StepEnum.StepPage4:
|
||||
{
|
||||
// 生成终审sql
|
||||
this.stepPage41.GenerateFinalSqlStatement();
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
@@ -355,7 +366,8 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
string stepName = frmAddStep.StepName;
|
||||
string stepGroup = frmAddStep.StepName;
|
||||
|
||||
this.stepPage11.InsertStep(stepGroup, stepGroup);
|
||||
// this.stepPage11.InsertStep(stepGroup, stepGroup);
|
||||
this.stepPage11.InsertFlowItem(stepGroup, stepGroup);
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -619,51 +631,4 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
if (this.stepPage41.Sp4XtraTabControl.SelectedTabPage.Name == "xtraTabPage1")//进行tabpage位置判断
|
||||
{
|
||||
this.but_increase.Enabled = false;
|
||||
this.but_delete.Enabled = false;
|
||||
}
|
||||
if (this.stepPage41.Sp4XtraTabControl.SelectedTabPage.Name == "xtraTabPage2")
|
||||
{
|
||||
this.but_increase.Enabled = true;
|
||||
this.but_delete.Enabled = true;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
private void onBut_increase(object sender, EventArgs e)
|
||||
{
|
||||
this.stepPage41.onBut_increase();
|
||||
}
|
||||
|
||||
private void onBut_delete(object sender, EventArgs e)
|
||||
{
|
||||
this.stepPage41.onBut_delete();
|
||||
}
|
||||
|
||||
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
public enum StepEnum
|
||||
{
|
||||
/// <summary>
|
||||
/// 流转步骤界面
|
||||
/// </summary>
|
||||
StepPage1,
|
||||
/// <summary>
|
||||
/// 小类设置界面
|
||||
/// </summary>
|
||||
StepPage2,
|
||||
/// <summary>
|
||||
/// 小类流转步骤界面设置
|
||||
/// </summary>
|
||||
StepPage3,
|
||||
/// <summary>
|
||||
/// 终审回退权限设置
|
||||
/// </summary>
|
||||
StepPage4
|
||||
}
|
||||
}
|
||||
this.but_delete.Enabled = false
|
||||
@@ -1142,6 +1142,78 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 插入
|
||||
/// </summary>
|
||||
/// <param name="stepGroup"></param>
|
||||
/// <param name="stepName"></param>
|
||||
public void InsertFlowItem(string stepGroup, string stepName)
|
||||
{
|
||||
int Code = 0;
|
||||
if (isBasis)
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
if (SelectBaseflowModel == null)
|
||||
{
|
||||
MessageUtil.Show("插入的流转类别不能为空");
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
//BillflowModelList
|
||||
//选中的步骤号
|
||||
int selectedStepCode = SelectBaseflowModel.stepCode;
|
||||
//获取比选中步骤小一步的步骤号
|
||||
int? maxStepCode = BaseflowModelList
|
||||
.Where(m => m.stepCode < selectedStepCode)
|
||||
.Select(m => m.stepCode)
|
||||
.DefaultIfEmpty() // 避免空集合时抛出异常
|
||||
.Max();
|
||||
|
||||
Code = (int)(maxStepCode + (selectedStepCode - maxStepCode) / 2);
|
||||
}
|
||||
BaseflowModel model = new BaseflowModel
|
||||
{
|
||||
stepCode = Convert.ToInt32(Code),
|
||||
typeCode = mMenuCode,
|
||||
stepGroup = stepGroup,
|
||||
stepName = stepName,
|
||||
stepApplyText = "审核(&Y)",
|
||||
stepApplyContent = "同意",
|
||||
stepBackText = "反退(&N)",
|
||||
stepBackContent = "不同意",
|
||||
};
|
||||
try
|
||||
{
|
||||
// 保存
|
||||
if (WorkFlowBaseImpl.SaveBaseFlow(model))
|
||||
{
|
||||
// 重排列表
|
||||
InitializeStepFlow();
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
MessageUtil.Show("保存失败!" + ex.Message);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (SelectBillflowModel == null)
|
||||
{
|
||||
MessageUtil.Show("插入的流转类别不能为空");
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
//BillflowModelList
|
||||
//选中的步骤号
|
||||
int selectedStepCode = SelectBillflowModel.stepCode;
|
||||
//获取比选中步骤小一步的步骤号
|
||||
int? maxStepCode = BillflowModelList
|
||||
.Where(m => m.stepCode < selectedStepCode)
|
||||
.Select(m => m.stepCode)
|
||||
.DefaultIfEmpty() // 避免空集合时抛出异常
|
||||
.Max();
|
||||
|
||||
Code = (int)(maxStepCode + (selectedStepCode - max
|
||||
File diff suppressed because it is too large
Load Diff
@@ -294,6 +294,8 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <para>说明:部门下拉框值改变后</para>
|
||||
/// <para>创建人:龚宇超</para>
|
||||
@@ -610,12 +612,4 @@ namespace Lskj.PubUserTomodule.AuditPermissionControls
|
||||
this.memoEdit2.Text = dataTable.Rows[0]["OverBackOper"] + "";
|
||||
string key = dataTable.Rows[0]["OverBackKey"] + "";
|
||||
OverBackKey = key;
|
||||
this.ConditionsControlEx.gridControl.DataSource = isBasis ? WorkFlowBaseImpl.getFallbackCondition(key) : WorkFlowBillImpl.getFallbackCondition(key);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
this.ConditionsControlEx.gridControl.DataSource = isBasis ? WorkFlowBaseImpl.getFallbackCondition(key) : WorkFlowBillImpl.getFallbackCondition(
|
||||
@@ -335,13 +335,30 @@ namespace Lskj.PubUserTomodule
|
||||
/// </summary>
|
||||
private void creatTreeListControl()
|
||||
{
|
||||
GridColumn treeListColumnFirst = new GridColumn();
|
||||
treeListColumnFirst.Caption = "一级目录";
|
||||
treeListColumnFirst.FieldName = "FirstDirectory";
|
||||
treeListColumnFirst.MinWidth = 38;
|
||||
treeListColumnFirst.Visible = true;
|
||||
treeListColumnFirst.VisibleIndex = 0;
|
||||
treeListColumnFirst.Width = 100;
|
||||
treeListColumnFirst.OptionsColumn.AllowEdit = false;
|
||||
|
||||
GridColumn treeListColumnDirectory = new GridColumn();
|
||||
treeListColumnDirectory.Caption = "二级目录";
|
||||
treeListColumnDirectory.FieldName = "SecondaryDirectory";
|
||||
treeListColumnDirectory.MinWidth = 38;
|
||||
treeListColumnDirectory.Visible = true;
|
||||
treeListColumnDirectory.VisibleIndex =1;
|
||||
treeListColumnDirectory.Width = 150;
|
||||
treeListColumnDirectory.OptionsColumn.AllowEdit = false;
|
||||
|
||||
GridColumn treeListColumnName = new GridColumn();
|
||||
treeListColumnName.Caption = "系统名称";
|
||||
treeListColumnName.FieldName = "MenuCaption";
|
||||
treeListColumnName.MinWidth = 38;
|
||||
treeListColumnName.Visible = true;
|
||||
treeListColumnName.VisibleIndex = 0;
|
||||
treeListColumnName.VisibleIndex = 2;
|
||||
treeListColumnName.Width = 400;
|
||||
treeListColumnName.OptionsColumn.AllowEdit = false;
|
||||
|
||||
@@ -349,7 +366,7 @@ namespace Lskj.PubUserTomodule
|
||||
treeListColumnMenuId.Caption = "菜单id";
|
||||
treeListColumnMenuId.FieldName = "MenuId";
|
||||
treeListColumnMenuId.Visible = true;
|
||||
treeListColumnMenuId.VisibleIndex = 1;
|
||||
treeListColumnMenuId.VisibleIndex = 3;
|
||||
treeListColumnMenuId.OptionsColumn.AllowEdit = false;
|
||||
|
||||
GridColumn treeListColumnReadflag = new GridColumn();
|
||||
@@ -364,7 +381,7 @@ namespace Lskj.PubUserTomodule
|
||||
treeListColumnReadflag.FieldName = "Readflag";
|
||||
treeListColumnReadflag.Name = "treeListColumnReadflagValue";
|
||||
treeListColumnReadflag.Visible = true;
|
||||
treeListColumnReadflag.VisibleIndex = 3;
|
||||
treeListColumnReadflag.VisibleIndex = 5;
|
||||
|
||||
GridColumn treeListColumnEditflag = new GridColumn();
|
||||
treeListColumnEditflag.ColumnEdit = checkEdit;
|
||||
@@ -372,9 +389,11 @@ namespace Lskj.PubUserTomodule
|
||||
treeListColumnEditflag.FieldName = "Editflag";
|
||||
treeListColumnEditflag.Name = "treeListColumnEditflagValue";
|
||||
treeListColumnEditflag.Visible = true;
|
||||
treeListColumnEditflag.VisibleIndex = 2;
|
||||
treeListColumnEditflag.VisibleIndex = 4;
|
||||
|
||||
this.ModulePermissionsControl.GridView.Columns.AddRange(new GridColumn[] {
|
||||
treeListColumnFirst,
|
||||
treeListColumnDirectory,
|
||||
treeListColumnName,
|
||||
treeListColumnMenuId,
|
||||
treeListColumnReadflag,
|
||||
@@ -2446,30 +2465,4 @@ namespace Lskj.PubUserTomodule
|
||||
string sql = string.Empty;
|
||||
try
|
||||
{
|
||||
if (MessageUtil.Show(ResourceKeys.DragSelectRow, MessageBoxButtons.YesNo) == DialogResult.Yes)
|
||||
{
|
||||
|
||||
foreach (DataRow rowItem in e.GridViewSelectRows)
|
||||
{
|
||||
string RoleId = rowItem["id"] + "";
|
||||
//把推拽角色id传入页签中,页签根据选中的人员添加角色权限
|
||||
personnelInformation.AddRolePermissions(RoleId);
|
||||
}
|
||||
|
||||
personnelInformation.GridView_FocusedRowObjectChanged(null, null);
|
||||
ModuleAssociationRole_onClickDeleteButton(null, null);
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
LogUtil.WriteError("表格拖拽错误", ex);
|
||||
LogHelper.Instance.WriteError(ex);
|
||||
//MessageUtil.Show(ResourceKeys.OperFault);
|
||||
string Message = ErrorMessage.PromptErrorMessage(ex);
|
||||
MessageUtil.Show(Message, ex.Message);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
if (MessageUtil.Show(ResourceKeys.DragSelectR
|
||||
Reference in New Issue
Block a user