We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
See clone option here: https://react-querybuilder.js.org/demo/antd#addRuleToNewGroups=false&autoSelectField=true&autoSelectOperator=true&debugMode=false&disabled=false&enableDragAndDrop=false&independentCombinators=false&justifiedLayout=false&listsAsArrays=false&parseNumbers=false&resetOnFieldChange=true&resetOnOperatorChange=false&showBranches=false&showCloneButtons=true&showCombinatorsBetweenRules=false&showLockButtons=false&showNotToggle=false&validateQuery=false
I've been able to create this functionality though it's a little forced:
renderAfterActions:(props)=><Button className=".rule--header" icon=<CopyOutlined /> onClick={()=>console.log(props)||this.dup(props.id)}/>, renderAfterWidget:(props)=><Button className=".rule--header" icon=<CopyOutlined /> onClick={()=>console.log(props)||this.dup(props.id)}/>,
then something like this
function duplicateById(obj, id) { if (obj === null || typeof obj !== 'object') return obj; if (Array.isArray(obj)) { return obj.reduce((acc, cur) => { let dup = duplicateById(cur, id); if (cur.id === id) { // Copy the duplicated item and assign a new id dup = { ...dup, id: Utils.uuid() }; acc.push(cur, dup); } else { acc.push(dup); } return acc; }, []); } return Object.keys(obj).reduce((acc, key) => { acc[key] = duplicateById(obj[key], id); return acc; }, {}); }
The text was updated successfully, but these errors were encountered:
Hi @ukrbublik, any update on this feature? When can we expect this to be available?
Sorry, something went wrong.
No branches or pull requests
See clone option here: https://react-querybuilder.js.org/demo/antd#addRuleToNewGroups=false&autoSelectField=true&autoSelectOperator=true&debugMode=false&disabled=false&enableDragAndDrop=false&independentCombinators=false&justifiedLayout=false&listsAsArrays=false&parseNumbers=false&resetOnFieldChange=true&resetOnOperatorChange=false&showBranches=false&showCloneButtons=true&showCombinatorsBetweenRules=false&showLockButtons=false&showNotToggle=false&validateQuery=false
I've been able to create this functionality though it's a little forced:
then something like this
The text was updated successfully, but these errors were encountered: