<commit_before><!DOCTYPE html>
<html lang="zh-CN">

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <!-- 上述3个meta标签*必须*放在最前面，任何其他内容都*必须*跟随其后！ -->
    <title>NiceFish</title>

    <!-- Bootstrap -->
    <link href="css/bootstrap.min.css" rel="stylesheet">
    <link href="css/style.css" rel="stylesheet">
    <style>
        .fa-weibo:before {
            content: "\F18A";
        }
        
         :after,
         :before {
            box-sizing: border-box;
        }
        
        .fa-video-camera:before {
            content: "\F03D";
        }
        /* .list-body .listli{
            list-style: none;
            border-bottom:1px solid #777; 
        } */
        
        .list-body .listli {
            list-style: none;
            height: 80px;
            font-size: 18px;
            border-bottom: 1px solid #ccc;
            margin: 20px 0;
        }
        /* .list-body .listli::after {
            content: 'gg';
            position: absolute;
            top: 0;
            left: 0px;
            right: 0px;
            bottom: 0px;
            height: 5px;
            border: 1px solid #fff;
        } */
        
        .list-body .listul {
            padding: 0px;
        }
        
        .little-list {
            font-size: 14px;
            margin: 10px 0;
        }
        
        .little-list span {
            padding-right: 15px;
        }
        
        .social-media .list-group-item,
        .qq-group .list-group-item {
            padding: 0;
        }
        
        .social-media .list-group-item a,
        .qq-group .list-group-item a {
            color: #555;
            display: block;
            padding: 10px 15px;
        }
        
        .qq-group .list-group-item:hover a {
            background: #f5f5f5;
        }
        
        .social-media .list-group-item:hover a {
            background: #f5f5f5;
        }
        
        .new-time:hover a {
            text-decoration: none;
        }
        
        .new-time {
            padding-left: 15px;
            padding-top: 1em;
        }
        
        .new-time li {
            list-style: none;
            height: 2em;
        }
        
        .btn-default {
            border-top-left-radius: 0;
            border-bottom-left-radius: 0;
        }
    </style>


</head>

<body>

    <!-- Static navbar -->
    <nav class="navbar navbar-default navbar-static-top">
        <div class="container">
            <div class="navbar-header">
                <a class="navbar-brand" href="#">NiceFish</a>
            </div>
            <div id="navbar" class="navbar-collapse collapse">
                <ul class="nav navbar-nav">
                    <li class="active">
                        <a href="#">动态</a>
                    </li>
                    <li>
                        <a href="#about">集成图表</a>
                    </li>
                    <li>
                        <a href="#contact">高德地图</a>
                    </li>
                    <li>
                        <a href="#contact">jsplumb</a>
                    </li>
                    <li>
                        <a href="#contact">NiceFish</a>
                    </li>
                    <li>
                        <a href="#contact">CodeBe</a>
                    </li>

                </ul>
                <ul class="nav navbar-nav navbar-right">
                    <li>
                        <a href="F:/workspace/cms/login.html">登录</a>
                    </li>
                    <li>
                        <a href="./">注册
                            <span class="sr-only">(current)</span>
                        </a>
                    </li>
                </ul>
            </div>
            <!--/.nav-collapse -->
        </div>
    </nav>

    <div class="container">
        <div class="row" id="con-row">
            <div class="col-md-9">
                <div class="row">
                    <div class="col-md-10">
                        <div class="input-group">
                            <input type="text" class="form-control" placeholder="搜索">
                            <span class="input-group-btn">
                                <button class="btn btn-default" type="button">
                                    <span class="glyphicon glyphicon-search" aria-hidden="true"></span>搜索</span>
                            </button>
                            </span>
                        </div>
                    </div>
                    <div class="col-md-2">
                        <button type="button" class="btn btn-success">
                            <span class="glyphicon glyphicon-pencil" aria-hidden="true"></span>
                            <span>发布文章</span>
                        </button>
                    </div>
                </div>


                <div class="list list-body">
                    <ul class="listul" id="list-content">

                    </ul>

                </div>

                <nav aria-label="Page navigation">
                    <ul class="pagination" id="pagination">

                    </ul>
                </nav>

            </div>
            <div class="col-md-3">
                <div class="panel panel-default">
                    <div class="panel-heading">
                        <h3 class="panel-title">社交媒体</h3>
                    </div>
                    <!-- List group -->
                    <ul class="list-group social-media">
                        <li class="list-group-item">
                            <a class="weibo" href="http://www.weibo.com">
                                <i aria-hidden="true" class="fa fa-weibo">
                                </i> 官方微博
                            </a>
                        </li>
                        <li class="list-group-item">
                            <a class="weibo">
                                <i _ngcontent-c2="" aria-hidden="true" class="fa fa-video-camera"></i>优酷视频教程</a>
                        </li>
                        <li class="list-group-item">
                            <a class="weibo">油管视频教程</a>
                        </li>
                        <li class="list-group-item">
                            <a class="weibo">我的主页</a>
                        </li>
                    </ul>
                </div>

                <div class="panel panel-default">
                    <div class="panel-heading">
                        <h3 class="panel-title">QQ群-请勿加多个</h3>
                    </div>
                    <!-- List group -->
                    <ul class="list-group qq-group">
                        <li class="list-group-item">
                            <a class="weibo" href="http://www.weibo.com">官方微博</a>
                        </li>
                        <li class="list-group-item">
                            <a class="weibo">官方微博</a>
                        </li>
                        <li class="list-group-item">
                            <a class="weibo">官方微博</a>
                        </li>
                        <li class="list-group-item">
                            <a class="weibo">官方微博</a>
                        </li>

                    </ul>
                </div>
                <div class="panel panel-default">
                    <div class="panel-heading">
                        <h3 class="panel-title">2017-10-18 20:46:50</h3>
                    </div>
                    <!-- List group -->
                    <ul class="list-group new-time">
                        <li>访问总数：16742169</li>
                        <li>文章总数：2458</li>
                        <li>评论总数：7880</li>
                        <li>会员总数：12772</li>
                        <li>在线访客：187</li>
                        <li>在线会员：2</li>
                        <li>在线记录：268</li>
                    </ul>
                </div>

            </div>
        </div>
    </div>

    <div class="footer">
        <div class="container">
            <div class="row">
                <p style="font-size:15px">
                    <span style="color:#fff">Powered by </span>
                    <a href="http://www.baidu.com" style="color:#25457C">NiceFish</a>
                </p>
            </div>
        </div>
    </div>

    <script src="js/jquery-3.2.1.js"></script>
    <script>
        var urlPrefix = 'http://4172.16.17.32/api';
        var current = 0;
        var pages;
        //获取数据并展示
        var getData = function(pageNow) {
            // 获取pageNow页的数据
            $.get(`${urlPrefix}/articles/list?pageNow=${pageNow}`, function(res, statusText, xhr) {
                // console.log(res)
                // console.log(statusText)
                // console.log(xhr)
                var data = res.data;

                /*
                <li class="listli">
                    <a href="###">如果你是新手，请务必先看完本项目的视频教程</a>
                    <div class="little-list">
                        <span class="glyphicon glyphicon glyphicon-thumbs-up" aria-hidden="true">5555</span>
                        <span class="glyphicon glyphicon glyphicon-comment" aria-hidden="true">10000</span>
                        <span class="glyphicon glyphicon glyphicon-eye-open" aria-hidden="true">10000</span>
                        <span>大漠穷秋</span>
                        <span>2017-05-17 10:44</span>
                    </div>
                </li>
                ES5 => ECMAScript 5
                ES6 => ECMAScript 6/ECMAScript 2015
                模板字符串
                */
                //渲染数据
                var list = '';
                for (var i = 0; i < data.length; i++) {
                    var d = data[i];
                    // var li = '<li class="listli">';
                    // li += '<a href="###">' + d.title + '</a>';
                    // li += '<div class="little-list">';
                    // li += '<span class="glyphicon glyphicon glyphicon-thumbs-up" aria-hidden="true">' + d.good + '</span>';
                    // li += '<span class="glyphicon glyphicon glyphicon-comment" aria-hidden="true">' + d.comment + '</span>';
                    // li += '<span class="glyphicon glyphicon glyphicon-eye-open" aria-hidden="true">' + d.view + '</span>';
                    // li += '<span>' + d.author + '</span>';
                    // li += '<span>' + d.time + '</span>';
                    // li += '</div>';
                    // li += '</li>';

                    var li = `<li class="listli">
                            <a href="###">${d.title}</a>
                            <div class="little-list">
                                <span class="glyphicon glyphicon glyphicon-thumbs-up" aria-hidden="true">${d.up}</span>
                                <span class="glyphicon glyphicon glyphicon-comment" aria-hidden="true">${d.comment}</span>
                                <span class="glyphicon glyphicon glyphicon-eye-open" aria-hidden="true">${d.view}</span>
                                <span>${d.author}</span>
                                <span>${d.publish_time}</span>
                            </div>
                        </li>`;


                    list += li;
                }

                $('#list-content').html(list);

                // 展示分页
                pages = res.pages;
                var pagination = `<li>
                                <a data-pageno="prev" aria-label="Previous">
                                    <span aria-hidden="true">&laquo;</span>
                                </a>
                            </li>`;
                for (var index = 0; index < pages.pageNumber; index++) {
                    var num = index + 1;
                    pagination += `<li><a data-pageno="${index}">${num}</a></li>`;
                }
                pagination += `<li>
                                <a data-pageno="next" aria-label="Next">
                                    <span aria-hidden="true">&raquo;</span>
                                </a>
                            </li>`;
                $('#pagination').html(pagination);
                //保存当前页的值
                current = pages.pageNow;
            });
        }


        //事件绑定，不生效的原因是，在绑定事件的时候，li元素还不存在
        // $('#pagination li').on('click', function (e) {
        //     console.log(e)
        // });
        // 事件委托   事件冒泡
        $('#pagination').on('click', 'a', function(e) {
            console.log(this)
            var pageNow = $(this).attr('data-pageno')

            if (pageNow === 'next') {
                //计算出下一页的页码
                var next = current + 1;
                //判断下一页页码是不是越界了，如果越界了，就不加1了
                if (next >= pages.pageNumber) {
                    next = current;
                }
                getData(next)
            } else if (pageNow === 'prev') {
                var prev = current - 1;
                if (prev < 0) {
                    prev = 0;
                }
                getData(prev)
            } else {
                getData(pageNow)
            }


        })

        getData(current);
    </script>

</body>

</html><commit_msg>container<commit_after><!DOCTYPE html>
<html lang="zh-CN">

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <!-- 上述3个meta标签*必须*放在最前面，任何其他内容都*必须*跟随其后！ -->
    <title>NiceFish</title>

    <!-- Bootstrap -->
    <link href="css/bootstrap.min.css" rel="stylesheet">
    <link href="css/style.css" rel="stylesheet">
    <style>
        .fa-weibo:before {
            content: "\F18A";
        }
        
         :after,
         :before {
            box-sizing: border-box;
        }
        
        .fa-video-camera:before {
            content: "\F03D";
        }
        /* .list-body .listli{
            list-style: none;
            border-bottom:1px solid #777; 
        } */
        
        .list-body .listli {
            list-style: none;
            height: 80px;
            font-size: 18px;
            border-bottom: 1px solid #ccc;
            margin: 20px 0;
        }
        /* .list-body .listli::after {
            content: 'gg';
            position: absolute;
            top: 0;
            left: 0px;
            right: 0px;
            bottom: 0px;
            height: 5px;
            border: 1px solid #fff;
        } */
        
        .list-body .listul {
            padding: 0px;
        }
        
        .little-list {
            font-size: 14px;
            margin: 10px 0;
        }
        
        .little-list span {
            padding-right: 15px;
        }
        
        .social-media .list-group-item,
        .qq-group .list-group-item {
            padding: 0;
        }
        
        .social-media .list-group-item a,
        .qq-group .list-group-item a {
            color: #555;
            display: block;
            padding: 10px 15px;
        }
        
        .qq-group .list-group-item:hover a {
            background: #f5f5f5;
        }
        
        .social-media .list-group-item:hover a {
            background: #f5f5f5;
        }
        
        .new-time:hover a {
            text-decoration: none;
        }
        
        .new-time {
            padding-left: 15px;
            padding-top: 1em;
        }
        
        .new-time li {
            list-style: none;
            height: 2em;
        }
        
        .btn-default {
            border-top-left-radius: 0;
            border-bottom-left-radius: 0;
        }
    </style>


</head>

<body>

    <!-- Static navbar -->
    <nav class="navbar navbar-default navbar-static-top">
        <div class="container">
            <div class="navbar-header">
                <a class="navbar-brand" href="#">NiceFish</a>
            </div>
            <div id="navbar" class="navbar-collapse collapse">
                <ul class="nav navbar-nav">
                    <li class="active">
                        <a href="#">动态</a>
                    </li>
                    <li>
                        <a href="#about">集成图表</a>
                    </li>
                    <li>
                        <a href="#contact">高德地图</a>
                    </li>
                    <li>
                        <a href="#contact">jsplumb</a>
                    </li>
                    <li>
                        <a href="#contact">NiceFish</a>
                    </li>
                    <li>
                        <a href="#contact">CodeBe</a>
                    </li>

                </ul>
                <ul class="nav navbar-nav navbar-right">
                    <li>
                        <a href="F:/workspace/cms/login.html">登录</a>
                    </li>
                    <li>
                        <a href="./">注册
                            <span class="sr-only">(current)</span>
                        </a>
                    </li>
                </ul>
            </div>
            <!--/.nav-collapse -->
        </div>
    </nav>

    <div class="container" id="con-row">
        <div class="row">
            <div class="col-md-9">
                <div class="row">
                    <div class="col-md-10">
                        <div class="input-group">
                            <input type="text" class="form-control" placeholder="搜索">
                            <span class="input-group-btn">
                                <button class="btn btn-default" type="button">
                                    <span class="glyphicon glyphicon-search" aria-hidden="true"></span>搜索</span>
                            </button>
                            </span>
                        </div>
                    </div>
                    <div class="col-md-2">
                        <button type="button" class="btn btn-success">
                            <span class="glyphicon glyphicon-pencil" aria-hidden="true"></span>
                            <span>发布文章</span>
                        </button>
                    </div>
                </div>


                <div class="list list-body">
                    <ul class="listul" id="list-content">

                    </ul>

                </div>

                <nav aria-label="Page navigation">
                    <ul class="pagination" id="pagination">

                    </ul>
                </nav>

            </div>
            <div class="col-md-3">
                <div class="panel panel-default">
                    <div class="panel-heading">
                        <h3 class="panel-title">社交媒体</h3>
                    </div>
                    <!-- List group -->
                    <ul class="list-group social-media">
                        <li class="list-group-item">
                            <a class="weibo" href="http://www.weibo.com">
                                <i aria-hidden="true" class="fa fa-weibo">
                                </i> 官方微博
                            </a>
                        </li>
                        <li class="list-group-item">
                            <a class="weibo">
                                <i _ngcontent-c2="" aria-hidden="true" class="fa fa-video-camera"></i>优酷视频教程</a>
                        </li>
                        <li class="list-group-item">
                            <a class="weibo">油管视频教程</a>
                        </li>
                        <li class="list-group-item">
                            <a class="weibo">我的主页</a>
                        </li>
                    </ul>
                </div>

                <div class="panel panel-default">
                    <div class="panel-heading">
                        <h3 class="panel-title">QQ群-请勿加多个</h3>
                    </div>
                    <!-- List group -->
                    <ul class="list-group qq-group">
                        <li class="list-group-item">
                            <a class="weibo" href="http://www.weibo.com">官方微博</a>
                        </li>
                        <li class="list-group-item">
                            <a class="weibo">官方微博</a>
                        </li>
                        <li class="list-group-item">
                            <a class="weibo">官方微博</a>
                        </li>
                        <li class="list-group-item">
                            <a class="weibo">官方微博</a>
                        </li>

                    </ul>
                </div>
                <div class="panel panel-default">
                    <div class="panel-heading">
                        <h3 class="panel-title">2017-10-18 20:46:50</h3>
                    </div>
                    <!-- List group -->
                    <ul class="list-group new-time">
                        <li>访问总数：16742169</li>
                        <li>文章总数：2458</li>
                        <li>评论总数：7880</li>
                        <li>会员总数：12772</li>
                        <li>在线访客：187</li>
                        <li>在线会员：2</li>
                        <li>在线记录：268</li>
                    </ul>
                </div>

            </div>
        </div>
    </div>

    <div class="footer">
        <div class="container">
            <div class="row">
                <p style="font-size:15px">
                    <span style="color:#fff">Powered by </span>
                    <a href="http://www.baidu.com" style="color:#25457C">NiceFish</a>
                </p>
            </div>
        </div>
    </div>

    <script src="js/jquery-3.2.1.js"></script>
    <script>
        var urlPrefix = 'http://192.168.127.12/api';
        var current = 0;
        var pages;
        //获取数据并展示
        var getData = function(pageNow) {
            // 获取pageNow页的数据
            $.get(`${urlPrefix}/articles/list?pageNow=${pageNow}`, function(res, statusText, xhr) {
                // console.log(res)
                // console.log(statusText)
                // console.log(xhr)
                var data = res.data;

                /*
                <li class="listli">
                    <a href="###">如果你是新手，请务必先看完本项目的视频教程</a>
                    <div class="little-list">
                        <span class="glyphicon glyphicon glyphicon-thumbs-up" aria-hidden="true">5555</span>
                        <span class="glyphicon glyphicon glyphicon-comment" aria-hidden="true">10000</span>
                        <span class="glyphicon glyphicon glyphicon-eye-open" aria-hidden="true">10000</span>
                        <span>大漠穷秋</span>
                        <span>2017-05-17 10:44</span>
                    </div>
                </li>
                ES5 => ECMAScript 5
                ES6 => ECMAScript 6/ECMAScript 2015
                模板字符串
                */
                //渲染数据
                var list = '';
                for (var i = 0; i < data.length; i++) {
                    var d = data[i];
                    // var li = '<li class="listli">';
                    // li += '<a href="###">' + d.title + '</a>';
                    // li += '<div class="little-list">';
                    // li += '<span class="glyphicon glyphicon glyphicon-thumbs-up" aria-hidden="true">' + d.good + '</span>';
                    // li += '<span class="glyphicon glyphicon glyphicon-comment" aria-hidden="true">' + d.comment + '</span>';
                    // li += '<span class="glyphicon glyphicon glyphicon-eye-open" aria-hidden="true">' + d.view + '</span>';
                    // li += '<span>' + d.author + '</span>';
                    // li += '<span>' + d.time + '</span>';
                    // li += '</div>';
                    // li += '</li>';

                    var li = `<li class="listli">
                            <a href="###">${d.title}</a>
                            <div class="little-list">
                                <span class="glyphicon glyphicon glyphicon-thumbs-up" aria-hidden="true">${d.up}</span>
                                <span class="glyphicon glyphicon glyphicon-comment" aria-hidden="true">${d.comment}</span>
                                <span class="glyphicon glyphicon glyphicon-eye-open" aria-hidden="true">${d.view}</span>
                                <span>${d.author}</span>
                                <span>${d.publish_time}</span>
                            </div>
                        </li>`;


                    list += li;
                }

                $('#list-content').html(list);

                // 展示分页
                pages = res.pages;
                var pagination = `<li>
                                <a data-pageno="prev" aria-label="Previous">
                                    <span aria-hidden="true">&laquo;</span>
                                </a>
                            </li>`;
                for (var index = 0; index < pages.pageNumber; index++) {
                    var num = index + 1;
                    pagination += `<li><a data-pageno="${index}">${num}</a></li>`;
                }
                pagination += `<li>
                                <a data-pageno="next" aria-label="Next">
                                    <span aria-hidden="true">&raquo;</span>
                                </a>
                            </li>`;
                $('#pagination').html(pagination);
                //保存当前页的值
                current = pages.pageNow;
            });
        }


        //事件绑定，不生效的原因是，在绑定事件的时候，li元素还不存在
        // $('#pagination li').on('click', function (e) {
        //     console.log(e)
        // });
        // 事件委托   事件冒泡
        $('#pagination').on('click', 'a', function(e) {
            console.log(this)
            var pageNow = $(this).attr('data-pageno')

            if (pageNow === 'next') {
                //计算出下一页的页码
                var next = current + 1;
                //判断下一页页码是不是越界了，如果越界了，就不加1了
                if (next >= pages.pageNumber) {
                    next = current;
                }
                getData(next)
            } else if (pageNow === 'prev') {
                var prev = current - 1;
                if (prev < 0) {
                    prev = 0;
                }
                getData(prev)
            } else {
                getData(pageNow)
            }


        })

        getData(current);
    </script>

</body>

</html>
{'fraction_non_alphanumeric': 0.14421737985021263, 'fraction_numerical': 0.012833540325919235, 'mean_word_length': 0.918694490576937, 'pattern_counts': {'":': 0, '<': 535, '<?xml version=': 0, '>': 535, 'https://': 0, 'lorem ipsum': 0, 'www.': 6, 'xml': 0}, 'pii_count': 2, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 14, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6379725', 'n_tokens_mistral': 7987, 'n_tokens_neox': 7370, 'n_words': 1285}