Closed mtakeuchi closed 7 years ago
setValue()で設定した値に対して、あらかじめ定義したコンバータ関数で変換を行い、その結果を取得したい。
実装イメージ
<input type="checkbox" name="chk1"> <input type="text" name="txt1">
this.formController.setSettings({ property: { chk1: { get: function(val) { return parseInt(val); } }, txt1: { get: function(val) { return val * 1.08; } } } }); this.formController.setValue({ chk1: "10", txt1: 100}); this.formController.getValue(); // { chk1: 10, txt1: 108 }
関連issue #581
setSetting()に指定するオプションvalueFuncの機能と重複しているため取り下げ。
setValue()で設定した値に対して、あらかじめ定義したコンバータ関数で変換を行い、その結果を取得したい。
実装イメージ
関連issue #581