Esempio n. 1
0
 public SelectionForm(B_Machine machine, string station, string empCode)
 {
     InitializeComponent();
     this.client   = new ServiceReference.ServiceClient();
     this._machine = machine;
     this._station = station;
     this._emp     = empCode;
     this.res      = new ILE.LEResult();
 }
Esempio n. 2
0
        public IResult DoWork(IJob job)
        {
            ILE.IResult res = new ILE.LEResult();
            client = new ServiceReference.ServiceClient();

            string ResDispatching = client.RunServerAPI("BLL.Machine", "GetMachineInfo", job.StationCode);

            if (ResDispatching == "")
            {
                res.Result     = false;
                res.ExtMessage = "该工位未绑定设备,无法使用模具";
                return(res);
            }

            B_Machine produc = JsonConvert.DeserializeObject <B_Machine>(ResDispatching);

            SelectionForm sf = new SelectionForm(produc, job.StationCode, job.EmpCode);

            sf.ShowDialog();
            res.Result       = sf.res.Result;
            res.ExtMessage   = sf.res.ExtMessage;
            job.reload_code += "mould/";
            return(res);
        }