add
This commit is contained in:
28
frontend/src/views/nurse/Notices.vue
Normal file
28
frontend/src/views/nurse/Notices.vue
Normal file
@@ -0,0 +1,28 @@
|
||||
<template>
|
||||
<div class="page-card">
|
||||
<h3>Notices</h3>
|
||||
<el-table :data="items" stripe>
|
||||
<el-table-column prop="title" label="Title" />
|
||||
<el-table-column prop="content" label="Content" />
|
||||
<el-table-column prop="createdAt" label="Created" />
|
||||
</el-table>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { nurseNoticeList } from "../../api";
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return { items: [] };
|
||||
},
|
||||
async created() {
|
||||
try {
|
||||
const res = await nurseNoticeList();
|
||||
this.items = res.data.data;
|
||||
} catch (e) {
|
||||
this.$message.error(e.message || "load failed");
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
Reference in New Issue
Block a user