Ejemplo n.º 1
0
        ///
        ///	 * <param name="icsLevel"> </param>
        ///
        protected internal virtual JDFCustomerInfo initCustomerInfo()
        {
            if (theParentNode != null)
            {
                //ORIGINAL LINE: final JDFCustomerInfo customerInfo = theParentNode.getCustomerInfo();
                JDFCustomerInfo customerInfo = theParentNode.getCustomerInfo();
                if (customerInfo != null)
                {
                    theNode.linkResource(customerInfo, EnumUsage.Input, null);
                    return(customerInfo);
                }
            }
            JDFCustomerInfo ci = theNode.getCreateCustomerInfo();

            ci.setResStatus(EnumResStatus.Available, false);

            ci.setCustomerID("customerID");
            ci.setCustomerJobName("customer job name");
            ci.setCustomerOrderID("customerOrder_1");
            JDFContact contact = ci.appendContact();

            contact.makeRootResource(null, null, true);
            contact.setContactTypes(new VString("Customer Administrator", " "));
            JDFPerson person = contact.appendPerson();

            person.setFamilyName("Töpfer");
            person.setFirstName("Harald");
            JDFCompany comp = contact.appendCompany();

            comp.setOrganizationName("The Pits");
            return(ci);
        }
Ejemplo n.º 2
0
        ///
        ///
        protected internal virtual JDFCustomerInfo initCustomerInfo(string firstame, string lastame, string companyName, string jobName)
        {
            JDFCustomerInfo ci = theNode.getCreateCustomerInfo();

            ci.setCustomerJobName(jobName);
            JDFContact c = ci.getContactWithContactType(EnumContactType.Customer.getName(), 0);

            if (c == null)
            {
                c = ci.appendContact(EnumContactType.Customer);
            }
            c.setPerson(firstame, lastame);
            if (companyName != null)
            {
                c.getCreateCompany().setOrganizationName(companyName);
            }
            return(ci);
        }