Hi team,
How to provide validation's existing content fragment models datatypes.
How to load clientlibs content fragment model page.
I created Content Fragment Models,need to do validation's in existing datatypes.
Based existing datatypes created content fragment model page.
Regards
Kotireddy Naru
Solved! Go to Solution.
Views
Replies
Total Likes
Hi,
Ok, then you need to add clientlibs with category type of dam.cfm.authoring.v2
$( document ).ready(function() {
console.log( "inside CFM - ready!" );
$("button.button-apply.editor-GlobalBar-item").click(function(){
alert("clicked");
})
});
Views
Replies
Total Likes
HI,
You can add validation clientlibs as cq.cfm.admin.models.formbuilder
you need to call that function to validate fields on onclick event of save button.
Views
Replies
Total Likes
thanks Arun, providing info.
I am adding my validation's below js files.
/libs/dam/cfm/models/editor/components/formbuilder/clientlibs/js/field-properties.js
/libs/dam/cfm/models/editor/components/formbuilder/clientlibs/js/main.js
/libs/dam/cfm/models/editor/components/formbuilder/clientlibs/js/submit.js
those Javascript files not loaded properly in model page.
Thanks
Kotireddy Naru
Views
Replies
Total Likes
Hi,
Can you check files in network tab or try to put log statement.
working for me.
Saved button event is also working
$( document ).ready(function() {
console.log( "inside CFM - ready!" );
$("button.foundation-wizard-control").click(function(){
alert("save button clicked");
})
});
Views
Replies
Total Likes
thanks Arun,
I dont need to validation's Content Fragment Model Editor, need validation's Content Fragment Model Page level
PFA
Thanks
Kotireddy
Views
Replies
Total Likes
Hi,
Ok, then you need to add clientlibs with category type of dam.cfm.authoring.v2
$( document ).ready(function() {
console.log( "inside CFM - ready!" );
$("button.button-apply.editor-GlobalBar-item").click(function(){
alert("clicked");
})
});
Views
Replies
Total Likes
thanks Arun,
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies