调整页面
This commit is contained in:
78
README.md
78
README.md
@@ -1,78 +1,2 @@
|
||||
<p align="center"><img src="https://res.cloudinary.com/dtfbvvkyp/image/upload/v1566331377/laravel-logolockup-cmyk-red.svg" width="400"></p>
|
||||
自然所
|
||||
|
||||
<p align="center">
|
||||
<a href="https://travis-ci.org/laravel/framework"><img src="https://travis-ci.org/laravel/framework.svg" alt="Build Status"></a>
|
||||
<a href="https://packagist.org/packages/laravel/framework"><img src="https://poser.pugx.org/laravel/framework/d/total.svg" alt="Total Downloads"></a>
|
||||
<a href="https://packagist.org/packages/laravel/framework"><img src="https://poser.pugx.org/laravel/framework/v/stable.svg" alt="Latest Stable Version"></a>
|
||||
<a href="https://packagist.org/packages/laravel/framework"><img src="https://poser.pugx.org/laravel/framework/license.svg" alt="License"></a>
|
||||
</p>
|
||||
|
||||
## About Laravel
|
||||
|
||||
Laravel is a web application framework with expressive, elegant syntax. We believe development must be an enjoyable and creative experience to be truly fulfilling. Laravel takes the pain out of development by easing common tasks used in many web projects, such as:
|
||||
|
||||
- [Simple, fast routing engine](https://laravel.com/docs/routing).
|
||||
- [Powerful dependency injection container](https://laravel.com/docs/container).
|
||||
- Multiple back-ends for [session](https://laravel.com/docs/session) and [cache](https://laravel.com/docs/cache) storage.
|
||||
- Expressive, intuitive [database ORM](https://laravel.com/docs/eloquent).
|
||||
- Database agnostic [schema migrations](https://laravel.com/docs/migrations).
|
||||
- [Robust background job processing](https://laravel.com/docs/queues).
|
||||
- [Real-time event broadcasting](https://laravel.com/docs/broadcasting).
|
||||
|
||||
Laravel is accessible, powerful, and provides tools required for large, robust applications.
|
||||
|
||||
## Learning Laravel
|
||||
|
||||
Laravel has the most extensive and thorough [documentation](https://laravel.com/docs) and video tutorial library of all modern web application frameworks, making it a breeze to get started with the framework.
|
||||
|
||||
If you don't feel like reading, [Laracasts](https://laracasts.com) can help. Laracasts contains over 1500 video tutorials on a range of topics including Laravel, modern PHP, unit testing, and JavaScript. Boost your skills by digging into our comprehensive video library.
|
||||
|
||||
## Laravel Sponsors
|
||||
|
||||
We would like to extend our thanks to the following sponsors for funding Laravel development. If you are interested in becoming a sponsor, please visit the Laravel [Patreon page](https://patreon.com/taylorotwell).
|
||||
|
||||
- **[Vehikl](https://vehikl.com/)**
|
||||
- **[Tighten Co.](https://tighten.co)**
|
||||
- **[Kirschbaum Development Group](https://kirschbaumdevelopment.com)**
|
||||
- **[64 Robots](https://64robots.com)**
|
||||
- **[Cubet Techno Labs](https://cubettech.com)**
|
||||
- **[Cyber-Duck](https://cyber-duck.co.uk)**
|
||||
- **[British Software Development](https://www.britishsoftware.co)**
|
||||
- **[Webdock, Fast VPS Hosting](https://www.webdock.io/en)**
|
||||
- **[DevSquad](https://devsquad.com)**
|
||||
- [UserInsights](https://userinsights.com)
|
||||
- [Fragrantica](https://www.fragrantica.com)
|
||||
- [SOFTonSOFA](https://softonsofa.com/)
|
||||
- [User10](https://user10.com)
|
||||
- [Soumettre.fr](https://soumettre.fr/)
|
||||
- [CodeBrisk](https://codebrisk.com)
|
||||
- [1Forge](https://1forge.com)
|
||||
- [TECPRESSO](https://tecpresso.co.jp/)
|
||||
- [Runtime Converter](http://runtimeconverter.com/)
|
||||
- [WebL'Agence](https://weblagence.com/)
|
||||
- [Invoice Ninja](https://www.invoiceninja.com)
|
||||
- [iMi digital](https://www.imi-digital.de/)
|
||||
- [Earthlink](https://www.earthlink.ro/)
|
||||
- [Steadfast Collective](https://steadfastcollective.com/)
|
||||
- [We Are The Robots Inc.](https://watr.mx/)
|
||||
- [Understand.io](https://www.understand.io/)
|
||||
- [Abdel Elrafa](https://abdelelrafa.com)
|
||||
- [Hyper Host](https://hyper.host)
|
||||
- [Appoly](https://www.appoly.co.uk)
|
||||
- [OP.GG](https://op.gg)
|
||||
|
||||
## Contributing
|
||||
|
||||
Thank you for considering contributing to the Laravel framework! The contribution guide can be found in the [Laravel documentation](https://laravel.com/docs/contributions).
|
||||
|
||||
## Code of Conduct
|
||||
|
||||
In order to ensure that the Laravel community is welcoming to all, please review and abide by the [Code of Conduct](https://laravel.com/docs/contributions#code-of-conduct).
|
||||
|
||||
## Security Vulnerabilities
|
||||
|
||||
If you discover a security vulnerability within Laravel, please send an e-mail to Taylor Otwell via [taylor@laravel.com](mailto:taylor@laravel.com). All security vulnerabilities will be promptly addressed.
|
||||
|
||||
## License
|
||||
|
||||
The Laravel framework is open-sourced software licensed under the [MIT license](https://opensource.org/licenses/MIT).
|
||||
|
||||
97
app/Helpers/function.php
Normal file
97
app/Helpers/function.php
Normal file
@@ -0,0 +1,97 @@
|
||||
<?php
|
||||
|
||||
use App\Models\Category;
|
||||
use App\Models\Article;
|
||||
|
||||
function getOneCategory($categoryId, $return = '')
|
||||
{
|
||||
$category = Category::find($categoryId);
|
||||
if ($category) {
|
||||
if ($return) {
|
||||
return $category->{$return};
|
||||
}
|
||||
|
||||
return $category;
|
||||
}
|
||||
|
||||
return new Category;
|
||||
}
|
||||
|
||||
/**
|
||||
* Notes: 获取文章分类详情
|
||||
* @Author: 玄尘
|
||||
* @Date : 2020/9/10 13:21
|
||||
* @param $categoryId
|
||||
* @param string $result
|
||||
* @return \App\Models\Article
|
||||
*/
|
||||
function getOneArticleBYCate($categoryId, $result = '')
|
||||
{
|
||||
$info = Article::where('category_id', $categoryId)->latest('sort')->latest()->first();
|
||||
|
||||
if ($info) {
|
||||
if ($result) {
|
||||
return $info->{$result};
|
||||
}
|
||||
|
||||
return $info;
|
||||
} else {
|
||||
return '';
|
||||
}
|
||||
|
||||
return new Article;
|
||||
}
|
||||
|
||||
/**
|
||||
* Notes: 获取分类下的文章
|
||||
* @Author: 玄尘
|
||||
* @Date : 2020/9/10 10:05
|
||||
* @param $categoryId
|
||||
* @param $take
|
||||
* @return \App\Models\Article
|
||||
*/
|
||||
function getArticlesBYCate($categoryId, $take = 8, $mark = 'one')
|
||||
{
|
||||
if ($mark == 'one') {
|
||||
$articles = Article::where('category_id', $categoryId)
|
||||
->where('status', 1)
|
||||
->latest('sort')
|
||||
->latest()
|
||||
->take($take)
|
||||
->get();
|
||||
} else {
|
||||
$cate = Category::find($categoryId);
|
||||
$ids = $cate->getAllChildrenId();
|
||||
|
||||
$articles = Article::whereIn('category_id', $ids)
|
||||
->where('status', 1)
|
||||
->latest('sort')
|
||||
->latest()
|
||||
->take($take)
|
||||
->get();
|
||||
}
|
||||
|
||||
return $articles;
|
||||
}
|
||||
|
||||
//获取子分类
|
||||
function getCateChild($categoryId)
|
||||
{
|
||||
return Category::where('status', 1)
|
||||
->where('parent_id', $categoryId)
|
||||
->orderBy('order', 'asc')
|
||||
->get();
|
||||
}
|
||||
|
||||
//获取顶级分类
|
||||
function getTopCate($categoryId)
|
||||
{
|
||||
$parent = Category::find($categoryId);
|
||||
|
||||
while ($parent->parent_id != 0) {
|
||||
$parent = $parent->parent;
|
||||
}
|
||||
|
||||
return $parent;
|
||||
}
|
||||
|
||||
@@ -10,7 +10,7 @@ class CategoryController extends Controller
|
||||
|
||||
/**
|
||||
* 显示分类
|
||||
* @param Category $category [description]
|
||||
* @param Category $category [description]
|
||||
* @return [type] [description]
|
||||
*/
|
||||
public function index(Category $category)
|
||||
@@ -18,15 +18,15 @@ class CategoryController extends Controller
|
||||
if ($category->type == Category::TYPE_SHOW && $category->article_id) {
|
||||
return redirect("articles/" . $category->article_id);
|
||||
} else {
|
||||
$articles = $category->relations(Category::TYPE_ARTICLE)->paginate();
|
||||
$articles = $category->relations(Category::TYPE_ARTICLE)->paginate(2);
|
||||
$parent = $category;
|
||||
if ($category->childrens->isEmpty()) {
|
||||
if ($parent->childrens->isEmpty()) {
|
||||
$parent = $category->parent;
|
||||
}
|
||||
|
||||
$advert = Advert::where('category_id',73)->first();
|
||||
$advert = Advert::where('category_id', 73)->first();
|
||||
|
||||
return view('category.show', compact('articles', 'category', 'parent','advert'));
|
||||
return view('category.show', compact('articles', 'category', 'parent'));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -19,18 +19,19 @@ class Controller extends BaseController
|
||||
{
|
||||
//顶部分类
|
||||
$categorys = Category::where('status', 1)
|
||||
->whereIn('type', [Category::TYPE_ARTICLE, Category::TYPE_SHOW])
|
||||
->where('top_show', 1)
|
||||
->orderBy('order', 'desc')
|
||||
->select('id', 'title')
|
||||
->get();
|
||||
->whereIn('type', [Category::TYPE_ARTICLE, Category::TYPE_SHOW])
|
||||
->where('top_show', 1)
|
||||
->latest('order')
|
||||
->select('id', 'title')
|
||||
->get();
|
||||
|
||||
//地步友情链接
|
||||
if (url()->current() == route('index.index')){
|
||||
if (url()->current() == route('index.index')) {
|
||||
$adverts = Advert::where('category_id', 72)->get();
|
||||
}else{
|
||||
} else {
|
||||
$adverts = Advert::where('category_id', 73)->get();
|
||||
}
|
||||
|
||||
View::share('all_categorys', $categorys);
|
||||
View::share('adverts', $adverts);
|
||||
}
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
namespace App\Http\Controllers;
|
||||
|
||||
use App\Models\Advert;
|
||||
use App\Models\Article;
|
||||
use App\Models\Category;
|
||||
use App\Models\Link;
|
||||
@@ -16,30 +17,23 @@ class IndexController extends Controller
|
||||
*/
|
||||
public function index()
|
||||
{
|
||||
$xwdt = $this->getArticle([53]); //新闻动态
|
||||
$kjpt = $this->getArticle([18]); //科技平台
|
||||
$zcjc = $this->getArticle([8]); //政府决策服务
|
||||
$zmzj = $this->getArticle([74, 127, 88]); //专家学者
|
||||
$tjgg = $this->getArticle([54]); //通知公告
|
||||
$kjlt = $this->getArticle([58]); //科技发展论坛
|
||||
$cxtd = $this->getArticle(Category::find(43)->getAllChildrenId(), 5); //创新团队
|
||||
$info = Article::where('category_id', 1)->first(); //简介
|
||||
|
||||
$kxyts = $this->getArticle(Category::find(17)->getAllChildrenId(), 10); //科学研究与特色品牌建设
|
||||
$yjzx = $this->getArticle([61], 2); //研究中心
|
||||
//研究中心
|
||||
$links = Link::get();
|
||||
|
||||
return view('index.index', compact('links', 'xwdt', 'kjpt', 'zcjc', 'zmzj', 'tjgg', 'kjlt', 'tjgg', 'kjlt', 'info', 'kxyts', 'cxtd', 'yjzx'));
|
||||
$adverts = Advert::where('category_id', 72)->latest('sort')->get();
|
||||
$lt_adverts = Advert::where('category_id', 175)->latest('sort')->get();
|
||||
|
||||
return view('index.index', compact('links', 'adverts', 'lt_adverts'));
|
||||
}
|
||||
|
||||
//通用获取文章
|
||||
public function getArticle($category_ids, $take = 3)
|
||||
{
|
||||
return Article::whereIn('category_id', $category_ids)
|
||||
->select('id', 'description', 'title', 'created_at', 'cover', 'content')
|
||||
->orderBy('created_at', 'desc')
|
||||
->take($take)
|
||||
->get();
|
||||
->select('id', 'description', 'title', 'created_at', 'cover', 'content')
|
||||
->orderBy('created_at', 'desc')
|
||||
->take($take)
|
||||
->get();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -7,8 +7,14 @@ use App\Models\Traits\HasOneCover;
|
||||
|
||||
class Article extends Model
|
||||
{
|
||||
|
||||
use HasOneCover, BelongsToCategory;
|
||||
|
||||
public function getLinkAttribute()
|
||||
{
|
||||
return route('article.show', $this);
|
||||
}
|
||||
|
||||
public function get_content_cover()
|
||||
{
|
||||
preg_match("/<img.*?src=\"([^\"]+)\"[^>].*?>/isU", str_ireplace("\\", "", $this->content), $matches);
|
||||
@@ -41,6 +47,7 @@ class Article extends Model
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return $path;
|
||||
|
||||
}
|
||||
|
||||
@@ -7,17 +7,22 @@ use Encore\Admin\Traits\ModelTree;
|
||||
|
||||
class Category extends Model
|
||||
{
|
||||
|
||||
use AdminBuilder, ModelTree;
|
||||
|
||||
public const TYPES = [
|
||||
'article' => '文章列表',
|
||||
'show' => '文章详情',
|
||||
'advert' => '广告',
|
||||
];
|
||||
|
||||
public const TYPE_SHOW = 'show';
|
||||
public const TYPE_SHOW = 'show';
|
||||
public const TYPE_ARTICLE = 'article';
|
||||
public const TYPE_ADVERT = 'advert';
|
||||
public const TYPES = [
|
||||
self::TYPE_ARTICLE => '文章列表',
|
||||
self::TYPE_SHOW => '文章详情',
|
||||
self::TYPE_ADVERT => '图片',
|
||||
];
|
||||
|
||||
public function getLinkAttribute()
|
||||
{
|
||||
return route('category.show', $this);
|
||||
}
|
||||
|
||||
/**
|
||||
* 关联的数据
|
||||
@@ -27,7 +32,7 @@ class Category extends Model
|
||||
{
|
||||
switch ($this->type) {
|
||||
case self::TYPE_SHOW:
|
||||
return $this->hasOne(Article::class)->where('id',$this->article_id);
|
||||
return $this->hasOne(Article::class)->where('id', $this->article_id);
|
||||
break;
|
||||
case self::TYPE_ARTICLE:
|
||||
return $this->hasMany(Article::class);
|
||||
@@ -42,12 +47,12 @@ class Category extends Model
|
||||
|
||||
public function childrens()
|
||||
{
|
||||
return $this->hasMany(self::class,'parent_id');
|
||||
return $this->hasMany(self::class, 'parent_id');
|
||||
}
|
||||
|
||||
public function parent()
|
||||
{
|
||||
return $this->hasOne(self::class,'id','parent_id');
|
||||
return $this->hasOne(self::class, 'id', 'parent_id');
|
||||
}
|
||||
|
||||
public function article()
|
||||
|
||||
@@ -40,6 +40,9 @@
|
||||
"classmap": [
|
||||
"database/seeds",
|
||||
"database/factories"
|
||||
],
|
||||
"files": [
|
||||
"app/Helpers/function.php"
|
||||
]
|
||||
},
|
||||
"autoload-dev": {
|
||||
|
||||
@@ -10,28 +10,30 @@
|
||||
*/
|
||||
|
||||
return [
|
||||
'hash_filename' => true,
|
||||
|
||||
// 存储引擎: config/filesystem.php 中 disks, public 或 qiniu
|
||||
'disk' => 'public',
|
||||
'route' => [
|
||||
'name' => '/ueditor/server',
|
||||
'disk' => 'public',
|
||||
'route' => [
|
||||
'name' => '/ueditor/server',
|
||||
'options' => [
|
||||
// middleware => 'auth',
|
||||
],
|
||||
],
|
||||
|
||||
// 上传 配置
|
||||
'upload' => [
|
||||
'upload' => [
|
||||
/* 前后端通信相关的配置,注释只允许使用多行方式 */
|
||||
/* 上传图片配置项 */
|
||||
'imageActionName' => 'upload-image', /* 执行上传图片的action名称 */
|
||||
'imageFieldName' => 'upfile', /* 提交的图片表单名称 */
|
||||
'imageMaxSize' => 2 * 1024 * 1024, /* 上传大小限制,单位B */
|
||||
'imageAllowFiles' => ['.png', '.jpg', '.jpeg', '.gif', '.bmp'], /* 上传图片格式显示 */
|
||||
'imageCompressEnable' => true, /* 是否压缩图片,默认是true */
|
||||
'imageCompressBorder' => 1600, /* 图片压缩最长边限制 */
|
||||
'imageInsertAlign' => 'none', /* 插入的图片浮动方式 */
|
||||
'imageUrlPrefix' => '', /* 图片访问路径前缀 */
|
||||
'imagePathFormat' => '/uploads/image/{yyyy}/{mm}/{dd}/', /* 上传保存路径,可以自定义保存路径和文件名格式 */
|
||||
'imageActionName' => 'upload-image', /* 执行上传图片的action名称 */
|
||||
'imageFieldName' => 'upfile', /* 提交的图片表单名称 */
|
||||
'imageMaxSize' => 2 * 1024 * 1024, /* 上传大小限制,单位B */
|
||||
'imageAllowFiles' => ['.png', '.jpg', '.jpeg', '.gif', '.bmp'], /* 上传图片格式显示 */
|
||||
'imageCompressEnable' => true, /* 是否压缩图片,默认是true */
|
||||
'imageCompressBorder' => 1600, /* 图片压缩最长边限制 */
|
||||
'imageInsertAlign' => 'none', /* 插入的图片浮动方式 */
|
||||
'imageUrlPrefix' => '', /* 图片访问路径前缀 */
|
||||
'imagePathFormat' => '/uploads/image/{yyyy}/{mm}/{dd}/', /* 上传保存路径,可以自定义保存路径和文件名格式 */
|
||||
/* {filename} 会替换成原文件名,配置这项需要注意中文乱码问题 */
|
||||
/* {rand:6} 会替换成随机数,后面的数字是随机数的位数 */
|
||||
/* {time} 会替换成时间戳 */
|
||||
@@ -46,45 +48,45 @@ return [
|
||||
/* 具请体看线上文档 => fex.baidu.com/assets/#use-format_upload_filename */
|
||||
|
||||
/* 涂鸦图片上传配置项 */
|
||||
'scrawlActionName' => 'upload-scrawl', /* 执行上传涂鸦的action名称 */
|
||||
'scrawlFieldName' => 'upfile', /* 提交的图片表单名称 */
|
||||
'scrawlPathFormat' => '/uploads/image/{yyyy}/{mm}/{dd}/', /* 上传保存路径,可以自定义保存路径和文件名格式 */
|
||||
'scrawlMaxSize' => 2048000, /* 上传大小限制,单位B */
|
||||
'scrawlUrlPrefix' => '', /* 图片访问路径前缀 */
|
||||
'scrawlInsertAlign' => 'none',
|
||||
'scrawlActionName' => 'upload-scrawl', /* 执行上传涂鸦的action名称 */
|
||||
'scrawlFieldName' => 'upfile', /* 提交的图片表单名称 */
|
||||
'scrawlPathFormat' => '/uploads/image/{yyyy}/{mm}/{dd}/', /* 上传保存路径,可以自定义保存路径和文件名格式 */
|
||||
'scrawlMaxSize' => 2048000, /* 上传大小限制,单位B */
|
||||
'scrawlUrlPrefix' => '', /* 图片访问路径前缀 */
|
||||
'scrawlInsertAlign' => 'none',
|
||||
|
||||
/* 截图工具上传 */
|
||||
'snapscreenActionName' => 'upload-image', /* 执行上传截图的action名称 */
|
||||
'snapscreenPathFormat' => '/uploads/image/{yyyy}/{mm}/{dd}/', /* 上传保存路径,可以自定义保存路径和文件名格式 */
|
||||
'snapscreenUrlPrefix' => '', /* 图片访问路径前缀 */
|
||||
'snapscreenInsertAlign' => 'none', /* 插入的图片浮动方式 */
|
||||
'snapscreenActionName' => 'upload-image', /* 执行上传截图的action名称 */
|
||||
'snapscreenPathFormat' => '/uploads/image/{yyyy}/{mm}/{dd}/', /* 上传保存路径,可以自定义保存路径和文件名格式 */
|
||||
'snapscreenUrlPrefix' => '', /* 图片访问路径前缀 */
|
||||
'snapscreenInsertAlign' => 'none', /* 插入的图片浮动方式 */
|
||||
|
||||
/* 抓取远程图片配置 */
|
||||
'catcherLocalDomain' => ['127.0.0.1', 'localhost', 'img.baidu.com'],
|
||||
'catcherActionName' => 'catch-image', /* 执行抓取远程图片的action名称 */
|
||||
'catcherFieldName' => 'source', /* 提交的图片列表表单名称 */
|
||||
'catcherPathFormat' => '/uploads/image/{yyyy}/{mm}/{dd}/', /* 上传保存路径,可以自定义保存路径和文件名格式 */
|
||||
'catcherUrlPrefix' => '', /* 图片访问路径前缀 */
|
||||
'catcherMaxSize' => 2048000, /* 上传大小限制,单位B */
|
||||
'catcherAllowFiles' => ['.png', '.jpg', '.jpeg', '.gif', '.bmp'], /* 抓取图片格式显示 */
|
||||
'catcherLocalDomain' => ['127.0.0.1', 'localhost', 'img.baidu.com'],
|
||||
'catcherActionName' => 'catch-image', /* 执行抓取远程图片的action名称 */
|
||||
'catcherFieldName' => 'source', /* 提交的图片列表表单名称 */
|
||||
'catcherPathFormat' => '/uploads/image/{yyyy}/{mm}/{dd}/', /* 上传保存路径,可以自定义保存路径和文件名格式 */
|
||||
'catcherUrlPrefix' => '', /* 图片访问路径前缀 */
|
||||
'catcherMaxSize' => 2048000, /* 上传大小限制,单位B */
|
||||
'catcherAllowFiles' => ['.png', '.jpg', '.jpeg', '.gif', '.bmp'], /* 抓取图片格式显示 */
|
||||
|
||||
/* 上传视频配置 */
|
||||
'videoActionName' => 'upload-video', /* 执行上传视频的action名称 */
|
||||
'videoFieldName' => 'upfile', /* 提交的视频表单名称 */
|
||||
'videoPathFormat' => '/uploads/video/{yyyy}/{mm}/{dd}/', /* 上传保存路径,可以自定义保存路径和文件名格式 */
|
||||
'videoUrlPrefix' => '', /* 视频访问路径前缀 */
|
||||
'videoMaxSize' => 102400000, /* 上传大小限制,单位B,默认100MB */
|
||||
'videoAllowFiles' => [
|
||||
'videoActionName' => 'upload-video', /* 执行上传视频的action名称 */
|
||||
'videoFieldName' => 'upfile', /* 提交的视频表单名称 */
|
||||
'videoPathFormat' => '/uploads/video/{yyyy}/{mm}/{dd}/', /* 上传保存路径,可以自定义保存路径和文件名格式 */
|
||||
'videoUrlPrefix' => '', /* 视频访问路径前缀 */
|
||||
'videoMaxSize' => 102400000, /* 上传大小限制,单位B,默认100MB */
|
||||
'videoAllowFiles' => [
|
||||
'.flv', '.swf', '.mkv', '.avi', '.rm', '.rmvb', '.mpeg', '.mpg',
|
||||
'.ogg', '.ogv', '.mov', '.wmv', '.mp4', '.webm', '.mp3', '.wav', '.mid', ], /* 上传视频格式显示 */
|
||||
'.ogg', '.ogv', '.mov', '.wmv', '.mp4', '.webm', '.mp3', '.wav', '.mid',], /* 上传视频格式显示 */
|
||||
|
||||
/* 上传文件配置 */
|
||||
'fileActionName' => 'upload-file', /* controller里,执行上传视频的action名称 */
|
||||
'fileFieldName' => 'upfile', /* 提交的文件表单名称 */
|
||||
'filePathFormat' => '/uploads/file/{yyyy}/{mm}/{dd}/', /* 上传保存路径,可以自定义保存路径和文件名格式 */
|
||||
'fileUrlPrefix' => '', /* 文件访问路径前缀 */
|
||||
'fileMaxSize' => 51200000, /* 上传大小限制,单位B,默认50MB */
|
||||
'fileAllowFiles' => [
|
||||
'fileActionName' => 'upload-file', /* controller里,执行上传视频的action名称 */
|
||||
'fileFieldName' => 'upfile', /* 提交的文件表单名称 */
|
||||
'filePathFormat' => '/uploads/file/{yyyy}/{mm}/{dd}/', /* 上传保存路径,可以自定义保存路径和文件名格式 */
|
||||
'fileUrlPrefix' => '', /* 文件访问路径前缀 */
|
||||
'fileMaxSize' => 51200000, /* 上传大小限制,单位B,默认50MB */
|
||||
'fileAllowFiles' => [
|
||||
'.png', '.jpg', '.jpeg', '.gif', '.bmp',
|
||||
'.flv', '.swf', '.mkv', '.avi', '.rm', '.rmvb', '.mpeg', '.mpg',
|
||||
'.ogg', '.ogv', '.mov', '.wmv', '.mp4', '.webm', '.mp3', '.wav', '.mid',
|
||||
@@ -93,19 +95,19 @@ return [
|
||||
], /* 上传文件格式显示 */
|
||||
|
||||
/* 列出指定目录下的图片 */
|
||||
'imageManagerActionName' => 'list-image', /* 执行图片管理的action名称 */
|
||||
'imageManagerListPath' => '/uploads/image/', /* 指定要列出图片的目录 */
|
||||
'imageManagerListSize' => 20, /* 每次列出文件数量 */
|
||||
'imageManagerUrlPrefix' => '', /* 图片访问路径前缀 */
|
||||
'imageManagerActionName' => 'list-image', /* 执行图片管理的action名称 */
|
||||
'imageManagerListPath' => '/uploads/image/', /* 指定要列出图片的目录 */
|
||||
'imageManagerListSize' => 20, /* 每次列出文件数量 */
|
||||
'imageManagerUrlPrefix' => '', /* 图片访问路径前缀 */
|
||||
'imageManagerInsertAlign' => 'none', /* 插入的图片浮动方式 */
|
||||
'imageManagerAllowFiles' => ['.png', '.jpg', '.jpeg', '.gif', '.bmp'], /* 列出的文件类型 */
|
||||
'imageManagerAllowFiles' => ['.png', '.jpg', '.jpeg', '.gif', '.bmp'], /* 列出的文件类型 */
|
||||
|
||||
/* 列出指定目录下的文件 */
|
||||
'fileManagerActionName' => 'list-file', /* 执行文件管理的action名称 */
|
||||
'fileManagerListPath' => '/uploads/file/', /* 指定要列出文件的目录 */
|
||||
'fileManagerUrlPrefix' => '', /* 文件访问路径前缀 */
|
||||
'fileManagerListSize' => 20, /* 每次列出文件数量 */
|
||||
'fileManagerAllowFiles' => [
|
||||
'fileManagerActionName' => 'list-file', /* 执行文件管理的action名称 */
|
||||
'fileManagerListPath' => '/uploads/file/', /* 指定要列出文件的目录 */
|
||||
'fileManagerUrlPrefix' => '', /* 文件访问路径前缀 */
|
||||
'fileManagerListSize' => 20, /* 每次列出文件数量 */
|
||||
'fileManagerAllowFiles' => [
|
||||
'.png', '.jpg', '.jpeg', '.gif', '.bmp',
|
||||
'.flv', '.swf', '.mkv', '.avi', '.rm', '.rmvb', '.mpeg', '.mpg',
|
||||
'.ogg', '.ogv', '.mov', '.wmv', '.mp4', '.webm', '.mp3', '.wav', '.mid',
|
||||
|
||||
4377
newine.sql
Normal file
4377
newine.sql
Normal file
File diff suppressed because one or more lines are too long
7
public/assets/index/js/cjango.js
Normal file
7
public/assets/index/js/cjango.js
Normal file
@@ -0,0 +1,7 @@
|
||||
$('[data-href]').on('click', function (event) {
|
||||
event.preventDefault();
|
||||
if ($(this).hasClass('ajax-get') || $(this).hasClass('ajax-post')) {
|
||||
return;
|
||||
}
|
||||
location.href = $(this).data('href');
|
||||
});
|
||||
@@ -2,9 +2,8 @@
|
||||
|
||||
/**
|
||||
* Laravel - A PHP Framework For Web Artisans
|
||||
*
|
||||
* @package Laravel
|
||||
* @author Taylor Otwell <taylor@laravel.com>
|
||||
* @package Laravel
|
||||
*/
|
||||
|
||||
define('LARAVEL_START', microtime(true));
|
||||
|
||||
@@ -3,61 +3,53 @@
|
||||
@section('title', '文章详情')
|
||||
|
||||
@section('content')
|
||||
@if ($advert)
|
||||
<div id="lyg_sub_banner"><img src="{{ $advert->cover_path }}"/></div>
|
||||
@endif
|
||||
|
||||
<div class="ly_page ly_min">
|
||||
<div class="ly_wrap">
|
||||
<div class="lyg_page_box">
|
||||
<div class="lyg_lpage">
|
||||
<div id="lyg_left_bar">
|
||||
<h2>{{ $parent->title }}</h2>
|
||||
<dl>
|
||||
@foreach ($parent->childrens as $children)
|
||||
<dt><a href="{{ route('category.show',$children) }}">{{ $children->title }}</a></dt>
|
||||
@endforeach
|
||||
</dl>
|
||||
</div>
|
||||
</div>
|
||||
<div class="lyg_rpage">
|
||||
<div class="lyg_rpage_bpx">
|
||||
<div class="lyg_page_title">
|
||||
<h2>{{ $category->title }}</h2>
|
||||
<div id="lyg_breadcrumb">
|
||||
<a class="ly_home" href="#">首页</a> <font>></font>
|
||||
@if ($parent->id==$category->id)
|
||||
{{ $category->title }}
|
||||
@else
|
||||
{{ $parent->title }}
|
||||
<font>></font>
|
||||
{{ $category->title }}
|
||||
<div class="container mg-t-b">
|
||||
<div class="page-left">
|
||||
<div class="pagelist">
|
||||
<h1>{{ $parent->title }}</h1>
|
||||
<ul class="listbox">
|
||||
@if ($parent->childrens->isNotEmpty())
|
||||
@foreach ($parent->childrens as $child)
|
||||
<li @if($category->id==$child->id) class="active" @endif>
|
||||
<a href="{{ $child->link }}">{{ $child->title }}</a>
|
||||
@if ($child->childrens->isNotEmpty())
|
||||
<ul class="dropdown">
|
||||
@foreach ($child->childrens as $childd)
|
||||
<li @if($category->id==$child->id) class="active" @endif>
|
||||
<a href="{{ $childd->link }}">{{ $childd->title }}</a>
|
||||
</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
@endif
|
||||
</div>
|
||||
<div class="lyg_clear"></div>
|
||||
</div>
|
||||
<div id="lyg_news_detail" class="lyg_container_content">
|
||||
<div id="lyg_news_detail_0">
|
||||
<h1>{{ $article->title }}</h1>
|
||||
<div class="lyg_para">
|
||||
<div class="lyg_date">{{ $article->created_at }}</div>
|
||||
<div class="lyg_clear"></div>
|
||||
</div>
|
||||
<div class="thumb">
|
||||
@if ($article->cover_path)
|
||||
<img src="{{ $article->cover_path }}" style="margin-bottom: 15px;" id="imgs"/>
|
||||
@endif
|
||||
</div>
|
||||
<div class="lyg_content">
|
||||
{!! $article->content !!}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="lyg_clear"></div>
|
||||
</li>
|
||||
@endforeach
|
||||
@endif
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="page-right">
|
||||
<div class="pagelujing">
|
||||
<div class="name">{{ $category->title }}</div>
|
||||
|
||||
<span>
|
||||
您当前所在位置:<a href="/">首页</a> >
|
||||
@if ($parent->id!=$category->id)
|
||||
<a href="{{ $parent->link }}">{{ $parent->title }}</a> >
|
||||
@endif
|
||||
<a href="{{ $category->link }}">{{ $category->title }}</a> >
|
||||
</span>
|
||||
</div>
|
||||
<div class="biaoti">{{ $article->title }}</div>
|
||||
<div class="sshuomign"><span>发布时间:{{ $article->created_at->format('Y-m-d') }}</span></div>
|
||||
<div class="article_txt">
|
||||
@if ($article->cover)
|
||||
<img src="{{ $article->cover_path }}">
|
||||
@endif
|
||||
{!! $article->content !!}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
@endsection
|
||||
|
||||
@@ -3,81 +3,63 @@
|
||||
@section('title', '首页')
|
||||
|
||||
@section('content')
|
||||
@if ($advert)
|
||||
<div id="lyg_sub_banner"><img src="{{ $advert->cover_path }}"/></div>
|
||||
@endif
|
||||
<div class="ly_page ly_min">
|
||||
<div class="ly_wrap">
|
||||
<div class="lyg_page_box">
|
||||
<div class="lyg_lpage">
|
||||
<div id="lyg_left_bar">
|
||||
<h2>{{ $parent->title }}</h2>
|
||||
<dl>
|
||||
@foreach ($parent->childrens as $children)
|
||||
<dt><a href="{{ route('category.show',$children) }}">{{ $children->title }}</a></dt>
|
||||
@endforeach
|
||||
</dl>
|
||||
</div>
|
||||
</div>
|
||||
<div class="lyg_rpage">
|
||||
<div class="lyg_rpage_box">
|
||||
<div class="lyg_page_title">
|
||||
<h2>{{ $parent->title }}</h2>
|
||||
<div id="lyg_breadcrumb">
|
||||
|
||||
<a class="ly_home" href="#">首页</a>
|
||||
<font>></font>
|
||||
@if ($parent->id==$category->id)
|
||||
{{ $category->title }}
|
||||
@else
|
||||
{{ $parent->title }}
|
||||
<font>></font>
|
||||
{{ $category->title }}
|
||||
<div class="container mg-t-b container_col">
|
||||
<div class="page-left">
|
||||
<div class="pagelist">
|
||||
<h1>{{ $parent->title }}</h1>
|
||||
<ul class="listbox">
|
||||
@if ($parent->childrens->isNotEmpty())
|
||||
@foreach ($parent->childrens as $child)
|
||||
<li @if($category->id==$child->id) class="active" @endif>
|
||||
<a href="{{ $child->link }}">{{ $child->title }}</a>
|
||||
@if ($child->childrens->isNotEmpty())
|
||||
<ul class="dropdown">
|
||||
@foreach ($child->childrens as $childd)
|
||||
<li @if($category->id==$child->id) class="active" @endif>
|
||||
<a href="{{ $childd->link }}">{{ $childd->title }}</a>
|
||||
</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
@endif
|
||||
</div>
|
||||
<div class="lyg_clear"></div>
|
||||
</div>
|
||||
<div id="lyg_news" class="lyg_container_content">
|
||||
<div id="lyg_news_0">
|
||||
@foreach ($articles as $article)
|
||||
<div class="lyg_item lyg_top">
|
||||
<div class="lyg_lbar">
|
||||
<a href="{{ route('article.show',$article) }}">
|
||||
<img src="{{ $article->cover_path }}" width="270" height="174"/>
|
||||
</a>
|
||||
</div>
|
||||
<div class="lyg_rbar">
|
||||
<h3><a href="{{ route('article.show',$article) }}">{{ $article->title }}</a></h3>
|
||||
<div class="lyg_intro">
|
||||
{{ $article->description }}
|
||||
</div>
|
||||
<div class="lyg_date">
|
||||
更新时间:{{ $article->created_at }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="lyg_clear"></div>
|
||||
</div>
|
||||
@endforeach
|
||||
<div class="lyg_blank25"></div>
|
||||
@if ($articles->isNotEmpty())
|
||||
{{ $articles->links('layouts.pagination') }}
|
||||
@endif
|
||||
{{-- <div class="Page clearfix">--}}
|
||||
{{-- <span>46 条记录 1/6 页</span>--}}
|
||||
{{-- <a href="">下一页</a>--}}
|
||||
{{-- <span class="current">1</span>--}}
|
||||
{{-- <a href=""> 2 </a>--}}
|
||||
{{-- <a href=""> 3 </a>--}}
|
||||
{{-- <a href=""> 4 </a>--}}
|
||||
{{-- <a href=""> 5 </a>--}}
|
||||
{{-- <a href="">下5页</a>--}}
|
||||
{{-- <a href="">末页</a>--}}
|
||||
{{-- </div>--}}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="lyg_clear"></div>
|
||||
</li>
|
||||
@endforeach
|
||||
@endif
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="page-right">
|
||||
<div class="pagelujing">
|
||||
<div class="name">{{ $category->title }}</div>
|
||||
<span>
|
||||
您当前所在位置:<a href="/">首页</a> >
|
||||
@if ($parent->id!=$category->id)
|
||||
<a href="{{ $parent->link }}">{{ $parent->title }}</a> >
|
||||
@endif
|
||||
<a href="{{ $category->link }}">{{ $category->title }}</a> >
|
||||
</span>
|
||||
</div>
|
||||
<div class="news-txt ny mg-t-b">
|
||||
<div class="news-con">
|
||||
<ul class="newslist ny">
|
||||
@if ($articles->isNotEmpty())
|
||||
@foreach ($articles as $article)
|
||||
<li>
|
||||
<a href="{{ $article->link }}">{{ $article->title }}</a><span>{{ $article->created_at->format('m-d') }}</span>
|
||||
</li>
|
||||
|
||||
@endforeach
|
||||
@endif
|
||||
</ul>
|
||||
|
||||
<div class="tcdPageCode">
|
||||
@if ($articles->isNotEmpty())
|
||||
{{ $articles->links('layouts.pagination') }}
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
@endsection
|
||||
|
||||
@@ -3,303 +3,334 @@
|
||||
@section('title', '首页')
|
||||
|
||||
@section('content')
|
||||
|
||||
<!--banner-->
|
||||
{{-- 顶部广告 --}}
|
||||
@if ($adverts->isNotEmpty())
|
||||
<div class="clear"></div>
|
||||
<div class="banner">
|
||||
<div class="b-img">
|
||||
@foreach ($adverts as $advert)
|
||||
<img src="{{ $advert->cover_path }}" width="100%"/>
|
||||
@endforeach
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
<div class="b-list"></div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
<!-- 新闻 -->
|
||||
<div class="news-2">
|
||||
<div class="l">
|
||||
<div id="lib_Tab1">
|
||||
<div class="lib_Menubox lib_tabborder">
|
||||
<ul>
|
||||
<li id="one1" onMouseOver="setTab('one',1,4)" class="hover"><a href="{{ route('category.show',53) }}">新闻动态</a></li>
|
||||
<li id="one2" onMouseOver="setTab('one',2,4)" class=""><a href="{{ route('category.show',20) }}">科技平台</a></li>
|
||||
<li id="one3" onMouseOver="setTab('one',3,4)" class=""><a href="{{ route('category.show',8) }}">政府决策服务</a></li>
|
||||
<li id="one4" onMouseOver="setTab('one',4,4)" class=""><a href="{{ route('category.show',74) }}">知名专家</a></li>
|
||||
</ul>
|
||||
<div class="container container_col">
|
||||
<!--轮播图 新闻动态 -->
|
||||
<div class="news-notice">
|
||||
<div class="indnews">
|
||||
<div class="news-pic">
|
||||
<div id="newspic" class="slideBox">
|
||||
<ul class="items">
|
||||
@if ($adverts->isNotEmpty())
|
||||
@foreach ($adverts as $advert)
|
||||
<li>
|
||||
<a href="{{ $advert->url }}" title="{{ $advert->title }}"><img src="{{ $advert->cover_path }}"></a>
|
||||
</li>
|
||||
@endforeach
|
||||
@endif
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="lib_Contentbox lib_tabborder">
|
||||
<div id="con_one_1" style="display: block;">
|
||||
<div class="con_l">
|
||||
<a href="{{ route('article.show',$xwdt->first()) }}"><img src="{{ $xwdt->first()->get_one_cover() }}" width="320" height="230"></a>
|
||||
</div>
|
||||
<div class="news-txt" id="news">
|
||||
<div class="news-title">
|
||||
<div class="news-name tab-nav j-tab-nav">
|
||||
<a href="javascript:void(0);" class="current">{{ getOneCategory(53,'title') }}<i></i></a>
|
||||
<a href="javascript:void(0);" class="">{{ getOneCategory(54,'title') }}<i></i></a>
|
||||
</div>
|
||||
{{-- <a href="#" class="more">更多 >></a>--}}
|
||||
</div>
|
||||
<div class="tab-con">
|
||||
<div class="j-tab-con">
|
||||
<div class="tab-con-item news-con" style="display: block;">
|
||||
@if (getArticlesBYCate(53,6)->isNotEmpty())
|
||||
<div class="hotnews">
|
||||
<h1>{{ getArticlesBYCate(53,6)->first()->title}}</h1>
|
||||
<div class="hotcon">
|
||||
<a href="getArticlesBYCate(53,6)->first()->link">{{ getArticlesBYCate(53,6)->first()->description }} </a>
|
||||
</div>
|
||||
</div>
|
||||
<ul class="newslist">
|
||||
@foreach (getArticlesBYCate(53,6) as $info)
|
||||
@if ($loop->iteration>1)
|
||||
<li>
|
||||
<a href="{{ $info->link }}">{{ $info->title }}</a><span>{{ $info->created_at->format('Y-m-d') }}</span>
|
||||
</li>
|
||||
@endif
|
||||
@endforeach
|
||||
</ul>
|
||||
@endif
|
||||
|
||||
</div>
|
||||
<div class="con_r">
|
||||
<ul>
|
||||
@foreach ($xwdt as $new)
|
||||
<div class="tab-con-item news-con" style="display: none;">
|
||||
@if (getArticlesBYCate(54,6)->isNotEmpty())
|
||||
<div class="hotnews">
|
||||
<h1>{{ getArticlesBYCate(54,6)->first()->title}}</h1>
|
||||
<div class="hotcon">
|
||||
<a href="getArticlesBYCate(54,6)->first()->link">{{ getArticlesBYCate(54,6)->first()->description }} </a>
|
||||
</div>
|
||||
</div>
|
||||
<ul class="newslist">
|
||||
@foreach (getArticlesBYCate(54,6) as $info)
|
||||
@if ($loop->iteration>1)
|
||||
<li>
|
||||
<a href="{{ $info->link }}">{{ $info->title }}</a><span>{{ $info->created_at->format('Y-m-d') }}</span>
|
||||
</li>
|
||||
@endif
|
||||
@endforeach
|
||||
</ul>
|
||||
@endif
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
|
||||
<!-- 科学研究与特色品牌建设 开始 -->
|
||||
<div class="" style="width: 100%;">
|
||||
<div class="words11_zzgz_xfgz_title">
|
||||
<font style="border-bottom: 2px solid #4c951c;">{{ getOneCategory(17,'title') }}</font>
|
||||
<span><a href="{{ getOneCategory(17,'link') }}">更多 >></a></span>
|
||||
</div>
|
||||
<div class="news_list_content flexrow jc_start">
|
||||
@if (getArticlesBYCate(17,8,'all')->isNotEmpty())
|
||||
@foreach (getArticlesBYCate(17,8,'all') as $info)
|
||||
@if ($loop->odd)
|
||||
<div class="news_list_item ">
|
||||
<div class="img" style="background-image:url({{ $info->cover_path }})">
|
||||
<div class="sanjiao pos_abs"></div>
|
||||
</div>
|
||||
<div class="txt flexcolumn jc_sb" data-href="{{ $info->link }}">
|
||||
<div>
|
||||
<div class="title overflow1">{{ $info->title }}</div>
|
||||
<div class="overflow4 "> {{ $info->descrition }}</div>
|
||||
</div>
|
||||
<div class="flexrow getMore">查看更多 <img src="/assets/index/images/right.png"></div>
|
||||
</div>
|
||||
</div>
|
||||
@else
|
||||
<div class="news_list_item ">
|
||||
<div class="txt flexcolumn jc_sb" data-href="{{ $info->link }}">
|
||||
<div>
|
||||
<div class="title overflow1">{{ $info->title }}</div>
|
||||
<div class="overflow4 "> {{ $info->descrition }}</div>
|
||||
</div>
|
||||
<div class="flexrow getMore">查看更多 <img src="/assets/index/images/right.png"></div>
|
||||
</div>
|
||||
<div class="img" style="background-image:url({{ $info->cover_path }})">
|
||||
<div class="sanjiao2 pos_abs"></div>
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
@endforeach
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 创新团队 开始 -->
|
||||
<div class="words11">
|
||||
<div class="words11_zzgz_xfgz" style="width: 580px">
|
||||
<div class="words11_zzgz_xfgz_title">
|
||||
<font style="border-bottom: 2px solid #4c951c;">{{ getOneCategory(43,'title') }}</font>
|
||||
<span><a href="{{ getOneCategory(43,'link') }}">更多 >></a></span>
|
||||
</div>
|
||||
<div class="words11_zzgz_xfgz_content">
|
||||
@if (getArticlesBYCate(43,10,'all')->isNotEmpty())
|
||||
|
||||
<div class="box">
|
||||
<div class="focus" style="width: 100%; height: 160px; margin: 0 0 10px">
|
||||
@foreach (getArticlesBYCate(43,8,'all') as $article)
|
||||
@if ($loop->iteration<=2)
|
||||
<img src="{{ $article->cover_path }}" style="width: calc(50% - 5px); height: 100%; margin-right: 5px">
|
||||
@endif
|
||||
@endforeach
|
||||
</div>
|
||||
<div class="tem">
|
||||
<ul>
|
||||
@foreach (getArticlesBYCate(43,8,'all') as $article)
|
||||
@if ($loop->iteration>2&&$loop->iteration<6)
|
||||
<li>
|
||||
<a href=""><img src="{{ $article->cover_path }}">{{ $article->title }}
|
||||
</a>
|
||||
</li>
|
||||
@endif
|
||||
@endforeach
|
||||
</ul>
|
||||
<ul>
|
||||
@foreach (getArticlesBYCate(43,8,'all') as $article)
|
||||
@if ($loop->iteration >5)
|
||||
<li>
|
||||
<a href=""><img src="{{ $article->cover_path }}">{{ $article->title }}
|
||||
</a>
|
||||
</li>
|
||||
@endif
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="words11_zzgz_xfgz" style="margin-left: 15px;">
|
||||
<div class="words11_zzgz_xfgz_title">
|
||||
<font style="border-bottom: 2px solid #4c951c;">{{ getOneCategory(74,'title') }}</font><span><a href="{{ getOneCategory(74,'link') }}">更多 >></a></span>
|
||||
</div>
|
||||
<div class="words11_jcfc_content">
|
||||
<div class="box">
|
||||
<div class="focus"><img src="/assets/index/images/name_04.jpg"></div>
|
||||
<div class="left" onclick="lb_jcfc('-')"></div>
|
||||
<div class="midd">
|
||||
@if (getArticlesBYCate(74,5)->isNotEmpty())
|
||||
<ul>
|
||||
@foreach (getArticlesBYCate(74,5) as $article)
|
||||
<li>
|
||||
<strong>
|
||||
<a href="{{ route('article.show',$new) }}">{{ $new->title }}</a>
|
||||
</strong>
|
||||
<span>
|
||||
<a href="{{ route('article.show',$new) }}">{{ $new->description }}</a>
|
||||
</span>
|
||||
<a href="javascript:void(0);"><img style="border: 2px solid #4c951c;" src="{{ $article->cover_path }}"></a>
|
||||
</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div id="con_one_2" style="display: none;">
|
||||
@endforeach
|
||||
</ul>
|
||||
@endif
|
||||
|
||||
<a href="{{ route('article.show',$kjpt->first()->id) }}"><img src="{{ $kjpt->first()->get_one_cover() }}" width="320" height="230"></a>
|
||||
<div class="con_r">
|
||||
<ul>
|
||||
@foreach ($kjpt as $new)
|
||||
<li>
|
||||
<strong>
|
||||
<a href="{{ route('article.show',$new) }}">{{ $new->title }}</a>
|
||||
</strong>
|
||||
<span>
|
||||
<a href="{{ route('article.show',$new) }}">{{ $new->description }}</a>
|
||||
</span>
|
||||
</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
<div class="right" onclick="lb_jcfc('+')"></div>
|
||||
</div>
|
||||
<div id="con_one_3" style="display: none;">
|
||||
<a href="{{ route('article.show',$zcjc->first()->id) }}"><img src="{{ $zcjc->first()->get_one_cover() }}" width="320" height="230"></a>
|
||||
<div class="con_r">
|
||||
</div>
|
||||
</div>
|
||||
<div class="words11_zzgz_xfgz" style="margin-left: 15px;width: 200px">
|
||||
<div class="words11_zzgz_xfgz_title">
|
||||
<font style="border-bottom: 2px solid #4c951c;">论坛</font>
|
||||
</div>
|
||||
<div class="poster">
|
||||
<div class="box">
|
||||
@if ($lt_adverts->isNotEmpty())
|
||||
<ul>
|
||||
@foreach ($zcjc as $new)
|
||||
<li>
|
||||
<strong>
|
||||
<a href="{{ route('article.show',$new) }}">{{ $new->title }}</a>
|
||||
</strong>
|
||||
<span>
|
||||
<a href="{{ route('article.show',$new) }}">{{ $new->description }}</a>
|
||||
</span>
|
||||
@foreach ($lt_adverts as $advert)
|
||||
<li data-herf="{{ $advert->url }}">
|
||||
<img src="{{ $advert->cover_path }}">
|
||||
</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div id="con_one_4" style="display: none;">
|
||||
<a href="{{ route('article.show',$zmzj->first()->id) }}"><img src="{{ $zmzj->first()->get_one_cover() }}" width="320" height="230"></a>
|
||||
<div class="con_r">
|
||||
<ul>
|
||||
@foreach ($zmzj as $new)
|
||||
<li>
|
||||
<strong>
|
||||
<a href="{{ route('article.show',$new) }}">{{ $new->title }}</a>
|
||||
</strong>
|
||||
<span>
|
||||
<a href="{{ route('article.show',$new) }}">{{ $new->description }}</a>
|
||||
</span>
|
||||
</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="r">
|
||||
<div id="lib_Tab1">
|
||||
<div class="lib_Menubox lib_tabborder">
|
||||
<ul>
|
||||
<li id="two1" onMouseOver="setTab('two',1,4)" class="hover"><a href="{{ route('category.show',54) }}">通知公告</a></li>
|
||||
<li id="two2" onMouseOver="setTab('two',2,4)" class=""><a href="{{ route('category.show',58) }}">科技发展论坛</a></li>
|
||||
</ul>
|
||||
<!-- 领军人才-->
|
||||
<div class="col-box">
|
||||
<div class="news-txt col-3">
|
||||
<div class="news-title">
|
||||
<div class="name">{{ getOneCategory(127,'title') }}<i></i></div>
|
||||
<a href="{{ getOneCategory(127,'link') }}" class="more">更多 >></a>
|
||||
</div>
|
||||
<div class="lib_Contentbox lib_tabborder">
|
||||
<div id="con_two_1" style="display: block;">
|
||||
<ul>
|
||||
@foreach ($tjgg as $new)
|
||||
<li>
|
||||
<strong>
|
||||
<a href="{{ route('article.show',$new) }}">{{ $new->title }}</a>
|
||||
</strong>
|
||||
<span>
|
||||
<a href="{{ route('article.show',$new) }}">{{ $new->description }}</a>
|
||||
</span>
|
||||
</li>
|
||||
<div class="news-con">
|
||||
@if (getArticlesBYCate(127,4)->isNotEmpty())
|
||||
<div class="focus" data-herf="{{ getArticlesBYCate(127,4)->first()->link }}">
|
||||
<img src="{{ getArticlesBYCate(127,4)->first()->cover_path}}">
|
||||
<p>{{ getArticlesBYCate(127,4)->first()->title}}</p>
|
||||
</div>
|
||||
<ul class="newslist">
|
||||
@foreach (getArticlesBYCate(127,4) as $info)
|
||||
@if ($loop->iteration>1)
|
||||
<li>
|
||||
<a href="{{ $info->link }}">{{ $info->title }}</a>
|
||||
</li>
|
||||
@endif
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
<div id="con_two_2" style="display: none;">
|
||||
<ul>
|
||||
@foreach ($kjlt as $new)
|
||||
<li>
|
||||
<strong>
|
||||
<a href="{{ route('article.show',$new) }}">{{ $new->title }}</a>
|
||||
</strong>
|
||||
<span>
|
||||
<a href="{{ route('article.show',$new) }}">{{ $new->description }}</a>
|
||||
</span>
|
||||
</li>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
<div class="news-txt col-3">
|
||||
<div class="news-title">
|
||||
<div class="name">{{ getOneCategory(8,'title') }}<i></i></div>
|
||||
<a href="{{ getOneCategory(8,'link') }}" class="more">更多 >></a>
|
||||
</div>
|
||||
<div class="news-con">
|
||||
|
||||
@if (getArticlesBYCate(8,4)->isNotEmpty())
|
||||
<div class="focus" data-herf="{{ getArticlesBYCate(8,4)->first()->link }}">
|
||||
<img src="{{ getArticlesBYCate(8,4)->first()->cover_path}}">
|
||||
<p>{{ getArticlesBYCate(8,4)->first()->title}}</p>
|
||||
</div>
|
||||
<ul class="newslist">
|
||||
@foreach (getArticlesBYCate(8,4) as $info)
|
||||
@if ($loop->iteration>1)
|
||||
<li>
|
||||
<a href="{{ $info->link }}">{{ $info->title }}</a>
|
||||
</li>
|
||||
@endif
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div id="ly_main" class="ly_min">
|
||||
<div class="ly_wrap">
|
||||
<div class="lyg_blank25"></div>
|
||||
<div class="lyg_blank25"></div>
|
||||
<!--关于我们-->
|
||||
<div class="ly_main_t">
|
||||
<div class="ly_lbar ly_fl">
|
||||
<div class="ly_article_bar">
|
||||
<h2><a class="ly_more" href="{{ route('category.show',1) }}">查看更多</a><span>院所介绍</span> <em>ABOUT US</em></h2>
|
||||
<div class="lyg_blank20"></div>
|
||||
<div class="ly_content">
|
||||
<div class="ly_a_lbar ly_fl">
|
||||
<div class="ly_pic"><img src="{{ $info->get_one_cover() }}" width="248" height="216"/></div>
|
||||
</div>
|
||||
<div class="ly_a_rbar ly_fr">
|
||||
<div class="ly_title">{{ $info->title??'' }}</div>
|
||||
<div class="ly_intro">
|
||||
{{ $info->description}}
|
||||
</div>
|
||||
</div>
|
||||
<div class="lyg_clear"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="news-txt col-3 last">
|
||||
<div class="news-title">
|
||||
<div class="name">{{ getOneCategory(18,'title') }}<i></i></div>
|
||||
<a href="#" class="more">更多 >></a>
|
||||
</div>
|
||||
<!--客户见证-->
|
||||
<div class="ly_rbar ly_fr">
|
||||
<div class="ly_news_bar">
|
||||
<h2><a class="ly_more" href="{{ route('category.show',61) }}">查看更多</a><span>研究中心</span> </h2>
|
||||
<div class="lyg_blank15"></div>
|
||||
<div class="ly_content">
|
||||
@foreach ($yjzx as $new)
|
||||
@if ($loop->iteration>1)
|
||||
<div class="ly_line"></div>
|
||||
@endif
|
||||
<div class="ly_item">
|
||||
<div class="ly_n_lbar ly_fl">
|
||||
<div class="ly_pic"><a href="{{ route('article.show',$new) }}"> <img src="{{ $info->get_one_cover() }}" width="145" height="103"/></a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ly_n_rbar ly_fr">
|
||||
<h3><a href="#">{{ $new->title }}</a></h3>
|
||||
<div class="ly_date">{{ $new->created_at }}</div>
|
||||
<div class="ly_intro">
|
||||
{{ $new->description }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="lyg_clear"></div>
|
||||
</div>
|
||||
<div class="news-con">
|
||||
@if (getArticlesBYCate(18,4)->isNotEmpty())
|
||||
<div class="focus" data-herf="{{ getArticlesBYCate(18,4)->first()->link }}">
|
||||
<img src="{{ getArticlesBYCate(18,4)->first()->cover_path}}">
|
||||
<p>{{ getArticlesBYCate(18,4)->first()->title}}</p>
|
||||
</div>
|
||||
<ul class="newslist">
|
||||
@foreach (getArticlesBYCate(18,4) as $info)
|
||||
@if ($loop->iteration>1)
|
||||
<li>
|
||||
<a href="{{ $info->link }}">{{ $info->title }}</a>
|
||||
</li>
|
||||
@endif
|
||||
@endforeach
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="lyg_clear"></div>
|
||||
</div>
|
||||
<div class="lyg_blank25"></div>
|
||||
<div class="lyg_blank25"></div>
|
||||
<!-- 产品展示 -->
|
||||
<div class="ly_main_b">
|
||||
<div class="lyg_blank25"></div>
|
||||
<div class="lyg_blank15"></div>
|
||||
<div class="ly_product_bar">
|
||||
<h2><a class="ly_more" href="{{ route('category.show',17) }}">查看更多</a><span>科学研究与特色品牌建设</span> </h2>
|
||||
<div class="lyg_blank25"></div>
|
||||
<div class="ly_content">
|
||||
<div class="ly_relative">
|
||||
<div class="product_list">
|
||||
|
||||
@foreach ($kxyts as $new)
|
||||
<div class="ly_items">
|
||||
<div class="ly_pic">
|
||||
<a href="{{ route('article.show',$new) }}">
|
||||
<img src="{{ $new->get_one_cover() }}" width="218" height="218"/>
|
||||
</a>
|
||||
</div>
|
||||
<div class="ly_pro_box">
|
||||
<h3><a href="{{ route('article.show',$new) }}">{{ $new->title }}</a></h3>
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
</div>
|
||||
</div>
|
||||
<div class="lyg_clear"></div>
|
||||
</div>
|
||||
</ul>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
<div class="lyg_blank25"></div>
|
||||
<div class="lyg_blank15"></div>
|
||||
<!--案例展示-->
|
||||
<div class="ly_main_b">
|
||||
<div class="ly_product_bar gundong_">
|
||||
<h2><a class="ly_more" href="{{ route('category.show',43) }}">查看更多</a><span>创新团队</span></h2>
|
||||
<div class="lyg_blank25"></div>
|
||||
<div class="ly_content">
|
||||
<a class="ly_left_btn" href="javascript:;"></a><a class="ly_right_btn" href="javascript:;"></a>
|
||||
<div class="ly_relative">
|
||||
<div class="ly_absolute">
|
||||
@foreach ($kxyts as $new)
|
||||
<div class="ly_item">
|
||||
<div class="ly_pic"><a href="{{ route('article.show',$new) }}"> <img src="{{ $new->get_one_cover() }}" width="196" height="196"/></a>
|
||||
</div>
|
||||
<div class="ly_pro_box">
|
||||
<h3><a href="{{ route('article.show',$new) }}">{{ $new->title }}</a></h3>
|
||||
<div class="ly_intro">
|
||||
{{ $new->description }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
</div>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
<!-- 友情链接 -->
|
||||
<div class="col-2-r">
|
||||
<div class="linksbox" id="link">
|
||||
<div class="txtlisttit linktit"><span>友情链接</span>
|
||||
</div>
|
||||
<div class="listcon tab-con">
|
||||
<div class="j-tab-con">
|
||||
<div class="tab-con-item linkcon" style="display: block;">
|
||||
<ul class="linkslist">
|
||||
@if ($links->isNotEmpty())
|
||||
@foreach ($links as $link)
|
||||
<li><a href="{{ $link->url }}" target="_blank">{{ $link->title }}</a></li>
|
||||
@endforeach
|
||||
@endif
|
||||
</ul>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
<div class="lyg_clear"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="linkbox">
|
||||
<div class="linkL">
|
||||
<p class="p1">友情链接</p>
|
||||
<p class="p2">Links</p>
|
||||
</div>
|
||||
<div class="linkR">
|
||||
@foreach ($links as $element)
|
||||
<a href="{{ $element->url }}"> {{ $element->title }}</a>
|
||||
@endforeach
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
@endsection
|
||||
|
||||
@section('script')
|
||||
<script src="{{ asset('assets/index/js/jquery.flexslider-min.js') }}"></script>
|
||||
<script>
|
||||
$(function () {
|
||||
web_obj.slide('.gundong_', {
|
||||
items: '.ly_item',
|
||||
seenum: 5,
|
||||
slidenum: 5,
|
||||
leftbtn: '.ly_left_btn',
|
||||
rightbtn: '.ly_right_btn'
|
||||
});
|
||||
@push('script')
|
||||
<script type="text/javascript" src="{{ asset('assets/index/js/lb_jcfc.js') }}"></script>
|
||||
|
||||
$('.banner').flexslider({
|
||||
directionNav: true,
|
||||
pauseOnAction: false
|
||||
<script>
|
||||
jQuery(function ($) {
|
||||
$('#newspic').slideBox({
|
||||
duration: 0.3,//滚动持续时间,单位:秒
|
||||
easing: 'linear',//swing,linear//滚动特效
|
||||
delay: 5,//滚动延迟时间,单位:秒
|
||||
hideClickBar: false,//不自动隐藏点选按键
|
||||
clickBarRadius: 10
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function () {
|
||||
$("#link").rTabs({
|
||||
bind: 'hover',
|
||||
animation: 'fadein',
|
||||
auto: false
|
||||
});
|
||||
$("#news").rTabs({
|
||||
bind: 'hover',
|
||||
animation: 'fadein',
|
||||
auto: false
|
||||
});
|
||||
})
|
||||
</script>
|
||||
@endsection
|
||||
@endpush
|
||||
|
||||
@@ -1,75 +1,28 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
|
||||
<title>{{ config('app.name', '') }} </title>
|
||||
<link rel="stylesheet" href="{{ asset('assets/index/css/style.css') }}?{{ time() }}" type="text/css"/>
|
||||
<!--[if IE 6]>
|
||||
<script type='text/javascript' src='js/dd_belatedpng.js'></script>
|
||||
<![endif]-->
|
||||
|
||||
<title>{{ config('app.name', '') }}</title>
|
||||
<link href="{{ asset('assets/index/css/base.css') }}?{{ time() }}" rel="stylesheet" type="text/css"/>
|
||||
<link href="{{ asset('assets/index/css/main.css') }}?{{ time() }}" rel="stylesheet" type="text/css"/>
|
||||
<link href="{{ asset('assets/index/css/jquery.slideBox.css') }}" rel="stylesheet" type="text/css"/>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="ly_header" class="ly_min">
|
||||
<div class="ly_wrap">
|
||||
<div class="ly_lbar ly_fl">
|
||||
<div id="ly_logo"><a href="/"> <img src="/assets/index/images/logo.jpg"/> <span></span> </a></div>
|
||||
</div>
|
||||
<div class="ly_rbar ly_fr">
|
||||
<div class="ly_tel">
|
||||
<div class="ly_name">电话热线</div>
|
||||
<div class="ly_value">{{ config('mobile') }}</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ly_cbar ly_fr">
|
||||
</div>
|
||||
<div class="lyg_clear"></div>
|
||||
</div>
|
||||
</div>
|
||||
<!--导航-->
|
||||
|
||||
<div id="ly_menu">
|
||||
<div class="ly_wrap">
|
||||
<div class="lyg_fir "><a href="/">网站首页</a></div>
|
||||
|
||||
@foreach ($all_categorys as $cate)
|
||||
<div class="lyg_fir @if (isset($category) && $cate->id==$category->id) lyg_current @endif">
|
||||
<a href="{{ route('category.show',$cate) }}">{{ $cate->title }}</a>
|
||||
</div>
|
||||
@endforeach
|
||||
<div class="lyg_clear"></div>
|
||||
</div>
|
||||
</div>
|
||||
@include('layouts.header')
|
||||
|
||||
@section('content')
|
||||
|
||||
@show
|
||||
|
||||
<div class="lyg_blank25"></div>
|
||||
<div class="lyg_blank25"></div>
|
||||
@include('layouts.footer')
|
||||
|
||||
{{-- 底部 --}}
|
||||
<div id="ly_footer" class="ly_min">
|
||||
<div class="ly_wrap">
|
||||
<div class="ly_lbar ly_fl">
|
||||
<div class="ly_logo">
|
||||
<img src="/assets/index/images/f_logo.png"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ly_cbar ly_fl">
|
||||
<div class="ly_copyright">
|
||||
地址:{{ config('address')}} 邮件:{{ config('email')}} <br>
|
||||
电话:{{ config('mobile')}} 传真:{{ config('mobile')}} 邮编:{{ config('postcode')}}<br>
|
||||
{{ config('name')}} 版权所有 (C)2010 All Right Reserved 黑ICP备10000021号
|
||||
</div>
|
||||
<div class="lyg_support"></div>
|
||||
</div>
|
||||
<div class="lyg_clear"></div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript" src="{{ asset('assets/index/js/jquery-1.8.2.min.js') }}"/></script>
|
||||
<script type="text/javascript" src="{{ asset('assets/index/js/web.js') }}"/></script>
|
||||
<script type="text/javascript" src="{{ asset('assets/index/js/gundong.js') }}"/></script>
|
||||
@yield('script')
|
||||
<script type="text/javascript" src="{{ asset('assets/index/js/jquery-1.8.3.min.js') }}"></script>
|
||||
<script type="text/javascript" src="{{ asset('assets/index/js/jquery.slideBox.min.js') }}"></script>
|
||||
<script type="text/javascript" src="{{ asset('assets/index/js/nav.js') }}"></script>
|
||||
<script type="text/javascript" src="{{ asset('assets/index/js/Tabs.js') }}"></script>
|
||||
<script type="text/javascript" src="{{ asset('assets/index/js/cjango.js') }}"></script>
|
||||
|
||||
@stack('script')
|
||||
</body>
|
||||
</html>
|
||||
|
||||
33
resources/views/layouts/footer.blade.php
Normal file
33
resources/views/layouts/footer.blade.php
Normal file
@@ -0,0 +1,33 @@
|
||||
<!-- 底部 -->
|
||||
<div class="foot">
|
||||
<div class="ft-menu">
|
||||
<div class="container">
|
||||
<div class="menu">
|
||||
@foreach ($all_categorys as $cate)
|
||||
<dl>
|
||||
<dt>{{ $cate->title }}</dt>
|
||||
</dl>
|
||||
@endforeach
|
||||
|
||||
<dl>
|
||||
<dd class="last" style="margin-top: 20px">
|
||||
<p>地址:黑龙江省哈尔滨市香坊区哈平路103号</p>
|
||||
<p>邮件:kxyzys@126.com</p>
|
||||
<p>电话:086-451-86664613</p>
|
||||
<p>传真:086-451-86664613</p>
|
||||
<p>邮编:150040</p>
|
||||
</dd>
|
||||
</dl>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
<div class="ewm">
|
||||
<img src="/assets/index/images/blue.png"/>
|
||||
</div>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="cop">
|
||||
<div class="container">黑龙江省科学院自然与生态研究所 版权所有 (C)2010 All Right Reserved 黑ICP备10000021号</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 底部 end -->
|
||||
27
resources/views/layouts/header.blade.php
Normal file
27
resources/views/layouts/header.blade.php
Normal file
@@ -0,0 +1,27 @@
|
||||
<div class="header">
|
||||
{{-- <div class="container">--}}
|
||||
{{-- <div id="weather"></div>--}}
|
||||
{{-- <div class="toptxt"><a href="#">加入收藏</a><a href="#">设为首页</a></div>--}}
|
||||
{{-- <div class="logo"><a href="#"><img src="images/logo.png"/></a></div>--}}
|
||||
{{-- <div class="search">--}}
|
||||
{{-- <input type="text" class="ipt-sea" placeholder="请输入搜索关键词"/>--}}
|
||||
{{-- <a href="javascript:;">搜索</a></div>--}}
|
||||
{{-- </div>--}}
|
||||
</div>
|
||||
<div class="nav">
|
||||
<ul class="" id="navul">
|
||||
<li @if (!isset($parent)) class="active" @endif><a href="/">首页</a></li>
|
||||
@foreach ($all_categorys as $cate)
|
||||
<li @if (isset($parent) && $cate->id==$parent->id) class="active" @endif>
|
||||
<a href="{{ $cate->link }}">{{ $cate->title }}</a>
|
||||
@if ($cate->childrens->isNotEmpty())
|
||||
<ul>
|
||||
@foreach ($cate->childrens as $children)
|
||||
<li><a href="{{ $children->link }}">{{ $children->title }}</a></li>
|
||||
@endforeach
|
||||
</ul>
|
||||
@endif
|
||||
</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
@@ -1,31 +1,28 @@
|
||||
@if ($paginator->hasPages())
|
||||
<form action="{{ url()->current() }}" method="get" accept-charset="utf-8">
|
||||
<div class="Page clearfix">
|
||||
<div class="tcdPageCode">
|
||||
{{-- Previous Page Link --}}
|
||||
@if ($paginator->onFirstPage())
|
||||
<li class="page-item disabled" aria-disabled="true" aria-label="@lang('pagination.previous')">
|
||||
<span class="page-link" aria-hidden="true">上一页</span>
|
||||
</li>
|
||||
<span class="disabled">上一页</span>
|
||||
@else
|
||||
<li class="page-item">
|
||||
<a class="page-link" href="{{ $paginator->previousPageUrl() }}" rel="prev" aria-label="@lang('pagination.previous')">上一页</a>
|
||||
</li>
|
||||
<a href="{{ $paginator->previousPageUrl() }}" class="prevPage">上一页</a>
|
||||
@endif
|
||||
|
||||
{{-- Pagination Elements --}}
|
||||
@foreach ($elements as $element)
|
||||
{{-- "Three Dots" Separator --}}
|
||||
@if (is_string($element))
|
||||
<li class="page-item disabled" aria-disabled="true"><span class="page-link">{{ $element }}</span></li>
|
||||
<li class="page-item disabled" aria-disabled="true"><span class="page-link">{{ $element }}</span>
|
||||
</li>
|
||||
@endif
|
||||
|
||||
{{-- Array Of Links --}}
|
||||
@if (is_array($element))
|
||||
@foreach ($element as $page => $url)
|
||||
@if ($page == $paginator->currentPage())
|
||||
<li class="page-item active" aria-current="page"><span class="page-link">{{ $page }}</span></li>
|
||||
<span class="current">{{ $page }}</span>
|
||||
@else
|
||||
<li class="page-item"><a class="page-link" href="{{ $url }}">{{ $page }}</a></li>
|
||||
<a href="{{ $url }}" class="tcdNumber">{{ $page }}</a>
|
||||
@endif
|
||||
@endforeach
|
||||
@endif
|
||||
@@ -33,17 +30,13 @@
|
||||
|
||||
{{-- Next Page Link --}}
|
||||
@if ($paginator->hasMorePages())
|
||||
<li class="page-item">
|
||||
<a class="page-link" href="{{ $paginator->nextPageUrl() }}" rel="next" aria-label="@lang('pagination.next')">下一页</a>
|
||||
</li>
|
||||
<a href="{{ $paginator->nextPageUrl() }}" class="nextPage">下一页</a>
|
||||
@else
|
||||
<li class="page-item disabled" aria-disabled="true" aria-label="@lang('pagination.next')">
|
||||
<span class="page-link" aria-hidden="true">下一页</span>
|
||||
</li>
|
||||
<span class="disabled">下一页</span>
|
||||
@endif
|
||||
<li class="page-item disabled" aria-disabled="true">
|
||||
<span class="page-link" aria-hidden="true">共{{ $paginator->total() }}条</span>
|
||||
</li>
|
||||
{{-- <li class="page-item disabled" aria-disabled="true">--}}
|
||||
{{-- <span class="page-link" aria-hidden="true">共{{ $paginator->total() }}条</span>--}}
|
||||
{{-- </li>--}}
|
||||
|
||||
</div>
|
||||
</form>
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
|
||||
Reference in New Issue
Block a user