<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>gothedistance</author_name>
  <author_url>https://blog.hatena.ne.jp/gothedistance/</author_url>
  <blog_title>Life is Really Short, Have Your Life!!</blog_title>
  <blog_url>https://aroundthedistance.hatenadiary.jp/</blog_url>
  <categories>
    <anon>Python</anon>
    <anon>Flask</anon>
  </categories>
  <description>WTFormsはこの辺がイケてないのぅ。SelectFieldで選択した値を元に検索をかけると、Ajaxでもなければ初期値の値に戻ってしまう。SelectFieldにはdefaultというプロパティがあるが、これはコンストラクタでしか有効にならない。 #これだと選択値が入る select = SelectField( choices=[(1, 'First'), (2, 'Second')], default=2) #これはダメ select = SelectField(choices=[(1, 'First'), (2, 'Second')]) select.default = 2 #NG …</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Faroundthedistance.hatenadiary.jp%2Fentry%2F2015%2F03%2F17%2F114542&quot; title=&quot;WTFormsのSelectFieldで選択値(selected)を保持する方法 - Life is Really Short, Have Your Life!!&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2015-03-17 11:45:42</published>
  <title>WTFormsのSelectFieldで選択値(selected)を保持する方法</title>
  <type>rich</type>
  <url>https://aroundthedistance.hatenadiary.jp/entry/2015/03/17/114542</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
