{"id":15356631,"url":"https://github.com/adlered/voter","last_synced_at":"2025-04-15T06:41:42.926Z","repository":{"id":105570674,"uuid":"189395864","full_name":"adlered/Voter","owner":"adlered","description":":cn: Simple online vote system based on Spring Boot | 基于SpringBoot的简约投票系统 | :sunglasses: COOL \u0026 MODERN | ANONYMOUS | Bootstrap | :cupid: Good looking","archived":false,"fork":false,"pushed_at":"2020-05-14T03:21:02.000Z","size":27545,"stargazers_count":62,"open_issues_count":0,"forks_count":30,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-04-15T06:41:39.864Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://voter.stackoverflow.wiki/","language":"Java","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/adlered.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null},"funding":{"custom":["https://doc.stackoverflow.wiki/web/#/21?page_id=138"]}},"created_at":"2019-05-30T10:42:54.000Z","updated_at":"2025-02-11T10:12:58.000Z","dependencies_parsed_at":"2023-06-28T10:07:06.695Z","dependency_job_id":null,"html_url":"https://github.com/adlered/Voter","commit_stats":{"total_commits":42,"total_committers":4,"mean_commits":10.5,"dds":0.0714285714285714,"last_synced_commit":"27ef5e2a0058122e7a08c78fffe3b63c7084b8ae"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adlered%2FVoter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adlered%2FVoter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adlered%2FVoter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adlered%2FVoter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/adlered","download_url":"https://codeload.github.com/adlered/Voter/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249023725,"owners_count":21199958,"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","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":[],"created_at":"2024-10-01T12:29:23.805Z","updated_at":"2025-04-15T06:41:42.909Z","avatar_url":"https://github.com/adlered.png","language":"Java","funding_links":["https://doc.stackoverflow.wiki/web/#/21?page_id=138"],"categories":[],"sub_categories":[],"readme":"# Voter\n:cn: Simple online vote system based on Spring Boot | 基于SpringBoot的简约投票系统 | :sunglasses: COOL \u0026 MODERN | ANONYMOUS | Bootstrap | :cupid: Good looking\n\n:construction_worker: 部署中遇到问题？:heavy_plus_sign: 我的微信号：1101635162 :ok_hand: 无偿帮助你解决问题。\n\n[中文说明](#中文说明)\n\n[English Version](#english-version)\n\n# 预览 Preview\n\n[公开测试网站 | Public Test Website](https://voter.stackoverflow.wiki/)\n\n![DEMO](/images/Demo-Full.gif)\n\n# 中文说明\n\n## 运行\n\n本项目使用Intellij IDEA构建，你可以使用IDEA直接调试本项目。\n\n### 配置MySQL数据库\n\nVoter默认使用MySQL中的`Voter`库。\n\n```$xslt\n在开始使用之前，请在你的MySQL中先创建一个名为\"Voter\"的数据库。\n```\n\n#### 自动生成表\n\nVoter集成了自动生成数据表的功能。编辑类`pers.adlered.voter.configuration.MySQL`类使项目在启动时自动部署数据表。\n\n**注意：配置此类只是为了自动生成数据表，如果你想为Voter配置读写数据库连接，请配置application.properties文件中的参数。**\n\n\u003e 请注意：如果你想手动建表，可以执行下列语句：\n\n```$xslt\nUSE Voter;\n\nCREATE TABLE `Voter_Vote` (\n  `VID` int(11) NOT NULL AUTO_INCREMENT,\n  `Title` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL,\n  `Describe` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL,\n  `Selection` varchar(10000) CHARACTER SET utf8mb4 DEFAULT NULL,\n  `Type` int(11) DEFAULT '0',\n  `Limit` int(11) DEFAULT '-1',\n  PRIMARY KEY (`VID`)\n) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=latin1;\n\nINSERT INTO `Voter_Vote` VALUES (1, 'This is a vote title :)', 'And here is a describe of the vote XD', '\u003c%1\u003c%92\u003c%Vote for Xiaoli\u003c%2\u003c%42\u003c%Vote for Zhanghua\u003c%3\u003c%41\u003c%Vote for Ergou\u003c%4\u003c%37\u003c%Vote for Guawazi\u003c%5\u003c%48\u003c%Vote for Benwei\u003c%6\u003c%50\u003c%Vote for Adler', 0, 2);\n```\n\n#### 配置数据库连接\n\n当建立完成数据库后，配置`application.properties`文件来配置数据库连接。\n\n## 工作原理\n\n### 实现一串字符串存储所有投票选项统计\n\n存储在数据库中的`SelectionText`字段如下：\n\n```$xslt\n\u003c%1\u003c%0\u003c%Vote for Xiaoli\n\u003c%2\u003c%10\u003c%Vote for Zhanghua\n\u003c%3\u003c%20\u003c%Vote for Ergou\n\u003c%4\u003c%30\u003c%Vote for Guawazi\n\u003c%5\u003c%40\u003c%Vote for Benwei\n\u003c%6\u003c%50\u003c%Vote for Adler\n```\n\n规定的投票存储语法如下：\n\n```$xslt\n\u003c%选项号\u003c%获得票数\u003c%选项描述\n```\n\n通过`pers.adlered.voter.analyzer`中的方法对此字段实现分析与修改。\n\n# English Version\n\n## Run\n\nThis project is built using Intellij IDEA, you can use IDEA to debug this project directly.\n\n### Configuring the MySQL database\n\nVoter defaults to the `Voter` library in MySQL.\n\n```$xslt\nBefore you start using it, create a database called \"Voter\" in your MySQL.\n```\n\n#### Automatically generating tables\n\nVoter integrates the ability to automatically generate data tables. Editing the class `pers.adlered.voter.configuration.MySQL` class enables the project to automatically deploy the data table at startup.\n\n**Note: This class is configured only to automatically generate data tables. If you want to configure read and write database connections for Voter, configure the parameters in the application.properties file. **\n\n\u003e Please note: If you want to build a table manually, you can execute the following statement:\n\n```$xslt\nUSE Voter;\n\nCREATE TABLE `Voter_Vote` (\n  `VID` int(11) NOT NULL AUTO_INCREMENT,\n  `Title` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL,\n  `Describe` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL,\n  `Selection` varchar(10000) CHARACTER SET utf8mb4 DEFAULT NULL,\n  `Type` int(11) DEFAULT '0',\n  `Limit` int(11) DEFAULT '-1',\n  PRIMARY KEY (`VID`)\n) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=latin1;\n\nINSERT INTO `Voter_Vote` VALUES (1, 'This is a vote title :)', 'And here is a describe of the vote XD', '\u003c%1\u003c%92\u003c%Vote for Xiaoli\u003c%2\u003c%42\u003c%Vote for Zhanghua\u003c%3\u003c%41\u003c%Vote for Ergou\u003c%4\u003c%37\u003c%Vote for Guawazi\u003c%5\u003c%48\u003c%Vote for Benwei\u003c%6\u003c%50\u003c%Vote for Adler', 0, 2);\n```\n\n#### Configuring database connections\n\nAfter creating the database, configure the `application.properties` file to configure the database connection.\n\n## working principle\n\n### Implement a string of strings to store all voting option statistics\n\nThe `SelectionText` field stored in the database is as follows:\n\n```$xslt\n\u003c%1\u003c%0\u003c%Vote for Xiaoli\n\u003c%2\u003c%10\u003c%Vote for Zhanghua\n\u003c%3\u003c%20\u003c%Vote for Ergou\n\u003c%4\u003c%30\u003c%Vote for Guawazi\n\u003c%5\u003c%40\u003c%Vote for Benwei\n\u003c%6\u003c%50\u003c%Vote for Adler\n```\n\nThe prescribed voting storage syntax is as follows:\n\n```$xslt\n\u003c% option number \u003c% get votes \u003c% option description\n```\n\nAnalyze and modify this field by the method in `pers.adlered.voter.analyzer`.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fadlered%2Fvoter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fadlered%2Fvoter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fadlered%2Fvoter/lists"}