Commit Graph

420 Commits

Author SHA1 Message Date
Ralf Becker
19fc7acb7f top.egw is a function not an object 2014-05-13 08:48:27 +00:00
Ralf Becker
ac220a6e82 using egw.is_popup() which deals with situation of egw main-window having an opener (eg. bookmark) 2014-05-13 06:44:50 +00:00
Nathan Gray
9a8182480f Stop popups from re-initializing sidebox. Fixes favorites causing whole application to reload after saving a popup. 2014-05-12 20:36:18 +00:00
Ralf Becker
194606b196 public method to translate between PHP and jQuery date(Time)Picker date/time-format 2014-05-08 15:57:07 +00:00
Ralf Becker
b111f5005b fixed select-accounts show only part of users, caused by previously trying to extend now used array 2014-05-07 15:51:45 +00:00
Nathan Gray
140a0746d1 Make sure top actually has app before calling it.
Fixes error in calendar where non-list views are still in an iframe, but top window has no app.js
2014-04-30 16:25:05 +00:00
Nathan Gray
4d016169e7 Precautions for iframes + sidebox
- Unbind any existing events on existing sidebox, if _init_sidebox() is called again
- Only call _init_sidebox() on top-level window's app.js, fixes some iframe issues with admin
2014-04-29 16:51:57 +00:00
Nathan Gray
5c19f99d9d Remove no longer needed AJAX call for groups, API now provides them directly to the widget 2014-04-29 16:15:23 +00:00
Nathan Gray
21e5eb79dd Fix bug where if no additional apps were requested, no translation was done.
Was visible in ACL edit dialog.
2014-04-28 16:17:41 +00:00
Hadi Nategh
c912849bd5 Apply favorites sortable feature to sidebox fav. menu 2014-04-25 07:37:11 +00:00
Nathan Gray
48fa6611f3 Use a single client-side cache for account selection so we don't have to send it for every widget 2014-04-23 19:00:59 +00:00
Ralf Becker
554789e9ff 2 new message types "help" and "info" and displaying now all message types but "success" until next message or user explicitly closes them 2014-04-02 19:02:49 +00:00
Ralf Becker
6fdf8c98d1 open preferences and ACL in a popup (ACL still needs a little more work: use et2_dialog to add/edit instead of an other popup) 2014-04-01 15:49:08 +00:00
Ralf Becker
d28583a3a4 fix Array has no method match, if egw_framework::message() is called in GET request 2014-04-01 14:16:11 +00:00
Ralf Becker
13ad291696 need to init apps too 2014-03-28 13:15:11 +00:00
Ralf Becker
115aabf21a fixed error because using (by loading order sometimes) uninitialised class-variable instead of documented and initialies private var 2014-03-28 08:06:30 +00:00
Nathan Gray
e7fd500006 Store the jQuery jqXHR request object in the json_request, and return it from sendRequest() so caller can access it, if needed. 2014-03-26 17:53:09 +00:00
Ralf Becker
a4b27d286d * FireFox/all apps: fixed in recent FF version popups opened always in a single popup (overwritting previous opened one) 2014-03-26 10:32:17 +00:00
Ralf Becker
7d7436e54b fixed javascript errors happening if config was not loaded 2014-03-25 12:23:06 +00:00
Ralf Becker
ac18b6cc8d changed et2_core_inheritance.js to implement ClassWithAttributes extending Class from egw_inheritance and changed et2 objects to use ClassWithAttributes when required (also fixed lots of IDE warnings / added docu) 2014-03-20 09:40:37 +00:00
Nathan Gray
aa3c0ca7c0 Pass along last modification time to callback 2014-03-18 22:28:50 +00:00
Ralf Becker
f47e38f320 wrong window was used when compiling list of already included scripts or css files, fixes missing css styles for context menu in popups (list of links) 2014-03-13 15:28:42 +00:00
Ralf Becker
2a34b88111 fixed not working referesh of ACL list 2014-03-12 13:14:23 +00:00
Ralf Becker
086195c0aa stop event propagation after calling setState, fixes "double sidebox" in CRM view, if called via a favorite (caused 2 identical requests to server, which both added their sidebox) 2014-03-11 08:16:52 +00:00
Hadi Nategh
96a6a7ee1a Adjust width for resized popup windows, since we are trying to use fix width for edit popups 2014-03-10 16:04:01 +00:00
Ralf Becker
79e1b5c9b8 fixed CSP error for multiple eTemplate2s (CRM view), by allways sending etemplate data via et2_container tag (instead etemplate script tag) and create an et2 object for all of them in egw.js 2014-03-10 11:58:49 +00:00
Nathan Gray
e9b5dfde4d Bind key handler to save favorite on Enter 2014-03-03 18:51:58 +00:00
Ralf Becker
11d77f3dab fixed a couple of problems with automatic switch to idots template from mobile browsers: csp-error, wrong icons 2014-03-03 17:35:48 +00:00
Ralf Becker
1ae9925cd5 removed .on("mouse(enter|leave)" (wrapping trash icon), as it stalls delete of favorites in IE11 2014-02-26 15:44:00 +00:00
Ralf Becker
b4a0a18de6 fixing wired IE11 errors ... 2014-02-25 17:16:42 +00:00
Ralf Becker
81818d2bbd fixing wired IE errors: need to clone data in set_preferences, as it gets cleaned up in IE 2014-02-25 17:05:16 +00:00
Nathan Gray
4591fa6e21 Fix TypeError: Cannot call method 'css' of undefined
Fixes blank infolog popup, timesheet index
2014-02-25 16:31:06 +00:00
Ralf Becker
e5aa97e2a0 fix IDE warnings 2014-02-25 16:03:12 +00:00
Ralf Becker
8181772025 do NOT initialise imediatly, as DOM is not yet ready (at least in IE11) 2014-02-25 16:02:46 +00:00
Ralf Becker
308dfdadc7 allow to already use egw.refresh() instead of egw_refresh() and added todo to move code 2014-02-25 09:46:05 +00:00
Ralf Becker
2f3add4ce9 hook to allow apps to add addional domains to CSP frame-src, eg. used by sitemgr to allow access to its sites, also fixed not displayed sidebox menu of old apps 2014-02-21 17:06:11 +00:00
Ralf Becker
796663c2a6 fixed modified translations were not automatic loaded after new login 2014-02-21 11:10:11 +00:00
Ralf Becker
530ebec63f fixed not translated time-labels in datetime picker 2014-02-19 16:40:56 +00:00
Ralf Becker
b692346cce several IE11 fixes avoiding or working around javascript errors 2014-02-19 15:10:39 +00:00
Ralf Becker
bd941f3601 allow to send a redirect from server-side via client-side egw.link_handler(url, app) allowing to specify which tab to use and a top-level (ajax=true) url 2014-02-19 15:08:38 +00:00
Ralf Becker
668bec020b fix display and logging of javascript errors for IE 2014-02-18 17:05:26 +00:00
Ralf Becker
186bdbcb55 running categories and acl in iframe again. If they run top-level their admin/js/app.js objects conflict with other top-level admin/js/app.js object and only one working categories or acl tab can be opened 2014-02-17 15:11:26 +00:00
Ralf Becker
d01d5119ca calling app[appname].et2_ready(et2,name) with template name as second parameter 2014-02-17 14:58:20 +00:00
Ralf Becker
0fa215c9e8 fixed sometimes not deletable favorites 2014-02-14 12:46:49 +00:00
Nathan Gray
bad65780bc Register a JSON handler to show error responses as error message instead of losing them. 2014-02-13 18:47:19 +00:00
Ralf Becker
af1e70ab32 fixed javascript error, if favorite has no href AND make sure all new favorites are created with an href, like they are created server-side 2014-02-13 16:50:49 +00:00
Ralf Becker
3a5ece79a7 fixed creating or deleting favorites in calendar does not work: was caused by sidebox not initialised as not yet loaded, now calling _init_sidebox from framework, also need to add a click handler for favorites as initialising sidebox removes one installed from template 2014-02-13 15:37:49 +00:00
Ralf Becker
f0d7751496 removed caret from group favorites, fixed prefered favorite was not show correct initialy nor updated 2014-02-12 21:51:25 +00:00
Ralf Becker
4a7c0204a0 fixed just added favorite can NOT be used as default for dropdown button (gave alert "No default set") 2014-02-12 20:55:10 +00:00
Ralf Becker
75316761b2 added FF name 2014-02-12 18:40:01 +00:00
Nathan Gray
1ca01da9b0 Fix missing group ID when deleting group favorites, fixes unable to delete group favorites 2014-02-12 17:33:22 +00:00
Ralf Becker
17b8bfcc95 fixed javascript error "max is undefined" 2014-02-12 16:36:51 +00:00
Ralf Becker
22b66c9e3d fix javascript error when clicking on a group favorite (state.state is undefined) 2014-02-12 11:23:04 +00:00
Ralf Becker
3ec6ffe264 deal with situation that storage quota on html5 localstorage is exceeded:
- browser/user can limit quota, we then get an exception which must NOT stall EGroupware!
- we set a smaller MAX_LOGS of 200 instead of current 1000
- if currently more log items stored OR if exception.name=="QuotaExceededError" we clear whole log (trying to clear old limit of 1000 messages)
2014-02-12 10:38:39 +00:00
Ralf Becker
ea9e2569bc fixed not working multiple account trigger after changing html::submit_button() from <input type="submit" to <button 2014-02-11 16:42:02 +00:00
Ralf Becker
a639b42222 translate calendar/timepicker on demand, works around not working call with ready in popup, fixes javascript error when doubleclick a mail 2014-02-11 15:17:43 +00:00
Ralf Becker
195c63a9d3 fixed "undefined is not a function" error originating from egw_message, because jQuery not loaded, when egw_message get initialised 2014-02-10 16:10:01 +00:00
Ralf Becker
9bfc082843 fix not opening infolog popup 2014-02-10 11:49:27 +00:00
Ralf Becker
061a1a07f2 fixed popup detection to deal with main EGw window opened with an opener from a different security context, also made is_popup() a global egw method 2014-02-10 11:21:58 +00:00
Ralf Becker
12666f0f53 fiddeling around with re-throwing event caught by global error-handler 2014-02-10 09:18:08 +00:00
Ralf Becker
1f599abaf6 fix exception for not found image / null passed 2014-02-10 09:16:18 +00:00
Ralf Becker
ca334ad13b moving egw_preferences (handler to call preferenes, acl or categories) from jsapi.js to egw_preferences.js show_preferences() method 2014-02-07 14:04:12 +00:00
Ralf Becker
d90faa7dcc fixed app-header show in wrong tab, caused by framework object being created AFTER egw 2014-02-07 09:11:30 +00:00
Nathan Gray
444d82d1c7 -Unencode favorite search, firefox leaves encoded spaces
-If adding a favorite with same name as existing favorite, old one is removed from the sidebox.
2014-02-06 17:53:29 +00:00
Ralf Becker
b13a7eefb8 calling egw.message() without or with empty argument clears message, installed click handler to hide message and also check for translation of "error" to determine unspecified type 2014-02-06 17:24:40 +00:00
Ralf Becker
6a8802fc35 move egw_(message|app_header) from jsapi.js to egw_message.js available as egw(window).message(_msg, _type) and make it usable in popups too 2014-02-06 15:42:33 +00:00
Nathan Gray
1cb3ac1111 Fix groups in add favorite popup:
- missing options for selectbox
 - saving for group wouldn't work
2014-02-06 00:30:03 +00:00
Nathan Gray
2ece0f771f Use ajax flag to load acl into div, not iframe 2014-02-05 22:39:00 +00:00
Nathan Gray
c771f2fc80 Make sure group is there before trying to set its value 2014-02-05 20:53:08 +00:00
Ralf Becker
4c2e29f960 more styling of calendar edit 2014-02-05 10:04:13 +00:00
Ralf Becker
b8aa28c055 fixed error if argument was a widget, using jQuery.extend instead not existing clone() 2014-02-03 09:59:30 +00:00
Ralf Becker
a659b49f51 silently fix skiped minutes or times with just one digit, as parser is quite pedantic ;-) 2014-01-29 13:10:31 +00:00
Hadi Nategh
fbccbb87a3 Fix wrong styling in egw_tail log 2014-01-28 08:33:28 +00:00
Ralf Becker
99ce5b41f9 allow to optionally specify app for redirect instead of always using current app 2014-01-27 16:28:39 +00:00
Hadi Nategh
ea20648d39 Remove inline-scripts from egw_tail. Additionally, add a new library to jsapi related to egw_tail 2014-01-27 14:29:24 +00:00
Ralf Becker
f0710fbecb fixed et2_dialog static methods like confirm did not show translations: injecting an egw object with loaded translations for current app 2014-01-23 10:52:44 +00:00
Ralf Becker
a788827c1e check if json apply needs a not yet instanciated app.js object and instanciate it in that case 2014-01-23 09:03:30 +00:00
Nathan Gray
e103145a53 Fix JSON to call callback even if server does not return anything in particular. 2014-01-22 09:30:22 +00:00
Ralf Becker
58e13743fc make local storage more robust (deal with gaps) 2014-01-21 15:09:06 +00:00
Ralf Becker
93ae56a9f2 catch exception about circular reference in JSON.stringify, try fixing object by unsetting _parent&_children and if that does not work the whole argument 2014-01-21 11:23:26 +00:00
Nathan Gray
95b51fefea Some UI for client error log, log egw.open() calls 2014-01-21 09:21:46 +00:00
Ralf Becker
658b773dc1 fixed an ide warning 2014-01-20 15:25:43 +00:00
Ralf Becker
595d2a23bf first step of a javascript error notifier and clientside log 2014-01-20 15:23:40 +00:00
Nathan Gray
e276a14be1 Make sure to copy registry settings, not use reference
Fixes mail compose always filling address
2014-01-20 09:48:17 +00:00
Ralf Becker
5a8b145b7f fixed caching in a couple of places:
- user.php was not reloaded if (session-)preferences changed eg. language via select-box in login, because we used Expires header, but did not force a different url
- (user|config|images).php now has etag on url, to force reload by browser as we use an Expires header (changed images still need Admin >> clear cache to rebuild image cache)
- preferences are now loaded via a cachable GET request
2014-01-18 17:43:15 +00:00
Ralf Becker
53c6059d84 fix en translation is always used for common, caused by preferences had a stub default preference for common AND egw.includeJS immediatly called callback for a file just sheduled to be loaded, but not yet arrived 2014-01-15 17:39:07 +00:00
Ralf Becker
0cc75cb3e6 need to strip egw-url from css includes, to not included css-files twice 2014-01-15 15:48:22 +00:00
Nathan Gray
6792b9831c Allow popups to set just a message without refreshing before closing 2014-01-15 14:40:42 +00:00
Ralf Becker
e265874bd7 new method to create object tag for svg and img for all other image types 2014-01-14 16:07:39 +00:00
Hadi Nategh
9dcc4cc00a Map mailto url params to right object in mailto magic function 2014-01-13 17:37:46 +00:00
Nathan Gray
71f0fcdda0 Implement refresh type 'update' to _only_ update the data of a row - sorting is not considered, so make sure to use 'edit' if sorting might be affected. 2014-01-13 09:40:23 +00:00
Nathan Gray
8228b9512d Fix type attribute check to work 2014-01-13 08:58:16 +00:00
Nathan Gray
8e69a1e23b Only call request callback once, when the request is finished.
Callback is not called if the response only has 'data' type responses, since data handler calls callback already.
2014-01-11 14:47:31 +00:00
Ralf Becker
ab490eadc1 extend egw.includeJS to support concatinated/bundled files included and not include contained files again 2014-01-11 12:10:31 +00:00
Nathan Gray
d94fc6b492 Fix not called callback 2014-01-11 11:41:05 +00:00
Nathan Gray
31987e9704 Check result type, if it's not 'data' quietly reject - fixes warning in multi-part responses 2014-01-11 11:40:30 +00:00
Nathan Gray
1742d07374 Use egw.debug function instead of console to warn about missing images. 2014-01-10 15:57:02 +00:00
Nathan Gray
15bc1b3909 Wait until DOM is loaded before trying to load etemplate or set message 2014-01-10 09:13:56 +00:00
Ralf Becker
5ec887d70d fixing the fix: using private var to store config 2014-01-10 08:12:59 +00:00
Klaus Leithoff
4cc93e8ead fix for unexpected not defined this.configs 2014-01-10 08:00:45 +00:00
Ralf Becker
400240f1e4 caching translations for 10days and changing translation url, when translations are changing --> saves server-roundtrip for each translation 2014-01-09 15:32:07 +00:00
Ralf Becker
90edb55ec5 add async include and et2 render times to page-generation-times shown 2014-01-09 12:20:13 +00:00
Ralf Becker
0092addd08 ignore SecurityError exception if opener is different security context / cross-origin 2014-01-08 15:19:04 +00:00
Ralf Becker
911e7d2955 ignore SecurityError exception if opener is different security context / cross-origin 2014-01-08 15:14:10 +00:00
Nathan Gray
271d7a869c Turn debug level down to warning 2014-01-08 14:58:41 +00:00
Nathan Gray
9009ef44bb Pass current app to egw_app_header() so it can set header for correct app. Fixes sometimes wrong app header shown. 2013-12-23 16:13:40 +00:00
Nathan Gray
7381f103e5 Initialize popup flag with window.opener detection, instead of false. 2013-12-19 17:18:01 +00:00
Nathan Gray
89e1757d9e Avoid errors if no email address was provided 2013-12-19 17:16:33 +00:00
Hadi Nategh
1d14ecc80f Remove "drag-and-drop" and "IE dropdownmenu hack" from the common preferences 2013-12-19 10:19:14 +00:00
Hadi Nategh
185237291f Make sure the et2 is not empty before giving up to not refresh the whole page 2013-12-19 08:46:51 +00:00
Nathan Gray
a79f7b87a6 Continue moving most favorite functionality from favorite widget into framework. Favorite widget now uses framework. 2013-12-12 23:45:09 +00:00
Ralf Becker
fef5bb4972 fix error if query parameters contain null 2013-12-12 03:43:17 +00:00
Ralf Becker
2bb7b7565c fix add-favorite method to NOT bubble and giving a CSP warning instead of running 2013-12-12 02:42:08 +00:00
Nathan Gray
e15144c7f9 - Fix name in delete confirm
- Some documentation & cleanup
2013-12-12 00:38:06 +00:00
Nathan Gray
0ecc494cb4 Remove loading class if there is no favorite delete being processed 2013-12-12 00:00:54 +00:00
Nathan Gray
d2e2622b77 Remove reference to sidebox in destructor 2013-12-11 23:54:42 +00:00
Nathan Gray
b9f39dd315 - Use egw.link() instead of string concatenation so it can craft the URL 'properly'
- Load categories in a div instead of an iframe
2013-12-10 22:26:07 +00:00
Nathan Gray
72c3d211be One more fix needed to allow :: inside UIDs 2013-12-09 21:13:59 +00:00
Nathan Gray
443b8ed854 Give some UI feedback if the delete does not work 2013-12-06 23:26:48 +00:00
Nathan Gray
72c37e0849 non-et2 Favorites work in progress
Handle states that are id_data objects for egw.open()
2013-12-06 23:12:05 +00:00
Nathan Gray
d097a0bfa1 non-et2 Favorites work in progress
New states now added to list immediately, can delete states
2013-12-06 21:26:55 +00:00
Nathan Gray
79498c5ae5 non-et2 Favorites work in progress
Can now save & restore state.  Still some UI needed, not fully integrated with et2 favorites.
2013-12-06 18:24:29 +00:00
Ralf Becker
b2c563e5aa restoring current app/tab, if pressing save or cancel, to do so let server know which is current app and run under that appname (otherwise redirect will happen to currently views app 2013-12-06 00:02:16 +00:00
Nathan Gray
cfefedc8f7 non-et2 Favorites work in progress
Add current link shows popup with state details.
2013-12-05 23:22:54 +00:00
Nathan Gray
87936488bf Implement getState() & setState() towards a more universal favorites, but still more to do:
- Need to get favorite widget to use setState()
- Move much code out of etemplate2 widgets into a higher level
2013-12-05 00:00:43 +00:00
Nathan Gray
6f15f0aa4c Make popups 10px bigger 2013-11-29 17:42:20 +00:00
Ralf Becker
4f3f88ae92 fixed not updated sidebox in calendar when using framed template-set, as sidebox is now transported as data attribute, we need to set it in or before header call 2013-11-28 23:18:36 +00:00
Nathan Gray
33b01975b2 Allow :: inside data UIDs 2013-11-28 20:16:33 +00:00
Nathan Gray
b86173ad16 Fix warning to only come when app JS object is missing 2013-11-27 00:13:56 +00:00
Nathan Gray
0502f9326c Make sure ajax flag is at the end so framework finds it 2013-11-26 22:23:08 +00:00
Hadi Nategh
fca35f8127 Revert r44596 about egw_refresh 'cause need more investigation 2013-11-26 08:48:10 +00:00
Nathan Gray
6985c3d61f Resize popups according to their content 2013-11-21 19:09:17 +00:00
Nathan Gray
fd737f10dc Change queued AJAX to go async 2013-11-20 23:40:26 +00:00
Nathan Gray
089144d986 Avoid adding CSS files again if they're already in the header 2013-11-19 23:22:33 +00:00
Hadi Nategh
74d0797904 Make sure only fall into et2 specific reload for egw_refresh when the etemplate2 object has value 2013-11-19 08:36:08 +00:00
Ralf Becker
8e69433829 use template specific images for foldertree, use "template" handler for all calls to template/framework object, NOT instanciating a new one using eg. a parent class 2013-11-15 16:28:24 +00:00
Nathan Gray
fb2c103cef Use current app to get around missing etemplate run rights 2013-11-13 23:57:49 +00:00
Nathan Gray
31a42e3110 Use current app to get around missing etemplate run rights 2013-11-13 23:22:44 +00:00
Ralf Becker
aeb6ebd84c instanciate app.js object from egw.js, so non et2 apps can use it too, get et2_dialog working from app.calendar outside listview 2013-11-05 18:08:07 +00:00
Ralf Becker
6d226a7921 split constructor function and place of instanciation for app.js objects: app[appname] = new app.classes[appname](); 2013-11-04 20:54:23 +00:00
Nathan Gray
07ff17704f Refresh current app or target app too, like it says it's supposed to 2013-11-04 18:57:20 +00:00
Nathan Gray
4d29125c41 Fix some window/scope issues with jquery & plain assign handlers to make sure they operate on the window, not the request context (which can be anything) 2013-10-28 22:22:09 +00:00
Nathan Gray
f6526a30e8 Fix intermittent issue with missing window breaking ajax 2013-10-18 21:01:53 +00:00
Ralf Becker
998d568ef4 for egw.json calls in a popup we need to use jQuery object of that window, as otherwise eg. apply from server with app.$app.method to run in main window instead of popup 2013-10-18 16:14:36 +00:00
Nathan Gray
129eb91b3d Null is also not OK for icon 2013-10-10 16:15:46 +00:00
Klaus Leithoff
43d73abbcd test if the required method is available on framework 2013-10-10 15:38:18 +00:00
Ralf Becker
24e3fb2e63 fix "Got invalid title request, by NOT sending empty requests" warnings 2013-10-10 10:49:41 +00:00
Nathan Gray
e0954288dd Switch to a heartbeat style of tracking open [named] popups. Seems much more consistent. 2013-10-10 09:37:21 +00:00
Ralf Becker
bafcc80e35 fixed translations not loaded on very first request, as postponing ready for waiting on translations did not work, now using a direct callback instead 2013-10-08 08:55:15 +00:00
Ralf Becker
0bb8093426 fixed translations on client-side: server sends now currentapp and langRequire to client, which uses that to translate phrases, langRequire is only stored in egw object for matching app-name and window! 2013-10-07 17:00:03 +00:00