projects
/
civicrm-core.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
10ffff2
)
CRM-14789 - crmCaseType - Pass through more specific error
author
Tim Otten
<totten@civicrm.org>
Mon, 14 Jul 2014 06:17:12 +0000
(23:17 -0700)
committer
Tim Otten
<totten@civicrm.org>
Mon, 14 Jul 2014 06:18:23 +0000
(23:18 -0700)
js/angular-crmCaseType.js
patch
|
blob
|
blame
|
history
diff --git
a/js/angular-crmCaseType.js
b/js/angular-crmCaseType.js
index 131dd62f8767c75354c09ab88bf5c01988a0df1f..8f579356b1ea7bde5d2e85f080814a62b97918c9 100644
(file)
--- a/
js/angular-crmCaseType.js
+++ b/
js/angular-crmCaseType.js
@@
-295,7
+295,11
@@
});
};
$scope.deleteCaseType = function (caseType) {
- crmApi('CaseType', 'delete', {id: caseType.id}, true)
+ crmApi('CaseType', 'delete', {id: caseType.id}, {
+ error: function (data) {
+ CRM.alert(data.error_message, ts('Error'));
+ }
+ })
.then(function (data) {
if (!data.is_error) {
delete caseTypes.values[caseType.id];