Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
LabNbook
LabNbook-Moodle
Commits
6f9d3d0d
Verified
Commit
6f9d3d0d
authored
May 19, 2021
by
David Beniamine
Browse files
Add missing field grade, Closes
#1
parent
0b6f8348
Changes
3
Hide whitespace changes
Inline
Side-by-side
db/install.xml
View file @
6f9d3d0d
<?xml version="1.0" encoding="UTF-8" ?>
<XMLDB
PATH=
"mod/labnbook/db"
VERSION=
"20
190402
"
COMMENT=
"XMLDB file for Moodle mod/labnbook"
<XMLDB
PATH=
"mod/labnbook/db"
VERSION=
"20
210519
"
COMMENT=
"XMLDB file for Moodle mod/labnbook"
xmlns:xsi=
"http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation=
"../../../lib/xmldb/xmldb.xsd"
>
...
...
@@ -15,6 +15,7 @@
<FIELD
NAME=
"labnbook_teamconfigid"
TYPE=
"int"
LENGTH=
"10"
NOTNULL=
"true"
DEFAULT=
"0"
SEQUENCE=
"false"
COMMENT=
"LabNbook DB: team_config.id_team_config"
/>
<FIELD
NAME=
"timecreated"
TYPE=
"int"
LENGTH=
"10"
NOTNULL=
"true"
DEFAULT=
"0"
SEQUENCE=
"false"
/>
<FIELD
NAME=
"timemodified"
TYPE=
"int"
LENGTH=
"10"
NOTNULL=
"false"
DEFAULT=
"0"
SEQUENCE=
"false"
/>
<FIELD
NAME=
"grade"
TYPE=
"int"
LENGTH=
"11"
NOTNULL=
"true"
DEFAULT=
"0"
SEQUENCE=
"false"
/>
</FIELDS>
<KEYS>
<KEY
NAME=
"primary"
TYPE=
"primary"
FIELDS=
"id"
/>
...
...
db/upgrade.php
View file @
6f9d3d0d
...
...
@@ -28,6 +28,11 @@ function xmldb_labnbook_upgrade($oldversion)
// Launch rename field course.
$dbman
->
rename_field
(
$table
,
$field
,
'course'
);
}
if
(
$oldversion
<
2021051900
)
{
$table
=
new
xmldb_table
(
'labnbook'
);
$field
=
new
xmldb_field
(
'grade'
,
XMLDB_TYPE_INTEGER
,
'11'
,
null
,
XMLDB_NOTNULL
,
null
,
'0'
,
null
);
$dbman
->
add_field
(
$table
,
$field
);
}
// For further information please read the Upgrade API documentation:
// https://docs.moodle.org/dev/Upgrade_API
...
...
version.php
View file @
6f9d3d0d
...
...
@@ -9,8 +9,8 @@
\
defined
(
'MOODLE_INTERNAL'
)
||
die
();
$plugin
->
component
=
'mod_labnbook'
;
$plugin
->
release
=
'0.1.
6
'
;
$plugin
->
version
=
20210
105
00
;
$plugin
->
release
=
'0.1.
7
'
;
$plugin
->
version
=
20210
519
00
;
$plugin
->
requires
=
2019052000
;
$plugin
->
maturity
=
MATURITY_RC
;
$plugin
->
supported
=
[
37
,
39
];
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment