imagdic/covid19 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

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

imagdic/covid19

Composer 安装命令:

composer require imagdic/covid19

包简介

A Laravel Wrapper for the COVID19 API

README 文档

README

Installation

composer require imagdic/covid19

Usage

// A summary of new and total cases per country updated daily.
$summary = Covid19::summary();

// Get recovered cases for specific country
$recovered = Covid19::recoveredByCountry('countryName');

// Get death cases for specific country
$deaths = Covid19::deathsByCountry('countryName');

// Get confirmed cases for specific country
$confirmed = Covid19::confirmedByCountry('countryName');

// Get all cases for specific country
$allCases = Covid19::allCasesByCountry('countryName');

Example

$allCases = Covid19::allCasesByCountry('Italy');

Content of $allCases variable:

...
  [
    "Country": "Italy",
    "CountryCode": "IT",
    "Province": "",
    "City": "",
    "CityCode": "",
    "Lat": "41.87",
    "Lon": "12.57",
    "Confirmed": 115242,
    "Deaths": 13915,
    "Recovered": 18278,
    "Active": 0,
    "Date": "2020-04-02T00:00:00Z"
  ],
  [
    "Country": "Italy",
    "CountryCode": "IT",
    "Province": "",
    "City": "",
    "CityCode": "",
    "Lat": "41.87",
    "Lon": "12.57",
    "Confirmed": 119827,
    "Deaths": 14681,
    "Recovered": 19758,
    "Active": 0,
    "Date": "2020-04-03T00:00:00Z"
  ],
  [
    "Country": "Italy",
    "CountryCode": "IT",
    "Province": "",
    "City": "",
    "CityCode": "",
    "Lat": "41.87",
    "Lon": "12.57",
    "Confirmed": 124632,
    "Deaths": 15362,
    "Recovered": 20996,
    "Active": 0,
    "Date": "2020-04-04T00:00:00Z"
  ],
...

Run Unit Test

$ php artisan test

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-04-24

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固