49 lines
2.6 KiB
Vue
49 lines
2.6 KiB
Vue
<!-- 页面编号:F-09;用途:相册照片写入。没有文件上传与 OSS 回执 owner 时关闭。 -->
|
||
<template>
|
||
<view class="media-upload-page">
|
||
<ModulePageBackground module="family" />
|
||
<view class="media-upload-header"><PageHeader title="添加照片" custom-back @back="returnToAlbum" /></view>
|
||
<view class="media-upload-content">
|
||
<view class="media-state-card">
|
||
<text class="media-state-card__eyebrow">文件服务待接入</text>
|
||
<text class="media-state-card__title">照片上传暂不可用</text>
|
||
<text class="media-state-card__copy">照片写入接口要求已有 `ossId`。当前没有经 Apifox 核实的文件上传 owner、真实 OSS 回执或访问 URL,页面不再从本地图片库选择图片,也不会生成上传预览。</text>
|
||
<AppButton block :label="hasValidContext ? '返回相册列表' : '返回上一页'" @click="returnToAlbum" />
|
||
</view>
|
||
</view>
|
||
</view>
|
||
</template>
|
||
|
||
<script setup>
|
||
import { computed, ref } from "vue";
|
||
import { onLoad } from "@dcloudio/uni-app";
|
||
import AppButton from "@/components/AppButton.vue";
|
||
import ModulePageBackground from "@/components/ModulePageBackground.vue";
|
||
import PageHeader from "@/components/PageHeader.vue";
|
||
import { goBack, returnTo } from "@/utils/navigation.js";
|
||
|
||
const genealogyId = ref("");
|
||
const albumId = ref("");
|
||
const hasValidContext = computed(() => /^[1-9]\d*$/.test(genealogyId.value) && /^[1-9]\d*$/.test(albumId.value));
|
||
onLoad((query) => {
|
||
genealogyId.value = String(query?.genealogyId || "");
|
||
albumId.value = String(query?.albumId || "");
|
||
});
|
||
const returnToAlbum = () => hasValidContext.value
|
||
? returnTo("F07", { genealogyId: genealogyId.value })
|
||
: goBack();
|
||
</script>
|
||
|
||
<style scoped lang="scss">
|
||
@use "../../styles/adaptive-frame-profiles.scss" as adaptive;
|
||
.media-upload-page { display: flex; min-height: 100vh; flex-direction: column; background: $paper; }
|
||
.media-upload-header, .media-upload-content { z-index: 1; }
|
||
.media-upload-content { padding: 20rpx 24rpx calc(48rpx + env(safe-area-inset-bottom)); }
|
||
.media-state-card { @include adaptive.adaptive-family-panel; min-height: 410rpx; box-sizing: border-box; padding: 98rpx 46rpx 58rpx; text-align: center; }
|
||
.media-state-card text { display: block; }
|
||
.media-state-card__eyebrow { color: $brand-red; font-size: 22rpx; letter-spacing: 2rpx; }
|
||
.media-state-card__title { margin-top: 12rpx; color: $ink; font-family: STKaiti, KaiTi, serif; font-size: 35rpx; font-weight: 700; }
|
||
.media-state-card__copy { margin-top: 16rpx; color: $ink-muted; font-size: 23rpx; line-height: 1.65; }
|
||
.media-state-card .app-button { margin-top: 30rpx; }
|
||
</style>
|