|
22 | 22 | :loading="serverTableLoading"
|
23 | 23 | :scroll="{ y: 'calc(100vh - 220px)' }"
|
24 | 24 | >
|
25 |
| - <template #bodyCell="{ column, record }"> |
| 25 | + <template #bodyCell="{ column, record : item }"> |
26 | 26 | <template v-if="column.dataIndex === 'name'">
|
27 |
| - <div> |
28 |
| - {{ record.ServerName ? record.ServerName : record.Name }} |
29 |
| - </div> |
| 27 | + <div>{{ item.ServerName ? item.ServerName : item.Name }}</div> |
30 | 28 | </template>
|
31 | 29 | <template v-if="column.dataIndex === 'status'">
|
32 | 30 | <div style="font-size: 20px">
|
33 |
| - <RightSquareFilled class="status-stop" v-if="!record.isRunning" /> |
34 |
| - <RightSquareFilled class="status-start" v-if="record.isRunning" /> |
| 31 | + <RightSquareFilled class="status-stop" v-if="!item.isRunning" /> |
| 32 | + <RightSquareFilled class="status-start" v-if="item.isRunning" /> |
35 | 33 | </div>
|
36 | 34 | </template>
|
37 | 35 |
|
38 | 36 | <template v-if="column.dataIndex === 'operate'">
|
39 | 37 | <div class="operate-td">
|
40 |
| - <a-button type="primary" @click="startServerClick(record)" v-if="!record.isRunning" :loading="record.btnLoading"> |
| 38 | + <a-button type="primary" @click="startServerClick(item)" v-if="!item.isRunning" :loading="item.btnLoading"> |
41 | 39 | <template #icon>
|
42 | 40 | <PoweroffOutlined />
|
43 | 41 | </template>
|
44 | 42 | {{ t('Start') }}
|
45 | 43 | </a-button>
|
46 |
| - <a-button type="primary" @click="stopServerClick(record)" v-if="record.isRunning" :loading="record.btnLoading"> |
| 44 | + <a-button type="primary" @click="stopServerClick(item)" v-if="item.isRunning" :loading="item.btnLoading"> |
47 | 45 | <template #icon>
|
48 | 46 | <PoweroffOutlined />
|
49 | 47 | </template>
|
50 | 48 | {{ t('Stop') }}
|
51 | 49 | </a-button>
|
52 |
| - <a-button type="primary" @click="restartServerClick(record)" :loading="record.btnLoading" :disabled="!record.isRunning"> |
| 50 | + <a-button type="primary" @click="restartServerClick(item)" :loading="item.btnLoading" :disabled="!item.isRunning"> |
53 | 51 | <template #icon>
|
54 | 52 | <ReloadOutlined />
|
55 | 53 | </template>
|
|
58 | 56 | <a-dropdown :trigger="['click']">
|
59 | 57 | <template #overlay>
|
60 | 58 | <a-menu>
|
61 |
| - <a-menu-item @click="openInstallDir(record)" key="999"> |
| 59 | + <a-menu-item @click="openInstallDir(item)" key="999"> |
62 | 60 | {{ mt('Open', 'ws', 'Directory') }}
|
63 | 61 | </a-menu-item>
|
64 |
| - <a-menu-item v-if="record.ConfPath" @click="openConfFile(record)" key="998"> |
65 |
| - {{ mt('Open', 'ws') }}{{ Path.GetBaseName(record.ConfPath) }} |
| 62 | + <a-menu-item v-if="item.ConfPath" @click="openConfFile(item)" key="998"> |
| 63 | + {{ mt('Open', 'ws') }}{{ Path.GetBaseName(item.ConfPath) }} |
66 | 64 | </a-menu-item>
|
67 |
| - <a-menu-item v-if="record.ServerConfPath" @click="openServerConfFile(record)" key="997"> |
68 |
| - {{ mt('Open', 'ws') }}{{ Path.GetBaseName(record.ServerConfPath) }} |
| 65 | + <a-menu-item v-if="item.ServerConfPath" @click="openServerConfFile(item)" key="997"> |
| 66 | + {{ mt('Open', 'ws') }}{{ Path.GetBaseName(item.ServerConfPath) }} |
69 | 67 | </a-menu-item>
|
70 |
| - <a-menu-item v-for="(item, i) in record.ExtraFiles" :key="i" @click="openExtraFile(record, item)"> |
| 68 | + <a-menu-item v-for="(item, i) in item.ExtraFiles" :key="i" @click="openExtraFile(item, item)"> |
71 | 69 | {{ mt('Open', 'ws') }}{{ item.Name }}
|
72 | 70 | </a-menu-item>
|
73 | 71 | </a-menu>
|
|
0 commit comments