public void WhenIPostValidCustomerServiceCreateRequest() { customerServiceSupport.PostValidCreateRequestToService(); customerUID = customerServiceSupport.CreateCustomerModel.CustomerUID; assetDetailsServiceSupport.CustomerModel.CustomerUID = customerServiceSupport.CreateCustomerModel.CustomerUID; assetDetailsServiceSupport.CustomerModel.CustomerName = customerServiceSupport.CreateCustomerModel.CustomerName; assetDetailsServiceSupport.CustomerModel.CustomerType = customerServiceSupport.CreateCustomerModel.CustomerType; customerRelationshipServiceSupport.CreateCustomerRelationshipModel = CustomerRelationshipServiceSteps.GetDefaultValidCustomerRelationshipServiceCreateRequest(); customerRelationshipServiceSupport.CreateCustomerRelationshipModel.ParentCustomerUID = dealerUID; customerRelationshipServiceSupport.CreateCustomerRelationshipModel.ChildCustomerUID = customerUID; customerRelationshipServiceSupport.PostValidCreateCustomerRelationshipRequestToService(); }
public void AssociateCustomer(Guid parentCustomerUID, Guid childCustomerUID) { customerRelationshipServiceSupport.CreateCustomerRelationshipModel = CustomerRelationshipServiceSteps.GetDefaultValidCustomerRelationshipServiceCreateRequest(); customerRelationshipServiceSupport.CreateCustomerRelationshipModel.ParentCustomerUID = parentCustomerUID; customerRelationshipServiceSupport.CreateCustomerRelationshipModel.ChildCustomerUID = childCustomerUID; customerRelationshipServiceSupport.PostValidCreateCustomerRelationshipRequestToService(); AccountHierarchyDBComparisonClass NodeDetails = new AccountHierarchyDBComparisonClass(); NodeDetails.NodeUID = childCustomerUID; NodeDetails.ParentNodeUID = parentCustomerUID; NodeDetails.RootNodeUID = parentUID[0]; AccountHierarchyNodes.Add(NodeDetails); }
public void GivenCustomerServiceCreateRequestIsSetupFor(string associationType) { if (associationType == "CustomerWithSameDealer") { customerServiceSupport.CreateCustomerModel = CustomerServiceSteps.GetDefaultValidCustomerServiceCreateRequest(); customerServiceSupport.PostValidCreateRequestToService(); dealerUID = customerServiceSupport.CreateCustomerModel.CustomerUID; assetDetailsServiceSupport.DealerModel.CustomerUID = customerServiceSupport.CreateCustomerModel.CustomerUID; assetDetailsServiceSupport.DealerModel.CustomerName = customerServiceSupport.CreateCustomerModel.CustomerName; assetDetailsServiceSupport.DealerModel.CustomerType = customerServiceSupport.CreateCustomerModel.CustomerType; customerServiceSupport.CreateCustomerModel = CustomerServiceSteps.GetDefaultValidCustomerServiceCreateRequest(); customerServiceSupport.CreateCustomerModel.CustomerType = "Customer"; customerServiceSupport.PostValidCreateRequestToService(); customerUID = customerServiceSupport.CreateCustomerModel.CustomerUID; oldCustomerUID = customerUID; assetDetailsServiceSupport.FirstCustomerModel.CustomerUID = customerServiceSupport.CreateCustomerModel.CustomerUID; assetDetailsServiceSupport.FirstCustomerModel.CustomerName = customerServiceSupport.CreateCustomerModel.CustomerName; assetDetailsServiceSupport.FirstCustomerModel.CustomerType = customerServiceSupport.CreateCustomerModel.CustomerType; customerRelationshipServiceSupport.CreateCustomerRelationshipModel = CustomerRelationshipServiceSteps.GetDefaultValidCustomerRelationshipServiceCreateRequest(); customerRelationshipServiceSupport.CreateCustomerRelationshipModel.ParentCustomerUID = dealerUID; customerRelationshipServiceSupport.CreateCustomerRelationshipModel.ChildCustomerUID = customerUID; customerRelationshipServiceSupport.PostValidCreateCustomerRelationshipRequestToService(); customerServiceSupport.CreateCustomerModel = CustomerServiceSteps.GetDefaultValidCustomerServiceCreateRequest(); customerServiceSupport.CreateCustomerModel.CustomerType = "Customer"; } else { customerServiceSupport.CreateCustomerModel = CustomerServiceSteps.GetDefaultValidCustomerServiceCreateRequest(); customerServiceSupport.PostValidCreateRequestToService(); dealerUID = customerServiceSupport.CreateCustomerModel.CustomerUID; assetDetailsServiceSupport.DealerModel.CustomerUID = customerServiceSupport.CreateCustomerModel.CustomerUID; assetDetailsServiceSupport.DealerModel.CustomerName = customerServiceSupport.CreateCustomerModel.CustomerName; assetDetailsServiceSupport.DealerModel.CustomerType = customerServiceSupport.CreateCustomerModel.CustomerType; customerServiceSupport.CreateCustomerModel = CustomerServiceSteps.GetDefaultValidCustomerServiceCreateRequest(); customerServiceSupport.CreateCustomerModel.CustomerType = "Customer"; } }
public void GivenCustomerServiceCreateRequestIsSetupForAssetAndDeviceVerification() { //first dealer customerServiceSupport.CreateCustomerModel = CustomerServiceSteps.GetDefaultValidCustomerServiceCreateRequest(); customerServiceSupport.PostValidCreateRequestToService(); dealerUID = customerServiceSupport.CreateCustomerModel.CustomerUID; assetDetailsServiceSupport.FirstDealerModel.CustomerUID = customerServiceSupport.CreateCustomerModel.CustomerUID; assetDetailsServiceSupport.FirstDealerModel.CustomerName = customerServiceSupport.CreateCustomerModel.CustomerName; assetDetailsServiceSupport.FirstDealerModel.CustomerType = customerServiceSupport.CreateCustomerModel.CustomerType; //first customer customerServiceSupport.CreateCustomerModel = CustomerServiceSteps.GetDefaultValidCustomerServiceCreateRequest(); customerServiceSupport.CreateCustomerModel.CustomerType = "Customer"; customerServiceSupport.PostValidCreateRequestToService(); customerUID = customerServiceSupport.CreateCustomerModel.CustomerUID; assetDetailsServiceSupport.FirstCustomerModel.CustomerUID = customerServiceSupport.CreateCustomerModel.CustomerUID; assetDetailsServiceSupport.FirstCustomerModel.CustomerName = customerServiceSupport.CreateCustomerModel.CustomerName; assetDetailsServiceSupport.FirstCustomerModel.CustomerType = customerServiceSupport.CreateCustomerModel.CustomerType; //first dealer customer relationship customerRelationshipServiceSupport.CreateCustomerRelationshipModel = CustomerRelationshipServiceSteps.GetDefaultValidCustomerRelationshipServiceCreateRequest(); customerRelationshipServiceSupport.CreateCustomerRelationshipModel.ParentCustomerUID = dealerUID; customerRelationshipServiceSupport.CreateCustomerRelationshipModel.ChildCustomerUID = customerUID; customerRelationshipServiceSupport.PostValidCreateCustomerRelationshipRequestToService(); //second dealer customerServiceSupport.CreateCustomerModel = CustomerServiceSteps.GetDefaultValidCustomerServiceCreateRequest(); customerServiceSupport.PostValidCreateRequestToService(); dealerUID = customerServiceSupport.CreateCustomerModel.CustomerUID; assetDetailsServiceSupport.DealerModel.CustomerUID = customerServiceSupport.CreateCustomerModel.CustomerUID; assetDetailsServiceSupport.DealerModel.CustomerName = customerServiceSupport.CreateCustomerModel.CustomerName; assetDetailsServiceSupport.DealerModel.CustomerType = customerServiceSupport.CreateCustomerModel.CustomerType; //second customer customerServiceSupport.CreateCustomerModel = CustomerServiceSteps.GetDefaultValidCustomerServiceCreateRequest(); customerServiceSupport.CreateCustomerModel.CustomerType = "Customer"; }