Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sync master with staging #2832

Merged
merged 208 commits into from
Aug 20, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
208 commits
Select commit Hold shift + click to select a range
be1ed18
PCHR-3545: Changed Order For Individual Prefix
backstageel Jun 19, 2018
b054784
Merge pull request #2691 from compucorp/PCHR-3545-Change-Order-For-In…
backstageel Jun 19, 2018
c6ca03a
PCHR-3603: Rename "Line Manager" Relationship
backstageel Jun 21, 2018
a2c1bcc
PCHR-3603: Changing Rename to Relabel
backstageel Jun 21, 2018
3b89915
PCHR-3604: Changed the order of the Gender Options
backstageel Jun 21, 2018
f986f71
Merge pull request #2700 from compucorp/PCHR-3603-Rename-Line-manager…
backstageel Jun 21, 2018
eb93d9d
Merge remote-tracking branch 'origin/PCHR-3536-Display-Preferences' i…
backstageel Jun 21, 2018
91e450a
Merge pull request #2701 from compucorp/PCHR-3604-Set-Default-Gender-…
backstageel Jun 21, 2018
2e6ba74
PCHR-3544: Hide fields for contact summary
ajesamson Jun 21, 2018
0991390
PCHR-3544: Resolved merge conflict with branch 'PCHR-3536-Display-Pr…
ajesamson Jun 21, 2018
f3b4a6f
PCHR-3544: PR Feedback - Code refactoring
ajesamson Jun 21, 2018
ebede58
Merge pull request #2703 from compucorp/PCHR-3544-hide-fields-for-con…
ajesamson Jun 21, 2018
6e89e7d
PCHR-3536: Fixing merge conflicts
backstageel Jun 21, 2018
e14e0f9
PCHR-3536: Fixing merge conflicts
backstageel Jun 21, 2018
17b142d
Merge branch 'PCHR-3536-Display-Preferences' of https://github.com/ci…
backstageel Jun 21, 2018
45176dd
PCHR-3536: Fixing Merge Conflicts
backstageel Jun 21, 2018
0c8ded2
PCHR-3546: Made all currencies available for new installations
backstageel Jun 20, 2018
ead88fa
Merge pull request #2698 from compucorp/PCHR-3546-Make-All-Currencies…
backstageel Jun 21, 2018
28b7bf7
PCHR-3606: Remove Some Social Accounts and Reorder the Remaining
backstageel Jun 22, 2018
5b92160
PCHR-3606: If a social account is used, only disable it
backstageel Jun 29, 2018
66e7e83
Merge pull request #2721 from compucorp/PCHR-3606-Change-Default-Soci…
backstageel Jul 2, 2018
9d56520
PCHR-3605: Deletes Some Instant Messenger Options and Disable if Used
backstageel Jul 2, 2018
d0f60ec
PCHR-3605: Extracted some logic to their own method and renamed the m…
backstageel Jul 3, 2018
88b146a
PCHR-3608: Makes contract length read only and hides it from Personal…
backstageel Jul 4, 2018
4ca310c
Merge pull request #2728 from compucorp/PCHR-3605-Delete-Instant-Mess…
backstageel Jul 4, 2018
8d6fc73
PCHR-3608: Field should not be removed on XML and chained the API calls
backstageel Jul 4, 2018
88de360
Merge pull request #2742 from compucorp/PCHR-3608-Make-Contract-Lengt…
backstageel Jul 4, 2018
ff6723e
PCHR-3602 Hides disabled relationship Types from non-root admins
backstageel Jul 11, 2018
7ed2530
PCHR-3607: Delete Default Groups and Hides One of Them
backstageel Jul 11, 2018
20c60c6
PCHR-3602: PR Feedback
backstageel Jul 11, 2018
3f8d444
PCHR-3607: changed to chained API calls
backstageel Jul 11, 2018
e666af4
Merge pull request #2754 from compucorp/PCHR-3607-Delete-Default-Groups
backstageel Jul 11, 2018
cae9178
Merge pull request #2755 from compucorp/PCHR-3602-Hide-Disabled-Relat…
backstageel Jul 11, 2018
63b149c
PCHR-3536: Merge branch 'staging' into PCHR-3536-Display-Preferences
ajesamson Jul 13, 2018
5af61dd
PCHR-3983: Fix hrcore installation issues related to enabling currencies
davialexandre Jul 16, 2018
ba439cb
PCHR-3975: Disable Prefer Not To Say Gender Option
backstageel Jul 16, 2018
7c921f4
PCHR-3983: Fix hrcore installation issues related to enabling currencies
davialexandre Jul 16, 2018
444e137
Merge pull request #2762 from compucorp/PCHR-3975-disable-some-gender…
backstageel Jul 17, 2018
b00cac6
Merge pull request #2764 from compucorp/PCHR-3983-fix-enabling-curren…
davialexandre Jul 17, 2018
13bf27e
Merge branch 'staging' into PCHR-3536-Display-Preferences
davialexandre Jul 17, 2018
5843ff7
PCHR-3944: Update AngularJS to 1.6.10
Jul 20, 2018
c55c74a
PCHR-4001: Allow contact to be own leave approver on relationship scr…
tunbola Jul 20, 2018
83366a1
Merge pull request #2780 from compucorp/PCHR-4001-remove-validation-r…
tunbola Jul 23, 2018
a25038e
PCHR-4018: Add getCurrentlyLoggedIn() method
igorpavlov Jul 24, 2018
fe5fbf1
PCHR-4018: Add checkIfSelfLeaveApprover() method
igorpavlov Jul 24, 2018
06c5541
PCHR-4018: Wrap tests so another case can be written
igorpavlov Jul 24, 2018
b6e5c70
PCHR-3345: Unable to create user account for restored contact
ajesamson Jul 24, 2018
f797f5a
PCHR-3955: (Job Contract) Fix unexpected request error in tests
Jul 24, 2018
0729178
PCHR-3944: (Job Contract) Misc test fixes
Jul 24, 2018
742a405
PCHR-3944: (Contact Summary) Use .templates module to fix failing specs
Jul 24, 2018
14d0203
PCHR-3941: Fix linting issues for HR Career
deb1990 Jul 19, 2018
af99942
PCHR-3941: Use RequireJS in HR Career
deb1990 Jul 19, 2018
8408085
PCHR-3941: Fix linting issues for HR Qual
deb1990 Jul 19, 2018
e875692
PCHR-3941: Use RequireJS in HR Qual
deb1990 Jul 19, 2018
307b586
PCHR-3941: Fix linting issues for HR IM
deb1990 Jul 19, 2018
51b3ca4
PCHR-3941: Use RequireJS in HR IM
deb1990 Jul 19, 2018
253fef9
PCHR-3941: Use RequireJS in Contact Actions
deb1990 Jul 19, 2018
cf6485a
PCHR-3941: Use RequireJS in HR CORE
deb1990 Jul 19, 2018
7701ebe
PCHR-3941: Use RequireJS in HR UI
deb1990 Jul 19, 2018
2b83701
PCHR-3941: Remove js file for HR CASE
deb1990 Jul 19, 2018
dbd097c
PCHR-3941: Fix linting issues for HR MED
deb1990 Jul 19, 2018
3053d24
PCHR-3941: Use RequireJS in HR MED
deb1990 Jul 19, 2018
b37126c
PCHR-3941: PR Feedback
deb1990 Jul 19, 2018
e1d4470
PCHR-3941: Fix HRUI
deb1990 Jul 24, 2018
20ba08b
PCHR-3944: Use in notificationBadge and fix spec
Jul 25, 2018
a32bd89
PCHR-3944: (L&A) Use hook in components
Jul 25, 2018
a015989
PCHR-3944: (L&A) Fix return value in update() method
Jul 25, 2018
4fe427e
PCHR-3944: (L&A) Fix tests
Jul 25, 2018
f777f46
PCHR-3941: PR Feedback - HRUI
deb1990 Jul 25, 2018
018145c
PCHR-4018: Treat contact as admin if self-approver
igorpavlov Jul 25, 2018
01ee42d
PCHR-3345: Resets role for restored contact when creating account
ajesamson Jul 25, 2018
e964da7
PCHR-4018: PR Feedback
igorpavlov Jul 25, 2018
48db010
PCHR-4018: Provide function descriptions
igorpavlov Jul 25, 2018
16bb1ad
Merge pull request #2786 from compucorp/PCHR-4018-allow-quick-lr-acti…
igorpavlov Jul 25, 2018
25ae6d1
PCHR-3424: Apply image path variable
igorpavlov Jul 25, 2018
fd4371c
PCHR-3944: Update dist files
Jul 25, 2018
d513885
PCHR-3944: Update AngularJS to 1.7.2
Jul 25, 2018
f36247e
PCHR-4002: Allow contact perform Admin status actions on own request …
tunbola Jul 25, 2018
2cf519c
PCHR-4002: Fix broken tests. Some tests were ran with admin permissio…
tunbola Jul 25, 2018
d947641
PCHR-4002: Split argument in separate lines
tunbola Jul 25, 2018
b8fe30f
Merge pull request #2792 from compucorp/PCHR-4002-leave-approver-admi…
tunbola Jul 25, 2018
7d7f2ee
PCHR-3941: Detach require.min.js from reqangular
deb1990 Jul 26, 2018
5207417
Merge pull request #2791 from compucorp/PCHR-3424-remove-bootstrapciv…
igorpavlov Jul 26, 2018
cc3e272
PCHR-4019: Allow self approver to choose request status
igorpavlov Jul 26, 2018
de59269
PCHR-4019: Improve the code
igorpavlov Jul 26, 2018
799e709
PCHR-3941: hide fields on document.ready
deb1990 Jul 27, 2018
9aaceeb
PCHR-3941: Refactor hrui
deb1990 Jul 27, 2018
5e543d2
PCHR-3624: Move extended demographics custom group XML
mickadoo Apr 26, 2018
e7753fd
PCHR-3624: Apply changes from upgrader to XML. Delete upgraders
mickadoo Apr 26, 2018
08d63d0
PCHR-3624: Migrate upgrader stuff from HRDemog
mickadoo Apr 26, 2018
7371dea
PCHR-3624: Delete the hrdemog extension
mickadoo Apr 26, 2018
4d1ae99
PCHR-3624: Remove references to hrdemog extension
mickadoo Apr 30, 2018
6b8b8d3
PCHR-3624: Add fabricators for custom group and field
mickadoo Apr 30, 2018
e19d686
PCHR-3624: Throw exception if group not found. Add tests
mickadoo Apr 30, 2018
539ece2
PCHR-3624: Add required param in update
mickadoo Apr 30, 2018
eacf764
PCHR-3624: Don't use HRCore in extension helper test
mickadoo Apr 30, 2018
eaccc6e
PCHR-4040: Allow user who is own leave approver to delete own request…
tunbola Jul 27, 2018
b909dcd
PCHR-3624: Resolve upgrader conflict
mickadoo Apr 30, 2018
4f04683
Merge pull request #2775 from compucorp/PCHR-3941-use-requirejs-in-ci…
deb1990 Jul 27, 2018
dbf2f65
PCHR-3624: Fix comments
mickadoo May 2, 2018
9c55a51
PCHR-3624: Ensure name is different on each successive fabricator call
mickadoo May 15, 2018
c3a645d
PCHR-3624: Move XML files to subdirectory
mickadoo May 15, 2018
989f3a9
PCHR-3624: Change service IDs to match convention
mickadoo May 17, 2018
aa453f0
PCHR-3624: Revert changes to ethnicity default value
mickadoo May 17, 2018
1438816
PCHR-4019: PR Feedback
igorpavlov Jul 27, 2018
7768069
Merge pull request #2794 from compucorp/PCHR-4019-allow-self-approver…
igorpavlov Jul 27, 2018
654de5d
Merge pull request #2795 from compucorp/PCHR-4040-allow-leave-approve…
tunbola Jul 27, 2018
df3618a
PCHR-3944: Update rangy version
Jul 27, 2018
149dfc1
PCHR-3944: Update textAngular version (use fork)
Jul 27, 2018
01a787d
PCHR-3944: (Reqangular) Fix path in test-main
Jul 27, 2018
10f115a
PCHR-3944: (Reqangular) Update dist file
Jul 27, 2018
3cea3b6
Merge branch 'staging' into PCHR-3944-update-angularjs
Jul 27, 2018
f2956a3
PCHR-3944: (Job Contract) More test fixing after bump to 1.7
Jul 27, 2018
5eb7ee3
Merge pull request #2797 from compucorp/PCHR-3624-migrating-custom-gr…
ajesamson Jul 27, 2018
056b9ad
Merge pull request #2778 from compucorp/PCHR-3345-unable-to-create-us…
ajesamson Jul 27, 2018
edccb32
PCHR-3944: Update to last angular-ui-router legacy version
Jul 27, 2018
dc31ebf
PCHR-3944: (L&A) Use common angular-ui-router instead of local one
Jul 27, 2018
1dc3e97
PCHR-3599: Deletes Some Extended Demographic Fields
backstageel Jun 29, 2018
29e5eb1
PCHR-3599: Changed function name and formated the query for better re…
backstageel Jul 4, 2018
8e7e02e
PCHR-3599: Updated extended demographics test
backstageel Jul 4, 2018
ed97c63
Merge pull request #2798 from compucorp/PCHR-3599-Remove-HRDemog-Cust…
ajesamson Jul 27, 2018
3b51401
PCHR-4045: Allow admins always approve their requests in the modal
igorpavlov Jul 27, 2018
34f3f0f
PCHR-4045: Allow admins always approve their requests via quick actions
igorpavlov Jul 27, 2018
58aad1d
PCHR-3944: Use .uniqueId in spec
Jul 30, 2018
956e00a
PCHR-4045: Refactor code
igorpavlov Jul 30, 2018
f83c589
Merge branch 'staging' into PCHR-3542-custom-group-updates
ajesamson Jul 30, 2018
2466ee9
PCHR-4045: PR Feedback
igorpavlov Jul 30, 2018
b17044d
Merge pull request #2800 from compucorp/PCHR-4045-treat-admin-as-self…
igorpavlov Jul 30, 2018
ce5c991
Merge branch 'staging' into PCHR-3997-allow-own-leave-approver
igorpavlov Jul 30, 2018
f2a12db
Merge pull request #2790 from compucorp/PCHR-3944-update-angularjs
AkA84 Jul 30, 2018
a4693c1
PCHR-3600: Move hrdemog fields in contact profile
ajesamson Jul 11, 2018
5189c58
Merge pull request #2801 from compucorp/PCHR-3600-move-hrdemog-fields…
ajesamson Jul 30, 2018
e1bee09
Merge branch 'staging' into PCHR-3997-allow-own-leave-approver
igorpavlov Jul 30, 2018
c039623
PCHR-4049: Upgrade gulp
igorpavlov Jul 30, 2018
8bfd196
PCHR-4049: Fix watching
igorpavlov Jul 31, 2018
98e4f95
Merge pull request #2802 from compucorp/PCHR-3542-custom-group-updates
ajesamson Jul 31, 2018
28bc2e0
PCHR-4049: Fix tasks promises execution
igorpavlov Jul 31, 2018
d56dfb0
PCHR-4051: Add the canCancelForAbsenceType method in LeaveRequestRigh…
tunbola Jul 31, 2018
f237c6d
PCHR-4049: Fix Jenkinsfile
igorpavlov Jul 31, 2018
3cf2fc4
PCHR-4051: Use the canCancelForAbsenceType method in LeaveRequest Ser…
tunbola Jul 31, 2018
c22b77e
PCHR-4051: Remove obsolete tests. Fix broken tests.
tunbola Jul 31, 2018
618dec1
PCHR-4051: Code formatting fixes
tunbola Jul 31, 2018
bbd8856
PCHR-4051: Fix boolean case in tests.
tunbola Jul 31, 2018
38f1808
PCHR-4051: Refactor method for clarity.
tunbola Jul 31, 2018
7061cc9
PCHR-4054: Fix role for self approving manager
igorpavlov Jul 31, 2018
da99782
Merge pull request #2805 from compucorp/PCHR-4051-allow-own-approver-…
tunbola Jul 31, 2018
09373c2
PCHR-4054: PR Feedback
igorpavlov Aug 1, 2018
e0e90c8
Merge pull request #2806 from compucorp/PCHR-4053-fix-issue-for-manag…
igorpavlov Aug 1, 2018
230c282
PCHR-4054: Refactored canChangeDatesFor method to allow own leave app…
tunbola Aug 1, 2018
0f6bf79
Merge pull request #2808 from compucorp/PCHR-4054-allow-leave-dates-edit
tunbola Aug 1, 2018
fc7f3b0
SHOR-22: Remove extra PHP code for appending contact image - covered …
swastikpareek Aug 1, 2018
8dceb0c
Merge branch 'staging' into PCHR-3536-Display-Preferences
backstageel Aug 1, 2018
01725f9
PCHR-4049: Fix tasks maps
igorpavlov Aug 1, 2018
d37f669
PCHR-4049: Fix watchers
igorpavlov Aug 1, 2018
fe86133
PCHR-4076: Fix filters on admin leave - leave requests and calendar tab
ajesamson Aug 1, 2018
b5f3b7c
Merge pull request #2807 from compucorp/PCHR-4076-fix-filters-on-admi…
ajesamson Aug 2, 2018
ab37348
PCHR-4094: Add admin to managees list
igorpavlov Aug 2, 2018
0659b91
PCHR-4094: PR Feedback
igorpavlov Aug 2, 2018
1844505
Merge pull request #2811 from compucorp/PCHR-4094-add-admin-in-the-ma…
igorpavlov Aug 2, 2018
e6b3ae0
Merge pull request #2785 from compucorp/PCHR-3997-allow-own-leave-app…
igorpavlov Aug 2, 2018
0c7c88d
Merge pull request #2810 from compucorp/SHOR-22-add-contact-image-to-…
AkA84 Aug 2, 2018
99553f3
PCHR-4075: Fix filters on admin - advanced search - job role filters
ajesamson Aug 3, 2018
c494a7f
Merge pull request #2813 from compucorp/PCHR-4075-fix-filters-on-admi…
ajesamson Aug 3, 2018
71d02cc
Merge pull request #2804 from compucorp/PCHR-4049-upgrade-gulp
igorpavlov Aug 6, 2018
0871e79
PCHR-4005: Fix JS for HRMed and HRCareer
igorpavlov Aug 2, 2018
6e89b0e
PCHR-4005: PR Feedback
igorpavlov Aug 2, 2018
2aed98e
PCHR-4005: Remove code duplication
igorpavlov Aug 3, 2018
3103b51
PCHR-4005: Refactor the code
igorpavlov Aug 3, 2018
09008ef
PCHR-4005: Update dist files
igorpavlov Aug 6, 2018
a0613de
PCHR-4049: Fix gulp tasks
igorpavlov Aug 6, 2018
8cf52a5
Merge pull request #2812 from compucorp/PCHR-4005-fix-js-for-hrcareer…
igorpavlov Aug 7, 2018
86b387a
PCHR-4049: PR Feedback
igorpavlov Aug 7, 2018
2f0f5bc
Merge pull request #2819 from compucorp/PCHR-4049-fix-gulp
igorpavlov Aug 7, 2018
035317f
PCHR-4098: Fix angular urls
Aug 3, 2018
d3bd8a8
PCHR-4098: Update selector for edit my details button
Aug 3, 2018
4cdd46a
PCHR-4098: Use backstopjs beta
Aug 7, 2018
af28150
PCHR-4105: Fix linter issue
Aug 8, 2018
774f91c
PCHR-4105: Add reset styles for h3
Aug 8, 2018
fbaf873
Merge pull request #2820 from compucorp/PCHR-4105-fix-h3-ta-jc
AkA84 Aug 8, 2018
5cd95b1
Merge pull request #2760 from compucorp/PCHR-3536-Display-Preferences
backstageel Aug 8, 2018
4a6639e
PCHR-4098: Use standard 3.5.2 version
Aug 8, 2018
39304a6
Merge pull request #2818 from compucorp/PCHR-4098-fix-backstopjs-angu…
AkA84 Aug 8, 2018
3f9b648
Merge pull request #2821 from compucorp/PCHR-3963-fix-ssp-filters-to-…
ajesamson Aug 8, 2018
9164976
PCHR-4072: Update help link to lead to freshdesk knowledge base home …
ajesamson Aug 13, 2018
83e8fbc
PCHR-4072: Updated the link as stated in ticket description
ajesamson Aug 14, 2018
11ecf68
PCHR-4110: Fix calendar feeds leave requests inclusion logic
igorpavlov Aug 14, 2018
bdd8389
Merge pull request #2823 from compucorp/PCHR-4110-fix-calendar-feeds-…
igorpavlov Aug 15, 2018
a49c561
Merge pull request #2822 from compucorp/PCHR-4072-update-help-link-to…
ajesamson Aug 15, 2018
dfefd13
PCHR-4046: (root) Auto fixes with npm audit fix
Aug 15, 2018
60c0821
PCHR-4046: Remove unused package.json for hrui
Aug 15, 2018
d6e60e6
PCHR-4046: Update to gulp4 in bootstrapcivihr
Aug 16, 2018
a4542f7
PCHR-4046: Update civihr.css
Aug 16, 2018
34faa0b
PCHR-4046: (reqangular) Auto fixes with npm audit fix
Aug 16, 2018
1b0f59f
PCHR-4046: (reqangular) Update to gulp4
Aug 16, 2018
fe2333e
PCHR-3797: Improve apply core fork patch script to avoid api rate lim…
ajesamson Aug 16, 2018
6adc98a
PCHR-4046: Remove added trailing slash from gulp-angular-templatecach…
Aug 16, 2018
f1e7db8
PCHR-4046: (L&A) Update to gulp4
Aug 16, 2018
61b2e66
PCHR-4046: (hrcore) Auto fixes with npm audit fix
Aug 16, 2018
0e36c18
PCHR-4046: (hrcore) Use gulp-sass-glob
Aug 16, 2018
d71cbe7
PCHR-4046: (hrcore) Update to karma v3
Aug 16, 2018
698d5d1
PCHR-4046: Update L&A min css file
Aug 16, 2018
a88b5f0
PCHR-3797: Changed last commit patched file update to use API
ajesamson Aug 16, 2018
af749c7
PCHR-4046: (hremails) Auto fixes with npm audit fix
Aug 17, 2018
a2de5e1
Merge pull request #2827 from compucorp/PCHR-3797-improve-apply-core-…
ajesamson Aug 17, 2018
5660247
PCHR-4046: (bootstrapcivihr) Fix glob patterns
Aug 17, 2018
fdd5866
Merge pull request #2828 from compucorp/PCHR-4046-fix-security-vulner…
AkA84 Aug 17, 2018
e890bc2
PCHR-4116: Bump version to 1.7.10
davialexandre Aug 20, 2018
2e38090
Merge pull request #2831 from compucorp/PCHR-4116-bump-version
davialexandre Aug 20, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@ def testJS(hrcoreFolder, java.util.LinkedHashMap extension) {
// workspace, where Jenkins will read it
sh """
cd $CIVICRM_EXT_ROOT/civihr/${hrcoreFolder}
gulp test --ext ${extension.folder} --reporters junit,progress || true
npx gulp test --ext ${extension.folder} --reporters junit,progress || true
cd $CIVICRM_EXT_ROOT/civihr/${extension.folder}
mv test-reports/*.xml $WORKSPACE/$KARMA_TESTS_REPORT_FOLDER/ || true
Expand Down
5 changes: 3 additions & 2 deletions bin/apply-core-fork-patch.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
set -e

API_URL_BASE="https://api.github.com/repos/compucorp/civicrm-core"
REPO_BASE_URL="https://github.com/compucorp/civicrm-core"
LAST_COMMIT_PATCHED_FILE="core-fork-last-commit-patched.txt"
PATCH_FILE="fork-patch.diff"

Expand All @@ -27,7 +28,7 @@ applyPatch () {
# Creates a diff patch file by sending a request to the given GitHub API url
#
# Globals:
# $API_URL_BASE
# $REPO_BASE_URL
# $civiRoot
# $PATCH_FILE
# Arguments:
Expand All @@ -37,7 +38,7 @@ applyPatch () {
# None
#######################################
createPatch () {
curl "$API_URL_BASE/compare/$1...$2" -s -H "Accept: application/vnd.github.v3.diff" > "$civiRoot/$PATCH_FILE"
curl "$REPO_BASE_URL/compare/$1...$2.diff" -s > "$civiRoot/$PATCH_FILE"
}

#######################################
Expand Down
1 change: 0 additions & 1 deletion bin/drush-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ uk.co.compucorp.civicrm.hremails
## List of extensions defining basic entity types
ENTITY_EXTS=\
org.civicrm.hrbank,\
org.civicrm.hrdemog,\
org.civicrm.hrjobcontract,\
com.civicrm.hrjobroles,\
org.civicrm.hrmed,\
Expand Down
1 change: 0 additions & 1 deletion bin/git-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ fileName=""
ENTITY_EXTS=( hrbank \
hrcareer \
hrcase \
hrdemog \
hrim \
hrmed \
hrprofile \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -126,9 +126,14 @@ private function addJoins(CRM_Utils_SQL_Select $query) {
private function addWhere(CRM_Utils_SQL_Select $customQuery) {
if (!empty($this->params['contact_id'])) {
$conditions[] = 'jc.contact_id IN (' . implode(',' , $this->params['contact_id']) . ')';
$customQuery->where($conditions);
unset($this->params['contact_id']);
}

$today = date('Y-m-d H:i:s');
$dateRestriction = 'a.start_date <= "' . $today . '"';
$dateRestriction .= ' AND (a.end_date >= "' . $today . '" OR a.end_date IS NULL)';
$conditions[] = $dateRestriction;
$customQuery->where($conditions);
}

/**
Expand Down
39 changes: 31 additions & 8 deletions com.civicrm.hrjobroles/CRM/Hrjobroles/BAO/Query.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,15 +70,26 @@ public function from($name, $mode, $side) {
}

public function where(&$query) {
$grouping = NULL;
foreach ($query->_params as $param) {
if ($this->isAJobRoleParam($param)) {
if ($query->_mode == CRM_Contact_BAO_QUERY::MODE_CONTACTS) {
$query->_useDistinct = TRUE;
}
$this->whereClauseSingle($param, $query);
}
$grouping = NULL;
$filterJobRoleByDate = $filterJobRole = FALSE;
foreach ($query->_params as $param) {
if ($this->isAJobRoleParam($param)) {
$filterJobRole = TRUE;
$paramHasDate = strpos($param[0], 'date');
if (!$filterJobRoleByDate && $paramHasDate) {
$filterJobRoleByDate = TRUE;
}

if ($query->_mode == CRM_Contact_BAO_QUERY::MODE_CONTACTS) {
$query->_useDistinct = TRUE;
}

$this->whereClauseSingle($param, $query);
}
}
if (!$filterJobRoleByDate && $filterJobRole) {
$this->applyJobRoleDateFiltering($query);
}
}

private function isAJobRoleParam($param) {
Expand All @@ -90,6 +101,18 @@ private function isAJobRoleParam($param) {
return false;
}

/**
* Applies date filtering for active job roles
*
* @param CRM_Contact_BAO_Query $query
*/
private function applyJobRoleDateFiltering(&$query) {
$today = date('Y-m-d H:i:s');
$dateRestriction = 'civicrm_hrjobroles.start_date <= "' . $today . '"';
$dateRestriction .= ' AND (civicrm_hrjobroles.end_date >= "' . $today . '" OR civicrm_hrjobroles.end_date IS NULL)';
$query->_where[] = [$dateRestriction];
}

private function whereClauseSingle($values, &$query) {
list($name, $op, $value, $grouping, $wildcard) = $values;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ class CRM_Hrjobroles_Test_Fabricator_HrJobRoles {
* @throws \Exception
*/
public static function fabricate($params) {
if (empty($params['start_date'])) {
$params['start_date'] = date('Y-m-d H:i:s');
}

$result = civicrm_api3(
'HrJobRoles',
'create',
Expand Down
4 changes: 2 additions & 2 deletions com.civicrm.hrjobroles/info.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
<author>Compucorp Ltd</author>
<email>info@compucorp.co.uk</email>
</maintainer>
<releaseDate>2018-07-24</releaseDate>
<version>1.7.9</version>
<releaseDate>2018-08-20</releaseDate>
<version>1.7.10</version>
<develStage>stable</develStage>
<compatibility>
<ver>4.7</ver>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,9 @@ public function testTheGetActionReturnsMultipleJobRoles() {
$contact2 = ContactFabricator::fabricate();
$contract1 = HRJobContractFabricator::fabricate(['contact_id' => $contact1['id']]);
$contract2 = HRJobContractFabricator::fabricate(['contact_id' => $contact2['id']]);
$jobRole1 = HRJobRolesFabricator::fabricate(['job_contract_id' => $contract1['id'],]);
$jobRole2 = HRJobRolesFabricator::fabricate(['job_contract_id' => $contract1['id'],]);
$jobRole3 = HRJobRolesFabricator::fabricate(['job_contract_id' => $contract2['id'],]);
$jobRole1 = HRJobRolesFabricator::fabricate(['job_contract_id' => $contract1['id']]);
$jobRole2 = HRJobRolesFabricator::fabricate(['job_contract_id' => $contract1['id']]);
$jobRole3 = HRJobRolesFabricator::fabricate(['job_contract_id' => $contract2['id']]);

$contactJobRoles = civicrm_api3($this->entity, $this->action)['values'];

Expand Down
4 changes: 2 additions & 2 deletions contactaccessrights/info.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
<author>Compucorp Ltd</author>
<email>info@compucorp.co.uk</email>
</maintainer>
<releaseDate>2018-07-24</releaseDate>
<version>1.7.9</version>
<releaseDate>2018-08-20</releaseDate>
<version>1.7.10</version>
<develStage>stable</develStage>
<compatibility>
<ver>4.7</ver>
Expand Down
2 changes: 1 addition & 1 deletion contactaccessrights/js/dist/access-rights.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions contactsummary/info.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
<author>Compucorp Ltd</author>
<email>info@compucorp.co.uk</email>
</maintainer>
<releaseDate>2018-07-24</releaseDate>
<version>1.7.9</version>
<releaseDate>2018-08-20</releaseDate>
<version>1.7.10</version>
<develStage>stable</develStage>
<compatibility>
<ver>4.7</ver>
Expand Down
4 changes: 2 additions & 2 deletions contactsummary/js/dist/contact-summary.min.js

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ define([
var $httpBackend, $rootScope, $q, contractServiceMock, controller, ctrlConstructor,
jobRoleServiceMock, pubSub;

beforeEach(module('contactsummary', 'contactsummary.mocks'));
beforeEach(module('contactsummary', 'contactsummary.mocks', 'contact-summary.templates'));

beforeEach(module(function ($provide) {
$provide.factory('contractService', function () {
Expand Down
4 changes: 2 additions & 2 deletions hrbank/info.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
<author>CiviCRM LLC</author>
<email>info@civicrm.org</email>
</maintainer>
<releaseDate>2018-07-24</releaseDate>
<version>1.7.9</version>
<releaseDate>2018-08-20</releaseDate>
<version>1.7.10</version>
<develStage>stable</develStage>
<compatibility>
<ver>4.7</ver>
Expand Down
2 changes: 1 addition & 1 deletion hrcareer/hrcareer.php
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,6 @@ function hrcareer_civicrm_pageRun($page) {
->addScriptFile('civicrm', 'js/jquery/jquery.crmRevisionLink.js', CRM_Core_Resources::DEFAULT_WEIGHT, 'html-header');

CRM_Core_Resources::singleton()
->addScriptFile('org.civicrm.hrcareer', 'js/hrcareer.js');
->addScriptFile('org.civicrm.hrcareer', 'js/dist/hrcareer.min.js', 1010);
}
}
Loading