101 Commits

Author SHA1 Message Date
dongsheng
9b34dc6e75 "MDL-14129, fix hardcoded print_error" 2008-09-25 02:09:49 +00:00
skodak
0cbe81112a MDL-14580 rewritten course sorting algorithms 2008-06-16 14:25:53 +00:00
skodak
294ce9870f MDL-15189 magic quotes finally removed 2008-06-09 16:53:30 +00:00
skodak
a5d424df7c MDL-14679 converted some get/set_field() 2008-06-02 21:39:23 +00:00
skodak
e4907498da MDL-14679 converted some course related code 2008-06-01 18:17:38 +00:00
thepurpleblob
ab7ac6ac55 MDL-14916:
Tidy up notices

Merged from STABLE_19
2008-05-21 12:47:35 +00:00
skodak
e2b347e933 MDL-14378 When deleting course category deal with everything that depends on its context; merged from MOODLE_19_STABLE 2008-05-13 21:52:38 +00:00
dongsheng
ba6018a902 "MDL-14129, fix print_error call under course/, see tracker" 2008-05-07 06:02:51 +00:00
dongsheng
5a2a53316f MDL-14129, remove all the other error() call 2008-04-04 02:54:20 +00:00
poltawski
8bbcf67bce MDL-12888 - remove require to form no longer used
merged from MOODLE_19_STABLE
2008-01-09 10:57:45 +00:00
poltawski
435f3044df MDL-12873 - show an add course button when editing at the top level (which
is the default view when you click 'Add/Edit Courses')

merged from MOODLE_19_STABLE
2008-01-08 12:00:11 +00:00
nfreear
317d5ddcb3 Fix for reopened bug MDL-7878, "Link identification and skipping" - includes site and course index.php. 2007-10-22 09:21:11 +00:00
nicolasconnault
86830be66e MDL-11543 Temporary solution originally proposed by Martin 2007-10-09 12:53:24 +00:00
martinlanghoff
853a093ec5 course/index: remove call to rebuild_context_rel()
Very last caller to rebuild_context_rel() and any XX_context_rel()
function. move_category() already takes care of calling
context_moved(), which does the required context.path maintenance.

Addresses MDL-11219
2007-09-19 07:53:17 +00:00
martinlanghoff
1d28d87b35 accesslib - Ensure newly-created categories have a context
New categories need a context immediately, and for top-level
categories, they also need to taint the "root" context to trigger
a reload of $USER->access.

This fixes problems with creation of initial courses(MDL-11178),
duplicate misc categories, etc.
2007-09-19 07:50:05 +00:00
martinlanghoff
c9e42aaa99 course/index: Bring back Petr's MDL-9647 simplify dealing with headers/footers in admin sections
I had mistakenly reverted some of Petr's changes.

Fixes MDL-11179 19PERF: Notice on /course/index.php as admin
2007-09-19 07:48:56 +00:00
martinlanghoff
dfbf98cdb3 course/index: minor context-related fixes
- The code uses the system context a lot. Declare
   $sysctx at the top and use it.

 - If the category has a context property, use it
   (saves 1 DB query per category displayed)

The DB costs of this page in editing mode are

 - ~100 DB queries for fix_course_sortorder()

 - ~50 DB queries for the categories listing

If we rewrite both to lose the recursion, we could resolve the
page in perhaps 5 DBq.
2007-09-19 07:27:31 +00:00
martinlanghoff
88903eeab9 course/index: Move categories around using move_category()
Use the newfangled move_category() when moving categories
around, to ensure we Do The Right Thing in the backend,
decoupled from UI stuff.
2007-09-19 07:14:34 +00:00
martinlanghoff
d863419245 course/index: move orphan fixups to an optimised fix_coursecategory_orphans()
Move the fixups for orphan courses to the newly minted
fix_coursecategory_orphans() -- and optimise it to take only 1 dbquery for
the common case.

If we do find lots of orphans, we issue 2 updates per orphan.

This cuts down dbqueries drastically - we used to have 2x the number of
courses in the site.
2007-09-12 02:56:36 +00:00
nicolasconnault
ba7472ccdf MDL-10910 Corrected two errors committed while fixing MDL-10870 2007-08-23 15:08:14 +00:00
toyomoyo
1dc08b85b1 MDL-4384, fixed undefined function call, hide the add sub category form in non-editing mode 2007-08-20 01:59:50 +00:00
nicolasconnault
0be6f67819 MDL-10870 All files updated to new build_navigation() method. Most are untested, because they are not easily accessible within a moodle site. 2007-08-17 19:09:11 +00:00
toyomoyo
ca5d523bef MDL-4384, description for course categories 2007-08-15 08:28:40 +00:00
toyomoyo
c345bb584a MDL-10679, improvement to context_rel table and load_user_capability 2007-08-02 08:28:29 +00:00
toyomoyo
e513826187 MDL-9983, adding triggers for certain events, no handler implemented 2007-07-09 06:43:33 +00:00
skodak
40935142f7 MDL-9647 simplify dealing with headers/footers in admin sections; some more cleanup
fixed continue button in error() on admin page when link present
2007-04-30 17:28:29 +00:00
skodak
1ae083e424 MDL-9647 simplify dealing with headers/footers in admin sections 2007-04-30 17:08:34 +00:00
toyomoyo
fb31c40a9c fix for MDL-9398, users need site:config to create course categories 2007-04-18 04:54:47 +00:00
skodak
571880d220 MDL-9172 "Turn editing off" button disappear from category page; merged from MOODLE_18_STABLE 2007-04-02 13:46:01 +00:00
stronk7
d9bb8caa28 Adding a missing parameter to the "add new course" button. MDL-9129
Merged from MOODLE_18_STABLE
2007-03-30 15:36:52 +00:00
toyomoyo
de0d92e378 fix for MDL-9010, course request button should not appear when it is disabled 2007-03-26 05:50:55 +00:00
nicolasconnault
45b26feebb MDL-2974 - Corrected notification of correctly entered new category with multilang display 2007-03-07 01:25:43 +00:00
moodler
6ba65fa08d Merged Nicolas' changes from MDL-8582 into HEAD. 2007-02-28 06:25:22 +00:00
toyomoyo
e2cd3ed012 merged nick's fix for MDL-8582, ampersand in course name/shortname causes xtheml strict problems 2007-02-23 06:03:09 +00:00
toyomoyo
35d0244a37 taking out deprecated width in print_courses and print_course 2007-02-14 04:56:26 +00:00
moodler
2cae9a4f11 Added a 'courseboxes' div around the course boxes on the course listing to help some CSS 2007-02-14 04:22:24 +00:00
moodler
378ef1fe98 Cleaned up HTML, quotes and styles for the neglected category editing screen MDL-8145 2007-02-05 07:27:07 +00:00
moodler
44b843b6d6 More XHTML strict stuff 2007-01-10 08:35:45 +00:00
skodak
0d905d9f34 MDL-7861 new class .icon and .iconsmall 2007-01-08 09:14:05 +00:00
skodak
b7dc225654 MDL-8062 1.3 Remove name attribute from <form> and fix focus everywhere - more changes ahead 2007-01-04 21:32:36 +00:00
vyshane
d4a18e3460 Added missing footer for delete confirmation view. MDL-7861. 2006-12-20 01:15:15 +00:00
toyomoyo
f78aa86032 MDL-7861, strict xhtml for course/index page 2006-12-19 05:57:55 +00:00
toyomoyo
54926e7818 various accessbility fixes 2006-12-13 03:03:43 +00:00
skodak
344044b28e MDL-7434 all images that convey information should have alt text to convey that information - part 1 2006-11-24 20:16:37 +00:00
skodak
6124048972 major whitespace cleanup - fixed tabs 2006-09-20 20:31:09 +00:00
skodak
09575480bb fixed several warnings in get_course() 2006-09-17 18:07:35 +00:00
toyomoyo
ae9e4c064e replacing iscreator() calls with capabilty 2006-09-12 08:56:10 +00:00
skodak
a13d2157f4 fixed wrong placement of comma 2006-09-08 15:53:24 +00:00
toyomoyo
51792df056 adding capabilities 2006-09-08 08:46:26 +00:00
skodak
6e4dc10f54 deglobalization of $ADMIN; merged admin/adminlib.php into lib/adminlib.php; fixed includes and some other minor fixes 2006-09-02 13:14:57 +00:00