Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
dream
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
dream
Commits
e62c7a1d
Commit
e62c7a1d
authored
Nov 25, 2013
by
Kazuhiko Shiozaki
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
improve spreadsheet.
parent
a1032667
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
62 additions
and
68 deletions
+62
-68
dream/platform/static/index.html
dream/platform/static/index.html
+0
-40
dream/platform/static/spreadsheet_template.html
dream/platform/static/spreadsheet_template.html
+40
-0
dream/platform/static/src/dream.js
dream/platform/static/src/dream.js
+1
-0
dream/platform/static/src/dream_launcher.js
dream/platform/static/src/dream_launcher.js
+7
-28
dream/platform/static/src/jsonPlumb.js
dream/platform/static/src/jsonPlumb.js
+14
-0
No files found.
dream/platform/static/index.html
View file @
e62c7a1d
...
...
@@ -81,46 +81,6 @@
<div
id=
"spreadsheet"
>
<h4>
Spreadsheet
</h4>
<div
class=
"jQuerySheet"
>
<table
title=
"Spreadsheet 1"
class=
"jSheet ui-widget-content"
border=
"1px"
cellpadding=
"0"
cellspacing=
"0"
>
<tbody>
<tr
height=
"18"
style=
"height: 18px;"
>
<td
id=
"0_table0_cell_c0_r0"
class=
""
>
ID
</td>
<td
id=
"0_table0_cell_c1_r0"
class=
""
>
Class
</td>
<td
id=
"0_table0_cell_c2_r0"
class=
""
>
Name
</td>
<td
id=
"0_table0_cell_c3_r0"
class=
""
>
Sequence
</td>
<td
id=
"0_table0_cell_c4_r0"
class=
""
>
Processing Times
</td>
<td
id=
"0_table0_cell_c5_r0"
class=
""
>
Priority
</td>
<td
id=
"0_table0_cell_c6_r0"
class=
""
>
Order Date
</td>
</tr>
<tr
height=
"18"
style=
"height: 18px;"
>
<td
id=
"0_table0_cell_c0_r1"
class=
""
></td>
<td
id=
"0_table0_cell_c1_r1"
class=
""
></td>
<td
id=
"0_table0_cell_c2_r1"
class=
""
></td>
<td
id=
"0_table0_cell_c3_r1"
class=
""
></td>
<td
id=
"0_table0_cell_c4_r1"
class=
""
></td>
<td
id=
"0_table0_cell_c5_r1"
class=
""
></td>
<td
id=
"0_table0_cell_c6_r1"
class=
""
></td>
</tr>
<tr
height=
"18"
style=
"height: 18px;"
>
<td
id=
"0_table0_cell_c0_r2"
class=
""
></td>
<td
id=
"0_table0_cell_c1_r2"
class=
""
></td>
<td
id=
"0_table0_cell_c2_r2"
class=
""
></td>
<td
id=
"0_table0_cell_c3_r2"
class=
""
></td>
<td
id=
"0_table0_cell_c4_r2"
class=
""
></td>
<td
id=
"0_table0_cell_c5_r2"
class=
""
></td>
<td
id=
"0_table0_cell_c6_r2"
class=
""
></td>
</tr>
<tr
height=
"18"
style=
"height: 18px;"
>
<td
id=
"0_table0_cell_c0_r3"
class=
""
></td>
<td
id=
"0_table0_cell_c1_r3"
class=
""
></td>
<td
id=
"0_table0_cell_c2_r3"
class=
""
></td>
<td
id=
"0_table0_cell_c3_r3"
class=
""
></td>
<td
id=
"0_table0_cell_c4_r3"
class=
""
></td>
<td
id=
"0_table0_cell_c5_r3"
class=
""
></td>
<td
id=
"0_table0_cell_c6_r3"
class=
""
></td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
...
...
dream/platform/static/spreadsheet_template.html
0 → 100644
View file @
e62c7a1d
<table
title=
"Spreadsheet 1"
class=
"jSheet ui-widget-content"
border=
"1px"
cellpadding=
"0"
cellspacing=
"0"
>
<tbody>
<tr
height=
"18"
style=
"height: 18px;"
>
<td
id=
"0_table0_cell_c0_r0"
class=
""
>
ID
</td>
<td
id=
"0_table0_cell_c1_r0"
class=
""
>
Class
</td>
<td
id=
"0_table0_cell_c2_r0"
class=
""
>
Name
</td>
<td
id=
"0_table0_cell_c3_r0"
class=
""
>
Sequence
</td>
<td
id=
"0_table0_cell_c4_r0"
class=
""
>
Processing Times
</td>
<td
id=
"0_table0_cell_c5_r0"
class=
""
>
Priority
</td>
<td
id=
"0_table0_cell_c6_r0"
class=
""
>
Order Date
</td>
</tr>
<tr
height=
"18"
style=
"height: 18px;"
>
<td
id=
"0_table0_cell_c0_r1"
class=
""
></td>
<td
id=
"0_table0_cell_c1_r1"
class=
""
></td>
<td
id=
"0_table0_cell_c2_r1"
class=
""
></td>
<td
id=
"0_table0_cell_c3_r1"
class=
""
></td>
<td
id=
"0_table0_cell_c4_r1"
class=
""
></td>
<td
id=
"0_table0_cell_c5_r1"
class=
""
></td>
<td
id=
"0_table0_cell_c6_r1"
class=
""
></td>
</tr>
<tr
height=
"18"
style=
"height: 18px;"
>
<td
id=
"0_table0_cell_c0_r2"
class=
""
></td>
<td
id=
"0_table0_cell_c1_r2"
class=
""
></td>
<td
id=
"0_table0_cell_c2_r2"
class=
""
></td>
<td
id=
"0_table0_cell_c3_r2"
class=
""
></td>
<td
id=
"0_table0_cell_c4_r2"
class=
""
></td>
<td
id=
"0_table0_cell_c5_r2"
class=
""
></td>
<td
id=
"0_table0_cell_c6_r2"
class=
""
></td>
</tr>
<tr
height=
"18"
style=
"height: 18px;"
>
<td
id=
"0_table0_cell_c0_r3"
class=
""
></td>
<td
id=
"0_table0_cell_c1_r3"
class=
""
></td>
<td
id=
"0_table0_cell_c2_r3"
class=
""
></td>
<td
id=
"0_table0_cell_c3_r3"
class=
""
></td>
<td
id=
"0_table0_cell_c4_r3"
class=
""
></td>
<td
id=
"0_table0_cell_c5_r3"
class=
""
></td>
<td
id=
"0_table0_cell_c6_r3"
class=
""
></td>
</tr>
</tbody>
</table>
dream/platform/static/src/dream.js
View file @
e62c7a1d
...
...
@@ -247,6 +247,7 @@
manpy_dict
[
'
nodes
'
]
=
nodes
;
manpy_dict
[
'
edges
'
]
=
data
[
'
edges
'
];
manpy_dict
[
'
general
'
]
=
data
[
'
general
'
];
manpy_dict
[
'
spreadsheet
'
]
=
data
[
'
spreadsheet
'
];
return
manpy_dict
;
};
...
...
dream/platform/static/src/dream_launcher.js
View file @
e62c7a1d
...
...
@@ -263,6 +263,13 @@
});
var
loadData
=
function
(
data
)
{
// spreadsheet
var
spreadsheet
=
data
.
spreadsheet
;
if
(
spreadsheet
!==
undefined
)
{
var
sheet
=
$
(
'
.jQuerySheet
'
);
sheet
.
html
(
$
.
sheet
.
dts
.
toTables
.
json
(
spreadsheet
)).
sheet
();
}
var
preference
=
data
.
preference
!==
undefined
?
data
.
preference
:
{};
dream_instance
.
setPreferences
(
preference
);
...
...
@@ -297,34 +304,6 @@
}
else
{
dream_instance
.
redraw
();
}
// spreadsheet
var
default_config
=
{
id
:
"
jquerysheet-div
"
,
style
:
''
,
jquerySheet
:
true
,
jquerySheetCss
:
true
,
parser
:
true
,
jqueryUiCss
:
true
,
scrollTo
:
false
,
jQueryUI
:
false
,
raphaelJs
:
false
,
gRaphaelJs
:
false
,
colorPicker
:
false
,
colorPickerCss
:
false
,
elastic
:
false
,
advancedMath
:
false
,
finance
:
false
,
editable
:
true
,
autoFiller
:
true
};
var
sheet
=
$
(
'
.jQuerySheet
'
);
var
spreadsheet
=
data
.
spreadsheet
;
if
(
spreadsheet
!==
undefined
)
{
sheet
.
html
(
$
.
sheet
.
dts
.
toTables
.
json
(
spreadsheet
));
}
sheet
.
sheet
();
};
// Check if there is already data when we first load the page, if yes, then build graph from it
jio
.
get
({
...
...
dream/platform/static/src/jsonPlumb.js
View file @
e62c7a1d
...
...
@@ -106,6 +106,18 @@
priv
.
draggable
();
};
priv
.
initSpreadSheet
=
function
()
{
var
sheet
=
$
(
'
.jQuerySheet
'
);
$
.
get
(
'
spreadsheet_template.html
'
,
function
(
data
)
{
sheet
.
html
(
data
).
sheet
();
// Here we bind on the parent object because bind will be
// reset when we replace the contents by using html().
$
(
'
#spreadsheet
'
).
bind
(
'
sheetCellEdited
'
,
function
()
{
priv
.
onDataChange
();
});
});
};
priv
.
updateElementCoordinate
=
function
(
element_id
,
coordinate
)
{
var
coordinates
=
priv
.
preference_container
[
'
coordinates
'
]
||
{},
element
;
if
(
coordinate
===
undefined
)
{
...
...
@@ -313,6 +325,7 @@
priv
.
preference_container
=
{};
priv
.
general_container
=
{};
priv
.
initJsPlumb
();
priv
.
initSpreadSheet
();
};
that
.
removeElement
=
function
(
element_id
)
{
...
...
@@ -329,6 +342,7 @@
});
// delete anything if still remains
$
(
"
#render
"
).
children
().
remove
();
priv
.
initSpreadSheet
();
};
that
.
connect
=
function
(
source_id
,
target_id
)
{
...
...
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