Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| d48f9f4bd0 | |||
| b591bc522d | |||
| b15e422953 | |||
| 634162e0d9 |
@@ -130,7 +130,7 @@ class _PublicProductScreenState extends State<PublicProductScreen> {
|
|||||||
slivers: [
|
slivers: [
|
||||||
// 1. Gallery
|
// 1. Gallery
|
||||||
SliverToBoxAdapter(
|
SliverToBoxAdapter(
|
||||||
child: _HeroGallery(imageUrls: imageUrls),
|
child: _HeroGallery(imageUrls: imageUrls, shopName: shop?['name'] as String? ?? ''),
|
||||||
),
|
),
|
||||||
// 2. Verified ribbon
|
// 2. Verified ribbon
|
||||||
SliverToBoxAdapter(
|
SliverToBoxAdapter(
|
||||||
@@ -227,7 +227,8 @@ class _PublicProductScreenState extends State<PublicProductScreen> {
|
|||||||
|
|
||||||
class _HeroGallery extends StatefulWidget {
|
class _HeroGallery extends StatefulWidget {
|
||||||
final List<String> imageUrls;
|
final List<String> imageUrls;
|
||||||
const _HeroGallery({required this.imageUrls});
|
final String shopName;
|
||||||
|
const _HeroGallery({required this.imageUrls, this.shopName = ''});
|
||||||
|
|
||||||
@override
|
@override
|
||||||
State<_HeroGallery> createState() => _HeroGalleryState();
|
State<_HeroGallery> createState() => _HeroGalleryState();
|
||||||
@@ -280,7 +281,7 @@ class _HeroGalleryState extends State<_HeroGallery> {
|
|||||||
),
|
),
|
||||||
// Image or placeholder
|
// Image or placeholder
|
||||||
if (urls.isEmpty)
|
if (urls.isEmpty)
|
||||||
_EmptyGalleryContent()
|
_EmptyGalleryContent(shopName: widget.shopName)
|
||||||
else
|
else
|
||||||
PageView.builder(
|
PageView.builder(
|
||||||
controller: _ctrl,
|
controller: _ctrl,
|
||||||
@@ -291,7 +292,7 @@ class _HeroGalleryState extends State<_HeroGallery> {
|
|||||||
child: Image.network(
|
child: Image.network(
|
||||||
urls[i],
|
urls[i],
|
||||||
fit: BoxFit.contain,
|
fit: BoxFit.contain,
|
||||||
errorBuilder: (_, __, ___) => _EmptyGalleryContent(),
|
errorBuilder: (_, __, ___) => _EmptyGalleryContent(shopName: widget.shopName),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@@ -409,8 +410,12 @@ class _HeroGalleryState extends State<_HeroGallery> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
class _EmptyGalleryContent extends StatelessWidget {
|
class _EmptyGalleryContent extends StatelessWidget {
|
||||||
|
final String shopName;
|
||||||
|
const _EmptyGalleryContent({this.shopName = ''});
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
|
final initial = shopName.isNotEmpty ? shopName.characters.first : '店';
|
||||||
return Center(
|
return Center(
|
||||||
child: Column(
|
child: Column(
|
||||||
mainAxisSize: MainAxisSize.min,
|
mainAxisSize: MainAxisSize.min,
|
||||||
@@ -421,9 +426,9 @@ class _EmptyGalleryContent extends StatelessWidget {
|
|||||||
color: const Color(0xFF0F3057),
|
color: const Color(0xFF0F3057),
|
||||||
borderRadius: BorderRadius.circular(12),
|
borderRadius: BorderRadius.circular(12),
|
||||||
),
|
),
|
||||||
child: const Center(
|
child: Center(
|
||||||
child: Text('岩美',
|
child: Text(initial,
|
||||||
style: TextStyle(color: Colors.white70, fontSize: 18, fontWeight: FontWeight.w700)),
|
style: const TextStyle(color: Colors.white70, fontSize: 28, fontWeight: FontWeight.w700)),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
const SizedBox(height: 12),
|
const SizedBox(height: 12),
|
||||||
|
|||||||
@@ -19,6 +19,13 @@
|
|||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta content="IE=Edge" http-equiv="X-UA-Compatible">
|
<meta content="IE=Edge" http-equiv="X-UA-Compatible">
|
||||||
<meta name="description" content="岩美酒库管理系统 — 酒店饮品库存与采购管理平台">
|
<meta name="description" content="岩美酒库管理系统 — 酒店饮品库存与采购管理平台">
|
||||||
|
<meta name="color-scheme" content="light">
|
||||||
|
<style>
|
||||||
|
html, body {
|
||||||
|
background-color: #ffffff;
|
||||||
|
color-scheme: light;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
||||||
<!-- iOS meta tags & icons -->
|
<!-- iOS meta tags & icons -->
|
||||||
<meta name="mobile-web-app-capable" content="yes">
|
<meta name="mobile-web-app-capable" content="yes">
|
||||||
|
|||||||
@@ -39,6 +39,20 @@ server {
|
|||||||
try_files $uri $uri/ /app/index.html;
|
try_files $uri $uri/ /app/index.html;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# index.html 不缓存,确保每次发版后浏览器加载最新版
|
||||||
|
location = /app/index.html {
|
||||||
|
alias /opt/jiu/web/index.html;
|
||||||
|
add_header Cache-Control "no-cache, no-store, must-revalidate";
|
||||||
|
add_header Pragma "no-cache";
|
||||||
|
expires 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
# 公开商品详情页(扫码跳转)→ 交给 Flutter Web 路由处理
|
||||||
|
location ~ ^/product/ {
|
||||||
|
root /opt/jiu/web;
|
||||||
|
try_files $uri /app/index.html;
|
||||||
|
}
|
||||||
|
|
||||||
# 扫码页(/scan/<id> → scan.html,JS 从 URL 读取 id)
|
# 扫码页(/scan/<id> → scan.html,JS 从 URL 读取 id)
|
||||||
location /scan/ {
|
location /scan/ {
|
||||||
root /opt/jiu/marketing;
|
root /opt/jiu/marketing;
|
||||||
|
|||||||
@@ -5,6 +5,8 @@
|
|||||||
========================================================================= */
|
========================================================================= */
|
||||||
|
|
||||||
:root {
|
:root {
|
||||||
|
color-scheme: light;
|
||||||
|
|
||||||
/* ---------- Brand: Primary (Slate Blue) ---------- */
|
/* ---------- Brand: Primary (Slate Blue) ---------- */
|
||||||
/* Trustworthy enterprise blue with a slight slate cast. */
|
/* Trustworthy enterprise blue with a slight slate cast. */
|
||||||
--brand-50: #EEF4FB;
|
--brand-50: #EEF4FB;
|
||||||
|
|||||||
@@ -3,6 +3,7 @@
|
|||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||||
|
<meta name="color-scheme" content="light" />
|
||||||
<title>岩美酒库管理系统 — 为酒行与酒店设计的库存管理平台</title>
|
<title>岩美酒库管理系统 — 为酒行与酒店设计的库存管理平台</title>
|
||||||
<link rel="stylesheet" href="assets/colors_and_type.css" />
|
<link rel="stylesheet" href="assets/colors_and_type.css" />
|
||||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||||
|
|||||||
Reference in New Issue
Block a user