From: Tim Otten Date: Tue, 12 Aug 2014 09:22:19 +0000 (-0700) Subject: CRM-14798 - Allow editing case-type names even if malformed X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=f42b448f6c1b08c86f0c568612b26fe0941504d8;p=civicrm-core.git CRM-14798 - Allow editing case-type names even if malformed This is a follow-up to #3820 --- diff --git a/js/angular-crmCaseType.js b/js/angular-crmCaseType.js index 8f579356b1..fa68c64bf6 100644 --- a/js/angular-crmCaseType.js +++ b/js/angular-crmCaseType.js @@ -228,6 +228,10 @@ } }; + $scope.isValidName = function(name) { + return !name || name.match(/^[a-zA-Z0-9_]+$/); + }; + $scope.getWorkflowName = function(activitySet) { var result = 'Unknown'; _.each($scope.workflows, function(value, key) { diff --git a/partials/crmCaseType/caseTypeDetails.html b/partials/crmCaseType/caseTypeDetails.html index 8e84a39452..3a24b86ee8 100644 --- a/partials/crmCaseType/caseTypeDetails.html +++ b/partials/crmCaseType/caseTypeDetails.html @@ -34,12 +34,14 @@ The original form used table layout; don't know if we have an alternative, CSS-b name="caseTypeName" ng-model="caseType.name" ng-disabled="locks.caseTypeName" - ng-pattern="/^[a-zA-Z0-9_]+$/" required class="big crm-form-text"/> +
+ WARNING: The case type name includes deprecated characters. +
WARNING: If any external files or programs reference the old "Name", then they must be updated manually.