{"id":15184903,"url":"https://github.com/ctq123/crowdfunding","last_synced_at":"2026-02-07T22:02:19.275Z","repository":{"id":252547678,"uuid":"840614859","full_name":"ctq123/Crowdfunding","owner":"ctq123","description":"web3-智能合约-DApp众筹项目","archived":false,"fork":false,"pushed_at":"2024-08-12T10:16:27.000Z","size":657,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-30T00:15:28.664Z","etag":null,"topics":["koa","vue2","web3"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ctq123.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-08-10T06:51:59.000Z","updated_at":"2025-04-21T10:26:41.000Z","dependencies_parsed_at":"2024-08-10T17:02:54.887Z","dependency_job_id":"82e6847b-0de6-40d7-9b2e-8d17e84a887e","html_url":"https://github.com/ctq123/Crowdfunding","commit_stats":{"total_commits":10,"total_committers":1,"mean_commits":10.0,"dds":0.0,"last_synced_commit":"97bb99aad47c31db8e041d22478e2dfc838b4f4b"},"previous_names":["ctq123/crowdfunding"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/ctq123/Crowdfunding","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ctq123%2FCrowdfunding","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ctq123%2FCrowdfunding/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ctq123%2FCrowdfunding/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ctq123%2FCrowdfunding/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ctq123","download_url":"https://codeload.github.com/ctq123/Crowdfunding/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ctq123%2FCrowdfunding/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29209840,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-07T21:35:21.898Z","status":"ssl_error","status_checked_at":"2026-02-07T21:35:20.106Z","response_time":63,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["koa","vue2","web3"],"created_at":"2024-09-27T17:42:08.851Z","updated_at":"2026-02-07T22:02:18.719Z","avatar_url":"https://github.com/ctq123.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# crowdfunding\n一个完整的应用，Ganache + Truffle开发智能合约，用户界面DApp，实现众筹功能\n\n## 项目结构\n```\ncrowdfunding\n├── contracts\n│   └── Crowdfunding.sol\n├── migrations\n│   └── 2_deploy_contracts.js\n├── node_modules\n├── public\n│   ├── index.html\n│   ├── favicon.ico\n├── server\n│   ├── index.js\n│   └── routes\n├── src\n│   ├── assets\n│   ├── components\n│   ├── App.vue\n│   ├── main.js\n├── test\n│   └── ..\n├── .gitignore\n├── babel.config.js\n├── package.json\n├── README.md\n└── truffle-config.js\n```\n\n## 智能合约\n\n#### 前置条件\n若还没有安装truffle和ganache-cli的需要提前安装\n\n```bash\nnpm install -g truffle@6.14.13\nnpm install -g ganache-cli@6.14.13\n```\n\u003e node版本说明\n\u003e node@16.14.0\n```\nnvm use 16.14.0\n```\n\n若安装后，ganache-cli没生效，需要刷新下bash_profile\n```\nsource ~/.bash_profile\n```\n\n若安装后，ganache-cli启动后，无法连接到truffle，需要修改truffle-config.js\n```\nnetworks: {\n  development: {\n    host: \"127.0.0.1\",     // Localhost (default: none)\n    port: 8545,            // Standard Ethereum port (default: none)\n    network_id: \"*\",       // Any network (default: none)\n  },\n}\n```\n\n#### 编译\n```\ntruffle compile\n```\n\n#### 启动\n新建一个窗口，启动服务\n```\nganache-cli\n```\n\n#### 部署\n```\ntruffle migrate\n```\n\n### 安装\n```\nyarn\n```\n\n### 运行\n```js\n// 启动前端\nyarn serve\n```\n\n\n## 服务端\n\n#### 前置条件\n安装mysql\n\n```bash\nbrew install mysql\n```\n另一种通过下载安装包进行安装，地址：https://downloads.mysql.com/archives/community/\n选择自己的电脑对应的安装包，以及兼容的版本\n\n安装完成后，启动，创建数据库\n```bash\n// 终端\nmysql -u root -p\n```\n\n```bash\n// 创建数据库\nCREATE DATABASE database_name;\n```\n\n```bash\n// 查看所有数据库\nSHOW DATABASES;\n```\n\n### 安装\n```\nyarn\n```\n\n#### 运行\n```js\n// 启动服务\nnode index.js\n```\n\n\n\n\n## 常见问题\n\n#### 1.程序中调用deployed()部署合约，报错Error: CrowdfundingCamp has not been deployed to detected network (network/artifact mismatch)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fctq123%2Fcrowdfunding","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fctq123%2Fcrowdfunding","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fctq123%2Fcrowdfunding/lists"}