<p>我有一个名为“counter”的javascript变量,我想用它来更新在中实例化的counter变量模型.py. 在</p>
<p>以下是模型.py在</p>
<pre><code>class Player(BasePlayer):
#track the number of times the user has lost window focus
blur_quantity = models.IntegerField(initial=0)
</code></pre>
<p>下面是一个页面.html在</p>
^{pr2}$
<p>现在,每当用户单击按钮时,“counter”的值应该存储在某个地方。如何更新中blur_quantity的值模型.py(例如,我的Django数据库)来反映blur_按钮的附加值?在</p>