Commit 95a39b2d5b9880d8a03e62aab6ab4311fcbcb8e1

Authored by Karpikau Andrei
1 parent a1fab1a6

change kanjai version

... ... @@ -47,8 +47,8 @@
47 47 <file leaf-file-name="pages_controller.rb" pinned="false" current-in-tab="false">
48 48 <entry file="file://$PROJECT_DIR$/app/controllers/kanjai/pages_controller.rb">
49 49 <provider selected="true" editor-type-id="text-editor">
50   - <state vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="2235">
51   - <caret line="26" column="59" selection-start-line="26" selection-start-column="59" selection-end-line="26" selection-end-column="59" />
  50 + <state vertical-scroll-proportion="0.0" vertical-offset="1316" max-vertical-offset="2370">
  51 + <caret line="122" column="15" selection-start-line="122" selection-start-column="15" selection-end-line="122" selection-end-column="15" />
52 52 <folding />
53 53 </state>
54 54 </provider>
... ... @@ -542,7 +542,7 @@
542 542 <window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
543 543 <window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
544 544 <window_info id="Application Servers" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
545   - <window_info id="Project" active="true" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.27786753" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
  545 + <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.27786753" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
546 546 <window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="2" side_tool="true" content_ui="tabs" />
547 547 <window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.32930514" sideWeight="0.5" order="7" side_tool="true" content_ui="tabs" />
548 548 <window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
... ... @@ -938,8 +938,8 @@
938 938 </entry>
939 939 <entry file="file://$PROJECT_DIR$/app/controllers/kanjai/pages_controller.rb">
940 940 <provider selected="true" editor-type-id="text-editor">
941   - <state vertical-scroll-proportion="0.0" vertical-offset="0" max-vertical-offset="2235">
942   - <caret line="26" column="59" selection-start-line="26" selection-start-column="59" selection-end-line="26" selection-end-column="59" />
  941 + <state vertical-scroll-proportion="0.0" vertical-offset="1316" max-vertical-offset="2370">
  942 + <caret line="122" column="15" selection-start-line="122" selection-start-column="15" selection-end-line="122" selection-end-column="15" />
943 943 <folding />
944 944 </state>
945 945 </provider>
... ...
1 1 PATH
2 2 remote: .
3 3 specs:
4   - kanjai (0.0.29)
  4 + kanjai (0.0.31)
5 5 acts_as_list
6 6 acts_as_tree
7 7 aws-sdk
... ...
... ... @@ -46,6 +46,11 @@ module Kanjai
46 46
47 47 def setTemplateContent(page_template, layer, page_data)
48 48
  49 + unless current_admin_user
  50 + layer.gsub!('<meta name="csrf-param" content="###CSRF_PARAM###"/>', '')
  51 + layer.gsub!('<meta name="csrf-token" content="###CSRF_TOKEN###"/>', '')
  52 + end
  53 +
49 54 layer.scan(/(<element name="([\w\W]+?)" type="([\w\W]+?)"><\/element>)/).each do |item|
50 55 content = item[0]
51 56 name = item[1]
... ... @@ -109,9 +114,13 @@ module Kanjai
109 114 end
110 115 layer.gsub!(marker, content)
111 116 when '###CSRF_PARAM###'
112   - layer.gsub!(marker, Rack::Utils.escape_html(request_forgery_protection_token))
  117 + unless current_admin_user
  118 + layer.gsub!(marker, Rack::Utils.escape_html(request_forgery_protection_token))
  119 + end
113 120 when '###CSRF_TOKEN###'
114   - layer.gsub!(marker, Rack::Utils.escape_html(form_authenticity_token))
  121 + unless current_admin_user
  122 + layer.gsub!(marker, Rack::Utils.escape_html(form_authenticity_token))
  123 + end
115 124 when '###DOMAIN_NAME###'
116 125 layer.gsub!(marker, $scheme + ADMIN_CONFIG['domain_name'])
117 126 when '###INCLUDE_JS_FILE###'
... ...
1 1 module Kanjai
2   - VERSION = "0.0.31"
  2 + VERSION = "0.0.32"
3 3 end
... ...