Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/jquery/77.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/jsf-2/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Jquery angularJS x-可编辑基于状态的条件_Jquery_Css_Angularjs - Fatal编程技术网

Jquery angularJS x-可编辑基于状态的条件

Jquery angularJS x-可编辑基于状态的条件,jquery,css,angularjs,Jquery,Css,Angularjs,我实现了一些颜色类,以便状态更改tr <tr id="item" class="tRow" ng-class="{'status1':'red', 'status2:'green', 'status3:'yellow'}[item.status]" ng-repeat="item in items | filter:search | filter:{section_id:filter.section_id} |orderBy:orderByFilter:reverse | limitTo:

我实现了一些颜色类,以便状态更改
tr

<tr id="item" class="tRow" ng-class="{'status1':'red', 'status2:'green', 'status3:'yellow'}[item.status]" ng-repeat="item in items | filter:search | filter:{section_id:filter.section_id} |orderBy:orderByFilter:reverse | limitTo:limit" ng-show="checkPriceFilter(item.price)"> 

最好不要像这样混合使用Angular和jQuery。当status2处于活动状态超过一天左右时,您能澄清一下您所说的
是什么意思吗?它是基于某种日期变量还是?@dfsq OP在问题中提到他想使用AngularJS,但这是他在jQuery中尝试过的。@peter是的,它将基于某种日期变量或计数器。。还没有这样做。欢迎提出建议。首先,我试图抓住我的tr类来给它一个条件。我想我有点明白你想要实现的,但是没有任何代码很难理解。我建议你试着做一些能显示目的的东西,并将其添加到你的问题中。
$('#mainDiv tr').each(function()
{
  if ($(this).hasClass('green')) {
      //function
     }
});