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
Amanda Ghassaei
DMDesign
Commits
95cf091f
Commit
95cf091f
authored
Sep 15, 2015
by
Amanda Ghassaei
Browse files
display and save seq to file
parent
dbe5702d
Changes
4
Hide whitespace changes
Inline
Side-by-side
css/main.css
View file @
95cf091f
...
...
@@ -508,4 +508,14 @@ label {
display
:
inline-block
;
text-overflow
:
ellipsis
;
position
:
absolute
;
}
.sequenceOutput
{
background-color
:
white
;
overflow
:
auto
;
max-height
:
200px
;
margin
:
10px
10px
;
padding
:
5px
10px
20px
10px
;
font-size
:
14px
;
font-family
:
Courier
,
monospace
;
}
\ No newline at end of file
js/cells/supercells/GIKSuperCell.js
View file @
95cf091f
...
...
@@ -99,6 +99,7 @@ define(['underscore', 'three', 'threeModel', 'lattice', 'appState', 'superCell',
if
(
i
==
0
)
seq
=
seq
.
split
(
''
).
reverse
().
join
(
''
);
sequence
+=
seq
;
}
if
(
sequence
==
"
-
"
)
return
""
;
return
sequence
;
};
...
...
js/dnaExport/dnaExport.js
View file @
95cf091f
...
...
@@ -30,9 +30,12 @@ define(['underscore', 'backbone', 'lattice', 'appState', 'fileSaver'],
var
sequences16
=
[];
lattice
.
loopCells
(
function
(
cell
,
x
,
y
,
z
){
if
(
!
cell
)
return
;
if
(
cell
.
getLength
()
==
2
)
sequences32
.
push
(
cell
.
getSequence
());
else
if
(
cell
.
getLength
()
==
1
)
sequences16
.
push
(
cell
.
getSequence
());
else
console
.
warn
(
"
unexpected cell of length
"
+
cell
.
getLength
());
var
seq
=
cell
.
getSequence
();
if
(
seq
&&
seq
!=
""
){
if
(
cell
.
getLength
()
==
2
)
sequences32
.
push
(
seq
);
else
if
(
cell
.
getLength
()
==
1
)
sequences16
.
push
(
seq
);
else
console
.
warn
(
"
unexpected cell of length
"
+
cell
.
getLength
());
}
});
this
.
set
(
"
sequence32
"
,
sequences32
);
this
.
set
(
"
sequence16
"
,
sequences16
);
...
...
js/menus/templates/DNAExportMenuView.html
View file @
95cf091f
32bp sequences:
<br/>
<
%
_.each
(
sequence32
,
function
(
seq
){
%
>
<
%=
seq
%
><br/>
<
%
});
%
><br/>
16bp sequences:
<br/>
<
%
_.each
(
sequence16
,
function
(
seq
){
%
>
<
%=
seq
%
><br/>
<
%
});
%
><br/>
<
%
if
(
sequence32.length
>
0){ %>
32bp sequences:
<br/>
<div
class=
"sequenceOutput"
>
<
%
_.each
(
sequence32
,
function
(
seq
){
%
>
<
%=
seq
%
><br/>
<
%
});
%
>
</div>
<
%
}
else
{
%
>
no 32bp sequences
<br/><br/>
<
%
}
%
>
<
%
if
(
sequence16.length
>
0){ %>
16bp sequences:
<br/>
<div
class=
"sequenceOutput"
>
<
%
_.each
(
sequence16
,
function
(
seq
){
%
>
<
%=
seq
%
><br/>
<
%
});
%
>
</div>
<
%
}
else
{
%
>
no 16bp sequences
<br/>
<
%
}
%
><br/>
<a
href=
"#"
id=
"saveSequences"
class=
"btn btn-block btn-lg btn-success"
>
Save to File
</a><br/>
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