<%@ page extends="oneit.servlets.process.AJAXProcessJSP" %>

<%@ page import="oneit.servlets.jsp.*,oneit.servlets.orm.*,oneit.servlets.objstore.*,oneit.servlets.jsp.tabs.*,oneit.logging.*,oneit.sql.*,oneit.objstore.services.*" %>
<%@ page import="performa.orm.*,performa.orm.types.*,performa.utils.*, java.util.*, oneit.objstore.*, oneit.servlets.process.*, oneit.utils.*" %>
<%@ page import="oneit.utils.filter.Filter, oneit.objstore.rdbms.filters.EqualsFilter" %>

<%@ include file="../../../setuprequest.jsp" %>

<%! protected String getName (ServletConfig config) { return "save_own_billing_jsp"; } %>
<oneit:form method="POST">
<%
    ORMProcessState     process         =   (ORMProcessState)ProcessDecorator.getDefaultProcess(request);
    ObjectTransaction   objTran         =   ObjectTransaction.getTransaction();
    Long                hiringTeamID    =   Long.valueOf(request.getParameter ("hiringTeamID"));
    boolean             ownBilling      =   Boolean.valueOf(request.getParameter ("ownBilling"));
    HiringTeam          hiringTeam      =   HiringTeam.getHiringTeamByID(objTran, hiringTeamID);

    hiringTeam.setManageOwnBilling(ownBilling);

    if(ownBilling)
    {
        hiringTeam.setBilledByTeam(null);
    }
%>
</oneit:form>