-
Notifications
You must be signed in to change notification settings - Fork 443
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
PersonView, FamilyView ui changes #1863 #2026
Conversation
closes ChurchCRM#1863 changed overlay, added view photo button. added modal for displaying larger photo, displaying view photo button, using code from Initials.js if photo exists.
src/FamilyView.php
Outdated
@@ -909,6 +912,22 @@ class="fa fa-cart-plus"></i> <?= gettext("Add All Family Members to Cart") ?></a | |||
|
|||
<!-- Modal --> | |||
<div id="photoUploader"></div> | |||
|
|||
<div id="view-image" class="modal fade" tabindex="-1" role="dialog"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Adnan0703 please switch to the new model system
src/PersonView.php
Outdated
|
||
$.ajax({ | ||
method :"HEAD", | ||
url: window.CRM.root + "/api/persons/<?= $iPersonID ?>/photo", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you can use familyId
and move it to familyview.js
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
personview.php and familyview.php uses the same code. familyview.js isn't used in personview.
how about making it a function and saving in utils.js?
function fileExists(fileUrl, func) {
$.ajax({
method :"HEAD",
url: fileUrl,
processData: false,
global:false,
success: function(data, textStatus, jqXHR){
func(true, data, textStatus, jqXHR);
},
error: function(jqXHR, textStatus, errorThrown) {
func(false, jqXHR, textStatus, errorThrown);
}
});
}
fileExists(url, function(success) {
if (success) {
$("#view-larger-image-btn").removeClass('hide');
}
});
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes you can call it MemberView.js and have it called by both
please make sure you branch and merge to Develop unless it is prod P0 bug fix |
@DawoudIO |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll do some testing tonight but this is the requested code changes
src/FamilyView.php
Outdated
success: function(d){ | ||
$("#view-larger-image-btn").removeClass('hide'); | ||
}, | ||
error: function(event) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if you are going to leave it blank, then remove this code
src/PersonView.php
Outdated
|
||
$.ajax({ | ||
method :"HEAD", | ||
url: window.CRM.root + "/api/persons/<?= $iPersonID ?>/photo", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes you can call it MemberView.js and have it called by both
src/PersonView.php
Outdated
success: function(d){ | ||
$("#view-larger-image-btn").removeClass('hide'); | ||
}, | ||
error: function(event) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same
@DawoudIO It's ready for review. |
* Updated Default Values * added select2 * using memeber default & select 2 for country using memeber default city/state & select 2 * Apply fixes from StyleCI (#1995) * Add Behat testing (#2010) * underp master vs develop merge * underps * start 2.6.1 (#2034) * start 2.6.1 * underp 2.6.1 upgrade. * don't include unreleased features in the changelog * 2.6.1 rev jquery photo uploader (#2035) * start 2.6.1 * underp 2.6.1 upgrade. * rev photo uploader to 1.0.10 * release window documentation (#2055) * release window doc * release window doc * cherry-pick #2061 for Master 2.6.1 * Update Config.php.example * fix broken search * rev photo uploader to 1.0.11 (#2071) * Member Count Error in Member Dashboard (#1925) * fix membercount error fix #1924 * Apply left join onn family wher join with person to get the members without family accounted. * Also added Links to Family Roles section on membersdashboard. * Changes to use SystemConfig using SystemConfig::getValue('sDirRoleChild') * PersonView, FamilyView ui changes #1863 (#2026) * PersonView, FamilyView ui changes #1863 closes #1863 changed overlay, added view photo button. added modal for displaying larger photo, displaying view photo button, using code from Initials.js if photo exists. * addressing review comments * upgrade
* Updated Default Values * added select2 * using memeber default & select 2 for country using memeber default city/state & select 2 * Apply fixes from StyleCI (#1995) * Add Behat testing (#2010) * underp master vs develop merge * underps * start 2.6.1 (#2034) * start 2.6.1 * underp 2.6.1 upgrade. * don't include unreleased features in the changelog * 2.6.1 rev jquery photo uploader (#2035) * start 2.6.1 * underp 2.6.1 upgrade. * rev photo uploader to 1.0.10 * release window documentation (#2055) * release window doc * release window doc * cherry-pick #2061 for Master 2.6.1 * Update Config.php.example * fix broken search * rev photo uploader to 1.0.11 (#2071) * Member Count Error in Member Dashboard (#1925) * fix membercount error fix #1924 * Apply left join onn family wher join with person to get the members without family accounted. * Also added Links to Family Roles section on membersdashboard. * Changes to use SystemConfig using SystemConfig::getValue('sDirRoleChild') * PersonView, FamilyView ui changes #1863 (#2026) * PersonView, FamilyView ui changes #1863 closes #1863 changed overlay, added view photo button. added modal for displaying larger photo, displaying view photo button, using code from Initials.js if photo exists. * addressing review comments * UI Cleanup/bugs closes #2084 #2112 * UI Improvments closes #2112 * Apply fixes from StyleCI (#2113) * Fix database backup (#2118) * closes #2099 * Apply fixes from StyleCI * using github-release-notes in the bash script renamed the npm target updated changeslog.md * updated steps and included changelog task * Cash is displayed even if 0 #1852 (#1983) * resolves #1852 * still show 0 cash if 0 cash 💯 * applied styleci patch * Remove old changelog * start 2.6.2 (#2125) * this works on ASO demo site. (#2126) * #2121-unable to create event (#2122) add document ready function around the dateranger script. fixes #2121 * start 2.6.3 (#2127) * 2.6.3 * update changelog * Update CHANGELOG.md removed dbl logs * Feature/2124 notification bar (#2167) * Working POC * Fix styles * get data from web service * Apply fixes from StyleCI * allow for differentating admin vs all user notifications * add TTL setting for notifications * don't include system notifications locally * cleanup * underp boolean call * address comments - handle exceptions correctly * fix logic if captive portal intercepts notification request * cleanup spaces * make code work again.
* Updated Default Values * added select2 * using memeber default & select 2 for country using memeber default city/state & select 2 * Apply fixes from StyleCI (#1995) * Add Behat testing (#2010) * underp master vs develop merge * underps * start 2.6.1 (#2034) * start 2.6.1 * underp 2.6.1 upgrade. * don't include unreleased features in the changelog * 2.6.1 rev jquery photo uploader (#2035) * start 2.6.1 * underp 2.6.1 upgrade. * rev photo uploader to 1.0.10 * release window documentation (#2055) * release window doc * release window doc * cherry-pick #2061 for Master 2.6.1 * Update Config.php.example * fix broken search * rev photo uploader to 1.0.11 (#2071) * Member Count Error in Member Dashboard (#1925) * fix membercount error fix #1924 * Apply left join onn family wher join with person to get the members without family accounted. * Also added Links to Family Roles section on membersdashboard. * Changes to use SystemConfig using SystemConfig::getValue('sDirRoleChild') * PersonView, FamilyView ui changes #1863 (#2026) * PersonView, FamilyView ui changes #1863 closes #1863 changed overlay, added view photo button. added modal for displaying larger photo, displaying view photo button, using code from Initials.js if photo exists. * addressing review comments * UI Cleanup/bugs closes #2084 #2112 * UI Improvments closes #2112 * Apply fixes from StyleCI (#2113) * Fix database backup (#2118) * closes #2099 * Apply fixes from StyleCI * using github-release-notes in the bash script renamed the npm target updated changeslog.md * updated steps and included changelog task * Cash is displayed even if 0 #1852 (#1983) * resolves #1852 * still show 0 cash if 0 cash 💯 * applied styleci patch * Remove old changelog * start 2.6.2 (#2125) * this works on ASO demo site. (#2126) * #2121-unable to create event (#2122) add document ready function around the dateranger script. fixes #2121 * start 2.6.3 (#2127) * 2.6.3 * update changelog * Update CHANGELOG.md removed dbl logs * Feature/2124 notification bar (#2167) * Working POC * Fix styles * get data from web service * Apply fixes from StyleCI * allow for differentating admin vs all user notifications * add TTL setting for notifications * don't include system notifications locally * cleanup * underp boolean call * address comments - handle exceptions correctly * fix logic if captive portal intercepts notification request * rev jQuery-photo-uploader (#2185) * closes #2123 (#2184) * update changelog (#2190) * update changelog * 2.6.3 * locked to 0.6.3 * locked to 0.6.3 * Update CHANGELOG.md trim down to subset of changes * Add Behat tests to TravisCI (#2011) * underp master vs develop merge * underps * add test to travis * add apache to travis. * tweaks * change path * move to script. troubleshooting. * debugging * debugging * fix path * fix path * tweaks * tweaks * underp * tweaks * tweaks * tweaks * tweaks * tweaks * tweaks * tweaks * tweaks * tweaks * tweaks * tweaks * move fpm conf * tweak * tweak * tweak * tweak * fingers crossed. * fingers crossed. * fingers crossed. * debug * tweak paths * tweak config * tweak config * permissions * permissions * tweaks * tweaks * tweaks * tweaks * tweaks * tweaks * tweaks * add config * tweaks * tweaks * revert login changes * change index * cleanup * underp php fpm * underp * rewrite? * rewrite? * SetHandler * use sockets * derppp * derppp * derppp sockets * derppp sockets * derppp sockets * proxy? * test? * tweaks? try again? * Important! Read the above again https://wiki.apache.org/httpd/PHP-FPM * tweak multi view * cleanup * Update Config.php * Update README.md (#2247) * added ignore question
closes #1863
changed overlay, added view photo button. added modal for displaying
larger photo, displaying view photo button (using code from Initials.js)
if photo exists.