From e74e1a3d65eae2350df1153c3d7c79c8c9c6d436 Mon Sep 17 00:00:00 2001
From: fei <791364011@qq.com>
Date: 星期一, 19 一月 2026 10:43:22 +0800
Subject: [PATCH] 增加了代码

---
 src/api/system/annotation.js          |   44 ++++
 src/views/archiveSignature/index.vue  |  261 +++++++++++++++++++++++
 src/api/system/signature.js           |   44 ++++
 src/views/archiveAnnotation/index.vue |  255 +++++++++++++++++++++++
 4 files changed, 604 insertions(+), 0 deletions(-)

diff --git a/src/api/system/annotation.js b/src/api/system/annotation.js
new file mode 100644
index 0000000..deb4584
--- /dev/null
+++ b/src/api/system/annotation.js
@@ -0,0 +1,44 @@
+import request from '@/utils/request'
+
+// 鏌ヨ銆愯濉啓鍔熻兘鍚嶇О銆戝垪琛�
+export function listAnnotation(query) {
+  return request({
+    url: '/system/annotation/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 鏌ヨ銆愯濉啓鍔熻兘鍚嶇О銆戣缁�
+export function getAnnotation(id) {
+  return request({
+    url: '/system/annotation/' + id,
+    method: 'get'
+  })
+}
+
+// 鏂板銆愯濉啓鍔熻兘鍚嶇О銆�
+export function addAnnotation(data) {
+  return request({
+    url: '/system/annotation',
+    method: 'post',
+    data: data
+  })
+}
+
+// 淇敼銆愯濉啓鍔熻兘鍚嶇О銆�
+export function updateAnnotation(data) {
+  return request({
+    url: '/system/annotation',
+    method: 'put',
+    data: data
+  })
+}
+
+// 鍒犻櫎銆愯濉啓鍔熻兘鍚嶇О銆�
+export function delAnnotation(id) {
+  return request({
+    url: '/system/annotation/' + id,
+    method: 'delete'
+  })
+}
diff --git a/src/api/system/signature.js b/src/api/system/signature.js
new file mode 100644
index 0000000..e352565
--- /dev/null
+++ b/src/api/system/signature.js
@@ -0,0 +1,44 @@
+import request from '@/utils/request'
+
+// 鏌ヨ銆愯濉啓鍔熻兘鍚嶇О銆戝垪琛�
+export function listSignature(query) {
+  return request({
+    url: '/system/signature/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 鏌ヨ銆愯濉啓鍔熻兘鍚嶇О銆戣缁�
+export function getSignature(id) {
+  return request({
+    url: '/system/signature/' + id,
+    method: 'get'
+  })
+}
+
+// 鏂板銆愯濉啓鍔熻兘鍚嶇О銆�
+export function addSignature(data) {
+  return request({
+    url: '/system/signature',
+    method: 'post',
+    data: data
+  })
+}
+
+// 淇敼銆愯濉啓鍔熻兘鍚嶇О銆�
+export function updateSignature(data) {
+  return request({
+    url: '/system/signature',
+    method: 'put',
+    data: data
+  })
+}
+
+// 鍒犻櫎銆愯濉啓鍔熻兘鍚嶇О銆�
+export function delSignature(id) {
+  return request({
+    url: '/system/signature/' + id,
+    method: 'delete'
+  })
+}
diff --git a/src/views/archiveAnnotation/index.vue b/src/views/archiveAnnotation/index.vue
new file mode 100644
index 0000000..85e8f75
--- /dev/null
+++ b/src/views/archiveAnnotation/index.vue
@@ -0,0 +1,255 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="鎺掑簭瀛楁" prop="srt">
+        <el-input
+          v-model="queryParams.srt"
+          placeholder="璇疯緭鍏ユ帓搴忓瓧娈�"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item>
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">鎼滅储</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">閲嶇疆</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['system:annotation:add']"
+        >鏂板</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['system:annotation:edit']"
+        >淇敼</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['system:annotation:remove']"
+        >鍒犻櫎</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['system:annotation:export']"
+        >瀵煎嚭</el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="annotationList" @selection-change="handleSelectionChange">
+      <el-table-column type="selection" width="55" align="center" />
+
+      <el-table-column label="娉ㄨВ鍚嶇О" align="center" prop="name" />
+      <el-table-column label="鎺掑簭瀛楁" align="center" prop="srt" />
+      <el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['system:annotation:edit']"
+          >淇敼</el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['system:annotation:remove']"
+          >鍒犻櫎</el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 娣诲姞鎴栦慨鏀广�愯濉啓鍔熻兘鍚嶇О銆戝璇濇 -->
+    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="娉ㄨВ鍚嶇О" prop="name">
+          <el-input v-model="form.name" type="textarea" placeholder="璇疯緭鍏ュ唴瀹�" />
+        </el-form-item>
+        <el-form-item label="鎺掑簭瀛楁" prop="srt">
+          <el-input v-model="form.srt" placeholder="璇疯緭鍏ユ帓搴忓瓧娈�" />
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">纭� 瀹�</el-button>
+        <el-button @click="cancel">鍙� 娑�</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import { listAnnotation, getAnnotation, delAnnotation, addAnnotation, updateAnnotation } from "@/api/system/annotation"
+
+export default {
+  name: "Annotation",
+  data() {
+    return {
+      // 閬僵灞�
+      loading: true,
+      // 閫変腑鏁扮粍
+      ids: [],
+      // 闈炲崟涓鐢�
+      single: true,
+      // 闈炲涓鐢�
+      multiple: true,
+      // 鏄剧ず鎼滅储鏉′欢
+      showSearch: true,
+      // 鎬绘潯鏁�
+      total: 0,
+      // 銆愯濉啓鍔熻兘鍚嶇О銆戣〃鏍兼暟鎹�
+      annotationList: [],
+      // 寮瑰嚭灞傛爣棰�
+      title: "",
+      // 鏄惁鏄剧ず寮瑰嚭灞�
+      open: false,
+      // 鏌ヨ鍙傛暟
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        name: null,
+        srt: null
+      },
+      // 琛ㄥ崟鍙傛暟
+      form: {},
+      // 琛ㄥ崟鏍¢獙
+      rules: {
+      }
+    }
+  },
+  created() {
+    this.getList()
+  },
+  methods: {
+    /** 鏌ヨ銆愯濉啓鍔熻兘鍚嶇О銆戝垪琛� */
+    getList() {
+      this.loading = true
+      alert(90)
+      listAnnotation(this.queryParams).then(response => {
+        console.log(response.rows)
+        alert(23)
+        this.annotationList = response.rows
+
+        this.total = response.total
+        this.loading = false
+      })
+    },
+    // 鍙栨秷鎸夐挳
+    cancel() {
+      this.open = false
+      this.reset()
+    },
+    // 琛ㄥ崟閲嶇疆
+    reset() {
+      this.form = {
+        id: null,
+        name: null,
+        srt: null
+      }
+      this.resetForm("form")
+    },
+    /** 鎼滅储鎸夐挳鎿嶄綔 */
+    handleQuery() {
+      this.queryParams.pageNum = 1
+      this.getList()
+    },
+    /** 閲嶇疆鎸夐挳鎿嶄綔 */
+    resetQuery() {
+      this.resetForm("queryForm")
+      this.handleQuery()
+    },
+    // 澶氶�夋閫変腑鏁版嵁
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id)
+      this.single = selection.length!==1
+      this.multiple = !selection.length
+    },
+    /** 鏂板鎸夐挳鎿嶄綔 */
+    handleAdd() {
+      this.reset()
+      this.open = true
+      this.title = "娣诲姞銆愯濉啓鍔熻兘鍚嶇О銆�"
+    },
+    /** 淇敼鎸夐挳鎿嶄綔 */
+    handleUpdate(row) {
+      this.reset()
+      const id = row.id || this.ids
+      getAnnotation(id).then(response => {
+        this.form = response.data
+        this.open = true
+        this.title = "淇敼銆愯濉啓鍔熻兘鍚嶇О銆�"
+      })
+    },
+    /** 鎻愪氦鎸夐挳 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateAnnotation(this.form).then(response => {
+              this.$modal.msgSuccess("淇敼鎴愬姛")
+              this.open = false
+              this.getList()
+            })
+          } else {
+            addAnnotation(this.form).then(response => {
+              this.$modal.msgSuccess("鏂板鎴愬姛")
+              this.open = false
+              this.getList()
+            })
+          }
+        }
+      })
+    },
+    /** 鍒犻櫎鎸夐挳鎿嶄綔 */
+    handleDelete(row) {
+      const ids = row.id || this.ids
+      this.$modal.confirm('鏄惁纭鍒犻櫎銆愯濉啓鍔熻兘鍚嶇О銆戠紪鍙蜂负"' + ids + '"鐨勬暟鎹」锛�').then(function() {
+        return delAnnotation(ids)
+      }).then(() => {
+        this.getList()
+        this.$modal.msgSuccess("鍒犻櫎鎴愬姛")
+      }).catch(() => {})
+    },
+    /** 瀵煎嚭鎸夐挳鎿嶄綔 */
+    handleExport() {
+      this.download('system/annotation/export', {
+        ...this.queryParams
+      }, `annotation_${new Date().getTime()}.xlsx`)
+    }
+  }
+}
+</script>
diff --git a/src/views/archiveSignature/index.vue b/src/views/archiveSignature/index.vue
new file mode 100644
index 0000000..1c59894
--- /dev/null
+++ b/src/views/archiveSignature/index.vue
@@ -0,0 +1,261 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="绛惧悕鍚嶇О" prop="sigaName">
+        <el-input
+          v-model="queryParams.sigaName"
+          placeholder="璇疯緭鍏ョ鍚嶅悕绉�"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="鎺掑簭瀛楁" prop="sot">
+        <el-input
+          v-model="queryParams.sot"
+          placeholder="璇疯緭鍏ユ帓搴忓瓧娈�"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item>
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">鎼滅储</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">閲嶇疆</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['system:signature:add']"
+        >鏂板</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['system:signature:edit']"
+        >淇敼</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['system:signature:remove']"
+        >鍒犻櫎</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['system:signature:export']"
+        >瀵煎嚭</el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="signatureList" @selection-change="handleSelectionChange">
+      <el-table-column type="selection" width="55" align="center" />
+<!--      <el-table-column label="${comment}" align="center" prop="id" / -->>
+      <el-table-column label="绛惧悕鍚嶇О" align="center" prop="sigaName" />
+      <el-table-column label="鎺掑簭瀛楁" align="center" prop="sot" />
+      <el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['system:signature:edit']"
+          >淇敼</el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['system:signature:remove']"
+          >鍒犻櫎</el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 娣诲姞鎴栦慨鏀广�愯濉啓鍔熻兘鍚嶇О銆戝璇濇 -->
+    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="绛惧悕鍚嶇О" prop="sigaName">
+          <el-input v-model="form.sigaName" placeholder="璇疯緭鍏ョ鍚嶅悕绉�" />
+        </el-form-item>
+        <el-form-item label="鎺掑簭瀛楁" prop="sot">
+          <el-input v-model="form.sot" placeholder="璇疯緭鍏ユ帓搴忓瓧娈�" />
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">纭� 瀹�</el-button>
+        <el-button @click="cancel">鍙� 娑�</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import { listSignature, getSignature, delSignature, addSignature, updateSignature } from "@/api/system/signature"
+
+export default {
+  name: "Signature",
+  data() {
+    return {
+      // 閬僵灞�
+      loading: true,
+      // 閫変腑鏁扮粍
+      ids: [],
+      // 闈炲崟涓鐢�
+      single: true,
+      // 闈炲涓鐢�
+      multiple: true,
+      // 鏄剧ず鎼滅储鏉′欢
+      showSearch: true,
+      // 鎬绘潯鏁�
+      total: 0,
+      // 銆愯濉啓鍔熻兘鍚嶇О銆戣〃鏍兼暟鎹�
+      signatureList: [],
+      // 寮瑰嚭灞傛爣棰�
+      title: "",
+      // 鏄惁鏄剧ず寮瑰嚭灞�
+      open: false,
+      // 鏌ヨ鍙傛暟
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        sigaName: null,
+        sot: null
+      },
+      // 琛ㄥ崟鍙傛暟
+      form: {},
+      // 琛ㄥ崟鏍¢獙
+      rules: {
+      }
+    }
+  },
+  created() {
+    this.getList()
+  },
+  methods: {
+    /** 鏌ヨ銆愯濉啓鍔熻兘鍚嶇О銆戝垪琛� */
+    getList() {
+      this.loading = true
+      listSignature(this.queryParams).then(response => {
+        console.log(response.data)
+
+        this.signatureList = response.data.data
+        this.total = response.data.total
+        this.loading = false
+      })
+    },
+    // 鍙栨秷鎸夐挳
+    cancel() {
+      this.open = false
+      this.reset()
+    },
+    // 琛ㄥ崟閲嶇疆
+    reset() {
+      this.form = {
+        id: null,
+        sigaName: null,
+        sot: null
+      }
+      this.resetForm("form")
+    },
+    /** 鎼滅储鎸夐挳鎿嶄綔 */
+    handleQuery() {
+      this.queryParams.pageNum = 1
+      this.getList()
+    },
+    /** 閲嶇疆鎸夐挳鎿嶄綔 */
+    resetQuery() {
+      this.resetForm("queryForm")
+      this.handleQuery()
+    },
+    // 澶氶�夋閫変腑鏁版嵁
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id)
+      this.single = selection.length!==1
+      this.multiple = !selection.length
+    },
+    /** 鏂板鎸夐挳鎿嶄綔 */
+    handleAdd() {
+      this.reset()
+      this.open = true
+      this.title = "娣诲姞銆愯濉啓鍔熻兘鍚嶇О銆�"
+    },
+    /** 淇敼鎸夐挳鎿嶄綔 */
+    handleUpdate(row) {
+      this.reset()
+      const id = row.id || this.ids
+      getSignature(id).then(response => {
+        this.form = response.data
+        this.open = true
+        this.title = "淇敼銆愯濉啓鍔熻兘鍚嶇О銆�"
+      })
+    },
+    /** 鎻愪氦鎸夐挳 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateSignature(this.form).then(response => {
+              this.$modal.msgSuccess("淇敼鎴愬姛")
+              this.open = false
+              this.getList()
+            })
+          } else {
+            addSignature(this.form).then(response => {
+              this.$modal.msgSuccess("鏂板鎴愬姛")
+              this.open = false
+              this.getList()
+            })
+          }
+        }
+      })
+    },
+    /** 鍒犻櫎鎸夐挳鎿嶄綔 */
+    handleDelete(row) {
+      const ids = row.id || this.ids
+      this.$modal.confirm('鏄惁纭鍒犻櫎銆愯濉啓鍔熻兘鍚嶇О銆戠紪鍙蜂负"' + ids + '"鐨勬暟鎹」锛�').then(function() {
+        return delSignature(ids)
+      }).then(() => {
+        this.getList()
+        this.$modal.msgSuccess("鍒犻櫎鎴愬姛")
+      }).catch(() => {})
+    },
+    /** 瀵煎嚭鎸夐挳鎿嶄綔 */
+    handleExport() {
+      this.download('system/signature/export', {
+        ...this.queryParams
+      }, `signature_${new Date().getTime()}.xlsx`)
+    }
+  }
+}
+</script>

--
Gitblit v1.9.1