feat(location): 位置相册公开链接 — 生成无需登录的分享链接
Open
Nobody has claimed this yet.
enhancement
status: pending-review
- Dominant language
- Python
- Stars
- 739
- Forks
- 97
- Avg merge
- 10h 3m
- Merged PRs (30d)
- 82
Description
功能描述
对指定位置/景区生成一个无需登录即可查看的公开链接,适合分享旅途相册给朋友。
实现思路
- 后端新增
share_tokens表(token, location_name, level, photo_ids, expires_at, created_by) - 新增 API:
POST /api/locations/share创建分享链接,GET /api/locations/shared/{token}获取公开数据(免认证) - 前端在
LocationDetail.vue增加分享按钮,弹出对话框配置:有效期(7天/30天/永久)、是否包含原图 - 公开页面使用 blank 布局,只展示照片瀑布流,不暴露用户其他数据
- 支持设置访问密码
优先级
低 — 功能完整但工作量较大,涉及安全审查
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the mentioned LocationDetail.vue entry point and map the existing location API and authentication flow before designing the share_tokens table and the two share endpoints. Done means creating expiring or permanent links with optional passwords and original photos, rendering a public blank-layout waterfall page, and completing the security review so no other user data is exposed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, python
- Domain
- api, full-stack, security
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100