Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
minerva
core
Commits
1294cbb8
Commit
1294cbb8
authored
Jul 10, 2018
by
Piotr Gawron
Browse files
protein modification uses string mapping for state
parent
1fe7ff92
Changes
4
Show whitespace changes
Inline
Side-by-side
model/src/main/java/lcsb/mapviewer/model/map/species/field/ModificationResidue.java
View file @
1294cbb8
...
...
@@ -6,6 +6,8 @@ import java.text.DecimalFormat;
import
javax.persistence.Column
;
import
javax.persistence.Entity
;
import
javax.persistence.EnumType
;
import
javax.persistence.Enumerated
;
import
javax.persistence.FetchType
;
import
javax.persistence.GeneratedValue
;
import
javax.persistence.GenerationType
;
...
...
@@ -65,6 +67,7 @@ public class ModificationResidue implements Serializable, ElementModification {
/**
* State in which this modification is.
*/
@Enumerated
(
EnumType
.
STRING
)
private
ModificationState
state
=
null
;
@Column
(
name
=
"position"
)
...
...
model/src/main/java/lcsb/mapviewer/model/map/species/field/ModificationState.java
View file @
1294cbb8
persist/src/db/12.1.0~alpha.0/fix_db_20180710.sql
0 → 100644
View file @
1294cbb8
-- state of modification_residue is mapped via string
alter
table
modification_residue_table
add
column
state_string
varchar
(
255
);
update
modification_residue_table
set
state_string
=
'PHOSPHORYLATED'
where
state
=
0
;
update
modification_residue_table
set
state_string
=
'ACETYLATED'
where
state
=
1
;
update
modification_residue_table
set
state_string
=
'UBIQUITINATED'
where
state
=
2
;
update
modification_residue_table
set
state_string
=
'METHYLATED'
where
state
=
3
;
update
modification_residue_table
set
state_string
=
'HYDROXYLATED'
where
state
=
4
;
update
modification_residue_table
set
state_string
=
'MYRISTOYLATED'
where
state
=
5
;
update
modification_residue_table
set
state_string
=
'SULFATED'
where
state
=
6
;
update
modification_residue_table
set
state_string
=
'PRENYLATED'
where
state
=
7
;
update
modification_residue_table
set
state_string
=
'GLYCOSYLATED'
where
state
=
8
;
update
modification_residue_table
set
state_string
=
'PALMYTOYLATED'
where
state
=
9
;
update
modification_residue_table
set
state_string
=
'UNKNOWN'
where
state
=
10
;
update
modification_residue_table
set
state_string
=
'EMPTY'
where
state
=
11
;
update
modification_residue_table
set
state_string
=
'PROTONATED'
where
state
=
12
;
update
modification_residue_table
set
state_string
=
'DONT_CARE'
where
state
=
13
;
alter
table
modification_residue_table
drop
column
state
;
alter
table
modification_residue_table
rename
column
state_string
to
state
;
persist/src/test/java/lcsb/mapviewer/persist/dao/map/layout/alias/AliasDaoTest.java
View file @
1294cbb8
...
...
@@ -31,7 +31,7 @@ public class AliasDaoTest extends PersistTestFunctions {
@Before
public
void
setUp
()
throws
Exception
{
project
=
projectDao
.
getProjectByProjectId
(
projectId
);
if
(
project
!=
null
)
{
if
(
project
!=
null
)
{
projectDao
.
delete
(
project
);
}
project
=
new
Project
();
...
...
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