我在php文件中的li标签内声明ng-class
时收到以下错误。
angularjs.js:107Error: [$parse:ueoe] http://errors.angularjs.org/1.4.6/$parse/ueoe?p0=%7B
at Error (native)
at http://oditek.in/crm/js/angularjs.js:6:416
at Object.s.peekToken (http://oditek.in/crm/js/angularjs.js:209:514)
at Object.s.object (http://oditek.in/crm/js/angularjs.js:208:336)
at Object.s.primary (http://oditek.in/crm/js/angularjs.js:205:503)
at Object.s.unary (http://oditek.in/crm/js/angularjs.js:205:342)
at Object.s.multiplicative (http://oditek.in/crm/js/angularjs.js:205:88)
at Object.s.additive (http://oditek.in/crm/js/angularjs.js:204:430)
at Object.s.relational (http://oditek.in/crm/js/angularjs.js:204:265)
at Object.s.equality (http://oditek.in/crm/js/angularjs.js:204:90) <a href="product.php#/dashboard" ng-class="{" active":="" $state.includes("dashboard")}"="">
我正在解释下面的代码。
<?php
if(in_array("Info",$userrights)){
//$class=(strpos($_SERVER['REQUEST_URI'],'product.php') || strpos($_SERVER['REQUEST_URI'],'product.php'))?'class="active"':'';
echo'<li><a href="product.php#/dashboard" ng-class="{"active": $state.includes("dashboard")}">E-Vouchers<b class="caret"></b></a>';
}
?>
<ul class="dropdown-menu">
<li ui-sref-active="active"><a ui-sref="dashboard">Dashboard</a></li>
<li ui-sref-active="active"><a ui-sref="code">Generate Voucher Code</a></li>
<li ui-sref-active="active"><a ui-sref="list">E-Voucher List</a></li>
</ul>
</li>
这里我的要求是当用户点击上面代码中的任何子菜单时,父菜单(i.e-E-Vouchers
)也将与子菜单一起获得活动课程。请帮助我。