Discovery.fullFillCombo = function(comboId,options,setDefault){
var targetCombo = dijit.byId(comboId);
var comboOptions = new dojo.data.ItemFileWriteStore({data: {identifier: 'name', items:[]}});
if(targetCombo.store!=null){
targetCombo.store==null;
}
for (var i in options) {
var tmpOption = options[i];
comboOptions.newItem({name: tmpOption});
comboOptions.save({onComplete: this.saveOptionComplete, onError: this.saveOptionError});
}
targetCombo.store = comboOptions;
if(setDefault == 'true'){
targetCombo.attr('value', options[0]);
}
};
Discovery.saveOptionComplete = function() {
console.log("SAVE COMPLETE");
};
Discovery.saveOptionError = function() {
console.log("SAVE ERROR");
};
上面代码是实现动态添加combo option的。
当出现assertion failed in ItemFileWriteStore异常时,检查下添加的option是否有重复的
分享到:
相关推荐
Debug Assertion Failed!
OpenCV Error: Assertion failed (!empty()) in cv::CascadeClassifier::detectMultiScale, file C:\build\master_winpack-bindings-win64-vc14-static\opencv\modules\objdetect\src\cascadedetect.cpp, line 1681 ...
Delphi 2007 或2009 在Windows 7 x64 以及其他x64 系统下,退出IDE 时,调试器会产生一个断言错误,错误窗口标题为:bds.exe –bordbk120N....”SetThreadContext failed”)”in ..\win32src\thread32.cpp at line 434。
occcont.cpp line 925运行错误 Debug Assertion Failed:表示缺少某个OCX控件。这里提供msflxgrd.ocx和mscomm32.ocx。下载后复制到C:\Windows\SysWOW64目录下,regsvr32注册即可
nhk4s.zip,用于Scala的NHK4S“NHK番組表API”客户端库
修复ASSERTION_FAILED导致的DUMP
Rooted in that challenge is the goal to shorten the verification cycle. This requires new design and verification techniques. In this book, we address the functional correctness challenge within a ...
Assertion "pcb->snd_queuelen >= pbuf_clen(next->p)" failed at line 1111 in../Middlewares/Third_Party/LwIP/src/core/tcp_in.c Assertion "pbuf_free: p->ref > 0" failed at line 753 in ../Middlewares/Third...
快速傅里叶算法fftw源代码,采用各种优化技术如SIMD等
在c#上,使用ae的控件,实现feature矢量数据,tin,dem栅格数据的加载显示,代码完整
深入理解opencv源码包 包括该书全部完整工程源码 希望对大家有用
xcode配置iOS 11.4 开发包(15F79),亲测有用的资源。。=
HTC vive疑难技术问题
当程序监测到领导靠近你的办公桌时,屏幕会自动切换至工作模式(编辑器界面)。DemoBoss 站起身,正在走过来当他靠近时,获取面部图像并进行图像识别若图像被检测为 “老板”,则切换屏幕环境要求WebCameraPython3.5...
netcdf的c库,适用于linux64位系统(32位未知)
assertion-1.8.7.jar
System Verilog Assertion 简介 中文版的介绍 简单、全面的概括了SVA的基础知识
Converting a bitmap to a region - memory leak fix将一个位图转换成一个区域--内存泄露的修正(4KB)
CSV Parser CSV file how to parser example
System Verilog Assertion简介 简单、全面 中文文档 了解、上手SVA的上好资料