Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add field to operator selector control element #28

Conversation

SamLoy
Copy link

@SamLoy SamLoy commented Mar 9, 2017

In addition to PR #27, also adding the 'field' param to the operatorSelector on the Rule.

When providing my own operatorSelector, I wanted access to the first field so I could perform an async filter of operators against an API.

I could not achieve this by providing the 'getOperators' function as it does not allow for asynchronously retrieving the list. Given that the 'field' param is passed into 'getOperators' anyway, it seems reasonable to pass it to the controlElement as well..

@codecov-io
Copy link

codecov-io commented Mar 9, 2017

Codecov Report

Merging #28 into master will increase coverage by 4.49%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master      #28      +/-   ##
==========================================
+ Coverage   66.37%   70.86%   +4.49%     
==========================================
  Files           6        6              
  Lines         113      127      +14     
  Branches       13       17       +4     
==========================================
+ Hits           75       90      +15     
  Misses         34       34              
+ Partials        4        3       -1
Impacted Files Coverage Δ
lib/RuleGroup.jsx 100% <100%> (ø)
lib/Rule.jsx 100% <100%> (ø)
lib/QueryBuilder.jsx 46.37% <100%> (+13.04%)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 760550d...dadbe1c. Read the comment docs.

@pavanpodila pavanpodila merged commit 86d6103 into react-querybuilder:master Mar 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants