From 20cdb83586daabfb15fc056c4c97eb8e7ccaf928 Mon Sep 17 00:00:00 2001
From: feiyu02 <risaku@163.com>
Date: 星期五, 20 三月 2026 17:07:16 +0800
Subject: [PATCH] 2026.3.20
---
src/views/system/SystemManage.vue | 160 +++++++++++++++++-----------------------------------
1 files changed, 53 insertions(+), 107 deletions(-)
diff --git a/src/views/system/SystemManage.vue b/src/views/system/SystemManage.vue
index c429e89..c345b68 100644
--- a/src/views/system/SystemManage.vue
+++ b/src/views/system/SystemManage.vue
@@ -60,108 +60,6 @@
/>
</div>
</el-tab-pane>
-
- <!-- 椁愰ギ搴楅摵绠$悊 -->
- <el-tab-pane label="椁愰ギ搴楅摵绠$悊" name="restaurants">
- <div class="tab-content">
- <!-- 鎼滅储鍜屾坊鍔犳寜閽� -->
- <div class="search-add-bar">
- <el-input
- v-model="restaurantSearchQuery"
- placeholder="鎼滅储搴楅摵"
- style="width: 200px"
- prefix-icon="el-icon-search"
- />
- <el-button type="primary" @click="openRestaurantDialog">
- <el-icon><Plus /></el-icon> 娣诲姞搴楅摵
- </el-button>
- </div>
-
- <!-- 搴楅摵琛ㄦ牸 -->
- <el-table :data="filteredRestaurants" style="width: 100%">
- <el-table-column prop="id" label="ID" width="80" />
- <el-table-column prop="name" label="搴楅摵鍚嶇О" />
- <el-table-column prop="address" label="鍦板潃" />
- <el-table-column prop="contact" label="鑱旂郴浜�" />
- <el-table-column prop="phone" label="鑱旂郴鐢佃瘽" />
- <el-table-column label="鎿嶄綔" width="250">
- <template #default="scope">
- <el-button size="small" @click="editRestaurant(scope.row)"> 缂栬緫 </el-button>
- <el-button size="small" type="danger" @click="deleteRestaurant(scope.row.id)">
- 鍒犻櫎
- </el-button>
- <el-button size="small" @click="manageDevices(scope.row)"> 璁惧绠$悊 </el-button>
- </template>
- </el-table-column>
- </el-table>
-
- <!-- 鍒嗛〉 -->
- <el-pagination
- v-model:current-page="restaurantCurrentPage"
- v-model:page-size="restaurantPageSize"
- :page-sizes="[10, 20, 50]"
- layout="total, sizes, prev, pager, next, jumper"
- :total="restaurants.length"
- style="margin-top: 20px"
- />
- </div>
- </el-tab-pane>
-
- <!-- 璁惧绠$悊 -->
- <el-tab-pane label="璁惧绠$悊" name="devices">
- <div class="tab-content" v-if="selectedRestaurant">
- <h3>{{ selectedRestaurant.name }} - 璁惧鍒楄〃</h3>
-
- <!-- 鎼滅储鍜屾坊鍔犳寜閽� -->
- <div class="search-add-bar">
- <el-input
- v-model="deviceSearchQuery"
- placeholder="鎼滅储璁惧"
- style="width: 200px"
- prefix-icon="el-icon-search"
- />
- <el-button type="primary" @click="openDeviceDialog">
- <el-icon><Plus /></el-icon> 娣诲姞璁惧
- </el-button>
- </div>
-
- <!-- 璁惧琛ㄦ牸 -->
- <el-table :data="filteredDevices" style="width: 100%">
- <el-table-column prop="id" label="ID" width="80" />
- <el-table-column prop="deviceId" label="璁惧缂栧彿" />
- <el-table-column prop="type" label="璁惧绫诲瀷" />
- <el-table-column prop="status" label="鐘舵��">
- <template #default="scope">
- <el-tag :type="scope.row.status === 'online' ? 'success' : 'danger'">
- {{ scope.row.status === 'online' ? '鍦ㄧ嚎' : '绂荤嚎' }}
- </el-tag>
- </template>
- </el-table-column>
- <el-table-column prop="installDate" label="瀹夎鏃ユ湡" />
- <el-table-column label="鎿嶄綔" width="200">
- <template #default="scope">
- <el-button size="small" @click="editDevice(scope.row)"> 缂栬緫 </el-button>
- <el-button size="small" type="danger" @click="deleteDevice(scope.row.id)">
- 鍒犻櫎
- </el-button>
- </template>
- </el-table-column>
- </el-table>
-
- <!-- 鍒嗛〉 -->
- <el-pagination
- v-model:current-page="deviceCurrentPage"
- v-model:page-size="devicePageSize"
- :page-sizes="[10, 20, 50]"
- layout="total, sizes, prev, pager, next, jumper"
- :total="devices.length"
- style="margin-top: 20px"
- />
- </div>
- <div class="tab-content" v-else>
- <el-empty description="璇峰厛閫夋嫨涓�涓楗簵閾�" />
- </div>
- </el-tab-pane>
</el-tabs>
</el-card>
@@ -304,12 +202,60 @@
// 鐢ㄦ埛绠$悊鐩稿叧
const users = ref([
- { id: 1, username: 'admin', name: '绠$悊鍛�', role: 'admin', status: 'active' },
- { id: 2, username: 'user1', name: '鐢ㄦ埛1', role: 'user', status: 'active' },
{
- id: 3,
- username: 'restaurant1',
- name: '搴楅摵绠$悊鍛�1',
+ id: 1,
+ username: 'fuxiaojie',
+ name: '浠樺皬濮愬湪鎴愰兘',
+ role: 'restaurant_admin',
+ status: 'active',
+ },
+ { id: 2, username: 'jike', name: '鍚夊埢鑱旂洘', role: 'restaurant_admin', status: 'active' },
+ { id: 3, username: 'jiazaitala', name: '瀹跺湪濉斿暒', role: 'restaurant_admin', status: 'active' },
+ { id: 4, username: 'langlailiao', name: '鐙兼潵浜�', role: 'restaurant_admin', status: 'active' },
+ { id: 5, username: 'lekaisai', name: '涔愬嚡鎾掓槦娓稿簵', role: 'restaurant_admin', status: 'active' },
+ {
+ id: 6,
+ username: 'xinyuan',
+ name: '棣ㄨ繙缇庨灏忛晣锛堝搱灏肩編椋熷箍鍦猴級',
+ role: 'restaurant_admin',
+ status: 'active',
+ },
+ { id: 7, username: 'bangyuehan', name: '妫掔害缈�', role: 'restaurant_admin', status: 'active' },
+ { id: 8, username: 'nangtang', name: '寮勫爞鍜亾', role: 'restaurant_admin', status: 'active' },
+ {
+ id: 9,
+ username: 'yangji',
+ name: '鏉ㄨ榻愰綈鍝堝皵鐑よ倝',
+ role: 'restaurant_admin',
+ status: 'active',
+ },
+ {
+ id: 10,
+ username: 'rensheng',
+ name: '涓婃捣绋斾紶椁愰ギ绠$悊鏈夐檺鍏徃锛堜汉鐢熶竴涓诧級',
+ role: 'restaurant_admin',
+ status: 'active',
+ },
+ { id: 11, username: 'yuanjia', name: '缂樺', role: 'restaurant_admin', status: 'active' },
+ {
+ id: 12,
+ username: 'quansheng',
+ name: '娉夌洓椁愰ギ锛堜笂娴凤級鏈夐檺鍏徃锛堥鍏跺锛�',
+ role: 'restaurant_admin',
+ status: 'active',
+ },
+ { id: 13, username: 'fengmao', name: '涓拌寕鐑や覆', role: 'restaurant_admin', status: 'active' },
+ {
+ id: 14,
+ username: 'taihuang',
+ name: '涓婃捣娉扮厡椁愰ギ绠$悊鏈夐檺鍏徃锛堟嘲鐓岄浮锛�',
+ role: 'restaurant_admin',
+ status: 'active',
+ },
+ {
+ id: 15,
+ username: 'chenxi',
+ name: '寰愭眹鍖鸿景鐔欓棣�(灏忛搧鍚涗覆鐑у眳閰掑眿)',
role: 'restaurant_admin',
status: 'active',
},
--
Gitblit v1.9.3