- * Version 1.3.0 (Topcoder - Add effort hours field)
+ * Version 1.3.0 (Topcoder - Add effort days field)
*
*
Add {@link #EFFORT_HOURS_ESTIMATE}
*
@@ -95,21 +95,21 @@ public class ProjectPropertyType implements Serializable {
/**
* Represents key for Allow Stock Art property.
- *
+ *
* @since 1.2.1
*/
public static final String ALLOW_STOCK_ART_KEY = "Allow Stock Art";
-
+
/**
* Represents key for Viewable Submissions Flag property.
- *
+ *
* @since 1.2.1
*/
public static final String VIEWABLE_SUBMISSIONS_FLAG_KEY_STRING = "Viewable Submissions Flag";
-
+
/**
* Represents key for Viewable Submitters property.
- *
+ *
* @since 1.2.1
*/
public static final String VIEWABLE_SUBMITTERS_KEY = "Viewable Submitters";
@@ -184,7 +184,7 @@ public class ProjectPropertyType implements Serializable {
*/
public static final String BILLING_PROJECT_PROJECT_PROPERTY_KEY = "Billing Project";
-
+
/**
*
* Represents the "confidentiality type" project property key
@@ -217,7 +217,7 @@ public class ProjectPropertyType implements Serializable {
*
*/
public static final String PUBLIC_PROJECT_PROPERTY_KEY = "Public";
-
+
/**
* Represents the "Rated" project property key
*
@@ -289,7 +289,7 @@ public class ProjectPropertyType implements Serializable {
*/
public static final String ROOT_CATALOG_ID_PROJECT_PROPERTY_KEY = "Root Catalog ID";
-
+
/**
* Represents the "Approval Required" project property key
*
@@ -338,13 +338,13 @@ public class ProjectPropertyType implements Serializable {
*
*/
public static final String COPILOT_COST_PROJECT_PROPERTY_KEY = "Copilot Cost";
-
+
/**
* Represents the "Contest Fee Percentage" project property key
*
*/
public static final String CONTEST_FEE_PERCENTAGE_PROJECT_PROPERTY_KEY = "Contest Fee Percentage";
-
+
/**
* Represents the "Review Feedback Flag" project property key
*
@@ -372,7 +372,7 @@ public class ProjectPropertyType implements Serializable {
*/
public static final String ALLOW_MULTIPLE_SUBMISSIONS_PROPERTY_KEY = "Allow multiple submissions";
-
+
/**
* Represents the "CloudSpokes CMC Task" project property key.
*
@@ -437,9 +437,9 @@ public class ProjectPropertyType implements Serializable {
public static final String REVIEW_TYPE_KEY = "Review Type";
/*
- * Represent "Effort Hours Estimate" key
+ * Represent "Effort Days Estimate" key
*/
- public static final String EFFORT_HOURS_ESTIMATE = "Effort Hours Estimate";
+ public static final String EFFORT_HOURS_ESTIMATE = "Effort Days Estimate";
/**
* Represents the id of this instance. Only values greater than zero is
diff --git a/services/client_project_entities_dao/src/java/main/com/topcoder/clients/dao/ejb3/ProjectDAOBean.java b/services/client_project_entities_dao/src/java/main/com/topcoder/clients/dao/ejb3/ProjectDAOBean.java
index 2b605b317..66798ea4f 100644
--- a/services/client_project_entities_dao/src/java/main/com/topcoder/clients/dao/ejb3/ProjectDAOBean.java
+++ b/services/client_project_entities_dao/src/java/main/com/topcoder/clients/dao/ejb3/ProjectDAOBean.java
@@ -82,8 +82,8 @@
*
*
*
- * Version 1.3 (TC - Add effort hours field)
- * - Add enable effort hours field for client
+ * Version 1.3 (TC - Add effort days field)
+ * - Add enable effort days field for client
*
*
*
@@ -154,8 +154,8 @@ public class ProjectDAOBean extends GenericEJB3DAO implements
+ " where p.start_date <= current and current <= p.end_date "
+ " and c.client_id = cp.client_id and (p.is_deleted = 0 or p.is_deleted is null) "
+ " and p.project_id = cp.project_id ";
-
-
+
+
/**
* The query string used to select project by project id.
*
@@ -499,8 +499,8 @@ private List convertQueryToListProjects(Query query) {
}
if (os[16] != null) {
- int enableEffortHours = Integer.parseInt(os[16].toString());
- client.setEnableEffortHours(enableEffortHours == 1 ? true : false);
+ int enableEffortDays = Integer.parseInt(os[16].toString());
+ client.setEnableEffortDays(enableEffortDays == 1 ? true : false);
}
result.add(c);
@@ -957,13 +957,13 @@ public List getProjectsByIds(List projectIds) throws DAOException
}
EntityManager entityManager = Helper.checkEntityManager(getEntityManager());
-
+
StringBuilder projectIdsClause = new StringBuilder();
-
+
projectIdsClause.append(" (");
boolean first = true;
-
+
for(int i = 0; i < projectIds.size(); ++i) {
if(projectIds.get(i) != null) {
@@ -978,11 +978,11 @@ public List getProjectsByIds(List projectIds) throws DAOException
}
projectIdsClause.append(")");
-
-
+
+
try {
String queryString = SELECT_PROJECTS_BY_IDS + projectIdsClause.toString();
-
+
System.out.println(queryString);
Query query = entityManager.createNativeQuery(queryString);
diff --git a/services/client_project_entities_dao/src/java/main/com/topcoder/clients/model/Client.java b/services/client_project_entities_dao/src/java/main/com/topcoder/clients/model/Client.java
index 5b3b666b5..dd885bf5e 100644
--- a/services/client_project_entities_dao/src/java/main/com/topcoder/clients/model/Client.java
+++ b/services/client_project_entities_dao/src/java/main/com/topcoder/clients/model/Client.java
@@ -95,7 +95,7 @@ public class Client extends AuditableEntity {
/**
*
- * This field represents the 'enableEffortHours' property of the Client.
+ * This field represents the 'enableEffortDays' property of the Client.
*
*
* It is default to the default value of this data type when it is not
@@ -103,7 +103,7 @@ public class Client extends AuditableEntity {
*
*
* Through corresponding getter/setter methods. It is retrieved from
- * Client.enableEffortHours [Client.isEffortHoursEnabled()] and in table
+ * Client.enableEffortDays [Client.isEffortDaysEnabled()] and in table
* client.enable_effort_hours.
*
*
@@ -112,7 +112,7 @@ public class Client extends AuditableEntity {
*
Version 1.2 Changes (Module Assembly - Contest Fee Based on % of Member Cost User Part):
* - Modified method getBillingProjectContestFees. Added support for fee percentage.
- * - If the billing is configured by percentage of member cost, the contest fee will be calculated
+ * - If the billing is configured by percentage of member cost, the contest fee will be calculated
* - as a percentage of the member cost.
*
*
@@ -57,7 +57,7 @@
* - Updates method {@link #getBillingAccountsForProject()} to return all the billing accounts of the project without
* checking the billing account permission of the users.
*
- *
+ *
*
* Version 1.5 (Release Assembly - TopCoder Cockpit - Launch Contest Update for Marathon Match)
* - New method {@link #getActiveProblemSet()} to return active problems as JSON.
@@ -94,9 +94,9 @@
*
*
*
- * Version 1.10 (Topcoder - Add effort hours field)
+ * Version 1.10 (Topcoder - Add effort days field)
*
- *
Add enable effort hours
+ *
Add enable effort days
*
*
*
@@ -166,7 +166,7 @@ public String getDirectProjectCopilots() throws Exception {
Map value = new HashMap();
for (ContestCopilotDTO copilot : copilots) {
value.put(String.valueOf(copilot.getUserId()), copilot.getHandle());
-
+
// current user is one of the copilots
if(currentUserId == copilot.getUserId()) {
isCurrentUser = true;
@@ -281,12 +281,12 @@ public String getDirectProjectContests() {
return SUCCESS;
}
-
+
/**
*
@@ -348,7 +348,7 @@ public String getContestConfigs() throws Exception {
*/
public String getBillingProjectContestFees() throws Exception {
Map result = new HashMap();
-
+
// set the percentage info
ProjectContestFeePercentage percentage = getContestFeePercentageService().getByProjectId(billingProjectId);
if (percentage != null && percentage.isActive()) {
@@ -383,26 +383,26 @@ public String getBillingAccountsForProject() {
List billingAccountsByProject = getProjectServiceFacade().getBillingAccountsByProject(getDirectProjectId());
List
*
*
- *
+ *
* Version 2.2 BUGR-8788 (TC Cockpit - New Client Billing Config Type) change notes:
*
*
change on {@link #billingAccountsForProject} to suuport CCA related for billing account
@@ -256,20 +256,20 @@
*
Added regEndDate property
*
*
- *
+ *
*
* Version 3.3 - Topcoder - Remove JIRA Issues Related Functionality In Direct App v1.0
* - remove JIRA related functionality
*
- *
+ *
*
* Version 3.4 - Quick72Hrs!! Topcoder - Remove VM Management Feature In Direct App version 1.0
* - remove VM related functionality
*
*
*
- * Version 3.5 - Topcoder - Add effort hours field
- * - add enable effort hours
+ * Version 3.5 - Topcoder - Add effort days field
+ * - add enable effort days
*
*
* @author fabrizyo, FireIce, isv, morehappiness, GreatKevin, minhu, Veve, Ghost_141, GreatKevin, Veve, GreatKevin, TCSCODER
@@ -557,9 +557,9 @@ protected void executeAction() throws Exception {
// set billing accounts for the direct project
List billingProjects =
getProjectServiceFacade().getBillingAccountsByProject(softwareCompetition.getProjectHeader().getTcDirectProjectId());
-
+
long[] billingAccountIds = new long[billingProjects.size()];
-
+
for (int i = 0; i < billingAccountIds.length; i++){
billingAccountIds[i] = billingProjects.get(i).getId();
}
@@ -569,12 +569,12 @@ protected void executeAction() throws Exception {
billingAccount.put("id", String.valueOf(billingProjects.get(i).getId()));
billingAccount.put("name", billingProjects.get(i).getName());
billingAccount.put("cca", String.valueOf(requireCCAs[i]));
- // Add enableEffortHours for each billing account
+ // Add enableEffortDays for each billing account
Client client = billingProjects.get(i).getClient();
- if (client != null && client.isEffortHoursEnabled() != null) {
- billingAccount.put("enableEffortHours", client.isEffortHoursEnabled());
+ if (client != null && client.isEffortDaysEnabled() != null) {
+ billingAccount.put("enableEffortDays", client.isEffortDaysEnabled());
} else {
- billingAccount.put("enableEffortHours", false);
+ billingAccount.put("enableEffortDays", false);
}
billingAccountsForProject.add(billingAccount);
}
@@ -634,7 +634,7 @@ public String specReviewScheduled() {
}
return SUCCESS;
}
-
+
/**
*
* Gets the project id.
diff --git a/src/web/WEB-INF/includes/contest/editTab.jsp b/src/web/WEB-INF/includes/contest/editTab.jsp
index a1f087607..c35f10364 100644
--- a/src/web/WEB-INF/includes/contest/editTab.jsp
+++ b/src/web/WEB-INF/includes/contest/editTab.jsp
@@ -163,8 +163,8 @@
-
Effort Hours Estimate
-
:
+
Effort Days Estimate
+
:
@@ -342,8 +342,8 @@
- Estimated Effort:
-
+ Estimated Effort:
+
Created By
diff --git a/src/web/WEB-INF/includes/contest/editTabSoftware.jsp b/src/web/WEB-INF/includes/contest/editTabSoftware.jsp
index b74640bc5..db31521e1 100644
--- a/src/web/WEB-INF/includes/contest/editTabSoftware.jsp
+++ b/src/web/WEB-INF/includes/contest/editTabSoftware.jsp
@@ -88,8 +88,8 @@
- Version 3.3 (Topcoder - Support Points Prize Type For Challenges):
- - Add "Points" section.
-
- - Version 3.4 (Topcoder - Add effort hours field):
- - - Add enable effort hours
+ - Version 3.4 (Topcoder - Add effort days field):
+ - - Add enable effort days
--%>
<%@ include file="/WEB-INF/includes/taglibs.jsp" %>
@@ -185,8 +185,8 @@
-
Effort Hours Estimate
-
:
+
Effort Days Estimate
+
:
@@ -369,8 +369,8 @@
- Estimated Effort:
-
+ Estimated Effort:
+
diff --git a/src/web/WEB-INF/includes/launch/contestSelection.jsp b/src/web/WEB-INF/includes/launch/contestSelection.jsp
index 34ba7d279..b7d19f738 100644
--- a/src/web/WEB-INF/includes/launch/contestSelection.jsp
+++ b/src/web/WEB-INF/includes/launch/contestSelection.jsp
@@ -54,8 +54,8 @@
- Version 2.7 (TOPCODER - SUPPORT TYPEAHEAD FOR TASK ASSIGNEES IN DIRECT APP):
- - Move task assign member to use magicSuggest
-
- - Version 2.8 (Topcoder - Add effort hours field):
- - - Add enable effort hours
+ - Version 2.8 (Topcoder - Add effort days field):
+ - - Add enable effort days
--%>
<%@ include file="/WEB-INF/includes/taglibs.jsp" %>
@@ -238,7 +238,7 @@
-
+
diff --git a/src/web/WEB-INF/includes/launch/orderReview.jsp b/src/web/WEB-INF/includes/launch/orderReview.jsp
index ec387ad0f..ce95d301c 100644
--- a/src/web/WEB-INF/includes/launch/orderReview.jsp
+++ b/src/web/WEB-INF/includes/launch/orderReview.jsp
@@ -15,7 +15,7 @@
- Version 1.3 - Topcoder - Support Points Prize Type For Challenges
- - Add "Challenge Points" section.
-
- - Version 1.4 (Topcoder - Add effort hours field):
+ - Version 1.4 (Topcoder - Add effort days field):
- - Add enable effort hours
--%>
<%@ include file="/WEB-INF/includes/taglibs.jsp" %>
@@ -59,8 +59,8 @@
-
Effort Hours Estimate :
-
+
Effort Days Estimate :
+
diff --git a/src/web/WEB-INF/includes/launch/orderReviewAlgorithm.jsp b/src/web/WEB-INF/includes/launch/orderReviewAlgorithm.jsp
index 1882df800..b4ceba03b 100644
--- a/src/web/WEB-INF/includes/launch/orderReviewAlgorithm.jsp
+++ b/src/web/WEB-INF/includes/launch/orderReviewAlgorithm.jsp
@@ -8,7 +8,7 @@
- Version 1.1 - Topcoder - Support Points Prize Type For Challenges
- - Add "Challenge Points" section.
-
- - Version 1.2 (Topcoder - Add effort hours field):
+ - Version 1.2 (Topcoder - Add effort days field):
- - Add enable effort hours
--%>
<%@ include file="/WEB-INF/includes/taglibs.jsp" %>
@@ -48,8 +48,8 @@
-
Effort Hours Estimate :
-
+
Effort Days Estimate :
+
diff --git a/src/web/WEB-INF/includes/launch/orderReviewSoftware.jsp b/src/web/WEB-INF/includes/launch/orderReviewSoftware.jsp
index 2109256e5..f51b21e25 100644
--- a/src/web/WEB-INF/includes/launch/orderReviewSoftware.jsp
+++ b/src/web/WEB-INF/includes/launch/orderReviewSoftware.jsp
@@ -20,7 +20,7 @@
- Version 1.5 - Topcoder - Support Points Prize Type For Challenges
- - Add "Challenge Points" section.
-
- - Version 1.6 (Topcoder - Add effort hours field):
+ - Version 1.6 (Topcoder - Add effort days field):
- - Add enable effort hours
--%>
<%@ include file="/WEB-INF/includes/taglibs.jsp" %>
@@ -60,7 +60,7 @@
-
Effort Hours Estimate :
+
Effort Days Estimate :
diff --git a/src/web/WEB-INF/includes/launch/review.jsp b/src/web/WEB-INF/includes/launch/review.jsp
index 966ea1bc8..3a55ef526 100644
--- a/src/web/WEB-INF/includes/launch/review.jsp
+++ b/src/web/WEB-INF/includes/launch/review.jsp
@@ -17,7 +17,7 @@
- Version 1.4 (Topcoder - Support Points Prize Type For Challenges):
- - Add "Challenge Points" section.
-
- - Version 1.5 (Topcoder - Add effort hours field):
+ - Version 1.5 (Topcoder - Add effort days field):
- - Add enable effort hours
--%>
<%@ include file="/WEB-INF/includes/taglibs.jsp" %>
@@ -68,8 +68,8 @@
diff --git a/src/web/css/direct/launchcontest.css b/src/web/css/direct/launchcontest.css
index 658d60188..d424b2908 100644
--- a/src/web/css/direct/launchcontest.css
+++ b/src/web/css/direct/launchcontest.css
@@ -1790,7 +1790,7 @@ a.draft:hover span.right, a.preview:hover span.right {
}
.overviewData th {
- width: 110px;
+ width: 130px;
font-weight: 400;
text-align: right;
}
diff --git a/src/web/scripts/launch/contestDetailSoftware.js b/src/web/scripts/launch/contestDetailSoftware.js
index 5224391ce..172b57fbb 100644
--- a/src/web/scripts/launch/contestDetailSoftware.js
+++ b/src/web/scripts/launch/contestDetailSoftware.js
@@ -188,8 +188,8 @@ $(document).ready(function(){
$.each(billingAccounts, function(key, value) {
var _cca = value["cca"] == "true" ? true : false;
- var _enableEffortHours = value["enableEffortHours"] == "true" ? true : false;
- $("#billingProjects").append($('').val(value["id"]).html(value["name"]).data("cca", _cca).data("enableEffortHours", _enableEffortHours));
+ var _enableEffortDays = value["enableEffortDays"] == "true" ? true : false;
+ $("#billingProjects").append($('').val(value["id"]).html(value["name"]).data("cca", _cca).data("enableEffortDays", _enableEffortDays));
});
/* Optgroup 2 columns fix */
if($('.selectDesing optgroup, .selectDesign .newListOptionTitle').length > 0){
@@ -568,7 +568,7 @@ $(document).ready(function(){
$("#chkboxCCA").removeAttr('disabled');
}
- if($(this).find(":selected").data("enableEffortHours")) {
+ if($(this).find(":selected").data("enableEffortDays")) {
$('.effortEstimateRow').show();
} else {
$('.effortEstimateRow').hide();
@@ -609,9 +609,9 @@ $(document).ready(function(){
}
});
$('.effortEstimateRow .helpme').hover(function() {
- showPopup(this, 'effortHourToolTip');
+ showPopup(this, 'effortDaysToolTip');
}, function() {
- $('#effortHourToolTip').hide();
+ $('#effortDaysToolTip').hide();
});
});
@@ -890,7 +890,7 @@ function initContest(contestJson) {
mainWidget.softwareCompetition.regEndDate = parseDate(contestJson.regEndDate);
$('#contestTypeNameText').text(getProjectCategoryById(mainWidget.softwareCompetition.projectHeader.projectCategory.id).name);
- mainWidget.softwareCompetition.projectHeader.properties['Effort Days Estimate'] = contestJson.properties['Effort Hours Estimate'];
+ mainWidget.softwareCompetition.projectHeader.properties['Effort Days Estimate'] = contestJson.properties['Effort Days Estimate'];
// copilots
var copilots = contestJson.copilots; // get copilots data from result
@@ -1438,9 +1438,9 @@ function populateTypeSection() {
}
var effortDaysEstimate = parseFloat(p['Effort Days Estimate']);
- if (!isNaN(effortDaysEstimate) && effortDayssEstimate > 0 ) {
+ if (!isNaN(effortDaysEstimate) && effortDaysEstimate > 0 ) {
$('#rEffortDaysEstimate').text(parseFloat(effortDaysEstimate));
- $('input[name=effortDayssEstimate]').val(effortDaysEstimate);
+ $('input[name=effortDaysEstimate]').val(effortDaysEstimate);
$('.effortEstimateRow').show();
} else {
$('#rEffortDaysEstimate').text('');
@@ -1585,7 +1585,7 @@ function validateFieldsTypeSection() {
}
// validate effort hours estimate
- validateEffortHoursEstimate(errors);
+ validateEffortDaysEstimate(errors);
// do NOT need milestone for First2Finish and CODE contest
if (categoryId != SOFTWARE_CATEGORY_ID_F2F
@@ -1673,12 +1673,12 @@ function showTypeSectionEdit() {
$.each(billingAccounts,function(k, v) {
var _cca = v["cca"] == "true" ? true : false;
- var _enableEffortHours = v["enableEffortHours"] == "true" ? true : false;
+ var _enableEffortDays = v["enableEffortDays"] == "true" ? true : false;
if (v["id"] == mainWidget.softwareCompetition.projectHeader.getBillingProject()) {
if (_cca) {
$("#chkboxCCA").attr('disabled','true');
}
- if(_enableEffortHours) {
+ if(_enableEffortDays) {
$(".effortEstimateRow").show();
}
}
@@ -2853,7 +2853,7 @@ function showPrizeSectionEdit() {
$("#chkboxCCA").removeAttr('disabled');
}
- if($(this).find(":selected").data("enableEffortHours")) {
+ if($(this).find(":selected").data("enableEffortDays")) {
$('.effortEstimateRow').show();
} else {
$('.effortEstimateRow').hide();
@@ -3633,8 +3633,8 @@ function handleProjectDropDownChange() {
$.each(billingAccounts, function(key, value) {
var _cca = value["cca"] == "true" ? true : false;
- var _enableEffortHours = value["enableEffortHours"] == "true" ? true : false;
- $("#billingProjects").append($('').val(value["id"]).text(value["name"]).data("cca", _cca).data("enableEffortHours", _enableEffortHours));
+ var _enableEffortDays = value["enableEffortDays"] == "true" ? true : false;
+ $("#billingProjects").append($('').val(value["id"]).text(value["name"]).data("cca", _cca).data("enableEffortDays", _enableEffortDays));
});
$("#chkboxCCA").removeAttr('checked');
$("#chkboxCCA").removeAttr('disabled');
@@ -3658,7 +3658,7 @@ function handleProjectDropDownChange() {
$("#chkboxCCA").removeAttr('disabled');
}
- if($(this).find(":selected").data("enableEffortHours")) {
+ if($(this).find(":selected").data("enableEffortDays")) {
$('.effortEstimateRow').show();
} else {
$('.effortEstimateRow').hide();
diff --git a/src/web/scripts/launch/pages/orderReview.js b/src/web/scripts/launch/pages/orderReview.js
index cdfa77446..5b64846b5 100644
--- a/src/web/scripts/launch/pages/orderReview.js
+++ b/src/web/scripts/launch/pages/orderReview.js
@@ -144,7 +144,7 @@ function updateOrderReviewSoftware() {
$('#sworContestName').html(mainWidget.softwareCompetition.assetDTO.name);
$('#sworProjectName').html($("#projects option[value="+ mainWidget.softwareCompetition.projectHeader.tcDirectProjectId +"]").text());
$('#sworBillingAccount').html($("#billingProjects option[value="+ billingProjectId +"]").text());
- $('#sworEffortHoursEstimate').html(mainWidget.softwareCompetition.projectHeader.properties['Effort Hours Estimate']);
+ $('#sworEffortDaysEstimate').html(mainWidget.softwareCompetition.projectHeader.properties['Effort Days Estimate']);
$('#sworStartDate').html(formatDateForReview(mainWidget.softwareCompetition.assetDTO.directjsProductionDate));
//points
@@ -296,7 +296,7 @@ function updateOrderReviewStudio() {
$('#orBillingAccount').html((billingProjectId == -1)?"(not selected)":$("#billingProjects option[value="+ billingProjectId +"]").text());
- $('#orEffortHoursEstimate').html(mainWidget.softwareCompetition.projectHeader.properties['Effort Hours Estimate']);
+ $('#orEffortDaysEstimate').html(mainWidget.softwareCompetition.projectHeader.properties['Effort Days Estimate']);
$('#orStartDate').html(formatDateForReview(mainWidget.softwareCompetition.assetDTO.directjsProductionDate));
diff --git a/src/web/scripts/launch/pages/review.js b/src/web/scripts/launch/pages/review.js
index b4c8b12b7..68c9a6d6e 100644
--- a/src/web/scripts/launch/pages/review.js
+++ b/src/web/scripts/launch/pages/review.js
@@ -43,7 +43,7 @@ function updateReviewAlgorithm() {
var billingProjectId = mainWidget.softwareCompetition.projectHeader.getBillingProject();
$('#ralBillingAccount').html((billingProjectId == -1)?" ":$("#billingProjects option[value="+ billingProjectId +"]").text());
- $('#ralEffortHoursEstimate').html(mainWidget.softwareCompetition.projectHeader.properties['Effort Days Estimate']);
+ $('#ralEffortDaysEstimate').html(mainWidget.softwareCompetition.projectHeader.properties['Effort Days Estimate']);
$('#ralStartDate').html(formatDateForReview(mainWidget.softwareCompetition.assetDTO.directjsProductionDate));
// to do
@@ -90,7 +90,7 @@ function updateReviewSoftware() {
var billingProjectId = mainWidget.softwareCompetition.projectHeader.getBillingProject();
$('#rswBillingAccount').html((billingProjectId == -1)?" ":$("#billingProjects option[value="+ billingProjectId +"]").text());
- $('#rswEffortDaysEstimate').html(mainWidget.softwareCompetition.projectHeader.properties['Effort Hours Estimate']);
+ $('#rswEffortDaysEstimate').html(mainWidget.softwareCompetition.projectHeader.properties['Effort Days Estimate']);
$('#rswStartDate').html(formatDateForReview(mainWidget.softwareCompetition.assetDTO.directjsProductionDate));
diff --git a/src/web/scripts/launch/pages/selection.js b/src/web/scripts/launch/pages/selection.js
index 4b3d39d39..36e2b4a3e 100644
--- a/src/web/scripts/launch/pages/selection.js
+++ b/src/web/scripts/launch/pages/selection.js
@@ -120,7 +120,7 @@ function initCompetitionSelectionCommonData() {
var tcProjectId = parseInt($('select#projects').val());
var billingProjectId = parseInt($('select#billingProjects').val());
var isMultiRound = hasMultiRound(categoryId) && ('multi' == $('#roundTypes').val());
- var effortHoursEstimate = $('input#effortHoursEstimate').val();
+ var effortDaysEstimate = $('input#effortDaysEstimate').val();
// apply category id data
var projectCategory = getProjectCategoryById(categoryId);
@@ -143,7 +143,7 @@ function initCompetitionSelectionCommonData() {
mainWidget.softwareCompetition.projectHeader.setProjectName(contestName);
mainWidget.softwareCompetition.multiRound = isMultiRound;
- mainWidget.softwareCompetition.projectHeader.properties['Effort Days Estimate'] = effortHoursEstimate;
+ mainWidget.softwareCompetition.projectHeader.properties['Effort Days Estimate'] = effortDaysEstimate;
}
function validateFieldsContestSelectionAlgorithm() {
@@ -171,7 +171,7 @@ function validateFieldsContestSelectionAlgorithm() {
errors.push('Marathon match type is required');
}
- validateEffortHoursEstimate(errors);
+ validateEffortDaysEstimate(errors);
// validate schedule
if(startDate >= regEndDate) {
@@ -264,7 +264,7 @@ function validateFieldsContestSelectionSoftware() {
}
}
- validateEffortHoursEstimate(errors);
+ validateEffortDaysEstimate(errors);
if (regEndDate.getTime() <= startDate.getTime()) {
errors.push('Registration end date/time should be larger than Start date/time.');
@@ -413,7 +413,7 @@ function validateFieldsContestSelectionStudio() {
validateDirectProjectMilestone(projectMilestoneId, errors);
}
- validateEffortHoursEstimate(errors);
+ validateEffortDaysEstimate(errors);
if(isMultiRound) {
if (checkpointDateHours == 0) {
diff --git a/src/web/scripts/launchcontest.js b/src/web/scripts/launchcontest.js
index e1129a404..388b0e8cd 100644
--- a/src/web/scripts/launchcontest.js
+++ b/src/web/scripts/launchcontest.js
@@ -385,9 +385,9 @@ $(document).ready(function() {
});
$('.ms-row.effortEstimateRow .helpme').hover(function() {
- showPopup(this, 'effortHourToolTip');
+ showPopup(this, 'effortDaysToolTip');
}, function() {
- $('#effortHourToolTip').hide();
+ $('#effortDaysToolTip').hide();
});
$('#assembly_bug_hunt .helpme').hover(function () {
@@ -659,7 +659,7 @@ function handleProjectDropDownChange() {
$.each(billingAccounts, function(key, value) {
- $("#billingProjects").append($('').val(value["id"]).html(value["name"]).data("cca", (value["cca"] == "true" ? true : false)).data("enableEffortHours", value["enableEffortHours"]));
+ $("#billingProjects").append($('').val(value["id"]).html(value["name"]).data("cca", (value["cca"] == "true" ? true : false)).data("enableEffortDays", value["enableEffortDays"]));
if(value["id"] == $("input[name=CMCBillingID]").val()) {
CMCBillingExisting = true;
@@ -670,7 +670,7 @@ function handleProjectDropDownChange() {
$("#billingProjects").val(0);
if(hasCMCBilling && !CMCBillingExisting) {
- $("#billingProjects").append($('').val($("input[name=CMCBillingID]").val()).html($("input[name=CMCBillingName]").val()).data("cca", false).data("enableEffortHours", value["enableEffortHours"]));
+ $("#billingProjects").append($('').val($("input[name=CMCBillingID]").val()).html($("input[name=CMCBillingName]").val()).data("cca", false).data("enableEffortDays", value["enableEffortDays"]));
}
$("#billingProjects").resetSS();
@@ -683,7 +683,7 @@ function handleProjectDropDownChange() {
$("#lccCheckBox").removeAttr('disabled');
}
- if($(this).find(":selected").data("enableEffortHours")) {
+ if($(this).find(":selected").data("enableEffortDays")) {
$('.effortEstimateRow').show();
} else {
$('.effortEstimateRow').hide();
From bf6f9bd3ebcf845f1563c8595fe05c4112ac25ab Mon Sep 17 00:00:00 2001
From: Deddy Syefria
Date: Thu, 28 Jun 2018 22:34:25 +0700
Subject: [PATCH 3/3] - Change column name enable_effort_hours to
enable_effort_days of table client - Change Effort Estimate label and tooltip
---
.../com/topcoder/clients/dao/ejb3/ProjectDAOBean.java | 4 ++--
.../java/main/com/topcoder/clients/model/Client.java | 4 ++--
src/web/WEB-INF/contest-details2.jsp | 2 +-
src/web/WEB-INF/includes/contest/editTab.jsp | 4 ++--
src/web/WEB-INF/includes/contest/editTabMarathon.jsp | 4 ++--
src/web/WEB-INF/includes/contest/editTabSoftware.jsp | 4 ++--
src/web/WEB-INF/includes/launch/contestSelection.jsp | 2 +-
src/web/WEB-INF/launch-contest.jsp | 2 +-
src/web/css/direct/launchcontest.css | 10 +++++++++-
9 files changed, 22 insertions(+), 14 deletions(-)
diff --git a/services/client_project_entities_dao/src/java/main/com/topcoder/clients/dao/ejb3/ProjectDAOBean.java b/services/client_project_entities_dao/src/java/main/com/topcoder/clients/dao/ejb3/ProjectDAOBean.java
index 66798ea4f..250c6fdd8 100644
--- a/services/client_project_entities_dao/src/java/main/com/topcoder/clients/dao/ejb3/ProjectDAOBean.java
+++ b/services/client_project_entities_dao/src/java/main/com/topcoder/clients/dao/ejb3/ProjectDAOBean.java
@@ -124,7 +124,7 @@ public class ProjectDAOBean extends GenericEJB3DAO implements
private static final String SELECT_PROJECT = "select p.project_id, p.name, p.po_box_number, p.description, "
+ " p.active, p.sales_tax, p.payment_terms_id, p.modification_user, p.modification_date, "
+ " p.creation_date, p.creation_user, p.is_deleted, "
- + " cp.client_id, c.name as client_name, p.is_manual_prize_setting, c.code_name, c.enable_effort_hours "
+ + " cp.client_id, c.name as client_name, p.is_manual_prize_setting, c.code_name, c.enable_effort_days "
+ " from project as p left join client_project as cp on p.project_id = cp.project_id left join client c "
+ " on c.client_id = cp.client_id and (c.is_deleted = 0 or c.is_deleted is null) "
+ " where p.active = 1 and p.start_date <= current and current <= p.end_date ";
@@ -135,7 +135,7 @@ public class ProjectDAOBean extends GenericEJB3DAO implements
private static final String SELECT_PROJECT_BY_CLIENT_ID = "select p.project_id, p.name, p.po_box_number, p.description, "
+ " p.active, p.sales_tax, p.payment_terms_id, p.modification_user, p.modification_date, "
+ " p.creation_date, p.creation_user, p.is_deleted, "
- + " cp.client_id, c.name as client_name, p.is_manual_prize_setting, c.code_name, c.enable_effort_hours "
+ + " cp.client_id, c.name as client_name, p.is_manual_prize_setting, c.code_name, c.enable_effort_days "
+ " from project as p, client_project as cp, client as c "
+ " where p.start_date <= current and current <= p.end_date "
+ " and c.client_id = cp.client_id and (p.is_deleted = 0 or p.is_deleted is null) "
diff --git a/services/client_project_entities_dao/src/java/main/com/topcoder/clients/model/Client.java b/services/client_project_entities_dao/src/java/main/com/topcoder/clients/model/Client.java
index dd885bf5e..f6f1a3f51 100644
--- a/services/client_project_entities_dao/src/java/main/com/topcoder/clients/model/Client.java
+++ b/services/client_project_entities_dao/src/java/main/com/topcoder/clients/model/Client.java
@@ -104,14 +104,14 @@ public class Client extends AuditableEntity {
*
* Through corresponding getter/setter methods. It is retrieved from
* Client.enableEffortDays [Client.isEffortDaysEnabled()] and in table
- * client.enable_effort_hours.
+ * client.enable_effort_days.
*
*
* There are no restrictions at this moment. It can take any value.
* OPTIONAL.
*