예제 #1
0
        public PrefillAgencyForm()
        {
            InitializeComponent();
            _paepFunc = new PrefillAgencyEndPointFunction();
            _paepFunc.ReturnMessageXml += ReturnMessageXmlHandler;
            ShipmentSpf   = new SubmitPrefillFormTaskShipment();
            ShipmentSaipf = new SubmitAndInstantiatePrefillFormTaskShipment();
            ResultSpf     = new ReceiptExternal();
            ResultSaipf   = new ReceiptExternal();

            ShipmentSpf.PrefillFormTask = new PrefillFormTaskDetails();
            ShipmentSpf.PrefillFormTask.PreFillFormTasklist = new PreFillFormTaskBEList();
            SetupObjForPropGrid();
        }
        public ReceiptExternal SubmitAndInstantiatePrefilledFormTask(SubmitAndInstantiatePrefillFormTaskShipment shipment)
        {
            var client = GenerateProxy(shipment);

            OperationContext = _context + "SubmitAndInstantiatePrefilledFormTask";
            if (shipment.PrefillFormTask.PrefillNotifications.Count == 0)
            {
                shipment.PrefillFormTask.PrefillNotifications = null;
            }
            if (shipment.PrefillFormTask.PreFillAttachments.Count == 0)
            {
                shipment.PrefillFormTask.PreFillAttachments = null;
            }
            if (shipment.PrefillFormTask.PreFillIdentityFields.Count == 0)
            {
                shipment.PrefillFormTask.PreFillIdentityFields = null;
            }
            if (shipment.PrefillFormTask.PreFillForms.Count == 0)
            {
                shipment.PrefillFormTask.PreFillForms = null;
            }
            return(client.SubmitAndInstantiatePrefilledFormTaskEC(shipment.Username, shipment.Password, shipment.ExternalBatchId, shipment.PrefillFormTask,
                                                                  shipment.DoSaveFormTask, shipment.DoInstantiateFormTask, shipment.CaseId, shipment.DueDate));
        }