<?xml version="1.0" encoding="UTF-8"?>

<ROOT xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:noNamespaceSchemaLocation='http://www.oneit.com.au/schemas/5.2/BusinessObject.xsd'>

    <BUSINESSCLASS  name="WorkFlowTemplate"   package="performa.orm">
        <IMPORT value="performa.orm.types.*"/>
                
        <MULTIPLEREFERENCE  name="WorkFlowStages"       type="WorkFlowStage"        backreferenceName="WorkFlowTemplate" />
        <MULTIPLEREFERENCE  name="Jobs"                 type="Job"                  backreferenceName="WorkFlowTemplate" />
        
        <TABLE  name="tl_work_flow_template"    tablePrefix="object"    polymorphic="FALSE">
            
            <ATTRIB name="TemplateName"                 type="String"           dbcol="template_name"                   mandatory="true"/>
            <ATTRIB name="LandingButtonText"            type="String"           dbcol="landing_button_text"             mandatory="false"       defaultValue='"Apply Now"'/>
            <ATTRIB name="VerificationHeaderText"       type="String"           dbcol="verification_header_text"        mandatory="false"       defaultValue='"Please verify your identity before applying to&#58;"'/>
            <ATTRIB name="CaptureCV"                    type="Boolean"          dbcol="capture_cv"                      mandatory="false"       defaultValue="Boolean.TRUE"/>
            <ATTRIB name="IsCVMandatory"                type="Boolean"          dbcol="is_cv_mandatory"                 mandatory="false"       defaultValue="Boolean.TRUE"/>
            <ATTRIB name="CaptureCL"                    type="Boolean"          dbcol="capture_cl"                      mandatory="false"       defaultValue="Boolean.TRUE"/>
            <ATTRIB name="IsCLMandatory"                type="Boolean"          dbcol="is_cl_mandatory"                 mandatory="false"       defaultValue="Boolean.TRUE"/>
            <ATTRIB name="ApplicationButtonText"        type="String"           dbcol="application_button_text"         mandatory="false"       defaultValue='"Submit"'/>
            <ATTRIB name="ApplicationResponseAction"    type="ResponseAction"   dbcol="application_response_action"     attribHelper="EnumeratedAttributeHelper"        mandatory="true"  defaultValue="ResponseAction.EMAIL_RESPONSE"/>
            <ATTRIB name="ThankYouHeaderText"           type="String"           dbcol="thank_you_header_text"           mandatory="false"       defaultValue='"Thank You for your application to&#58;"'/>
            <ATTRIB name="ThankYouSecondaryText"        type="String"           dbcol="thank_you_secondary_text"        mandatory="false"       defaultValue='"We will get in touch with you soon"'/>
            <ATTRIB name="JobOutlineButtonText"         type="String"           dbcol="job_outline_button_text"         mandatory="false"       defaultValue='"Continue"'/>
            <ATTRIB name="RelatedToJob"                 type="Boolean"          dbcol="related_to_job"                  mandatory="false"       defaultValue="Boolean.FALSE"/>
            <ATTRIB name="IsSystemGenerated"            type="Boolean"          dbcol="is_system_generated"             mandatory="false"       defaultValue="Boolean.FALSE"/>
            
            <SINGLEREFERENCE    name="WithdrawalMessage"        type="WorkFlowMessage"      dbcol="withdrawal_message_id"  />
            <SINGLEREFERENCE    name="HiringTeam"               type="HiringTeam"           dbcol="hiring_team_id"          backreferenceName="WorkFlowTemplates"    mandatory="false"/>

        </TABLE>
        
        <SEARCH type="All"  paramFilter="tl_work_flow_template.object_id is not null"   orderBy="tl_work_flow_template.object_id"   />
            
    </BUSINESSCLASS>
    
</ROOT>