| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899 |
- using System;
- using System.Collections;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.Data;
- using System.Drawing;
- using System.Linq;
- using System.Text;
- using System.Windows.Forms;
- using com.hnshituo.pur.vo;
- using Core.Mes.Client.Comm.Tool;
- using CoreFS.CA06;
- using Pur.Entity;
- namespace Pur.Pop_upWindow
- {
- public partial class frmExamineShowNew : FrmPmsBase
- {
- private ArrayList list;
- public string tips = "0";
- public string isAudit = "";
- public string type = "pur";//"pur":采购,order:合同,req:需求
- public frmExamineShowNew()
- {
- InitializeComponent();
- }
- public frmExamineShowNew(ArrayList listM,OpeBase OB,string strType)
- {
- InitializeComponent();
- this.ob = OB;
- this.list = listM;
- this.type = strType;
- }
- private void frmExamineShowNew_Load(object sender, EventArgs e)
- {
- //加载数据
- }
- /// <summary>
- /// 状态 1:不通过2:通过
- /// </summary>
- private void button2_Click(object sender, EventArgs e)
- {
- tips = "0";
- this.Close();
- }
- private void button1_Click(object sender, EventArgs e)
- {
- if (textBox1.Text.Trim() == "" && radioButton1.Checked == false)
- {
- MessageUtil.ShowTips("请输入审批意见");
- return;
- }
- else
- {
- if (radioButton1.Checked)
- {
- isAudit = "2";//审批通过
- }
- else if (radioButton2.Checked)
- {
- isAudit = "1";//审批不通过
- }
- String auditMessage = textBox1.Text.ToString().Trim();
- CoreResult rt = new CoreResult();
- if (type == "pur")
- {
- rt = this.execute<CoreResult>("com.hnshituo.pur.purplan.service.PurPlanMService", "doAudit", new object[] { list, isAudit, auditMessage });
- }
- else if (type == "order")
- {
- rt = this.execute<CoreResult>("com.hnshituo.pur.order.service.OrderMService", "doAudit", new object[] { list, isAudit, auditMessage });
- }
- else if (type == "req")
- {
- rt = this.execute<CoreResult>("com.hnshituo.pur.purplan.service.PurPlanMService", "doAudit", new object[] { list, isAudit, auditMessage });
- }
- else
- {
- tips = "1";
- MessageUtil.ShowTips("未知审批类型参数!");
- this.Close();
- }
-
- if (rt.Resultcode == 0)
- {
- tips = "1";
- MessageUtil.ShowTips("审批成功!");
- this.Close();
- }
- else
- {
- MessageUtil.ShowTips("操作失败:"+rt.Resultmsg);
- tips = "0";
- }
- }
- }
- }
- }
|