Browse Source

整改基本完成

Huanyi 9 giờ trước cách đây
mục cha
commit
b29f404ce6

+ 2 - 1
package.json

@@ -8,6 +8,7 @@
   "type": "module",
   "scripts": {
     "dev": "vite serve --mode development",
+    "test": "vite serve --mode test",
     "prod": "vite serve --mode production",
     "build:prod": "vite build --mode production",
     "build:test": "vite build --mode test",
@@ -96,4 +97,4 @@
     "Safari >= 14",
     "Firefox >= 78"
   ]
-}
+}

+ 9 - 1
src/components/CustomerDetailDrawer/index.vue

@@ -278,6 +278,7 @@ onMounted(() => {
 .name-row {
   display: flex;
   align-items: center;
+  gap: 12px;
 }
 
 .name {
@@ -287,7 +288,6 @@ onMounted(() => {
 }
 
 .phone {
-  margin-left: 10px;
   color: #666;
 }
 
@@ -299,4 +299,12 @@ onMounted(() => {
   padding-left: 10px;
   line-height: 1.2;
 }
+
+.profile-tabs {
+  padding-top: 10px;
+}
+
+.profile-tabs :deep(.el-tab-pane) {
+  padding-top: 15px;
+}
 </style>

+ 2 - 1
src/components/PetDetailDrawer/index.vue

@@ -36,7 +36,7 @@
 
         <div class="section-title" style="margin-top: 20px">家庭信息</div>
         <el-descriptions :column="2" border>
-          <el-descriptions-item label="到家时间">{{ currentPet.arrivalTime || '-' }}</el-descriptions-item>
+          <el-descriptions-item label="到家时间">{{ currentPet.arrivalTime ? proxy.parseTime(currentPet.arrivalTime, '{y}-{m}-{d}') : '-' }}</el-descriptions-item>
           <el-descriptions-item label="房屋类型">
             <dict-tag :options="sys_house_type" :value="currentPet.houseType" />
           </el-descriptions-item>
@@ -265,6 +265,7 @@ onMounted(() => {
   font-size: 20px;
   font-weight: bold;
   color: #303133;
+  margin-right: 12px;
 }
 
 .section-title {

+ 1 - 1
src/views/archieves/customer/index.vue

@@ -71,7 +71,7 @@
             />
           </template>
         </el-table-column>
-<!--        <el-table-column prop="remark" label="备注" show-overflow-tooltip />-->
+        <el-table-column prop="remark" label="备注" show-overflow-tooltip min-width="150" />
         <el-table-column label="操作" width="200" align="center">
           <template #default="scope">
             <el-button link type="primary" size="small" @click="handleDetail(scope.row)" v-hasPermi="['archieves:customer:query']">详情</el-button>

+ 7 - 4
src/views/order/management/components/OrderDetailDrawer.vue

@@ -402,9 +402,10 @@ const loadPetAndCustomer = async (order) => {
         try {
             const res = await getPet(petId)
             const pet = res?.data
+            console.log('Web商户端 - 宠物详情:', pet)
             if (pet) {
                 next.petName = pet.name ?? next.petName
-                next.petAvatar = pet.avatarUrl ?? next.petAvatar
+                next.petAvatar = pet.avatarUrl || pet.avatar || next.petAvatar
                 next.petGender = pet.gender ?? next.petGender
                 next.petAge = (pet.age !== undefined && pet.age !== null) ? `${pet.age}岁` : next.petAge
                 next.petWeight = (pet.weight !== undefined && pet.weight !== null) ? `${pet.weight}kg` : next.petWeight
@@ -413,7 +414,7 @@ const loadPetAndCustomer = async (order) => {
                     ? (Number(pet.isSterilized) === 1)
                     : next.petSterilized
                 next.petVaccine = pet.vaccineStatus ?? next.petVaccine
-                next.petCharacter = pet.personality ?? next.petCharacter
+                next.petCharacter = (pet.cutePersonality || pet.personality) ?? next.petCharacter
                 next.petHealth = pet.healthStatus ?? next.petHealth
             }
         } catch {
@@ -425,9 +426,10 @@ const loadPetAndCustomer = async (order) => {
         try {
             const res = await getCustomer(customerId)
             const customer = res?.data
+            console.log('Web商户端 - 客户详情:', customer)
             if (customer) {
                 next.userName = customer.name ?? next.userName
-                next.userAvatar = customer.avatarUrl ?? next.userAvatar
+                next.userAvatar = customer.avatarUrl || customer.avatar || next.userAvatar
                 next.contactPhone = customer.phone ?? next.contactPhone
                 next.city = customer.areaName ?? next.city
                 next.address = customer.address ?? next.address
@@ -441,8 +443,9 @@ const loadPetAndCustomer = async (order) => {
         try {
             const res = await getFulfillerDetail(fulfillerId)
             const fulfillerData = res?.data?.data || res?.data
+            console.log('Web商户端 - 履约者详情:', fulfillerData)
             if (fulfillerData) {
-                next.fulfillerAvatar = fulfillerData.avatarUrl ?? next.fulfillerAvatar
+                next.fulfillerAvatar = fulfillerData.avatarUrl || fulfillerData.avatar || next.fulfillerAvatar
                 next.fulfillerPhone = fulfillerData.phone ?? next.fulfillerPhone
                 next.fulfillerStation = fulfillerData.stationName ?? next.fulfillerStation
                 next.fulfillerName = fulfillerData.name ?? next.fulfillerName

+ 1 - 1
src/views/order/purchase/index.vue

@@ -58,7 +58,7 @@
               <el-form-item label="选择宠物" v-if="form.userId">
                 <div class="pet-select-row">
                   <div v-for="p in currentPets" :key="p.id" class="pet-card" :class="{ active: form.petId === p.id }" @click="form.petId = p.id">
-                    <el-avatar :size="48" :src="p.avatar" shape="square" style="border-radius: 6px">{{ p.name.charAt(0) }}</el-avatar>
+                    <el-avatar :size="48" :src="p.avatarUrl || p.avatar" shape="square" style="border-radius: 6px">{{ p.name.charAt(0) }}</el-avatar>
                     <div class="pet-info">
                       <div class="name">{{ p.name }}</div>
                       <div class="sub">{{ p.breed }}</div>