Log of /trunk/webwork-modperl/lib/WeBWorK/DB.pm
Parent Directory
Revision
3973 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Jan 25 23:13:56 2006 UTC (7 years, 3 months ago) by
sh002i
File length: 76073 byte(s)
Diff to
previous 3848
,
to
selected 1641
forward-port from rel-2-2-dev: (update copyright date range -- 2000-2006.
this is probably overkill, since there are some files that were created
after 2000 and some files that were last modified before 2006.)
Revision
3848 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Thu Dec 22 18:46:25 2005 UTC (7 years, 5 months ago) by
glarose
File length: 76068 byte(s)
Diff to
previous 3640
,
to
selected 1641
Gateway update:
- correct error check in deleteUserSet to allow deletion of set versions
- change countUserSets to only count non-versioned sets
- add countUserSetVersions to count versioned sets
- change listUserSets to not list versioned sets
- add listUserSetVersions to list versioned sets
These should resolve bug #894.
Revision
3640 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Mon Sep 19 17:11:26 2005 UTC (7 years, 8 months ago) by
jj
File length: 75066 byte(s)
Diff to
previous 3485
,
to
selected 1641
Fix bug 819. This adds a method to DB for getting all merged problems
for a (student,set) combination so that the problem value can be
correct. See bug 819 for additional comments on how this affects
scoring when an individual student is given an override value for
"weight".
Revision
3485 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Aug 12 02:47:30 2005 UTC (7 years, 9 months ago) by
sh002i
File length: 74287 byte(s)
Diff to
previous 3398
,
to
selected 1641
added HiRes timing data to WeBWorK::Debug, removed WeBWorK::Timing. all
existing calls to the WeBWorK::Timing methods now pass the same messages
to debug().
added an option to WeBWorK::Debug to allow only certain subroutines to
log debug messages, in addition to the existing option to bar certain
subroutines from doing so.
Revision
3377 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Thu Jul 14 13:15:27 2005 UTC (7 years, 10 months ago) by
glarose
File length: 75857 byte(s)
Diff to
previous 3284
,
to
selected 1641
Preliminary commit of changes to add Gateway module.
This adds to WeBWorK
- the ability to create versioned, timed problem sets ("gateway tests")
for which all problems are displayed on a single page ("versioned"
means that students can get multiple versions of the problem set),
- the ability to create sets that draw problems from groups of
problems, and
- the ability to create sets that require a proctor login to start
and grade.
Sets can be defined as gateway tests or proctored gateway tests from
the ProblemSetDetail page.
Not quite bug-free yet. Known bugs include handling of problem values
on the Student Progress page (I think this may be a problem with
changing from sql database format where all entries were 'text' to
sql_single in ver 2.1, where they are integer), and a division by zero
error on the grades page (which may be the same problem).
Tests with a number of attempts per version greater than one haven't
been carefully tested, nor has scoring of gateway tests.
Revision
3052 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Sun Dec 19 00:53:27 2004 UTC (8 years, 5 months ago) by
gage
File length: 59102 byte(s)
Diff to
previous 3050
,
to
selected 1641
Changed
unless $value =~ m/^[\w-.]*$/
to
unless $value =~ m/^[.\w-]*$/
for some reason having the period at the end was causing the warning:
False [] range "\w-" before HERE mark in regex m/^[\w- << HERE .]*$/ at
/home/gage/webwork/webwork-modperl/lib/WeBWorK/DB.pm line 1974.
Revision
2747 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Sep 8 06:38:59 2004 UTC (8 years, 8 months ago) by
sh002i
File length: 58444 byte(s)
Diff to
previous 2542
,
to
selected 1641
putPassword() and putPermissionLevel() now auto-create records that
don't exist by calling addPassword() and addPermissionLevel()
respectively. Closes bug #643.
Revision
1696 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Sat Jan 3 20:07:03 2004 UTC (9 years, 4 months ago) by
sh002i
File length: 49964 byte(s)
Diff to
previous 1681
,
to
selected 1641
UPDATE YOUR CONFIG FILES! (global.conf.dist, database.conf.dist)
Made changes to support the storage of multiple database layouts in a
single course environment. Database layouts are now stored in a hash
named %dbLayouts in database.conf, and the default layout is aliased to
*dbLayout (see comments in database.conf.dist and global.conf.dist)
sql.conf and gdbm.conf are no longer used.
Support the selection of a specific database layout when instantiating
WeBWorK::DB. WeBWorK::DB now takes a reference to a database layout
rather than an entire course environment.
All calls to WeBWorK::DB::new were updated to pass the correct argument.
Revision
1681 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Thu Dec 18 23:15:34 2003 UTC (9 years, 5 months ago) by
sh002i
File length: 49729 byte(s)
Diff to
previous 1672
,
to
selected 1641
- Assigner and SetsAssignedToUser now refuse to unassign sets from the
GlobalTableEmulator's "global user". Closes bug #283.
- New "unassign from all users" button in Assigner.
- Cosmetic changes to path() and title() in several modules.
Revision
1668 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Dec 12 20:23:27 2003 UTC (9 years, 5 months ago) by
sh002i
File length: 49046 byte(s)
Diff to
previous 1663
,
to
selected 1641
Added DB: getAllUserProblems; WW1Hash: getAll, getAllNoFilter;
GlobalTableEmulator: getAll.
Together, these functions allow efficient access to all problems in a
given set.
Revision
1663 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue Dec 9 01:12:32 2003 UTC (9 years, 5 months ago) by
sh002i
File length: 48159 byte(s)
Diff to
previous 1661
,
to
selected 1641
Normalized headers. All files now contain the text below as a header.
This is important since all files now (a) use the full name of the
package, (b) assign copyright to "The WeBWorK Project", (c) give the
full path of the file (relative to CVSROOT) instead of simply the file
name, and (d) include license and warranty information.
Here is the new header:
################################################################################
# WeBWorK Online Homework Delivery System
# Copyright © 2000-2003 The WeBWorK Projcct, http://openwebwork.sf.net/
# $CVSHeader$
#
# This program is free software; you can redistribute it and/or modify it under
# the terms of either: (a) the GNU General Public License as published by the
# Free Software Foundation; either version 2, or (at your option) any later
# version, or (b) the "Artistic License" which comes with this package.
#
# This program is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
# FOR A PARTICULAR PURPOSE. See either the GNU General Public License or the
# Artistic License for more details.
################################################################################
Revision
1661 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Mon Dec 8 23:07:46 2003 UTC (9 years, 5 months ago) by
sh002i
File length: 47502 byte(s)
Diff to
previous 1657
,
to
selected 1641
Implemented a schema-level "count" function in the WW1Hash schema.
Added countSetUsers and countProblemUsers to DB.
Replaced SCALAR calls to listSetUsers with calls to countSetUsers.
Update Schema documentation.
The immediate advantage of this is to make ProblemSetList MUCH faster.
Revision
1649 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Wed Dec 3 20:30:31 2003 UTC (9 years, 5 months ago) by
sh002i
File length: 46518 byte(s)
Diff to
previous 1641
finally committing "terrible GDBM hack": if WW1Hash and
GlobalTableEmuator are being used, a schema-specific optimization is
enabled in getMergedSets.
Revision
1641 -
(
view)
(
download)
(
as text)
(
annotate)
-
[selected]
Modified
Wed Nov 19 22:55:58 2003 UTC (9 years, 6 months ago) by
sh002i
File length: 45009 byte(s)
Diff to
previous 1635
plural get methods no longer require an argument. that way, one can pass
an empty list to them and get an empty list back.
Revision
1583 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue Oct 14 18:02:39 2003 UTC (9 years, 7 months ago) by
sh002i
File length: 44598 byte(s)
Diff to
previous 1568
,
to
selected 1641
closes bug #251: getMergedSets and getMergedProblems now call
getGlobalSets/getUserSets and getGlobalProblems/getUserProblems.
The algorithm used to merge fields is also more efficient now, and
getMergedSet/getMergedProblem have been reimplemented to call
getMergedSets/getMergedProblems.
Revision
1236 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Jun 20 17:04:03 2003 UTC (9 years, 11 months ago) by
sh002i
File length: 35479 byte(s)
Diff to
previous 1226
,
to
selected 1641
new{Password,PermissionLevel,Key,User,GlobalSet,UserSet,...} now pass an
optional prototype object to the record class's constructor. this allows
you to use these methods in place of global2user and user2global (which
you should):
my $userSet = $db->getUserSet($userID, $setID);
my $gloalSet = $db->newGlobalSet($userSet);
You can even do weird things like:
my $gloalSet = $db->newGlobalSet($userProblem);
The WeBWorK::DB::Record class just copies the values of ANY matching
fields from the old object to the new object.
Revision
1167 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Jun 13 23:35:54 2003 UTC (9 years, 11 months ago) by
sh002i
File length: 32821 byte(s)
Diff to
previous 1108
,
to
selected 1641
Several changes to the DB system:
Made all schemas subclasses of WeBWorK::DB::Schema, factored common
constructor code out into Schema.pm. Made all drivers subclasses of
WeBWorK::DB::Schema, factored common constructor code out into
Driver.pm.
Removed superfluous style() and tables() functions from schemas and
drivers. (You can treat the constants in which these are defined as
functions, and call them like $object->STYLE or $object->STYLE().)
WeBWorK::DB now tries to build all tables defined in %dbLayout, instead
of using its own internal list. (TODO: add warnings if known tables are
not built or unknown tables are built.)
Made the error messages given during DB instantiation a little more
intelligent.
Changed the behavior of the exists() and delete() schema methods in all
schemas (and updated the docs) s.t. not all elements of @keyparts have
to be defined.
Changed WeBWorK::DB to allow undefined values to be passed instead of
IDs in delete* method calls, but only if the call was made from
WeBWorK::DB itself (to protect you from accidentally passing an
undefined value and clobbering your whole database).
Changed delete functions to be more efficient. For example,
deleteGlobalSet no longer has to say:
$self->deleteUserSet($_, $setID)
foreach $self->listSetUsers($setID);
$self->deleteGlobalProblem($setID, $_)
foreach $self->listGlobalProblems($setID);
Instead it says:
$self->deleteUserSet(undef, $setID);
$self->deleteGlobalProblem($setID, undef);
This is somewhat more efficient with hash-style schemas, and MUCH more
efficient with the SQL schema.
As usual, be wary of lingering bugs. w00t!
-sam
Revision
956 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri May 30 21:09:19 2003 UTC (9 years, 11 months ago) by
sh002i
File length: 14155 byte(s)
Diff to
previous 953
,
to
selected 1641
Added the capability to the GlobalTableEmulator to designate a user
whose records will be used as global records. To specify this, set the
globalUserID param for the tables using the GlobalTableEmulator (in
%dbLayout). It's probably good to do this on a per-course basis. Put the
following in your course.conf:
$dbLayout{set}->{params}->{globalUserID} = "professor";
$dbLayout{problem}->{params}->{globalUserID} = "professor";
If globalUserID is not present, GlobalTableEmulator will use consensus
(which is very slow!).
-sam
Revision
953 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri May 30 18:14:14 2003 UTC (9 years, 11 months ago) by
sh002i
File length: 10546 byte(s)
Diff to
previous 931
,
to
selected 1641
Made listGlobalProblems more efficient. (I have to go back and look at
the rest of DB and see if there are any more optimizations that can be
made.)
-sam
Revision
909 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Tue May 27 20:11:18 2003 UTC (9 years, 11 months ago) by
sh002i
File length: 10419 byte(s)
Diff to
previous 904
,
to
selected 1641
added:
* listSetUsers($setID) - lists users to whom a set has been assigned
* listProblemUsers($setID, $problemID) - lists users to whom a problem
has been assigned
Both return userIDs.
-sam
Revision
798 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Modified
Fri Mar 21 23:30:16 2003 UTC (10 years, 2 months ago) by
sh002i
File length: 9102 byte(s)
Diff to
previous 775
,
to
selected 1641
initial support for WWDBv2:
- DB.pm finished (except for getGlobalUser{Set,Problem} methods)
- schema modules for password, permission, key, and user with
WWDBv1 hash-bashed backends
- GDBM driver
- wwdb command-line frontend
-sam
This form allows you to request diffs between any two revisions of this file.
For each of the two "sides" of the diff,
enter a numeric revision.