定制 jvleeuwen/cspreporter 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

jvleeuwen/cspreporter

Composer 安装命令:

composer create-project jvleeuwen/cspreporter

包简介

Cspreporter.nl intergration in laravel.

README 文档

README

Master: Build Status Coverage Status Maintainability Test Coverage StyleCI

Develop: Build Status Coverage Status Maintainability Test Coverage StyleCI

CSPreporter Laravel Package

Installation

To get the latest version, simply require the project using Composer:

$ composer require jvleeuwen/laravel-cspreporter

Using the package:

// Return an array of current open/scheduled issues and maintenaince windows.
$array = cspreporter::uri('http://cspreporter.nl/rss/actueel/');

// Using the configuration file.
$array = cspreporter::uri({{config('cspreporter.uri').config('cspreporter.actueel)}});

Returned array contents:

$array = [
    'id'    		=> (integer) $item->attributes()->id,
    'title' 		=> (string) $item->title,
    'description'	=> (string) $item->description,
    'pubDate'		=> (string) $item->pubDate,
    'startDate'		=> (string) $item->startDate,
    'endDate'		=> (string) $item->endDate,
    'category'		=> (string) $item->category,
    'link'			=> (string) $item->link,
];

.Env options:

These value's are currently set by default if not present in the .env file:

CSPREPORTER_URI=http://cspreporter.nl/rss/
CSPREPORTER_WERKZAAMHEDEN=werkzaamheden/
CSPREPORTER_STORINGEN=storingen/
CSPREPORTER_ACTUEEL=actueel/

Available commands:

// Uri:
$array = cspreporter::uri('<cspreporter uri>'); // grabs the uri and returns the xml as an array;

// File:
$file = cspreporter::file('<localFile>'); // parses the file and returns the xml as an array;

// Test:
$test = cspreporter::test(); // Temporary test function, will be removed later on.

// ParseRss:
$parse = cspreporter::ParseRss('simplexml_load_string('filecontents')'); // implements the simplexml_load_string, parses the xml and returns an array;

Scheduling:

See the Laravel docs on scheduling. Advising is to pull the Feed once every 10 minutes or less. This prevents the App from beeing blocked.

Tests:

All the needed tests are provided in the /tests dir. If u are missing something check the Questions and commands section.

Questions and comments:

I am allways open for questions and comments. Just reach out to me and i will do my best.

License

This package is licensed under The MIT License (MIT).

统计信息

  • 总下载量: 17
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 2
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2017-11-14

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固