@@ -114,7 +114,7 @@ class BoardContainer extends Component {
114
114
}
115
115
116
116
render ( ) {
117
- const { id, reducerData, draggable, laneDraggable, laneDragClass, style, addLaneTitle, editable, ...otherProps } = this . props
117
+ const { id, reducerData, draggable, laneDraggable, laneDragClass, style, addLaneTitle, editable, canAddLanes , ...otherProps } = this . props
118
118
const { addLaneMode} = this . state
119
119
// Stick to whitelisting attributes to segregate board and lane props
120
120
const passthroughProps = pick ( this . props , [
@@ -129,6 +129,7 @@ class BoardContainer extends Component {
129
129
'cardDraggable' ,
130
130
'collapsibleLanes' ,
131
131
'editable' ,
132
+ 'canAddLanes' ,
132
133
'hideCardDeleteIcon' ,
133
134
'customCardLayout' ,
134
135
'customLaneHeader' ,
@@ -174,15 +175,18 @@ class BoardContainer extends Component {
174
175
) ;
175
176
} ) }
176
177
</ Container >
177
- < Container
178
- orientation = "horizontal"
179
- >
180
- { editable && ! addLaneMode ? (
181
- < LaneSection style = { { width : 200 } } >
182
- < NewLaneButton onClick = { this . showEditableLane } > { addLaneTitle } </ NewLaneButton >
183
- </ LaneSection >
184
- ) : ( addLaneMode && this . renderNewLane ( ) ) }
185
- </ Container >
178
+ {
179
+ canAddLanes &&
180
+ < Container
181
+ orientation = "horizontal"
182
+ >
183
+ { editable && ! addLaneMode ? (
184
+ < LaneSection style = { { width : 200 } } >
185
+ < NewLaneButton onClick = { this . showEditableLane } > { addLaneTitle } </ NewLaneButton >
186
+ </ LaneSection >
187
+ ) : ( addLaneMode && this . renderNewLane ( ) ) }
188
+ </ Container >
189
+ }
186
190
</ BoardDiv >
187
191
) ;
188
192
}
@@ -205,6 +209,7 @@ BoardContainer.propTypes = {
205
209
draggable : PropTypes . bool ,
206
210
collapsibleLanes : PropTypes . bool ,
207
211
editable : PropTypes . bool ,
212
+ canAddLanes : PropTypes . bool ,
208
213
hideCardDeleteIcon : PropTypes . bool ,
209
214
handleDragStart : PropTypes . func ,
210
215
handleDragEnd : PropTypes . func ,
@@ -230,6 +235,7 @@ BoardContainer.defaultProps = {
230
235
handleLaneDragStart : ( ) => { } ,
231
236
handleLaneDragEnd : ( ) => { } ,
232
237
editable : false ,
238
+ canAddLanes : false ,
233
239
hideCardDeleteIcon : false ,
234
240
draggable : false ,
235
241
collapsibleLanes : false ,
0 commit comments