همیشه جستجو و فیلتر کردن اطلاعات در پروژه ها یکی از ویژگی های مهم پروژه محسوب میشود.در این پروژه که توسط Angularjs طراحی و برنامه نویسی شده است.شما در این نمونه سورس کد میتوانید امکانی برای جستجو و فیلتر کردن اطلاعات برای لیست خود توسط انگولار جی اس پیاده سازی کنید.سورس کد کامل ضمیمه شده است امیدوارم استفاده کنید.
<!DOCTYPE hmtl> <html lang = "en"> <body ng-app = "myModule"> <nav class = "navbar navbar-default"> <div class = "container-fluid"> <a class = "navbar-brand" href = "<a href="https://www.mspsoft.com">ام اس پی سافت</a> " rel="nofollow">https://www.sourcecodester.com">Sourcecodester</a> </a> </div> </nav> <div class = "row" ng-controller = "myController"> <div class = "col-md-3"></div> <div class = "col-md-6 well"> <h3 class = "text-primary">Simple Search Filter Using AngularJS</h3> <hr style = "border-top:1px solid #000;"/> <form class="form-inline"> <div class="form-group"> <div class="input-group"> <div class="input-group-addon"><span class = "glyphicon glyphicon-search"></span></div> <input type="text" class="form-control" id="exampleInputAmount" placeholder="Enter Here" ng-model = "search"> </div> </div> </form> <table class = "table table-bordered alert-warning"> <thead> <tr> <th>زبان های برنامه نویسی</th> <th>سازنده</th> </tr> </thead> <tbody> <tr ng-repeat = "PLang in PLangs | filter: search"> <td>{{PLang.name}}</td> <td>{{PLang.creator}}</td> </tr> </tbody> </table> </div> </div> </body> </html>
هیچ دیدگاهی نوشته نشده است.