Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Error checking for Clear Activity, Empty screen now shows message

  • Loading branch information...
commit 8a1906e99d9183ef642802cf6b637c9196155d1c 1 parent 67defc8
@stefancrain stefancrain authored
View
4 civicrm/custom/php/CRM/IMAP/AJAX.php
@@ -939,12 +939,12 @@ public static function unproccessedActivity() {
if(!$error){
- $returnCode = array('code'=>'SUCCESS','id'=>$id, 'message'=>'Activity Deleted');
+ $returnCode = array('code'=>'SUCCESS','id'=>$id, 'message'=>'Activity Cleared');
}else{
$returnCode = array('code'=>'ERROR','status'=> '1','message'=>'Activity not found');
}
- echo json_encode($result);
+ echo json_encode($returnCode);
mysql_close(self::$db);
CRM_Utils_System::civiExit();
View
5 modules/nyss_imapper/nyss_imapper.js
@@ -228,6 +228,7 @@ cj(document).ready(function(){
});
if(cj("#Activities").length){
+
pullActivitiesHeaders();
autocomplete_setup();
}else if(cj("#Unmatched").length){
@@ -888,7 +889,7 @@ function checks(){
}
function buildMessageList() {
- if(messages == '' || messages == null){
+ if(messages.count == '0' || messages == null){
cj('#imapper-messages-list').html('<strong>No Messages found</strong>');
cj("#total_number").html('0');
}else{
@@ -944,7 +945,7 @@ function buildMessageList() {
// matched messages screen
function buildActivitiesList() {
- if(messages == '' || messages == null){
+ if(messages.count == '0' || messages == null){
cj('#imapper-messages-list').html('<strong>No Messages found</strong>');
cj("#total_number").html('0');
}else{
Please sign in to comment.
Something went wrong with that request. Please try again.