private void Save_button_Click(object sender, EventArgs e) { if (Status_ytComboBox1.SelectedIndex < 0) { WJs.alert("请选择一个状态信息!"); } if (isFlag == 2 && Status == 1) { if (AddBXYanZheng() == 1) { return; } } if (isFlag == 1 && Status == 2) { if (ModifyWXYanZheng() == 1) { return; } } if (isFlag == 1 && Status == 6) { if (ModifyJFYanZheng() == 1) { return; } } if (Status == 10) { if (AddBXYanZheng() == 1) { return; } if (ModifyWXYanZheng() == 1) { return; } if (ModifyJFYanZheng() == 1) { return; } } //下面开始保存了 ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.UseingEQ.EQFixManagSvr"; ac.Sql = "ModifyOrAddInfo"; AddRepairCardInfo(ac); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); if (isOk) { WJs.alert("保存信息成功,即将关闭本窗口……"); this.Close(); } }
private void toolStripButton3_Click(object sender, EventArgs e)//删除 { DataRow r7 = this.dataGView_Main.GetRowData(); if (r7 != null) { if (WJs.confirmFb("确定要删除选择的设备信息吗?\n删除后不能恢复!")) { rowid = this.dataGView_Main.CurrentRow.Index; ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.JiChuDictionary.EQDictSvr"; ac.Sql = "DelEQDictInfo"; ac.Add("EQID", r7["EQID"]); ac.Add("IFUSE", r7["IFUSE"]); ac.Add("CHOSCODE", His.his.Choscode); ac.Add("flag", "0"); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); } } else { WJs.alert("请选择要删除的设备信息"); } }
private void btnDelete_Click(object sender, EventArgs e) { Dictionary <string, ObjItem> dr = this.dataGView1.getRowData(); if (dr != null) { if (WJs.confirmFb("你确定要删除选择的设备类别吗?")) { decimal isusekindcode = Convert.ToDecimal(LData.Es("IsUseEQKindCode", null, new object[] { dr["类别编码"].ToString(), this.warecode_yTextBox.Text })); if (isusekindcode > 0) { WJs.alert("该类别已被使用,不能删除!"); return; } ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.JiChuDictionary.SetEQManagKind"; ac.Sql = "Delete"; ac.Add("CHOSCODE", dr["医疗机构编码"].ToString()); ac.Add("WARECODE", this.warecode_yTextBox.Text); ac.Add("KINDCODE", dr["类别编码"].ToString()); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); } } else { WJs.alert("请选择要删除的设备类别信息"); } }
//启用该条设备入出库管理 private void enable_toolStrip_Click(object sender, EventArgs e) { Dictionary <string, ObjItem> dr = this.dataGView1.getRowData(); if (dr != null) { if (WJs.confirm("您确定要启用选中的设备入出库记录吗?")) { if (dr["是否使用"].ToString() == "0") { ActionLoad ac = ActionLoad.Conn(); ac.Sql = "QiYong"; ac.Action = "LKWZSVR.lkeq.JiChuDictionary.EQInOutSvr"; ac.Add("CHOSCODE", His.his.Choscode.ToString()); ac.Add("IOID", dr["入出ID"].ToString()); ac.Add("IFUSE", "1"); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); } else { WJs.alert("该设备入出库记录已经被启用,无需修改!"); } } } else { WJs.alert("请选择要启用的设备出入库类型记录!"); } }
private void toolStripButton_Del_Click(object sender, EventArgs e) { DataRow row = this.dataGView1.GetRowData(); if (row != null) { if (WJs.confirmFb("确定要删除选择的盘点详细信息吗?")) { this.dataGView1.SelectedRows[0].Cells["Column9"].Value = null; this.dataGView1.SelectedRows[0].Cells["Column2"].Value = this.dataGView1.SelectedRows[0].Cells["Column12"].Value; if (!isAdd && r["PDID"] != null) { ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.EQWareManag.EQPanDianSvr"; ac.Sql = "DelEQPanDianDetailInfo"; ac.Add("PDID", r["PDID"].ToString()); ac.Add("ROWNO", Convert.ToDecimal(row["ROWNO"])); ac.Add("CHOSCODE", His.his.Choscode); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceDetailDeleteLoad); ac.ServiceFaiLoad += new YtClient.data.events.LoadFaiEventHandle(ac_ServiceFaiLoad); ac.Post(); } } } else { WJs.alert("请选择要删除的盘点信息"); } }
private void toolStripButton7_Click(object sender, EventArgs e)//停用 { DataRow r = this.ytTreeView1.getSelectRow(); if (r != null) { if (WJs.confirmFb("是否停用?")) { tr = this.ytTreeView1.SelectedNode.Text; string[] str = tr.Split('|'); tr = str[0]; tr = tr.Trim(); ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.JiChuDictionary.EQKind"; ac.Sql = "StopEQKindInfo"; ac.Add("KINDCODE", r["KINDCODE"]); ac.Add("CHOSCODE", His.his.Choscode); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); } } else { WJs.alert("请选择要停用的设备类别"); } }
private void toolStripButton6_Click(object sender, EventArgs e)//启用 { Dictionary <string, ObjItem> dr = this.dataGView1.getRowData(); if (dr != null) { if (dr["医疗机构编码"].ToString() != His.his.Choscode) { WJs.alert("只能启用属于本医疗机构的厂商信息!"); } else if (WJs.confirmFb("是否启用?")) { rowid = this.dataGView1.CurrentRow.Index; ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.JiChuDictionary.EQSupplySvr"; ac.Sql = "StartWZSupplyInfo"; ac.Add("SUPPLYID", dr["厂商ID"].ToInt()); ac.Add("CHOSCODE", His.his.Choscode); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); } } else { WJs.alert("请选择要停用的厂商信息"); } }
private void copy_toolStrip_Click(object sender, EventArgs e) { if (WJs.confirm("您确定要复制系统提供的出入库数据到本医疗机构吗?")) { ActionLoad ac = ActionLoad.Conn(); ac.Sql = "CopyChoscodeData"; ac.Action = "LKWZSVR.lkeq.JiChuDictionary.EQInOutSvr"; ac.Add("IOID", null); ac.Add("IONAME", null); ac.Add("PYCODE", null); ac.Add("WBCODE", null); ac.Add("IFUSE", null); ac.Add("RECIPECODE", null); ac.Add("RECIPELENGTH", null); ac.Add("RECIPEYEAR", null); ac.Add("RECIPEMONTH", null); ac.Add("MEMO", null); ac.Add("IOFLAG", null); ac.Add("OPFLAG", null); ac.Add("IFDEFAULT", null); ac.Add("RECDATE", null); ac.Add("USERID", His.his.UserId.ToString()); ac.Add("USERNAME", His.his.UserName); ac.Add("CHOSCODE", His.his.Choscode); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); } }
private void toolStrip_SHPass_Click(object sender, EventArgs e) { if (this.textBox_SHADVICE.Text.Trim() == "") { WJs.alert("请填写审批意见!"); this.textBox_SHADVICE.Focus(); return; } ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.UseingEQ.EQKeepAccountsManagSvr"; ac.Sql = "SHPass"; ac.Add("NOID", NOID_textBox.Text.ToString()); ac.Add("SHUSERID", His.his.UserId); ac.Add("SHMAN", His.his.UserName); ac.Add("SHADVICE", this.textBox_JDADVICE.Text); ac.Add("CARDID", drZ["卡片ID"].ToString()); ac.Add("STATUS", 6); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); }
private void save_button_Click(object sender, EventArgs e)//保存 { if (this.dicdesc_yTextBox.Text.Trim().Length == 0) { WJs.alert("请输入名称!"); dicdesc_yTextBox.Focus(); return; } if (this.defvalue_ytComboBox.SelectedIndex < 0) { WJs.alert("请设置是否为默认值!"); defvalue_ytComboBox.Focus(); return; } ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.JiChuDictionary.EQUnit"; ac.Sql = "Save"; ac.Add("DICGRPID", this.dicgrpid_yTextBox.Text); ac.Add("DICDESC", this.dicdesc_yTextBox.Text); ac.Add("FIXED", 1); ac.Add("PYCODE", this.pycode_yTextBox5.Text); ac.Add("DEFVALUE", TvList.getValue(this.defvalue_ytComboBox).ToInt()); if (!isAdd) { ac.Add("DICID", dr["DICID"].ToString()); ac.SetKeyValue("DICGRPID,DICID"); } ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); }
private void DeleButton_Click(object sender, EventArgs e)//删除 { Dictionary <string, ObjItem> dr = this.dataGView1.getRowData(); if (dr != null) { if (WJs.confirmFb("您确定要删除选择的设备项目单位信息吗?")) { ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.JiChuDictionary.EQUnit"; // ac.Action = "Save"; ac.Sql = "Del"; //ac.Sql = "DelWZInfo"; // ac.Add("choscode", His.his.Choscode.ToString()); ac.Add("UNITCODE", dr["DICID"].ToString()); ac.Add("LSUNITCODE", dr["DICID"].ToString()); ac.Add("DICID", dr["DICID"].ToString()); ac.Add("DICGRPID", dr["字典组类别"].ToString()); //ac.SetKeyValue("choscode,warecode"); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); //reLoad(); //刷新表格数据 Search_button_Click(null, null); } } else { WJs.alert("请选择要删除的设备项目单位信息!"); } }
private void DeleButton_Click(object sender, EventArgs e)//删除 { Dictionary <string, ObjItem> dr = this.dataGView1.getRowData(); if (dr != null) { if (dr["状态"].ToInt() == 1 || dr["状态"].ToInt() == 2) { ActionLoad ac = new ActionLoad(); ac.Action = "LKWZSVR.lkeq.EQPurchase.EQPurchasePlanSvr"; ac.Sql = "EQPurchasePlanDelete"; ac.Add("PLANID", dr["采购计划ID"].ToString()); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); Search_button_Click(null, null); // WJs.alert("删除采购计划id=" + dr["采购计划id"].ToString() + "成功!"); } if (dr["状态"].ToInt() == 0) { WJs.alert("该计划已删除,不能再次删除!"); } if (dr["状态"].ToInt() == 6) { WJs.alert("该计划已审核,不能删除!"); } } else { WJs.alert("请选择要删除的采购计划信息!"); } }
private void Submit_toolStripButton_Click(object sender, EventArgs e) //提交 { Dictionary <string, ObjItem> dr = this.dataGView1.getRowData(); if (dr != null) { if (dr["状态"].ToInt() == 2) { ActionLoad ac = new ActionLoad(); ac.Action = "LKWZSVR.lkeq.EQPurchase.EQPurchasePlanSvr"; ac.Sql = "PlanDanUpdata_Submit"; ac.Add("PLANID", dr["采购计划ID"].ToString()); ac.Add("STATUS", 1); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); Search_button_Click(null, null); } if (dr["状态"].ToInt() == 0) { WJs.alert("该计划已删除,不能提交!"); } if (dr["状态"].ToInt() == 1) { WJs.alert("该计划已是等待审核,不需提交!"); } if (dr["状态"].ToInt() == 6) { WJs.alert("该计划已审核,不需再提交!"); } } else { WJs.alert("请选择要提交的采购计划信息!"); } }
private void Enable_toolStripButton_Click(object sender, EventArgs e) { Dictionary <string, ObjItem> dr = this.dataGView1.getRowData(); if (dr != null) { if (dr["是否使用"].ToString() == "0") { ActionLoad ac = ActionLoad.Conn(); ac.Sql = "QiYong"; ac.Action = "LKWZSVR.lkeq.JiChuDictionary.EQStatusSvr"; ac.Add("STATUSCODE", dr["状态编码"].ToString()); ac.Add("CHOSCODE", dr["医疗机构编码"].ToString()); ac.Add("IFUSE", "1"); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); } else { WJs.alert("该设备状态已经为启用状态,无需更改!"); } } else { WJs.alert("请选择需要启用的设备状态信息!"); } }
private void UsetoolStripButton_Click(object sender, EventArgs e) { Dictionary <string, ObjItem> dr = this.dataGView1.getRowData(); if (dr != null) { if (dr["是否使用"].ToString() == "0") { if (WJs.confirmFb("您确定要启用选择的设备库房吗?")) { ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.JiChuDictionary.EQWare"; ac.Sql = "Enab"; ac.Add("ifuse", "1"); ac.Add("choscode", His.his.Choscode.ToString()); ac.Add("warecode", dr["库房编码"].ToString()); ac.SetKeyValue("warecode,choscode"); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); reLoad(); } } else { WJs.alert("该设备库房已经启用了"); } } else { WJs.alert("请选择要启用的设备库房信息!"); } }
private void QueRen_toolStrip_Click(object sender, EventArgs e) { if (dataGView1.RowCount <= 0) { WJs.alert("当前折旧细表内无数据,不能进行月结信息!"); return; } //确认的时候先保存折旧记录 然后更新对应的数据 string XmlData = this.dataGView1.GetDataToXml(); ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.UseingEQ.EQMonthAccountSvr"; ac.Sql = "QueRenYueJie"; ac.Add("XmlDataList", XmlData); ac.Add("BEGINDATE", drZ["开始日期"].ToDateTime()); ac.Add("ENDDATE", drZ["结束日期"].ToDateTime()); AddZhuBiaoInfo(ac); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); if (isOk) { WJs.alert("月结成功,即将关闭本窗口!"); this.Close(); } }
private void Enable_toolStripButton_Click(object sender, EventArgs e) { //针对启用 DataRow dr = this.ytTreeView1.getSelectRow(); if (dr != null) { if (dr["IFUSE"].ToString() == "0") { if (WJs.confirmFb("您确定要启用选择的统计类别信息吗?")) { ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.JiChuDictionary.EQCountKindSvr"; ac.Sql = "QiYong"; ac.Add("IFUSE", "1"); ac.Add("CHOSCODE", His.his.Choscode.ToString()); ac.Add("COUNTCODE", dr["COUNTCODE"]); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); } } else { WJs.alert("该统计类别信息已经启用了!"); } } else { WJs.alert("请选择要启用的统计类别信息!"); } }
private void toolStripButton6_Click(object sender, EventArgs e)//提交 { DataRow r = this.dataGView_Main.GetRowData(); if (r != null) { if (WJs.confirmFb("是否提交?")) { if (r["STATUS"].ToString() == "2") { rowid = this.dataGView_Main.CurrentRow.Index; ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.EQPurchase.EQAskBuySvr"; ac.Sql = "Submit_EQAskBuyInfo"; ac.Add("APPLYID", r["APPLYID"]); ac.Add("CHOSCODE", His.his.Choscode); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); } else { WJs.alert("状态错误,只能对状态为审核被拒的数据进行再次提交!"); } } } else { WJs.alert("请选择要提交的请购信息!"); } }
private void toolStripButton3_Click(object sender, EventArgs e)//删除 { Dictionary <string, ObjItem> dr = this.dataGView1.getRowData(); if (dr != null) { if (dr["医疗机构编码"].ToString() != His.his.Choscode) { WJs.alert("不能删除不属于本医疗机构的厂商信息!"); return; } else if (WJs.confirmFb("确定要删除选择的厂商信息吗?\n删除后不能恢复!")) { rowid = this.dataGView1.CurrentRow.Index; ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.JiChuDictionary.EQSupplySvr"; ac.Sql = "EQDelChangShangInfo"; ac.Add("SUPPLYID", dr["厂商ID"].ToInt()); ac.Add("CHOSCODE", His.his.Choscode); ac.Add("IFUSE", dr["是否使用"].ToString()); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); } } else { WJs.alert("请选择要删除的厂商信息!"); } }
private void toolStripButton_Submit_Click(object sender, EventArgs e) { DataRow r1 = this.dataGView1.GetRowData(); if (r1 != null) { if (WJs.confirmFb("确定要提交选择的盘点信息吗?")) { if (r1["STATUS"].ToString() == "2") { rowid = this.dataGView1.CurrentRow.Index; if (this.dataGView1[1, rowid].Value == null || this.dataGView1[1, rowid].Value.ToString().Trim().Length <= 0)//判断是否为最后一行 { rowid = 0; } ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.EQWareManag.EQPanDianSvr"; ac.Sql = "SubmitEQPD"; ac.Add("PDID", r1["PDID"]); ac.Add("CHOSCODE", His.his.Choscode); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); } else { WJs.alert("状态错误,只能提交状态为审核被拒的数据!"); } } } else { WJs.alert("请选择要提交的盘点信息"); } }
void UnitCodeBind() { ActionLoad acUnitcode = ActionLoad.Conn(); acUnitcode.Action = "LKWZSVR.lkeq.WareManag.EQDiaoBoSvr"; acUnitcode.Sql = "BindUnitCode"; acUnitcode.ServiceLoad += new YtClient.data.events.LoadEventHandle(acUnitcode_ServiceLoad); acUnitcode.Post(); }
void EQIDBind() { ActionLoad acEQID = ActionLoad.Conn(); acEQID.Action = "LKWZSVR.lkeq.WareManag.EQDiaoBoSvr"; acEQID.Sql = "BindEQIDInfo"; acEQID.Add("CHOSCODE", His.his.Choscode); acEQID.ServiceLoad += new YtClient.data.events.LoadEventHandle(acEQID_ServiceLoad); acEQID.Post(); }
private void toolStrip_JDNo_Click(object sender, EventArgs e) { ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.UseingEQ.EQKeepAccountsManagSvr"; ac.Add("NOID", NOID_textBox.Text.Trim().ToString()); ac.Sql = "JDNo"; ac.Add("STATUS", 2); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); }
private void toolStripButton1_Click(object sender, EventArgs e)//复制 { ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.JiChuDictionary.EQKind"; ac.Sql = "CopyEQKindInfo"; ac.Add("CHOSCODE", His.his.Choscode); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); }
private void button1_Click(object sender, EventArgs e) //修改 { if (this.yTextBox_XSWS.Text.Trim().Length >= 1) { int a; if (!int.TryParse(this.yTextBox_XSWS.Text, out a)) { WJs.alert("小数位数必须是大于或等于零的整数"); this.yTextBox_XSWS.Focus(); return; } } if (this.yTextBox_CardsLong.Text.Trim().Length >= 1) { int a; if (!int.TryParse(this.yTextBox_CardsLong.Text, out a)) { WJs.alert("卡号长度必须是大于或等于零的整数"); this.yTextBox_CardsLong.Focus(); return; } } ActionLoad ld = ActionLoad.Conn(); ld.Action = "LKWZSVR.lkeq.JiChuDictionary.SysValue"; ld.Sql = "Add"; if (mzd == null || mzd.Rows.Count == 0) { ld.SetParams(new object[] { 2200, "设备维修是否采用多个步骤", this.ytComboBox_MoreStype.SelectedIndex.ToString(), "0:单步维修 1:多步维修 “报修→维修→交付”", His.his.Choscode, 2201, "是否设备领用时建卡", this.ytComboBox_BuildCard.SelectedIndex.ToString(), "0:否 1:是", His.his.Choscode, 2202, "是否一台设备建立一张卡片", this.ytComboBox_OnlyOneCard.SelectedIndex.ToString(), "0:否 1:是", His.his.Choscode, 2203, "小数位数", this.yTextBox_XSWS.Text, "设定在系统中显示单价、金额信息时,所使用的小数位数,默认是2", His.his.Choscode, 2204, "是否使用千分位符号", this.ytComboBox_UseQian.SelectedIndex, "0:不使用 1:使用", His.his.Choscode, 2205, "建卡时,是否自动启用设备", this.ytComboBox_AutoUse.SelectedIndex, "0:不启用 1:启用", His.his.Choscode, 2206, "设备卡的卡号长度", this.yTextBox_CardsLong.Text, "设置设备卡片的卡号长度,不含前缀字符的数字长度", His.his.Choscode, 2207, "是否允许负库存出库", this.ytComboBox_AllowDropOut.SelectedIndex, "0:不允许 1:允许", His.his.Choscode }); ld.Sql = "Add"; } else { ld.SetParams(new object[] { this.ytComboBox_MoreStype.SelectedIndex.ToString(), His.his.Choscode, this.ytComboBox_BuildCard.SelectedIndex.ToString(), His.his.Choscode, this.ytComboBox_OnlyOneCard.SelectedIndex.ToString(), His.his.Choscode, this.yTextBox_XSWS.Text, His.his.Choscode, this.ytComboBox_UseQian.SelectedIndex, His.his.Choscode , this.ytComboBox_AutoUse.SelectedIndex, His.his.Choscode, this.yTextBox_CardsLong.Text, His.his.Choscode, this.ytComboBox_AllowDropOut.SelectedIndex, His.his.Choscode }); ld.Sql = "Update"; } ld.ServiceLoad += new YtClient.data.events.LoadEventHandle(ld_ServiceLoad); ld.Post(); }
private void button1_Click(object sender, EventArgs e) { if (this.countname_yTextBox.Text.Trim().Length == 0) { WJs.alert("请输入统计类别名称!"); return; } ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.JiChuDictionary.EQCountKindSvr"; if (isAdd) { ac.Sql = "Add"; } else { ac.Sql = "Modify"; } ac.Add("COUNTCODE", this.countcode_yTextBox.Text.Trim()); ac.Add("SUPERCODE", this.supercode_yTextBox.Text.Trim()); ac.Add("COUNTNAME", this.countname_yTextBox.Text.Trim()); ac.Add("PYCODE", this.pycode_yTextBox.Text.Trim()); ac.Add("WBCODE", this.wbcode_yTextBox.Text.Trim()); ac.Add("IFEND", this.ifend_ytComboBox.SelectedIndex); ac.Add("IFUSE", this.ifuse_ytComboBox.SelectedIndex); ac.Add("MEMO", this.memo_yTextBox.Text); ac.Add("USERID", His.his.UserId.ToString()); ac.Add("USERNAME", His.his.UserName); ac.Add("RECDATE", this.reedittime_yTextBox.Text); ac.Add("CHOSCODE", His.his.Choscode); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); if (isOk) { if (isAdd) { if (!WJs.confirm("添加统计类别信息成功,是否继续添加?")) { this.Close(); } else { InitAddEQCountKind(); } } else { this.Close(); } } else { WJs.alert("保存设备统计类别信息失败!"); } }
private void save_toolStripButton_Click(object sender, EventArgs e)//保存 { if (this.ytComboBox_Plan.Value == null) { WJs.alert("请选择计划类型!"); return; } if (this.dataGView1.RowCount == 0) { WJs.alert("请添加采购设备"); return; } if (this.totalmoney_yTextBox.Text.Trim().Length > 11) { WJs.alert("总金额太大(不能超过100000.0000)!请减少该批次设备"); return; } string str = this.dataGView1.GetDataToXml(); if (str != null) { ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.EQPurchase.EQPurchasePlanSvr"; ac.Sql = "PlanDanSave"; ac.Add("WARECODE", this.InWare_selTextInpt.Value); ac.Add("PLANDATE", DateTime.Now); ac.Add("MEMO", this.memo_yTextBox.Text); ac.Add("CHOSCODE", His.his.Choscode); ac.Add("USERID", His.his.UserId); ac.Add("USERNAME", His.his.UserName); ac.Add("STATUS", "1"); ac.Add("TOTALMONEY", this.totalmoney_yTextBox.Text); ac.Add("PLANTYPE", this.ytComboBox_Plan.Value); ac.Add("DanJuMx", str); if (isAdd == 2) { ac.Add("PLANID", dr["采购计划ID"].ToString()); } ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad); ac.Post(); } }
private void reLoad() { ActionLoad ld = ActionLoad.Conn(); ld.Action = "Find"; ld.Sql = "EQFindSysValue"; ld.SetParams(new object[] { His.his.Choscode }); ld.ServiceLoad += new YtClient.data.events.LoadEventHandle(ld_ServiceLoadcSF); ld.Post(); }
private void DeleButton_Click(object sender, EventArgs e) { Dictionary <string, ObjItem> doc = this.dataGView1.getRowData(); if (doc != null) { if (doc["设备"].IsNull) { this.dataGView1.Rows.Remove(this.dataGView1.CurrentRow); } else { if (WJs.confirmFb("您确定要删除选择的出库设备信息吗?")) { this.dataGView1.Rows.Remove(this.dataGView1.CurrentRow); this.dataGView1.jsBds("金额=数量*单价"); this.dataGView1.jsBds("运杂率=原运杂费/(入库数-出库数"); this.dataGView1.jsBds("运杂费=运杂率*数量"); this.dataGView1.jsBds("成本单价=单价+运杂费/数量"); this.dataGView1.jsBds("成本金额=成本单价*数量"); ////统计金额 this.totalmoney_yTextBox.Text = dataGView1.Sum("金额").ToString(); if (!doc["流水号"].IsNull && !doc["流水号"].ToString().Equals("")) { //数据库中已经存在该记录,需要删除数据库中的记录 ActionLoad ac = new ActionLoad(); ac.Action = "LKWZSVR.lkeq.EQWareManag.EQOutSvr"; ac.Sql = "ChuKuDanEQdelete"; ac.Add("DETAILNO", doc["流水号"].ToString()); //ac.Add("WZID", doc["物资ID"].ToString()); //获取入库ID string inwareid = LData.Es("EQGetInWareId", null, new object[] { doc["流水号"].ToString() }); ac.Add("OUTID", inwareid); ac.Add("TOTALMONEY", this.totalmoney_yTextBox.Text); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac2_ServiceLoad); ac.Post(); } } } } else { WJs.alert("请选择需要删除的行!"); } }
private void button_SB_Click(object sender, EventArgs e) { ActionLoad ac = ActionLoad.Conn(); ac.Action = "LKWZSVR.lkeq.EQPurchase.EQAskBuySvr"; ac.Sql = "EQAskBuyInfo_SHSB"; ac.Add("APPLYID", r["APPLYID"]); ac.Add("CHOSCODE", His.his.Choscode); ac.Add("RECDATE", this.ytDateTime_RECDATE.Value); ac.ServiceLoad += new YtClient.data.events.LoadEventHandle(ac_ServiceLoad_SH); ac.ServiceFaiLoad += new YtClient.data.events.LoadFaiEventHandle(ac_ServiceFaiLoad); ac.Post(); }