gemercheung 2 years ago
parent
commit
8c7fcd272a

+ 8 - 1
src/locales/lang/en/statistic.ts

@@ -17,5 +17,12 @@ export default {
   firstEnter: "First time Entrance",
   departure: "Last time Departure",
   amount: 'amount',
-  message: 'message'
+  message: 'message',
+  aofubt: "Amount of Online Users by Time",
+  roomUsage: "Room Usage",
+  userViews: 'User Views',
+  userShare: "User Share",
+  msgMans: "Messagers",
+  msgNumber: "Messages Total",
+
 }

+ 7 - 1
src/locales/lang/zh/statistic.ts

@@ -17,5 +17,11 @@ export default {
     firstEnter: "初次进入房间",
     departure: "最后离开房间",
     amount: '数量',
-    message: '留言内容'
+    message: '留言内容',
+    aofubt: "各时段在线人数",
+    roomUsage: "房间使用情况",
+    userViews: '用户浏览量',
+    userShare: "用户分享数",
+    msgMans: "留言人数",
+    msgNumber: "留言总数"
 }

+ 13 - 11
src/views/statistic/tab/tab1.vue

@@ -99,7 +99,7 @@
 
     <a-row style="margin-bottom: 20px">
       <a-col :span="24">
-        <a-card title="各时间段在线人数">
+        <a-card :title="t('statistic.aofubt')">
           <div id="chart-1" class="chart"></div>
         </a-card>
       </a-col>
@@ -107,17 +107,17 @@
 
     <a-row>
       <a-col :span="24">
-        <a-card title="房间使用情况" style="overflow: hidden">
+        <a-card :title="t('statistic.roomUsage')" style="overflow: hidden">
           <div class="container search-container" style="min-width: 850px">
             <a-form layout="inline" :model="formState" @finish="handleFinish">
-              <a-form-item label="房间名称" name="roomTitle">
+              <a-form-item :label="t('room.roomTitle')" name="roomTitle">
                 <a-input
                   v-model:value="formState.roomTitle"
-                  placeholder="房间名称"
+                  :placeholder="t('room.roomTitle')"
                 >
                 </a-input>
               </a-form-item>
-              <a-form-item label="使用时间" name="username">
+              <a-form-item :label="t('room.usingTime')" name="username">
                 <a-range-picker
                   :show-time="{ format: 'HH:mm' }"
                   format="YYYY-MM-DD HH:mm"
@@ -126,7 +126,9 @@
                 />
               </a-form-item>
               <a-form-item>
-                <a-button type="primary" html-type="submit"> 确定 </a-button>
+                <a-button type="primary" html-type="submit">
+                  {{ t('base.confirm') }}
+                </a-button>
               </a-form-item>
             </a-form>
           </div>
@@ -250,7 +252,7 @@ const initOnlineChart = () => {
       },
       series: [
         {
-          name: '各时段在线人数',
+          name: t('statistic.aofubt'),
           type: 'line',
           smooth: true,
           data: yAxis
@@ -339,7 +341,7 @@ const initRoomVisitChart = () => {
           data: ch1Y,
           type: 'bar',
           areaStyle: {},
-          name: '用户浏览量',
+          name: t('statistic.userViews'),
           itemStyle: {
             color: '#5ab1ef'
           }
@@ -348,7 +350,7 @@ const initRoomVisitChart = () => {
           smooth: true,
           data: ch2Y,
           type: 'bar',
-          name: '用户分享数',
+          name: t('statistic.userShare'),
           areaStyle: {},
           itemStyle: {
             color: '#019680'
@@ -436,7 +438,7 @@ const initRoomMsgChart = () => {
           data: ch1Y,
           type: 'line',
           areaStyle: {},
-          name: '留言人数',
+          name: t('statistic.msgMans'),
           itemStyle: {
             color: '#5ab1ef'
           }
@@ -445,7 +447,7 @@ const initRoomMsgChart = () => {
           smooth: true,
           data: ch2Y,
           type: 'line',
-          name: '留言总数',
+          name: t('statistic.msgNumber'),
           areaStyle: {},
           itemStyle: {
             color: '#019680'