feat(miniprogram): OSS直链上传+资讯互动+详情页重设计

- API 基址支持 TARO_APP_API_BASE 覆盖;头像/入驻资料上传带 dir 业务目录(OSS 路径规范)
- 资讯详情:真实点赞(计数)/微信分享(openType=share+useShareAppMessage)/留言;封面 3.35:1 裁切;顶部色条修复
- 发布者徽章(官方/园区/OPC 三款渐变胶囊);头像有则显示无则不留位
- 动作按钮纯图标化并入留言标题行;留言区胶囊输入+渐变发送键
This commit is contained in:
Pine
2026-08-28 17:20:10 +08:00
parent d23b6976eb
commit c6def26b52
14 changed files with 68 additions and 30 deletions
+1 -1
View File
@@ -4,7 +4,7 @@ import { cached } from './cache';
// API 基址
// - 开发:指向本地 web 后端(project.config.json 需 urlCheck:false
// - 生产:真实备案 HTTPS 域名(小程序要求)
const API_BASE = 'https://opc.pinesound.cn'; // 云超服 FastAPI 后端(备案 HTTPS 域名)
export const API_BASE = process.env.TARO_APP_API_BASE || 'https://opc.pinesound.cn'; // 云超服 FastAPI 后端(备案 HTTPS 域名;开发可用 TARO_APP_API_BASE 覆盖
/**
* 统一请求封装(对齐 web 端 fetch 契约)
+2 -2
View File
@@ -9,8 +9,8 @@ export const MK_HERO = {
headline: ['ONE PERSON', 'DESIGNED TO EVOLVE'],
subhead:
'我们落地在昆明市大学生创业园。每周有免费公益课和线下沙龙,讲透「一个人 + AI 怎么开一家公司」。先来听一场,交个朋友。',
ctaPrimary: { label: '预约公益课 / 沙龙', tab: '/pages/booking/index' },
ctaSecondary: { label: '先做 OPC 测评', tab: '/pages/test/index' }
ctaPrimary: { label: '预约', tab: '/pages/booking/index' },
ctaSecondary: { label: '测评', tab: '/pages/test/index' }
};
export const MK_TRUST = [
+2 -1
View File
@@ -1,7 +1,7 @@
import Taro from '@tarojs/taro';
import { request } from './api';
const API_BASE = 'https://opc.pinesound.cn';
import { API_BASE } from './api';
/** 平台可见园区列表(选择园区用,公开) */
export async function getParks() {
@@ -29,6 +29,7 @@ export async function uploadParkDoc(filePath, name = 'file') {
url: `${API_BASE}/api/upload`,
filePath,
name,
formData: { dir: 'park-admission' },
header: { Authorization: `Bearer ${token}` },
});
const data = JSON.parse(up.data || '{}');