
<div class="container">
    <div><a ui-sref="CatagoriManagement" style="padding:20px">Home</a></div>
    <div >
            <a href="#/management/HR/1/catagori/{{catagoriById.id}}/createNews"> Add News</a>
            <div style="margin-top: 25px;">

                <table class="table" >
                    <thead>

                    <tr>
                        <tr>

                            <div ng-if="catagoriById.name == 'Office'">
                                <a href="#/management/catagori/5" style="float:left"><< Back </a>
                            </div>
                            <div ng-if="catagoriById.name == 'Outdoor Activity'">
                                <a href="#/management/catagori/1" style="float:left"><< Back </a>
                            </div>
                            <div ng-if="catagoriById.name == 'Projects'">
                                <a href="#/management/catagori/2" style="float:left"><< Back</a>
                            </div>
                            <div ng-if="catagoriById.name == 'Recruitments'">
                                <a href="#/management/catagori/4" style="float:left"><< Back </a>
                            </div>
                            <div ng-if="catagoriById.name == 'Office'">
                                <a href="#/management/catagori/2" style="float:right">Next >> </a>
                            </div>
                            <div ng-if="catagoriById.name == 'Outdoor Activity'">
                                <a href="#/management/catagori/4" style="float:right">Next >></a>
                            </div>
                            <div ng-if="catagoriById.name == 'Projects'">
                                <a href="#/management/catagori/5" style="float:right">Next >></a>
                            </div>
                            <div ng-if="catagoriById.name == 'Recruitments'">
                                <a href="#/management/catagori/1" style="float:right">Next >></a>
                            </div>
                            <td colspan="12"><h1 style="font-size: 30px;text-align: center">{{catagoriById.name}}</h1></td>
                        </tr>
                    <th>STT</th>
                    <th>News title</th>
                    <th>Create Date</th>
                    <th>Content</th>
                    <th>Edit</th>
                    <th>Delete</th>

                    </tr>
                    </thead>
                    <tbody>
                    <tr class="vide" ng-repeat="myNews in catagoriById.news">
                        <td>{{$index + 1}}</td>
                        <td>{{myNews.title}}</td>
                        <td>{{myNews.createdAt}}</td>
                        <td>{{myNews.content}}</td>
                        <td><a href="#/management/catagori/{{catagoriById.id}}/news/{{myNews.id}}" style="color:green;border: 1px solid black;padding: 10px;" >Edit</a> </td>
                        <td><button type="button"  style="color:red;border: 1px solid black;padding: 10px;" ng-click="deleteNews(myNews.id)">Delete</button> </td>
                    </tr>
                    </tbody>
                </table>
            </div>
    </div>

</div>
