如何将$ index observable“绑定”(存储)到我的observable中?(How to “bind” (store) the $index observable to my observable?)

我有一个foreach绑定,在我的数据中我有一个名为Level的可观察对象。 我怎么能将$index值存储在我的Level observable中? 我需要它,因为数组转到服务器端脚本,我不能指望订单将在最后保留。

我一直在谷歌搜索一段时间,但还没有找到任何相关的答案


I have a foreach binding, and in my data I have an observable called Level. How could I store the $index value in my Level observable? I would need it because the array goes to a server-side script, and Icannot expect that the order will be preserved at the end.

I've been googling for a while now but haven't found any related answer yet


原文:https://stackoverflow.com/questions/26059618
2024-04-21 14:04

相关问答

更多

如何整合APScheduler和Imp?(How to integrate APScheduler and Imp?)

自动检测模块名称中的某些内容出错了。 很难说是什么,但另一种方法是手动为它提供正确的查找路径作为字符串(例如“package.module:function”)。 如果可以这样做,则可以避免此问题。 Something in the automatic detection of the module name is going wrong. Hard to say what, but the alternative is to manually give it the proper lookup ...

Eclipse插件问题(Eclipse plugin issue)

务必确保正确关闭日食。 (1)首先你需要尝试这个 myeclipse.exe -clean 要么 或者, myeclipse.ini下行添加到顶部附近的myeclipse.ini文件中: -clean (2)如果问题仍然存在,则只需创建一个新工作区,然后导入其中的所有项目文件。 它肯定会工作:) 但如果它还没有解决的话 (3) 你需要重新安装日食 Always make sure that you shut down eclipse properly. (1)First of all you ne...

Mercurial Eclipse插件(Mercurial Eclipse Plugin)

MercurialEclipse 更新网站: https : //bitbucket.org/mercurialeclipse/update-site/raw/default/ 安装手册 如下所述(在注释中),名称是MercurialEclipse。 名称HgEclipse是Intland做的一个叉子,后来再次使用MercurialEclipse“并入”,MercurialEclipse在当前站点,Google代码和javaforge.com之间移动。 MercurialEclipse Updat...

JGraph是一个eclipse插件(JGraph in an eclipse plugin)

可以在SWT应用程序中使用Swing组件。 如果JGraph工作完美仍有待测试,我在谷歌上找不到任何积极的结果。 这是Eclipse上有关如何使用Swing组件的文章。 祝你好运。 It is possible to use Swing components in an SWT application. If JGraph works perfectly remains to be tested though, I couldn't find any positive results on goo...

如何使用eclipse JDT插件(How to use eclipse JDT plugin)

如果您尝试在eclipse插件项目中使用JDT库,则必须将org.eclipse.jdt.core添加到插件依赖项(在plugin.xml文件中)。 否则,如果您尝试将这些添加到Java应用程序中,则需要将这些添加到构建路径中。 右键单击该项目,然后选择“ 属性”>“构建路径”>“添加外部JAR” 这里只需添加Eclipse插件目录中的jdt库。 If you are trying to use the JDT libraries in an eclipse plugin project, you...

使用独立于eclipse的eclipse插件(Using eclipse plugin independent from eclipse)

是的,你可以如果: 您要使用的插件没有任何外部依赖关系=>它只是一个库插件 你想使用的插件和它的所有依赖项都在你的类路径中 在所有其他情况下没有。 由于许多插件至少使用OSGI / Equinox的核心概念(具有激活器),因此在独立的Java应用程序中使用它们将非常困难。 例如,SWT可以在eclipse之外使用。 Yes you can if: The plugin you want to use doesn't have any external dependencies => it's ju...

我安装了Eclipse IMP,eclipse ide无法打开(I installed Eclipse IMP, eclipse ide can't open)

我不确定IMP是否兼容日食伽利略(3.5)。 他们的安装页面提到了eclipse3.2 It is just .metadata crash of eclipse after installed Eclipse IMP

相关文章

更多

顶 lucene--创建index

这是我在lucene in action 中看到的,本来想翻译一下,但是翻译成汉语就没有原来的味道了。 ...

Solr4.7.2启动时的Index locked for write for core问题分析

Solr在启动时,通过多线程的方式加载core,在加载完每个core的配置文件后,实例化了一个Solr ...

Hibernate Search(基于version3.4)--第四章Mapping entities to the index structure

Mapping entities to the index structure 4.1. 映射一个实 ...

[Hadoop 2.2 + Solr 4.5]系列之三:MapReduce + Lucene 生成Index文件

[Hadoop 2.2 + Solr 4.5]系列之三:MapReduce + Lucene 生成In ...

利用SolrJ操作solr API完成index操作

使用SolrJ操作Solr会比利用httpClient来操作Solr要简单。SolrJ是封装了http ...

merge solr index &&&&& very import create new core

http://wiki.apache.org/solr/MergingSolrIndexes http ...

我的架构演化笔记 13:自己动手写Nutch-index插件导入数据到MongoDB

需求是导入数据到MongoDB. 1创建目录 在$Nutch_home/src/plugin ...

部署index.html,局域网能访问,远程连接超时

把index.html部署到web服务器,用公司的其他电脑访问“服务器IP:端口号”可以正常访问到in ...

index()方法默认是把所有数据全读出来,如何分类查看?

def index @banks = Bank.all#Bnka.find(:all,:cond ...

SOLR Performance Benchmarks – Single vs. Multi-core Index Shards

http://www.derivante.com/2009/05/05/solr-performanc ...

最新问答

更多

python的访问器方法有哪些

使用方法: class A(object): def foo(self,x): #类实例方法 print "executing foo(%s,%s)"%(self,x) @classmethod def class_foo(cls,x): #类方法 print "executing class_foo(%s,%s)"%(cls,x) @staticmethod def static_foo(x): #静态方法 print "executing static_foo(%s)"%x调用方法: a =

使用Zend Framework 2中的JOIN sql检索数据(Retrieve data using JOIN sql in Zend Framework 2)

我认为你必须将两个TableGetway传递给UserTable构造。 你必须改变Module.php看看: public function getServiceConfig() { return array( 'factories' => array( 'User\Model\UserTable' => function($sm) { $userTableGateway = $sm->get('UserTable

透明度错误IE11(Transparency bug IE11)

这是一个渲染错误,由使用透明度触发,使用bootstrap用于在聚焦控件周围放置蓝色光环的box-shadow属性。 可以通过添加以下类覆盖来解决它。 .form-control:hover { -webkit-box-shadow: 0px 0px 5px 0px rgba(0,0,255,1); -moz-box-shadow: 0px 0px 5px 0px rgba(0,0,255,1); box-shadow: 0px 0px 4px 0px rgba(0,0,255,1)

linux的基本操作命令。。。

ls 显示目录 mkdir 建立目录 cd 进入目录

响应navi重叠h1和nav上的h1链接不起作用(Responsive navi overlaps h1 and navi links on h1 isn't working)

将z-index设置为.main-nav这将解决您的重叠问题 .main-nav { position:relative; z-index:9; } set z-index to .main-nav This will fix your overlaping issue .main-nav { position:relative; z-index:9; }

在C中读取文件:“r”和“a +”标志的不同行为(Reading a File in C: different behavior for “r” and “a+” flags)

这是因为模式规范"a"打开一个文件以便追加,文件指针在末尾。 如果您尝试从此处读取,则由于文件指针位于EOF,因此没有数据。 您应该打开"r+"进行阅读和写作。 如果在写入之前读取整个文件,则在写入更多数据时,文件指针将正确定位以追加。 如果这还不够,请探索ftell()和fseek()函数。 That is because the mode spec "a" opens a file for appending, with the file pointer at the end. If you

NFC提供什么样的带宽?(What Kind of Bandwidth does NFC Provide?)

支持空中接口的数据速率是一回事。 在消除协议开销,等待eeprom写入以及所有需要时间的其他内容之后,您看到的数据速率是完全不同的故事。 长话短说,从标签读取或进行对等传输时的实际数据速率峰值约为2.5千字节/秒。 取决于具体的标签或对等技术,它可能比这慢很多。 The supported data-rates of the air-interface are one thing. The data-rate that you see after removing protocol overhe

元素上的盒子阴影行为(box-shadow behaviour on elements)

它看起来像只在Windows上的Chrome的错误。 我在Google Canary (Chrome 63)中也进行了测试,问题依然存在,所以有可能它不会很快修复。 这个问题是由overflow: auto引起的overflow: auto ,在你的情况下,它可以很容易地通过删除或设置为可见(默认)来解决。 但是 ,将鼠标悬停在右侧(顶部和底部)时,会出现滚动条。 一个解决方案可以设置overflow: hidden的身体,所以预期的结果是所需的。 我想指出,这不是一个很好的解决方案,但我建议暂

Laravel检查是否存在记录(Laravel Checking If a Record Exists)

这取决于您是否要以后与用户合作,或仅检查是否存在。 如果要使用用户对象(如果存在): $user = User::where('email', '=', Input::get('email'))->first(); if ($user === null) { // user doesn't exist } 如果你只想检查 if (User::where('email', '=', Input::get('email'))->count() > 0) { // user found

设置base64图像的大小javascript - angularjs(set size of a base64 image javascript - angularjs)

$scope.getData= function () { var reader = new FileReader(); reader.onload = $('input[type=file]')[0].files; var img = new Image(); img.src =(reader.onload[0].result); img.onload = function() { if(this.width > 640