<%@ page extends="oneit.servlets.jsp.JSPInclude" %>
<%@ include file="/inc/stdimports50.jsp" %><%-- This is in cougar --%>
<%@ include file="/inc/stdcms.jsp" %><%-- This is in cougar --%>
<%@ include file="../../inc/std_imports.jsp" %>

<oneit:dynIncluded>
<%
    ObjectTransaction   objTran = (process == null ? ObjectTransaction.getTransaction () : process.getTransaction ());
    Job                 job     = (Job) process.getAttribute("Job");

    String  firstPage   = HTTPRequestDetails.getFullURL(WebUtils.getSamePageInRenderMode(request, "Page"), ProcessDecorator.getRequestParameters(request, new String[0]), "");
    String  secondPage  = HTTPRequestDetails.getFullURL(WebUtils.getSamePageInRenderMode(request, PerformaArticleUtil.ASSESSMENT_CRITERIA), ProcessDecorator.getRequestParameters(request, new String[0]), "");
    String  fourthPage  = HTTPRequestDetails.getFullURL(WebUtils.getSamePageInRenderMode(request, PerformaArticleUtil.JOB_MATCH), ProcessDecorator.getRequestParameters(request, new String[0]), "");
    String  fifthPage   = HTTPRequestDetails.getFullURL(WebUtils.getSamePageInRenderMode(request, PerformaArticleUtil.JOB_REVIEW), ProcessDecorator.getRequestParameters(request, new String[0]), "");
%>
    <oneit:form name="editJob" method="post" enctype="multipart/form-data" action="<%= fourthPage %>">
    
        <div class="container-fluid">
            <h1 class="page-title">Create a job <span class="active-time">(Active for 30 days)</span> </h1>
            <div class="main-tab-form">
                <ul class="nav nav-pills nav-justified">
                    <li class="<%= job.jobDetailsCompleted() ? "complate" : ""%>">
                        <a href="<%= firstPage %>"><span><%= job.jobDetailsCompleted() ? "<img src=\"images/right-mark.png\" />" : "1"%></span>
                            Job Detail
                        </a>
                    </li>
                    <li class="<%= job.assessmentCompleted() ? "complate" : ""%>">
                        <a href="<%= secondPage %>"><span><%= job.assessmentCompleted() ? "<img src=\"images/right-mark.png\" />" : "2"%></span>
                            Assessment Criteria
                        </a>
                    </li>
                    <li class="active">
                        <a href="#"><span><%= job.cultureCompleted() ? "<img src=\"images/right-mark.png\" />" : "3"%></span>
                            Workplace Culture
                        </a>
                    </li>
                    <li class="<%= job.jobMatchCompleted() ? "complate" : ""%>">
                        <a href="<%= fourthPage %>"><span><%= job.jobMatchCompleted() ? "<img src=\"images/right-mark.png\" />" : "3"%></span>
                            Job Match Assessment
                        </a>
                    </li>
                    <li>
                        <a href="<%= fifthPage %>"><span>5</span>
                            Review and Submit
                        </a>
                    </li>
                </ul>
            </div>
            <div class="form-page-area">
                <div class="create-job">
                    <div class="assessment-criteria">
                        <div class="form-group">
                            <label class="label-16 work-title">Workplace Culture</label>
                            <p>
                              Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipit lobortis nisl ut aliquip ex ea commodo consequat. Duis autem vel eum iriure dolor in hendrerit.
                            </p>      
                        </div>
                        <div class="form-group">
                            <select class="form-control">
                                <option>Optional: Select previously defined Workplace Culture</option>
                                <option>One 1</option>
                                <option>One 2</option>
                                <option>One 3</option>
                          </select>              
                        </div>              
                        <div class="form-brack-line-sub"></div> 
                        <%
                            for(CultureClass culture : CultureClass.getCultureClassArray())
                            {
                        %>
                                <div class="form-group">
                                    <div class="work-belonging">
                                        <oneit:toString value="<%= culture %>" mode="EscapeHTML"/>
                                    </div>
                                    <%
                                        for(CultureElement element : CultureElement.SearchByAll().andCultureClass(new EqualsFilter<>(culture)).search(objTran))
                                        {
                                    %>
                                            <div class="work-radio-title">
                                                <oneit:toString value="<%= element.getDescription() %>" mode="EscapeHTML"/>
                                            </div>
                                            <div class="radio radio-primary workplace-radio">
                                                <input type="radio" name="radio" id="radio11" value="option1" checked>
                                                <label for="radio11">
                                                    Teamwork is vital
                                                </label>
                                            </div>
                                            <div class="work-rating">
                                                <div class="rate-background">
                                                    <span class="arrow-up-gray"></span>
                                                    <span class="rate-label">Rate Importance</span>
                                                    <span class="rate-toggle">
                                                        <ul class="nav nav-pills nav-justified">
                                                            <li><a href="javascript:void(0)">Not Applicable</a></li>
                                                            <li class="active"><a href="javascript:void(0)">Desirable</a></li>
                                                            <li><a href="javascript:void(0)">Highly Desirable</a></li>
                                                            <li><a href="javascript:void(0)">Essential</a></li>
                                                        </ul>
                                                    </span>                      
                                                </div>
                                            </div>
                                            <div class="radio radio-primary workplace-radio">
                                                <input type="radio" name="radio" id="radio12" value="option1" checked="">
                                                <label for="radio12">
                                                    Some teamwork is involved
                                                </label>
                                            </div>
                                            <div class="radio radio-primary workplace-radio margin-bottom-none">
                                                <input type="radio" name="radio" id="radio13" value="option1" checked="">
                                                <label for="radio13">
                                                    Little teamwork is neeeded
                                                </label>
                                            </div>
                                    <%
                                        }
                                    %>
                                </div>
                                <div class="form-brack-line-sub"></div>
                        <%
                            }
                        %>
                        <div class="form-group">
                            <div class="save-assess">
                                <div class="checkbox checkbox-primary">
                                    <input id="checkbox2" type="checkbox" checked>
                                    <label for="checkbox2">
                                      Save this Assessment Criteria as a template
                                    </label>
                                </div>
                            </div>
                        </div>
                        <div class="form-group">
                            <div class="input-group input-group-lg">                    
                                <div class="icon-addon addon-lg">
                                    <input type="text" placeholder="Template Name" class="form-control" id="email">
                                </div>
                                <span class="input-group-btn">
                                    <button class="btn btn-primary" type="button">SAVE</button>
                                </span>
                            </div>
                        </div>
                        <div class="text-center">
                            <input type="button" class="btn btn-primary top-margin-25" value="Proceed to Job Match" />
                        </div>
                    </div>
                </div>
            </div>                                    
        </div>
    </oneit:form>
</oneit:dynIncluded>