From 65d3e04c91fec363c19effc2cb5232855bb712d2 Mon Sep 17 00:00:00 2001 From: Tim Otten Date: Thu, 9 Apr 2015 17:29:36 -0700 Subject: [PATCH] CRM-16253 - crmUiRichtext - Enable file uploads --- ang/crmUi.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/ang/crmUi.js b/ang/crmUi.js index b83ad4c50d..de2e078246 100644 --- a/ang/crmUi.js +++ b/ang/crmUi.js @@ -393,6 +393,19 @@ link: function (scope, elm, attr, ngModel) { var ck = CKEDITOR.replace(elm[0]); + if (ck) { + _.extend(ck.config, { + width: '94%', + height: '400', + filebrowserBrowseUrl: CRM.crmUi.browseUrl + '?cms=civicrm&type=files', + filebrowserImageBrowseUrl: CRM.crmUi.browseUrl + '?cms=civicrm&type=images', + filebrowserFlashBrowseUrl: CRM.crmUi.browseUrl + '?cms=civicrm&type=flash', + filebrowserUploadUrl: CRM.crmUi.uploadUrl + '?cms=civicrm&type=files', + filebrowserImageUploadUrl: CRM.crmUi.uploadUrl + '?cms=civicrm&type=images', + filebrowserFlashUploadUrl: CRM.crmUi.uploadUrl + '?cms=civicrm&type=flash', + }); + } + if (!ngModel) { return; } -- 2.25.1