選択リストのオプションを正常に設定できましたが、選択したオプションが設定されていません。
誰かが私が間違っていることを見ることができますか?
http://jsfiddle.net/devlife/YmshY/2/
HTML:
<select data-bind="options: FundTypeOptions, optionsText: 'Text', optionsValue: 'Value', value:
Javscript:
$root.SelectedFundType"></select>
$(function(){
var options = {
"ImportType":0,
"ImportTypeList":{
"":"",
"Funds":"Fund Level Investments",
"Valuations":"Valuations"
},
"FundTypeOptions":[
{"Value":"","Text":""},
{"Value":"Initial","Text":"Initial"},
{"Value":"FollowOn","Text":"Follow-on"}
],
"SelectedImportType":"Funds",
SelectedFundType: "FollowOn"
};
var viewModel = {
FundTypeOptions: ko.observableArray(options.FundTypeOptions)
};
ko.applyBindings(viewModel);
});