File tree Expand file tree Collapse file tree 3 files changed +30045
-30
lines changed Expand file tree Collapse file tree 3 files changed +30045
-30
lines changed Load Diff Large diffs are not rendered by default.
Original file line number Diff line number Diff line change @@ -2,24 +2,6 @@ var React = require('react');
2
2
var BookStore = require ( './stores' ) . BookStore ;
3
3
var BookActions = require ( './actions' ) . BookActions ;
4
4
5
- var SearchPanel = React . createClass ( {
6
- render : function ( ) {
7
- return (
8
- < div className = "row" >
9
- < div className = "one-fourth column" >
10
- Filter:
11
- < input ref = 'search' type = 'text' value = { this . props . search } onChange = { this . onSearchChanged } />
12
- { this . props . search ?< button onClick = { this . props . onClearSearch } > x</ button > :null }
13
- </ div >
14
- </ div >
15
- )
16
- } ,
17
- onSearchChanged : function ( ) {
18
- var query = React . findDOMNode ( this . refs . search ) . value ;
19
- this . props . onSearchChanged ( query ) ;
20
- }
21
- } ) ;
22
-
23
5
var BookTableRow = React . createClass ( {
24
6
render : function ( ) {
25
7
return (
@@ -40,7 +22,6 @@ var BookTableRow = React.createClass({
40
22
var BookTable = React . createClass ( {
41
23
render : function ( ) {
42
24
var rows = [ ] ;
43
- var self = this ;
44
25
this . props . books . forEach ( function ( book ) {
45
26
rows . push ( < BookTableRow key = { book . id } book = { book } /> ) ;
46
27
} ) ;
@@ -132,7 +113,7 @@ var SearchPanel = React.createClass({
132
113
)
133
114
} ,
134
115
onSearchChange : function ( ) {
135
- var query = React . findDOMNode ( this . refs . search ) . value . trim ( ) ;
116
+ var query = React . findDOMNode ( this . refs . search ) . value ;
136
117
if ( this . promise ) {
137
118
clearInterval ( this . promise )
138
119
}
Original file line number Diff line number Diff line change @@ -4,6 +4,6 @@ module.exports = {
4
4
BOOK_EDIT_CANCEL : 'BOOK_EDIT_CANCEL' ,
5
5
BOOK_SAVE : 'BOOK_SAVE' ,
6
6
BOOK_SEARCH : 'BOOK_SEARCH' ,
7
- BOOK_DELETE : 'BOOK_DELETE' ,
7
+ BOOK_DELETE : 'BOOK_DELETE'
8
8
} ;
9
9
You can’t perform that action at this time.
0 commit comments