Commit 4ab4a41c by nilu

Merged 'develop'.

parents 204aa0d2 c5958847
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
<column name="object_created_date" type="Date" nullable="false" length="22"/> <column name="object_created_date" type="Date" nullable="false" length="22"/>
<column name="client_name" type="String" nullable="false" length="30"/> <column name="client_name" type="String" nullable="false" length="30"/>
<column name="client_logo" type="BLOB" nullable="true"/> <column name="client_logo" type="BLOB" nullable="true"/>
<column name="use_client_details" type="Boolean" nullable="true"/>
<column name="email" type="String" nullable="true" length="100"/> <column name="email" type="String" nullable="true" length="100"/>
<column name="contact_name" type="String" nullable="true" length="100"/> <column name="contact_name" type="String" nullable="true" length="100"/>
<column name="contact_surname" type="String" nullable="true" length="100"/> <column name="contact_surname" type="String" nullable="true" length="100"/>
......
...@@ -14,6 +14,7 @@ ...@@ -14,6 +14,7 @@
<column name="open_date" type="Date" nullable="true"/> <column name="open_date" type="Date" nullable="true"/>
<column name="apply_by" type="Date" nullable="true"/> <column name="apply_by" type="Date" nullable="true"/>
<column name="include_assessment_criteria" type="Boolean" nullable="false"/> <column name="include_assessment_criteria" type="Boolean" nullable="false"/>
<column name="include_culture" type="Boolean" nullable="false"/>
<column name="assessment_type" type="String" nullable="false" length="200"/> <column name="assessment_type" type="String" nullable="false" length="200"/>
<column name="random_key" type="String" nullable="true" length="10"/> <column name="random_key" type="String" nullable="true" length="10"/>
<column name="job_type" type="String" nullable="false" length="200"/> <column name="job_type" type="String" nullable="false" length="200"/>
......
...@@ -12,7 +12,9 @@ ...@@ -12,7 +12,9 @@
<column name="name" type="String" nullable="false" length="250"/> <column name="name" type="String" nullable="false" length="250"/>
<column name="level" type="String" nullable="false" length="200"/> <column name="level" type="String" nullable="false" length="200"/>
<column name="assessment_type" type="String" nullable="true" length="200"/> <column name="assessment_type" type="String" nullable="true" length="200"/>
<column name="parttime_assessment_type" type="String" nullable="true" length="200"/>
<column name="assessment_level_id" type="Long" length="11" nullable="true"/> <column name="assessment_level_id" type="Long" length="11" nullable="true"/>
<column name="express_assessment_level_id" type="Long" length="11" nullable="true"/>
<column name="parent_occupation_id" type="Long" length="11" nullable="true"/> <column name="parent_occupation_id" type="Long" length="11" nullable="true"/>
</NODE> </NODE>
......
...@@ -10,6 +10,7 @@ CREATE TABLE tl_client ( ...@@ -10,6 +10,7 @@ CREATE TABLE tl_client (
, ,
client_name varchar(30) NOT NULL, client_name varchar(30) NOT NULL,
client_logo image NULL, client_logo image NULL,
use_client_details char(1) NULL,
email varchar(100) NULL, email varchar(100) NULL,
contact_name varchar(100) NULL, contact_name varchar(100) NULL,
contact_surname varchar(100) NULL, contact_surname varchar(100) NULL,
......
...@@ -14,6 +14,7 @@ CREATE TABLE tl_job ( ...@@ -14,6 +14,7 @@ CREATE TABLE tl_job (
open_date datetime NULL, open_date datetime NULL,
apply_by datetime NULL, apply_by datetime NULL,
include_assessment_criteria char(1) NOT NULL, include_assessment_criteria char(1) NOT NULL,
include_culture char(1) NOT NULL,
assessment_type varchar(200) NOT NULL, assessment_type varchar(200) NOT NULL,
random_key varchar(10) NULL, random_key varchar(10) NULL,
job_type varchar(200) NOT NULL, job_type varchar(200) NOT NULL,
......
...@@ -12,7 +12,9 @@ CREATE TABLE tl_occupation ( ...@@ -12,7 +12,9 @@ CREATE TABLE tl_occupation (
name varchar(250) NOT NULL, name varchar(250) NOT NULL,
level varchar(200) NOT NULL, level varchar(200) NOT NULL,
assessment_type varchar(200) NULL, assessment_type varchar(200) NULL,
parttime_assessment_type varchar(200) NULL,
assessment_level_id numeric(12) NULL, assessment_level_id numeric(12) NULL,
express_assessment_level_id numeric(12) NULL,
parent_occupation_id numeric(12) NULL parent_occupation_id numeric(12) NULL
); );
......
...@@ -11,6 +11,7 @@ CREATE TABLE tl_client ( ...@@ -11,6 +11,7 @@ CREATE TABLE tl_client (
, ,
client_name varchar2(30) NOT NULL, client_name varchar2(30) NOT NULL,
client_logo blob NULL, client_logo blob NULL,
use_client_details char(1) NULL,
email varchar2(100) NULL, email varchar2(100) NULL,
contact_name varchar2(100) NULL, contact_name varchar2(100) NULL,
contact_surname varchar2(100) NULL, contact_surname varchar2(100) NULL,
......
...@@ -15,6 +15,7 @@ CREATE TABLE tl_job ( ...@@ -15,6 +15,7 @@ CREATE TABLE tl_job (
open_date date NULL, open_date date NULL,
apply_by date NULL, apply_by date NULL,
include_assessment_criteria char(1) NOT NULL, include_assessment_criteria char(1) NOT NULL,
include_culture char(1) NOT NULL,
assessment_type varchar2(200) NOT NULL, assessment_type varchar2(200) NOT NULL,
random_key varchar2(10) NULL, random_key varchar2(10) NULL,
job_type varchar2(200) NOT NULL, job_type varchar2(200) NOT NULL,
......
...@@ -13,7 +13,9 @@ CREATE TABLE tl_occupation ( ...@@ -13,7 +13,9 @@ CREATE TABLE tl_occupation (
name varchar2(250) NOT NULL, name varchar2(250) NOT NULL,
level varchar2(200) NOT NULL, level varchar2(200) NOT NULL,
assessment_type varchar2(200) NULL, assessment_type varchar2(200) NULL,
parttime_assessment_type varchar2(200) NULL,
assessment_level_id number(12) NULL, assessment_level_id number(12) NULL,
express_assessment_level_id number(12) NULL,
parent_occupation_id number(12) NULL parent_occupation_id number(12) NULL
); );
......
...@@ -11,6 +11,7 @@ CREATE TABLE tl_client ( ...@@ -11,6 +11,7 @@ CREATE TABLE tl_client (
, ,
client_name varchar(30) NOT NULL, client_name varchar(30) NOT NULL,
client_logo bytea NULL, client_logo bytea NULL,
use_client_details char(1) NULL,
email varchar(100) NULL, email varchar(100) NULL,
contact_name varchar(100) NULL, contact_name varchar(100) NULL,
contact_surname varchar(100) NULL, contact_surname varchar(100) NULL,
......
...@@ -15,6 +15,7 @@ CREATE TABLE tl_job ( ...@@ -15,6 +15,7 @@ CREATE TABLE tl_job (
open_date timestamp NULL, open_date timestamp NULL,
apply_by timestamp NULL, apply_by timestamp NULL,
include_assessment_criteria char(1) NOT NULL, include_assessment_criteria char(1) NOT NULL,
include_culture char(1) NOT NULL,
assessment_type varchar(200) NOT NULL, assessment_type varchar(200) NOT NULL,
random_key varchar(10) NULL, random_key varchar(10) NULL,
job_type varchar(200) NOT NULL, job_type varchar(200) NOT NULL,
......
...@@ -13,7 +13,9 @@ CREATE TABLE tl_occupation ( ...@@ -13,7 +13,9 @@ CREATE TABLE tl_occupation (
name varchar(250) NOT NULL, name varchar(250) NOT NULL,
level varchar(200) NOT NULL, level varchar(200) NOT NULL,
assessment_type varchar(200) NULL, assessment_type varchar(200) NULL,
parttime_assessment_type varchar(200) NULL,
assessment_level_id numeric(12) NULL, assessment_level_id numeric(12) NULL,
express_assessment_level_id numeric(12) NULL,
parent_occupation_id numeric(12) NULL parent_occupation_id numeric(12) NULL
); );
......
...@@ -15,7 +15,7 @@ import oneit.utils.CollectionUtils; ...@@ -15,7 +15,7 @@ import oneit.utils.CollectionUtils;
import oneit.utils.RandomStringGen; import oneit.utils.RandomStringGen;
import performa.orm.JobApplication; import performa.orm.JobApplication;
import performa.orm.WorkFlow; import performa.orm.WorkFlow;
import performa.orm.types.ApplicationStatus; import performa.orm.types.AppView;
import performa.utils.PDFUtils; import performa.utils.PDFUtils;
...@@ -30,7 +30,7 @@ public class ApplicantReportFP extends ORMProcessFormProcessor ...@@ -30,7 +30,7 @@ public class ApplicantReportFP extends ORMProcessFormProcessor
HttpServletRequest request = submission.getRequest(); HttpServletRequest request = submission.getRequest();
RandomStringGen rand = new RandomStringGen(); RandomStringGen rand = new RandomStringGen();
final String randFileName = rand.generateAlphaNum(16) + ".pdf"; final String randFileName = rand.generateAlphaNum(16) + ".pdf";
boolean showList = (boolean) request.getAttribute("ShowList"); AppView appView = (AppView) request.getAttribute("AppView");
boolean detailed = (boolean) request.getAttribute("Detailed"); boolean detailed = (boolean) request.getAttribute("Detailed");
boolean applicantPage = (boolean) request.getAttribute("ApplicantPage"); boolean applicantPage = (boolean) request.getAttribute("ApplicantPage");
WorkFlow workflow = (WorkFlow) request.getAttribute("WorkFlow"); WorkFlow workflow = (WorkFlow) request.getAttribute("WorkFlow");
...@@ -49,7 +49,7 @@ public class ApplicantReportFP extends ORMProcessFormProcessor ...@@ -49,7 +49,7 @@ public class ApplicantReportFP extends ORMProcessFormProcessor
.mapEntry("WorkFlow", workflow) .mapEntry("WorkFlow", workflow)
.toMap(); .toMap();
if(CollectionUtils.equals(showList, true)) if(appView == AppView.LIST)
{ {
pdfBytes = PDFUtils.generateApplicantsListPDF(submission, data); pdfBytes = PDFUtils.generateApplicantsListPDF(submission, data);
} }
......
package performa.form;
import java.util.Map;
import javax.servlet.http.HttpServletRequest;
import oneit.logging.*;
import oneit.objstore.ObjectTransaction;
import oneit.objstore.StorageException;
import oneit.servlets.forms.*;
import oneit.servlets.process.*;
import oneit.utils.BusinessException;
import performa.orm.*;
public class ChangeCultureCriteriaFP extends ORMProcessFormProcessor
{
@Override
public SuccessfulResult processForm(ORMProcessState process, SubmissionDetails submission, Map params) throws BusinessException, StorageException
{
HttpServletRequest request = submission.getRequest();
ObjectTransaction objTran = process.getTransaction();
Job job = (Job) request.getAttribute("Job");
LogMgr.log(Job.LOG, LogLevel.PROCESSING1, "Inside ChangeCultureCriteriaFP for ", job , " Include Culture:", job.getIncludeCulture());
if(!job.isTrue(job.getIncludeCulture()))
{
for(CultureCriteria cultureCriteria : job.getCultureCriteriasSet())
{
cultureCriteria.delete();
}
job.setSaveCultureTemplate(false);
job.setCultureTemplate(null);
}
else
{
for(CultureElement cultureElement : CultureElement.searchAll(objTran))
{
CultureCriteria cultureCriteria = CultureCriteria.createCultureCriteria(objTran);
cultureCriteria.setCultureElement(cultureElement);
job.addToCultureCriterias(cultureCriteria);
}
}
LogMgr.log(Job.LOG, LogLevel.PROCESSING1, "ChangeCultureCriteriaFP completed for ", job);
return RedisplayResult.getInstance();
}
}
...@@ -14,6 +14,7 @@ import oneit.utils.filter.Filter; ...@@ -14,6 +14,7 @@ import oneit.utils.filter.Filter;
import oneit.utils.parsers.FieldException; import oneit.utils.parsers.FieldException;
import performa.orm.types.AssessmentType; import performa.orm.types.AssessmentType;
import performa.orm.types.CriteriaType; import performa.orm.types.CriteriaType;
import performa.orm.types.JobType;
public class AssessmentCriteriaTemplate extends BaseAssessmentCriteriaTemplate public class AssessmentCriteriaTemplate extends BaseAssessmentCriteriaTemplate
...@@ -102,13 +103,57 @@ public class AssessmentCriteriaTemplate extends BaseAssessmentCriteriaTemplate ...@@ -102,13 +103,57 @@ public class AssessmentCriteriaTemplate extends BaseAssessmentCriteriaTemplate
if(occupation != null) if(occupation != null)
{ {
setOccupation(occupation); setOccupation(occupation);
setLevel(occupation.getAssessmentLevel()); setSuggestedAssessmentType(getJobType() == JobType.FULL_TIME ? occupation.getAssessmentType() : occupation.getPartTimeAssessmentType());
setAssessmentType(occupation.getAssessmentType()); setAssessmentType(getJobType() == JobType.FULL_TIME ? occupation.getAssessmentType() : occupation.getPartTimeAssessmentType());
setLevel(getAssessmentType() == AssessmentType.COMPREHENSIVE ? occupation.getAssessmentLevel() : occupation.getExpressAssessmentLevel());
} }
super.postILOJobTitleChange(); super.postILOJobTitleChange();
} }
@Override
protected void postJobTypeChange() throws FieldException
{
Occupation occupation = getILOJobTitle() != null ? getILOJobTitle().getOccupation() : null;
if(occupation != null)
{
setSuggestedAssessmentType(getJobType() == JobType.FULL_TIME ? occupation.getAssessmentType() : occupation.getPartTimeAssessmentType());
setAssessmentType(getJobType() == JobType.FULL_TIME ? occupation.getAssessmentType() : occupation.getPartTimeAssessmentType());
setLevel(getAssessmentType() == AssessmentType.COMPREHENSIVE ? occupation.getAssessmentLevel() : occupation.getExpressAssessmentLevel());
}
super.postJobTypeChange();
}
@Override
public AssessmentType getSuggestedAssessmentType()
{
Occupation occupation = getILOJobTitle() != null ? getILOJobTitle().getOccupation() : null;
if(occupation != null)
{
return getJobType() == JobType.FULL_TIME ? occupation.getAssessmentType() : occupation.getPartTimeAssessmentType();
}
return super.getSuggestedAssessmentType();
}
@Override
protected void postAssessmentTypeChange() throws FieldException
{
Occupation occupation = getILOJobTitle() != null ? getILOJobTitle().getOccupation() : null;
if(occupation != null && getSuggestedAssessmentType() != super.getAssessmentType())
{
setLevel(getAssessmentType() == AssessmentType.COMPREHENSIVE ? occupation.getAssessmentLevel() : occupation.getExpressAssessmentLevel());
}
super.postAssessmentTypeChange();
}
public Occupation displayOccupation() public Occupation displayOccupation()
{ {
return getOccupation(); return getOccupation();
......
...@@ -7,6 +7,8 @@ ...@@ -7,6 +7,8 @@
<IMPORT value="performa.orm.types.*"/> <IMPORT value="performa.orm.types.*"/>
<IMPORT value="oneit.security.*"/> <IMPORT value="oneit.security.*"/>
<TRANSIENT name="SuggestedAssessmentType" type="AssessmentType" attribHelper="EnumeratedAttributeHelper"/>
<MULTIPLEREFERENCE name="AssessmentCriterias" type="AssessmentCriteria" backreferenceName="Template" /> <MULTIPLEREFERENCE name="AssessmentCriterias" type="AssessmentCriteria" backreferenceName="Template" />
<MULTIPLEREFERENCE name="WorkFlows" type="WorkFlow" backreferenceName="Template" /> <MULTIPLEREFERENCE name="WorkFlows" type="WorkFlow" backreferenceName="Template" />
......
...@@ -54,6 +54,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -54,6 +54,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
public static final String FIELD_RequireCV = "RequireCV"; public static final String FIELD_RequireCV = "RequireCV";
public static final String FIELD_AssessmentType = "AssessmentType"; public static final String FIELD_AssessmentType = "AssessmentType";
public static final String FIELD_IncludeAssessmentCriteria = "IncludeAssessmentCriteria"; public static final String FIELD_IncludeAssessmentCriteria = "IncludeAssessmentCriteria";
public static final String FIELD_SuggestedAssessmentType = "SuggestedAssessmentType";
public static final String SINGLEREFERENCE_Level = "Level"; public static final String SINGLEREFERENCE_Level = "Level";
public static final String SINGLEREFERENCE_Occupation = "Occupation"; public static final String SINGLEREFERENCE_Occupation = "Occupation";
public static final String SINGLEREFERENCE_JobOwner = "JobOwner"; public static final String SINGLEREFERENCE_JobOwner = "JobOwner";
...@@ -84,6 +85,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -84,6 +85,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
private static final DefaultAttributeHelper<AssessmentCriteriaTemplate> HELPER_RequireCV = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper<AssessmentCriteriaTemplate> HELPER_RequireCV = DefaultAttributeHelper.INSTANCE;
private static final EnumeratedAttributeHelper<AssessmentCriteriaTemplate, AssessmentType> HELPER_AssessmentType = new EnumeratedAttributeHelper<AssessmentCriteriaTemplate, AssessmentType> (AssessmentType.FACTORY_AssessmentType); private static final EnumeratedAttributeHelper<AssessmentCriteriaTemplate, AssessmentType> HELPER_AssessmentType = new EnumeratedAttributeHelper<AssessmentCriteriaTemplate, AssessmentType> (AssessmentType.FACTORY_AssessmentType);
private static final DefaultAttributeHelper<AssessmentCriteriaTemplate> HELPER_IncludeAssessmentCriteria = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper<AssessmentCriteriaTemplate> HELPER_IncludeAssessmentCriteria = DefaultAttributeHelper.INSTANCE;
private static final EnumeratedAttributeHelper<AssessmentCriteriaTemplate, AssessmentType> HELPER_SuggestedAssessmentType = new EnumeratedAttributeHelper<AssessmentCriteriaTemplate, AssessmentType> (AssessmentType.FACTORY_AssessmentType);
// Private attributes corresponding to business object data // Private attributes corresponding to business object data
...@@ -99,6 +101,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -99,6 +101,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
private Boolean _RequireCV; private Boolean _RequireCV;
private AssessmentType _AssessmentType; private AssessmentType _AssessmentType;
private Boolean _IncludeAssessmentCriteria; private Boolean _IncludeAssessmentCriteria;
private AssessmentType _SuggestedAssessmentType;
// Private attributes corresponding to single references // Private attributes corresponding to single references
...@@ -121,6 +124,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -121,6 +124,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
private static final Map ATTRIBUTES_METADATA_AssessmentCriteriaTemplate = new HashMap (); private static final Map ATTRIBUTES_METADATA_AssessmentCriteriaTemplate = new HashMap ();
// Arrays of validators for each attribute // Arrays of validators for each attribute
private static final AttributeValidator[] FIELD_SuggestedAssessmentType_Validators;
private static final AttributeValidator[] FIELD_TemplateName_Validators; private static final AttributeValidator[] FIELD_TemplateName_Validators;
private static final AttributeValidator[] FIELD_JobTitle_Validators; private static final AttributeValidator[] FIELD_JobTitle_Validators;
private static final AttributeValidator[] FIELD_JobDescription_Validators; private static final AttributeValidator[] FIELD_JobDescription_Validators;
...@@ -158,6 +162,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -158,6 +162,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
setupAssocMetaData_HiringTeam(); setupAssocMetaData_HiringTeam();
setupAssocMetaData_CompanyUser(); setupAssocMetaData_CompanyUser();
setupAssocMetaData_ILOJobTitle(); setupAssocMetaData_ILOJobTitle();
FIELD_SuggestedAssessmentType_Validators = (AttributeValidator[])setupAttribMetaData_SuggestedAssessmentType(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_TemplateName_Validators = (AttributeValidator[])setupAttribMetaData_TemplateName(validatorMapping).toArray (new AttributeValidator[0]); FIELD_TemplateName_Validators = (AttributeValidator[])setupAttribMetaData_TemplateName(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_JobTitle_Validators = (AttributeValidator[])setupAttribMetaData_JobTitle(validatorMapping).toArray (new AttributeValidator[0]); FIELD_JobTitle_Validators = (AttributeValidator[])setupAttribMetaData_JobTitle(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_JobDescription_Validators = (AttributeValidator[])setupAttribMetaData_JobDescription(validatorMapping).toArray (new AttributeValidator[0]); FIELD_JobDescription_Validators = (AttributeValidator[])setupAttribMetaData_JobDescription(validatorMapping).toArray (new AttributeValidator[0]);
...@@ -330,6 +335,24 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -330,6 +335,24 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
// Meta Info setup // Meta Info setup
private static List setupAttribMetaData_SuggestedAssessmentType(Map validatorMapping)
{
Map metaInfo = new HashMap ();
metaInfo.put ("attribHelper", "EnumeratedAttributeHelper");
metaInfo.put ("name", "SuggestedAssessmentType");
metaInfo.put ("type", "AssessmentType");
LogMgr.log (BUSINESS_OBJECTS, LogLevel.DEBUG2, "Metadata for AssessmentCriteriaTemplate.SuggestedAssessmentType:", metaInfo);
ATTRIBUTES_METADATA_AssessmentCriteriaTemplate.put (FIELD_SuggestedAssessmentType, Collections.unmodifiableMap (metaInfo));
List validators = BaseBusinessClass.getAttribValidators(AssessmentCriteriaTemplate.class, "SuggestedAssessmentType", metaInfo, validatorMapping);
LogMgr.log (BUSINESS_OBJECTS, LogLevel.DEBUG1, "Validators for AssessmentCriteriaTemplate.SuggestedAssessmentType:", validators);
return validators;
}
// Meta Info setup
private static List setupAttribMetaData_TemplateName(Map validatorMapping) private static List setupAttribMetaData_TemplateName(Map validatorMapping)
{ {
Map metaInfo = new HashMap (); Map metaInfo = new HashMap ();
...@@ -607,6 +630,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -607,6 +630,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
_RequireCV = (Boolean)(Boolean.FALSE); _RequireCV = (Boolean)(Boolean.FALSE);
_AssessmentType = (AssessmentType)(AssessmentType.COMPREHENSIVE); _AssessmentType = (AssessmentType)(AssessmentType.COMPREHENSIVE);
_IncludeAssessmentCriteria = (Boolean)(Boolean.TRUE); _IncludeAssessmentCriteria = (Boolean)(Boolean.TRUE);
_SuggestedAssessmentType = (AssessmentType)(HELPER_SuggestedAssessmentType.initialise (_SuggestedAssessmentType));
} }
...@@ -1835,6 +1859,104 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -1835,6 +1859,104 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
} }
} }
/**
* Get the attribute SuggestedAssessmentType
*/
public AssessmentType getSuggestedAssessmentType ()
{
assertValid();
AssessmentType valToReturn = _SuggestedAssessmentType;
for (AssessmentCriteriaTemplateBehaviourDecorator bhd : AssessmentCriteriaTemplate_BehaviourDecorators)
{
valToReturn = bhd.getSuggestedAssessmentType ((AssessmentCriteriaTemplate)this, valToReturn);
}
return valToReturn;
}
/**
* Called prior to the attribute changing. Subclasses need not call super. If a field exception
* is thrown, the attribute change will fail. The new value is different to the old value.
*/
protected void preSuggestedAssessmentTypeChange (AssessmentType newSuggestedAssessmentType) throws FieldException
{
}
/**
* Called after the attribute changes.
* If a field exception is thrown, the value is still changed, however it
* may lead to the TX being rolled back
*/
protected void postSuggestedAssessmentTypeChange () throws FieldException
{
}
public FieldWriteability getWriteability_SuggestedAssessmentType ()
{
return getFieldWritabilityUtil (FieldWriteability.TRUE);
}
/**
* Set the attribute SuggestedAssessmentType. Checks to ensure a new value
* has been supplied. If so, marks the field as altered and sets the attribute.
*/
public void setSuggestedAssessmentType (AssessmentType newSuggestedAssessmentType) throws FieldException
{
boolean oldAndNewIdentical = HELPER_SuggestedAssessmentType.compare (_SuggestedAssessmentType, newSuggestedAssessmentType);
try
{
for (AssessmentCriteriaTemplateBehaviourDecorator bhd : AssessmentCriteriaTemplate_BehaviourDecorators)
{
newSuggestedAssessmentType = bhd.setSuggestedAssessmentType ((AssessmentCriteriaTemplate)this, newSuggestedAssessmentType);
oldAndNewIdentical = HELPER_SuggestedAssessmentType.compare (_SuggestedAssessmentType, newSuggestedAssessmentType);
}
if (FIELD_SuggestedAssessmentType_Validators.length > 0)
{
Object newSuggestedAssessmentTypeObj = HELPER_SuggestedAssessmentType.toObject (newSuggestedAssessmentType);
if (newSuggestedAssessmentTypeObj != null)
{
int loopMax = FIELD_SuggestedAssessmentType_Validators.length;
Map metadata = (Map)ATTRIBUTES_METADATA_AssessmentCriteriaTemplate.get (FIELD_SuggestedAssessmentType);
for (int v = 0 ; v < loopMax ; ++v)
{
FIELD_SuggestedAssessmentType_Validators[v].checkAttribute (this, FIELD_SuggestedAssessmentType, metadata, newSuggestedAssessmentTypeObj);
}
}
}
}
catch (FieldException e)
{
if (!oldAndNewIdentical)
{
e.setWouldModify ();
}
throw e;
}
if (!oldAndNewIdentical)
{
assertValid();
Debug.assertion (getWriteability_SuggestedAssessmentType () != FieldWriteability.FALSE, "Field SuggestedAssessmentType is not writeable");
preSuggestedAssessmentTypeChange (newSuggestedAssessmentType);
markFieldChange (FIELD_SuggestedAssessmentType);
_SuggestedAssessmentType = newSuggestedAssessmentType;
postFieldChange (FIELD_SuggestedAssessmentType);
postSuggestedAssessmentTypeChange ();
}
}
/** /**
...@@ -3455,6 +3577,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -3455,6 +3577,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
_RequireCV = sourceAssessmentCriteriaTemplate._RequireCV; _RequireCV = sourceAssessmentCriteriaTemplate._RequireCV;
_AssessmentType = sourceAssessmentCriteriaTemplate._AssessmentType; _AssessmentType = sourceAssessmentCriteriaTemplate._AssessmentType;
_IncludeAssessmentCriteria = sourceAssessmentCriteriaTemplate._IncludeAssessmentCriteria; _IncludeAssessmentCriteria = sourceAssessmentCriteriaTemplate._IncludeAssessmentCriteria;
_SuggestedAssessmentType = sourceAssessmentCriteriaTemplate._SuggestedAssessmentType;
} }
} }
...@@ -3533,6 +3656,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -3533,6 +3656,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
_RequireCV = (Boolean)(HELPER_RequireCV.readExternal (_RequireCV, vals.get(FIELD_RequireCV))); // _RequireCV = (Boolean)(HELPER_RequireCV.readExternal (_RequireCV, vals.get(FIELD_RequireCV))); //
_AssessmentType = (AssessmentType)(HELPER_AssessmentType.readExternal (_AssessmentType, vals.get(FIELD_AssessmentType))); // _AssessmentType = (AssessmentType)(HELPER_AssessmentType.readExternal (_AssessmentType, vals.get(FIELD_AssessmentType))); //
_IncludeAssessmentCriteria = (Boolean)(HELPER_IncludeAssessmentCriteria.readExternal (_IncludeAssessmentCriteria, vals.get(FIELD_IncludeAssessmentCriteria))); // _IncludeAssessmentCriteria = (Boolean)(HELPER_IncludeAssessmentCriteria.readExternal (_IncludeAssessmentCriteria, vals.get(FIELD_IncludeAssessmentCriteria))); //
_SuggestedAssessmentType = (AssessmentType)(HELPER_SuggestedAssessmentType.readExternal (_SuggestedAssessmentType, vals.get(FIELD_SuggestedAssessmentType))); //
_Level.readExternalData(vals.get(SINGLEREFERENCE_Level)); _Level.readExternalData(vals.get(SINGLEREFERENCE_Level));
_Occupation.readExternalData(vals.get(SINGLEREFERENCE_Occupation)); _Occupation.readExternalData(vals.get(SINGLEREFERENCE_Occupation));
_JobOwner.readExternalData(vals.get(SINGLEREFERENCE_JobOwner)); _JobOwner.readExternalData(vals.get(SINGLEREFERENCE_JobOwner));
...@@ -3566,6 +3690,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -3566,6 +3690,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
vals.put (FIELD_RequireCV, HELPER_RequireCV.writeExternal (_RequireCV)); vals.put (FIELD_RequireCV, HELPER_RequireCV.writeExternal (_RequireCV));
vals.put (FIELD_AssessmentType, HELPER_AssessmentType.writeExternal (_AssessmentType)); vals.put (FIELD_AssessmentType, HELPER_AssessmentType.writeExternal (_AssessmentType));
vals.put (FIELD_IncludeAssessmentCriteria, HELPER_IncludeAssessmentCriteria.writeExternal (_IncludeAssessmentCriteria)); vals.put (FIELD_IncludeAssessmentCriteria, HELPER_IncludeAssessmentCriteria.writeExternal (_IncludeAssessmentCriteria));
vals.put (FIELD_SuggestedAssessmentType, HELPER_SuggestedAssessmentType.writeExternal (_SuggestedAssessmentType));
vals.put (SINGLEREFERENCE_Level, _Level.writeExternalData()); vals.put (SINGLEREFERENCE_Level, _Level.writeExternalData());
vals.put (SINGLEREFERENCE_Occupation, _Occupation.writeExternalData()); vals.put (SINGLEREFERENCE_Occupation, _Occupation.writeExternalData());
vals.put (SINGLEREFERENCE_JobOwner, _JobOwner.writeExternalData()); vals.put (SINGLEREFERENCE_JobOwner, _JobOwner.writeExternalData());
...@@ -3661,6 +3786,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -3661,6 +3786,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
{ {
super.visitAttributes (visitor); super.visitAttributes (visitor);
visitor.visitField(this, FIELD_SuggestedAssessmentType, HELPER_SuggestedAssessmentType.toObject(getSuggestedAssessmentType()));
} }
...@@ -4078,6 +4204,10 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -4078,6 +4204,10 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
{ {
return HELPER_IncludeAssessmentCriteria.toObject (getIncludeAssessmentCriteria ()); return HELPER_IncludeAssessmentCriteria.toObject (getIncludeAssessmentCriteria ());
} }
else if (attribName.equals (FIELD_SuggestedAssessmentType))
{
return HELPER_SuggestedAssessmentType.toObject (getSuggestedAssessmentType ());
}
else else
{ {
return super.getAttribute (attribName); return super.getAttribute (attribName);
...@@ -4139,6 +4269,10 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -4139,6 +4269,10 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
{ {
return HELPER_IncludeAssessmentCriteria; return HELPER_IncludeAssessmentCriteria;
} }
else if (attribName.equals (FIELD_SuggestedAssessmentType))
{
return HELPER_SuggestedAssessmentType;
}
else else
{ {
return super.getAttributeHelper (attribName); return super.getAttributeHelper (attribName);
...@@ -4200,6 +4334,10 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -4200,6 +4334,10 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
{ {
setIncludeAssessmentCriteria ((Boolean)(HELPER_IncludeAssessmentCriteria.fromObject (_IncludeAssessmentCriteria, attribValue))); setIncludeAssessmentCriteria ((Boolean)(HELPER_IncludeAssessmentCriteria.fromObject (_IncludeAssessmentCriteria, attribValue)));
} }
else if (attribName.equals (FIELD_SuggestedAssessmentType))
{
setSuggestedAssessmentType ((AssessmentType)(HELPER_SuggestedAssessmentType.fromObject (_SuggestedAssessmentType, attribValue)));
}
else else
{ {
super.setAttribute (attribName, attribValue); super.setAttribute (attribName, attribValue);
...@@ -4308,6 +4446,10 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -4308,6 +4446,10 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
{ {
return getWriteability_ILOJobTitle (); return getWriteability_ILOJobTitle ();
} }
else if (fieldName.equals (FIELD_SuggestedAssessmentType))
{
return getWriteability_SuggestedAssessmentType ();
}
else else
{ {
return super.getWriteable (fieldName); return super.getWriteable (fieldName);
...@@ -4378,6 +4520,11 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -4378,6 +4520,11 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
fields.add (FIELD_IncludeAssessmentCriteria); fields.add (FIELD_IncludeAssessmentCriteria);
} }
if (getWriteability_SuggestedAssessmentType () != FieldWriteability.TRUE)
{
fields.add (FIELD_SuggestedAssessmentType);
}
super.putUnwriteable (fields); super.putUnwriteable (fields);
} }
...@@ -4399,6 +4546,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -4399,6 +4546,7 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
result.add(HELPER_RequireCV.getAttribObject (getClass (), _RequireCV, false, FIELD_RequireCV)); result.add(HELPER_RequireCV.getAttribObject (getClass (), _RequireCV, false, FIELD_RequireCV));
result.add(HELPER_AssessmentType.getAttribObject (getClass (), _AssessmentType, true, FIELD_AssessmentType)); result.add(HELPER_AssessmentType.getAttribObject (getClass (), _AssessmentType, true, FIELD_AssessmentType));
result.add(HELPER_IncludeAssessmentCriteria.getAttribObject (getClass (), _IncludeAssessmentCriteria, true, FIELD_IncludeAssessmentCriteria)); result.add(HELPER_IncludeAssessmentCriteria.getAttribObject (getClass (), _IncludeAssessmentCriteria, true, FIELD_IncludeAssessmentCriteria));
result.add(HELPER_SuggestedAssessmentType.getAttribObject (getClass (), _SuggestedAssessmentType, false, FIELD_SuggestedAssessmentType));
return result; return result;
} }
...@@ -4665,6 +4813,24 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -4665,6 +4813,24 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
return newIncludeAssessmentCriteria; return newIncludeAssessmentCriteria;
} }
/**
* Get the attribute SuggestedAssessmentType
*/
public AssessmentType getSuggestedAssessmentType (AssessmentCriteriaTemplate obj, AssessmentType original)
{
return original;
}
/**
* Change the value set for attribute SuggestedAssessmentType.
* May modify the field beforehand
* Occurs before validation.
*/
public AssessmentType setSuggestedAssessmentType (AssessmentCriteriaTemplate obj, AssessmentType newSuggestedAssessmentType) throws FieldException
{
return newSuggestedAssessmentType;
}
} }
...@@ -4717,6 +4883,10 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -4717,6 +4883,10 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
public PipeLine<From, ? extends Object> to(String name) public PipeLine<From, ? extends Object> to(String name)
{ {
if (name.equals ("SuggestedAssessmentType"))
{
return toSuggestedAssessmentType ();
}
if (name.equals ("AssessmentCriterias")) if (name.equals ("AssessmentCriterias"))
{ {
return toAssessmentCriterias (); return toAssessmentCriterias ();
...@@ -4811,6 +4981,8 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -4811,6 +4981,8 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
} }
public PipeLine<From, AssessmentType> toSuggestedAssessmentType () { return pipe(new ORMAttributePipe<Me, AssessmentType>(FIELD_SuggestedAssessmentType)); }
public PipeLine<From, String> toTemplateName () { return pipe(new ORMAttributePipe<Me, String>(FIELD_TemplateName)); } public PipeLine<From, String> toTemplateName () { return pipe(new ORMAttributePipe<Me, String>(FIELD_TemplateName)); }
public PipeLine<From, String> toJobTitle () { return pipe(new ORMAttributePipe<Me, String>(FIELD_JobTitle)); } public PipeLine<From, String> toJobTitle () { return pipe(new ORMAttributePipe<Me, String>(FIELD_JobTitle)); }
...@@ -4900,6 +5072,11 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass ...@@ -4900,6 +5072,11 @@ public abstract class BaseAssessmentCriteriaTemplate extends BaseBusinessClass
public boolean isTransientAttrib(String attribName) public boolean isTransientAttrib(String attribName)
{ {
if(CollectionUtils.equals(attribName, "SuggestedAssessmentType"))
{
return true;
}
return super.isTransientAttrib(attribName); return super.isTransientAttrib(attribName);
} }
......
...@@ -44,6 +44,7 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -44,6 +44,7 @@ public abstract class BaseClient extends BaseBusinessClass
public static final String FIELD_ClientName = "ClientName"; public static final String FIELD_ClientName = "ClientName";
public static final String FIELD_ClientLogo = "ClientLogo"; public static final String FIELD_ClientLogo = "ClientLogo";
public static final String FIELD_UseClientDetails = "UseClientDetails";
public static final String FIELD_Email = "Email"; public static final String FIELD_Email = "Email";
public static final String FIELD_ContactName = "ContactName"; public static final String FIELD_ContactName = "ContactName";
public static final String FIELD_ContactSurname = "ContactSurname"; public static final String FIELD_ContactSurname = "ContactSurname";
...@@ -68,6 +69,7 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -68,6 +69,7 @@ public abstract class BaseClient extends BaseBusinessClass
// Static constants corresponding to attribute helpers // Static constants corresponding to attribute helpers
private static final DefaultAttributeHelper<Client> HELPER_ClientName = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper<Client> HELPER_ClientName = DefaultAttributeHelper.INSTANCE;
private static final BLOBAttributeHelper HELPER_ClientLogo = BLOBAttributeHelper.INSTANCE; private static final BLOBAttributeHelper HELPER_ClientLogo = BLOBAttributeHelper.INSTANCE;
private static final DefaultAttributeHelper<Client> HELPER_UseClientDetails = DefaultAttributeHelper.INSTANCE;
private static final DefaultAttributeHelper<Client> HELPER_Email = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper<Client> HELPER_Email = DefaultAttributeHelper.INSTANCE;
private static final DefaultAttributeHelper<Client> HELPER_ContactName = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper<Client> HELPER_ContactName = DefaultAttributeHelper.INSTANCE;
private static final DefaultAttributeHelper<Client> HELPER_ContactSurname = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper<Client> HELPER_ContactSurname = DefaultAttributeHelper.INSTANCE;
...@@ -83,6 +85,7 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -83,6 +85,7 @@ public abstract class BaseClient extends BaseBusinessClass
// Private attributes corresponding to business object data // Private attributes corresponding to business object data
private String _ClientName; private String _ClientName;
private BinaryContent _ClientLogo; private BinaryContent _ClientLogo;
private Boolean _UseClientDetails;
private String _Email; private String _Email;
private String _ContactName; private String _ContactName;
private String _ContactSurname; private String _ContactSurname;
...@@ -111,6 +114,7 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -111,6 +114,7 @@ public abstract class BaseClient extends BaseBusinessClass
private static final AttributeValidator[] FIELD_IsLogoDeleted_Validators; private static final AttributeValidator[] FIELD_IsLogoDeleted_Validators;
private static final AttributeValidator[] FIELD_ClientName_Validators; private static final AttributeValidator[] FIELD_ClientName_Validators;
private static final AttributeValidator[] FIELD_ClientLogo_Validators; private static final AttributeValidator[] FIELD_ClientLogo_Validators;
private static final AttributeValidator[] FIELD_UseClientDetails_Validators;
private static final AttributeValidator[] FIELD_Email_Validators; private static final AttributeValidator[] FIELD_Email_Validators;
private static final AttributeValidator[] FIELD_ContactName_Validators; private static final AttributeValidator[] FIELD_ContactName_Validators;
private static final AttributeValidator[] FIELD_ContactSurname_Validators; private static final AttributeValidator[] FIELD_ContactSurname_Validators;
...@@ -142,6 +146,7 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -142,6 +146,7 @@ public abstract class BaseClient extends BaseBusinessClass
FIELD_IsLogoDeleted_Validators = (AttributeValidator[])setupAttribMetaData_IsLogoDeleted(validatorMapping).toArray (new AttributeValidator[0]); FIELD_IsLogoDeleted_Validators = (AttributeValidator[])setupAttribMetaData_IsLogoDeleted(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_ClientName_Validators = (AttributeValidator[])setupAttribMetaData_ClientName(validatorMapping).toArray (new AttributeValidator[0]); FIELD_ClientName_Validators = (AttributeValidator[])setupAttribMetaData_ClientName(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_ClientLogo_Validators = (AttributeValidator[])setupAttribMetaData_ClientLogo(validatorMapping).toArray (new AttributeValidator[0]); FIELD_ClientLogo_Validators = (AttributeValidator[])setupAttribMetaData_ClientLogo(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_UseClientDetails_Validators = (AttributeValidator[])setupAttribMetaData_UseClientDetails(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_Email_Validators = (AttributeValidator[])setupAttribMetaData_Email(validatorMapping).toArray (new AttributeValidator[0]); FIELD_Email_Validators = (AttributeValidator[])setupAttribMetaData_Email(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_ContactName_Validators = (AttributeValidator[])setupAttribMetaData_ContactName(validatorMapping).toArray (new AttributeValidator[0]); FIELD_ContactName_Validators = (AttributeValidator[])setupAttribMetaData_ContactName(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_ContactSurname_Validators = (AttributeValidator[])setupAttribMetaData_ContactSurname(validatorMapping).toArray (new AttributeValidator[0]); FIELD_ContactSurname_Validators = (AttributeValidator[])setupAttribMetaData_ContactSurname(validatorMapping).toArray (new AttributeValidator[0]);
...@@ -272,6 +277,26 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -272,6 +277,26 @@ public abstract class BaseClient extends BaseBusinessClass
} }
// Meta Info setup // Meta Info setup
private static List setupAttribMetaData_UseClientDetails(Map validatorMapping)
{
Map metaInfo = new HashMap ();
metaInfo.put ("dbcol", "use_client_details");
metaInfo.put ("defaultValue", "Boolean.TRUE");
metaInfo.put ("mandatory", "false");
metaInfo.put ("name", "UseClientDetails");
metaInfo.put ("type", "Boolean");
LogMgr.log (BUSINESS_OBJECTS, LogLevel.DEBUG2, "Metadata for Client.UseClientDetails:", metaInfo);
ATTRIBUTES_METADATA_Client.put (FIELD_UseClientDetails, Collections.unmodifiableMap (metaInfo));
List validators = BaseBusinessClass.getAttribValidators(Client.class, "UseClientDetails", metaInfo, validatorMapping);
LogMgr.log (BUSINESS_OBJECTS, LogLevel.DEBUG1, "Validators for Client.UseClientDetails:", validators);
return validators;
}
// Meta Info setup
private static List setupAttribMetaData_Email(Map validatorMapping) private static List setupAttribMetaData_Email(Map validatorMapping)
{ {
Map metaInfo = new HashMap (); Map metaInfo = new HashMap ();
...@@ -483,6 +508,7 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -483,6 +508,7 @@ public abstract class BaseClient extends BaseBusinessClass
_ClientName = (String)(HELPER_ClientName.initialise (_ClientName)); _ClientName = (String)(HELPER_ClientName.initialise (_ClientName));
_ClientLogo = (BinaryContent)(HELPER_ClientLogo.initialise (_ClientLogo)); _ClientLogo = (BinaryContent)(HELPER_ClientLogo.initialise (_ClientLogo));
_UseClientDetails = (Boolean)(Boolean.TRUE);
_Email = (String)(HELPER_Email.initialise (_Email)); _Email = (String)(HELPER_Email.initialise (_Email));
_ContactName = (String)(HELPER_ContactName.initialise (_ContactName)); _ContactName = (String)(HELPER_ContactName.initialise (_ContactName));
_ContactSurname = (String)(HELPER_ContactSurname.initialise (_ContactSurname)); _ContactSurname = (String)(HELPER_ContactSurname.initialise (_ContactSurname));
...@@ -721,6 +747,104 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -721,6 +747,104 @@ public abstract class BaseClient extends BaseBusinessClass
} }
/** /**
* Get the attribute UseClientDetails
*/
public Boolean getUseClientDetails ()
{
assertValid();
Boolean valToReturn = _UseClientDetails;
for (ClientBehaviourDecorator bhd : Client_BehaviourDecorators)
{
valToReturn = bhd.getUseClientDetails ((Client)this, valToReturn);
}
return valToReturn;
}
/**
* Called prior to the attribute changing. Subclasses need not call super. If a field exception
* is thrown, the attribute change will fail. The new value is different to the old value.
*/
protected void preUseClientDetailsChange (Boolean newUseClientDetails) throws FieldException
{
}
/**
* Called after the attribute changes.
* If a field exception is thrown, the value is still changed, however it
* may lead to the TX being rolled back
*/
protected void postUseClientDetailsChange () throws FieldException
{
}
public FieldWriteability getWriteability_UseClientDetails ()
{
return getFieldWritabilityUtil (FieldWriteability.TRUE);
}
/**
* Set the attribute UseClientDetails. Checks to ensure a new value
* has been supplied. If so, marks the field as altered and sets the attribute.
*/
public void setUseClientDetails (Boolean newUseClientDetails) throws FieldException
{
boolean oldAndNewIdentical = HELPER_UseClientDetails.compare (_UseClientDetails, newUseClientDetails);
try
{
for (ClientBehaviourDecorator bhd : Client_BehaviourDecorators)
{
newUseClientDetails = bhd.setUseClientDetails ((Client)this, newUseClientDetails);
oldAndNewIdentical = HELPER_UseClientDetails.compare (_UseClientDetails, newUseClientDetails);
}
if (FIELD_UseClientDetails_Validators.length > 0)
{
Object newUseClientDetailsObj = HELPER_UseClientDetails.toObject (newUseClientDetails);
if (newUseClientDetailsObj != null)
{
int loopMax = FIELD_UseClientDetails_Validators.length;
Map metadata = (Map)ATTRIBUTES_METADATA_Client.get (FIELD_UseClientDetails);
for (int v = 0 ; v < loopMax ; ++v)
{
FIELD_UseClientDetails_Validators[v].checkAttribute (this, FIELD_UseClientDetails, metadata, newUseClientDetailsObj);
}
}
}
}
catch (FieldException e)
{
if (!oldAndNewIdentical)
{
e.setWouldModify ();
}
throw e;
}
if (!oldAndNewIdentical)
{
assertValid();
Debug.assertion (getWriteability_UseClientDetails () != FieldWriteability.FALSE, "Field UseClientDetails is not writeable");
preUseClientDetailsChange (newUseClientDetails);
markFieldChange (FIELD_UseClientDetails);
_UseClientDetails = newUseClientDetails;
postFieldChange (FIELD_UseClientDetails);
postUseClientDetailsChange ();
}
}
/**
* Get the attribute Email * Get the attribute Email
*/ */
public String getEmail () public String getEmail ()
...@@ -2365,6 +2489,7 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -2365,6 +2489,7 @@ public abstract class BaseClient extends BaseBusinessClass
tl_clientPSet.setAttrib (FIELD_ObjectID, myID); tl_clientPSet.setAttrib (FIELD_ObjectID, myID);
tl_clientPSet.setAttrib (FIELD_ClientName, HELPER_ClientName.toObject (_ClientName)); // tl_clientPSet.setAttrib (FIELD_ClientName, HELPER_ClientName.toObject (_ClientName)); //
tl_clientPSet.setAttrib (FIELD_ClientLogo, HELPER_ClientLogo.toObject (_ClientLogo)); // tl_clientPSet.setAttrib (FIELD_ClientLogo, HELPER_ClientLogo.toObject (_ClientLogo)); //
tl_clientPSet.setAttrib (FIELD_UseClientDetails, HELPER_UseClientDetails.toObject (_UseClientDetails)); //
tl_clientPSet.setAttrib (FIELD_Email, HELPER_Email.toObject (_Email)); // tl_clientPSet.setAttrib (FIELD_Email, HELPER_Email.toObject (_Email)); //
tl_clientPSet.setAttrib (FIELD_ContactName, HELPER_ContactName.toObject (_ContactName)); // tl_clientPSet.setAttrib (FIELD_ContactName, HELPER_ContactName.toObject (_ContactName)); //
tl_clientPSet.setAttrib (FIELD_ContactSurname, HELPER_ContactSurname.toObject (_ContactSurname)); // tl_clientPSet.setAttrib (FIELD_ContactSurname, HELPER_ContactSurname.toObject (_ContactSurname)); //
...@@ -2392,6 +2517,7 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -2392,6 +2517,7 @@ public abstract class BaseClient extends BaseBusinessClass
_ClientName = (String)(HELPER_ClientName.fromObject (_ClientName, tl_clientPSet.getAttrib (FIELD_ClientName))); // _ClientName = (String)(HELPER_ClientName.fromObject (_ClientName, tl_clientPSet.getAttrib (FIELD_ClientName))); //
_ClientLogo = (BinaryContent)(HELPER_ClientLogo.fromObject (_ClientLogo, tl_clientPSet.getAttrib (FIELD_ClientLogo))); // _ClientLogo = (BinaryContent)(HELPER_ClientLogo.fromObject (_ClientLogo, tl_clientPSet.getAttrib (FIELD_ClientLogo))); //
_UseClientDetails = (Boolean)(HELPER_UseClientDetails.fromObject (_UseClientDetails, tl_clientPSet.getAttrib (FIELD_UseClientDetails))); //
_Email = (String)(HELPER_Email.fromObject (_Email, tl_clientPSet.getAttrib (FIELD_Email))); // _Email = (String)(HELPER_Email.fromObject (_Email, tl_clientPSet.getAttrib (FIELD_Email))); //
_ContactName = (String)(HELPER_ContactName.fromObject (_ContactName, tl_clientPSet.getAttrib (FIELD_ContactName))); // _ContactName = (String)(HELPER_ContactName.fromObject (_ContactName, tl_clientPSet.getAttrib (FIELD_ContactName))); //
_ContactSurname = (String)(HELPER_ContactSurname.fromObject (_ContactSurname, tl_clientPSet.getAttrib (FIELD_ContactSurname))); // _ContactSurname = (String)(HELPER_ContactSurname.fromObject (_ContactSurname, tl_clientPSet.getAttrib (FIELD_ContactSurname))); //
...@@ -2438,6 +2564,15 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -2438,6 +2564,15 @@ public abstract class BaseClient extends BaseBusinessClass
try try
{ {
setUseClientDetails (otherClient.getUseClientDetails ());
}
catch (FieldException ex)
{
e.addException (ex);
}
try
{
setEmail (otherClient.getEmail ()); setEmail (otherClient.getEmail ());
} }
catch (FieldException ex) catch (FieldException ex)
...@@ -2534,6 +2669,7 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -2534,6 +2669,7 @@ public abstract class BaseClient extends BaseBusinessClass
_ClientName = sourceClient._ClientName; _ClientName = sourceClient._ClientName;
_ClientLogo = sourceClient._ClientLogo; _ClientLogo = sourceClient._ClientLogo;
_UseClientDetails = sourceClient._UseClientDetails;
_Email = sourceClient._Email; _Email = sourceClient._Email;
_ContactName = sourceClient._ContactName; _ContactName = sourceClient._ContactName;
_ContactSurname = sourceClient._ContactSurname; _ContactSurname = sourceClient._ContactSurname;
...@@ -2603,6 +2739,7 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -2603,6 +2739,7 @@ public abstract class BaseClient extends BaseBusinessClass
_ClientName = (String)(HELPER_ClientName.readExternal (_ClientName, vals.get(FIELD_ClientName))); // _ClientName = (String)(HELPER_ClientName.readExternal (_ClientName, vals.get(FIELD_ClientName))); //
_ClientLogo = (BinaryContent)(HELPER_ClientLogo.readExternal (_ClientLogo, vals.get(FIELD_ClientLogo))); // _ClientLogo = (BinaryContent)(HELPER_ClientLogo.readExternal (_ClientLogo, vals.get(FIELD_ClientLogo))); //
_UseClientDetails = (Boolean)(HELPER_UseClientDetails.readExternal (_UseClientDetails, vals.get(FIELD_UseClientDetails))); //
_Email = (String)(HELPER_Email.readExternal (_Email, vals.get(FIELD_Email))); // _Email = (String)(HELPER_Email.readExternal (_Email, vals.get(FIELD_Email))); //
_ContactName = (String)(HELPER_ContactName.readExternal (_ContactName, vals.get(FIELD_ContactName))); // _ContactName = (String)(HELPER_ContactName.readExternal (_ContactName, vals.get(FIELD_ContactName))); //
_ContactSurname = (String)(HELPER_ContactSurname.readExternal (_ContactSurname, vals.get(FIELD_ContactSurname))); // _ContactSurname = (String)(HELPER_ContactSurname.readExternal (_ContactSurname, vals.get(FIELD_ContactSurname))); //
...@@ -2629,6 +2766,7 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -2629,6 +2766,7 @@ public abstract class BaseClient extends BaseBusinessClass
vals.put (FIELD_ClientName, HELPER_ClientName.writeExternal (_ClientName)); vals.put (FIELD_ClientName, HELPER_ClientName.writeExternal (_ClientName));
vals.put (FIELD_ClientLogo, HELPER_ClientLogo.writeExternal (_ClientLogo)); vals.put (FIELD_ClientLogo, HELPER_ClientLogo.writeExternal (_ClientLogo));
vals.put (FIELD_UseClientDetails, HELPER_UseClientDetails.writeExternal (_UseClientDetails));
vals.put (FIELD_Email, HELPER_Email.writeExternal (_Email)); vals.put (FIELD_Email, HELPER_Email.writeExternal (_Email));
vals.put (FIELD_ContactName, HELPER_ContactName.writeExternal (_ContactName)); vals.put (FIELD_ContactName, HELPER_ContactName.writeExternal (_ContactName));
vals.put (FIELD_ContactSurname, HELPER_ContactSurname.writeExternal (_ContactSurname)); vals.put (FIELD_ContactSurname, HELPER_ContactSurname.writeExternal (_ContactSurname));
...@@ -2663,6 +2801,10 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -2663,6 +2801,10 @@ public abstract class BaseClient extends BaseBusinessClass
{ {
listener.notifyFieldChange(this, other, FIELD_ClientLogo, HELPER_ClientLogo.toObject(this._ClientLogo), HELPER_ClientLogo.toObject(otherClient._ClientLogo)); listener.notifyFieldChange(this, other, FIELD_ClientLogo, HELPER_ClientLogo.toObject(this._ClientLogo), HELPER_ClientLogo.toObject(otherClient._ClientLogo));
} }
if (!HELPER_UseClientDetails.compare(this._UseClientDetails, otherClient._UseClientDetails))
{
listener.notifyFieldChange(this, other, FIELD_UseClientDetails, HELPER_UseClientDetails.toObject(this._UseClientDetails), HELPER_UseClientDetails.toObject(otherClient._UseClientDetails));
}
if (!HELPER_Email.compare(this._Email, otherClient._Email)) if (!HELPER_Email.compare(this._Email, otherClient._Email))
{ {
listener.notifyFieldChange(this, other, FIELD_Email, HELPER_Email.toObject(this._Email), HELPER_Email.toObject(otherClient._Email)); listener.notifyFieldChange(this, other, FIELD_Email, HELPER_Email.toObject(this._Email), HELPER_Email.toObject(otherClient._Email));
...@@ -2727,6 +2869,7 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -2727,6 +2869,7 @@ public abstract class BaseClient extends BaseBusinessClass
visitor.visitField(this, FIELD_ClientName, HELPER_ClientName.toObject(getClientName())); visitor.visitField(this, FIELD_ClientName, HELPER_ClientName.toObject(getClientName()));
visitor.visitField(this, FIELD_ClientLogo, HELPER_ClientLogo.toObject(getClientLogo())); visitor.visitField(this, FIELD_ClientLogo, HELPER_ClientLogo.toObject(getClientLogo()));
visitor.visitField(this, FIELD_UseClientDetails, HELPER_UseClientDetails.toObject(getUseClientDetails()));
visitor.visitField(this, FIELD_Email, HELPER_Email.toObject(getEmail())); visitor.visitField(this, FIELD_Email, HELPER_Email.toObject(getEmail()));
visitor.visitField(this, FIELD_ContactName, HELPER_ContactName.toObject(getContactName())); visitor.visitField(this, FIELD_ContactName, HELPER_ContactName.toObject(getContactName()));
visitor.visitField(this, FIELD_ContactSurname, HELPER_ContactSurname.toObject(getContactSurname())); visitor.visitField(this, FIELD_ContactSurname, HELPER_ContactSurname.toObject(getContactSurname()));
...@@ -2792,6 +2935,10 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -2792,6 +2935,10 @@ public abstract class BaseClient extends BaseBusinessClass
{ {
return filter.matches (getClientLogo ()); return filter.matches (getClientLogo ());
} }
else if (attribName.equals (FIELD_UseClientDetails))
{
return filter.matches (getUseClientDetails ());
}
else if (attribName.equals (FIELD_Email)) else if (attribName.equals (FIELD_Email))
{ {
return filter.matches (getEmail ()); return filter.matches (getEmail ());
...@@ -2879,6 +3026,12 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -2879,6 +3026,12 @@ public abstract class BaseClient extends BaseBusinessClass
return this; return this;
} }
public SearchAll andUseClientDetails (QueryFilter<Boolean> filter)
{
filter.addFilter (context, "tl_client.use_client_details", "UseClientDetails");
return this;
}
public SearchAll andEmail (QueryFilter<String> filter) public SearchAll andEmail (QueryFilter<String> filter)
{ {
filter.addFilter (context, "tl_client.email", "Email"); filter.addFilter (context, "tl_client.email", "Email");
...@@ -2988,6 +3141,10 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -2988,6 +3141,10 @@ public abstract class BaseClient extends BaseBusinessClass
{ {
return HELPER_ClientLogo.toObject (getClientLogo ()); return HELPER_ClientLogo.toObject (getClientLogo ());
} }
else if (attribName.equals (FIELD_UseClientDetails))
{
return HELPER_UseClientDetails.toObject (getUseClientDetails ());
}
else if (attribName.equals (FIELD_Email)) else if (attribName.equals (FIELD_Email))
{ {
return HELPER_Email.toObject (getEmail ()); return HELPER_Email.toObject (getEmail ());
...@@ -3049,6 +3206,10 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -3049,6 +3206,10 @@ public abstract class BaseClient extends BaseBusinessClass
{ {
return HELPER_ClientLogo; return HELPER_ClientLogo;
} }
else if (attribName.equals (FIELD_UseClientDetails))
{
return HELPER_UseClientDetails;
}
else if (attribName.equals (FIELD_Email)) else if (attribName.equals (FIELD_Email))
{ {
return HELPER_Email; return HELPER_Email;
...@@ -3110,6 +3271,10 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -3110,6 +3271,10 @@ public abstract class BaseClient extends BaseBusinessClass
{ {
setClientLogo ((BinaryContent)(HELPER_ClientLogo.fromObject (_ClientLogo, attribValue))); setClientLogo ((BinaryContent)(HELPER_ClientLogo.fromObject (_ClientLogo, attribValue)));
} }
else if (attribName.equals (FIELD_UseClientDetails))
{
setUseClientDetails ((Boolean)(HELPER_UseClientDetails.fromObject (_UseClientDetails, attribValue)));
}
else if (attribName.equals (FIELD_Email)) else if (attribName.equals (FIELD_Email))
{ {
setEmail ((String)(HELPER_Email.fromObject (_Email, attribValue))); setEmail ((String)(HELPER_Email.fromObject (_Email, attribValue)));
...@@ -3178,6 +3343,10 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -3178,6 +3343,10 @@ public abstract class BaseClient extends BaseBusinessClass
{ {
return getWriteability_ClientLogo (); return getWriteability_ClientLogo ();
} }
else if (fieldName.equals (FIELD_UseClientDetails))
{
return getWriteability_UseClientDetails ();
}
else if (fieldName.equals (FIELD_Email)) else if (fieldName.equals (FIELD_Email))
{ {
return getWriteability_Email (); return getWriteability_Email ();
...@@ -3250,6 +3419,11 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -3250,6 +3419,11 @@ public abstract class BaseClient extends BaseBusinessClass
fields.add (FIELD_ClientLogo); fields.add (FIELD_ClientLogo);
} }
if (getWriteability_UseClientDetails () != FieldWriteability.TRUE)
{
fields.add (FIELD_UseClientDetails);
}
if (getWriteability_Email () != FieldWriteability.TRUE) if (getWriteability_Email () != FieldWriteability.TRUE)
{ {
fields.add (FIELD_Email); fields.add (FIELD_Email);
...@@ -3311,6 +3485,7 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -3311,6 +3485,7 @@ public abstract class BaseClient extends BaseBusinessClass
result.add(HELPER_ClientName.getAttribObject (getClass (), _ClientName, true, FIELD_ClientName)); result.add(HELPER_ClientName.getAttribObject (getClass (), _ClientName, true, FIELD_ClientName));
result.add(HELPER_ClientLogo.getAttribObject (getClass (), _ClientLogo, false, FIELD_ClientLogo)); result.add(HELPER_ClientLogo.getAttribObject (getClass (), _ClientLogo, false, FIELD_ClientLogo));
result.add(HELPER_UseClientDetails.getAttribObject (getClass (), _UseClientDetails, false, FIELD_UseClientDetails));
result.add(HELPER_Email.getAttribObject (getClass (), _Email, false, FIELD_Email)); result.add(HELPER_Email.getAttribObject (getClass (), _Email, false, FIELD_Email));
result.add(HELPER_ContactName.getAttribObject (getClass (), _ContactName, false, FIELD_ContactName)); result.add(HELPER_ContactName.getAttribObject (getClass (), _ContactName, false, FIELD_ContactName));
result.add(HELPER_ContactSurname.getAttribObject (getClass (), _ContactSurname, false, FIELD_ContactSurname)); result.add(HELPER_ContactSurname.getAttribObject (getClass (), _ContactSurname, false, FIELD_ContactSurname));
...@@ -3426,6 +3601,24 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -3426,6 +3601,24 @@ public abstract class BaseClient extends BaseBusinessClass
} }
/** /**
* Get the attribute UseClientDetails
*/
public Boolean getUseClientDetails (Client obj, Boolean original)
{
return original;
}
/**
* Change the value set for attribute UseClientDetails.
* May modify the field beforehand
* Occurs before validation.
*/
public Boolean setUseClientDetails (Client obj, Boolean newUseClientDetails) throws FieldException
{
return newUseClientDetails;
}
/**
* Get the attribute Email * Get the attribute Email
*/ */
public String getEmail (Client obj, String original) public String getEmail (Client obj, String original)
...@@ -3673,6 +3866,10 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -3673,6 +3866,10 @@ public abstract class BaseClient extends BaseBusinessClass
{ {
return toClientLogo (); return toClientLogo ();
} }
if (name.equals ("UseClientDetails"))
{
return toUseClientDetails ();
}
if (name.equals ("Email")) if (name.equals ("Email"))
{ {
return toEmail (); return toEmail ();
...@@ -3729,6 +3926,8 @@ public abstract class BaseClient extends BaseBusinessClass ...@@ -3729,6 +3926,8 @@ public abstract class BaseClient extends BaseBusinessClass
public PipeLine<From, BinaryContent> toClientLogo () { return pipe(new ORMAttributePipe<Me, BinaryContent>(FIELD_ClientLogo)); } public PipeLine<From, BinaryContent> toClientLogo () { return pipe(new ORMAttributePipe<Me, BinaryContent>(FIELD_ClientLogo)); }
public PipeLine<From, Boolean> toUseClientDetails () { return pipe(new ORMAttributePipe<Me, Boolean>(FIELD_UseClientDetails)); }
public PipeLine<From, String> toEmail () { return pipe(new ORMAttributePipe<Me, String>(FIELD_Email)); } public PipeLine<From, String> toEmail () { return pipe(new ORMAttributePipe<Me, String>(FIELD_Email)); }
public PipeLine<From, String> toContactName () { return pipe(new ORMAttributePipe<Me, String>(FIELD_ContactName)); } public PipeLine<From, String> toContactName () { return pipe(new ORMAttributePipe<Me, String>(FIELD_ContactName)); }
......
...@@ -48,6 +48,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -48,6 +48,7 @@ public abstract class BaseJob extends BaseBusinessClass
public static final String FIELD_OpenDate = "OpenDate"; public static final String FIELD_OpenDate = "OpenDate";
public static final String FIELD_ApplyBy = "ApplyBy"; public static final String FIELD_ApplyBy = "ApplyBy";
public static final String FIELD_IncludeAssessmentCriteria = "IncludeAssessmentCriteria"; public static final String FIELD_IncludeAssessmentCriteria = "IncludeAssessmentCriteria";
public static final String FIELD_IncludeCulture = "IncludeCulture";
public static final String FIELD_AssessmentType = "AssessmentType"; public static final String FIELD_AssessmentType = "AssessmentType";
public static final String FIELD_RandomKey = "RandomKey"; public static final String FIELD_RandomKey = "RandomKey";
public static final String FIELD_JobType = "JobType"; public static final String FIELD_JobType = "JobType";
...@@ -80,6 +81,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -80,6 +81,7 @@ public abstract class BaseJob extends BaseBusinessClass
public static final String FIELD_AssessmentTemplateName = "AssessmentTemplateName"; public static final String FIELD_AssessmentTemplateName = "AssessmentTemplateName";
public static final String FIELD_CultureTemplateName = "CultureTemplateName"; public static final String FIELD_CultureTemplateName = "CultureTemplateName";
public static final String FIELD_AppProcessOption = "AppProcessOption"; public static final String FIELD_AppProcessOption = "AppProcessOption";
public static final String FIELD_SuggestedAssessmentType = "SuggestedAssessmentType";
public static final String FIELD_RankingCompleted = "RankingCompleted"; public static final String FIELD_RankingCompleted = "RankingCompleted";
public static final String SINGLEREFERENCE_CultureTemplate = "CultureTemplate"; public static final String SINGLEREFERENCE_CultureTemplate = "CultureTemplate";
public static final String SINGLEREFERENCE_JobTemplate = "JobTemplate"; public static final String SINGLEREFERENCE_JobTemplate = "JobTemplate";
...@@ -117,6 +119,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -117,6 +119,7 @@ public abstract class BaseJob extends BaseBusinessClass
private static final DefaultAttributeHelper<Job> HELPER_OpenDate = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper<Job> HELPER_OpenDate = DefaultAttributeHelper.INSTANCE;
private static final DefaultAttributeHelper<Job> HELPER_ApplyBy = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper<Job> HELPER_ApplyBy = DefaultAttributeHelper.INSTANCE;
private static final DefaultAttributeHelper<Job> HELPER_IncludeAssessmentCriteria = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper<Job> HELPER_IncludeAssessmentCriteria = DefaultAttributeHelper.INSTANCE;
private static final DefaultAttributeHelper<Job> HELPER_IncludeCulture = DefaultAttributeHelper.INSTANCE;
private static final EnumeratedAttributeHelper<Job, AssessmentType> HELPER_AssessmentType = new EnumeratedAttributeHelper<Job, AssessmentType> (AssessmentType.FACTORY_AssessmentType); private static final EnumeratedAttributeHelper<Job, AssessmentType> HELPER_AssessmentType = new EnumeratedAttributeHelper<Job, AssessmentType> (AssessmentType.FACTORY_AssessmentType);
private static final DefaultAttributeHelper<Job> HELPER_RandomKey = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper<Job> HELPER_RandomKey = DefaultAttributeHelper.INSTANCE;
private static final EnumeratedAttributeHelper<Job, JobType> HELPER_JobType = new EnumeratedAttributeHelper<Job, JobType> (JobType.FACTORY_JobType); private static final EnumeratedAttributeHelper<Job, JobType> HELPER_JobType = new EnumeratedAttributeHelper<Job, JobType> (JobType.FACTORY_JobType);
...@@ -149,6 +152,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -149,6 +152,7 @@ public abstract class BaseJob extends BaseBusinessClass
private static final DefaultAttributeHelper<Job> HELPER_AssessmentTemplateName = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper<Job> HELPER_AssessmentTemplateName = DefaultAttributeHelper.INSTANCE;
private static final DefaultAttributeHelper<Job> HELPER_CultureTemplateName = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper<Job> HELPER_CultureTemplateName = DefaultAttributeHelper.INSTANCE;
private static final EnumeratedAttributeHelper<Job, AppProcessOption> HELPER_AppProcessOption = new EnumeratedAttributeHelper<Job, AppProcessOption> (AppProcessOption.FACTORY_AppProcessOption); private static final EnumeratedAttributeHelper<Job, AppProcessOption> HELPER_AppProcessOption = new EnumeratedAttributeHelper<Job, AppProcessOption> (AppProcessOption.FACTORY_AppProcessOption);
private static final EnumeratedAttributeHelper<Job, AssessmentType> HELPER_SuggestedAssessmentType = new EnumeratedAttributeHelper<Job, AssessmentType> (AssessmentType.FACTORY_AssessmentType);
private static final DefaultAttributeHelper<Job> HELPER_RankingCompleted = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper<Job> HELPER_RankingCompleted = DefaultAttributeHelper.INSTANCE;
...@@ -159,6 +163,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -159,6 +163,7 @@ public abstract class BaseJob extends BaseBusinessClass
private Date _OpenDate; private Date _OpenDate;
private Date _ApplyBy; private Date _ApplyBy;
private Boolean _IncludeAssessmentCriteria; private Boolean _IncludeAssessmentCriteria;
private Boolean _IncludeCulture;
private AssessmentType _AssessmentType; private AssessmentType _AssessmentType;
private String _RandomKey; private String _RandomKey;
private JobType _JobType; private JobType _JobType;
...@@ -191,6 +196,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -191,6 +196,7 @@ public abstract class BaseJob extends BaseBusinessClass
private String _AssessmentTemplateName; private String _AssessmentTemplateName;
private String _CultureTemplateName; private String _CultureTemplateName;
private AppProcessOption _AppProcessOption; private AppProcessOption _AppProcessOption;
private AssessmentType _SuggestedAssessmentType;
private Boolean _RankingCompleted; private Boolean _RankingCompleted;
...@@ -233,6 +239,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -233,6 +239,7 @@ public abstract class BaseJob extends BaseBusinessClass
private static final AttributeValidator[] FIELD_AssessmentTemplateName_Validators; private static final AttributeValidator[] FIELD_AssessmentTemplateName_Validators;
private static final AttributeValidator[] FIELD_CultureTemplateName_Validators; private static final AttributeValidator[] FIELD_CultureTemplateName_Validators;
private static final AttributeValidator[] FIELD_AppProcessOption_Validators; private static final AttributeValidator[] FIELD_AppProcessOption_Validators;
private static final AttributeValidator[] FIELD_SuggestedAssessmentType_Validators;
private static final AttributeValidator[] FIELD_RankingCompleted_Validators; private static final AttributeValidator[] FIELD_RankingCompleted_Validators;
private static final AttributeValidator[] FIELD_JobTitle_Validators; private static final AttributeValidator[] FIELD_JobTitle_Validators;
private static final AttributeValidator[] FIELD_JobDescription_Validators; private static final AttributeValidator[] FIELD_JobDescription_Validators;
...@@ -240,6 +247,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -240,6 +247,7 @@ public abstract class BaseJob extends BaseBusinessClass
private static final AttributeValidator[] FIELD_OpenDate_Validators; private static final AttributeValidator[] FIELD_OpenDate_Validators;
private static final AttributeValidator[] FIELD_ApplyBy_Validators; private static final AttributeValidator[] FIELD_ApplyBy_Validators;
private static final AttributeValidator[] FIELD_IncludeAssessmentCriteria_Validators; private static final AttributeValidator[] FIELD_IncludeAssessmentCriteria_Validators;
private static final AttributeValidator[] FIELD_IncludeCulture_Validators;
private static final AttributeValidator[] FIELD_AssessmentType_Validators; private static final AttributeValidator[] FIELD_AssessmentType_Validators;
private static final AttributeValidator[] FIELD_RandomKey_Validators; private static final AttributeValidator[] FIELD_RandomKey_Validators;
private static final AttributeValidator[] FIELD_JobType_Validators; private static final AttributeValidator[] FIELD_JobType_Validators;
...@@ -306,6 +314,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -306,6 +314,7 @@ public abstract class BaseJob extends BaseBusinessClass
FIELD_AssessmentTemplateName_Validators = (AttributeValidator[])setupAttribMetaData_AssessmentTemplateName(validatorMapping).toArray (new AttributeValidator[0]); FIELD_AssessmentTemplateName_Validators = (AttributeValidator[])setupAttribMetaData_AssessmentTemplateName(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_CultureTemplateName_Validators = (AttributeValidator[])setupAttribMetaData_CultureTemplateName(validatorMapping).toArray (new AttributeValidator[0]); FIELD_CultureTemplateName_Validators = (AttributeValidator[])setupAttribMetaData_CultureTemplateName(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_AppProcessOption_Validators = (AttributeValidator[])setupAttribMetaData_AppProcessOption(validatorMapping).toArray (new AttributeValidator[0]); FIELD_AppProcessOption_Validators = (AttributeValidator[])setupAttribMetaData_AppProcessOption(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_SuggestedAssessmentType_Validators = (AttributeValidator[])setupAttribMetaData_SuggestedAssessmentType(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_RankingCompleted_Validators = (AttributeValidator[])setupAttribMetaData_RankingCompleted(validatorMapping).toArray (new AttributeValidator[0]); FIELD_RankingCompleted_Validators = (AttributeValidator[])setupAttribMetaData_RankingCompleted(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_JobTitle_Validators = (AttributeValidator[])setupAttribMetaData_JobTitle(validatorMapping).toArray (new AttributeValidator[0]); FIELD_JobTitle_Validators = (AttributeValidator[])setupAttribMetaData_JobTitle(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_JobDescription_Validators = (AttributeValidator[])setupAttribMetaData_JobDescription(validatorMapping).toArray (new AttributeValidator[0]); FIELD_JobDescription_Validators = (AttributeValidator[])setupAttribMetaData_JobDescription(validatorMapping).toArray (new AttributeValidator[0]);
...@@ -313,6 +322,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -313,6 +322,7 @@ public abstract class BaseJob extends BaseBusinessClass
FIELD_OpenDate_Validators = (AttributeValidator[])setupAttribMetaData_OpenDate(validatorMapping).toArray (new AttributeValidator[0]); FIELD_OpenDate_Validators = (AttributeValidator[])setupAttribMetaData_OpenDate(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_ApplyBy_Validators = (AttributeValidator[])setupAttribMetaData_ApplyBy(validatorMapping).toArray (new AttributeValidator[0]); FIELD_ApplyBy_Validators = (AttributeValidator[])setupAttribMetaData_ApplyBy(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_IncludeAssessmentCriteria_Validators = (AttributeValidator[])setupAttribMetaData_IncludeAssessmentCriteria(validatorMapping).toArray (new AttributeValidator[0]); FIELD_IncludeAssessmentCriteria_Validators = (AttributeValidator[])setupAttribMetaData_IncludeAssessmentCriteria(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_IncludeCulture_Validators = (AttributeValidator[])setupAttribMetaData_IncludeCulture(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_AssessmentType_Validators = (AttributeValidator[])setupAttribMetaData_AssessmentType(validatorMapping).toArray (new AttributeValidator[0]); FIELD_AssessmentType_Validators = (AttributeValidator[])setupAttribMetaData_AssessmentType(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_RandomKey_Validators = (AttributeValidator[])setupAttribMetaData_RandomKey(validatorMapping).toArray (new AttributeValidator[0]); FIELD_RandomKey_Validators = (AttributeValidator[])setupAttribMetaData_RandomKey(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_JobType_Validators = (AttributeValidator[])setupAttribMetaData_JobType(validatorMapping).toArray (new AttributeValidator[0]); FIELD_JobType_Validators = (AttributeValidator[])setupAttribMetaData_JobType(validatorMapping).toArray (new AttributeValidator[0]);
...@@ -802,6 +812,24 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -802,6 +812,24 @@ public abstract class BaseJob extends BaseBusinessClass
} }
// Meta Info setup // Meta Info setup
private static List setupAttribMetaData_SuggestedAssessmentType(Map validatorMapping)
{
Map metaInfo = new HashMap ();
metaInfo.put ("attribHelper", "EnumeratedAttributeHelper");
metaInfo.put ("name", "SuggestedAssessmentType");
metaInfo.put ("type", "AssessmentType");
LogMgr.log (BUSINESS_OBJECTS, LogLevel.DEBUG2, "Metadata for Job.SuggestedAssessmentType:", metaInfo);
ATTRIBUTES_METADATA_Job.put (FIELD_SuggestedAssessmentType, Collections.unmodifiableMap (metaInfo));
List validators = BaseBusinessClass.getAttribValidators(Job.class, "SuggestedAssessmentType", metaInfo, validatorMapping);
LogMgr.log (BUSINESS_OBJECTS, LogLevel.DEBUG1, "Validators for Job.SuggestedAssessmentType:", validators);
return validators;
}
// Meta Info setup
private static List setupAttribMetaData_RankingCompleted(Map validatorMapping) private static List setupAttribMetaData_RankingCompleted(Map validatorMapping)
{ {
Map metaInfo = new HashMap (); Map metaInfo = new HashMap ();
...@@ -934,6 +962,26 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -934,6 +962,26 @@ public abstract class BaseJob extends BaseBusinessClass
} }
// Meta Info setup // Meta Info setup
private static List setupAttribMetaData_IncludeCulture(Map validatorMapping)
{
Map metaInfo = new HashMap ();
metaInfo.put ("dbcol", "include_culture");
metaInfo.put ("defaultValue", "Boolean.TRUE");
metaInfo.put ("mandatory", "true");
metaInfo.put ("name", "IncludeCulture");
metaInfo.put ("type", "Boolean");
LogMgr.log (BUSINESS_OBJECTS, LogLevel.DEBUG2, "Metadata for Job.IncludeCulture:", metaInfo);
ATTRIBUTES_METADATA_Job.put (FIELD_IncludeCulture, Collections.unmodifiableMap (metaInfo));
List validators = BaseBusinessClass.getAttribValidators(Job.class, "IncludeCulture", metaInfo, validatorMapping);
LogMgr.log (BUSINESS_OBJECTS, LogLevel.DEBUG1, "Validators for Job.IncludeCulture:", validators);
return validators;
}
// Meta Info setup
private static List setupAttribMetaData_AssessmentType(Map validatorMapping) private static List setupAttribMetaData_AssessmentType(Map validatorMapping)
{ {
Map metaInfo = new HashMap (); Map metaInfo = new HashMap ();
...@@ -1335,6 +1383,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -1335,6 +1383,7 @@ public abstract class BaseJob extends BaseBusinessClass
_OpenDate = (Date)(HELPER_OpenDate.initialise (_OpenDate)); _OpenDate = (Date)(HELPER_OpenDate.initialise (_OpenDate));
_ApplyBy = (Date)(HELPER_ApplyBy.initialise (_ApplyBy)); _ApplyBy = (Date)(HELPER_ApplyBy.initialise (_ApplyBy));
_IncludeAssessmentCriteria = (Boolean)(Boolean.TRUE); _IncludeAssessmentCriteria = (Boolean)(Boolean.TRUE);
_IncludeCulture = (Boolean)(Boolean.TRUE);
_AssessmentType = (AssessmentType)(AssessmentType.COMPREHENSIVE); _AssessmentType = (AssessmentType)(AssessmentType.COMPREHENSIVE);
_RandomKey = (String)(HELPER_RandomKey.initialise (_RandomKey)); _RandomKey = (String)(HELPER_RandomKey.initialise (_RandomKey));
_JobType = (JobType)(JobType.FULL_TIME); _JobType = (JobType)(JobType.FULL_TIME);
...@@ -1367,6 +1416,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -1367,6 +1416,7 @@ public abstract class BaseJob extends BaseBusinessClass
_AssessmentTemplateName = (String)(HELPER_AssessmentTemplateName.initialise (_AssessmentTemplateName)); _AssessmentTemplateName = (String)(HELPER_AssessmentTemplateName.initialise (_AssessmentTemplateName));
_CultureTemplateName = (String)(HELPER_CultureTemplateName.initialise (_CultureTemplateName)); _CultureTemplateName = (String)(HELPER_CultureTemplateName.initialise (_CultureTemplateName));
_AppProcessOption = (AppProcessOption)(HELPER_AppProcessOption.initialise (_AppProcessOption)); _AppProcessOption = (AppProcessOption)(HELPER_AppProcessOption.initialise (_AppProcessOption));
_SuggestedAssessmentType = (AssessmentType)(HELPER_SuggestedAssessmentType.initialise (_SuggestedAssessmentType));
_RankingCompleted = (Boolean)(HELPER_RankingCompleted.initialise (_RankingCompleted)); _RankingCompleted = (Boolean)(HELPER_RankingCompleted.initialise (_RankingCompleted));
} }
...@@ -2017,6 +2067,105 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -2017,6 +2067,105 @@ public abstract class BaseJob extends BaseBusinessClass
} }
/** /**
* Get the attribute IncludeCulture
*/
public Boolean getIncludeCulture ()
{
assertValid();
Boolean valToReturn = _IncludeCulture;
for (JobBehaviourDecorator bhd : Job_BehaviourDecorators)
{
valToReturn = bhd.getIncludeCulture ((Job)this, valToReturn);
}
return valToReturn;
}
/**
* Called prior to the attribute changing. Subclasses need not call super. If a field exception
* is thrown, the attribute change will fail. The new value is different to the old value.
*/
protected void preIncludeCultureChange (Boolean newIncludeCulture) throws FieldException
{
}
/**
* Called after the attribute changes.
* If a field exception is thrown, the value is still changed, however it
* may lead to the TX being rolled back
*/
protected void postIncludeCultureChange () throws FieldException
{
}
public FieldWriteability getWriteability_IncludeCulture ()
{
return getFieldWritabilityUtil (FieldWriteability.TRUE);
}
/**
* Set the attribute IncludeCulture. Checks to ensure a new value
* has been supplied. If so, marks the field as altered and sets the attribute.
*/
public void setIncludeCulture (Boolean newIncludeCulture) throws FieldException
{
boolean oldAndNewIdentical = HELPER_IncludeCulture.compare (_IncludeCulture, newIncludeCulture);
try
{
for (JobBehaviourDecorator bhd : Job_BehaviourDecorators)
{
newIncludeCulture = bhd.setIncludeCulture ((Job)this, newIncludeCulture);
oldAndNewIdentical = HELPER_IncludeCulture.compare (_IncludeCulture, newIncludeCulture);
}
BusinessObjectParser.assertFieldCondition (newIncludeCulture != null, this, FIELD_IncludeCulture, "mandatory");
if (FIELD_IncludeCulture_Validators.length > 0)
{
Object newIncludeCultureObj = HELPER_IncludeCulture.toObject (newIncludeCulture);
if (newIncludeCultureObj != null)
{
int loopMax = FIELD_IncludeCulture_Validators.length;
Map metadata = (Map)ATTRIBUTES_METADATA_Job.get (FIELD_IncludeCulture);
for (int v = 0 ; v < loopMax ; ++v)
{
FIELD_IncludeCulture_Validators[v].checkAttribute (this, FIELD_IncludeCulture, metadata, newIncludeCultureObj);
}
}
}
}
catch (FieldException e)
{
if (!oldAndNewIdentical)
{
e.setWouldModify ();
}
throw e;
}
if (!oldAndNewIdentical)
{
assertValid();
Debug.assertion (getWriteability_IncludeCulture () != FieldWriteability.FALSE, "Field IncludeCulture is not writeable");
preIncludeCultureChange (newIncludeCulture);
markFieldChange (FIELD_IncludeCulture);
_IncludeCulture = newIncludeCulture;
postFieldChange (FIELD_IncludeCulture);
postIncludeCultureChange ();
}
}
/**
* Get the attribute AssessmentType * Get the attribute AssessmentType
*/ */
public AssessmentType getAssessmentType () public AssessmentType getAssessmentType ()
...@@ -5158,6 +5307,104 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -5158,6 +5307,104 @@ public abstract class BaseJob extends BaseBusinessClass
} }
/** /**
* Get the attribute SuggestedAssessmentType
*/
public AssessmentType getSuggestedAssessmentType ()
{
assertValid();
AssessmentType valToReturn = _SuggestedAssessmentType;
for (JobBehaviourDecorator bhd : Job_BehaviourDecorators)
{
valToReturn = bhd.getSuggestedAssessmentType ((Job)this, valToReturn);
}
return valToReturn;
}
/**
* Called prior to the attribute changing. Subclasses need not call super. If a field exception
* is thrown, the attribute change will fail. The new value is different to the old value.
*/
protected void preSuggestedAssessmentTypeChange (AssessmentType newSuggestedAssessmentType) throws FieldException
{
}
/**
* Called after the attribute changes.
* If a field exception is thrown, the value is still changed, however it
* may lead to the TX being rolled back
*/
protected void postSuggestedAssessmentTypeChange () throws FieldException
{
}
public FieldWriteability getWriteability_SuggestedAssessmentType ()
{
return getFieldWritabilityUtil (FieldWriteability.TRUE);
}
/**
* Set the attribute SuggestedAssessmentType. Checks to ensure a new value
* has been supplied. If so, marks the field as altered and sets the attribute.
*/
public void setSuggestedAssessmentType (AssessmentType newSuggestedAssessmentType) throws FieldException
{
boolean oldAndNewIdentical = HELPER_SuggestedAssessmentType.compare (_SuggestedAssessmentType, newSuggestedAssessmentType);
try
{
for (JobBehaviourDecorator bhd : Job_BehaviourDecorators)
{
newSuggestedAssessmentType = bhd.setSuggestedAssessmentType ((Job)this, newSuggestedAssessmentType);
oldAndNewIdentical = HELPER_SuggestedAssessmentType.compare (_SuggestedAssessmentType, newSuggestedAssessmentType);
}
if (FIELD_SuggestedAssessmentType_Validators.length > 0)
{
Object newSuggestedAssessmentTypeObj = HELPER_SuggestedAssessmentType.toObject (newSuggestedAssessmentType);
if (newSuggestedAssessmentTypeObj != null)
{
int loopMax = FIELD_SuggestedAssessmentType_Validators.length;
Map metadata = (Map)ATTRIBUTES_METADATA_Job.get (FIELD_SuggestedAssessmentType);
for (int v = 0 ; v < loopMax ; ++v)
{
FIELD_SuggestedAssessmentType_Validators[v].checkAttribute (this, FIELD_SuggestedAssessmentType, metadata, newSuggestedAssessmentTypeObj);
}
}
}
}
catch (FieldException e)
{
if (!oldAndNewIdentical)
{
e.setWouldModify ();
}
throw e;
}
if (!oldAndNewIdentical)
{
assertValid();
Debug.assertion (getWriteability_SuggestedAssessmentType () != FieldWriteability.FALSE, "Field SuggestedAssessmentType is not writeable");
preSuggestedAssessmentTypeChange (newSuggestedAssessmentType);
markFieldChange (FIELD_SuggestedAssessmentType);
_SuggestedAssessmentType = newSuggestedAssessmentType;
postFieldChange (FIELD_SuggestedAssessmentType);
postSuggestedAssessmentTypeChange ();
}
}
/**
* Get the attribute RankingCompleted * Get the attribute RankingCompleted
*/ */
public Boolean getRankingCompleted () public Boolean getRankingCompleted ()
...@@ -7395,6 +7642,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -7395,6 +7642,7 @@ public abstract class BaseJob extends BaseBusinessClass
tl_jobPSet.setAttrib (FIELD_OpenDate, HELPER_OpenDate.toObject (_OpenDate)); // tl_jobPSet.setAttrib (FIELD_OpenDate, HELPER_OpenDate.toObject (_OpenDate)); //
tl_jobPSet.setAttrib (FIELD_ApplyBy, HELPER_ApplyBy.toObject (_ApplyBy)); // tl_jobPSet.setAttrib (FIELD_ApplyBy, HELPER_ApplyBy.toObject (_ApplyBy)); //
tl_jobPSet.setAttrib (FIELD_IncludeAssessmentCriteria, HELPER_IncludeAssessmentCriteria.toObject (_IncludeAssessmentCriteria)); // tl_jobPSet.setAttrib (FIELD_IncludeAssessmentCriteria, HELPER_IncludeAssessmentCriteria.toObject (_IncludeAssessmentCriteria)); //
tl_jobPSet.setAttrib (FIELD_IncludeCulture, HELPER_IncludeCulture.toObject (_IncludeCulture)); //
tl_jobPSet.setAttrib (FIELD_AssessmentType, HELPER_AssessmentType.toObject (_AssessmentType)); // tl_jobPSet.setAttrib (FIELD_AssessmentType, HELPER_AssessmentType.toObject (_AssessmentType)); //
tl_jobPSet.setAttrib (FIELD_RandomKey, HELPER_RandomKey.toObject (_RandomKey)); // tl_jobPSet.setAttrib (FIELD_RandomKey, HELPER_RandomKey.toObject (_RandomKey)); //
tl_jobPSet.setAttrib (FIELD_JobType, HELPER_JobType.toObject (_JobType)); // tl_jobPSet.setAttrib (FIELD_JobType, HELPER_JobType.toObject (_JobType)); //
...@@ -7443,6 +7691,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -7443,6 +7691,7 @@ public abstract class BaseJob extends BaseBusinessClass
_OpenDate = (Date)(HELPER_OpenDate.fromObject (_OpenDate, tl_jobPSet.getAttrib (FIELD_OpenDate))); // _OpenDate = (Date)(HELPER_OpenDate.fromObject (_OpenDate, tl_jobPSet.getAttrib (FIELD_OpenDate))); //
_ApplyBy = (Date)(HELPER_ApplyBy.fromObject (_ApplyBy, tl_jobPSet.getAttrib (FIELD_ApplyBy))); // _ApplyBy = (Date)(HELPER_ApplyBy.fromObject (_ApplyBy, tl_jobPSet.getAttrib (FIELD_ApplyBy))); //
_IncludeAssessmentCriteria = (Boolean)(HELPER_IncludeAssessmentCriteria.fromObject (_IncludeAssessmentCriteria, tl_jobPSet.getAttrib (FIELD_IncludeAssessmentCriteria))); // _IncludeAssessmentCriteria = (Boolean)(HELPER_IncludeAssessmentCriteria.fromObject (_IncludeAssessmentCriteria, tl_jobPSet.getAttrib (FIELD_IncludeAssessmentCriteria))); //
_IncludeCulture = (Boolean)(HELPER_IncludeCulture.fromObject (_IncludeCulture, tl_jobPSet.getAttrib (FIELD_IncludeCulture))); //
_AssessmentType = (AssessmentType)(HELPER_AssessmentType.fromObject (_AssessmentType, tl_jobPSet.getAttrib (FIELD_AssessmentType))); // _AssessmentType = (AssessmentType)(HELPER_AssessmentType.fromObject (_AssessmentType, tl_jobPSet.getAttrib (FIELD_AssessmentType))); //
_RandomKey = (String)(HELPER_RandomKey.fromObject (_RandomKey, tl_jobPSet.getAttrib (FIELD_RandomKey))); // _RandomKey = (String)(HELPER_RandomKey.fromObject (_RandomKey, tl_jobPSet.getAttrib (FIELD_RandomKey))); //
_JobType = (JobType)(HELPER_JobType.fromObject (_JobType, tl_jobPSet.getAttrib (FIELD_JobType))); // _JobType = (JobType)(HELPER_JobType.fromObject (_JobType, tl_jobPSet.getAttrib (FIELD_JobType))); //
...@@ -7542,6 +7791,15 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -7542,6 +7791,15 @@ public abstract class BaseJob extends BaseBusinessClass
try try
{ {
setIncludeCulture (otherJob.getIncludeCulture ());
}
catch (FieldException ex)
{
e.addException (ex);
}
try
{
setAssessmentType (otherJob.getAssessmentType ()); setAssessmentType (otherJob.getAssessmentType ());
} }
catch (FieldException ex) catch (FieldException ex)
...@@ -7732,6 +7990,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -7732,6 +7990,7 @@ public abstract class BaseJob extends BaseBusinessClass
_OpenDate = sourceJob._OpenDate; _OpenDate = sourceJob._OpenDate;
_ApplyBy = sourceJob._ApplyBy; _ApplyBy = sourceJob._ApplyBy;
_IncludeAssessmentCriteria = sourceJob._IncludeAssessmentCriteria; _IncludeAssessmentCriteria = sourceJob._IncludeAssessmentCriteria;
_IncludeCulture = sourceJob._IncludeCulture;
_AssessmentType = sourceJob._AssessmentType; _AssessmentType = sourceJob._AssessmentType;
_RandomKey = sourceJob._RandomKey; _RandomKey = sourceJob._RandomKey;
_JobType = sourceJob._JobType; _JobType = sourceJob._JobType;
...@@ -7764,6 +8023,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -7764,6 +8023,7 @@ public abstract class BaseJob extends BaseBusinessClass
_AssessmentTemplateName = sourceJob._AssessmentTemplateName; _AssessmentTemplateName = sourceJob._AssessmentTemplateName;
_CultureTemplateName = sourceJob._CultureTemplateName; _CultureTemplateName = sourceJob._CultureTemplateName;
_AppProcessOption = sourceJob._AppProcessOption; _AppProcessOption = sourceJob._AppProcessOption;
_SuggestedAssessmentType = sourceJob._SuggestedAssessmentType;
_RankingCompleted = sourceJob._RankingCompleted; _RankingCompleted = sourceJob._RankingCompleted;
} }
...@@ -7843,6 +8103,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -7843,6 +8103,7 @@ public abstract class BaseJob extends BaseBusinessClass
_OpenDate = (Date)(HELPER_OpenDate.readExternal (_OpenDate, vals.get(FIELD_OpenDate))); // _OpenDate = (Date)(HELPER_OpenDate.readExternal (_OpenDate, vals.get(FIELD_OpenDate))); //
_ApplyBy = (Date)(HELPER_ApplyBy.readExternal (_ApplyBy, vals.get(FIELD_ApplyBy))); // _ApplyBy = (Date)(HELPER_ApplyBy.readExternal (_ApplyBy, vals.get(FIELD_ApplyBy))); //
_IncludeAssessmentCriteria = (Boolean)(HELPER_IncludeAssessmentCriteria.readExternal (_IncludeAssessmentCriteria, vals.get(FIELD_IncludeAssessmentCriteria))); // _IncludeAssessmentCriteria = (Boolean)(HELPER_IncludeAssessmentCriteria.readExternal (_IncludeAssessmentCriteria, vals.get(FIELD_IncludeAssessmentCriteria))); //
_IncludeCulture = (Boolean)(HELPER_IncludeCulture.readExternal (_IncludeCulture, vals.get(FIELD_IncludeCulture))); //
_AssessmentType = (AssessmentType)(HELPER_AssessmentType.readExternal (_AssessmentType, vals.get(FIELD_AssessmentType))); // _AssessmentType = (AssessmentType)(HELPER_AssessmentType.readExternal (_AssessmentType, vals.get(FIELD_AssessmentType))); //
_RandomKey = (String)(HELPER_RandomKey.readExternal (_RandomKey, vals.get(FIELD_RandomKey))); // _RandomKey = (String)(HELPER_RandomKey.readExternal (_RandomKey, vals.get(FIELD_RandomKey))); //
_JobType = (JobType)(HELPER_JobType.readExternal (_JobType, vals.get(FIELD_JobType))); // _JobType = (JobType)(HELPER_JobType.readExternal (_JobType, vals.get(FIELD_JobType))); //
...@@ -7875,6 +8136,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -7875,6 +8136,7 @@ public abstract class BaseJob extends BaseBusinessClass
_AssessmentTemplateName = (String)(HELPER_AssessmentTemplateName.readExternal (_AssessmentTemplateName, vals.get(FIELD_AssessmentTemplateName))); // _AssessmentTemplateName = (String)(HELPER_AssessmentTemplateName.readExternal (_AssessmentTemplateName, vals.get(FIELD_AssessmentTemplateName))); //
_CultureTemplateName = (String)(HELPER_CultureTemplateName.readExternal (_CultureTemplateName, vals.get(FIELD_CultureTemplateName))); // _CultureTemplateName = (String)(HELPER_CultureTemplateName.readExternal (_CultureTemplateName, vals.get(FIELD_CultureTemplateName))); //
_AppProcessOption = (AppProcessOption)(HELPER_AppProcessOption.readExternal (_AppProcessOption, vals.get(FIELD_AppProcessOption))); // _AppProcessOption = (AppProcessOption)(HELPER_AppProcessOption.readExternal (_AppProcessOption, vals.get(FIELD_AppProcessOption))); //
_SuggestedAssessmentType = (AssessmentType)(HELPER_SuggestedAssessmentType.readExternal (_SuggestedAssessmentType, vals.get(FIELD_SuggestedAssessmentType))); //
_RankingCompleted = (Boolean)(HELPER_RankingCompleted.readExternal (_RankingCompleted, vals.get(FIELD_RankingCompleted))); // _RankingCompleted = (Boolean)(HELPER_RankingCompleted.readExternal (_RankingCompleted, vals.get(FIELD_RankingCompleted))); //
_CultureTemplate.readExternalData(vals.get(SINGLEREFERENCE_CultureTemplate)); _CultureTemplate.readExternalData(vals.get(SINGLEREFERENCE_CultureTemplate));
_JobTemplate.readExternalData(vals.get(SINGLEREFERENCE_JobTemplate)); _JobTemplate.readExternalData(vals.get(SINGLEREFERENCE_JobTemplate));
...@@ -7909,6 +8171,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -7909,6 +8171,7 @@ public abstract class BaseJob extends BaseBusinessClass
vals.put (FIELD_OpenDate, HELPER_OpenDate.writeExternal (_OpenDate)); vals.put (FIELD_OpenDate, HELPER_OpenDate.writeExternal (_OpenDate));
vals.put (FIELD_ApplyBy, HELPER_ApplyBy.writeExternal (_ApplyBy)); vals.put (FIELD_ApplyBy, HELPER_ApplyBy.writeExternal (_ApplyBy));
vals.put (FIELD_IncludeAssessmentCriteria, HELPER_IncludeAssessmentCriteria.writeExternal (_IncludeAssessmentCriteria)); vals.put (FIELD_IncludeAssessmentCriteria, HELPER_IncludeAssessmentCriteria.writeExternal (_IncludeAssessmentCriteria));
vals.put (FIELD_IncludeCulture, HELPER_IncludeCulture.writeExternal (_IncludeCulture));
vals.put (FIELD_AssessmentType, HELPER_AssessmentType.writeExternal (_AssessmentType)); vals.put (FIELD_AssessmentType, HELPER_AssessmentType.writeExternal (_AssessmentType));
vals.put (FIELD_RandomKey, HELPER_RandomKey.writeExternal (_RandomKey)); vals.put (FIELD_RandomKey, HELPER_RandomKey.writeExternal (_RandomKey));
vals.put (FIELD_JobType, HELPER_JobType.writeExternal (_JobType)); vals.put (FIELD_JobType, HELPER_JobType.writeExternal (_JobType));
...@@ -7941,6 +8204,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -7941,6 +8204,7 @@ public abstract class BaseJob extends BaseBusinessClass
vals.put (FIELD_AssessmentTemplateName, HELPER_AssessmentTemplateName.writeExternal (_AssessmentTemplateName)); vals.put (FIELD_AssessmentTemplateName, HELPER_AssessmentTemplateName.writeExternal (_AssessmentTemplateName));
vals.put (FIELD_CultureTemplateName, HELPER_CultureTemplateName.writeExternal (_CultureTemplateName)); vals.put (FIELD_CultureTemplateName, HELPER_CultureTemplateName.writeExternal (_CultureTemplateName));
vals.put (FIELD_AppProcessOption, HELPER_AppProcessOption.writeExternal (_AppProcessOption)); vals.put (FIELD_AppProcessOption, HELPER_AppProcessOption.writeExternal (_AppProcessOption));
vals.put (FIELD_SuggestedAssessmentType, HELPER_SuggestedAssessmentType.writeExternal (_SuggestedAssessmentType));
vals.put (FIELD_RankingCompleted, HELPER_RankingCompleted.writeExternal (_RankingCompleted)); vals.put (FIELD_RankingCompleted, HELPER_RankingCompleted.writeExternal (_RankingCompleted));
vals.put (SINGLEREFERENCE_CultureTemplate, _CultureTemplate.writeExternalData()); vals.put (SINGLEREFERENCE_CultureTemplate, _CultureTemplate.writeExternalData());
vals.put (SINGLEREFERENCE_JobTemplate, _JobTemplate.writeExternalData()); vals.put (SINGLEREFERENCE_JobTemplate, _JobTemplate.writeExternalData());
...@@ -7995,6 +8259,10 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -7995,6 +8259,10 @@ public abstract class BaseJob extends BaseBusinessClass
{ {
listener.notifyFieldChange(this, other, FIELD_IncludeAssessmentCriteria, HELPER_IncludeAssessmentCriteria.toObject(this._IncludeAssessmentCriteria), HELPER_IncludeAssessmentCriteria.toObject(otherJob._IncludeAssessmentCriteria)); listener.notifyFieldChange(this, other, FIELD_IncludeAssessmentCriteria, HELPER_IncludeAssessmentCriteria.toObject(this._IncludeAssessmentCriteria), HELPER_IncludeAssessmentCriteria.toObject(otherJob._IncludeAssessmentCriteria));
} }
if (!HELPER_IncludeCulture.compare(this._IncludeCulture, otherJob._IncludeCulture))
{
listener.notifyFieldChange(this, other, FIELD_IncludeCulture, HELPER_IncludeCulture.toObject(this._IncludeCulture), HELPER_IncludeCulture.toObject(otherJob._IncludeCulture));
}
if (!HELPER_AssessmentType.compare(this._AssessmentType, otherJob._AssessmentType)) if (!HELPER_AssessmentType.compare(this._AssessmentType, otherJob._AssessmentType))
{ {
listener.notifyFieldChange(this, other, FIELD_AssessmentType, HELPER_AssessmentType.toObject(this._AssessmentType), HELPER_AssessmentType.toObject(otherJob._AssessmentType)); listener.notifyFieldChange(this, other, FIELD_AssessmentType, HELPER_AssessmentType.toObject(this._AssessmentType), HELPER_AssessmentType.toObject(otherJob._AssessmentType));
...@@ -8114,6 +8382,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -8114,6 +8382,7 @@ public abstract class BaseJob extends BaseBusinessClass
visitor.visitField(this, FIELD_AssessmentTemplateName, HELPER_AssessmentTemplateName.toObject(getAssessmentTemplateName())); visitor.visitField(this, FIELD_AssessmentTemplateName, HELPER_AssessmentTemplateName.toObject(getAssessmentTemplateName()));
visitor.visitField(this, FIELD_CultureTemplateName, HELPER_CultureTemplateName.toObject(getCultureTemplateName())); visitor.visitField(this, FIELD_CultureTemplateName, HELPER_CultureTemplateName.toObject(getCultureTemplateName()));
visitor.visitField(this, FIELD_AppProcessOption, HELPER_AppProcessOption.toObject(getAppProcessOption())); visitor.visitField(this, FIELD_AppProcessOption, HELPER_AppProcessOption.toObject(getAppProcessOption()));
visitor.visitField(this, FIELD_SuggestedAssessmentType, HELPER_SuggestedAssessmentType.toObject(getSuggestedAssessmentType()));
visitor.visitField(this, FIELD_RankingCompleted, HELPER_RankingCompleted.toObject(getRankingCompleted())); visitor.visitField(this, FIELD_RankingCompleted, HELPER_RankingCompleted.toObject(getRankingCompleted()));
} }
...@@ -8129,6 +8398,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -8129,6 +8398,7 @@ public abstract class BaseJob extends BaseBusinessClass
visitor.visitField(this, FIELD_OpenDate, HELPER_OpenDate.toObject(getOpenDate())); visitor.visitField(this, FIELD_OpenDate, HELPER_OpenDate.toObject(getOpenDate()));
visitor.visitField(this, FIELD_ApplyBy, HELPER_ApplyBy.toObject(getApplyBy())); visitor.visitField(this, FIELD_ApplyBy, HELPER_ApplyBy.toObject(getApplyBy()));
visitor.visitField(this, FIELD_IncludeAssessmentCriteria, HELPER_IncludeAssessmentCriteria.toObject(getIncludeAssessmentCriteria())); visitor.visitField(this, FIELD_IncludeAssessmentCriteria, HELPER_IncludeAssessmentCriteria.toObject(getIncludeAssessmentCriteria()));
visitor.visitField(this, FIELD_IncludeCulture, HELPER_IncludeCulture.toObject(getIncludeCulture()));
visitor.visitField(this, FIELD_AssessmentType, HELPER_AssessmentType.toObject(getAssessmentType())); visitor.visitField(this, FIELD_AssessmentType, HELPER_AssessmentType.toObject(getAssessmentType()));
visitor.visitField(this, FIELD_RandomKey, HELPER_RandomKey.toObject(getRandomKey())); visitor.visitField(this, FIELD_RandomKey, HELPER_RandomKey.toObject(getRandomKey()));
visitor.visitField(this, FIELD_JobType, HELPER_JobType.toObject(getJobType())); visitor.visitField(this, FIELD_JobType, HELPER_JobType.toObject(getJobType()));
...@@ -8285,6 +8555,10 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -8285,6 +8555,10 @@ public abstract class BaseJob extends BaseBusinessClass
{ {
return filter.matches (getIncludeAssessmentCriteria ()); return filter.matches (getIncludeAssessmentCriteria ());
} }
else if (attribName.equals (FIELD_IncludeCulture))
{
return filter.matches (getIncludeCulture ());
}
else if (attribName.equals (FIELD_AssessmentType)) else if (attribName.equals (FIELD_AssessmentType))
{ {
return filter.matches (getAssessmentType ()); return filter.matches (getAssessmentType ());
...@@ -8464,6 +8738,12 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -8464,6 +8738,12 @@ public abstract class BaseJob extends BaseBusinessClass
return this; return this;
} }
public SearchAll andIncludeCulture (QueryFilter<Boolean> filter)
{
filter.addFilter (context, "tl_job.include_culture", "IncludeCulture");
return this;
}
public SearchAll andAssessmentType (QueryFilter<AssessmentType> filter) public SearchAll andAssessmentType (QueryFilter<AssessmentType> filter)
{ {
filter.addFilter (context, "tl_job.assessment_type", "AssessmentType"); filter.addFilter (context, "tl_job.assessment_type", "AssessmentType");
...@@ -8731,6 +9011,12 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -8731,6 +9011,12 @@ public abstract class BaseJob extends BaseBusinessClass
return this; return this;
} }
public SearchJobKey andIncludeCulture (QueryFilter<Boolean> filter)
{
filter.addFilter (context, "tl_job.include_culture", "IncludeCulture");
return this;
}
public SearchJobKey andAssessmentType (QueryFilter<AssessmentType> filter) public SearchJobKey andAssessmentType (QueryFilter<AssessmentType> filter)
{ {
filter.addFilter (context, "tl_job.assessment_type", "AssessmentType"); filter.addFilter (context, "tl_job.assessment_type", "AssessmentType");
...@@ -8992,6 +9278,12 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -8992,6 +9278,12 @@ public abstract class BaseJob extends BaseBusinessClass
return this; return this;
} }
public SearchCompany andIncludeCulture (QueryFilter<Boolean> filter)
{
filter.addFilter (context, "tl_job.include_culture", "IncludeCulture");
return this;
}
public SearchCompany andAssessmentType (QueryFilter<AssessmentType> filter) public SearchCompany andAssessmentType (QueryFilter<AssessmentType> filter)
{ {
filter.addFilter (context, "tl_job.assessment_type", "AssessmentType"); filter.addFilter (context, "tl_job.assessment_type", "AssessmentType");
...@@ -9254,6 +9546,12 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -9254,6 +9546,12 @@ public abstract class BaseJob extends BaseBusinessClass
return this; return this;
} }
public SearchDetails andIncludeCulture (QueryFilter<Boolean> filter)
{
filter.addFilter (context, "tl_job.include_culture", "IncludeCulture");
return this;
}
public SearchDetails andAssessmentType (QueryFilter<AssessmentType> filter) public SearchDetails andAssessmentType (QueryFilter<AssessmentType> filter)
{ {
filter.addFilter (context, "tl_job.assessment_type", "AssessmentType"); filter.addFilter (context, "tl_job.assessment_type", "AssessmentType");
...@@ -9482,6 +9780,10 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -9482,6 +9780,10 @@ public abstract class BaseJob extends BaseBusinessClass
{ {
return HELPER_IncludeAssessmentCriteria.toObject (getIncludeAssessmentCriteria ()); return HELPER_IncludeAssessmentCriteria.toObject (getIncludeAssessmentCriteria ());
} }
else if (attribName.equals (FIELD_IncludeCulture))
{
return HELPER_IncludeCulture.toObject (getIncludeCulture ());
}
else if (attribName.equals (FIELD_AssessmentType)) else if (attribName.equals (FIELD_AssessmentType))
{ {
return HELPER_AssessmentType.toObject (getAssessmentType ()); return HELPER_AssessmentType.toObject (getAssessmentType ());
...@@ -9610,6 +9912,10 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -9610,6 +9912,10 @@ public abstract class BaseJob extends BaseBusinessClass
{ {
return HELPER_AppProcessOption.toObject (getAppProcessOption ()); return HELPER_AppProcessOption.toObject (getAppProcessOption ());
} }
else if (attribName.equals (FIELD_SuggestedAssessmentType))
{
return HELPER_SuggestedAssessmentType.toObject (getSuggestedAssessmentType ());
}
else if (attribName.equals (FIELD_RankingCompleted)) else if (attribName.equals (FIELD_RankingCompleted))
{ {
return HELPER_RankingCompleted.toObject (getRankingCompleted ()); return HELPER_RankingCompleted.toObject (getRankingCompleted ());
...@@ -9651,6 +9957,10 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -9651,6 +9957,10 @@ public abstract class BaseJob extends BaseBusinessClass
{ {
return HELPER_IncludeAssessmentCriteria; return HELPER_IncludeAssessmentCriteria;
} }
else if (attribName.equals (FIELD_IncludeCulture))
{
return HELPER_IncludeCulture;
}
else if (attribName.equals (FIELD_AssessmentType)) else if (attribName.equals (FIELD_AssessmentType))
{ {
return HELPER_AssessmentType; return HELPER_AssessmentType;
...@@ -9779,6 +10089,10 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -9779,6 +10089,10 @@ public abstract class BaseJob extends BaseBusinessClass
{ {
return HELPER_AppProcessOption; return HELPER_AppProcessOption;
} }
else if (attribName.equals (FIELD_SuggestedAssessmentType))
{
return HELPER_SuggestedAssessmentType;
}
else if (attribName.equals (FIELD_RankingCompleted)) else if (attribName.equals (FIELD_RankingCompleted))
{ {
return HELPER_RankingCompleted; return HELPER_RankingCompleted;
...@@ -9820,6 +10134,10 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -9820,6 +10134,10 @@ public abstract class BaseJob extends BaseBusinessClass
{ {
setIncludeAssessmentCriteria ((Boolean)(HELPER_IncludeAssessmentCriteria.fromObject (_IncludeAssessmentCriteria, attribValue))); setIncludeAssessmentCriteria ((Boolean)(HELPER_IncludeAssessmentCriteria.fromObject (_IncludeAssessmentCriteria, attribValue)));
} }
else if (attribName.equals (FIELD_IncludeCulture))
{
setIncludeCulture ((Boolean)(HELPER_IncludeCulture.fromObject (_IncludeCulture, attribValue)));
}
else if (attribName.equals (FIELD_AssessmentType)) else if (attribName.equals (FIELD_AssessmentType))
{ {
setAssessmentType ((AssessmentType)(HELPER_AssessmentType.fromObject (_AssessmentType, attribValue))); setAssessmentType ((AssessmentType)(HELPER_AssessmentType.fromObject (_AssessmentType, attribValue)));
...@@ -9948,6 +10266,10 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -9948,6 +10266,10 @@ public abstract class BaseJob extends BaseBusinessClass
{ {
setAppProcessOption ((AppProcessOption)(HELPER_AppProcessOption.fromObject (_AppProcessOption, attribValue))); setAppProcessOption ((AppProcessOption)(HELPER_AppProcessOption.fromObject (_AppProcessOption, attribValue)));
} }
else if (attribName.equals (FIELD_SuggestedAssessmentType))
{
setSuggestedAssessmentType ((AssessmentType)(HELPER_SuggestedAssessmentType.fromObject (_SuggestedAssessmentType, attribValue)));
}
else if (attribName.equals (FIELD_RankingCompleted)) else if (attribName.equals (FIELD_RankingCompleted))
{ {
setRankingCompleted ((Boolean)(HELPER_RankingCompleted.fromObject (_RankingCompleted, attribValue))); setRankingCompleted ((Boolean)(HELPER_RankingCompleted.fromObject (_RankingCompleted, attribValue)));
...@@ -9996,6 +10318,10 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -9996,6 +10318,10 @@ public abstract class BaseJob extends BaseBusinessClass
{ {
return getWriteability_IncludeAssessmentCriteria (); return getWriteability_IncludeAssessmentCriteria ();
} }
else if (fieldName.equals (FIELD_IncludeCulture))
{
return getWriteability_IncludeCulture ();
}
else if (fieldName.equals (FIELD_AssessmentType)) else if (fieldName.equals (FIELD_AssessmentType))
{ {
return getWriteability_AssessmentType (); return getWriteability_AssessmentType ();
...@@ -10176,6 +10502,10 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -10176,6 +10502,10 @@ public abstract class BaseJob extends BaseBusinessClass
{ {
return getWriteability_AppProcessOption (); return getWriteability_AppProcessOption ();
} }
else if (fieldName.equals (FIELD_SuggestedAssessmentType))
{
return getWriteability_SuggestedAssessmentType ();
}
else if (fieldName.equals (FIELD_RankingCompleted)) else if (fieldName.equals (FIELD_RankingCompleted))
{ {
return getWriteability_RankingCompleted (); return getWriteability_RankingCompleted ();
...@@ -10232,6 +10562,11 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -10232,6 +10562,11 @@ public abstract class BaseJob extends BaseBusinessClass
fields.add (FIELD_IncludeAssessmentCriteria); fields.add (FIELD_IncludeAssessmentCriteria);
} }
if (getWriteability_IncludeCulture () != FieldWriteability.TRUE)
{
fields.add (FIELD_IncludeCulture);
}
if (getWriteability_AssessmentType () != FieldWriteability.TRUE) if (getWriteability_AssessmentType () != FieldWriteability.TRUE)
{ {
fields.add (FIELD_AssessmentType); fields.add (FIELD_AssessmentType);
...@@ -10392,6 +10727,11 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -10392,6 +10727,11 @@ public abstract class BaseJob extends BaseBusinessClass
fields.add (FIELD_AppProcessOption); fields.add (FIELD_AppProcessOption);
} }
if (getWriteability_SuggestedAssessmentType () != FieldWriteability.TRUE)
{
fields.add (FIELD_SuggestedAssessmentType);
}
if (getWriteability_RankingCompleted () != FieldWriteability.TRUE) if (getWriteability_RankingCompleted () != FieldWriteability.TRUE)
{ {
fields.add (FIELD_RankingCompleted); fields.add (FIELD_RankingCompleted);
...@@ -10412,6 +10752,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -10412,6 +10752,7 @@ public abstract class BaseJob extends BaseBusinessClass
result.add(HELPER_OpenDate.getAttribObject (getClass (), _OpenDate, false, FIELD_OpenDate)); result.add(HELPER_OpenDate.getAttribObject (getClass (), _OpenDate, false, FIELD_OpenDate));
result.add(HELPER_ApplyBy.getAttribObject (getClass (), _ApplyBy, false, FIELD_ApplyBy)); result.add(HELPER_ApplyBy.getAttribObject (getClass (), _ApplyBy, false, FIELD_ApplyBy));
result.add(HELPER_IncludeAssessmentCriteria.getAttribObject (getClass (), _IncludeAssessmentCriteria, true, FIELD_IncludeAssessmentCriteria)); result.add(HELPER_IncludeAssessmentCriteria.getAttribObject (getClass (), _IncludeAssessmentCriteria, true, FIELD_IncludeAssessmentCriteria));
result.add(HELPER_IncludeCulture.getAttribObject (getClass (), _IncludeCulture, true, FIELD_IncludeCulture));
result.add(HELPER_AssessmentType.getAttribObject (getClass (), _AssessmentType, true, FIELD_AssessmentType)); result.add(HELPER_AssessmentType.getAttribObject (getClass (), _AssessmentType, true, FIELD_AssessmentType));
result.add(HELPER_RandomKey.getAttribObject (getClass (), _RandomKey, false, FIELD_RandomKey)); result.add(HELPER_RandomKey.getAttribObject (getClass (), _RandomKey, false, FIELD_RandomKey));
result.add(HELPER_JobType.getAttribObject (getClass (), _JobType, true, FIELD_JobType)); result.add(HELPER_JobType.getAttribObject (getClass (), _JobType, true, FIELD_JobType));
...@@ -10444,6 +10785,7 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -10444,6 +10785,7 @@ public abstract class BaseJob extends BaseBusinessClass
result.add(HELPER_AssessmentTemplateName.getAttribObject (getClass (), _AssessmentTemplateName, false, FIELD_AssessmentTemplateName)); result.add(HELPER_AssessmentTemplateName.getAttribObject (getClass (), _AssessmentTemplateName, false, FIELD_AssessmentTemplateName));
result.add(HELPER_CultureTemplateName.getAttribObject (getClass (), _CultureTemplateName, false, FIELD_CultureTemplateName)); result.add(HELPER_CultureTemplateName.getAttribObject (getClass (), _CultureTemplateName, false, FIELD_CultureTemplateName));
result.add(HELPER_AppProcessOption.getAttribObject (getClass (), _AppProcessOption, false, FIELD_AppProcessOption)); result.add(HELPER_AppProcessOption.getAttribObject (getClass (), _AppProcessOption, false, FIELD_AppProcessOption));
result.add(HELPER_SuggestedAssessmentType.getAttribObject (getClass (), _SuggestedAssessmentType, false, FIELD_SuggestedAssessmentType));
result.add(HELPER_RankingCompleted.getAttribObject (getClass (), _RankingCompleted, false, FIELD_RankingCompleted)); result.add(HELPER_RankingCompleted.getAttribObject (getClass (), _RankingCompleted, false, FIELD_RankingCompleted));
return result; return result;
...@@ -10604,6 +10946,24 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -10604,6 +10946,24 @@ public abstract class BaseJob extends BaseBusinessClass
} }
/** /**
* Get the attribute IncludeCulture
*/
public Boolean getIncludeCulture (Job obj, Boolean original)
{
return original;
}
/**
* Change the value set for attribute IncludeCulture.
* May modify the field beforehand
* Occurs before validation.
*/
public Boolean setIncludeCulture (Job obj, Boolean newIncludeCulture) throws FieldException
{
return newIncludeCulture;
}
/**
* Get the attribute AssessmentType * Get the attribute AssessmentType
*/ */
public AssessmentType getAssessmentType (Job obj, AssessmentType original) public AssessmentType getAssessmentType (Job obj, AssessmentType original)
...@@ -11180,6 +11540,24 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -11180,6 +11540,24 @@ public abstract class BaseJob extends BaseBusinessClass
} }
/** /**
* Get the attribute SuggestedAssessmentType
*/
public AssessmentType getSuggestedAssessmentType (Job obj, AssessmentType original)
{
return original;
}
/**
* Change the value set for attribute SuggestedAssessmentType.
* May modify the field beforehand
* Occurs before validation.
*/
public AssessmentType setSuggestedAssessmentType (Job obj, AssessmentType newSuggestedAssessmentType) throws FieldException
{
return newSuggestedAssessmentType;
}
/**
* Get the attribute RankingCompleted * Get the attribute RankingCompleted
*/ */
public Boolean getRankingCompleted (Job obj, Boolean original) public Boolean getRankingCompleted (Job obj, Boolean original)
...@@ -11317,6 +11695,10 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -11317,6 +11695,10 @@ public abstract class BaseJob extends BaseBusinessClass
{ {
return toAppProcessOption (); return toAppProcessOption ();
} }
if (name.equals ("SuggestedAssessmentType"))
{
return toSuggestedAssessmentType ();
}
if (name.equals ("RankingCompleted")) if (name.equals ("RankingCompleted"))
{ {
return toRankingCompleted (); return toRankingCompleted ();
...@@ -11357,6 +11739,10 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -11357,6 +11739,10 @@ public abstract class BaseJob extends BaseBusinessClass
{ {
return toIncludeAssessmentCriteria (); return toIncludeAssessmentCriteria ();
} }
if (name.equals ("IncludeCulture"))
{
return toIncludeCulture ();
}
if (name.equals ("AssessmentType")) if (name.equals ("AssessmentType"))
{ {
return toAssessmentType (); return toAssessmentType ();
...@@ -11501,6 +11887,8 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -11501,6 +11887,8 @@ public abstract class BaseJob extends BaseBusinessClass
public PipeLine<From, AppProcessOption> toAppProcessOption () { return pipe(new ORMAttributePipe<Me, AppProcessOption>(FIELD_AppProcessOption)); } public PipeLine<From, AppProcessOption> toAppProcessOption () { return pipe(new ORMAttributePipe<Me, AppProcessOption>(FIELD_AppProcessOption)); }
public PipeLine<From, AssessmentType> toSuggestedAssessmentType () { return pipe(new ORMAttributePipe<Me, AssessmentType>(FIELD_SuggestedAssessmentType)); }
public PipeLine<From, Boolean> toRankingCompleted () { return pipe(new ORMAttributePipe<Me, Boolean>(FIELD_RankingCompleted)); } public PipeLine<From, Boolean> toRankingCompleted () { return pipe(new ORMAttributePipe<Me, Boolean>(FIELD_RankingCompleted)); }
public PipeLine<From, String> toJobTitle () { return pipe(new ORMAttributePipe<Me, String>(FIELD_JobTitle)); } public PipeLine<From, String> toJobTitle () { return pipe(new ORMAttributePipe<Me, String>(FIELD_JobTitle)); }
...@@ -11515,6 +11903,8 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -11515,6 +11903,8 @@ public abstract class BaseJob extends BaseBusinessClass
public PipeLine<From, Boolean> toIncludeAssessmentCriteria () { return pipe(new ORMAttributePipe<Me, Boolean>(FIELD_IncludeAssessmentCriteria)); } public PipeLine<From, Boolean> toIncludeAssessmentCriteria () { return pipe(new ORMAttributePipe<Me, Boolean>(FIELD_IncludeAssessmentCriteria)); }
public PipeLine<From, Boolean> toIncludeCulture () { return pipe(new ORMAttributePipe<Me, Boolean>(FIELD_IncludeCulture)); }
public PipeLine<From, AssessmentType> toAssessmentType () { return pipe(new ORMAttributePipe<Me, AssessmentType>(FIELD_AssessmentType)); } public PipeLine<From, AssessmentType> toAssessmentType () { return pipe(new ORMAttributePipe<Me, AssessmentType>(FIELD_AssessmentType)); }
public PipeLine<From, String> toRandomKey () { return pipe(new ORMAttributePipe<Me, String>(FIELD_RandomKey)); } public PipeLine<From, String> toRandomKey () { return pipe(new ORMAttributePipe<Me, String>(FIELD_RandomKey)); }
...@@ -11719,6 +12109,11 @@ public abstract class BaseJob extends BaseBusinessClass ...@@ -11719,6 +12109,11 @@ public abstract class BaseJob extends BaseBusinessClass
return true; return true;
} }
if(CollectionUtils.equals(attribName, "SuggestedAssessmentType"))
{
return true;
}
if(CollectionUtils.equals(attribName, "RankingCompleted")) if(CollectionUtils.equals(attribName, "RankingCompleted"))
{ {
return true; return true;
......
...@@ -44,7 +44,9 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -44,7 +44,9 @@ public abstract class BaseOccupation extends BaseBusinessClass
public static final String FIELD_Name = "Name"; public static final String FIELD_Name = "Name";
public static final String FIELD_Level = "Level"; public static final String FIELD_Level = "Level";
public static final String FIELD_AssessmentType = "AssessmentType"; public static final String FIELD_AssessmentType = "AssessmentType";
public static final String FIELD_PartTimeAssessmentType = "PartTimeAssessmentType";
public static final String SINGLEREFERENCE_AssessmentLevel = "AssessmentLevel"; public static final String SINGLEREFERENCE_AssessmentLevel = "AssessmentLevel";
public static final String SINGLEREFERENCE_ExpressAssessmentLevel = "ExpressAssessmentLevel";
public static final String SINGLEREFERENCE_ParentOccupation = "ParentOccupation"; public static final String SINGLEREFERENCE_ParentOccupation = "ParentOccupation";
public static final String BACKREF_ParentOccupation = ""; public static final String BACKREF_ParentOccupation = "";
public static final String MULTIPLEREFERENCE_ChildOccupations = "ChildOccupations"; public static final String MULTIPLEREFERENCE_ChildOccupations = "ChildOccupations";
...@@ -59,6 +61,7 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -59,6 +61,7 @@ public abstract class BaseOccupation extends BaseBusinessClass
private static final DefaultAttributeHelper<Occupation> HELPER_Name = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper<Occupation> HELPER_Name = DefaultAttributeHelper.INSTANCE;
private static final EnumeratedAttributeHelper<Occupation, OccupationLevel> HELPER_Level = new EnumeratedAttributeHelper<Occupation, OccupationLevel> (OccupationLevel.FACTORY_OccupationLevel); private static final EnumeratedAttributeHelper<Occupation, OccupationLevel> HELPER_Level = new EnumeratedAttributeHelper<Occupation, OccupationLevel> (OccupationLevel.FACTORY_OccupationLevel);
private static final EnumeratedAttributeHelper<Occupation, AssessmentType> HELPER_AssessmentType = new EnumeratedAttributeHelper<Occupation, AssessmentType> (AssessmentType.FACTORY_AssessmentType); private static final EnumeratedAttributeHelper<Occupation, AssessmentType> HELPER_AssessmentType = new EnumeratedAttributeHelper<Occupation, AssessmentType> (AssessmentType.FACTORY_AssessmentType);
private static final EnumeratedAttributeHelper<Occupation, AssessmentType> HELPER_PartTimeAssessmentType = new EnumeratedAttributeHelper<Occupation, AssessmentType> (AssessmentType.FACTORY_AssessmentType);
// Private attributes corresponding to business object data // Private attributes corresponding to business object data
...@@ -66,10 +69,12 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -66,10 +69,12 @@ public abstract class BaseOccupation extends BaseBusinessClass
private String _Name; private String _Name;
private OccupationLevel _Level; private OccupationLevel _Level;
private AssessmentType _AssessmentType; private AssessmentType _AssessmentType;
private AssessmentType _PartTimeAssessmentType;
// Private attributes corresponding to single references // Private attributes corresponding to single references
private SingleAssociation<Occupation, Level> _AssessmentLevel; private SingleAssociation<Occupation, Level> _AssessmentLevel;
private SingleAssociation<Occupation, Level> _ExpressAssessmentLevel;
private SingleAssociation<Occupation, Occupation> _ParentOccupation; private SingleAssociation<Occupation, Occupation> _ParentOccupation;
...@@ -85,6 +90,7 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -85,6 +90,7 @@ public abstract class BaseOccupation extends BaseBusinessClass
private static final AttributeValidator[] FIELD_Name_Validators; private static final AttributeValidator[] FIELD_Name_Validators;
private static final AttributeValidator[] FIELD_Level_Validators; private static final AttributeValidator[] FIELD_Level_Validators;
private static final AttributeValidator[] FIELD_AssessmentType_Validators; private static final AttributeValidator[] FIELD_AssessmentType_Validators;
private static final AttributeValidator[] FIELD_PartTimeAssessmentType_Validators;
// Arrays of behaviour decorators // Arrays of behaviour decorators
...@@ -102,11 +108,13 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -102,11 +108,13 @@ public abstract class BaseOccupation extends BaseBusinessClass
setupAssocMetaData_ChildOccupations(); setupAssocMetaData_ChildOccupations();
setupAssocMetaData_AssessmentLevel(); setupAssocMetaData_AssessmentLevel();
setupAssocMetaData_ExpressAssessmentLevel();
setupAssocMetaData_ParentOccupation(); setupAssocMetaData_ParentOccupation();
FIELD_Code_Validators = (AttributeValidator[])setupAttribMetaData_Code(validatorMapping).toArray (new AttributeValidator[0]); FIELD_Code_Validators = (AttributeValidator[])setupAttribMetaData_Code(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_Name_Validators = (AttributeValidator[])setupAttribMetaData_Name(validatorMapping).toArray (new AttributeValidator[0]); FIELD_Name_Validators = (AttributeValidator[])setupAttribMetaData_Name(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_Level_Validators = (AttributeValidator[])setupAttribMetaData_Level(validatorMapping).toArray (new AttributeValidator[0]); FIELD_Level_Validators = (AttributeValidator[])setupAttribMetaData_Level(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_AssessmentType_Validators = (AttributeValidator[])setupAttribMetaData_AssessmentType(validatorMapping).toArray (new AttributeValidator[0]); FIELD_AssessmentType_Validators = (AttributeValidator[])setupAttribMetaData_AssessmentType(validatorMapping).toArray (new AttributeValidator[0]);
FIELD_PartTimeAssessmentType_Validators = (AttributeValidator[])setupAttribMetaData_PartTimeAssessmentType(validatorMapping).toArray (new AttributeValidator[0]);
REFERENCE_Occupation.initialiseReference (); REFERENCE_Occupation.initialiseReference ();
...@@ -150,6 +158,20 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -150,6 +158,20 @@ public abstract class BaseOccupation extends BaseBusinessClass
// Meta Info setup // Meta Info setup
private static void setupAssocMetaData_ExpressAssessmentLevel()
{
Map metaInfo = new HashMap ();
metaInfo.put ("dbcol", "express_assessment_level_id");
metaInfo.put ("name", "ExpressAssessmentLevel");
metaInfo.put ("type", "Level");
LogMgr.log (BUSINESS_OBJECTS, LogLevel.DEBUG2, "Metadata for Occupation.ExpressAssessmentLevel:", metaInfo);
ATTRIBUTES_METADATA_Occupation.put (SINGLEREFERENCE_ExpressAssessmentLevel, Collections.unmodifiableMap (metaInfo));
}
// Meta Info setup
private static void setupAssocMetaData_ParentOccupation() private static void setupAssocMetaData_ParentOccupation()
{ {
Map metaInfo = new HashMap (); Map metaInfo = new HashMap ();
...@@ -244,6 +266,25 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -244,6 +266,25 @@ public abstract class BaseOccupation extends BaseBusinessClass
return validators; return validators;
} }
// Meta Info setup
private static List setupAttribMetaData_PartTimeAssessmentType(Map validatorMapping)
{
Map metaInfo = new HashMap ();
metaInfo.put ("attribHelper", "EnumeratedAttributeHelper");
metaInfo.put ("dbcol", "parttime_assessment_type");
metaInfo.put ("name", "PartTimeAssessmentType");
metaInfo.put ("type", "AssessmentType");
LogMgr.log (BUSINESS_OBJECTS, LogLevel.DEBUG2, "Metadata for Occupation.PartTimeAssessmentType:", metaInfo);
ATTRIBUTES_METADATA_Occupation.put (FIELD_PartTimeAssessmentType, Collections.unmodifiableMap (metaInfo));
List validators = BaseBusinessClass.getAttribValidators(Occupation.class, "PartTimeAssessmentType", metaInfo, validatorMapping);
LogMgr.log (BUSINESS_OBJECTS, LogLevel.DEBUG1, "Validators for Occupation.PartTimeAssessmentType:", validators);
return validators;
}
// END OF STATIC METADATA DEFINITION // END OF STATIC METADATA DEFINITION
...@@ -275,6 +316,7 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -275,6 +316,7 @@ public abstract class BaseOccupation extends BaseBusinessClass
_Name = (String)(HELPER_Name.initialise (_Name)); _Name = (String)(HELPER_Name.initialise (_Name));
_Level = (OccupationLevel)(HELPER_Level.initialise (_Level)); _Level = (OccupationLevel)(HELPER_Level.initialise (_Level));
_AssessmentType = (AssessmentType)(HELPER_AssessmentType.initialise (_AssessmentType)); _AssessmentType = (AssessmentType)(HELPER_AssessmentType.initialise (_AssessmentType));
_PartTimeAssessmentType = (AssessmentType)(HELPER_PartTimeAssessmentType.initialise (_PartTimeAssessmentType));
} }
...@@ -284,6 +326,7 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -284,6 +326,7 @@ public abstract class BaseOccupation extends BaseBusinessClass
super._initialiseAssociations (); super._initialiseAssociations ();
_AssessmentLevel = new SingleAssociation<Occupation, Level> (this, SINGLEREFERENCE_AssessmentLevel, null, Level.REFERENCE_Level, "tl_occupation"); _AssessmentLevel = new SingleAssociation<Occupation, Level> (this, SINGLEREFERENCE_AssessmentLevel, null, Level.REFERENCE_Level, "tl_occupation");
_ExpressAssessmentLevel = new SingleAssociation<Occupation, Level> (this, SINGLEREFERENCE_ExpressAssessmentLevel, null, Level.REFERENCE_Level, "tl_occupation");
_ParentOccupation = new SingleAssociation<Occupation, Occupation> (this, SINGLEREFERENCE_ParentOccupation, Occupation.MULTIPLEREFERENCE_ChildOccupations, Occupation.REFERENCE_Occupation, "tl_occupation"); _ParentOccupation = new SingleAssociation<Occupation, Occupation> (this, SINGLEREFERENCE_ParentOccupation, Occupation.MULTIPLEREFERENCE_ChildOccupations, Occupation.REFERENCE_Occupation, "tl_occupation");
_ChildOccupations = new MultipleAssociation<Occupation, Occupation> (this, MULTIPLEREFERENCE_ChildOccupations, Occupation.SINGLEREFERENCE_ParentOccupation, Occupation.REFERENCE_Occupation); _ChildOccupations = new MultipleAssociation<Occupation, Occupation> (this, MULTIPLEREFERENCE_ChildOccupations, Occupation.SINGLEREFERENCE_ParentOccupation, Occupation.REFERENCE_Occupation);
...@@ -296,6 +339,7 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -296,6 +339,7 @@ public abstract class BaseOccupation extends BaseBusinessClass
super.initialiseReference (); super.initialiseReference ();
_AssessmentLevel = new SingleAssociation<Occupation, Level> (this, SINGLEREFERENCE_AssessmentLevel, null, Level.REFERENCE_Level, "tl_occupation"); _AssessmentLevel = new SingleAssociation<Occupation, Level> (this, SINGLEREFERENCE_AssessmentLevel, null, Level.REFERENCE_Level, "tl_occupation");
_ExpressAssessmentLevel = new SingleAssociation<Occupation, Level> (this, SINGLEREFERENCE_ExpressAssessmentLevel, null, Level.REFERENCE_Level, "tl_occupation");
_ParentOccupation = new SingleAssociation<Occupation, Occupation> (this, SINGLEREFERENCE_ParentOccupation, Occupation.MULTIPLEREFERENCE_ChildOccupations, Occupation.REFERENCE_Occupation, "tl_occupation"); _ParentOccupation = new SingleAssociation<Occupation, Occupation> (this, SINGLEREFERENCE_ParentOccupation, Occupation.MULTIPLEREFERENCE_ChildOccupations, Occupation.REFERENCE_Occupation, "tl_occupation");
_ChildOccupations = new MultipleAssociation<Occupation, Occupation> (this, MULTIPLEREFERENCE_ChildOccupations, Occupation.SINGLEREFERENCE_ParentOccupation, Occupation.REFERENCE_Occupation); _ChildOccupations = new MultipleAssociation<Occupation, Occupation> (this, MULTIPLEREFERENCE_ChildOccupations, Occupation.SINGLEREFERENCE_ParentOccupation, Occupation.REFERENCE_Occupation);
...@@ -700,6 +744,104 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -700,6 +744,104 @@ public abstract class BaseOccupation extends BaseBusinessClass
} }
} }
/**
* Get the attribute PartTimeAssessmentType
*/
public AssessmentType getPartTimeAssessmentType ()
{
assertValid();
AssessmentType valToReturn = _PartTimeAssessmentType;
for (OccupationBehaviourDecorator bhd : Occupation_BehaviourDecorators)
{
valToReturn = bhd.getPartTimeAssessmentType ((Occupation)this, valToReturn);
}
return valToReturn;
}
/**
* Called prior to the attribute changing. Subclasses need not call super. If a field exception
* is thrown, the attribute change will fail. The new value is different to the old value.
*/
protected void prePartTimeAssessmentTypeChange (AssessmentType newPartTimeAssessmentType) throws FieldException
{
}
/**
* Called after the attribute changes.
* If a field exception is thrown, the value is still changed, however it
* may lead to the TX being rolled back
*/
protected void postPartTimeAssessmentTypeChange () throws FieldException
{
}
public FieldWriteability getWriteability_PartTimeAssessmentType ()
{
return getFieldWritabilityUtil (FieldWriteability.TRUE);
}
/**
* Set the attribute PartTimeAssessmentType. Checks to ensure a new value
* has been supplied. If so, marks the field as altered and sets the attribute.
*/
public void setPartTimeAssessmentType (AssessmentType newPartTimeAssessmentType) throws FieldException
{
boolean oldAndNewIdentical = HELPER_PartTimeAssessmentType.compare (_PartTimeAssessmentType, newPartTimeAssessmentType);
try
{
for (OccupationBehaviourDecorator bhd : Occupation_BehaviourDecorators)
{
newPartTimeAssessmentType = bhd.setPartTimeAssessmentType ((Occupation)this, newPartTimeAssessmentType);
oldAndNewIdentical = HELPER_PartTimeAssessmentType.compare (_PartTimeAssessmentType, newPartTimeAssessmentType);
}
if (FIELD_PartTimeAssessmentType_Validators.length > 0)
{
Object newPartTimeAssessmentTypeObj = HELPER_PartTimeAssessmentType.toObject (newPartTimeAssessmentType);
if (newPartTimeAssessmentTypeObj != null)
{
int loopMax = FIELD_PartTimeAssessmentType_Validators.length;
Map metadata = (Map)ATTRIBUTES_METADATA_Occupation.get (FIELD_PartTimeAssessmentType);
for (int v = 0 ; v < loopMax ; ++v)
{
FIELD_PartTimeAssessmentType_Validators[v].checkAttribute (this, FIELD_PartTimeAssessmentType, metadata, newPartTimeAssessmentTypeObj);
}
}
}
}
catch (FieldException e)
{
if (!oldAndNewIdentical)
{
e.setWouldModify ();
}
throw e;
}
if (!oldAndNewIdentical)
{
assertValid();
Debug.assertion (getWriteability_PartTimeAssessmentType () != FieldWriteability.FALSE, "Field PartTimeAssessmentType is not writeable");
prePartTimeAssessmentTypeChange (newPartTimeAssessmentType);
markFieldChange (FIELD_PartTimeAssessmentType);
_PartTimeAssessmentType = newPartTimeAssessmentType;
postFieldChange (FIELD_PartTimeAssessmentType);
postPartTimeAssessmentTypeChange ();
}
}
/** /**
...@@ -712,6 +854,8 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -712,6 +854,8 @@ public abstract class BaseOccupation extends BaseBusinessClass
result.add("AssessmentLevel"); result.add("AssessmentLevel");
result.add("ExpressAssessmentLevel");
result.add("ParentOccupation"); result.add("ParentOccupation");
...@@ -728,6 +872,9 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -728,6 +872,9 @@ public abstract class BaseOccupation extends BaseBusinessClass
else if (assocName.equals (SINGLEREFERENCE_AssessmentLevel)) else if (assocName.equals (SINGLEREFERENCE_AssessmentLevel))
{ {
return _AssessmentLevel.getReferencedType (); return _AssessmentLevel.getReferencedType ();
}else if (assocName.equals (SINGLEREFERENCE_ExpressAssessmentLevel))
{
return _ExpressAssessmentLevel.getReferencedType ();
}else if (assocName.equals (SINGLEREFERENCE_ParentOccupation)) }else if (assocName.equals (SINGLEREFERENCE_ParentOccupation))
{ {
return _ParentOccupation.getReferencedType (); return _ParentOccupation.getReferencedType ();
...@@ -748,6 +895,9 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -748,6 +895,9 @@ public abstract class BaseOccupation extends BaseBusinessClass
else if (assocName.equals (SINGLEREFERENCE_AssessmentLevel)) else if (assocName.equals (SINGLEREFERENCE_AssessmentLevel))
{ {
return null ; return null ;
}else if (assocName.equals (SINGLEREFERENCE_ExpressAssessmentLevel))
{
return null ;
}else if (assocName.equals (SINGLEREFERENCE_ParentOccupation)) }else if (assocName.equals (SINGLEREFERENCE_ParentOccupation))
{ {
return Occupation.MULTIPLEREFERENCE_ChildOccupations ; return Occupation.MULTIPLEREFERENCE_ChildOccupations ;
...@@ -768,6 +918,9 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -768,6 +918,9 @@ public abstract class BaseOccupation extends BaseBusinessClass
else if (assocName.equals (SINGLEREFERENCE_AssessmentLevel)) else if (assocName.equals (SINGLEREFERENCE_AssessmentLevel))
{ {
return getAssessmentLevel (); return getAssessmentLevel ();
}else if (assocName.equals (SINGLEREFERENCE_ExpressAssessmentLevel))
{
return getExpressAssessmentLevel ();
}else if (assocName.equals (SINGLEREFERENCE_ParentOccupation)) }else if (assocName.equals (SINGLEREFERENCE_ParentOccupation))
{ {
return getParentOccupation (); return getParentOccupation ();
...@@ -788,6 +941,9 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -788,6 +941,9 @@ public abstract class BaseOccupation extends BaseBusinessClass
else if (assocName.equals (SINGLEREFERENCE_AssessmentLevel)) else if (assocName.equals (SINGLEREFERENCE_AssessmentLevel))
{ {
return getAssessmentLevel (getType); return getAssessmentLevel (getType);
}else if (assocName.equals (SINGLEREFERENCE_ExpressAssessmentLevel))
{
return getExpressAssessmentLevel (getType);
}else if (assocName.equals (SINGLEREFERENCE_ParentOccupation)) }else if (assocName.equals (SINGLEREFERENCE_ParentOccupation))
{ {
return getParentOccupation (getType); return getParentOccupation (getType);
...@@ -808,6 +964,9 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -808,6 +964,9 @@ public abstract class BaseOccupation extends BaseBusinessClass
else if (assocName.equals (SINGLEREFERENCE_AssessmentLevel)) else if (assocName.equals (SINGLEREFERENCE_AssessmentLevel))
{ {
return getAssessmentLevelID (); return getAssessmentLevelID ();
}else if (assocName.equals (SINGLEREFERENCE_ExpressAssessmentLevel))
{
return getExpressAssessmentLevelID ();
}else if (assocName.equals (SINGLEREFERENCE_ParentOccupation)) }else if (assocName.equals (SINGLEREFERENCE_ParentOccupation))
{ {
return getParentOccupationID (); return getParentOccupationID ();
...@@ -828,6 +987,9 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -828,6 +987,9 @@ public abstract class BaseOccupation extends BaseBusinessClass
else if (assocName.equals (SINGLEREFERENCE_AssessmentLevel)) else if (assocName.equals (SINGLEREFERENCE_AssessmentLevel))
{ {
setAssessmentLevel ((Level)(newValue)); setAssessmentLevel ((Level)(newValue));
}else if (assocName.equals (SINGLEREFERENCE_ExpressAssessmentLevel))
{
setExpressAssessmentLevel ((Level)(newValue));
}else if (assocName.equals (SINGLEREFERENCE_ParentOccupation)) }else if (assocName.equals (SINGLEREFERENCE_ParentOccupation))
{ {
setParentOccupation ((Occupation)(newValue)); setParentOccupation ((Occupation)(newValue));
...@@ -935,6 +1097,100 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -935,6 +1097,100 @@ public abstract class BaseOccupation extends BaseBusinessClass
} }
/** /**
* Get the reference ExpressAssessmentLevel
*/
public Level getExpressAssessmentLevel () throws StorageException
{
assertValid();
try
{
return (Level)(_ExpressAssessmentLevel.get ());
}
catch (ClassCastException e)
{
LogMgr.log (BUSINESS_OBJECTS, LogLevel.SYSTEMERROR2, "Cache collision in Occupation:", this.getObjectID (), ", was trying to get Level:", getExpressAssessmentLevelID ());
LogMgr.log (BUSINESS_OBJECTS, LogLevel.SYSTEMERROR2, "Instead I got:", _ExpressAssessmentLevel.get ().getClass ());
throw e;
}
}
/**
* Get the object id for the referenced object. Does not force a DB access.
*/
public Level getExpressAssessmentLevel (Get getType) throws StorageException
{
assertValid();
return _ExpressAssessmentLevel.get(getType);
}
/**
* Get the object id for the referenced object. Does not force a DB access.
*/
public Long getExpressAssessmentLevelID ()
{
assertValid();
if (_ExpressAssessmentLevel == null)
{
return null;
}
else
{
return _ExpressAssessmentLevel.getID ();
}
}
/**
* Called prior to the assoc changing. Subclasses need not call super. If a field exception
* is thrown, the attribute change will fail. The new value is different to the old value.
*/
protected void preExpressAssessmentLevelChange (Level newExpressAssessmentLevel) throws FieldException
{
}
/**
* Called after the assoc changes.
* If a field exception is thrown, the value is still changed, however it
* may lead to the TX being rolled back
*/
protected void postExpressAssessmentLevelChange () throws FieldException
{
}
public FieldWriteability getWriteability_ExpressAssessmentLevel ()
{
return getFieldWritabilityUtil (FieldWriteability.TRUE);
}
/**
* Set the reference ExpressAssessmentLevel. Checks to ensure a new value
* has been supplied. If so, marks the reference as altered and sets it.
*/
public void setExpressAssessmentLevel (Level newExpressAssessmentLevel) throws StorageException, FieldException
{
if (_ExpressAssessmentLevel.wouldReferencedChange (newExpressAssessmentLevel))
{
assertValid();
Debug.assertion (getWriteability_ExpressAssessmentLevel () != FieldWriteability.FALSE, "Assoc ExpressAssessmentLevel is not writeable");
preExpressAssessmentLevelChange (newExpressAssessmentLevel);
_ExpressAssessmentLevel.set (newExpressAssessmentLevel);
postExpressAssessmentLevelChange ();
}
}
/**
* Get the reference ParentOccupation * Get the reference ParentOccupation
*/ */
public Occupation getParentOccupation () throws StorageException public Occupation getParentOccupation () throws StorageException
...@@ -1339,7 +1595,9 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1339,7 +1595,9 @@ public abstract class BaseOccupation extends BaseBusinessClass
tl_occupationPSet.setAttrib (FIELD_Name, HELPER_Name.toObject (_Name)); // tl_occupationPSet.setAttrib (FIELD_Name, HELPER_Name.toObject (_Name)); //
tl_occupationPSet.setAttrib (FIELD_Level, HELPER_Level.toObject (_Level)); // tl_occupationPSet.setAttrib (FIELD_Level, HELPER_Level.toObject (_Level)); //
tl_occupationPSet.setAttrib (FIELD_AssessmentType, HELPER_AssessmentType.toObject (_AssessmentType)); // tl_occupationPSet.setAttrib (FIELD_AssessmentType, HELPER_AssessmentType.toObject (_AssessmentType)); //
tl_occupationPSet.setAttrib (FIELD_PartTimeAssessmentType, HELPER_PartTimeAssessmentType.toObject (_PartTimeAssessmentType)); //
_AssessmentLevel.getPersistentSets (allSets); _AssessmentLevel.getPersistentSets (allSets);
_ExpressAssessmentLevel.getPersistentSets (allSets);
_ParentOccupation.getPersistentSets (allSets); _ParentOccupation.getPersistentSets (allSets);
} }
...@@ -1359,7 +1617,9 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1359,7 +1617,9 @@ public abstract class BaseOccupation extends BaseBusinessClass
_Name = (String)(HELPER_Name.fromObject (_Name, tl_occupationPSet.getAttrib (FIELD_Name))); // _Name = (String)(HELPER_Name.fromObject (_Name, tl_occupationPSet.getAttrib (FIELD_Name))); //
_Level = (OccupationLevel)(HELPER_Level.fromObject (_Level, tl_occupationPSet.getAttrib (FIELD_Level))); // _Level = (OccupationLevel)(HELPER_Level.fromObject (_Level, tl_occupationPSet.getAttrib (FIELD_Level))); //
_AssessmentType = (AssessmentType)(HELPER_AssessmentType.fromObject (_AssessmentType, tl_occupationPSet.getAttrib (FIELD_AssessmentType))); // _AssessmentType = (AssessmentType)(HELPER_AssessmentType.fromObject (_AssessmentType, tl_occupationPSet.getAttrib (FIELD_AssessmentType))); //
_PartTimeAssessmentType = (AssessmentType)(HELPER_PartTimeAssessmentType.fromObject (_PartTimeAssessmentType, tl_occupationPSet.getAttrib (FIELD_PartTimeAssessmentType))); //
_AssessmentLevel.setFromPersistentSets (objectID, allSets); _AssessmentLevel.setFromPersistentSets (objectID, allSets);
_ExpressAssessmentLevel.setFromPersistentSets (objectID, allSets);
_ParentOccupation.setFromPersistentSets (objectID, allSets); _ParentOccupation.setFromPersistentSets (objectID, allSets);
} }
...@@ -1412,6 +1672,15 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1412,6 +1672,15 @@ public abstract class BaseOccupation extends BaseBusinessClass
e.addException (ex); e.addException (ex);
} }
try
{
setPartTimeAssessmentType (otherOccupation.getPartTimeAssessmentType ());
}
catch (FieldException ex)
{
e.addException (ex);
}
} }
} }
...@@ -1431,6 +1700,7 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1431,6 +1700,7 @@ public abstract class BaseOccupation extends BaseBusinessClass
_Name = sourceOccupation._Name; _Name = sourceOccupation._Name;
_Level = sourceOccupation._Level; _Level = sourceOccupation._Level;
_AssessmentType = sourceOccupation._AssessmentType; _AssessmentType = sourceOccupation._AssessmentType;
_PartTimeAssessmentType = sourceOccupation._PartTimeAssessmentType;
} }
} }
...@@ -1448,6 +1718,7 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1448,6 +1718,7 @@ public abstract class BaseOccupation extends BaseBusinessClass
BaseOccupation sourceOccupation = (BaseOccupation)(source); BaseOccupation sourceOccupation = (BaseOccupation)(source);
_AssessmentLevel.copyFrom (sourceOccupation._AssessmentLevel, linkToGhosts); _AssessmentLevel.copyFrom (sourceOccupation._AssessmentLevel, linkToGhosts);
_ExpressAssessmentLevel.copyFrom (sourceOccupation._ExpressAssessmentLevel, linkToGhosts);
_ParentOccupation.copyFrom (sourceOccupation._ParentOccupation, linkToGhosts); _ParentOccupation.copyFrom (sourceOccupation._ParentOccupation, linkToGhosts);
} }
...@@ -1490,7 +1761,9 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1490,7 +1761,9 @@ public abstract class BaseOccupation extends BaseBusinessClass
_Name = (String)(HELPER_Name.readExternal (_Name, vals.get(FIELD_Name))); // _Name = (String)(HELPER_Name.readExternal (_Name, vals.get(FIELD_Name))); //
_Level = (OccupationLevel)(HELPER_Level.readExternal (_Level, vals.get(FIELD_Level))); // _Level = (OccupationLevel)(HELPER_Level.readExternal (_Level, vals.get(FIELD_Level))); //
_AssessmentType = (AssessmentType)(HELPER_AssessmentType.readExternal (_AssessmentType, vals.get(FIELD_AssessmentType))); // _AssessmentType = (AssessmentType)(HELPER_AssessmentType.readExternal (_AssessmentType, vals.get(FIELD_AssessmentType))); //
_PartTimeAssessmentType = (AssessmentType)(HELPER_PartTimeAssessmentType.readExternal (_PartTimeAssessmentType, vals.get(FIELD_PartTimeAssessmentType))); //
_AssessmentLevel.readExternalData(vals.get(SINGLEREFERENCE_AssessmentLevel)); _AssessmentLevel.readExternalData(vals.get(SINGLEREFERENCE_AssessmentLevel));
_ExpressAssessmentLevel.readExternalData(vals.get(SINGLEREFERENCE_ExpressAssessmentLevel));
_ParentOccupation.readExternalData(vals.get(SINGLEREFERENCE_ParentOccupation)); _ParentOccupation.readExternalData(vals.get(SINGLEREFERENCE_ParentOccupation));
_ChildOccupations.readExternalData(vals.get(MULTIPLEREFERENCE_ChildOccupations)); _ChildOccupations.readExternalData(vals.get(MULTIPLEREFERENCE_ChildOccupations));
...@@ -1508,7 +1781,9 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1508,7 +1781,9 @@ public abstract class BaseOccupation extends BaseBusinessClass
vals.put (FIELD_Name, HELPER_Name.writeExternal (_Name)); vals.put (FIELD_Name, HELPER_Name.writeExternal (_Name));
vals.put (FIELD_Level, HELPER_Level.writeExternal (_Level)); vals.put (FIELD_Level, HELPER_Level.writeExternal (_Level));
vals.put (FIELD_AssessmentType, HELPER_AssessmentType.writeExternal (_AssessmentType)); vals.put (FIELD_AssessmentType, HELPER_AssessmentType.writeExternal (_AssessmentType));
vals.put (FIELD_PartTimeAssessmentType, HELPER_PartTimeAssessmentType.writeExternal (_PartTimeAssessmentType));
vals.put (SINGLEREFERENCE_AssessmentLevel, _AssessmentLevel.writeExternalData()); vals.put (SINGLEREFERENCE_AssessmentLevel, _AssessmentLevel.writeExternalData());
vals.put (SINGLEREFERENCE_ExpressAssessmentLevel, _ExpressAssessmentLevel.writeExternalData());
vals.put (SINGLEREFERENCE_ParentOccupation, _ParentOccupation.writeExternalData()); vals.put (SINGLEREFERENCE_ParentOccupation, _ParentOccupation.writeExternalData());
vals.put (MULTIPLEREFERENCE_ChildOccupations, _ChildOccupations.writeExternalData()); vals.put (MULTIPLEREFERENCE_ChildOccupations, _ChildOccupations.writeExternalData());
...@@ -1540,9 +1815,14 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1540,9 +1815,14 @@ public abstract class BaseOccupation extends BaseBusinessClass
{ {
listener.notifyFieldChange(this, other, FIELD_AssessmentType, HELPER_AssessmentType.toObject(this._AssessmentType), HELPER_AssessmentType.toObject(otherOccupation._AssessmentType)); listener.notifyFieldChange(this, other, FIELD_AssessmentType, HELPER_AssessmentType.toObject(this._AssessmentType), HELPER_AssessmentType.toObject(otherOccupation._AssessmentType));
} }
if (!HELPER_PartTimeAssessmentType.compare(this._PartTimeAssessmentType, otherOccupation._PartTimeAssessmentType))
{
listener.notifyFieldChange(this, other, FIELD_PartTimeAssessmentType, HELPER_PartTimeAssessmentType.toObject(this._PartTimeAssessmentType), HELPER_PartTimeAssessmentType.toObject(otherOccupation._PartTimeAssessmentType));
}
// Compare single assocs // Compare single assocs
_AssessmentLevel.compare (otherOccupation._AssessmentLevel, listener); _AssessmentLevel.compare (otherOccupation._AssessmentLevel, listener);
_ExpressAssessmentLevel.compare (otherOccupation._ExpressAssessmentLevel, listener);
_ParentOccupation.compare (otherOccupation._ParentOccupation, listener); _ParentOccupation.compare (otherOccupation._ParentOccupation, listener);
...@@ -1569,7 +1849,9 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1569,7 +1849,9 @@ public abstract class BaseOccupation extends BaseBusinessClass
visitor.visitField(this, FIELD_Name, HELPER_Name.toObject(getName())); visitor.visitField(this, FIELD_Name, HELPER_Name.toObject(getName()));
visitor.visitField(this, FIELD_Level, HELPER_Level.toObject(getLevel())); visitor.visitField(this, FIELD_Level, HELPER_Level.toObject(getLevel()));
visitor.visitField(this, FIELD_AssessmentType, HELPER_AssessmentType.toObject(getAssessmentType())); visitor.visitField(this, FIELD_AssessmentType, HELPER_AssessmentType.toObject(getAssessmentType()));
visitor.visitField(this, FIELD_PartTimeAssessmentType, HELPER_PartTimeAssessmentType.toObject(getPartTimeAssessmentType()));
visitor.visitAssociation (_AssessmentLevel); visitor.visitAssociation (_AssessmentLevel);
visitor.visitAssociation (_ExpressAssessmentLevel);
visitor.visitAssociation (_ParentOccupation); visitor.visitAssociation (_ParentOccupation);
visitor.visitAssociation (_ChildOccupations); visitor.visitAssociation (_ChildOccupations);
...@@ -1584,6 +1866,10 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1584,6 +1866,10 @@ public abstract class BaseOccupation extends BaseBusinessClass
{ {
visitor.visit (_AssessmentLevel); visitor.visit (_AssessmentLevel);
} }
if (scope.includes (_ExpressAssessmentLevel))
{
visitor.visit (_ExpressAssessmentLevel);
}
if (scope.includes (_ParentOccupation)) if (scope.includes (_ParentOccupation))
{ {
visitor.visit (_ParentOccupation); visitor.visit (_ParentOccupation);
...@@ -1633,10 +1919,18 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1633,10 +1919,18 @@ public abstract class BaseOccupation extends BaseBusinessClass
{ {
return filter.matches (getAssessmentType ()); return filter.matches (getAssessmentType ());
} }
else if (attribName.equals (FIELD_PartTimeAssessmentType))
{
return filter.matches (getPartTimeAssessmentType ());
}
else if (attribName.equals (SINGLEREFERENCE_AssessmentLevel)) else if (attribName.equals (SINGLEREFERENCE_AssessmentLevel))
{ {
return filter.matches (getAssessmentLevel ()); return filter.matches (getAssessmentLevel ());
} }
else if (attribName.equals (SINGLEREFERENCE_ExpressAssessmentLevel))
{
return filter.matches (getExpressAssessmentLevel ());
}
else if (attribName.equals (SINGLEREFERENCE_ParentOccupation)) else if (attribName.equals (SINGLEREFERENCE_ParentOccupation))
{ {
return filter.matches (getParentOccupation ()); return filter.matches (getParentOccupation ());
...@@ -1696,12 +1990,24 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1696,12 +1990,24 @@ public abstract class BaseOccupation extends BaseBusinessClass
return this; return this;
} }
public SearchAll andPartTimeAssessmentType (QueryFilter<AssessmentType> filter)
{
filter.addFilter (context, "tl_occupation.parttime_assessment_type", "PartTimeAssessmentType");
return this;
}
public SearchAll andAssessmentLevel (QueryFilter<Level> filter) public SearchAll andAssessmentLevel (QueryFilter<Level> filter)
{ {
filter.addFilter (context, "tl_occupation.assessment_level_id", "AssessmentLevel"); filter.addFilter (context, "tl_occupation.assessment_level_id", "AssessmentLevel");
return this; return this;
} }
public SearchAll andExpressAssessmentLevel (QueryFilter<Level> filter)
{
filter.addFilter (context, "tl_occupation.express_assessment_level_id", "ExpressAssessmentLevel");
return this;
}
public SearchAll andParentOccupation (QueryFilter<Occupation> filter) public SearchAll andParentOccupation (QueryFilter<Occupation> filter)
{ {
filter.addFilter (context, "tl_occupation.parent_occupation_id", "ParentOccupation"); filter.addFilter (context, "tl_occupation.parent_occupation_id", "ParentOccupation");
...@@ -1759,6 +2065,10 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1759,6 +2065,10 @@ public abstract class BaseOccupation extends BaseBusinessClass
{ {
return HELPER_AssessmentType.toObject (getAssessmentType ()); return HELPER_AssessmentType.toObject (getAssessmentType ());
} }
else if (attribName.equals (FIELD_PartTimeAssessmentType))
{
return HELPER_PartTimeAssessmentType.toObject (getPartTimeAssessmentType ());
}
else else
{ {
return super.getAttribute (attribName); return super.getAttribute (attribName);
...@@ -1788,6 +2098,10 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1788,6 +2098,10 @@ public abstract class BaseOccupation extends BaseBusinessClass
{ {
return HELPER_AssessmentType; return HELPER_AssessmentType;
} }
else if (attribName.equals (FIELD_PartTimeAssessmentType))
{
return HELPER_PartTimeAssessmentType;
}
else else
{ {
return super.getAttributeHelper (attribName); return super.getAttributeHelper (attribName);
...@@ -1817,6 +2131,10 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1817,6 +2131,10 @@ public abstract class BaseOccupation extends BaseBusinessClass
{ {
setAssessmentType ((AssessmentType)(HELPER_AssessmentType.fromObject (_AssessmentType, attribValue))); setAssessmentType ((AssessmentType)(HELPER_AssessmentType.fromObject (_AssessmentType, attribValue)));
} }
else if (attribName.equals (FIELD_PartTimeAssessmentType))
{
setPartTimeAssessmentType ((AssessmentType)(HELPER_PartTimeAssessmentType.fromObject (_PartTimeAssessmentType, attribValue)));
}
else else
{ {
super.setAttribute (attribName, attribValue); super.setAttribute (attribName, attribValue);
...@@ -1853,6 +2171,10 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1853,6 +2171,10 @@ public abstract class BaseOccupation extends BaseBusinessClass
{ {
return getWriteability_AssessmentType (); return getWriteability_AssessmentType ();
} }
else if (fieldName.equals (FIELD_PartTimeAssessmentType))
{
return getWriteability_PartTimeAssessmentType ();
}
else if (fieldName.equals (MULTIPLEREFERENCE_ChildOccupations)) else if (fieldName.equals (MULTIPLEREFERENCE_ChildOccupations))
{ {
return getWriteability_ChildOccupations (); return getWriteability_ChildOccupations ();
...@@ -1861,6 +2183,10 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1861,6 +2183,10 @@ public abstract class BaseOccupation extends BaseBusinessClass
{ {
return getWriteability_AssessmentLevel (); return getWriteability_AssessmentLevel ();
} }
else if (fieldName.equals (SINGLEREFERENCE_ExpressAssessmentLevel))
{
return getWriteability_ExpressAssessmentLevel ();
}
else if (fieldName.equals (SINGLEREFERENCE_ParentOccupation)) else if (fieldName.equals (SINGLEREFERENCE_ParentOccupation))
{ {
return getWriteability_ParentOccupation (); return getWriteability_ParentOccupation ();
...@@ -1895,6 +2221,11 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1895,6 +2221,11 @@ public abstract class BaseOccupation extends BaseBusinessClass
fields.add (FIELD_AssessmentType); fields.add (FIELD_AssessmentType);
} }
if (getWriteability_PartTimeAssessmentType () != FieldWriteability.TRUE)
{
fields.add (FIELD_PartTimeAssessmentType);
}
super.putUnwriteable (fields); super.putUnwriteable (fields);
} }
...@@ -1908,6 +2239,7 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -1908,6 +2239,7 @@ public abstract class BaseOccupation extends BaseBusinessClass
result.add(HELPER_Name.getAttribObject (getClass (), _Name, true, FIELD_Name)); result.add(HELPER_Name.getAttribObject (getClass (), _Name, true, FIELD_Name));
result.add(HELPER_Level.getAttribObject (getClass (), _Level, true, FIELD_Level)); result.add(HELPER_Level.getAttribObject (getClass (), _Level, true, FIELD_Level));
result.add(HELPER_AssessmentType.getAttribObject (getClass (), _AssessmentType, false, FIELD_AssessmentType)); result.add(HELPER_AssessmentType.getAttribObject (getClass (), _AssessmentType, false, FIELD_AssessmentType));
result.add(HELPER_PartTimeAssessmentType.getAttribObject (getClass (), _PartTimeAssessmentType, false, FIELD_PartTimeAssessmentType));
return result; return result;
} }
...@@ -2030,6 +2362,24 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -2030,6 +2362,24 @@ public abstract class BaseOccupation extends BaseBusinessClass
return newAssessmentType; return newAssessmentType;
} }
/**
* Get the attribute PartTimeAssessmentType
*/
public AssessmentType getPartTimeAssessmentType (Occupation obj, AssessmentType original)
{
return original;
}
/**
* Change the value set for attribute PartTimeAssessmentType.
* May modify the field beforehand
* Occurs before validation.
*/
public AssessmentType setPartTimeAssessmentType (Occupation obj, AssessmentType newPartTimeAssessmentType) throws FieldException
{
return newPartTimeAssessmentType;
}
} }
...@@ -2102,10 +2452,18 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -2102,10 +2452,18 @@ public abstract class BaseOccupation extends BaseBusinessClass
{ {
return toAssessmentType (); return toAssessmentType ();
} }
if (name.equals ("PartTimeAssessmentType"))
{
return toPartTimeAssessmentType ();
}
if (name.equals ("AssessmentLevel")) if (name.equals ("AssessmentLevel"))
{ {
return toAssessmentLevel (); return toAssessmentLevel ();
} }
if (name.equals ("ExpressAssessmentLevel"))
{
return toExpressAssessmentLevel ();
}
if (name.equals ("ParentOccupation")) if (name.equals ("ParentOccupation"))
{ {
return toParentOccupation (); return toParentOccupation ();
...@@ -2123,12 +2481,20 @@ public abstract class BaseOccupation extends BaseBusinessClass ...@@ -2123,12 +2481,20 @@ public abstract class BaseOccupation extends BaseBusinessClass
public PipeLine<From, OccupationLevel> toLevel () { return pipe(new ORMAttributePipe<Me, OccupationLevel>(FIELD_Level)); } public PipeLine<From, OccupationLevel> toLevel () { return pipe(new ORMAttributePipe<Me, OccupationLevel>(FIELD_Level)); }
public PipeLine<From, AssessmentType> toAssessmentType () { return pipe(new ORMAttributePipe<Me, AssessmentType>(FIELD_AssessmentType)); } public PipeLine<From, AssessmentType> toAssessmentType () { return pipe(new ORMAttributePipe<Me, AssessmentType>(FIELD_AssessmentType)); }
public PipeLine<From, AssessmentType> toPartTimeAssessmentType () { return pipe(new ORMAttributePipe<Me, AssessmentType>(FIELD_PartTimeAssessmentType)); }
public Level.LevelPipeLineFactory<From, Level> toAssessmentLevel () { return toAssessmentLevel (Filter.ALL); } public Level.LevelPipeLineFactory<From, Level> toAssessmentLevel () { return toAssessmentLevel (Filter.ALL); }
public Level.LevelPipeLineFactory<From, Level> toAssessmentLevel (Filter<Level> filter) public Level.LevelPipeLineFactory<From, Level> toAssessmentLevel (Filter<Level> filter)
{ {
return Level.REFERENCE_Level.new LevelPipeLineFactory<From, Level> (this, new ORMSingleAssocPipe<Me, Level>(SINGLEREFERENCE_AssessmentLevel, filter)); return Level.REFERENCE_Level.new LevelPipeLineFactory<From, Level> (this, new ORMSingleAssocPipe<Me, Level>(SINGLEREFERENCE_AssessmentLevel, filter));
} }
public Level.LevelPipeLineFactory<From, Level> toExpressAssessmentLevel () { return toExpressAssessmentLevel (Filter.ALL); }
public Level.LevelPipeLineFactory<From, Level> toExpressAssessmentLevel (Filter<Level> filter)
{
return Level.REFERENCE_Level.new LevelPipeLineFactory<From, Level> (this, new ORMSingleAssocPipe<Me, Level>(SINGLEREFERENCE_ExpressAssessmentLevel, filter));
}
public Occupation.OccupationPipeLineFactory<From, Occupation> toParentOccupation () { return toParentOccupation (Filter.ALL); } public Occupation.OccupationPipeLineFactory<From, Occupation> toParentOccupation () { return toParentOccupation (Filter.ALL); }
public Occupation.OccupationPipeLineFactory<From, Occupation> toParentOccupation (Filter<Occupation> filter) public Occupation.OccupationPipeLineFactory<From, Occupation> toParentOccupation (Filter<Occupation> filter)
...@@ -2186,6 +2552,20 @@ class DummyOccupation extends Occupation ...@@ -2186,6 +2552,20 @@ class DummyOccupation extends Occupation
return Level.DUMMY_Level.getObjectID(); return Level.DUMMY_Level.getObjectID();
} }
public Level getExpressAssessmentLevel () throws StorageException
{
return (Level)(Level.DUMMY_Level);
}
/**
* Get the object id for the referenced object. Does not force a DB access.
*/
public Long getExpressAssessmentLevelID ()
{
return Level.DUMMY_Level.getObjectID();
}
public Occupation getParentOccupation () throws StorageException public Occupation getParentOccupation () throws StorageException
{ {
return (Occupation)(Occupation.DUMMY_Occupation); return (Occupation)(Occupation.DUMMY_Occupation);
......
...@@ -114,7 +114,7 @@ public class Candidate extends BaseCandidate ...@@ -114,7 +114,7 @@ public class Candidate extends BaseCandidate
{ {
int allAnswersCount = getCultureCriteriaAnswersCount(); int allAnswersCount = getCultureCriteriaAnswersCount();
if(allAnswersCount == job.getCultureCriteriasCount()) if(job.showCultureCriteriaSection() && allAnswersCount == job.getCultureCriteriasCount())
{ {
Filter filter = CultureCriteriaAnswer.SearchByAll().andSelectedQuestion(new IsNotNullFilter<>()); Filter filter = CultureCriteriaAnswer.SearchByAll().andSelectedQuestion(new IsNotNullFilter<>());
Collection selectedAnswers = pipelineCandidate().toCultureCriteriaAnswers(filter).vals(); Collection selectedAnswers = pipelineCandidate().toCultureCriteriaAnswers(filter).vals();
...@@ -127,7 +127,7 @@ public class Candidate extends BaseCandidate ...@@ -127,7 +127,7 @@ public class Candidate extends BaseCandidate
public double cultureCompletedPercentage(Job job) public double cultureCompletedPercentage(Job job)
{ {
return (getCultureCriteriaAnswersCount() * 100) / job.getCultureCriteriasCount() ; return job.showCultureCriteriaSection() ? (getCultureCriteriaAnswersCount() * 100) / job.getCultureCriteriasCount() : 0d;
} }
public double roleFitCompletedPercentage(Job job) public double roleFitCompletedPercentage(Job job)
......
package performa.orm; package performa.orm;
import oneit.utils.math.NullArith;
public class CandidateClassScore extends BaseCandidateClassScore public class CandidateClassScore extends BaseCandidateClassScore
{ {
...@@ -10,4 +12,9 @@ public class CandidateClassScore extends BaseCandidateClassScore ...@@ -10,4 +12,9 @@ public class CandidateClassScore extends BaseCandidateClassScore
{ {
// Do not add any code to this, always put it in initialiseNewObject // Do not add any code to this, always put it in initialiseNewObject
} }
public double getWeightedPercentage()
{
return NullArith.divide(getWghtdClassScore(), getMaxWghtdClassScore()) * 100;
}
} }
\ No newline at end of file
...@@ -32,4 +32,9 @@ public class Client extends BaseClient ...@@ -32,4 +32,9 @@ public class Client extends BaseClient
{ {
return StringUtils.subNulls(getClientName(), super.getToString()); return StringUtils.subNulls(getClientName(), super.getToString());
} }
public boolean showUseClientDetails()
{
return isTrue(getUseClientDetails());
}
} }
\ No newline at end of file
...@@ -15,6 +15,7 @@ ...@@ -15,6 +15,7 @@
<ATTRIB name="ClientName" type="String" dbcol="client_name" mandatory="true" length="30"/> <ATTRIB name="ClientName" type="String" dbcol="client_name" mandatory="true" length="30"/>
<ATTRIB name="ClientLogo" type="BinaryContent" dbcol="client_logo" mandatory="false" binaryHandler="loggedin" attribHelper="BLOBAttributeHelper" attribHelperInstance="BLOBAttributeHelper.INSTANCE" /> <ATTRIB name="ClientLogo" type="BinaryContent" dbcol="client_logo" mandatory="false" binaryHandler="loggedin" attribHelper="BLOBAttributeHelper" attribHelperInstance="BLOBAttributeHelper.INSTANCE" />
<ATTRIB name="UseClientDetails" type="Boolean" dbcol="use_client_details" mandatory="false" defaultValue="Boolean.TRUE" />
<ATTRIB name="Email" type="String" dbcol="email" mandatory="false" length="100" validators="Email" /> <ATTRIB name="Email" type="String" dbcol="email" mandatory="false" length="100" validators="Email" />
<ATTRIB name="ContactName" type="String" dbcol="contact_name" mandatory="false" length="100"/> <ATTRIB name="ContactName" type="String" dbcol="contact_name" mandatory="false" length="100"/>
<ATTRIB name="ContactSurname" type="String" dbcol="contact_surname" mandatory="false" length="100"/> <ATTRIB name="ContactSurname" type="String" dbcol="contact_surname" mandatory="false" length="100"/>
......
...@@ -30,6 +30,7 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr ...@@ -30,6 +30,7 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr
// Private attributes corresponding to business object data // Private attributes corresponding to business object data
private String dummyClientName; private String dummyClientName;
private BinaryContent dummyClientLogo; private BinaryContent dummyClientLogo;
private Boolean dummyUseClientDetails;
private String dummyEmail; private String dummyEmail;
private String dummyContactName; private String dummyContactName;
private String dummyContactSurname; private String dummyContactSurname;
...@@ -44,6 +45,7 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr ...@@ -44,6 +45,7 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr
// Static constants corresponding to attribute helpers // Static constants corresponding to attribute helpers
private static final DefaultAttributeHelper HELPER_ClientName = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper HELPER_ClientName = DefaultAttributeHelper.INSTANCE;
private static final BLOBAttributeHelper HELPER_ClientLogo = BLOBAttributeHelper.INSTANCE; private static final BLOBAttributeHelper HELPER_ClientLogo = BLOBAttributeHelper.INSTANCE;
private static final DefaultAttributeHelper HELPER_UseClientDetails = DefaultAttributeHelper.INSTANCE;
private static final DefaultAttributeHelper HELPER_Email = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper HELPER_Email = DefaultAttributeHelper.INSTANCE;
private static final DefaultAttributeHelper HELPER_ContactName = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper HELPER_ContactName = DefaultAttributeHelper.INSTANCE;
private static final DefaultAttributeHelper HELPER_ContactSurname = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper HELPER_ContactSurname = DefaultAttributeHelper.INSTANCE;
...@@ -61,6 +63,7 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr ...@@ -61,6 +63,7 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr
{ {
dummyClientName = (String)(HELPER_ClientName.initialise (dummyClientName)); dummyClientName = (String)(HELPER_ClientName.initialise (dummyClientName));
dummyClientLogo = (BinaryContent)(HELPER_ClientLogo.initialise (dummyClientLogo)); dummyClientLogo = (BinaryContent)(HELPER_ClientLogo.initialise (dummyClientLogo));
dummyUseClientDetails = (Boolean)(HELPER_UseClientDetails.initialise (dummyUseClientDetails));
dummyEmail = (String)(HELPER_Email.initialise (dummyEmail)); dummyEmail = (String)(HELPER_Email.initialise (dummyEmail));
dummyContactName = (String)(HELPER_ContactName.initialise (dummyContactName)); dummyContactName = (String)(HELPER_ContactName.initialise (dummyContactName));
dummyContactSurname = (String)(HELPER_ContactSurname.initialise (dummyContactSurname)); dummyContactSurname = (String)(HELPER_ContactSurname.initialise (dummyContactSurname));
...@@ -73,7 +76,7 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr ...@@ -73,7 +76,7 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr
} }
private String SELECT_COLUMNS = "{PREFIX}tl_client.object_id as id, {PREFIX}tl_client.object_LAST_UPDATED_DATE as LAST_UPDATED_DATE, {PREFIX}tl_client.object_CREATED_DATE as CREATED_DATE, {PREFIX}tl_client.client_name, {PREFIX}tl_client.client_logo, {PREFIX}tl_client.email, {PREFIX}tl_client.contact_name, {PREFIX}tl_client.contact_surname, {PREFIX}tl_client.phone, {PREFIX}tl_client.state, {PREFIX}tl_client.country, {PREFIX}tl_client.post_code, {PREFIX}tl_client.city, {PREFIX}tl_client.time_zone, {PREFIX}tl_client.hiring_team_id, {PREFIX}tl_client.company_id, 1 AS commasafe "; private String SELECT_COLUMNS = "{PREFIX}tl_client.object_id as id, {PREFIX}tl_client.object_LAST_UPDATED_DATE as LAST_UPDATED_DATE, {PREFIX}tl_client.object_CREATED_DATE as CREATED_DATE, {PREFIX}tl_client.client_name, {PREFIX}tl_client.client_logo, {PREFIX}tl_client.use_client_details, {PREFIX}tl_client.email, {PREFIX}tl_client.contact_name, {PREFIX}tl_client.contact_surname, {PREFIX}tl_client.phone, {PREFIX}tl_client.state, {PREFIX}tl_client.country, {PREFIX}tl_client.post_code, {PREFIX}tl_client.city, {PREFIX}tl_client.time_zone, {PREFIX}tl_client.hiring_team_id, {PREFIX}tl_client.company_id, 1 AS commasafe ";
private String SELECT_JOINS = ""; private String SELECT_JOINS = "";
public BaseBusinessClass fetchByID(ObjectID id, PersistentSetCollection allPSets, RDBMSPersistenceContext context, SQLManager sqlMgr) throws SQLException, StorageException public BaseBusinessClass fetchByID(ObjectID id, PersistentSetCollection allPSets, RDBMSPersistenceContext context, SQLManager sqlMgr) throws SQLException, StorageException
...@@ -126,6 +129,7 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr ...@@ -126,6 +129,7 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr
if (false || !tl_clientPSet.containsAttrib(BaseBusinessClass.FIELD_ObjectLastModified) || if (false || !tl_clientPSet.containsAttrib(BaseBusinessClass.FIELD_ObjectLastModified) ||
!tl_clientPSet.containsAttrib(Client.FIELD_ClientName)|| !tl_clientPSet.containsAttrib(Client.FIELD_ClientName)||
!tl_clientPSet.containsAttrib(Client.FIELD_ClientLogo)|| !tl_clientPSet.containsAttrib(Client.FIELD_ClientLogo)||
!tl_clientPSet.containsAttrib(Client.FIELD_UseClientDetails)||
!tl_clientPSet.containsAttrib(Client.FIELD_Email)|| !tl_clientPSet.containsAttrib(Client.FIELD_Email)||
!tl_clientPSet.containsAttrib(Client.FIELD_ContactName)|| !tl_clientPSet.containsAttrib(Client.FIELD_ContactName)||
!tl_clientPSet.containsAttrib(Client.FIELD_ContactSurname)|| !tl_clientPSet.containsAttrib(Client.FIELD_ContactSurname)||
...@@ -226,10 +230,10 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr ...@@ -226,10 +230,10 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr
{ {
int rowsUpdated = executeStatement (sqlMgr, int rowsUpdated = executeStatement (sqlMgr,
"UPDATE {PREFIX}tl_client " + "UPDATE {PREFIX}tl_client " +
"SET client_name = ?, client_logo = ?, email = ?, contact_name = ?, contact_surname = ?, phone = ?, state = ?, country = ?, post_code = ?, city = ?, time_zone = ?, hiring_team_id = ? , company_id = ? , object_LAST_UPDATED_DATE = " + sqlMgr.getPortabilityServices ().getTimestampExpression () + " " + "SET client_name = ?, client_logo = ?, use_client_details = ?, email = ?, contact_name = ?, contact_surname = ?, phone = ?, state = ?, country = ?, post_code = ?, city = ?, time_zone = ?, hiring_team_id = ? , company_id = ? , object_LAST_UPDATED_DATE = " + sqlMgr.getPortabilityServices ().getTimestampExpression () + " " +
"WHERE tl_client.object_id = ? AND " + getConcurrencyCheck (sqlMgr, "object_LAST_UPDATED_DATE", obj.getObjectLastModified ()) + " ", "WHERE tl_client.object_id = ? AND " + getConcurrencyCheck (sqlMgr, "object_LAST_UPDATED_DATE", obj.getObjectLastModified ()) + " ",
CollectionUtils.listEntry (HELPER_ClientName.getForSQL(dummyClientName, tl_clientPSet.getAttrib (Client.FIELD_ClientName))).listEntry (HELPER_ClientLogo.getForSQL(dummyClientLogo, tl_clientPSet.getAttrib (Client.FIELD_ClientLogo))).listEntry (HELPER_Email.getForSQL(dummyEmail, tl_clientPSet.getAttrib (Client.FIELD_Email))).listEntry (HELPER_ContactName.getForSQL(dummyContactName, tl_clientPSet.getAttrib (Client.FIELD_ContactName))).listEntry (HELPER_ContactSurname.getForSQL(dummyContactSurname, tl_clientPSet.getAttrib (Client.FIELD_ContactSurname))).listEntry (HELPER_Phone.getForSQL(dummyPhone, tl_clientPSet.getAttrib (Client.FIELD_Phone))).listEntry (HELPER_State.getForSQL(dummyState, tl_clientPSet.getAttrib (Client.FIELD_State))).listEntry (HELPER_Country.getForSQL(dummyCountry, tl_clientPSet.getAttrib (Client.FIELD_Country))).listEntry (HELPER_PostCode.getForSQL(dummyPostCode, tl_clientPSet.getAttrib (Client.FIELD_PostCode))).listEntry (HELPER_City.getForSQL(dummyCity, tl_clientPSet.getAttrib (Client.FIELD_City))).listEntry (HELPER_TimeZone.getForSQL(dummyTimeZone, tl_clientPSet.getAttrib (Client.FIELD_TimeZone))).listEntry (SQLManager.CheckNull((Long)(tl_clientPSet.getAttrib (Client.SINGLEREFERENCE_HiringTeam)))).listEntry (SQLManager.CheckNull((Long)(tl_clientPSet.getAttrib (Client.SINGLEREFERENCE_Company)))).listEntry (objectID.longID ()).listEntry (obj.getObjectLastModified ()).toList().toArray()); CollectionUtils.listEntry (HELPER_ClientName.getForSQL(dummyClientName, tl_clientPSet.getAttrib (Client.FIELD_ClientName))).listEntry (HELPER_ClientLogo.getForSQL(dummyClientLogo, tl_clientPSet.getAttrib (Client.FIELD_ClientLogo))).listEntry (HELPER_UseClientDetails.getForSQL(dummyUseClientDetails, tl_clientPSet.getAttrib (Client.FIELD_UseClientDetails))).listEntry (HELPER_Email.getForSQL(dummyEmail, tl_clientPSet.getAttrib (Client.FIELD_Email))).listEntry (HELPER_ContactName.getForSQL(dummyContactName, tl_clientPSet.getAttrib (Client.FIELD_ContactName))).listEntry (HELPER_ContactSurname.getForSQL(dummyContactSurname, tl_clientPSet.getAttrib (Client.FIELD_ContactSurname))).listEntry (HELPER_Phone.getForSQL(dummyPhone, tl_clientPSet.getAttrib (Client.FIELD_Phone))).listEntry (HELPER_State.getForSQL(dummyState, tl_clientPSet.getAttrib (Client.FIELD_State))).listEntry (HELPER_Country.getForSQL(dummyCountry, tl_clientPSet.getAttrib (Client.FIELD_Country))).listEntry (HELPER_PostCode.getForSQL(dummyPostCode, tl_clientPSet.getAttrib (Client.FIELD_PostCode))).listEntry (HELPER_City.getForSQL(dummyCity, tl_clientPSet.getAttrib (Client.FIELD_City))).listEntry (HELPER_TimeZone.getForSQL(dummyTimeZone, tl_clientPSet.getAttrib (Client.FIELD_TimeZone))).listEntry (SQLManager.CheckNull((Long)(tl_clientPSet.getAttrib (Client.SINGLEREFERENCE_HiringTeam)))).listEntry (SQLManager.CheckNull((Long)(tl_clientPSet.getAttrib (Client.SINGLEREFERENCE_Company)))).listEntry (objectID.longID ()).listEntry (obj.getObjectLastModified ()).toList().toArray());
if (rowsUpdated != 1) if (rowsUpdated != 1)
{ {
...@@ -487,6 +491,7 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr ...@@ -487,6 +491,7 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr
tl_clientPSet.setAttrib(Client.FIELD_ClientName, HELPER_ClientName.getFromRS(dummyClientName, r, "client_name")); tl_clientPSet.setAttrib(Client.FIELD_ClientName, HELPER_ClientName.getFromRS(dummyClientName, r, "client_name"));
tl_clientPSet.setAttrib(Client.FIELD_ClientLogo, HELPER_ClientLogo.getFromRS(dummyClientLogo, r, "client_logo")); tl_clientPSet.setAttrib(Client.FIELD_ClientLogo, HELPER_ClientLogo.getFromRS(dummyClientLogo, r, "client_logo"));
tl_clientPSet.setAttrib(Client.FIELD_UseClientDetails, HELPER_UseClientDetails.getFromRS(dummyUseClientDetails, r, "use_client_details"));
tl_clientPSet.setAttrib(Client.FIELD_Email, HELPER_Email.getFromRS(dummyEmail, r, "email")); tl_clientPSet.setAttrib(Client.FIELD_Email, HELPER_Email.getFromRS(dummyEmail, r, "email"));
tl_clientPSet.setAttrib(Client.FIELD_ContactName, HELPER_ContactName.getFromRS(dummyContactName, r, "contact_name")); tl_clientPSet.setAttrib(Client.FIELD_ContactName, HELPER_ContactName.getFromRS(dummyContactName, r, "contact_name"));
tl_clientPSet.setAttrib(Client.FIELD_ContactSurname, HELPER_ContactSurname.getFromRS(dummyContactSurname, r, "contact_surname")); tl_clientPSet.setAttrib(Client.FIELD_ContactSurname, HELPER_ContactSurname.getFromRS(dummyContactSurname, r, "contact_surname"));
...@@ -515,10 +520,10 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr ...@@ -515,10 +520,10 @@ public class ClientPersistenceMgr extends ObjectPersistenceMgr
{ {
executeStatement (sqlMgr, executeStatement (sqlMgr,
"INSERT INTO {PREFIX}tl_client " + "INSERT INTO {PREFIX}tl_client " +
" (client_name, client_logo, email, contact_name, contact_surname, phone, state, country, post_code, city, time_zone, hiring_team_id, company_id, object_id, object_LAST_UPDATED_DATE, object_CREATED_DATE) " + " (client_name, client_logo, use_client_details, email, contact_name, contact_surname, phone, state, country, post_code, city, time_zone, hiring_team_id, company_id, object_id, object_LAST_UPDATED_DATE, object_CREATED_DATE) " +
"VALUES " + "VALUES " +
" (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ", " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ")", " (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ", " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ")",
CollectionUtils.listEntry (HELPER_ClientName.getForSQL(dummyClientName, tl_clientPSet.getAttrib (Client.FIELD_ClientName))).listEntry (HELPER_ClientLogo.getForSQL(dummyClientLogo, tl_clientPSet.getAttrib (Client.FIELD_ClientLogo))).listEntry (HELPER_Email.getForSQL(dummyEmail, tl_clientPSet.getAttrib (Client.FIELD_Email))).listEntry (HELPER_ContactName.getForSQL(dummyContactName, tl_clientPSet.getAttrib (Client.FIELD_ContactName))).listEntry (HELPER_ContactSurname.getForSQL(dummyContactSurname, tl_clientPSet.getAttrib (Client.FIELD_ContactSurname))).listEntry (HELPER_Phone.getForSQL(dummyPhone, tl_clientPSet.getAttrib (Client.FIELD_Phone))).listEntry (HELPER_State.getForSQL(dummyState, tl_clientPSet.getAttrib (Client.FIELD_State))).listEntry (HELPER_Country.getForSQL(dummyCountry, tl_clientPSet.getAttrib (Client.FIELD_Country))).listEntry (HELPER_PostCode.getForSQL(dummyPostCode, tl_clientPSet.getAttrib (Client.FIELD_PostCode))).listEntry (HELPER_City.getForSQL(dummyCity, tl_clientPSet.getAttrib (Client.FIELD_City))).listEntry (HELPER_TimeZone.getForSQL(dummyTimeZone, tl_clientPSet.getAttrib (Client.FIELD_TimeZone))) .listEntry (SQLManager.CheckNull((Long)(tl_clientPSet.getAttrib (Client.SINGLEREFERENCE_HiringTeam)))).listEntry (SQLManager.CheckNull((Long)(tl_clientPSet.getAttrib (Client.SINGLEREFERENCE_Company)))) .listEntry (objectID.longID ()).toList().toArray()); CollectionUtils.listEntry (HELPER_ClientName.getForSQL(dummyClientName, tl_clientPSet.getAttrib (Client.FIELD_ClientName))).listEntry (HELPER_ClientLogo.getForSQL(dummyClientLogo, tl_clientPSet.getAttrib (Client.FIELD_ClientLogo))).listEntry (HELPER_UseClientDetails.getForSQL(dummyUseClientDetails, tl_clientPSet.getAttrib (Client.FIELD_UseClientDetails))).listEntry (HELPER_Email.getForSQL(dummyEmail, tl_clientPSet.getAttrib (Client.FIELD_Email))).listEntry (HELPER_ContactName.getForSQL(dummyContactName, tl_clientPSet.getAttrib (Client.FIELD_ContactName))).listEntry (HELPER_ContactSurname.getForSQL(dummyContactSurname, tl_clientPSet.getAttrib (Client.FIELD_ContactSurname))).listEntry (HELPER_Phone.getForSQL(dummyPhone, tl_clientPSet.getAttrib (Client.FIELD_Phone))).listEntry (HELPER_State.getForSQL(dummyState, tl_clientPSet.getAttrib (Client.FIELD_State))).listEntry (HELPER_Country.getForSQL(dummyCountry, tl_clientPSet.getAttrib (Client.FIELD_Country))).listEntry (HELPER_PostCode.getForSQL(dummyPostCode, tl_clientPSet.getAttrib (Client.FIELD_PostCode))).listEntry (HELPER_City.getForSQL(dummyCity, tl_clientPSet.getAttrib (Client.FIELD_City))).listEntry (HELPER_TimeZone.getForSQL(dummyTimeZone, tl_clientPSet.getAttrib (Client.FIELD_TimeZone))) .listEntry (SQLManager.CheckNull((Long)(tl_clientPSet.getAttrib (Client.SINGLEREFERENCE_HiringTeam)))).listEntry (SQLManager.CheckNull((Long)(tl_clientPSet.getAttrib (Client.SINGLEREFERENCE_Company)))) .listEntry (objectID.longID ()).toList().toArray());
tl_clientPSet.setStatus (PersistentSetStatus.PROCESSED); tl_clientPSet.setStatus (PersistentSetStatus.PROCESSED);
} }
......
package performa.orm; package performa.orm;
import java.io.*;
import java.util.*;
import oneit.appservices.config.*;
import oneit.logging.*;
import oneit.objstore.*;
import oneit.utils.*; import oneit.utils.*;
import performa.orm.types.*;
public class ILOJobTitle extends BaseILOJobTitle public class ILOJobTitle extends BaseILOJobTitle
{ {
...@@ -32,4 +20,3 @@ public class ILOJobTitle extends BaseILOJobTitle ...@@ -32,4 +20,3 @@ public class ILOJobTitle extends BaseILOJobTitle
} }
} }
\ No newline at end of file
...@@ -415,6 +415,16 @@ public class Job extends BaseJob ...@@ -415,6 +415,16 @@ public class Job extends BaseJob
return isTrue(getIncludeAssessmentCriteria()); return isTrue(getIncludeAssessmentCriteria());
} }
public boolean showCultureCriteriaSection()
{
return isTrue(getIncludeCulture());
}
public int getNumberOfSections()
{
return (showCultureCriteriaSection() && showAssessmentCriteriaSection() ? 3 : (showCultureCriteriaSection() || showAssessmentCriteriaSection()) ? 2 : 1);
}
public int getMaxShortlistApplicants() public int getMaxShortlistApplicants()
{ {
return 25; return 25;
...@@ -462,7 +472,7 @@ public class Job extends BaseJob ...@@ -462,7 +472,7 @@ public class Job extends BaseJob
title.append("Matchd - "); title.append("Matchd - ");
if(isClientAvailable()) if(isClientAvailable() && getClient().showUseClientDetails())
{ {
title.append(getClient()).append(" - "); title.append(getClient()).append(" - ");
} }
...@@ -549,30 +559,23 @@ public class Job extends BaseJob ...@@ -549,30 +559,23 @@ public class Job extends BaseJob
public BinaryContent getLogo() public BinaryContent getLogo()
{ {
if(isClientAvailable() && getClient().getClientLogo() != null) if(isClientAvailable() && getClient().showUseClientDetails())
{ {
return getClient().getClientLogo(); return getClient().getClientLogo();
} }
else if(getHiringTeam() != null)
{
return getHiringTeam().getHiringTeamLogo();
}
return null; return getHiringTeam() != null ? getHiringTeam().getHiringTeamLogo() : null;
} }
public String getTeamName() public String getTeamName()
{ {
if(isClientAvailable()) if(isClientAvailable() && getClient().showUseClientDetails())
{ {
return getClient().getClientName(); return getClient().getClientName();
} }
else if(getHiringTeam() != null)
{
return getHiringTeam().getHiringTeamName();
}
return ""; return getHiringTeam() != null ? getHiringTeam().getHiringTeamName() : "";
} }
...@@ -741,13 +744,58 @@ public class Job extends BaseJob ...@@ -741,13 +744,58 @@ public class Job extends BaseJob
if(occupation != null) if(occupation != null)
{ {
setOccupation(occupation); setOccupation(occupation);
setLevel(occupation.getAssessmentLevel()); setSuggestedAssessmentType(getJobType() == JobType.FULL_TIME ? occupation.getAssessmentType() : occupation.getPartTimeAssessmentType());
setAssessmentType(occupation.getAssessmentType()); setAssessmentType(getJobType() == JobType.FULL_TIME ? occupation.getAssessmentType() : occupation.getPartTimeAssessmentType());
setLevel(getAssessmentType() == AssessmentType.COMPREHENSIVE ? occupation.getAssessmentLevel() : occupation.getExpressAssessmentLevel());
} }
super.postILOJobTitleChange(); super.postILOJobTitleChange();
} }
@Override
protected void postJobTypeChange() throws FieldException
{
Occupation occupation = getILOJobTitle() != null ? getILOJobTitle().getOccupation() : null;
if(occupation != null)
{
setSuggestedAssessmentType(getJobType() == JobType.FULL_TIME ? occupation.getAssessmentType() : occupation.getPartTimeAssessmentType());
setAssessmentType(getJobType() == JobType.FULL_TIME ? occupation.getAssessmentType() : occupation.getPartTimeAssessmentType());
setLevel(getAssessmentType() == AssessmentType.COMPREHENSIVE ? occupation.getAssessmentLevel() : occupation.getExpressAssessmentLevel());
}
super.postJobTypeChange();
}
@Override
protected void postAssessmentTypeChange() throws FieldException
{
Occupation occupation = getILOJobTitle() != null ? getILOJobTitle().getOccupation() : null;
if(occupation != null && getSuggestedAssessmentType() != super.getAssessmentType())
{
setLevel(getAssessmentType() == AssessmentType.COMPREHENSIVE ? occupation.getAssessmentLevel() : occupation.getExpressAssessmentLevel());
}
super.postAssessmentTypeChange();
}
@Override
public AssessmentType getSuggestedAssessmentType()
{
Occupation occupation = getILOJobTitle() != null ? getILOJobTitle().getOccupation() : null;
if(occupation != null)
{
return getJobType() == JobType.FULL_TIME ? occupation.getAssessmentType() : occupation.getPartTimeAssessmentType();
}
return super.getSuggestedAssessmentType();
}
public Occupation displayOccupation() public Occupation displayOccupation()
{ {
return getOccupation(); return getOccupation();
......
...@@ -24,6 +24,7 @@ ...@@ -24,6 +24,7 @@
<TRANSIENT name="AssessmentTemplateName" type="String"/> <TRANSIENT name="AssessmentTemplateName" type="String"/>
<TRANSIENT name="CultureTemplateName" type="String"/> <TRANSIENT name="CultureTemplateName" type="String"/>
<TRANSIENT name="AppProcessOption" type="AppProcessOption" attribHelper="EnumeratedAttributeHelper"/> <TRANSIENT name="AppProcessOption" type="AppProcessOption" attribHelper="EnumeratedAttributeHelper"/>
<TRANSIENT name="SuggestedAssessmentType" type="AssessmentType" attribHelper="EnumeratedAttributeHelper"/>
<TRANSIENT name="RankingCompleted" type="Boolean" /> <TRANSIENT name="RankingCompleted" type="Boolean" />
<TRANSIENTSINGLE name="CultureTemplate" type="CultureCriteriaTemplate" /> <TRANSIENTSINGLE name="CultureTemplate" type="CultureCriteriaTemplate" />
...@@ -38,6 +39,7 @@ ...@@ -38,6 +39,7 @@
<ATTRIB name="OpenDate" type="Date" dbcol="open_date"/> <ATTRIB name="OpenDate" type="Date" dbcol="open_date"/>
<ATTRIB name="ApplyBy" type="Date" dbcol="apply_by"/> <ATTRIB name="ApplyBy" type="Date" dbcol="apply_by"/>
<ATTRIB name="IncludeAssessmentCriteria" type="Boolean" dbcol="include_assessment_criteria" mandatory="true" defaultValue="Boolean.TRUE"/> <ATTRIB name="IncludeAssessmentCriteria" type="Boolean" dbcol="include_assessment_criteria" mandatory="true" defaultValue="Boolean.TRUE"/>
<ATTRIB name="IncludeCulture" type="Boolean" dbcol="include_culture" mandatory="true" defaultValue="Boolean.TRUE"/>
<ATTRIB name="AssessmentType" type="AssessmentType" dbcol="assessment_type" attribHelper="EnumeratedAttributeHelper" mandatory="true" defaultValue="AssessmentType.COMPREHENSIVE"/> <ATTRIB name="AssessmentType" type="AssessmentType" dbcol="assessment_type" attribHelper="EnumeratedAttributeHelper" mandatory="true" defaultValue="AssessmentType.COMPREHENSIVE"/>
<ATTRIB name="RandomKey" type="String" dbcol="random_key" length="10"/> <ATTRIB name="RandomKey" type="String" dbcol="random_key" length="10"/>
<ATTRIB name="JobType" type="JobType" dbcol="job_type" attribHelper="EnumeratedAttributeHelper" mandatory="true" defaultValue="JobType.FULL_TIME"/> <ATTRIB name="JobType" type="JobType" dbcol="job_type" attribHelper="EnumeratedAttributeHelper" mandatory="true" defaultValue="JobType.FULL_TIME"/>
......
...@@ -165,7 +165,7 @@ public class JobApplication extends BaseJobApplication ...@@ -165,7 +165,7 @@ public class JobApplication extends BaseJobApplication
Candidate candidate = getCandidate(); Candidate candidate = getCandidate();
//to skip culture test //to skip culture test
if(cultureCompleted()) if(!isIncludeCultureCriteria() || cultureCompleted())
{ {
return safeRedirect; return safeRedirect;
} }
...@@ -249,7 +249,7 @@ public class JobApplication extends BaseJobApplication ...@@ -249,7 +249,7 @@ public class JobApplication extends BaseJobApplication
public boolean cultureCompleted() public boolean cultureCompleted()
{ {
return getCandidate().cultureCompleted(getJob()); return isIncludeCultureCriteria() ? getCandidate().cultureCompleted(getJob()) : true;
} }
...@@ -281,6 +281,11 @@ public class JobApplication extends BaseJobApplication ...@@ -281,6 +281,11 @@ public class JobApplication extends BaseJobApplication
return getJob() != null && isTrue(getJob().getIncludeAssessmentCriteria()); return getJob() != null && isTrue(getJob().getIncludeAssessmentCriteria());
} }
public boolean isIncludeCultureCriteria()
{
return getJob() != null && isTrue(getJob().getIncludeCulture());
}
@Override @Override
public Map getRoleFit() public Map getRoleFit()
{ {
...@@ -709,7 +714,7 @@ public class JobApplication extends BaseJobApplication ...@@ -709,7 +714,7 @@ public class JobApplication extends BaseJobApplication
{ {
Tuple.T3<Double, ColorCode, Double> roleFitData = (getRoleFit() != null && getRoleFit().get(null) != null) ? (Tuple.T3<Double, ColorCode, Double>) getRoleFit().get(null) : null; Tuple.T3<Double, ColorCode, Double> roleFitData = (getRoleFit() != null && getRoleFit().get(null) != null) ? (Tuple.T3<Double, ColorCode, Double>) getRoleFit().get(null) : null;
double score = roleFitData != null ? roleFitData.get2() : 0d; double score = roleFitData != null ? roleFitData.get2() > 0 ? roleFitData.get2() : 0d : 0d;
Color color = roleFitData != null ? Utils.getColor(roleFitData.get1()) : RingChart.GREEN; Color color = roleFitData != null ? Utils.getColor(roleFitData.get1()) : RingChart.GREEN;
return new RingChart(getID().toString() + "rolefit.jpeg").addData("Completed", score , color).addData("Incomplete", (100 - score), RingChart.GREY).getChartImage(); return new RingChart(getID().toString() + "rolefit.jpeg").addData("Completed", score , color).addData("Incomplete", (100 - score), RingChart.GREY).getChartImage();
......
...@@ -34,6 +34,7 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr ...@@ -34,6 +34,7 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr
private Date dummyOpenDate; private Date dummyOpenDate;
private Date dummyApplyBy; private Date dummyApplyBy;
private Boolean dummyIncludeAssessmentCriteria; private Boolean dummyIncludeAssessmentCriteria;
private Boolean dummyIncludeCulture;
private AssessmentType dummyAssessmentType; private AssessmentType dummyAssessmentType;
private String dummyRandomKey; private String dummyRandomKey;
private JobType dummyJobType; private JobType dummyJobType;
...@@ -62,6 +63,7 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr ...@@ -62,6 +63,7 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr
private static final DefaultAttributeHelper HELPER_OpenDate = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper HELPER_OpenDate = DefaultAttributeHelper.INSTANCE;
private static final DefaultAttributeHelper HELPER_ApplyBy = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper HELPER_ApplyBy = DefaultAttributeHelper.INSTANCE;
private static final DefaultAttributeHelper HELPER_IncludeAssessmentCriteria = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper HELPER_IncludeAssessmentCriteria = DefaultAttributeHelper.INSTANCE;
private static final DefaultAttributeHelper HELPER_IncludeCulture = DefaultAttributeHelper.INSTANCE;
private static final EnumeratedAttributeHelper HELPER_AssessmentType = new EnumeratedAttributeHelper (AssessmentType.FACTORY_AssessmentType); private static final EnumeratedAttributeHelper HELPER_AssessmentType = new EnumeratedAttributeHelper (AssessmentType.FACTORY_AssessmentType);
private static final DefaultAttributeHelper HELPER_RandomKey = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper HELPER_RandomKey = DefaultAttributeHelper.INSTANCE;
private static final EnumeratedAttributeHelper HELPER_JobType = new EnumeratedAttributeHelper (JobType.FACTORY_JobType); private static final EnumeratedAttributeHelper HELPER_JobType = new EnumeratedAttributeHelper (JobType.FACTORY_JobType);
...@@ -93,6 +95,7 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr ...@@ -93,6 +95,7 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr
dummyOpenDate = (Date)(HELPER_OpenDate.initialise (dummyOpenDate)); dummyOpenDate = (Date)(HELPER_OpenDate.initialise (dummyOpenDate));
dummyApplyBy = (Date)(HELPER_ApplyBy.initialise (dummyApplyBy)); dummyApplyBy = (Date)(HELPER_ApplyBy.initialise (dummyApplyBy));
dummyIncludeAssessmentCriteria = (Boolean)(HELPER_IncludeAssessmentCriteria.initialise (dummyIncludeAssessmentCriteria)); dummyIncludeAssessmentCriteria = (Boolean)(HELPER_IncludeAssessmentCriteria.initialise (dummyIncludeAssessmentCriteria));
dummyIncludeCulture = (Boolean)(HELPER_IncludeCulture.initialise (dummyIncludeCulture));
dummyAssessmentType = (AssessmentType)(HELPER_AssessmentType.initialise (dummyAssessmentType)); dummyAssessmentType = (AssessmentType)(HELPER_AssessmentType.initialise (dummyAssessmentType));
dummyRandomKey = (String)(HELPER_RandomKey.initialise (dummyRandomKey)); dummyRandomKey = (String)(HELPER_RandomKey.initialise (dummyRandomKey));
dummyJobType = (JobType)(HELPER_JobType.initialise (dummyJobType)); dummyJobType = (JobType)(HELPER_JobType.initialise (dummyJobType));
...@@ -115,7 +118,7 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr ...@@ -115,7 +118,7 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr
} }
private String SELECT_COLUMNS = "{PREFIX}tl_job.object_id as id, {PREFIX}tl_job.object_LAST_UPDATED_DATE as LAST_UPDATED_DATE, {PREFIX}tl_job.object_CREATED_DATE as CREATED_DATE, {PREFIX}tl_job.job_title, {PREFIX}tl_job.job_description, {PREFIX}tl_job.job_status, {PREFIX}tl_job.open_date, {PREFIX}tl_job.apply_by, {PREFIX}tl_job.include_assessment_criteria, {PREFIX}tl_job.assessment_type, {PREFIX}tl_job.random_key, {PREFIX}tl_job.job_type, {PREFIX}tl_job.ref_number, {PREFIX}tl_job.last_status_change_date, {PREFIX}tl_job.remote, {PREFIX}tl_job.city, {PREFIX}tl_job.postcode, {PREFIX}tl_job.location_radius, {PREFIX}tl_job.state, {PREFIX}tl_job.country, {PREFIX}tl_job.require_cv, {PREFIX}tl_job.manually_closed, {PREFIX}tl_job.last_edited, {PREFIX}tl_job.is_ppj, {PREFIX}tl_job.industry, {PREFIX}tl_job.culture_statement, {PREFIX}tl_job.draft_location, {PREFIX}tl_job.google_address_text, {PREFIX}tl_job.level_id, {PREFIX}tl_job.client_id, {PREFIX}tl_job.job_owner_id, {PREFIX}tl_job.company_user_id, {PREFIX}tl_job.hiring_team_id, {PREFIX}tl_job.occupation_id, {PREFIX}tl_job.shortened_url_id, {PREFIX}tl_job.template_id, {PREFIX}tl_job.job_title_id, 1 AS commasafe "; private String SELECT_COLUMNS = "{PREFIX}tl_job.object_id as id, {PREFIX}tl_job.object_LAST_UPDATED_DATE as LAST_UPDATED_DATE, {PREFIX}tl_job.object_CREATED_DATE as CREATED_DATE, {PREFIX}tl_job.job_title, {PREFIX}tl_job.job_description, {PREFIX}tl_job.job_status, {PREFIX}tl_job.open_date, {PREFIX}tl_job.apply_by, {PREFIX}tl_job.include_assessment_criteria, {PREFIX}tl_job.include_culture, {PREFIX}tl_job.assessment_type, {PREFIX}tl_job.random_key, {PREFIX}tl_job.job_type, {PREFIX}tl_job.ref_number, {PREFIX}tl_job.last_status_change_date, {PREFIX}tl_job.remote, {PREFIX}tl_job.city, {PREFIX}tl_job.postcode, {PREFIX}tl_job.location_radius, {PREFIX}tl_job.state, {PREFIX}tl_job.country, {PREFIX}tl_job.require_cv, {PREFIX}tl_job.manually_closed, {PREFIX}tl_job.last_edited, {PREFIX}tl_job.is_ppj, {PREFIX}tl_job.industry, {PREFIX}tl_job.culture_statement, {PREFIX}tl_job.draft_location, {PREFIX}tl_job.google_address_text, {PREFIX}tl_job.level_id, {PREFIX}tl_job.client_id, {PREFIX}tl_job.job_owner_id, {PREFIX}tl_job.company_user_id, {PREFIX}tl_job.hiring_team_id, {PREFIX}tl_job.occupation_id, {PREFIX}tl_job.shortened_url_id, {PREFIX}tl_job.template_id, {PREFIX}tl_job.job_title_id, 1 AS commasafe ";
private String SELECT_JOINS = ""; private String SELECT_JOINS = "";
public BaseBusinessClass fetchByID(ObjectID id, PersistentSetCollection allPSets, RDBMSPersistenceContext context, SQLManager sqlMgr) throws SQLException, StorageException public BaseBusinessClass fetchByID(ObjectID id, PersistentSetCollection allPSets, RDBMSPersistenceContext context, SQLManager sqlMgr) throws SQLException, StorageException
...@@ -172,6 +175,7 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr ...@@ -172,6 +175,7 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr
!tl_jobPSet.containsAttrib(Job.FIELD_OpenDate)|| !tl_jobPSet.containsAttrib(Job.FIELD_OpenDate)||
!tl_jobPSet.containsAttrib(Job.FIELD_ApplyBy)|| !tl_jobPSet.containsAttrib(Job.FIELD_ApplyBy)||
!tl_jobPSet.containsAttrib(Job.FIELD_IncludeAssessmentCriteria)|| !tl_jobPSet.containsAttrib(Job.FIELD_IncludeAssessmentCriteria)||
!tl_jobPSet.containsAttrib(Job.FIELD_IncludeCulture)||
!tl_jobPSet.containsAttrib(Job.FIELD_AssessmentType)|| !tl_jobPSet.containsAttrib(Job.FIELD_AssessmentType)||
!tl_jobPSet.containsAttrib(Job.FIELD_RandomKey)|| !tl_jobPSet.containsAttrib(Job.FIELD_RandomKey)||
!tl_jobPSet.containsAttrib(Job.FIELD_JobType)|| !tl_jobPSet.containsAttrib(Job.FIELD_JobType)||
...@@ -279,10 +283,10 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr ...@@ -279,10 +283,10 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr
{ {
int rowsUpdated = executeStatement (sqlMgr, int rowsUpdated = executeStatement (sqlMgr,
"UPDATE {PREFIX}tl_job " + "UPDATE {PREFIX}tl_job " +
"SET job_title = ?, job_description = ?, job_status = ?, open_date = ?, apply_by = ?, include_assessment_criteria = ?, assessment_type = ?, random_key = ?, job_type = ?, ref_number = ?, last_status_change_date = ?, remote = ?, city = ?, postcode = ?, location_radius = ?, state = ?, country = ?, require_cv = ?, manually_closed = ?, last_edited = ?, is_ppj = ?, industry = ?, culture_statement = ?, draft_location = ?, google_address_text = ?, level_id = ? , client_id = ? , job_owner_id = ? , company_user_id = ? , hiring_team_id = ? , occupation_id = ? , shortened_url_id = ? , template_id = ? , job_title_id = ? , object_LAST_UPDATED_DATE = " + sqlMgr.getPortabilityServices ().getTimestampExpression () + " " + "SET job_title = ?, job_description = ?, job_status = ?, open_date = ?, apply_by = ?, include_assessment_criteria = ?, include_culture = ?, assessment_type = ?, random_key = ?, job_type = ?, ref_number = ?, last_status_change_date = ?, remote = ?, city = ?, postcode = ?, location_radius = ?, state = ?, country = ?, require_cv = ?, manually_closed = ?, last_edited = ?, is_ppj = ?, industry = ?, culture_statement = ?, draft_location = ?, google_address_text = ?, level_id = ? , client_id = ? , job_owner_id = ? , company_user_id = ? , hiring_team_id = ? , occupation_id = ? , shortened_url_id = ? , template_id = ? , job_title_id = ? , object_LAST_UPDATED_DATE = " + sqlMgr.getPortabilityServices ().getTimestampExpression () + " " +
"WHERE tl_job.object_id = ? AND " + getConcurrencyCheck (sqlMgr, "object_LAST_UPDATED_DATE", obj.getObjectLastModified ()) + " ", "WHERE tl_job.object_id = ? AND " + getConcurrencyCheck (sqlMgr, "object_LAST_UPDATED_DATE", obj.getObjectLastModified ()) + " ",
CollectionUtils.listEntry (HELPER_JobTitle.getForSQL(dummyJobTitle, tl_jobPSet.getAttrib (Job.FIELD_JobTitle))).listEntry (HELPER_JobDescription.getForSQL(dummyJobDescription, tl_jobPSet.getAttrib (Job.FIELD_JobDescription))).listEntry (HELPER_JobStatus.getForSQL(dummyJobStatus, tl_jobPSet.getAttrib (Job.FIELD_JobStatus))).listEntry (HELPER_OpenDate.getForSQL(dummyOpenDate, tl_jobPSet.getAttrib (Job.FIELD_OpenDate))).listEntry (HELPER_ApplyBy.getForSQL(dummyApplyBy, tl_jobPSet.getAttrib (Job.FIELD_ApplyBy))).listEntry (HELPER_IncludeAssessmentCriteria.getForSQL(dummyIncludeAssessmentCriteria, tl_jobPSet.getAttrib (Job.FIELD_IncludeAssessmentCriteria))).listEntry (HELPER_AssessmentType.getForSQL(dummyAssessmentType, tl_jobPSet.getAttrib (Job.FIELD_AssessmentType))).listEntry (HELPER_RandomKey.getForSQL(dummyRandomKey, tl_jobPSet.getAttrib (Job.FIELD_RandomKey))).listEntry (HELPER_JobType.getForSQL(dummyJobType, tl_jobPSet.getAttrib (Job.FIELD_JobType))).listEntry (HELPER_ReferenceNumber.getForSQL(dummyReferenceNumber, tl_jobPSet.getAttrib (Job.FIELD_ReferenceNumber))).listEntry (HELPER_LastStatusChangeDate.getForSQL(dummyLastStatusChangeDate, tl_jobPSet.getAttrib (Job.FIELD_LastStatusChangeDate))).listEntry (HELPER_Remote.getForSQL(dummyRemote, tl_jobPSet.getAttrib (Job.FIELD_Remote))).listEntry (HELPER_City.getForSQL(dummyCity, tl_jobPSet.getAttrib (Job.FIELD_City))).listEntry (HELPER_PostCode.getForSQL(dummyPostCode, tl_jobPSet.getAttrib (Job.FIELD_PostCode))).listEntry (HELPER_ExpectedCandidateRadius.getForSQL(dummyExpectedCandidateRadius, tl_jobPSet.getAttrib (Job.FIELD_ExpectedCandidateRadius))).listEntry (HELPER_State.getForSQL(dummyState, tl_jobPSet.getAttrib (Job.FIELD_State))).listEntry (HELPER_Country.getForSQL(dummyCountry, tl_jobPSet.getAttrib (Job.FIELD_Country))).listEntry (HELPER_RequireCV.getForSQL(dummyRequireCV, tl_jobPSet.getAttrib (Job.FIELD_RequireCV))).listEntry (HELPER_IsManuallyClosed.getForSQL(dummyIsManuallyClosed, tl_jobPSet.getAttrib (Job.FIELD_IsManuallyClosed))).listEntry (HELPER_LastEdited.getForSQL(dummyLastEdited, tl_jobPSet.getAttrib (Job.FIELD_LastEdited))).listEntry (HELPER_IsPPJ.getForSQL(dummyIsPPJ, tl_jobPSet.getAttrib (Job.FIELD_IsPPJ))).listEntry (HELPER_Industry.getForSQL(dummyIndustry, tl_jobPSet.getAttrib (Job.FIELD_Industry))).listEntry (HELPER_CultureStatement.getForSQL(dummyCultureStatement, tl_jobPSet.getAttrib (Job.FIELD_CultureStatement))).listEntry (HELPER_DraftLocation.getForSQL(dummyDraftLocation, tl_jobPSet.getAttrib (Job.FIELD_DraftLocation))).listEntry (HELPER_GoogleAddressText.getForSQL(dummyGoogleAddressText, tl_jobPSet.getAttrib (Job.FIELD_GoogleAddressText))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_Level)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_Client)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_JobOwner)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_CreatedBy)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_HiringTeam)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_Occupation)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_ShortenedURL)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_AssessmentTemplate)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_ILOJobTitle)))).listEntry (objectID.longID ()).listEntry (obj.getObjectLastModified ()).toList().toArray()); CollectionUtils.listEntry (HELPER_JobTitle.getForSQL(dummyJobTitle, tl_jobPSet.getAttrib (Job.FIELD_JobTitle))).listEntry (HELPER_JobDescription.getForSQL(dummyJobDescription, tl_jobPSet.getAttrib (Job.FIELD_JobDescription))).listEntry (HELPER_JobStatus.getForSQL(dummyJobStatus, tl_jobPSet.getAttrib (Job.FIELD_JobStatus))).listEntry (HELPER_OpenDate.getForSQL(dummyOpenDate, tl_jobPSet.getAttrib (Job.FIELD_OpenDate))).listEntry (HELPER_ApplyBy.getForSQL(dummyApplyBy, tl_jobPSet.getAttrib (Job.FIELD_ApplyBy))).listEntry (HELPER_IncludeAssessmentCriteria.getForSQL(dummyIncludeAssessmentCriteria, tl_jobPSet.getAttrib (Job.FIELD_IncludeAssessmentCriteria))).listEntry (HELPER_IncludeCulture.getForSQL(dummyIncludeCulture, tl_jobPSet.getAttrib (Job.FIELD_IncludeCulture))).listEntry (HELPER_AssessmentType.getForSQL(dummyAssessmentType, tl_jobPSet.getAttrib (Job.FIELD_AssessmentType))).listEntry (HELPER_RandomKey.getForSQL(dummyRandomKey, tl_jobPSet.getAttrib (Job.FIELD_RandomKey))).listEntry (HELPER_JobType.getForSQL(dummyJobType, tl_jobPSet.getAttrib (Job.FIELD_JobType))).listEntry (HELPER_ReferenceNumber.getForSQL(dummyReferenceNumber, tl_jobPSet.getAttrib (Job.FIELD_ReferenceNumber))).listEntry (HELPER_LastStatusChangeDate.getForSQL(dummyLastStatusChangeDate, tl_jobPSet.getAttrib (Job.FIELD_LastStatusChangeDate))).listEntry (HELPER_Remote.getForSQL(dummyRemote, tl_jobPSet.getAttrib (Job.FIELD_Remote))).listEntry (HELPER_City.getForSQL(dummyCity, tl_jobPSet.getAttrib (Job.FIELD_City))).listEntry (HELPER_PostCode.getForSQL(dummyPostCode, tl_jobPSet.getAttrib (Job.FIELD_PostCode))).listEntry (HELPER_ExpectedCandidateRadius.getForSQL(dummyExpectedCandidateRadius, tl_jobPSet.getAttrib (Job.FIELD_ExpectedCandidateRadius))).listEntry (HELPER_State.getForSQL(dummyState, tl_jobPSet.getAttrib (Job.FIELD_State))).listEntry (HELPER_Country.getForSQL(dummyCountry, tl_jobPSet.getAttrib (Job.FIELD_Country))).listEntry (HELPER_RequireCV.getForSQL(dummyRequireCV, tl_jobPSet.getAttrib (Job.FIELD_RequireCV))).listEntry (HELPER_IsManuallyClosed.getForSQL(dummyIsManuallyClosed, tl_jobPSet.getAttrib (Job.FIELD_IsManuallyClosed))).listEntry (HELPER_LastEdited.getForSQL(dummyLastEdited, tl_jobPSet.getAttrib (Job.FIELD_LastEdited))).listEntry (HELPER_IsPPJ.getForSQL(dummyIsPPJ, tl_jobPSet.getAttrib (Job.FIELD_IsPPJ))).listEntry (HELPER_Industry.getForSQL(dummyIndustry, tl_jobPSet.getAttrib (Job.FIELD_Industry))).listEntry (HELPER_CultureStatement.getForSQL(dummyCultureStatement, tl_jobPSet.getAttrib (Job.FIELD_CultureStatement))).listEntry (HELPER_DraftLocation.getForSQL(dummyDraftLocation, tl_jobPSet.getAttrib (Job.FIELD_DraftLocation))).listEntry (HELPER_GoogleAddressText.getForSQL(dummyGoogleAddressText, tl_jobPSet.getAttrib (Job.FIELD_GoogleAddressText))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_Level)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_Client)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_JobOwner)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_CreatedBy)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_HiringTeam)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_Occupation)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_ShortenedURL)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_AssessmentTemplate)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_ILOJobTitle)))).listEntry (objectID.longID ()).listEntry (obj.getObjectLastModified ()).toList().toArray());
if (rowsUpdated != 1) if (rowsUpdated != 1)
{ {
...@@ -708,6 +712,7 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr ...@@ -708,6 +712,7 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr
tl_jobPSet.setAttrib(Job.FIELD_OpenDate, HELPER_OpenDate.getFromRS(dummyOpenDate, r, "open_date")); tl_jobPSet.setAttrib(Job.FIELD_OpenDate, HELPER_OpenDate.getFromRS(dummyOpenDate, r, "open_date"));
tl_jobPSet.setAttrib(Job.FIELD_ApplyBy, HELPER_ApplyBy.getFromRS(dummyApplyBy, r, "apply_by")); tl_jobPSet.setAttrib(Job.FIELD_ApplyBy, HELPER_ApplyBy.getFromRS(dummyApplyBy, r, "apply_by"));
tl_jobPSet.setAttrib(Job.FIELD_IncludeAssessmentCriteria, HELPER_IncludeAssessmentCriteria.getFromRS(dummyIncludeAssessmentCriteria, r, "include_assessment_criteria")); tl_jobPSet.setAttrib(Job.FIELD_IncludeAssessmentCriteria, HELPER_IncludeAssessmentCriteria.getFromRS(dummyIncludeAssessmentCriteria, r, "include_assessment_criteria"));
tl_jobPSet.setAttrib(Job.FIELD_IncludeCulture, HELPER_IncludeCulture.getFromRS(dummyIncludeCulture, r, "include_culture"));
tl_jobPSet.setAttrib(Job.FIELD_AssessmentType, HELPER_AssessmentType.getFromRS(dummyAssessmentType, r, "assessment_type")); tl_jobPSet.setAttrib(Job.FIELD_AssessmentType, HELPER_AssessmentType.getFromRS(dummyAssessmentType, r, "assessment_type"));
tl_jobPSet.setAttrib(Job.FIELD_RandomKey, HELPER_RandomKey.getFromRS(dummyRandomKey, r, "random_key")); tl_jobPSet.setAttrib(Job.FIELD_RandomKey, HELPER_RandomKey.getFromRS(dummyRandomKey, r, "random_key"));
tl_jobPSet.setAttrib(Job.FIELD_JobType, HELPER_JobType.getFromRS(dummyJobType, r, "job_type")); tl_jobPSet.setAttrib(Job.FIELD_JobType, HELPER_JobType.getFromRS(dummyJobType, r, "job_type"));
...@@ -753,10 +758,10 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr ...@@ -753,10 +758,10 @@ public class JobPersistenceMgr extends ObjectPersistenceMgr
{ {
executeStatement (sqlMgr, executeStatement (sqlMgr,
"INSERT INTO {PREFIX}tl_job " + "INSERT INTO {PREFIX}tl_job " +
" (job_title, job_description, job_status, open_date, apply_by, include_assessment_criteria, assessment_type, random_key, job_type, ref_number, last_status_change_date, remote, city, postcode, location_radius, state, country, require_cv, manually_closed, last_edited, is_ppj, industry, culture_statement, draft_location, google_address_text, level_id, client_id, job_owner_id, company_user_id, hiring_team_id, occupation_id, shortened_url_id, template_id, job_title_id, object_id, object_LAST_UPDATED_DATE, object_CREATED_DATE) " + " (job_title, job_description, job_status, open_date, apply_by, include_assessment_criteria, include_culture, assessment_type, random_key, job_type, ref_number, last_status_change_date, remote, city, postcode, location_radius, state, country, require_cv, manually_closed, last_edited, is_ppj, industry, culture_statement, draft_location, google_address_text, level_id, client_id, job_owner_id, company_user_id, hiring_team_id, occupation_id, shortened_url_id, template_id, job_title_id, object_id, object_LAST_UPDATED_DATE, object_CREATED_DATE) " +
"VALUES " + "VALUES " +
" (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ", " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ")", " (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ", " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ")",
CollectionUtils.listEntry (HELPER_JobTitle.getForSQL(dummyJobTitle, tl_jobPSet.getAttrib (Job.FIELD_JobTitle))).listEntry (HELPER_JobDescription.getForSQL(dummyJobDescription, tl_jobPSet.getAttrib (Job.FIELD_JobDescription))).listEntry (HELPER_JobStatus.getForSQL(dummyJobStatus, tl_jobPSet.getAttrib (Job.FIELD_JobStatus))).listEntry (HELPER_OpenDate.getForSQL(dummyOpenDate, tl_jobPSet.getAttrib (Job.FIELD_OpenDate))).listEntry (HELPER_ApplyBy.getForSQL(dummyApplyBy, tl_jobPSet.getAttrib (Job.FIELD_ApplyBy))).listEntry (HELPER_IncludeAssessmentCriteria.getForSQL(dummyIncludeAssessmentCriteria, tl_jobPSet.getAttrib (Job.FIELD_IncludeAssessmentCriteria))).listEntry (HELPER_AssessmentType.getForSQL(dummyAssessmentType, tl_jobPSet.getAttrib (Job.FIELD_AssessmentType))).listEntry (HELPER_RandomKey.getForSQL(dummyRandomKey, tl_jobPSet.getAttrib (Job.FIELD_RandomKey))).listEntry (HELPER_JobType.getForSQL(dummyJobType, tl_jobPSet.getAttrib (Job.FIELD_JobType))).listEntry (HELPER_ReferenceNumber.getForSQL(dummyReferenceNumber, tl_jobPSet.getAttrib (Job.FIELD_ReferenceNumber))).listEntry (HELPER_LastStatusChangeDate.getForSQL(dummyLastStatusChangeDate, tl_jobPSet.getAttrib (Job.FIELD_LastStatusChangeDate))).listEntry (HELPER_Remote.getForSQL(dummyRemote, tl_jobPSet.getAttrib (Job.FIELD_Remote))).listEntry (HELPER_City.getForSQL(dummyCity, tl_jobPSet.getAttrib (Job.FIELD_City))).listEntry (HELPER_PostCode.getForSQL(dummyPostCode, tl_jobPSet.getAttrib (Job.FIELD_PostCode))).listEntry (HELPER_ExpectedCandidateRadius.getForSQL(dummyExpectedCandidateRadius, tl_jobPSet.getAttrib (Job.FIELD_ExpectedCandidateRadius))).listEntry (HELPER_State.getForSQL(dummyState, tl_jobPSet.getAttrib (Job.FIELD_State))).listEntry (HELPER_Country.getForSQL(dummyCountry, tl_jobPSet.getAttrib (Job.FIELD_Country))).listEntry (HELPER_RequireCV.getForSQL(dummyRequireCV, tl_jobPSet.getAttrib (Job.FIELD_RequireCV))).listEntry (HELPER_IsManuallyClosed.getForSQL(dummyIsManuallyClosed, tl_jobPSet.getAttrib (Job.FIELD_IsManuallyClosed))).listEntry (HELPER_LastEdited.getForSQL(dummyLastEdited, tl_jobPSet.getAttrib (Job.FIELD_LastEdited))).listEntry (HELPER_IsPPJ.getForSQL(dummyIsPPJ, tl_jobPSet.getAttrib (Job.FIELD_IsPPJ))).listEntry (HELPER_Industry.getForSQL(dummyIndustry, tl_jobPSet.getAttrib (Job.FIELD_Industry))).listEntry (HELPER_CultureStatement.getForSQL(dummyCultureStatement, tl_jobPSet.getAttrib (Job.FIELD_CultureStatement))).listEntry (HELPER_DraftLocation.getForSQL(dummyDraftLocation, tl_jobPSet.getAttrib (Job.FIELD_DraftLocation))).listEntry (HELPER_GoogleAddressText.getForSQL(dummyGoogleAddressText, tl_jobPSet.getAttrib (Job.FIELD_GoogleAddressText))) .listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_Level)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_Client)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_JobOwner)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_CreatedBy)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_HiringTeam)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_Occupation)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_ShortenedURL)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_AssessmentTemplate)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_ILOJobTitle)))) .listEntry (objectID.longID ()).toList().toArray()); CollectionUtils.listEntry (HELPER_JobTitle.getForSQL(dummyJobTitle, tl_jobPSet.getAttrib (Job.FIELD_JobTitle))).listEntry (HELPER_JobDescription.getForSQL(dummyJobDescription, tl_jobPSet.getAttrib (Job.FIELD_JobDescription))).listEntry (HELPER_JobStatus.getForSQL(dummyJobStatus, tl_jobPSet.getAttrib (Job.FIELD_JobStatus))).listEntry (HELPER_OpenDate.getForSQL(dummyOpenDate, tl_jobPSet.getAttrib (Job.FIELD_OpenDate))).listEntry (HELPER_ApplyBy.getForSQL(dummyApplyBy, tl_jobPSet.getAttrib (Job.FIELD_ApplyBy))).listEntry (HELPER_IncludeAssessmentCriteria.getForSQL(dummyIncludeAssessmentCriteria, tl_jobPSet.getAttrib (Job.FIELD_IncludeAssessmentCriteria))).listEntry (HELPER_IncludeCulture.getForSQL(dummyIncludeCulture, tl_jobPSet.getAttrib (Job.FIELD_IncludeCulture))).listEntry (HELPER_AssessmentType.getForSQL(dummyAssessmentType, tl_jobPSet.getAttrib (Job.FIELD_AssessmentType))).listEntry (HELPER_RandomKey.getForSQL(dummyRandomKey, tl_jobPSet.getAttrib (Job.FIELD_RandomKey))).listEntry (HELPER_JobType.getForSQL(dummyJobType, tl_jobPSet.getAttrib (Job.FIELD_JobType))).listEntry (HELPER_ReferenceNumber.getForSQL(dummyReferenceNumber, tl_jobPSet.getAttrib (Job.FIELD_ReferenceNumber))).listEntry (HELPER_LastStatusChangeDate.getForSQL(dummyLastStatusChangeDate, tl_jobPSet.getAttrib (Job.FIELD_LastStatusChangeDate))).listEntry (HELPER_Remote.getForSQL(dummyRemote, tl_jobPSet.getAttrib (Job.FIELD_Remote))).listEntry (HELPER_City.getForSQL(dummyCity, tl_jobPSet.getAttrib (Job.FIELD_City))).listEntry (HELPER_PostCode.getForSQL(dummyPostCode, tl_jobPSet.getAttrib (Job.FIELD_PostCode))).listEntry (HELPER_ExpectedCandidateRadius.getForSQL(dummyExpectedCandidateRadius, tl_jobPSet.getAttrib (Job.FIELD_ExpectedCandidateRadius))).listEntry (HELPER_State.getForSQL(dummyState, tl_jobPSet.getAttrib (Job.FIELD_State))).listEntry (HELPER_Country.getForSQL(dummyCountry, tl_jobPSet.getAttrib (Job.FIELD_Country))).listEntry (HELPER_RequireCV.getForSQL(dummyRequireCV, tl_jobPSet.getAttrib (Job.FIELD_RequireCV))).listEntry (HELPER_IsManuallyClosed.getForSQL(dummyIsManuallyClosed, tl_jobPSet.getAttrib (Job.FIELD_IsManuallyClosed))).listEntry (HELPER_LastEdited.getForSQL(dummyLastEdited, tl_jobPSet.getAttrib (Job.FIELD_LastEdited))).listEntry (HELPER_IsPPJ.getForSQL(dummyIsPPJ, tl_jobPSet.getAttrib (Job.FIELD_IsPPJ))).listEntry (HELPER_Industry.getForSQL(dummyIndustry, tl_jobPSet.getAttrib (Job.FIELD_Industry))).listEntry (HELPER_CultureStatement.getForSQL(dummyCultureStatement, tl_jobPSet.getAttrib (Job.FIELD_CultureStatement))).listEntry (HELPER_DraftLocation.getForSQL(dummyDraftLocation, tl_jobPSet.getAttrib (Job.FIELD_DraftLocation))).listEntry (HELPER_GoogleAddressText.getForSQL(dummyGoogleAddressText, tl_jobPSet.getAttrib (Job.FIELD_GoogleAddressText))) .listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_Level)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_Client)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_JobOwner)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_CreatedBy)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_HiringTeam)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_Occupation)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_ShortenedURL)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_AssessmentTemplate)))).listEntry (SQLManager.CheckNull((Long)(tl_jobPSet.getAttrib (Job.SINGLEREFERENCE_ILOJobTitle)))) .listEntry (objectID.longID ()).toList().toArray());
tl_jobPSet.setStatus (PersistentSetStatus.PROCESSED); tl_jobPSet.setStatus (PersistentSetStatus.PROCESSED);
} }
......
...@@ -13,8 +13,10 @@ ...@@ -13,8 +13,10 @@
<ATTRIB name="Name" type="String" dbcol="name" length="250" mandatory="true"/> <ATTRIB name="Name" type="String" dbcol="name" length="250" mandatory="true"/>
<ATTRIB name="Level" type="OccupationLevel" dbcol="level" attribHelper="EnumeratedAttributeHelper" mandatory="true"/> <ATTRIB name="Level" type="OccupationLevel" dbcol="level" attribHelper="EnumeratedAttributeHelper" mandatory="true"/>
<ATTRIB name="AssessmentType" type="AssessmentType" dbcol="assessment_type" attribHelper="EnumeratedAttributeHelper" /> <ATTRIB name="AssessmentType" type="AssessmentType" dbcol="assessment_type" attribHelper="EnumeratedAttributeHelper" />
<ATTRIB name="PartTimeAssessmentType" type="AssessmentType" dbcol="parttime_assessment_type" attribHelper="EnumeratedAttributeHelper" />
<SINGLEREFERENCE name="AssessmentLevel" type="Level" dbcol="assessment_level_id" /> <SINGLEREFERENCE name="AssessmentLevel" type="Level" dbcol="assessment_level_id" />
<SINGLEREFERENCE name="ExpressAssessmentLevel" type="Level" dbcol="express_assessment_level_id" />
<SINGLEREFERENCE name="ParentOccupation" type="Occupation" dbcol="parent_occupation_id" backreferenceName="ChildOccupations"/> <SINGLEREFERENCE name="ParentOccupation" type="Occupation" dbcol="parent_occupation_id" backreferenceName="ChildOccupations"/>
</TABLE> </TABLE>
......
...@@ -31,6 +31,7 @@ public class OccupationPersistenceMgr extends ObjectPersistenceMgr ...@@ -31,6 +31,7 @@ public class OccupationPersistenceMgr extends ObjectPersistenceMgr
private String dummyName; private String dummyName;
private OccupationLevel dummyLevel; private OccupationLevel dummyLevel;
private AssessmentType dummyAssessmentType; private AssessmentType dummyAssessmentType;
private AssessmentType dummyPartTimeAssessmentType;
// Static constants corresponding to attribute helpers // Static constants corresponding to attribute helpers
...@@ -38,6 +39,7 @@ public class OccupationPersistenceMgr extends ObjectPersistenceMgr ...@@ -38,6 +39,7 @@ public class OccupationPersistenceMgr extends ObjectPersistenceMgr
private static final DefaultAttributeHelper HELPER_Name = DefaultAttributeHelper.INSTANCE; private static final DefaultAttributeHelper HELPER_Name = DefaultAttributeHelper.INSTANCE;
private static final EnumeratedAttributeHelper HELPER_Level = new EnumeratedAttributeHelper (OccupationLevel.FACTORY_OccupationLevel); private static final EnumeratedAttributeHelper HELPER_Level = new EnumeratedAttributeHelper (OccupationLevel.FACTORY_OccupationLevel);
private static final EnumeratedAttributeHelper HELPER_AssessmentType = new EnumeratedAttributeHelper (AssessmentType.FACTORY_AssessmentType); private static final EnumeratedAttributeHelper HELPER_AssessmentType = new EnumeratedAttributeHelper (AssessmentType.FACTORY_AssessmentType);
private static final EnumeratedAttributeHelper HELPER_PartTimeAssessmentType = new EnumeratedAttributeHelper (AssessmentType.FACTORY_AssessmentType);
...@@ -48,10 +50,11 @@ public class OccupationPersistenceMgr extends ObjectPersistenceMgr ...@@ -48,10 +50,11 @@ public class OccupationPersistenceMgr extends ObjectPersistenceMgr
dummyName = (String)(HELPER_Name.initialise (dummyName)); dummyName = (String)(HELPER_Name.initialise (dummyName));
dummyLevel = (OccupationLevel)(HELPER_Level.initialise (dummyLevel)); dummyLevel = (OccupationLevel)(HELPER_Level.initialise (dummyLevel));
dummyAssessmentType = (AssessmentType)(HELPER_AssessmentType.initialise (dummyAssessmentType)); dummyAssessmentType = (AssessmentType)(HELPER_AssessmentType.initialise (dummyAssessmentType));
dummyPartTimeAssessmentType = (AssessmentType)(HELPER_PartTimeAssessmentType.initialise (dummyPartTimeAssessmentType));
} }
private String SELECT_COLUMNS = "{PREFIX}tl_occupation.object_id as id, {PREFIX}tl_occupation.object_LAST_UPDATED_DATE as LAST_UPDATED_DATE, {PREFIX}tl_occupation.object_CREATED_DATE as CREATED_DATE, {PREFIX}tl_occupation.code, {PREFIX}tl_occupation.name, {PREFIX}tl_occupation.level, {PREFIX}tl_occupation.assessment_type, {PREFIX}tl_occupation.assessment_level_id, {PREFIX}tl_occupation.parent_occupation_id, 1 AS commasafe "; private String SELECT_COLUMNS = "{PREFIX}tl_occupation.object_id as id, {PREFIX}tl_occupation.object_LAST_UPDATED_DATE as LAST_UPDATED_DATE, {PREFIX}tl_occupation.object_CREATED_DATE as CREATED_DATE, {PREFIX}tl_occupation.code, {PREFIX}tl_occupation.name, {PREFIX}tl_occupation.level, {PREFIX}tl_occupation.assessment_type, {PREFIX}tl_occupation.parttime_assessment_type, {PREFIX}tl_occupation.assessment_level_id, {PREFIX}tl_occupation.express_assessment_level_id, {PREFIX}tl_occupation.parent_occupation_id, 1 AS commasafe ";
private String SELECT_JOINS = ""; private String SELECT_JOINS = "";
public BaseBusinessClass fetchByID(ObjectID id, PersistentSetCollection allPSets, RDBMSPersistenceContext context, SQLManager sqlMgr) throws SQLException, StorageException public BaseBusinessClass fetchByID(ObjectID id, PersistentSetCollection allPSets, RDBMSPersistenceContext context, SQLManager sqlMgr) throws SQLException, StorageException
...@@ -106,7 +109,9 @@ public class OccupationPersistenceMgr extends ObjectPersistenceMgr ...@@ -106,7 +109,9 @@ public class OccupationPersistenceMgr extends ObjectPersistenceMgr
!tl_occupationPSet.containsAttrib(Occupation.FIELD_Name)|| !tl_occupationPSet.containsAttrib(Occupation.FIELD_Name)||
!tl_occupationPSet.containsAttrib(Occupation.FIELD_Level)|| !tl_occupationPSet.containsAttrib(Occupation.FIELD_Level)||
!tl_occupationPSet.containsAttrib(Occupation.FIELD_AssessmentType)|| !tl_occupationPSet.containsAttrib(Occupation.FIELD_AssessmentType)||
!tl_occupationPSet.containsAttrib(Occupation.FIELD_PartTimeAssessmentType)||
!tl_occupationPSet.containsAttrib(Occupation.SINGLEREFERENCE_AssessmentLevel)|| !tl_occupationPSet.containsAttrib(Occupation.SINGLEREFERENCE_AssessmentLevel)||
!tl_occupationPSet.containsAttrib(Occupation.SINGLEREFERENCE_ExpressAssessmentLevel)||
!tl_occupationPSet.containsAttrib(Occupation.SINGLEREFERENCE_ParentOccupation)) !tl_occupationPSet.containsAttrib(Occupation.SINGLEREFERENCE_ParentOccupation))
{ {
// We will need to retrieve it // We will need to retrieve it
...@@ -187,10 +192,10 @@ public class OccupationPersistenceMgr extends ObjectPersistenceMgr ...@@ -187,10 +192,10 @@ public class OccupationPersistenceMgr extends ObjectPersistenceMgr
{ {
int rowsUpdated = executeStatement (sqlMgr, int rowsUpdated = executeStatement (sqlMgr,
"UPDATE {PREFIX}tl_occupation " + "UPDATE {PREFIX}tl_occupation " +
"SET code = ?, name = ?, level = ?, assessment_type = ?, assessment_level_id = ? , parent_occupation_id = ? , object_LAST_UPDATED_DATE = " + sqlMgr.getPortabilityServices ().getTimestampExpression () + " " + "SET code = ?, name = ?, level = ?, assessment_type = ?, parttime_assessment_type = ?, assessment_level_id = ? , express_assessment_level_id = ? , parent_occupation_id = ? , object_LAST_UPDATED_DATE = " + sqlMgr.getPortabilityServices ().getTimestampExpression () + " " +
"WHERE tl_occupation.object_id = ? AND " + getConcurrencyCheck (sqlMgr, "object_LAST_UPDATED_DATE", obj.getObjectLastModified ()) + " ", "WHERE tl_occupation.object_id = ? AND " + getConcurrencyCheck (sqlMgr, "object_LAST_UPDATED_DATE", obj.getObjectLastModified ()) + " ",
CollectionUtils.listEntry (HELPER_Code.getForSQL(dummyCode, tl_occupationPSet.getAttrib (Occupation.FIELD_Code))).listEntry (HELPER_Name.getForSQL(dummyName, tl_occupationPSet.getAttrib (Occupation.FIELD_Name))).listEntry (HELPER_Level.getForSQL(dummyLevel, tl_occupationPSet.getAttrib (Occupation.FIELD_Level))).listEntry (HELPER_AssessmentType.getForSQL(dummyAssessmentType, tl_occupationPSet.getAttrib (Occupation.FIELD_AssessmentType))).listEntry (SQLManager.CheckNull((Long)(tl_occupationPSet.getAttrib (Occupation.SINGLEREFERENCE_AssessmentLevel)))).listEntry (SQLManager.CheckNull((Long)(tl_occupationPSet.getAttrib (Occupation.SINGLEREFERENCE_ParentOccupation)))).listEntry (objectID.longID ()).listEntry (obj.getObjectLastModified ()).toList().toArray()); CollectionUtils.listEntry (HELPER_Code.getForSQL(dummyCode, tl_occupationPSet.getAttrib (Occupation.FIELD_Code))).listEntry (HELPER_Name.getForSQL(dummyName, tl_occupationPSet.getAttrib (Occupation.FIELD_Name))).listEntry (HELPER_Level.getForSQL(dummyLevel, tl_occupationPSet.getAttrib (Occupation.FIELD_Level))).listEntry (HELPER_AssessmentType.getForSQL(dummyAssessmentType, tl_occupationPSet.getAttrib (Occupation.FIELD_AssessmentType))).listEntry (HELPER_PartTimeAssessmentType.getForSQL(dummyPartTimeAssessmentType, tl_occupationPSet.getAttrib (Occupation.FIELD_PartTimeAssessmentType))).listEntry (SQLManager.CheckNull((Long)(tl_occupationPSet.getAttrib (Occupation.SINGLEREFERENCE_AssessmentLevel)))).listEntry (SQLManager.CheckNull((Long)(tl_occupationPSet.getAttrib (Occupation.SINGLEREFERENCE_ExpressAssessmentLevel)))).listEntry (SQLManager.CheckNull((Long)(tl_occupationPSet.getAttrib (Occupation.SINGLEREFERENCE_ParentOccupation)))).listEntry (objectID.longID ()).listEntry (obj.getObjectLastModified ()).toList().toArray());
if (rowsUpdated != 1) if (rowsUpdated != 1)
{ {
...@@ -450,8 +455,10 @@ public class OccupationPersistenceMgr extends ObjectPersistenceMgr ...@@ -450,8 +455,10 @@ public class OccupationPersistenceMgr extends ObjectPersistenceMgr
tl_occupationPSet.setAttrib(Occupation.FIELD_Name, HELPER_Name.getFromRS(dummyName, r, "name")); tl_occupationPSet.setAttrib(Occupation.FIELD_Name, HELPER_Name.getFromRS(dummyName, r, "name"));
tl_occupationPSet.setAttrib(Occupation.FIELD_Level, HELPER_Level.getFromRS(dummyLevel, r, "level")); tl_occupationPSet.setAttrib(Occupation.FIELD_Level, HELPER_Level.getFromRS(dummyLevel, r, "level"));
tl_occupationPSet.setAttrib(Occupation.FIELD_AssessmentType, HELPER_AssessmentType.getFromRS(dummyAssessmentType, r, "assessment_type")); tl_occupationPSet.setAttrib(Occupation.FIELD_AssessmentType, HELPER_AssessmentType.getFromRS(dummyAssessmentType, r, "assessment_type"));
tl_occupationPSet.setAttrib(Occupation.FIELD_PartTimeAssessmentType, HELPER_PartTimeAssessmentType.getFromRS(dummyPartTimeAssessmentType, r, "parttime_assessment_type"));
tl_occupationPSet.setAttrib(Occupation.SINGLEREFERENCE_AssessmentLevel, r.getObject ("assessment_level_id")); tl_occupationPSet.setAttrib(Occupation.SINGLEREFERENCE_AssessmentLevel, r.getObject ("assessment_level_id"));
tl_occupationPSet.setAttrib(Occupation.SINGLEREFERENCE_ExpressAssessmentLevel, r.getObject ("express_assessment_level_id"));
tl_occupationPSet.setAttrib(Occupation.SINGLEREFERENCE_ParentOccupation, r.getObject ("parent_occupation_id")); tl_occupationPSet.setAttrib(Occupation.SINGLEREFERENCE_ParentOccupation, r.getObject ("parent_occupation_id"));
} }
...@@ -469,10 +476,10 @@ public class OccupationPersistenceMgr extends ObjectPersistenceMgr ...@@ -469,10 +476,10 @@ public class OccupationPersistenceMgr extends ObjectPersistenceMgr
{ {
executeStatement (sqlMgr, executeStatement (sqlMgr,
"INSERT INTO {PREFIX}tl_occupation " + "INSERT INTO {PREFIX}tl_occupation " +
" (code, name, level, assessment_type, assessment_level_id, parent_occupation_id, object_id, object_LAST_UPDATED_DATE, object_CREATED_DATE) " + " (code, name, level, assessment_type, parttime_assessment_type, assessment_level_id, express_assessment_level_id, parent_occupation_id, object_id, object_LAST_UPDATED_DATE, object_CREATED_DATE) " +
"VALUES " + "VALUES " +
" (?, ?, ?, ?, ?, ?, ?, " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ", " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ")", " (?, ?, ?, ?, ?, ?, ?, ?, ?, " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ", " + sqlMgr.getPortabilityServices ().getTimestampExpression () + ")",
CollectionUtils.listEntry (HELPER_Code.getForSQL(dummyCode, tl_occupationPSet.getAttrib (Occupation.FIELD_Code))).listEntry (HELPER_Name.getForSQL(dummyName, tl_occupationPSet.getAttrib (Occupation.FIELD_Name))).listEntry (HELPER_Level.getForSQL(dummyLevel, tl_occupationPSet.getAttrib (Occupation.FIELD_Level))).listEntry (HELPER_AssessmentType.getForSQL(dummyAssessmentType, tl_occupationPSet.getAttrib (Occupation.FIELD_AssessmentType))) .listEntry (SQLManager.CheckNull((Long)(tl_occupationPSet.getAttrib (Occupation.SINGLEREFERENCE_AssessmentLevel)))).listEntry (SQLManager.CheckNull((Long)(tl_occupationPSet.getAttrib (Occupation.SINGLEREFERENCE_ParentOccupation)))) .listEntry (objectID.longID ()).toList().toArray()); CollectionUtils.listEntry (HELPER_Code.getForSQL(dummyCode, tl_occupationPSet.getAttrib (Occupation.FIELD_Code))).listEntry (HELPER_Name.getForSQL(dummyName, tl_occupationPSet.getAttrib (Occupation.FIELD_Name))).listEntry (HELPER_Level.getForSQL(dummyLevel, tl_occupationPSet.getAttrib (Occupation.FIELD_Level))).listEntry (HELPER_AssessmentType.getForSQL(dummyAssessmentType, tl_occupationPSet.getAttrib (Occupation.FIELD_AssessmentType))).listEntry (HELPER_PartTimeAssessmentType.getForSQL(dummyPartTimeAssessmentType, tl_occupationPSet.getAttrib (Occupation.FIELD_PartTimeAssessmentType))) .listEntry (SQLManager.CheckNull((Long)(tl_occupationPSet.getAttrib (Occupation.SINGLEREFERENCE_AssessmentLevel)))).listEntry (SQLManager.CheckNull((Long)(tl_occupationPSet.getAttrib (Occupation.SINGLEREFERENCE_ExpressAssessmentLevel)))).listEntry (SQLManager.CheckNull((Long)(tl_occupationPSet.getAttrib (Occupation.SINGLEREFERENCE_ParentOccupation)))) .listEntry (objectID.longID ()).toList().toArray());
tl_occupationPSet.setStatus (PersistentSetStatus.PROCESSED); tl_occupationPSet.setStatus (PersistentSetStatus.PROCESSED);
} }
......
package performa.orm.types;
import java.util.*;
import oneit.utils.*;
/**
* This class was generated using constGen.bat.
* DO NOT MODIFY THIS CODE.
* Edit the associated .xml file, and regenerate this file
* constGen (directory) (file minus extension)
* e.g. constGen C:\...\sql FieldType
*/
public class AppView extends AbstractEnumerated
{
public static final EnumeratedFactory FACTORY_AppView = new AppViewFactory();
public static final AppView LIST = new AppView ("LIST", "LIST", "List", false);
public static final AppView GRID = new AppView ("GRID", "GRID", "Grid", false);
public static final AppView DETAILED_GRID = new AppView ("DETAILED_GRID", "DETAILED_GRID", "Detailed Grid", false);
private static final AppView[] allAppViews =
new AppView[] { LIST,GRID,DETAILED_GRID};
private static AppView[] getAllAppViews ()
{
return allAppViews;
}
private AppView (String name, String value, String description, boolean disabled)
{
super (name, value, description, disabled);
}
public static final Comparator COMPARE_BY_POSITION = new CompareEnumByPosition (allAppViews);
static
{
defineAdditionalData ();
}
public boolean isEqual (AppView other)
{
return this.name.equals (other.name);
}
public Enumeration getAllInstances ()
{
return AppView.getAll ();
}
private Object readResolve() throws java.io.ObjectStreamException
{
return AppView.forName (this.name);
}
public EnumeratedFactory getFactory ()
{
return FACTORY_AppView;
}
public static AppView forName (String name)
{
if (name == null) { return null; }
AppView[] all = getAllAppViews();
int enumIndex = AbstractEnumerated.getIndexForName (all, name);
return all[enumIndex];
}
public static AppView forValue (String value)
{
if (value == null) { return null; }
AppView[] all = getAllAppViews();
int enumIndex = AbstractEnumerated.getIndexForValue (getAllAppViews (), value);
return all[enumIndex];
}
public static java.util.Enumeration getAll ()
{
return AbstractEnumerated.getAll (getAllAppViews());
}
public static AppView[] getAppViewArray ()
{
return (AppView[])getAllAppViews().clone ();
}
public static void defineAdditionalData ()
{
}
static class AppViewFactory implements EnumeratedFactory
{
public AbstractEnumerated getForName (String name)
{
return AppView.forName (name);
}
public AbstractEnumerated getForValue (String name)
{
return AppView.forValue (name);
}
public Enumeration getAll ()
{
return AppView.getAll ();
}
}
public Map getAdditionalAttributes ()
{
Map attribs = new HashMap ();
return attribs;
}
}
<?xml version="1.0" encoding="UTF-8"?>
<ROOT>
<CONSTANT package="performa.orm.types" name="AppView">
<VALUE name="LIST" value="LIST" description="List"/>
<VALUE name="GRID" value="GRID" description="Grid"/>
<VALUE name="DETAILED_GRID" value="DETAILED_GRID" description="Detailed Grid"/>
</CONSTANT>
</ROOT>
\ No newline at end of file
...@@ -423,9 +423,29 @@ public class AnalysisEngine ...@@ -423,9 +423,29 @@ public class AnalysisEngine
TestAnalysis testAnalysis = candidate.getTestAnalysisFor(level); TestAnalysis testAnalysis = candidate.getTestAnalysisFor(level);
Map<FactorClass, Tuple.T3<Double, ColorCode, Double>> scoreMap = new HashMap(); Map<FactorClass, Tuple.T3<Double, ColorCode, Double>> scoreMap = new HashMap();
boolean isExpress = level.getAppliedToExpress();
if(testAnalysis != null && testAnalysis.getCandidateClassScoresCount() > 0) if(testAnalysis != null && testAnalysis.getCandidateClassScoresCount() > 0)
{ {
Tuple.T3<Double, ColorCode, Double> suitabilityScore = getSuitabilityScore(testAnalysis);
double totalPercentage = 0d;
int count = 0;
for(LevelClassCriteria levelClassCriteria : level.getLevelClassCriteriasSet())
{
FactorClass factorClass = levelClassCriteria.getFactorClass();
Filter<CandidateClassScore> candidateClassScoreFilter = CandidateClassScore.SearchByAll().andFactorClass(new EqualsFilter(factorClass));
CandidateClassScore candidateClassScore = testAnalysis.pipelineTestAnalysis().toCandidateClassScores(candidateClassScoreFilter).val();
if(isExpress && candidateClassScore != null)
{
totalPercentage += candidateClassScore.getWeightedPercentage();
count++;
}
}
double average = totalPercentage / count;
double ratio = (average / suitabilityScore.get2());
for(LevelClassCriteria levelClassCriteria : level.getLevelClassCriteriasSet()) for(LevelClassCriteria levelClassCriteria : level.getLevelClassCriteriasSet())
{ {
FactorClass factorClass = levelClassCriteria.getFactorClass(); FactorClass factorClass = levelClassCriteria.getFactorClass();
...@@ -437,16 +457,23 @@ public class AnalysisEngine ...@@ -437,16 +457,23 @@ public class AnalysisEngine
Double scorePercentage = 0d; Double scorePercentage = 0d;
ColorCode colorCode = null; ColorCode colorCode = null;
if(candidateClassScore != null && classNormalisation != null && NullArith.greaterThan(classNormalisation.getWghtStddevScore(), 0d)) if(isExpress && candidateClassScore != null)
{
score = (double)candidateClassScore.getWghtdClassScore();
scorePercentage = NullArith.round(NullArith.divide(candidateClassScore.getWeightedPercentage(), ratio), 2);
colorCode = candidateClassScore.getColorCode();
}
else if(candidateClassScore != null && classNormalisation != null && NullArith.greaterThan(classNormalisation.getWghtStddevScore(), 0d))
{ {
score = classNormalisation.getRoleFitScore(candidateClassScore.getWghtdClassScore()); score = classNormalisation.getRoleFitScore(candidateClassScore.getWghtdClassScore());
maxScore = classNormalisation.getRoleFitScore(candidateClassScore.getMaxWghtdClassScore()); maxScore = classNormalisation.getRoleFitScore(candidateClassScore.getMaxWghtdClassScore());
colorCode = candidateClassScore.getColorCode(); colorCode = candidateClassScore.getColorCode();
scorePercentage = NullArith.round(NullArith.divide(NullArith.multiply(score, 100), maxScore), 2); scorePercentage = NullArith.round(NullArith.divide(NullArith.multiply(score, 100), maxScore), 2);
} }
scoreMap.put(factorClass, new Tuple.T3(score, colorCode, scorePercentage)); scoreMap.put(factorClass, new Tuple.T3(score, colorCode, scorePercentage));
} }
scoreMap.put(null, getSuitabilityScore(testAnalysis)); scoreMap.put(null, suitabilityScore);
} }
LogMgr.log(JobApplication.LOG, LogLevel.PROCESSING1, "AnalysisEngine --> getRoleFitSuitability completed for candidate ", candidate, " Level ", level); LogMgr.log(JobApplication.LOG, LogLevel.PROCESSING1, "AnalysisEngine --> getRoleFitSuitability completed for candidate ", candidate, " Level ", level);
......
package performa.utils;
import oneit.utils.FormatterFactory;
import performa.orm.AssessmentCriteriaTemplate;
import performa.orm.Job;
import performa.orm.types.AssessmentType;
public class AssessmentTypeEnumFormatter implements FormatterFactory
{
private Job job;
private AssessmentCriteriaTemplate template;
public AssessmentTypeEnumFormatter(Job job)
{
this.job = job;
}
public AssessmentTypeEnumFormatter(AssessmentCriteriaTemplate template)
{
this.template = template;
}
@Override
public Object getFormatterFor(Object objectToFormat)
{
AssessmentType assessmentType = ((AssessmentType) objectToFormat);
AssessmentType suggestedType = job != null ? job.getSuggestedAssessmentType() : template.getSuggestedAssessmentType();
if(suggestedType == assessmentType)
{
return assessmentType.getDescription() + " (Suggested)";
}
return assessmentType.getDescription();
}
}
\ No newline at end of file
...@@ -275,12 +275,20 @@ public class PerformaEmailFetcher implements Runnable, InitialisationParticipant ...@@ -275,12 +275,20 @@ public class PerformaEmailFetcher implements Runnable, InitialisationParticipant
if(message.getAllRecipients() != null && message.getAllRecipients().length > 0) if(message.getAllRecipients() != null && message.getAllRecipients().length > 0)
{ {
tmpRecipient = ((InternetAddress) message.getAllRecipients()[0]).getAddress(); for(Address receipientAddress : message.getAllRecipients())
} {
tmpRecipient = ((InternetAddress)receipientAddress).getAddress();
if(StringUtils.subBlanks(tmpRecipient) != null) if(StringUtils.subBlanks(tmpRecipient) != null && tmpRecipient.contains("job"))
{ {
tmpJobId = getJobIdentifierFromEmail(tmpRecipient); tmpJobId = getJobIdentifierFromEmail(tmpRecipient);
if(tmpJobId != null && !tmpJobId.isEmpty() && StringUtils.isNumber(tmpJobId))
{
break;
}
}
}
} }
tmpEmailText = EmailFetcher.getText(message, new ArrayList<>()); tmpEmailText = EmailFetcher.getText(message, new ArrayList<>());
......
...@@ -4447,6 +4447,14 @@ no-applicant.inactive a:hover,no-applicant.inactive a:hover span{ ...@@ -4447,6 +4447,14 @@ no-applicant.inactive a:hover,no-applicant.inactive a:hover span{
text-transform: uppercase; text-transform: uppercase;
width: 20%; width: 20%;
} }
.appli-jcs3 {
color: #4a4a4a;
font-size: 11px;
letter-spacing: 1px;
padding: 26px 18px 5px;
text-transform: uppercase;
width: 40%;
}
.appli-overall{ .appli-overall{
color: #4a4a4a; color: #4a4a4a;
font-size: 11px; font-size: 11px;
...@@ -4678,12 +4686,24 @@ span.right-img { ...@@ -4678,12 +4686,24 @@ span.right-img {
margin-right: 8px; margin-right: 8px;
margin-top: 4px; margin-top: 4px;
} }
.detailed-grid-list a:before{
background-image: url('../images/details-icon-black.jpg');
width: 13px;
height: 13px;
content: '';
float: left;
margin-right: 8px;
margin-top: 4px;
}
.short-list.active a:before{ .short-list.active a:before{
background-image: url('../images/list-active.png'); background-image: url('../images/list-active.png');
} }
.grid-list.active a:before{ .grid-list.active a:before{
background-image: url('../images/grid-active.png'); background-image: url('../images/grid-active.png');
} }
.detailed-grid-list.active a:before{
background-image: url('../images/details-icon.jpg');
}
.appli-list-shorting.main-shortlist{ .appli-list-shorting.main-shortlist{
margin-top: 0; margin-top: 0;
} }
......
...@@ -27,6 +27,7 @@ ...@@ -27,6 +27,7 @@
<NODE name="dynamic_content_form::ADMIN_PORTAL" factory="Participant"> <NODE name="dynamic_content_form::ADMIN_PORTAL" factory="Participant">
<FORM name="*.changeAssessmentCriteria" factory="Participant" class="performa.form.ChangeAssessmentCriteriaFP"/> <FORM name="*.changeAssessmentCriteria" factory="Participant" class="performa.form.ChangeAssessmentCriteriaFP"/>
<FORM name="*.changeCultureCriteria" factory="Participant" class="performa.form.ChangeCultureCriteriaFP"/>
<FORM name="*.saveJob" factory="Participant" class="performa.form.SaveJobFP"/> <FORM name="*.saveJob" factory="Participant" class="performa.form.SaveJobFP"/>
<FORM name="*.saveRequirementTemplate" factory="Participant" class="performa.form.SaveRequirementsTemplateFP"/> <FORM name="*.saveRequirementTemplate" factory="Participant" class="performa.form.SaveRequirementsTemplateFP"/>
<FORM name="*.saveCultureTemplate" factory="Participant" class="performa.form.SaveCultureTemplateFP"/> <FORM name="*.saveCultureTemplate" factory="Participant" class="performa.form.SaveCultureTemplateFP"/>
...@@ -80,6 +81,9 @@ ...@@ -80,6 +81,9 @@
<INHERITS factory="Named" nodename="CoreORMAdminNoPriv"/> <INHERITS factory="Named" nodename="CoreORMAdminNoPriv"/>
</NODE> </NODE>
<NODE name="assessment_type_selector_jsp" factory="Participant">
<INHERITS factory="Named" nodename="CoreORMAdminNoPriv"/>
</NODE>
<NODE name="signin_jsp" factory="Participant"> <NODE name="signin_jsp" factory="Participant">
<INHERITS factory="Named" nodename="CoreORMAdminNoPriv"/> <INHERITS factory="Named" nodename="CoreORMAdminNoPriv"/>
......
...@@ -72,7 +72,18 @@ ...@@ -72,7 +72,18 @@
</span> </span>
</div> </div>
</div> </div>
<div class="form-group">
<div class="styled_checkboxes">
<div class="checkbox checkbox-primary">
<oneit:ormInput obj="<%= client %>" id="use-client-details" attributeName="UseClientDetails" type="checkbox"/>
<oneit:recalcClass htmlTag="span" classScript="client.showUseClientDetails() ? 'checked': 'unchecked'" client="<%= client %>">
<label for="use-client-details">
<oneit:ormlabel obj="<%= client %>" field="UseClientDetails" />
</label>
</oneit:recalcClass>
</div>
</div>
</div>
<div class="form-brack-line-sub"></div> <div class="form-brack-line-sub"></div>
<div class="form-group"> <div class="form-group">
......
...@@ -242,6 +242,10 @@ ...@@ -242,6 +242,10 @@
<label class="label-16 blue-label">Culture</label> <label class="label-16 blue-label">Culture</label>
</div> </div>
<div class="form-brack-line-sub"></div> <div class="form-brack-line-sub"></div>
<%
if(job.showCultureCriteriaSection())
{
%>
<div class="row"> <div class="row">
<div class="col-md-12 review-medium-title"> <div class="col-md-12 review-medium-title">
<oneit:label GUIName="Organisation Culture Statement" /> <oneit:label GUIName="Organisation Culture Statement" />
...@@ -279,6 +283,7 @@ ...@@ -279,6 +283,7 @@
<% <%
} }
} }
}
%> %>
</div> </div>
<% <%
......
...@@ -44,13 +44,31 @@ ...@@ -44,13 +44,31 @@
var scrolldiv = null ; var scrolldiv = null ;
$(document).ready(function() $(document).ready(function()
{ {
setupRecalc ($("form#editJobTemplate"), {'recalcOnError':true}); setupRecalc ($("form#editJob"), {'recalcOnError':true});
$("select[name$='JobTemplate']").change(function() $("select[name$='JobTemplate']").change(function()
{ {
$("button[name$='loadJobFromTemplate']").click(); $("button[name$='loadJobFromTemplate']").click();
}); });
$('input[type="text"][id$="ILOJobTitle_autocomplete"]').change(function()
{
$("#assessment_type").empty();
ajaxProcessAddJQ ("<%= request.getContextPath() %>/extensions/adminportal/inc/assessment_type_selector.jsp", "#assessment_type", {jobTitleID : $('input[type="hidden"][id$="JobTitle"]').val()}, function (theHTML_JQ) {
$("#assessment_type").append (theHTML_JQ);
});
});
$("select[name$='JobType']").change(function()
{
$("#assessment_type").empty();
ajaxProcessAddJQ ("<%= request.getContextPath() %>/extensions/adminportal/inc/assessment_type_selector.jsp", "#assessment_type", {jobTypeName : $(this).val()}, function (theHTML_JQ) {
$("#assessment_type").append (theHTML_JQ);
});
});
if ($("#select-occupation-id").val()) { if ($("#select-occupation-id").val()) {
lastclickedOccid = $("#select-occupation-id").val(); lastclickedOccid = $("#select-occupation-id").val();
}else { }else {
...@@ -164,6 +182,14 @@ ...@@ -164,6 +182,14 @@
$("#occupation span").addClass("form-control"); $("#occupation span").addClass("form-control");
$("#occupation span").css({"padding":"15px","display":"inline-table"}); $("#occupation span").css({"padding":"15px","display":"inline-table"});
ajaxProcessAddJQ ("<%= request.getContextPath() %>/extensions/adminportal/inc/assessment_type_selector.jsp", "#assessment_type", {}, function (theHTML_JQ) {
$("#assessment_type").append (theHTML_JQ);
});
addPostAjaxAddHTMLModifiers (function () {
$( "select[name$='AssessmentType']" ).select2({minimumResultsForSearch: Infinity});
}, true);
}); });
...@@ -277,7 +303,7 @@ ...@@ -277,7 +303,7 @@
<oneit:script src="/scripts/google_address.js"/> <oneit:script src="/scripts/google_address.js"/>
</oneit:script> </oneit:script>
<oneit:form name="editJobTemplate" method="post" enctype="multipart/form-data"> <oneit:form name="editJob" method="post" enctype="multipart/form-data">
<h1 class="page-title page-title-with-arrow edit-template"> <h1 class="page-title page-title-with-arrow edit-template">
<oneit:button cssClass="arrow-btn-blue" name="gotoPage" value=" " skin="link" <oneit:button cssClass="arrow-btn-blue" name="gotoPage" value=" " skin="link"
...@@ -401,7 +427,12 @@ ...@@ -401,7 +427,12 @@
<oneit:ormEnum obj="<%= template %>" attributeName="Industry" cssClass="form-control" displayType="autocomplete"/> <oneit:ormEnum obj="<%= template %>" attributeName="Industry" cssClass="form-control" displayType="autocomplete"/>
</div> </div>
</div> </div>
<div class="form-group row">
<div class="col-md-6">
<label><oneit:label GUIName="Assessment Length" /></label>
<div id="assessment_type"></div>
</div>
</div>
<div class="form-group row"> <div class="form-group row">
<div class="col-md-12"> <div class="col-md-12">
<div class="styled_checkboxes"> <div class="styled_checkboxes">
......
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
} }
%> %>
</span> by <oneit:toString value="<%= job.getCreatedBy() %>" mode="EscapeHTML" nullValue=""/> &nbsp;&nbsp;.&nbsp;&nbsp; </span> by <oneit:toString value="<%= job.getCreatedBy() %>" mode="EscapeHTML" nullValue=""/> &nbsp;&nbsp;.&nbsp;&nbsp;
<oneit:toString value="<%= job.getLevel() %>" mode="EscapeHTML" /> <oneit:toString value="<%= job.getOccupation() %>" mode="EscapeHTML" />
</div> </div>
</div> </div>
<div class="white-header"> <div class="white-header">
...@@ -105,7 +105,7 @@ ...@@ -105,7 +105,7 @@
<div class="view-appli-list"> <div class="view-appli-list">
<!--Requirements--> <!--Requirements-->
<% <%
if(job.getIncludeAssessmentCriteria() == Boolean.TRUE) if(job.showAssessmentCriteriaSection())
{ {
%> %>
<table width="100%" cellspacing="0" cellpadding="0" class="charts-table"> <table width="100%" cellspacing="0" cellpadding="0" class="charts-table">
...@@ -304,7 +304,7 @@ ...@@ -304,7 +304,7 @@
for(FactorClass factorClass : factorClassDtls.keySet()) for(FactorClass factorClass : factorClassDtls.keySet())
{ {
Map<FactorLevelLink, Map> factorDetails = factorClassDtls.get(factorClass); Map<FactorLevelLink, Map> factorDetails = factorClassDtls.get(factorClass);
Double rating = roleScoreMap.get(factorClass).get2(); Double rating = roleScoreMap.get(factorClass).get2() > 0 ? roleScoreMap.get(factorClass).get2() : 0d;
index++; index++;
...@@ -382,6 +382,7 @@ ...@@ -382,6 +382,7 @@
</div> </div>
</span> </span>
</div> </div>
<% <%
if(detailed) if(detailed)
{ {
...@@ -433,7 +434,7 @@ ...@@ -433,7 +434,7 @@
</tr> </tr>
</table> </table>
<% <%
if(detailed) if(detailed && job.showCultureCriteriaSection())
{ {
%> %>
<p style="page-break-before: always"></p> <p style="page-break-before: always"></p>
...@@ -442,6 +443,10 @@ ...@@ -442,6 +443,10 @@
%> %>
<!--Culture Fit Data--> <!--Culture Fit Data-->
<%
if(job.showCultureCriteriaSection())
{
%>
<table width="100%" cellspacing="0" cellpadding="0" class="charts-table culture"> <table width="100%" cellspacing="0" cellpadding="0" class="charts-table culture">
<tr> <tr>
<td class="chart-cell"> <td class="chart-cell">
...@@ -543,6 +548,9 @@ ...@@ -543,6 +548,9 @@
</td> </td>
</tr> </tr>
</table> </table>
<%
}
%>
</div> </div>
</div> </div>
</oneit:dynIncluded> </oneit:dynIncluded>
\ No newline at end of file
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
Job job = (Job) process.getAttribute("Job"); Job job = (Job) process.getAttribute("Job");
ApplicationStatus appStatus = (ApplicationStatus) getData(request, "WorkFlowStatus"); ApplicationStatus appStatus = (ApplicationStatus) getData(request, "WorkFlowStatus");
WorkFlow workFlow = (WorkFlow) getData(request, "WorkFlow"); WorkFlow workFlow = (WorkFlow) getData(request, "WorkFlow");
boolean showList = (boolean) getData(request, "ShowList"); AppView appView = (AppView) getData(request, "AppView");
String applicantsPage = WebUtils.getSamePageInRenderMode(request, WebUtils.VIEW_APPLICANTS); String applicantsPage = WebUtils.getSamePageInRenderMode(request, WebUtils.VIEW_APPLICANTS);
List<JobApplication> applications = (List<JobApplication>) getData(request, "applications"); List<JobApplication> applications = (List<JobApplication>) getData(request, "applications");
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
applicantPage="<%= false %>" applicantPage="<%= false %>"
applications="<%= applications %>" applications="<%= applications %>"
WorkFlow="<%= workFlow %>" WorkFlow="<%= workFlow %>"
ShowList="<%= showList %>"/> AppView="<%= appView %>"/>
<div class="int-timeline"> <div class="int-timeline">
<ul> <ul>
<li class="<%= "incomplete " + (noOfIncomplete > 0 ? "has-applicant" : "no-applicant") %> <%= appStatus == ApplicationStatus.DRAFT ? "active" : "inactive" %>"> <li class="<%= "incomplete " + (noOfIncomplete > 0 ? "has-applicant" : "no-applicant") %> <%= appStatus == ApplicationStatus.DRAFT ? "active" : "inactive" %>">
......
...@@ -112,6 +112,10 @@ ...@@ -112,6 +112,10 @@
<oneit:toString value="<%= jobApplication.getRoleFitPercentage() %>" mode="PercentageWholeNumber" /> <oneit:toString value="<%= jobApplication.getRoleFitPercentage() %>" mode="PercentageWholeNumber" />
</div> </div>
</div> </div>
<%
if(job.showCultureCriteriaSection())
{
%>
<div class="culture jcc"> <div class="culture jcc">
<div class="jcc-title"> <div class="jcc-title">
<img src="file:///<%= PDFUtils.FILE_BASE_PATH %>/images/culture-icon.png" /> culture fit <img src="file:///<%= PDFUtils.FILE_BASE_PATH %>/images/culture-icon.png" /> culture fit
...@@ -120,9 +124,10 @@ ...@@ -120,9 +124,10 @@
<oneit:toString value="<%= jobApplication.getCultureFitScore() %>" mode="PercentageWholeNumber" /> <oneit:toString value="<%= jobApplication.getCultureFitScore() %>" mode="PercentageWholeNumber" />
</div> </div>
</div> </div>
<% <%
if(job.getIncludeAssessmentCriteria()==Boolean.TRUE) }
if(job.showAssessmentCriteriaSection())
{ {
%> %>
<div class="criteria jcc <%=(missingReq ? "red-bg" : "green-bg")%> "> <div class="criteria jcc <%=(missingReq ? "red-bg" : "green-bg")%> ">
......
...@@ -69,7 +69,7 @@ ...@@ -69,7 +69,7 @@
%> %>
</span> by <oneit:toString value="<%= job.getCreatedBy() %>" mode="EscapeHTML" nullValue=""/> </span> by <oneit:toString value="<%= job.getCreatedBy() %>" mode="EscapeHTML" nullValue=""/>
&nbsp;&nbsp;.&nbsp;&nbsp; &nbsp;&nbsp;.&nbsp;&nbsp;
<oneit:toString value="<%= job.getLevel() %>" mode="EscapeHTML" /> <oneit:toString value="<%= job.getOccupation() %>" mode="EscapeHTML" />
</div> </div>
</div> </div>
...@@ -114,7 +114,10 @@ ...@@ -114,7 +114,10 @@
</span> </span>
role fit role fit
</div> </div>
<%
if(job.showCultureCriteriaSection())
{
%>
<div class="appli-jcs appli-l eq-second-height"> <div class="appli-jcs appli-l eq-second-height">
<span class="appli-view-bar"> <span class="appli-view-bar">
<div class="progress"> <div class="progress">
...@@ -127,7 +130,9 @@ ...@@ -127,7 +130,9 @@
culture fit culture fit
</div> </div>
<% <%
if(job.getIncludeAssessmentCriteria() == Boolean.TRUE) }
if(job.showAssessmentCriteriaSection())
{ {
long criteriaVal = jobApplication.getRequirementFitScore(); long criteriaVal = jobApplication.getRequirementFitScore();
String criteria = FormatUtils.stringify(criteriaVal, "PercentageWholeNumber", "0"); String criteria = FormatUtils.stringify(criteriaVal, "PercentageWholeNumber", "0");
......
...@@ -9,9 +9,10 @@ ...@@ -9,9 +9,10 @@
Job job = (Job) process.getAttribute("Job"); Job job = (Job) process.getAttribute("Job");
AppSortOption appSortOpt = (AppSortOption) getData(request, "SortOption"); AppSortOption appSortOpt = (AppSortOption) getData(request, "SortOption");
ApplicationStatus workflowStatus = (ApplicationStatus) getData(request, "WorkFlowStatus"); ApplicationStatus workflowStatus = (ApplicationStatus) getData(request, "WorkFlowStatus");
boolean isDraft = workflowStatus == ApplicationStatus.DRAFT;
ApplicationFilter appFilter = (ApplicationFilter) getData(request, "ApplicationFilter"); ApplicationFilter appFilter = (ApplicationFilter) getData(request, "ApplicationFilter");
Boolean showOrderBy = getData(request, "ShowOrderBy")!= null ? (Boolean) getData(request, "ShowOrderBy") : Boolean.FALSE; Boolean showOrderBy = getData(request, "ShowOrderBy")!= null ? (Boolean) getData(request, "ShowOrderBy") : Boolean.FALSE;
boolean showList = (boolean) getData(request,"ShowList"); AppView appView = (AppView) getData(request,"AppView");
SearchApplicant searchApplicant = (SearchApplicant) getData(request, "SearchApplicant"); SearchApplicant searchApplicant = (SearchApplicant) getData(request, "SearchApplicant");
String applicantsPage = WebUtils.getSamePageInRenderMode(request, WebUtils.VIEW_APPLICANTS) + "&JobID=" + job.getID() + "&WorkFlowStatus=" + workflowStatus.getName(); String applicantsPage = WebUtils.getSamePageInRenderMode(request, WebUtils.VIEW_APPLICANTS) + "&JobID=" + job.getID() + "&WorkFlowStatus=" + workflowStatus.getName();
List<WorkFlow> sortedWorkFlows = ObjstoreUtils.sort(job.getApplicantWFs(), List<WorkFlow> sortedWorkFlows = ObjstoreUtils.sort(job.getApplicantWFs(),
...@@ -42,7 +43,8 @@ ...@@ -42,7 +43,8 @@
}); });
function enableBulkEdit() { function enableBulkEdit() {
$("[name$='AppStatusWorkFlow']").prop("disabled",$('input[class=applicant]:checked').length===0); var disable = <%= isDraft %> || $('input[class=applicant]:checked').length === 0;
$("[name$='AppStatusWorkFlow']").prop("disabled", disable);
} }
$(function(){ $(function(){
...@@ -74,16 +76,22 @@ ...@@ -74,16 +76,22 @@
%> %>
<ul class=""> <ul class="">
<li class="lable-appli-shorting">View</li> <li class="lable-appli-shorting">View</li>
<li class="<%= (showList ? "active" : "" ) + " short-list"%>"> <li class="<%= (appView == AppView.LIST ? "active" : "" ) + " short-list"%>">
<oneit:button value="List" name="gotoPage" skin="link" <oneit:button value="List" name="gotoPage" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", applicantsPage) requestAttribs="<%= CollectionUtils.mapEntry("nextPage", applicantsPage)
.mapEntry("procParams", CollectionUtils.mapEntry("Job", job).mapEntry("ShowList", true).toMap()) .mapEntry("procParams", CollectionUtils.mapEntry("Job", job).mapEntry("AppView", AppView.LIST).toMap())
.toMap() %>"/> .toMap() %>"/>
</li> </li>
<li class="<%= (!showList ? "active" : "" ) + " grid-list"%>"> <li class="<%= (appView == AppView.GRID ? "active" : "" ) + " grid-list"%>">
<oneit:button value="Grid" name="gotoPage" skin="link" <oneit:button value="Grid" name="gotoPage" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", applicantsPage) requestAttribs="<%= CollectionUtils.mapEntry("nextPage", applicantsPage)
.mapEntry("procParams", CollectionUtils.mapEntry("Job", job).mapEntry("ShowList", false).toMap()) .mapEntry("procParams", CollectionUtils.mapEntry("Job", job).mapEntry("AppView", AppView.GRID).toMap())
.toMap() %>"/>
</li>
<li class="<%= (appView == AppView.DETAILED_GRID ? "active" : "" ) + " detailed-grid-list"%>">
<oneit:button value="Detailed Grid" name="gotoPage" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", applicantsPage)
.mapEntry("procParams", CollectionUtils.mapEntry("Job", job).mapEntry("AppView", AppView.DETAILED_GRID).toMap())
.toMap() %>"/> .toMap() %>"/>
</li> </li>
</ul> </ul>
......
<%@ page extends="oneit.servlets.process.AJAXProcessJSP" %>
<%@ include file="/inc/stdimports50.jsp" %><%-- This is in cougar --%>
<%@ include file="/extensions/performa/inc/stdimports.jsp" %>
<%@ include file="/inc/std_imports.jsp" %>
<%! protected String getName (ServletConfig config) { return "assessment_type_selector_jsp"; } %>
<%
ORMProcessState process = (ORMProcessState) ProcessDecorator.getDefaultProcess(request);
ObjectTransaction objTran = process.getTransaction ();
Job job = (Job) process.getAttribute("Job");
AssessmentCriteriaTemplate template = (AssessmentCriteriaTemplate) process.getAttribute("AssessmentCriteriaTemplate");
Long jobTitleID = request.getParameter("jobTitleID") != null ? Long.valueOf(request.getParameter("jobTitleID")) : null;
String jobTypeName = request.getParameter("jobTypeName");
AssessmentTypeEnumFormatter formatter = null;
if(jobTypeName != null)
{
JobType jobType = JobType.forName(jobTypeName);
if(job != null)
{
job.setJobType(jobType);
}
else
{
template.setJobType(jobType);
}
}
if(jobTitleID != null)
{
ILOJobTitle jobTitle = ILOJobTitle.getILOJobTitleByID(objTran, jobTitleID);
if(job != null)
{
job.setILOJobTitle(jobTitle);
}
else
{
template.setILOJobTitle(jobTitle);
}
}
if(job != null)
{
formatter = new AssessmentTypeEnumFormatter(job);
}
else
{
formatter = new AssessmentTypeEnumFormatter(template);
}
%>
<oneit:form name="editJob" method="POST">
<oneit:evalBody buffer="<%= getBuffer(request) %>">
<oneit:ormEnum obj="<%= job != null ? job : template %>" attributeName="AssessmentType" cssClass="form-control" enumFormatter="<%= formatter %>"/>
</oneit:evalBody>
</oneit:form>
...@@ -20,6 +20,8 @@ ...@@ -20,6 +20,8 @@
<script type="text/javascript"> <script type="text/javascript">
$(document).ready(function() $(document).ready(function()
{ {
$("[name$='WorkFlow']").prop("disabled",true);
$("[name$='WorkFlow']").change(function() $("[name$='WorkFlow']").change(function()
{ {
var id = $(this).closest('.appli-row').attr('id'); var id = $(this).closest('.appli-row').attr('id');
...@@ -139,14 +141,10 @@ ...@@ -139,14 +141,10 @@
</div> </div>
</div> </div>
<% <%
String widthClass = "appli-jcs2"; String widthClass = (job.showAssessmentCriteriaSection() && job.showCultureCriteriaSection()) ? "appli-jcs" :
(job.showAssessmentCriteriaSection() || job.showCultureCriteriaSection()) ? "appli-jcs2" : "appli-jcs3";
if(job.getIncludeAssessmentCriteria() == Boolean.TRUE) if(job.showAssessmentCriteriaSection())
{
widthClass = "appli-jcs";
}
if(job.getIncludeAssessmentCriteria() == Boolean.TRUE)
{ {
%> %>
<div class="<%= widthClass %> appli-l eq-second-height"> <div class="<%= widthClass %> appli-l eq-second-height">
...@@ -166,6 +164,9 @@ ...@@ -166,6 +164,9 @@
</div> </div>
<% <%
} }
if(job.showCultureCriteriaSection())
{
%> %>
<div class="<%= widthClass %> appli-l eq-second-height"> <div class="<%= widthClass %> appli-l eq-second-height">
<span class="appli-view-bar"> <span class="appli-view-bar">
...@@ -179,6 +180,9 @@ ...@@ -179,6 +180,9 @@
</span> </span>
culture fit culture fit
</div> </div>
<%
}
%>
<div class="<%= widthClass %> appli-l eq-second-height"> <div class="<%= widthClass %> appli-l eq-second-height">
<span class="appli-view-bar"> <span class="appli-view-bar">
<div class="progress"> <div class="progress">
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
<% <%
Job job = (Job) process.getAttribute("Job"); Job job = (Job) process.getAttribute("Job");
boolean applicantPage = (boolean) getData(request, "applicantPage"); boolean applicantPage = (boolean) getData(request, "applicantPage");
boolean showList = (boolean) getData(request, "ShowList"); AppView appView = (AppView) getData(request, "AppView");
WorkFlow workFlow = (WorkFlow) getData(request, "WorkFlow"); WorkFlow workFlow = (WorkFlow) getData(request, "WorkFlow");
String editJobPage = WebUtils.getSamePageInRenderMode(request, WebUtils.EDIT_JOB); String editJobPage = WebUtils.getSamePageInRenderMode(request, WebUtils.EDIT_JOB);
String sharePage = WebUtils.getSamePageInRenderMode(request, WebUtils.CREATED_JOB); String sharePage = WebUtils.getSamePageInRenderMode(request, WebUtils.CREATED_JOB);
...@@ -60,7 +60,7 @@ ...@@ -60,7 +60,7 @@
<div class="off-name"> <div class="off-name">
<oneit:toString value="<%= job.getAssessmentType() %>" mode="EscapeHTML" nullValue=""/>: <oneit:toString value="<%= job.getAssessmentType() %>" mode="EscapeHTML" nullValue=""/>:
<span class="ex-management"> <span class="ex-management">
<oneit:toString value="<%= job.getLevel() %>" mode="EscapeHTML" /> <oneit:toString value="<%= job.getOccupation() %>" mode="EscapeHTML" />
</span> </span>
</div> </div>
<div class="off-name"> <div class="off-name">
...@@ -124,11 +124,11 @@ ...@@ -124,11 +124,11 @@
EDIT JOB EDIT JOB
</oneit:button> </oneit:button>
<% <%
if(!applicantPage || !job.isExpressJob()) if(applicantPage)
{ {
%> %>
<oneit:button value=" " cssClass="job-edit-menu-item" name="downloadApplicantReport" skin="link" <oneit:button value=" " cssClass="job-edit-menu-item" name="downloadApplicantReport" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("ShowList", showList) requestAttribs="<%= CollectionUtils.mapEntry("AppView", appView)
.mapEntry("ApplicantPage", applicantPage) .mapEntry("ApplicantPage", applicantPage)
.mapEntry("Applications", applications) .mapEntry("Applications", applications)
.mapEntry("Detailed", false) .mapEntry("Detailed", false)
...@@ -136,14 +136,9 @@ ...@@ -136,14 +136,9 @@
.toMap() %>"> .toMap() %>">
EXPORT APPLICANT REPORT EXPORT APPLICANT REPORT
</oneit:button> </oneit:button>
<%
}
if(applicantPage)
{
%>
<oneit:button value=" " cssClass="job-edit-menu-item" name="downloadApplicantReport" skin="link" <oneit:button value=" " cssClass="job-edit-menu-item" name="downloadApplicantReport" skin="link"
requestAttribs="<%= CollectionUtils.mapEntry("ShowList", showList) requestAttribs="<%= CollectionUtils.mapEntry("AppView", appView)
.mapEntry("ApplicantPage", applicantPage) .mapEntry("ApplicantPage", applicantPage)
.mapEntry("Applications", applications) .mapEntry("Applications", applications)
.mapEntry("Detailed", true) .mapEntry("Detailed", true)
......
...@@ -104,6 +104,10 @@ ...@@ -104,6 +104,10 @@
</oneit:button> </oneit:button>
</span> </span>
</div> </div>
<%
if(job.showCultureCriteriaSection())
{
%>
<div class="culture jcc"> <div class="culture jcc">
<img src="images/culture-icon.svg"> culture fit <img src="images/culture-icon.svg"> culture fit
<span> <span>
...@@ -116,7 +120,9 @@ ...@@ -116,7 +120,9 @@
</span> </span>
</div> </div>
<% <%
if(job.getIncludeAssessmentCriteria()==Boolean.TRUE) }
if(job.showAssessmentCriteriaSection())
{ {
%> %>
<div class="criteria jcc <%=(missingReq ? "red-bg" : "green-bg")%> "> <div class="criteria jcc <%=(missingReq ? "red-bg" : "green-bg")%> ">
......
...@@ -75,12 +75,8 @@ ...@@ -75,12 +75,8 @@
</div> </div>
</div> </div>
<% <%
String widthClass = "appli-jcs2"; String widthClass = (job.showAssessmentCriteriaSection() && job.showCultureCriteriaSection()) ? "appli-jcs" :
(job.showAssessmentCriteriaSection() || job.showCultureCriteriaSection()) ? "appli-jcs2" : "appli-jcs3";
if(job.getIncludeAssessmentCriteria() == Boolean.TRUE)
{
widthClass = "appli-jcs";
}
%> %>
<div class="<%= widthClass %> appli-l eq-second-height"> <div class="<%= widthClass %> appli-l eq-second-height">
<span class="appli-view-bar"> <span class="appli-view-bar">
...@@ -94,6 +90,10 @@ ...@@ -94,6 +90,10 @@
</span> </span>
role fit role fit
</div> </div>
<%
if(job.showCultureCriteriaSection())
{
%>
<div class="<%= widthClass %> appli-l eq-second-height"> <div class="<%= widthClass %> appli-l eq-second-height">
<span class="appli-view-bar"> <span class="appli-view-bar">
<div class="progress"> <div class="progress">
...@@ -107,7 +107,9 @@ ...@@ -107,7 +107,9 @@
culture fit culture fit
</div> </div>
<% <%
if(job.getIncludeAssessmentCriteria() == Boolean.TRUE) }
if(job.showAssessmentCriteriaSection())
{ {
%> %>
<div class="<%= widthClass %> appli-l eq-second-height"> <div class="<%= widthClass %> appli-l eq-second-height">
......
...@@ -180,6 +180,9 @@ ...@@ -180,6 +180,9 @@
</div> </div>
<% <%
} }
if(job.showCultureCriteriaSection())
{
%> %>
<div class="culture jcc"> <div class="culture jcc">
<img src="images/culture-icon.svg"> culture fit <img src="images/culture-icon.svg"> culture fit
...@@ -212,7 +215,9 @@ ...@@ -212,7 +215,9 @@
%> %>
</div> </div>
<% <%
if(job.getIncludeAssessmentCriteria()==Boolean.TRUE) }
if(job.showAssessmentCriteriaSection())
{ {
%> %>
<div class="jcc"> <div class="jcc">
......
...@@ -153,10 +153,10 @@ ...@@ -153,10 +153,10 @@
List<Tuple.T2> cultureConcerns = jobApplication.getCultureAreaOfConcerns(); List<Tuple.T2> cultureConcerns = jobApplication.getCultureAreaOfConcerns();
%> %>
<div class="applicant-progress"> <div class="applicant-progress">
<div class="<%= job.getIncludeAssessmentCriteria()==Boolean.TRUE ? "col-sm-4" : "col-sm-6" %> col-xs-12 text-center thr-block role-fit" href="#1a" data-toggle="tab" id="progress1" onClick="tabToggle('#tab1', '.role-fit')"> <div class="<%= job.getNumberOfSections() == 3 ? "col-sm-4" : job.getNumberOfSections() == 2 ? "col-sm-6" : "col-sm-12" %> col-xs-12 text-center thr-block role-fit" href="#1a" data-toggle="tab" id="progress1" onClick="tabToggle('#tab1', '.role-fit')">
<label class="progress-label">role fit</label> <label class="progress-label">role fit</label>
<div class="<%= colorClass %> fixed-width"> <div class="<%= colorClass %> fixed-width">
<p style="display:none;"><oneit:toString value="<%= roleFitData!=null ? roleFitData.get2() : 0d %>" mode="TwoDPDouble" nullValue="0"/></p> <p style="display:none;"><oneit:toString value="<%= roleFitData!=null ? roleFitData.get2() > 0 ? roleFitData.get2() : 0d : 0d %>" mode="TwoDPDouble" nullValue="0"/></p>
</div> </div>
<div class="row four-label"> <div class="row four-label">
<% <%
...@@ -202,7 +202,11 @@ ...@@ -202,7 +202,11 @@
%> %>
</div> </div>
</div> </div>
<div class="<%= job.getIncludeAssessmentCriteria()==Boolean.TRUE ? "col-sm-4" : "col-sm-6" %> col-xs-12 text-center thr-block culture-fit" href="#2a" data-toggle="tab" id="progress2" onClick="tabToggle('#tab2', '.culture-fit')"> <%
if(job.showCultureCriteriaSection())
{
%>
<div class="<%= job.getNumberOfSections() == 3 ? "col-sm-4" : job.getNumberOfSections() == 2 ? "col-sm-6" : "col-sm-12" %> col-xs-12 text-center thr-block culture-fit" href="#2a" data-toggle="tab" id="progress2" onClick="tabToggle('#tab2', '.culture-fit')">
<label class="progress-label">culture fit</label> <label class="progress-label">culture fit</label>
<div class="<%= "percent-" + jobApplication.getCultureFitColor() + " fixed-width" %>"> <div class="<%= "percent-" + jobApplication.getCultureFitColor() + " fixed-width" %>">
<p style="display:none;"><oneit:toString value="<%= jobApplication.getCultureFitScore() %>" mode="TwoDPDouble" /></p> <p style="display:none;"><oneit:toString value="<%= jobApplication.getCultureFitScore() %>" mode="TwoDPDouble" /></p>
...@@ -253,10 +257,12 @@ ...@@ -253,10 +257,12 @@
</div> </div>
</div> </div>
<% <%
if(job.getIncludeAssessmentCriteria()==Boolean.TRUE) }
if(job.showAssessmentCriteriaSection())
{ {
%> %>
<div class="col-sm-4 col-xs-12 text-center thr-block requirement-fit" href="#3a" data-toggle="tab" id="progress3" onClick="tabToggle('#tab3','.requirement-fit')"> <div class="<%= job.getNumberOfSections() == 3 ? "col-sm-4" : job.getNumberOfSections() == 2 ? "col-sm-6" : "col-sm-12" %> col-xs-12 text-center thr-block requirement-fit" href="#3a" data-toggle="tab" id="progress3" onClick="tabToggle('#tab3','.requirement-fit')">
<label class="progress-label">requirements</label> <label class="progress-label">requirements</label>
<div class="<%= "percent-" + jobApplication.getRequirementFitColor() + " fixed-width progress-circle" %>"> <div class="<%= "percent-" + jobApplication.getRequirementFitColor() + " fixed-width progress-circle" %>">
<% if (missingReq) { %> <% if (missingReq) { %>
...@@ -330,7 +336,7 @@ ...@@ -330,7 +336,7 @@
} }
Map<FactorLevelLink, Map> factorDetails = factorClassDtls.get(factorClass); Map<FactorLevelLink, Map> factorDetails = factorClassDtls.get(factorClass);
Double rating = roleScoreMap.get(factorClass).get2(); Double rating = roleScoreMap.get(factorClass).get2() > 0 ? roleScoreMap.get(factorClass).get2() : 0d;
ColorCode colorCode = roleScoreMap.get(factorClass).get1(); ColorCode colorCode = roleScoreMap.get(factorClass).get1();
String cssClass = colorCode != null ? colorCode.getCSSClass() : ""; String cssClass = colorCode != null ? colorCode.getCSSClass() : "";
%> %>
...@@ -346,7 +352,6 @@ ...@@ -346,7 +352,6 @@
<span class="expand-box"> <span class="expand-box">
<span class="hasarrow"><img src="images/select-down-arrow.svg"></span> <span class="hasarrow"><img src="images/select-down-arrow.svg"></span>
</span> </span>
</div> </div>
<div class="core-values expand-hide-tag"> <div class="core-values expand-hide-tag">
......
...@@ -46,6 +46,24 @@ ...@@ -46,6 +46,24 @@
$("button[name$='loadJobFromTemplate']").click(); $("button[name$='loadJobFromTemplate']").click();
}); });
$('input[type="text"][id$="ILOJobTitle_autocomplete"]').change(function()
{
$("#assessment_type").empty();
ajaxProcessAddJQ ("<%= request.getContextPath() %>/extensions/adminportal/inc/assessment_type_selector.jsp", "#assessment_type", {jobTitleID : $('input[type="hidden"][id$="JobTitle"]').val()}, function (theHTML_JQ) {
$("#assessment_type").append (theHTML_JQ);
});
});
$("select[name$='JobType']").change(function()
{
$("#assessment_type").empty();
ajaxProcessAddJQ ("<%= request.getContextPath() %>/extensions/adminportal/inc/assessment_type_selector.jsp", "#assessment_type", {jobTypeName : $(this).val()}, function (theHTML_JQ) {
$("#assessment_type").append (theHTML_JQ);
});
});
if ($("#select-occupation-id").val()) { if ($("#select-occupation-id").val()) {
lastclickedOccid = $("#select-occupation-id").val(); lastclickedOccid = $("#select-occupation-id").val();
}else { }else {
...@@ -164,6 +182,14 @@ ...@@ -164,6 +182,14 @@
$("#occupation span").addClass("form-control"); $("#occupation span").addClass("form-control");
$("#occupation span").css({"padding":"15px","display":"inline-table"}); $("#occupation span").css({"padding":"15px","display":"inline-table"});
ajaxProcessAddJQ ("<%= request.getContextPath() %>/extensions/adminportal/inc/assessment_type_selector.jsp", "#assessment_type", {}, function (theHTML_JQ) {
$("#assessment_type").append (theHTML_JQ);
});
addPostAjaxAddHTMLModifiers (function () {
$( "select[name$='AssessmentType']" ).select2({minimumResultsForSearch: Infinity});
}, true);
}); });
...@@ -335,32 +361,6 @@ ...@@ -335,32 +361,6 @@
<label class="label-16">Job Location</label> <label class="label-16">Job Location</label>
</div> </div>
</div> </div>
<%--
<div class="form-group row">
<div class="col-md-6">
<label><oneit:ormlabel obj="<%= job %>" field="Country" /></label>
<oneit:ormEnum obj="<%= job %>" attributeName="Country" cssClass="form-control"/>
</div>
<div class="col-md-6">
<label><oneit:label GUIName="State or Province"/></label>
<oneit:ormEnum obj="<%= job %>" attributeName="State" cssClass="form-control"/>
</div>
</div>
<div class="form-group row">
<div class="col-md-4">
<label><oneit:label GUIName="City or Town"/></label>
<oneit:ormInput obj="<%= job %>" type="text" attributeName="City" cssClass="form-control" />
</div>
<div class="col-md-4">
<label><oneit:label GUIName="Zip / Post Code"/></label>
<oneit:ormInput obj="<%= job %>" type="text" attributeName="PostCode" cssClass="form-control" />
</div>
<div class="col-md-4">
<label><oneit:label GUIName="Expected Candidate Radius"/></label>
<oneit:ormEnum obj="<%= job %>" attributeName="ExpectedCandidateRadius" cssClass="form-control"/>
</div>
</div>
--%>
<div class="form-group row"> <div class="form-group row">
<div class="col-md-8"> <div class="col-md-8">
<label><oneit:label GUIName="Google Location"/></label> <label><oneit:label GUIName="Google Location"/></label>
...@@ -403,7 +403,6 @@ ...@@ -403,7 +403,6 @@
<oneit:recalc mode="EscapeHTML" script="job.displayOccupation()" job="<%= job %>"/> <oneit:recalc mode="EscapeHTML" script="job.displayOccupation()" job="<%= job %>"/>
</div> </div>
</div> </div>
<div class="form-group row"> <div class="form-group row">
<div class="col-md-6"> <div class="col-md-6">
<label><oneit:label GUIName="Job Type" /></label> <label><oneit:label GUIName="Job Type" /></label>
...@@ -415,6 +414,13 @@ ...@@ -415,6 +414,13 @@
</div> </div>
</div> </div>
<div class="form-group row"> <div class="form-group row">
<div class="col-md-6">
<label><oneit:label GUIName="Assessment Length" /></label>
<div id="assessment_type"></div>
</div>
</div>
<div class="form-group row">
<div class="col-md-12"> <div class="col-md-12">
<div class="styled_checkboxes"> <div class="styled_checkboxes">
<div class="checkbox checkbox-primary"> <div class="checkbox checkbox-primary">
......
...@@ -298,7 +298,10 @@ ...@@ -298,7 +298,10 @@
</div> </div>
<div class="form-brack-line-sub"></div> <div class="form-brack-line-sub"></div>
<%
if(job.showCultureCriteriaSection())
{
%>
<div class="row"> <div class="row">
<div class="col-md-12 review-medium-title"> <div class="col-md-12 review-medium-title">
<oneit:label GUIName="Organisation Culture Statement" /> <oneit:label GUIName="Organisation Culture Statement" />
...@@ -349,6 +352,9 @@ ...@@ -349,6 +352,9 @@
} }
%> %>
</div> </div>
<%
}
%>
<div class="text-center"> <div class="text-center">
<oneit:button value="Save as Draft and go to your jobs" name="saveJob" cssClass="btn btn-primary btn-gray largeBtn" <oneit:button value="Save as Draft and go to your jobs" name="saveJob" cssClass="btn btn-primary btn-gray largeBtn"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", jobsPage) requestAttribs="<%= CollectionUtils.mapEntry("nextPage", jobsPage)
......
...@@ -33,6 +33,7 @@ Client.ContactName = Contact First Name ...@@ -33,6 +33,7 @@ Client.ContactName = Contact First Name
Client.ContactSurname = Contact Last Name Client.ContactSurname = Contact Last Name
Client.ClientLogo = Client Logo Client.ClientLogo = Client Logo
Client.State = State or Province Client.State = State or Province
Client.UseClientDetails = Display client name and logo for job applicants (if No, then use Hiring Team details)
Company.TimeZone = Time zone Company.TimeZone = Time zone
Company.HasClientSupport = We help clients with hiring Company.HasClientSupport = We help clients with hiring
......
<?xml version="1.0" encoding="UTF-8"?>
<!-- @AutoRun -->
<OBJECTS name="" xmlns:oneit="http://www.1iT.com.au">
<NODE name="Script" factory="Vector">
<NODE name="DDL" factory="Participant" class="oneit.sql.transfer.RedefineTableOperation">
<tableName factory="String">tl_job</tableName>
<column name="include_culture" type="Boolean" nullable="true"/>
</NODE>
</NODE>
</OBJECTS>
\ No newline at end of file
update tl_job set include_culture = 'Y' where include_culture is null;
<?xml version="1.0" encoding="UTF-8"?>
<!-- @AutoRun -->
<OBJECTS name="" xmlns:oneit="http://www.1iT.com.au">
<NODE name="Script" factory="Vector">
<NODE name="DDL" factory="Participant" class="oneit.sql.transfer.RedefineTableOperation">
<tableName factory="String">tl_client</tableName>
<column name="use_client_details" type="Boolean" nullable="true"/>
</NODE>
</NODE>
</OBJECTS>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!-- @AutoRun -->
<OBJECTS name="" xmlns:oneit="http://www.1iT.com.au">
<NODE name="Script" factory="Vector">
<NODE name="DDL" factory="Participant" class="oneit.sql.transfer.RedefineTableOperation">
<tableName factory="String">tl_occupation</tableName>
<column name="parttime_assessment_type" type="String" nullable="true" length="200"/>
<column name="express_assessment_level_id" type="Long" length="11" nullable="true"/>
</NODE>
</NODE>
</OBJECTS>
\ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
update tl_narrative set graphic_notes = 'Tends to focus on non-personal issues, displaying a limited concern for others'' welfare.' where narrative_code = 'W10ALV4';
update tl_narrative set graphic_notes = 'Tends to focus on professional issues, displaying a limited concern for others'' welfare.' where narrative_code = '10ALV4';
update tl_narrative set graphic_notes = 'Highly considerate of others'' welfare, but may find it difficult to remain objective when making strategic decisions.' where narrative_code = '10AVHV4';
update tl_narrative set graphic_notes = 'Highly considerate of others'' welfare, but may find it difficult to remain objective when making strategic decisions.' where narrative_code = 'M10AVHV4';
update tl_narrative set graphic_notes = 'Tends to focus on non-personal issues, displaying a limited concern for others'' welfare.' where narrative_code = 'M10ALV4';
update tl_narrative set graphic_notes = 'Tends to focus on non-personal issues, displaying a limited concern for others'' welfare.' where narrative_code = 'VW10ALV4';
\ No newline at end of file
...@@ -113,30 +113,25 @@ ...@@ -113,30 +113,25 @@
applicantList = job.filterEssentialRequirements(appFilter == ApplicationFilter.HAS_REQ , applicantList); applicantList = job.filterEssentialRequirements(appFilter == ApplicationFilter.HAS_REQ , applicantList);
} }
if((process.getAttribute("ShowList") != null && process.getAttribute("ShowList") == Boolean.TRUE) || CollectionUtils.equals(workflowStatus,ApplicationStatus.DRAFT)) if(process.getAttribute("AppView") != null)
{ {
session.setAttribute("ShowList",true); session.setAttribute("AppView", (AppView) process.getAttribute("AppView"));
} }
else if(process.getAttribute("ShowList") != null && process.getAttribute("ShowList") == Boolean.FALSE)
{
session.setAttribute("ShowList",false);
}
boolean showList = session.getAttribute("ShowList") != null ? (boolean) session.getAttribute("ShowList") : true;
AppView appView = (session.getAttribute("AppView") != null && !CollectionUtils.equals(workflowStatus,ApplicationStatus.DRAFT))? (AppView) session.getAttribute("AppView") : AppView.LIST;
List<JobApplication> sortedApplications = Utils.getApplicationsSorted(applicantList, appSortOpt); List<JobApplication> sortedApplications = Utils.getApplicationsSorted(applicantList, appSortOpt);
process.setAttribute("AppSortOption", appSortOpt); process.setAttribute("AppSortOption", appSortOpt);
process.setAttribute("ApplicationFilter", appFilter); process.setAttribute("ApplicationFilter", appFilter);
process.setAttribute("WorkFlowStatus", workflowStatus); process.setAttribute("WorkFlowStatus", workflowStatus);
process.setAttribute("ShowList", showList); process.setAttribute("AppView", appView);
%> %>
<oneit:form name="viewApplicants" method="post" enctype="multipart/form-data"> <oneit:form name="viewApplicants" method="post" enctype="multipart/form-data">
<div class="dashboard-content-area"> <div class="dashboard-content-area">
<oneit:dynInclude page="/extensions/adminportal/inc/applicant_view_tabs.jsp" <oneit:dynInclude page="/extensions/adminportal/inc/applicant_view_tabs.jsp"
ShowList="<%= showList %>" AppView="<%= appView %>"
applications="<%= sortedApplications %>" applications="<%= sortedApplications %>"
WorkFlowStatus="<%= workflowStatus %>" WorkFlowStatus="<%= workflowStatus %>"
WorkFlow="<%= workflow %>" WorkFlow="<%= workflow %>"
...@@ -145,7 +140,7 @@ ...@@ -145,7 +140,7 @@
<div class="second-part view-app-area"> <div class="second-part view-app-area">
<oneit:dynInclude page="/extensions/adminportal/inc/application_sorting_bar.jsp" <oneit:dynInclude page="/extensions/adminportal/inc/application_sorting_bar.jsp"
ShowList="<%= showList %>" AppView="<%= appView %>"
SearchApplicant="<%= searchApplicant %>" SearchApplicant="<%= searchApplicant %>"
ShowOrderBy="<%= sortedApplications.size() > 1 %>" ShowOrderBy="<%= sortedApplications.size() > 1 %>"
ApplicationFilter="<%= appFilter %>" ApplicationFilter="<%= appFilter %>"
...@@ -154,7 +149,7 @@ ...@@ -154,7 +149,7 @@
data="<%= CollectionUtils.EMPTY_MAP%>"/> data="<%= CollectionUtils.EMPTY_MAP%>"/>
<% <%
if(showList) if(appView == AppView.LIST)
{ {
if(workflowStatus == ApplicationStatus.DRAFT) if(workflowStatus == ApplicationStatus.DRAFT)
{ {
...@@ -178,12 +173,10 @@ ...@@ -178,12 +173,10 @@
<% <%
} }
} }
else else if(appView == AppView.GRID)
{
if(workflowStatus == ApplicationStatus.SHORTLISTED)
{ {
%> %>
<oneit:dynInclude page="/extensions/adminportal/inc/view_applicants_shortlist_grid.jsp" <oneit:dynInclude page="/extensions/adminportal/inc/view_applicants_grid.jsp"
applications="<%= sortedApplications %>" applications="<%= sortedApplications %>"
currentPage="<%= currentPage %>" currentPage="<%= currentPage %>"
data="<%= CollectionUtils.EMPTY_MAP%>"/> data="<%= CollectionUtils.EMPTY_MAP%>"/>
...@@ -192,14 +185,13 @@ ...@@ -192,14 +185,13 @@
else else
{ {
%> %>
<oneit:dynInclude page="/extensions/adminportal/inc/view_applicants_grid.jsp" <oneit:dynInclude page="/extensions/adminportal/inc/view_applicants_shortlist_grid.jsp"
applications="<%= sortedApplications %>" applications="<%= sortedApplications %>"
currentPage="<%= currentPage %>" currentPage="<%= currentPage %>"
data="<%= CollectionUtils.EMPTY_MAP%>"/> data="<%= CollectionUtils.EMPTY_MAP%>"/>
<% <%
} }
}
%> %>
</div> </div>
</div> </div>
......
...@@ -20,6 +20,10 @@ ...@@ -20,6 +20,10 @@
$(document).ready(function(){ $(document).ready(function(){
recalcFunction = setupRecalc ($("form#editJob"), {'recalcOnError':true}); recalcFunction = setupRecalc ($("form#editJob"), {'recalcOnError':true});
$(".switch input[name$='IncludeCulture'] ").change(function() {
$("button[name$='changeCultureCriteria']").click();
});
}); });
</script> </script>
...@@ -44,11 +48,29 @@ ...@@ -44,11 +48,29 @@
.toMap() %>" /> .toMap() %>" />
<div class="form-page-area nopadding"> <div class="form-page-area nopadding">
<div class="create-job"> <div class="create-job">
<div class="form-page-section" style="padding-bottom: 0px">
<div class="form-group">
<label>Include Culture for this Job?</label>
<span class="pull-right">
<label class="switch">
<oneit:recalcClass htmlTag="span" classScript="job.showCultureCriteriaSection() ? 'checkbox checked': 'checkbox unchecked'" job="<%= job %>">
<oneit:ormInput obj="<%= job %>" attributeName="IncludeCulture" type="checkbox"/>
</oneit:recalcClass>
<div class="slider round"></div>
</label>
<oneit:button value=" " name="changeCultureCriteria" cssClass="hide"
requestAttribs="<%= CollectionUtils.mapEntry ("Job", job)
.mapEntry (UpdateMappedObjFP.FAIL_VALIDATION_ERRORS, Boolean.FALSE)
.toMap() %>" />
</span>
</div>
</div>
<oneit:recalcClass htmlTag="div" classScript="job.showCultureCriteriaSection() ? 'show': 'hide'" job="<%= job %>">
<% <%
if(templates.length > 0) if(templates.length > 0)
{ {
%> %>
<div class="form-page-section" style="padding-bottom: 0px"> <div class="form-page-section" style="padding-bottom: 0px; padding-top: 0px;">
<div class="form-group"> <div class="form-group">
<label class="label-16 work-title">Culture</label> <label class="label-16 work-title">Culture</label>
</div> </div>
...@@ -71,7 +93,10 @@ ...@@ -71,7 +93,10 @@
</div> </div>
<oneit:dynInclude page="/extensions/adminportal/inc/culture_details.jsp" Job="<%= job %>" data="<%= CollectionUtils.EMPTY_MAP%>"/> <oneit:dynInclude page="/extensions/adminportal/inc/culture_details.jsp" Job="<%= job %>" data="<%= CollectionUtils.EMPTY_MAP%>"/>
</oneit:recalcClass>
<div class="form-page-section"> <div class="form-page-section">
<oneit:recalcClass htmlTag="div" classScript="job.showCultureCriteriaSection() ? 'show': 'hide'" job="<%= job %>">
<div class="form-group"> <div class="form-group">
<div class="styled_checkboxes"> <div class="styled_checkboxes">
<div class="checkbox checkbox-primary"> <div class="checkbox checkbox-primary">
...@@ -97,6 +122,7 @@ ...@@ -97,6 +122,7 @@
</span> </span>
</div> </div>
</oneit:recalcClass> </oneit:recalcClass>
</oneit:recalcClass>
<div class="text-center"> <div class="text-center">
<oneit:button value="Save as draft" name="saveJob" cssClass="btn btn-primary top-margin-25 largeBtn greyBtn" <oneit:button value="Save as draft" name="saveJob" cssClass="btn btn-primary top-margin-25 largeBtn greyBtn"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", jobPage) requestAttribs="<%= CollectionUtils.mapEntry("nextPage", jobPage)
......
...@@ -78,7 +78,7 @@ ...@@ -78,7 +78,7 @@
if(job.getIncludeAssessmentCriteria()) if(job.getIncludeAssessmentCriteria())
{ {
%> %>
<div class="col-sm-4 col-xs-12 app-block eq-height"> <div class="<%= (job.getNumberOfSections() == 3 ? "col-sm-4" : (job.getNumberOfSections() == 2 ? "col-sm-6" : "col-sm-12" )) + " col-xs-12 app-block eq-height"%>">
<div class="block-icon <%= isSelectionComplete ? "app-outline-complete" : "" %>"> <div class="block-icon <%= isSelectionComplete ? "app-outline-complete" : "" %>">
<div class="<%= isSelectionComplete ? "app-outline-complete-icon" : "app-outline-selection-icon" %>"></div> <div class="<%= isSelectionComplete ? "app-outline-complete-icon" : "app-outline-selection-icon" %>"></div>
</div> </div>
...@@ -105,8 +105,11 @@ ...@@ -105,8 +105,11 @@
</div> </div>
<% <%
} }
if(job.showCultureCriteriaSection())
{
%> %>
<div class="<%= (job.getIncludeAssessmentCriteria() ? "col-sm-4 app-second-block " : " col-sm-6 app-block " ) + " col-xs-12 app-block eq-height "%> "> <div class="<%= (job.getNumberOfSections() == 3 ? "col-sm-4 app-second-block " : (job.getNumberOfSections() == 2 ? " col-sm-6 app-block " : " col-sm-12 app-block " )) + " col-xs-12 app-block eq-height "%> ">
<div class="block-icon <%= isCultureComplete ? "app-outline-complete" : "" %>"> <div class="block-icon <%= isCultureComplete ? "app-outline-complete" : "" %>">
<div class="<%= isCultureComplete ? "app-outline-complete-icon" : "app-outline-culture-icon" %>"></div> <div class="<%= isCultureComplete ? "app-outline-complete-icon" : "app-outline-culture-icon" %>"></div>
</div> </div>
...@@ -133,7 +136,10 @@ ...@@ -133,7 +136,10 @@
There are no right or wrong answers, so please choose what best fits you (not what you think might be right for a particular job). There are no right or wrong answers, so please choose what best fits you (not what you think might be right for a particular job).
</p> </p>
</div> </div>
<div class="<%= (job.getIncludeAssessmentCriteria() ? "col-sm-4 " : "col-sm-6 app-thired-block " ) + "col-xs-12 app-block eq-height last-border"%>"> <%
}
%>
<div class="<%= (job.getNumberOfSections() == 3 ? "col-sm-4 " : (job.getNumberOfSections() == 2 ? " col-sm-6 app-thired-block " :"col-sm-12 " )) + "col-xs-12 app-block eq-height last-border"%>">
<div class="block-icon <%= isAssesmentComplete ? "app-outline-complete" : "" %>"> <div class="block-icon <%= isAssesmentComplete ? "app-outline-complete" : "" %>">
<div class="<%= isAssesmentComplete ? "app-outline-complete-icon" : "app-outline-assesmet-icon" %>"></div> <div class="<%= isAssesmentComplete ? "app-outline-complete-icon" : "app-outline-assesmet-icon" %>"></div>
</div> </div>
......
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
String secondPage = WebUtils.getSamePageInRenderMode(request, "WorkplaceCulture"); String secondPage = WebUtils.getSamePageInRenderMode(request, "WorkplaceCulture");
String thirdPage = WebUtils.getSamePageInRenderMode(request, "JobMatchAssessment"); String thirdPage = WebUtils.getSamePageInRenderMode(request, "JobMatchAssessment");
boolean includeAssessment = jobApplication.isIncludeAssessmentCriteria(); boolean includeAssessment = jobApplication.isIncludeAssessmentCriteria();
boolean includeCulture = jobApplication.isIncludeCultureCriteria();
// Boolean alreadyCompletedCulture = (Boolean) process.getAttribute("AlreadyCompletedCulture"); // Boolean alreadyCompletedCulture = (Boolean) process.getAttribute("AlreadyCompletedCulture");
// Boolean alreadyCompletedRole = (Boolean) process.getAttribute("AlreadyCompletedRole"); // Boolean alreadyCompletedRole = (Boolean) process.getAttribute("AlreadyCompletedRole");
...@@ -41,6 +42,9 @@ ...@@ -41,6 +42,9 @@
</li> </li>
<% <%
} }
if(includeCulture)
{
%> %>
<li class="<%= pageNumber == "2" ? "active" : isCultureComplete ? "complate" : ""%>"> <li class="<%= pageNumber == "2" ? "active" : isCultureComplete ? "complate" : ""%>">
<oneit:button value=" " name="validateApplication" skin="link" disabled="<%= isCultureComplete ? "true" : "false"%>" <oneit:button value=" " name="validateApplication" skin="link" disabled="<%= isCultureComplete ? "true" : "false"%>"
...@@ -53,6 +57,9 @@ ...@@ -53,6 +57,9 @@
<div class="mobile-hide">Workplace Preferences</div> <div class="mobile-hide">Workplace Preferences</div>
</oneit:button> </oneit:button>
</li> </li>
<%
}
%>
<li class="<%= pageNumber == "3" ? "active" : isAssesmentComplete ? "complate" : ""%>"> <li class="<%= pageNumber == "3" ? "active" : isAssesmentComplete ? "complate" : ""%>">
<oneit:button value=" " name="validateApplication" skin="link" disabled="<%= isAssesmentComplete ? "true" : "false"%>" <oneit:button value=" " name="validateApplication" skin="link" disabled="<%= isAssesmentComplete ? "true" : "false"%>"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", thirdPage) requestAttribs="<%= CollectionUtils.mapEntry("nextPage", thirdPage)
...@@ -60,11 +67,11 @@ ...@@ -60,11 +67,11 @@
.mapEntry("procParams", CollectionUtils.mapEntry("JobApplication", jobApplication).toMap()) .mapEntry("procParams", CollectionUtils.mapEntry("JobApplication", jobApplication).toMap())
.mapEntry("fromRequirements", fromRequirements) .mapEntry("fromRequirements", fromRequirements)
.toMap() %>"> .toMap() %>">
<span><%= isAssesmentComplete ? "<img src=\"images/right-mark.png\" />" : (includeAssessment ? "3" : "2")%></span> <span><%= isAssesmentComplete ? "<img src=\"images/right-mark.png\" />" : (includeAssessment && includeCulture ? "3" : ( (includeAssessment || includeCulture) ? "2" : "1"))%></span>
<div class="mobile-hide">Your Work Style</div> <div class="mobile-hide">Your Work Style</div>
</oneit:button> </oneit:button>
</li> </li>
<li><a href="#"><span><%= includeAssessment ? "4" : "3" %></span><div class="mobile-hide">Submit Application</div></a></li> <li><a href="#"><span><%= (includeAssessment && includeCulture ? "4" : ( (includeAssessment || includeCulture) ? "3" : "2")) %></span><div class="mobile-hide">Submit Application</div></a></li>
</ul> </ul>
</div> </div>
</oneit:dynIncluded> </oneit:dynIncluded>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment