You are viewing limited content. For full access, please sign in.

Question

Question

Feature Request: Forms Theme Export and Apply to Multiple Forms

asked on January 9, 2017 Show version history

This may be a VAR only request, but I have had the question a couple of times from clients as well.  I assume this is a feature request since I haven't seen the ability to do this in Forms or a simple way to do it in LF Answers.

 

A little background:

When I am prepping for a demo to show LF Forms to a prospective customer I try to make a theme that matches their website logos, color scheme, etc.  I save each of these as custom themes.  Once I have the theme dialed in, then I go back to each of the other forms that we might possibly demonstrate as part of our presentation and change the theme on all the forms.  There are also times when I build the theme for one of our salespeople on my laptop and would like to export the theme to them.

As for changing the form themes in mass, I poked around the forms database in SQL and saw where the form elements and themes are stored but could not find the table where the theme for each form is stored.  If I knew where that was, then that would be a decent/time-saving work around to help me prepare for a demonstration.  

So, here are the two requests.  If these are already possible please reply how to do them.  

  1. An easy way to apply a theme/design elements (CSS etc) to multiple forms and multiple processes at the same time.
  2. An easy way to create an export of theme/design elements to transfer to another forms server. 

 

Hopefully, I didn't miss something that allows for these operations in the current Forms build.  If so, please let me know.  Otherwise, I think these would be extremely helpful features.

3 0

Replies

replied on December 6, 2023 Show version history

Please add our vote for this feature - especially the ability to update a Custom Form Theme and push it out to multiple Process and Forms all at once. For some customers we now have dozens of processes, and several Forms per process... meaning if we have change the Theme 'globally' we have to go in and update it literally hundreds of times, on each Form. 

I'm aware of the discussion (on other Answers threads) around only being able to update for Forms for which the user is an admin/designer - but assume there could be a way for a 'superuser' to have access to all, or some setting that enables 'apply updated theme to all forms where it is set' or 'apply updated theme to selected forms where it is set'?

Thanks.

2 0
replied on December 7, 2023

Duncan, in my demo system I have created a form that does a lookup of all available themes in LF Forms.  When you pick the theme you want, it then fires off a workflow that goes through the SQL database for Forms and updates all forms to the newly created theme.  This allows me to create a custom theme for a new customer demo and then update all my forms to this newly created theme.  I tried to attach the files and I got this message.  "The selected file Business Process Change Themes on Existing Forms.xml cannot be uploaded. Only files with the following extensions are allowed: txt, jpg, jpeg, gif, png, tif, tiff, svg, rtf, doc, docx, pdf, xps, xls, xlsx, odt, ppt, pptx, odp, msg, mht, eml, swf, arf, mp4."  So I can't attach the XML for WFI for the form and Workflow.  DM me and I can send those to you. 

0 0
replied on January 10, 2017 Show version history

 

The theme is stored in the cf_theme table in the Forms database. If you want to export and import theme in Forms, the easiest way is to apply the theme to a form, then export the process contain the form, then import to another Forms site.

For what theme the form is used, it is stored in the theme_id column of the cf_forms table. So you can just run an sql query to update the column for multiple forms at  once.

1 0
replied on January 10, 2017 Show version history

So I had tried messing with the theme_id Column in the cf_forms table and didn't get very good results.  When I changed the theme number it seemed to kill the theme in the design mode.  It changed it in preview and use, but if I was in the designer on the theme tab it looks like the attached image.

The other issue was that the theme ID didn't seem consistent.   For example, I apply a theme in design mode and it works great on the form.  The issue I ran into here is that the theme_ID doesn't seem to match.  I may apply a theme to a form that has an ID of 38 and that theme works and displays great, but in SQL it still shows the previous theme number of 54.  But if I change it in SQL to a specific theme number, that seems to work but then it doesn't work in the designer.  

 

Thoughts?

Missing Theme.JPG
Missing Theme.JPG (142.59 KB)
0 0
replied on January 11, 2017

Actually each form that need to have a corresponding theme in the cf_theme table with type is FP, and that theme will use the show column to link to the saved custom themes. You can use following queries to set the theme for the form, you just need to provide the value for the id of the custom theme and the id of the form in following queries:


  declare @json nvarchar(2500)
  declare @css nvarchar(4000)
  declare @custom_theme_id int=228
  declare @logo_id int
  declare @theme_id int
  declare @form_id int=403
declare cur Cursor local for select [json], css, logo_id  from [dbo].[cf_theme] where id=@custom_them_id
open cur
fetch next from cur into @json, @css, @logo_id

 insert into [dbo].[cf_theme]([type],[name],[json],[css],[show],[logo_id]) values('FP','Current', @json,@css,@custom_theme_id,@logo_id)
 select top 1 @theme_id=id from [dbo].[cf_theme] order by id desc
 update [cf_forms] set theme_id=@theme_id where form_id=@form_id

 

0 0
replied on April 17, 2024

Is there a similar table for the Modern forms designer?  I can create a theme in the Classic Designer, and it will apply to to the Modern forms no problem if I do it manually but I want to add that table to my current workflow that updates the Classic forms easily.   I have tried manually changing the values for the modern_form_image_mapping and modern_theme_image_mapping tables.  That doesn't see to do anything. I did notice when I apply a classic theme to a modern form, that form is removed from the modern_form_image_mapping table.  I have been digging through the SQL tables and can't seem to find where the reference goes.   Thoughts?

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.