Skip to content
This repository has been archived by the owner on Dec 13, 2020. It is now read-only.

Commit

Permalink
Github issue #2
Browse files Browse the repository at this point in the history
  • Loading branch information
damianprzygodzki committed Aug 29, 2016
1 parent ef3895b commit 967bafe
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 7 deletions.
6 changes: 3 additions & 3 deletions src/components/Widget.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class Widget extends Component {
}
handlePatch = (property, value) => {
const {widgetData,dataId, windowType, dispatch, rowId, tabId, onChange} = this.props;

console.log(value, widgetData.value)
//check if we should update store
if(widgetData.value !== value){
dispatch(updateProperty(property, value, tabId, rowId));
Expand Down Expand Up @@ -267,7 +267,7 @@ class Widget extends Component {
type="checkbox"
value={data.value}
disabled={data.readonly}
onClick={(e) => this.handlePatch(fields[0].field, e.target.value)}
onClick={(e) => this.handlePatch(fields[0].field, e.target.checked)}
/>
<div className="input-checkbox-tick"/>
</label>
Expand All @@ -284,7 +284,7 @@ class Widget extends Component {
type="checkbox"
checked={data.value}
disabled={data.readonly}
onChange={(e) => this.handlePatch(fields[0].field, e.target.value)}
onChange={(e) => this.handlePatch(fields[0].field, e.target.checked)}
/>
<div className="input-slider" />
</label>
Expand Down
2 changes: 0 additions & 2 deletions src/components/app/Header.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,6 @@ class Header extends Component {
"displayed": true
};



return (
<div>
{(isSubheaderShow || isOrderListShow) ? <div className="backdrop" onClick={this.handleBackdropClick}></div> : null}
Expand Down
3 changes: 1 addition & 2 deletions src/components/widget/Lookup.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ class Lookup extends Component {
this.setState({selected: null});
let propertiesCopy = this.getItemsByProperty(properties, "source", "list")
let mainProperty = this.getItemsByProperty(properties, "source", "lookup")

//
// Handling selection when main is not set or set.
//
Expand All @@ -52,7 +51,7 @@ class Lookup extends Component {
// - second should be chosen automatically

let batchArray = [];
if(propertiesCopy.length > 1){
if(propertiesCopy.length >= 1){
let batch = new Promise((resolve, reject) => {
propertiesCopy.map((item) => {
dispatch(dropdownRequest(143, item.field, dataId)).then((response)=>{
Expand Down

0 comments on commit 967bafe

Please sign in to comment.