Errors when Configure -> Smart class parameters

Problem:
When I try to edit a parameter as above I get this error:

Just a simple select override -> submit will reproduce the error.

Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator at [no address given] to inform them of the time this error occurred, and the actions you performed just before this error.
More information about this error may be available in the server error log.

Expected outcome:

But when I try with Configure -> Classes -> (select) Class name -> Smart class parameter. It works fine.

Foreman and Proxy versions:
Foreman 1.12.4
Foreman and Proxy plugin versions:

Other relevant data:
On CentOS 7.4
[e.g. logs from Foreman and/or the Proxy, modified templates, commands issued, etc]

Set logging to debug in /etc/foreman/settings/yaml

Got the following:

[ 2018-02-27 16:15:21.6650 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr] [ 2018-02-27 16:15:21.6644 21305/0x00000001e519f0(Worker 1) utils.rb:74 ]: *** Exception EOFError in Rack application object (bad content body) (process 21305, thread 0x00000001e519f0(Worker 1)):
[ 2018-02-27 16:15:21.6651 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/multipart/parser.rb:148:in `get_current_head_and_filename_and_content_type_and_name_and_body'
[ 2018-02-27 16:15:21.6651 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/multipart/parser.rb:59:in `block in parse'
[ 2018-02-27 16:15:21.6651 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/multipart/parser.rb:56:in `loop'
[ 2018-02-27 16:15:21.6652 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/multipart/parser.rb:56:in `parse'
[ 2018-02-27 16:15:21.6653 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/multipart.rb:25:in `parse_multipart'
[ 2018-02-27 16:15:21.6653 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/request.rb:373:in `parse_multipart'
[ 2018-02-27 16:15:21.6653 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/request.rb:207:in `POST'
[ 2018-02-27 16:15:21.6653 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/methodoverride.rb:39:in `method_override_param'
[ 2018-02-27 16:15:21.6653 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/methodoverride.rb:27:in `method_override'
[ 2018-02-27 16:15:21.6655 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/methodoverride.rb:15:in `call'
[ 2018-02-27 16:15:21.6661 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/runtime.rb:18:in `call'
[ 2018-02-27 16:15:21.6662 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/cache/strategy/local_cache_middleware.rb:28:in `call'
[ 2018-02-27 16:15:21.6664 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/static.rb:116:in `call'
[ 2018-02-27 16:15:21.6665 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/sendfile.rb:113:in `call'
[ 2018-02-27 16:15:21.6666 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/railties-4.2.5.1/lib/rails/engine.rb:518:in `call'
[ 2018-02-27 16:15:21.6667 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/railties-4.2.5.1/lib/rails/application.rb:165:in `call'
[ 2018-02-27 16:15:21.6668 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/railties-4.2.5.1/lib/rails/railtie.rb:194:in `public_send'
[ 2018-02-27 16:15:21.6669 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/railties-4.2.5.1/lib/rails/railtie.rb:194:in `method_missing'
[ 2018-02-27 16:15:21.6669 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/urlmap.rb:66:in `block in call'
[ 2018-02-27 16:15:21.6670 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/urlmap.rb:50:in `each'
[ 2018-02-27 16:15:21.6671 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/urlmap.rb:50:in `call'
[ 2018-02-27 16:15:21.6672 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /usr/share/gems/gems/passenger-4.0.18/lib/phusion_passenger/rack/thread_handler_extension.rb:77:in `process_request'
[ 2018-02-27 16:15:21.6673 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /usr/share/gems/gems/passenger-4.0.18/lib/phusion_passenger/request_handler/thread_handler.rb:140:in `accept_and_process_next_request'
[ 2018-02-27 16:15:21.6674 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /usr/share/gems/gems/passenger-4.0.18/lib/phusion_passenger/request_handler/thread_handler.rb:108:in `main_loop'
[ 2018-02-27 16:15:21.6674 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /usr/share/gems/gems/passenger-4.0.18/lib/phusion_passenger/request_handler.rb:441:in `block (3 levels) in start_threads'
[ 2018-02-27 16:15:21.6676 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/theforeman/tfm/root/usr/share/gems/gems/logging-1.8.2/lib/logging/diagnostic_context.rb:323:in `call'
[ 2018-02-27 16:15:21.6677 31896/7f0055a8c700 Pool2/Implementation.cpp:1274 ]: [App 21155 stderr]       from /opt/theforeman/tfm/root/usr/share/gems/gems/logging-1.8.2/lib/logging/diagnostic_context.rb:323:in `block in create_with_logging_context'

What browser are you using? if it’s IE, this may be an issue that was fixed already, the workaround is to open the parameter in a new tab instead of in the same tab.
There were many improvements in this area (and many others) since 1.12 which came out over a year ago and is no longer receiving any updates, 1.17 is almost out already - I highly recommend updating to a newer version to see if the issue persists.

Thank your suggestion works. Also there is no problem when I try it on Firefox & Chrome.
It may also work with the default certs but not on our site/domain certs I need to look into that later.
But for now I have a bigger issue. with the db schema on our production server.
I will open a new support request for that later.