<?xml version="1.0" encoding="euc-kr"?>
<process xmlns:bean="http://bean.boe.com/" xmlns:bpel="http://bpel.boe.com/" targetNamespace="http://bpel.boe.com/bpelj/" name="MakePreScrap.bpel">
    <partnerLinks>
        <partnerLink name="bpelj" partnerLinkType="bpel:bpelj" />
        <partnerLink name="TransactionUtil" partnerLinkType="bean:TransactionUtil" />
        <partnerLink name="MaterialPackingStockInImpl" partnerLinkType="bean:MaterialPackingStockInImpl" />
        <partnerLink name="CommonValidation" partnerLinkType="bean:CommonValidation" />
        <partnerLink name="EventInfoUtil" partnerLinkType="bean:EventInfoUtil" />
        <partnerLink name="MaterialPackingServiceUtil" partnerLinkType="bean:MaterialPackingServiceUtil" />
        <partnerLink name="MaterialPackingServiceImpl" partnerLinkType="bean:MaterialPackingServiceImpl" />
        <partnerLink name="ERPInterfaceServiceImpl" partnerLinkType="bean:ERPInterfaceServiceImpl" />
        <partnerLink name="ESBService" partnerLinkType="bean:ESBService" />
    </partnerLinks>
    <variables>
        <variable name="actType" messageType="java.lang.String" expression="getXmlData('message', '//Message/Body/ACTTYPE')" />
        <variable name="boxList" messageType="java.util.List"></variable>
        <variable name="E" messageType="java.lang.String"></variable>
        <variable name="erpEventTime" messageType="java.lang.String" expression="getXmlData('message', '//Message/Body/ERPEVENTTIME')" />
        <variable name="erpFactory" messageType="java.lang.String" expression="getXmlData('message', '//Message/Body/ERPFACTORY')" />
        <variable name="erpLocation" messageType="java.lang.String" expression="getXmlData('message', '//Message/Body/ERPLOCATION')" />
        <variable name="ERP&#x8fc7;&#x8d26;³¬&#x65f6;" messageType="java.lang.String"></variable>
        <variable name="eventComment" messageType="java.lang.String" expression="getXmlData('message', '//Message/Body/LASTEVENTCOMMENT')" />
        <variable name="eventInfo" messageType="com.cim.idm.framework.data.EventInfo"></variable>
        <variable name="eventUser" messageType="java.lang.String" expression="getXmlData('message', '//Message/Header/EVENTUSER')" />
        <variable name="materialUndoInfo" messageType="java.util.List"></variable>
        <variable name="message" messageType="org.jdom.Document"></variable>
        <variable name="messageID" messageType="java.lang.String"></variable>
        <variable name="newUnDoList" messageType="java.util.List"></variable>
        <variable name="OICSender" messageType="java.lang.String"></variable>
        <variable name="PDASender" messageType="java.lang.String"></variable>
        <variable name="POName" messageType="java.lang.String" expression="getXmlData('message', '//Message/Body/RECEIVEREQUESTNAME')" />
        <variable name="reasonCode" messageType="java.lang.String" expression="getXmlData('message', '//Message/Body/REASONCODE')" />
        <variable name="reasonCodeType" messageType="java.lang.String" expression="getXmlData('message', '//Message/Body/REASONCODETYPE')" />
        <variable name="ReceiveAct" messageType="java.lang.String"></variable>
        <variable name="receiveActNo" messageType="java.lang.String" expression="getXmlData('message', '//Message/Body/RECEIVEACTNO')" />
        <variable name="replySubjectName" messageType="java.lang.String" expression="getXmlData('message', '//Message/Header/ORIGINALSOURCESUBJECTNAME')" />
        <variable name="requestDetailName" messageType="java.lang.String" expression="getXmlData('message', '//Message/Body/DESCRIPTION')" />
        <variable name="shipRequestName" messageType="java.lang.String" expression="getXmlData('message', '//Message/Body/RECEIVEREQUESTNAME')" />
        <variable name="shipType" messageType="java.lang.String" expression="getXmlData('message', '//Message/Body/RECEIVEREQUESTDETAILTYPE')" />
        <variable name="siteName" messageType="java.lang.String" expression="getXmlData('message', '//Message/Body/SITENAME')" />
        <variable name="StockOutToOEM" messageType="org.jdom.Document"></variable>
    </variables>
    <sequence>
        <receive name="MakePreScrap" bounds="178,30,144,62">
            <input variable="message" type="org.jdom.Document" />
        </receive>
        <invoke name="TransactionUtil beginTransaction" type="invokebean" description="public void beginTransaction()" bounds="171,122,158,106" partnerLink="TransactionUtil" partnerLinkType="TransactionUtil" operation="beginTransaction" operationDesc="public void beginTransaction()" ignoreThrow="false" fork="false">
            <source idx="0" terminal="5,A" />
        </invoke>
        <invoke name="MaterialPackingStockInImpl checkReceiveactState" type="invokebean" description="public void checkReceiveactState(java.lang.String receiveActNo)" bounds="180,258,141,105" partnerLink="MaterialPackingStockInImpl" partnerLinkType="MaterialPackingStockInImpl" operation="checkReceiveactState" operationDesc="public void checkReceiveactState(java.lang.String receiveActNo)" ignoreThrow="false" fork="false">
            <source idx="0" terminal="5,A" />
            <input variable="receiveActNo" type="java.lang.String" />
        </invoke>
        <invoke name="CommonValidation GetMessageID" type="invokebean" description="public java.lang.String GetMessageID(java.lang.String sitename)" bounds="180,393,141,105" partnerLink="CommonValidation" partnerLinkType="CommonValidation" operation="GetMessageID" operationDesc="public java.lang.String GetMessageID(java.lang.String sitename)" ignoreThrow="false" fork="false">
            <source idx="0" terminal="5,A" />
            <input variable="siteName" type="java.lang.String" />
            <output variable="messageID" />
        </invoke>
        <invoke name="TransactionUtil commitTransaction" type="invokebean" description="public void commitTransaction()" bounds="180,528,141,105" partnerLink="TransactionUtil" partnerLinkType="TransactionUtil" operation="commitTransaction" operationDesc="public void commitTransaction()" ignoreThrow="false" fork="false">
            <source idx="0" terminal="5,A" />
        </invoke>
        <invoke name="TransactionUtil beginTransaction" type="invokebean" description="public void beginTransaction()" bounds="180,663,141,105" partnerLink="TransactionUtil" partnerLinkType="TransactionUtil" operation="beginTransaction" operationDesc="public void beginTransaction()" ignoreThrow="false" fork="false">
            <source idx="0" terminal="5,A" />
        </invoke>
        <invoke name="EventInfoUtil makeEventInfo" type="invokebean" description="public static com.cim.idm.framework.data.EventInfo makeEventInfo(java.lang.String eventName, java.lang.String eventUser, java.lang.String eventComment, java.lang.String reasonCodeType, java.lang.String reasonCode)" bounds="180,798,141,105" partnerLink="EventInfoUtil" partnerLinkType="EventInfoUtil" operation="makeEventInfo" operationDesc="public static com.cim.idm.framework.data.EventInfo makeEventInfo(java.lang.String eventName, java.lang.String eventUser, java.lang.String eventComment, java.lang.String reasonCodeType, java.lang.String reasonCode)" ignoreThrow="false" fork="false">
            <source idx="0" terminal="5,A" />
            <input constant="MakeMaterialPreScraped" type="java.lang.String" />
            <input variable="eventUser" type="java.lang.String" />
            <input variable="eventComment" type="java.lang.String" />
            <input variable="reasonCodeType" type="java.lang.String" />
            <input variable="reasonCode" type="java.lang.String" />
            <output variable="eventInfo" />
        </invoke>
        <invoke name="MaterialPackingServiceUtil getPackingListFromShipRequest" type="invokebean" description="public java.util.List getPackingListFromShipRequest(java.lang.String invoiceNo, java.lang.String receiveActNo)" bounds="180,933,141,105" partnerLink="MaterialPackingServiceUtil" partnerLinkType="MaterialPackingServiceUtil" operation="getPackingListFromShipRequest" operationDesc="public java.util.List getPackingListFromShipRequest(java.lang.String invoiceNo, java.lang.String receiveActNo)" ignoreThrow="false" fork="false">
            <source idx="0" terminal="5,A" />
            <input variable="shipRequestName" type="java.lang.String" />
            <input variable="receiveActNo" type="java.lang.String" />
            <output variable="boxList" />
        </invoke>
        <invoke name="MaterialPackingServiceImpl PreScrapSEQ" type="invokebean" description="public void PreScrapSEQ(java.util.List materialPackingKeyList, java.lang.String siteName, java.lang.String receiveActNo, java.lang.String receiveRequestName, com.cim.idm.framework.data.EventInfo eventInfo, java.lang.String erpLocation, java.lang.String factoryName)" bounds="180,1068,141,105" partnerLink="MaterialPackingServiceImpl" partnerLinkType="MaterialPackingServiceImpl" operation="PreScrapSEQ" operationDesc="public void PreScrapSEQ(java.util.List materialPackingKeyList, java.lang.String siteName, java.lang.String receiveActNo, java.lang.String receiveRequestName, com.cim.idm.framework.data.EventInfo eventInfo, java.lang.String erpLocation, java.lang.String factoryName)" ignoreThrow="false" fork="false">
            <source idx="0" terminal="5,A" />
            <input variable="boxList" type="java.util.List" />
            <input variable="siteName" type="java.lang.String" />
            <input variable="receiveActNo" type="java.lang.String" />
            <input variable="shipRequestName" type="java.lang.String" />
            <input variable="eventInfo" type="com.cim.idm.framework.data.EventInfo" />
            <input variable="erpLocation" type="java.lang.String" />
            <input variable="erpFactory" type="java.lang.String" />
        </invoke>
        <invoke name="ERPInterfaceServiceImpl PreScrapForERPAccount" type="invokebean" description="public static java.util.List PreScrapForERPAccount(com.cim.idm.framework.data.EventInfo eventInfo, java.lang.String erpEventTime, java.lang.String shipType, java.lang.String reasonCode, java.lang.String messageID, java.lang.String receiveActNO)" bounds="180,1203,141,105" partnerLink="ERPInterfaceServiceImpl" partnerLinkType="ERPInterfaceServiceImpl" operation="PreScrapForERPAccount" operationDesc="public static java.util.List PreScrapForERPAccount(com.cim.idm.framework.data.EventInfo eventInfo, java.lang.String erpEventTime, java.lang.String shipType, java.lang.String reasonCode, java.lang.String messageID, java.lang.String receiveActNO)" ignoreThrow="false" fork="false">
            <source idx="0" terminal="5,A" />
            <input variable="eventInfo" type="com.cim.idm.framework.data.EventInfo" />
            <input variable="erpEventTime" type="java.lang.String" />
            <input variable="shipType" type="java.lang.String" />
            <input variable="reasonCode" type="java.lang.String" />
            <input variable="messageID" type="java.lang.String" />
            <input variable="receiveActNo" type="java.lang.String" />
            <output variable="newUnDoList" />
        </invoke>
        <invoke name="TransactionUtil commitTransaction" type="invokebean" description="public void commitTransaction()" bounds="169,1338,162,103" partnerLink="TransactionUtil" partnerLinkType="TransactionUtil" operation="commitTransaction" operationDesc="public void commitTransaction()" ignoreThrow="false" fork="false">
            <source idx="0" terminal="5,A" />
        </invoke>
        <switch name="switch" bounds="234,1471,33,33" type="switch">
            <source idx="0" terminal="5,A" />
            <switchstart name="switchstart" type="switchstart" bounds="195,1550,110,49">
                <source idx="0" terminal="5,A" />
            </switchstart>
            <case name="case" type="case" condition="getListSize('newUnDoList') &gt; 0" bounds="114,1629,57,47">
                <source idx="0" terminal="5,A" />
                <invoke name="TransactionUtil beginTransaction" type="invokebean" description="public void beginTransaction()" bounds="63,1706,158,106" partnerLink="TransactionUtil" partnerLinkType="TransactionUtil" operation="beginTransaction" operationDesc="public void beginTransaction()" ignoreThrow="false" fork="false">
                    <source idx="0" terminal="5,A" />
                </invoke>
                <invoke name="MaterialPackingServiceImpl insertScrappedInfo" type="invokebean" description="public void insertScrappedInfo(java.util.List materialUnDoinfoList, com.cim.idm.framework.data.EventInfo eventInfo, java.lang.String receiveActNo)" bounds="72,1842,141,105" partnerLink="MaterialPackingServiceImpl" partnerLinkType="MaterialPackingServiceImpl" operation="insertScrappedInfo" operationDesc="public void insertScrappedInfo(java.util.List materialUnDoinfoList, com.cim.idm.framework.data.EventInfo eventInfo, java.lang.String receiveActNo)" ignoreThrow="false" fork="false">
                    <source idx="0" terminal="5,A" />
                    <input variable="newUnDoList" type="java.util.List" />
                    <input variable="eventInfo" type="com.cim.idm.framework.data.EventInfo" />
                    <input variable="receiveActNo" type="java.lang.String" />
                </invoke>
                <invoke name="ESBService sendReplyBySender" type="invokebean" description="public void sendReplyBySender(java.lang.String replySubject, org.jdom.Document doc, java.lang.String senderName)" bounds="72,1977,141,105" partnerLink="ESBService" partnerLinkType="ESBService" operation="sendReplyBySender" operationDesc="public void sendReplyBySender(java.lang.String replySubject, org.jdom.Document doc, java.lang.String senderName)" ignoreThrow="false" fork="false">
                    <source idx="0" terminal="5,A" />
                    <input variable="replySubjectName" type="java.lang.String" />
                    <input variable="message" type="org.jdom.Document" />
                    <input constant="PDASender" type="java.lang.String" />
                </invoke>
                <invoke name="TransactionUtil commitTransaction" type="invokebean" description="public void commitTransaction()" bounds="61,2112,162,103" partnerLink="TransactionUtil" partnerLinkType="TransactionUtil" operation="commitTransaction" operationDesc="public void commitTransaction()" ignoreThrow="false" fork="false">
                    <source idx="0" terminal="5,A" />
                </invoke>
            </case>
            <otherwise name="otherwise" type="otherwise" bounds="313,1629,92,50">
                <source idx="0" terminal="5,A" />
                <invoke name="ESBService sendReplyBySender" type="invokebean" description="public void sendReplyBySender(java.lang.String replySubject, org.jdom.Document doc, java.lang.String senderName, java.lang.String resultCode, java.lang.String resultMessage)" bounds="281,1755,141,105" partnerLink="ESBService" partnerLinkType="ESBService" operation="sendReplyBySender" operationDesc="public void sendReplyBySender(java.lang.String replySubject, org.jdom.Document doc, java.lang.String senderName, java.lang.String resultCode, java.lang.String resultMessage)" ignoreThrow="false" fork="false">
                    <source idx="0" terminal="5,A" />
                    <input variable="replysubjectname" type="java.lang.String" />
                    <input variable="message" type="org.jdom.Document" />
                    <input constant="PDASender" type="java.lang.String" />
                    <input constant="E" type="java.lang.String" />
                    <input constant="ERP&#x8fc7;&#x8d26;³¬&#x65f6;" type="java.lang.String" />
                </invoke>
                <terminate name="terminate" bounds="286,1890,141,65">
                    <source idx="0" terminal="5,A" />
                </terminate>
            </otherwise>
        </switch>
    </sequence>
</process>

