private void btnModify_Click(object sender, System.EventArgs e) { //修改 try { OrderBook order = new OrderBook(); order.cnvcOperID = oper.strLoginID; order.cnvcOrderType = ddlOrderType.SelectedValue; order.cnvcProduceDeptID = ddlProduceDept.SelectedValue; order.cnvcOrderDeptID = ddlSalesRoom.SelectedValue; if (order.cnvcOrderType == "WDO") { order.cndArrivedDate = DateTime.Parse(txtArrivedDate.Text); order.cnvcLinkPhone = txtLinkPhone.Text; order.cnvcShipAddress = txtShipAddress.Text; order.cnvcCustomName = txtCustomName.Text; } order.cnnOrderSerialNo = decimal.Parse(txtOrderSerialNo.Text); order.cndShipDate = DateTime.Parse(txtShipDate.Text); OperLog operLog = new OperLog(); operLog.cnvcOperID = oper.strLoginID; operLog.cnvcDeptID = oper.strDeptID; operLog.cnvcOperType = "修改订单"; OrderFacade orderFacade = new OrderFacade(); orderFacade.UpdateOrder(order, operLog); Popup("修改成功"); } catch (Exception ex) { Popup(ex.Message); } }