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
961f44b9
Commit
961f44b9
authored
Sep 15, 2015
by
Amanda Ghassaei
Browse files
keep seq in sync with assembly
parent
95cf091f
Changes
2
Hide whitespace changes
Inline
Side-by-side
js/menus/DNAExportMenuView.js
View file @
961f44b9
...
...
@@ -3,18 +3,20 @@
*/
define
([
'
jquery
'
,
'
underscore
'
,
'
menuParent
'
,
'
dnaExport
'
,
'
text!menus/templates/DNAExportMenuView.html
'
],
function
(
$
,
_
,
MenuParentView
,
dnaExport
,
template
){
define
([
'
jquery
'
,
'
underscore
'
,
'
menuParent
'
,
'
dnaExport
'
,
'
lattice
'
,
'
text!menus/templates/DNAExportMenuView.html
'
],
function
(
$
,
_
,
MenuParentView
,
dnaExport
,
lattice
,
template
){
return
MenuParentView
.
extend
({
events
:
{
"
click #saveSequences
"
:
"
_saveToFile
"
"
click #saveSequences
"
:
"
_saveToFile
"
,
"
click #calcSequences
"
:
"
_calcSequences
"
},
_initialize
:
function
(){
this
.
listenTo
(
dnaExport
,
"
change
"
,
this
.
render
);
},
_saveToFile
:
function
(
e
){
...
...
@@ -22,8 +24,13 @@ define(['jquery', 'underscore', 'menuParent', 'dnaExport', 'text!menus/templates
dnaExport
.
save
();
},
_calcSequences
:
function
(
e
){
e
.
preventDefault
();
dnaExport
.
generateSequences
();
},
_makeTemplateJSON
:
function
(){
return
dnaExport
.
toJSON
();
return
_
.
extend
(
dnaExport
.
toJSON
()
,
lattice
.
toJSON
())
;
},
template
:
_
.
template
(
template
)
...
...
js/menus/templates/DNAExportMenuView.html
View file @
961f44b9
<
%
if
(
sequence32.length
+
sequence16.length
!=
numCells
){
%
>
<div
class=
"inlineWarning"
>
The number of sequences calculated does not match the number of cells in your assembly. Switch to part type "DNA" and then hit "Re-Calc Sequences" to fix this.
</div>
<
%
}
%
>
<
%
if
(
sequence32.length
>
0){ %>
32bp sequences:
<br/>
<div
class=
"sequenceOutput"
>
...
...
@@ -18,4 +23,5 @@
<
%
}
else
{
%
>
no 16bp sequences
<br/>
<
%
}
%
><br/>
<a
href=
"#"
id=
"calcSequences"
class=
"btn btn-block btn-lg btn-default"
>
(Re)-Calc Sequences
</a><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