{"id":16296880,"url":"https://github.com/windomz/lottery-engine","last_synced_at":"2025-10-24T22:40:18.124Z","repository":{"id":57080986,"uuid":"93845884","full_name":"WindomZ/lottery-engine","owner":"WindomZ","description":"A lottery(抽奖) component engine - modularity and easy to deploy.","archived":false,"fork":false,"pushed_at":"2017-07-03T10:00:32.000Z","size":123,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-08-05T22:12:21.360Z","etag":null,"topics":["component","lottery-engine","module","php7"],"latest_commit_sha":null,"homepage":"https://windomz.github.io/lottery-engine/","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/WindomZ.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-06-09T10:05:31.000Z","updated_at":"2022-02-12T14:15:18.000Z","dependencies_parsed_at":"2022-08-24T14:42:47.626Z","dependency_job_id":null,"html_url":"https://github.com/WindomZ/lottery-engine","commit_stats":null,"previous_names":[],"tags_count":13,"template":false,"template_full_name":null,"purl":"pkg:github/WindomZ/lottery-engine","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WindomZ%2Flottery-engine","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WindomZ%2Flottery-engine/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WindomZ%2Flottery-engine/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WindomZ%2Flottery-engine/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/WindomZ","download_url":"https://codeload.github.com/WindomZ/lottery-engine/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WindomZ%2Flottery-engine/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":280878345,"owners_count":26406641,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-24T02:00:06.418Z","response_time":73,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["component","lottery-engine","module","php7"],"created_at":"2024-10-10T20:24:18.360Z","updated_at":"2025-10-24T22:40:18.090Z","avatar_url":"https://github.com/WindomZ.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# lottery-engine\n\n\u003e A lottery component engine - modularity and easy to deploy.\n\n[![Latest Stable Version](https://img.shields.io/packagist/v/windomz/lottery-engine.svg?style=flat-square)](https://packagist.org/packages/windomz/lottery-engine)\n[![Build Status](https://img.shields.io/travis/WindomZ/lottery-engine/master.svg?style=flat-square)](https://travis-ci.org/WindomZ/lottery-engine)\n[![Minimum PHP Version](https://img.shields.io/badge/php-%3E%3D%207.0-8892BF.svg?style=flat-square)](https://php.net/)\n[![Minimum MYSQL Version](https://img.shields.io/badge/mysql-%3E%3D%205.6-4479a1.svg?style=flat-square)](https://www.mysql.com/)\n[![Platform](https://img.shields.io/badge/platform-Linux%2FmacOS-ff69b4.svg?style=flat-square)](#readme)\n\n[中文文档](https://github.com/WindomZ/lottery-engine/blob/master/README_Ch-zh.md#readme)\n\n## Feature\n\n- [x] Play - How to play\n- [x] Rule - The rule of playing\n- [x] Reward - Play rewards\n- [x] Record - Play records\n\n## Install\n\nOpen the terminal in the project directory:\n```bash\n$ composer require windomz/lottery-engine\n```\n\nCreate a configuration file, like `config.yml`:\n```yaml\ndatabase_host: 127.0.0.1\ndatabase_port: 3306\ndatabase_type: mysql\ndatabase_name: lotterydb\ndatabase_username: root\ndatabase_password: root\ndatabase_charset: utf8\ndatabase_logging: false\ndatabase_json: true # If the database supports JSON.\n```\n\nIf only for quick testing, \nyou can run `./sql/lotterydb.sql` in `MySQL` to quickly create a test database.\n\nOf course, you can also customize the `database name` based on `./sql/lotterydb.sql`, \nbut note that the `table name` _CANNOT MODIFY_!\n\nIn the project initialization, \nload the specified configuration file through the following implementation:\n```php\nLottery::setConfigPath('./config.yml');\n```\n\n## Usage\n\nRefer to the [Document](https://windomz.github.io/lottery-engine)(_Currently only Chinese_) for details.\n\n## Limitation\n\n\u003e There is no memory cache system, such as `Memcached`, `Redis`, but through `shmop` functions to share memory operations, \nthis brings some performance bottlenecks, if necessary, can fork and rewrite `\\LotteryEngine\\Model\\Cache` class to access.\n\n## License\n\nThe [MIT License](https://github.com/WindomZ/lottery-engine/blob/master/LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwindomz%2Flottery-engine","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwindomz%2Flottery-engine","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwindomz%2Flottery-engine/lists"}