Author: jleroux
Date: Sun Sep 6 17:13:04 2009 New Revision: 811838 URL: http://svn.apache.org/viewvc?rev=811838&view=rev Log: A patch from Anil Soni "Improvements in HR module." (https://issues.apache.org/jira/browse/OFBIZ-2604) - OFBIZ-2604 Modified: ofbiz/trunk/applications/humanres/script/org/ofbiz/humanres/HumanResServices.xml ofbiz/trunk/applications/humanres/servicedef/services.xml ofbiz/trunk/applications/humanres/webapp/humanres/WEB-INF/controller.xml ofbiz/trunk/applications/humanres/widget/CommonScreens.xml ofbiz/trunk/applications/humanres/widget/forms/GlobalHRSettingForms.xml ofbiz/trunk/applications/humanres/widget/forms/PartyResumeForms.xml ofbiz/trunk/applications/humanres/widget/forms/PayGradeForms.xml Modified: ofbiz/trunk/applications/humanres/script/org/ofbiz/humanres/HumanResServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/humanres/script/org/ofbiz/humanres/HumanResServices.xml?rev=811838&r1=811837&r2=811838&view=diff ============================================================================== --- ofbiz/trunk/applications/humanres/script/org/ofbiz/humanres/HumanResServices.xml (original) +++ ofbiz/trunk/applications/humanres/script/org/ofbiz/humanres/HumanResServices.xml Sun Sep 6 17:13:04 2009 @@ -52,7 +52,7 @@ <make-value entity-name="PartyResume" value-field="newEntity"/> <set-nonpk-fields map="parameters" value-field="newEntity"/> <sequenced-id sequence-name="PartyResume" field="newEntity.resumeId"/> - <field-to-result field="resumeId" result-name="resumeId"/> + <field-to-result field="resumeId" result-name="newEntity.resumeId"/> <create-value value-field="newEntity"/> </simple-method> @@ -325,8 +325,11 @@ <simple-method method-name="createTerminationReason" short-description="Create a Termination Reason"> <make-value entity-name="TerminationReason" value-field="newEntity"/> + <set-pk-fields map="parameters" value-field="newEntity"/> <set-nonpk-fields map="parameters" value-field="newEntity"/> - <sequenced-id sequence-name="TerminationReason" field="newEntity.terminationReasonId"/> + <if-empty field="newEntity.terminationReasonId"> + <sequenced-id sequence-name="TerminationReason" field="newEntity.terminationReasonId"/> + </if-empty> <field-to-result field="newEntity.terminationReasonId" result-name="terminationReasonId"/> <create-value value-field="newEntity"/> </simple-method> @@ -486,8 +489,11 @@ <!-- Skill Types --> <simple-method method-name="createSkillType" short-description="Create a SkillType"> <make-value entity-name="SkillType" value-field="newEntity"/> + <set-pk-fields map="parameters" value-field="newEntity"/> <set-nonpk-fields map="parameters" value-field="newEntity"/> - <sequenced-id sequence-name="SkillType" field="newEntity.skillTypeId"/> + <if-empty field="newEntity.skillTypeId"> + <sequenced-id sequence-name="SkillType" field="newEntity.skillTypeId"/> + </if-empty> <field-to-result field="newEntity.skillTypeId" result-name="skillTypeId"/> <create-value value-field="newEntity"/> </simple-method> @@ -548,9 +554,10 @@ <simple-method method-name="createTerminationType" short-description="Create a TerminationType"> <make-value entity-name="TerminationType" value-field="newEntity"/> + <set-pk-fields map="parameters" value-field="newEntity"/> <set-nonpk-fields map="parameters" value-field="newEntity"/> <if-empty field="newEntity.terminationTypeId"> - <sequenced-id sequence-name="TerminationType" field="newEntity.terminationTypeId"/> + <sequenced-id sequence-name="TerminationType" field="newEntity.terminationTypeId"/> </if-empty> <field-to-result field="newEntity.terminationTypeId" result-name="terminationTypeId"/> <create-value value-field="newEntity"/> @@ -582,6 +589,11 @@ <set-nonpk-fields value-field="lookedUpValue" map="parameters"/> <store-value value-field="lookedUpValue"/> </simple-method> + + <simple-method method-name="deleteEmplPositionType" short-description="Delete EmplPositionType"> + <entity-one entity-name="EmplPositionType" value-field="lookedUpValue"/> + <remove-value value-field="lookedUpValue"/> + </simple-method> <simple-method method-name="updateEmplPositionTypeRate" short-description="Update/create EmplPositionTypeRate"> <entity-one entity-name="EmplPositionTypeRate" value-field="lookedUpValue"/> Modified: ofbiz/trunk/applications/humanres/servicedef/services.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/humanres/servicedef/services.xml?rev=811838&r1=811837&r2=811838&view=diff ============================================================================== --- ofbiz/trunk/applications/humanres/servicedef/services.xml (original) +++ ofbiz/trunk/applications/humanres/servicedef/services.xml Sun Sep 6 17:13:04 2009 @@ -255,6 +255,7 @@ <permission-service service-name="humanResManagerPermission" main-action="UPDATE"/> <auto-attributes mode="IN" include="pk" optional="false"/> <auto-attributes mode="IN" include="nonpk" optional="true"/> + <override name="payGradeName" optional="false"/> </service> <service name="deletePayGrade" engine="simple" default-entity-name="PayGrade" @@ -343,6 +344,7 @@ <permission-service service-name="humanResManagerPermission" main-action="CREATE"/> <auto-attributes mode="INOUT" include="pk" optional="true"/> <auto-attributes mode="IN" include="nonpk" optional="true"/> + <override name="description" optional="false"/> </service> <service name="updateTerminationReason" engine="simple" default-entity-name="TerminationReason" @@ -351,6 +353,7 @@ <permission-service service-name="humanResManagerPermission" main-action="UPDATE"/> <auto-attributes mode="IN" include="pk" optional="false"/> <auto-attributes mode="IN" include="nonpk" optional="true"/> + <override name="description" optional="false"/> </service> <service name="deleteTerminationReason" engine="simple" default-entity-name="TerminationReason" @@ -521,6 +524,7 @@ <permission-service service-name="humanResManagerPermission" main-action="UPDATE"/> <auto-attributes mode="IN" include="pk" optional="false"/> <auto-attributes mode="IN" include="nonpk" optional="true"/> + <override name="description" optional="false"/> </service> <service name="deleteSkillType" engine="simple" default-entity-name="SkillType" location="component://humanres/script/org/ofbiz/humanres/HumanResServices.xml" invoke="deleteSkillType" auth="true"> @@ -584,6 +588,7 @@ <permission-service service-name="humanResManagerPermission" main-action="UPDATE"/> <auto-attributes mode="IN" include="pk" optional="false"/> <auto-attributes mode="IN" include="nonpk" optional="true"/> + <override name="description" optional="false"/> </service> <service name="deleteTerminationType" engine="simple" default-entity-name="TerminationType" location="component://humanres/script/org/ofbiz/humanres/HumanResServices.xml" invoke="deleteTerminationType" auth="true"> @@ -607,6 +612,14 @@ <permission-service service-name="humanResManagerPermission" main-action="UPDATE"/> <auto-attributes mode="IN" include="pk" optional="false"/> <auto-attributes mode="IN" include="nonpk" optional="true"/> + <override name="description" optional="false"/> + </service> + + <service name="deleteEmplPositionType" engine="simple" default-entity-name="EmplPositionType" + location="component://humanres/script/org/ofbiz/humanres/HumanResServices.xml" invoke="deleteEmplPositionType" auth="true"> + <description>Delete EmplPositionType</description> + <permission-service service-name="humanResManagerPermission" main-action="DELETE"/> + <auto-attributes mode="IN" include="pk" optional="false"/> </service> <service name="updateEmplPositionTypeRate" engine="simple" default-entity-name="EmplPositionTypeRate" @@ -682,6 +695,7 @@ <permission-service service-name="humanResManagerPermission" main-action="UPDATE"/> <auto-attributes mode="IN" include="pk" optional="false"/> <auto-attributes mode="IN" include="nonpk" optional="true"/> + <override name="description" optional="false"/> </service> <service name="deleteEmplLeaveType" engine="simple" default-entity-name="EmplLeaveType" Modified: ofbiz/trunk/applications/humanres/webapp/humanres/WEB-INF/controller.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/humanres/webapp/humanres/WEB-INF/controller.xml?rev=811838&r1=811837&r2=811838&view=diff ============================================================================== --- ofbiz/trunk/applications/humanres/webapp/humanres/WEB-INF/controller.xml (original) +++ ofbiz/trunk/applications/humanres/webapp/humanres/WEB-INF/controller.xml Sun Sep 6 17:13:04 2009 @@ -110,7 +110,7 @@ <request-map uri="deletePartyResume"> <security https="true" auth="true"/> <event type="service" invoke="deletePartyResume"/> - <response name="success" type="view" value="EditPartyResume"/> + <response name="success" type="view" value="FindPartyResumes"/> </request-map> <request-map uri="FindPartySkills"> <security https="true" auth="true"/> @@ -312,12 +312,12 @@ <request-map uri="createPayGrade"> <security https="true" auth="true"/> <event type="service" invoke="createPayGrade"/> - <response name="success" type="view" value="FindPayGrades"/> + <response name="success" type="view" value="EditPayGrade"/> <response name="error" type="view" value="EditPayGrade"/> </request-map> <request-map uri="updatePayGrade"> <security https="true" auth="true"/> - <event type="service-multi" invoke="updatePayGrade"/> + <event type="service" invoke="updatePayGrade"/> <response name="success" type="view" value="EditPayGrade"/> <response name="error" type="view" value="EditPayGrade"/> </request-map> @@ -718,6 +718,11 @@ <event type="service" invoke="updateEmplPositionType"/> <response name="success" type="view" value="EditEmplPositionTypes"/> </request-map> + <request-map uri="deleteEmplPositionType"> + <security https="true" auth="true"/> + <event type="service" invoke="deleteEmplPositionType"/> + <response name="success" type="view" value="FindEmplPositionTypes"/> + </request-map> <request-map uri="EditEmplPositionTypeRates"> <security https="true" auth="true"/> <response name="success" type="view" value="EditEmplPositionTypeRates"/> Modified: ofbiz/trunk/applications/humanres/widget/CommonScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/humanres/widget/CommonScreens.xml?rev=811838&r1=811837&r2=811838&view=diff ============================================================================== --- ofbiz/trunk/applications/humanres/widget/CommonScreens.xml (original) +++ ofbiz/trunk/applications/humanres/widget/CommonScreens.xml Sun Sep 6 17:13:04 2009 @@ -165,12 +165,19 @@ </entity-one> </actions> <widgets> - <include-menu name="EmploymentBar" location="component://humanres/widget/Menus.xml"/> - <container style="button-bar"> - <link target="EditEmployment" text="${uiLabelMap.HumanResNewEmployment}" style="buttontext"/> - </container> - <label style="h1" text="${emplName.lastName},${emplName.firstName} ${emplName.middleName} [${emplName.partyId}] ${uiLabelMap.CommonFor}"></label> - <label style="h1" text="${orgName.groupName} [${orgName.partyId}]"></label> + <section> + <condition> + <not><if-empty field="parameters.fromDate"/></not> + </condition> + <widgets> + <include-menu name="EmploymentBar" location="component://humanres/widget/Menus.xml"/> + <container style="button-bar"> + <link target="EditEmployment" text="${uiLabelMap.HumanResNewEmployment}" style="buttontext"/> + </container> + <label style="h1" text="${emplName.lastName},${emplName.firstName} ${emplName.middleName} [${emplName.partyId}] ${uiLabelMap.CommonFor}"></label> + <label style="h1" text="${orgName.groupName} [${orgName.partyId}]"></label> + </widgets> + </section> </widgets> </section> <decorator-section-include name="body"/> Modified: ofbiz/trunk/applications/humanres/widget/forms/GlobalHRSettingForms.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/humanres/widget/forms/GlobalHRSettingForms.xml?rev=811838&r1=811837&r2=811838&view=diff ============================================================================== --- ofbiz/trunk/applications/humanres/widget/forms/GlobalHRSettingForms.xml (original) +++ ofbiz/trunk/applications/humanres/widget/forms/GlobalHRSettingForms.xml Sun Sep 6 17:13:04 2009 @@ -62,7 +62,7 @@ <form name="AddResponsibilityType" type="single" target="createResponsibilityType" title="" default-map-name="responsibilityType"> <auto-fields-service service-name="createResponsibilityType" default-field-type="hidden"/> <field name="responsibilityTypeId" title="${uiLabelMap.HumanResResponsibilityTypeId}"><text/></field> - <field name="description" title="${uiLabelMap.CommonDescription}" tooltip="${uiLabelMap.CommonRequired}"><text/></field> + <field name="description" title="${uiLabelMap.CommonDescription}" tooltip="${uiLabelMap.CommonRequired}" widget-style="required"><text/></field> <field name="submitButton" title="${uiLabelMap.CommonCreate}" widget-style="buttontext"><submit button-type="text-link"/></field> </form> <form name="ListTerminationTypes" type="multi" title="" target="updateTerminationType" @@ -116,15 +116,21 @@ </hyperlink> </field> <field name="description" title="${uiLabelMap.CommonDescription}"><display/></field> + <field name="deleteLink" title="${uiLabelMap.CommonDelete}" widget-style="buttontext"> + <hyperlink target="deleteEmplPositionType" description="${uiLabelMap.CommonDelete}" also-hidden="false"> + <parameter param-name="emplPositionTypeId"/> + </hyperlink> + </field> </form> <form name="EditEmplPositionTypes" type="single" target="updateEmplPositionType" default-map-name="emplPositionType" header-row-style="header-row" default-table-style="basic-table"> <alt-target use-when="emplPositionType==null" target="createEmplPositionType"/> <auto-fields-service service-name="updateEmplPositionType"/> - <field name="emplPositionTypeId" use-when="emplPositionType==null" tooltip="${uiLabelMap.CommonRequired}" widget-style="required"><text/></field> + <field name="emplPositionTypeId" use-when="emplPositionType==null"><text/></field> <field name="emplPositionTypeId" use-when="emplPositionType!=null"><display/></field> - <field name="description" title="${uiLabelMap.CommonDescription}"><text/></field> + <field name="description" title="${uiLabelMap.CommonDescription}" tooltip="${uiLabelMap.CommonRequired}" widget-style="required"><text/></field> <field name="submitButton" title="${uiLabelMap.CommonCreate}" widget-style="smallSubmit"><submit button-type="button"/></field> + <field name="submitButton" title="${uiLabelMap.CommonUpdate}" use-when="emplPositionType!=null" widget-style="smallSubmit"><submit button-type="button"/></field> </form> <form name="ListEmplPositionTypeRates" type="list" title="" target="deleteEmplPositionTypeRate" odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar"> Modified: ofbiz/trunk/applications/humanres/widget/forms/PartyResumeForms.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/humanres/widget/forms/PartyResumeForms.xml?rev=811838&r1=811837&r2=811838&view=diff ============================================================================== --- ofbiz/trunk/applications/humanres/widget/forms/PartyResumeForms.xml (original) +++ ofbiz/trunk/applications/humanres/widget/forms/PartyResumeForms.xml Sun Sep 6 17:13:04 2009 @@ -61,8 +61,8 @@ <form name="EditPartyResume" type="single" target="createPartyResume" title="" default-map-name="partyResume" header-row-style="header-row" default-table-style="basic-table"> <alt-target use-when="partyResume != null" target="updatePartyResume"/> - <field name="resumeId" use-when="resumeId!=null" tooltip="${uiLabelMap.CommonNotModifRecreat}"><display/></field> - <field name="resumeId" use-when="resumeId==null" tooltip="${uiLabelMap.CommonRequired}" widget-style="required"><text/></field> + <field name="resumeId" use-when="partyResume!=null" tooltip="${uiLabelMap.CommonNotModifRecreat}"><display/></field> + <field name="resumeId" use-when="partyResume==null" tooltip="${uiLabelMap.CommonRequired}" widget-style="required"><text/></field> <field name="contentId"><lookup target-form-name="LookupContent"/></field> <field name="partyId" use-when="partyResume!=null&&partyId!=null" title="${uiLabelMap.FormFieldTitle_partyId}"><hidden/></field> <field name="partyId" use-when="partyResume==null&&partyId==null" title="${uiLabelMap.FormFieldTitle_partyId}"><lookup target-form-name="LookupPartyName"/></field> Modified: ofbiz/trunk/applications/humanres/widget/forms/PayGradeForms.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/humanres/widget/forms/PayGradeForms.xml?rev=811838&r1=811837&r2=811838&view=diff ============================================================================== --- ofbiz/trunk/applications/humanres/widget/forms/PayGradeForms.xml (original) +++ ofbiz/trunk/applications/humanres/widget/forms/PayGradeForms.xml Sun Sep 6 17:13:04 2009 @@ -43,15 +43,21 @@ <parameter param-name="payGradeId"/> </hyperlink> </field> + <field name="deleteLink" title="${uiLabelMap.CommonDelete}" widget-style="buttontext"> + <hyperlink target="deletePayGrade" description="${uiLabelMap.CommonDelete}" also-hidden="false"> + <parameter param-name="payGradeId"/> + </hyperlink> + </field> </form> <form name="EditPayGrade" type="single" target="updatePayGrade" title="" header-row-style="header-row" default-table-style="basic-table" default-map-name="payGrade"> <alt-target use-when="payGradeId==null" target="createPayGrade"/> - <auto-fields-service default-field-type="edit" service-name="createPayGrade"/> + <auto-fields-service service-name="updatePayGrade"/> <field use-when="payGrade!=null" name="payGradeId" tooltip="${uiLabelMap.CommonNotModifRecreat}"><display/></field> - <field use-when="payGrade==null" name="payGradeId" tooltip="${uiLabelMap.CommonRequired}" widget-style="required"><text/></field> - <field name="payGradeName"><text/></field> - <field name="submitButton" title="${uiLabelMap.CommonSave}" widget-style="smallSubmit"><submit button-type="button"/></field> + <field use-when="payGrade==null" name="payGradeId"><text/></field> + <field name="payGradeName" tooltip="${uiLabelMap.CommonRequired}" widget-style="required"><text/></field> + <field name="submitButton" title="${uiLabelMap.CommonCreate}" widget-style="smallSubmit"><submit button-type="button"/></field> + <field name="submitButton" title="${uiLabelMap.CommonUpdate}" use-when="payGrade!=null" widget-style="smallSubmit"><submit button-type="button"/></field> </form> <form name="ListSalarySteps" type="multi" target="updateSalaryStep?salaryStepSeqId=${salaryStepSeqId}&payGradeId=${payGradeId}" paginate-target="findSalarySteps" odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar"> |
Free forum by Nabble | Edit this page |