feat: 商业核算+个人库存+认证优化 #23
@@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<div v-if="isPreview" style="background:#e65100;color:white;text-align:center;padding:6px 16px;font-size:13px;font-weight:600;letter-spacing:0.5px;position:sticky;top:0;z-index:100">
|
||||
⚠️ 预览环境 · PR #{{ prId }} · 数据为生产副本,修改不影响正式环境
|
||||
⚠️ 预览环境 · PR #{{ prId }} · 数据为生产副本,修改不影响正式环境 · {{ buildInfo }}
|
||||
</div>
|
||||
<div class="app-header">
|
||||
<div class="header-inner">
|
||||
@@ -116,6 +116,7 @@ const hostname = window.location.hostname
|
||||
const prMatch = hostname.match(/^pr-(\d+)\./)
|
||||
const isPreview = !!prMatch
|
||||
const prId = prMatch ? prMatch[1] : ''
|
||||
const buildInfo = __BUILD_TIME__ || ''
|
||||
|
||||
function handleTabClick(tab) {
|
||||
if (tab.require === 'login' && !auth.isLoggedIn) {
|
||||
|
||||
@@ -304,7 +304,7 @@ function selectDemoProject() {
|
||||
packaging_cost: p.packaging_cost || 0,
|
||||
labor_cost: p.labor_cost || 0,
|
||||
other_cost: p.other_cost || 0,
|
||||
selling_price: p.selling_price || 0,
|
||||
selling_price: p.selling_price || 299,
|
||||
quantity: p.quantity || 1,
|
||||
notes: p.notes || '',
|
||||
}
|
||||
@@ -330,7 +330,7 @@ async function createProject() {
|
||||
packaging_cost: 0,
|
||||
labor_cost: 0,
|
||||
other_cost: 0,
|
||||
selling_price: 0,
|
||||
selling_price: 299,
|
||||
quantity: 1,
|
||||
notes: '',
|
||||
}),
|
||||
@@ -357,7 +357,7 @@ function selectProject(p) {
|
||||
packaging_cost: p.packaging_cost || 0,
|
||||
labor_cost: p.labor_cost || 0,
|
||||
other_cost: p.other_cost || 0,
|
||||
selling_price: p.selling_price || 0,
|
||||
selling_price: p.selling_price || 299,
|
||||
quantity: p.quantity || 1,
|
||||
notes: p.notes || '',
|
||||
}
|
||||
|
||||
@@ -1,7 +1,12 @@
|
||||
import { defineConfig } from 'vite'
|
||||
import vue from '@vitejs/plugin-vue'
|
||||
|
||||
const buildTime = new Date().toLocaleString('zh-CN', { timeZone: 'Asia/Shanghai', month: '2-digit', day: '2-digit', hour: '2-digit', minute: '2-digit' })
|
||||
|
||||
export default defineConfig({
|
||||
define: {
|
||||
__BUILD_TIME__: JSON.stringify(buildTime),
|
||||
},
|
||||
plugins: [vue()],
|
||||
server: {
|
||||
proxy: {
|
||||
|
||||
Reference in New Issue
Block a user