Browse Source

[用品领用] 页面、 及编辑回显静态完成

liangyan0105 3 years ago
parent
commit
ebe46b0c83

+ 30 - 26
src/components/jeecg/JEditor.vue

@@ -1,32 +1,29 @@
 <template>
   <div class="tinymce-editor">
-    <editor
-      v-model="myValue"
-      :init="init"
-      :disabled="disabled"
-      @onClick="onClick">
-    </editor>
+    <editor v-model="myValue" :init="init" :disabled="disabled" @onClick="onClick" height="200px"></editor>
     <!-- 显示 -->
-  <!-- <div v-html="myValue" id="myValue"></div> -->
+    <!-- <div v-html="myValue" id="myValue"></div> -->
   </div>
 </template>
 
 <script>
 import tinymce from 'tinymce/tinymce'
 import Editor from '@tinymce/tinymce-vue'
-// import 'tinymce/themes/silver/theme'
-// import 'tinymce/plugins/image'
-// import 'tinymce/plugins/link'
-// import 'tinymce/plugins/media'
 import 'tinymce/plugins/table'
 import 'tinymce/plugins/lists'
 import 'tinymce/plugins/contextmenu'
-// import 'tinymce/plugins/wordcount'
 import 'tinymce/plugins/colorpicker'
 import 'tinymce/plugins/textcolor'
+
+// 重复
+// import 'tinymce/themes/silver/theme'
+// import 'tinymce/plugins/image'
+// import 'tinymce/plugins/link'
+// import 'tinymce/plugins/media'
+// import 'tinymce/plugins/wordcount'
 // import 'tinymce/plugins/fullscreen'
-// 新增
 
+// 新增
 import 'tinymce/themes/silver/theme' // 引用主题文件
 import 'tinymce/icons/default' // 引用图标文件
 import 'tinymce/plugins/link'
@@ -48,7 +45,7 @@ import 'tinymce/plugins/imagetools' // 图片工具
 import 'tinymce/plugins/importcss' // 图片工具
 import 'tinymce/plugins/insertdatetime' // 时间插入
 import 'tinymce/plugins/media' // 媒体插入
-import 'tinymce/plugins/nonbreaking' //
+import 'tinymce/plugins/nonbreaking'
 import 'tinymce/plugins/noneditable' // 不间断空格
 import 'tinymce/plugins/pagebreak' // 分页
 import 'tinymce/plugins/paste' // 粘贴
@@ -58,15 +55,15 @@ import 'tinymce/plugins/quickbars' // 快捷菜单
 import 'tinymce/plugins/save' // 保存
 import 'tinymce/plugins/searchreplace' // 查询替换
 import 'tinymce/plugins/spellchecker' // 拼写检查
-import 'tinymce/plugins/tabfocus' //
+import 'tinymce/plugins/tabfocus'
 import 'tinymce/plugins/template' // 插入模板
-import 'tinymce/plugins/textpattern' //
-import 'tinymce/plugins/toc' //
-import 'tinymce/plugins/visualblocks' //
-import 'tinymce/plugins/visualchars' //
+import 'tinymce/plugins/textpattern'
+import 'tinymce/plugins/toc'
+import 'tinymce/plugins/visualblocks'
+import 'tinymce/plugins/visualchars'
 import 'tinymce/plugins/wordcount' // 数字统计
-
 import 'tinymce/icons/default/icons.min.js'
+
 export default {
     components: {
         Editor
@@ -92,13 +89,14 @@ export default {
         },
         toolbar: {
             type: [String, Array],
-            default: 'undo redo |  formatselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | lists link unlink image media table | removeformat | fullscreen',
+            default:
+        'undo redo |  formatselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | lists link unlink image media table | removeformat | fullscreen',
             branding: false
         }
     },
     data () {
         return {
-        // 初始化配置
+            // 初始化配置
             init: {
                 language_url: '/tinymce/langs/zh_CN.js',
                 language: 'zh_CN',
@@ -131,7 +129,6 @@ export default {
         tinymce.init({})
     },
     methods: {
-
         onClick (e) {
             this.$emit('onClick', e, tinymce)
         },
@@ -142,7 +139,7 @@ export default {
     },
     watch: {
         value (newValue) {
-            this.myValue = (newValue == null ? '' : newValue)
+            this.myValue = newValue == null ? '' : newValue
         },
         myValue (newValue) {
             if (this.triggerChange) {
@@ -153,7 +150,14 @@ export default {
         }
     }
 }
-
 </script>
-<style scoped>
+<style lang="less" scoped>
+.tox-edit-area {
+  background-color: #15616d;
+  height: 500px;
+}
+#tiny-vue_82314621621635824271508_ifr {
+  background-color: #15616d;
+  height: 500px;
+}
 </style>

+ 48 - 48
src/views/administrative-management/asset-management/assetAdd.vue

@@ -142,55 +142,55 @@
 </template>
 <script>
 export default {
-  data() {
-    return {
-      labelCol: {
-        xs: { span: 24 },
-        sm: { span: 5 }
-      },
-      wrapperCol: {
-        xs: { span: 24 },
-        sm: { span: 16 }
-      },
-      visible: false,
-      //表单属性
-      form: {
-        name: '',
-        type: '',
-        code: '',
-        source: '',
-        unitPrice: '',
-        state: '',
-        receiver: ''
-      },
-      //表单校验
-      rules: {
-        name: [{ required: true, message: '请输入名称', trigger: 'blur' }],
-        code: [{ required: true, message: '请输入编码', trigger: 'blur' }]
-      }
-    }
-  },
-  methods: {
-    //打开抽屉
-    showDrawer() {
-      this.visible = true
-    },
-    //保存按钮
-    save() {
-      this.$refs.ruleForm.validate(valid => {
-        if (valid) {
-          //校验成功
-          console.log(this.form)
-        } else {
-          return false
+    data () {
+        return {
+            labelCol: {
+                xs: { span: 24 },
+                sm: { span: 5 }
+            },
+            wrapperCol: {
+                xs: { span: 24 },
+                sm: { span: 16 }
+            },
+            visible: false,
+            // 表单属性
+            form: {
+                name: '',
+                type: '',
+                code: '',
+                source: '',
+                unitPrice: '',
+                state: '',
+                receiver: ''
+            },
+            // 表单校验
+            rules: {
+                name: [{ required: true, message: '请输入名称', trigger: 'blur' }],
+                code: [{ required: true, message: '请输入编码', trigger: 'blur' }]
+            }
         }
-      })
     },
-    //关闭按钮
-    close() {
-      this.$refs.ruleForm.resetFields()
-      this.visible = false
+    methods: {
+    // 打开抽屉
+        showDrawer () {
+            this.visible = true
+        },
+        // 保存按钮
+        save () {
+            this.$refs.ruleForm.validate(valid => {
+                if (valid) {
+                    // 校验成功
+                    console.log(this.form)
+                } else {
+                    return false
+                }
+            })
+        },
+        // 关闭按钮
+        close () {
+            this.$refs.ruleForm.resetFields()
+            this.visible = false
+        }
     }
-  }
 }
-</script>
+</script>

+ 137 - 104
src/views/administrative-management/asset-management/assetManagement.vue

@@ -31,6 +31,7 @@
           </div>
           <!-- 表格区域 -->
           <a-table
+            bordered
             :columns="columns"
             :row-key="record => record.id"
             :data-source="dataPageList"
@@ -40,11 +41,13 @@
           >
             <!-- 领用人 -->
             <span slot="receiverSlot" slot-scope="text, record">
-              <a-tag color="blue">{{record.receiver}}</a-tag>
+              <a-tag color="blue">{{ record.receiver }}</a-tag>
             </span>
             <!-- 状态 -->
             <span slot="stateSlot" slot-scope="text, record">
-              <a-badge v-if="record.state=='0'" status="success" text="正常" />
+              <a-badge v-if="record.state === '0'" status="success" text="正常" />
+              <a-badge v-else-if="record.state === '1'" status="warning" text="维修" />
+              <a-badge v-else status="error" text="报废" />
             </span>
             <!-- 操作 -->
             <span slot="actionSlot" slot-scope="text, record">
@@ -61,7 +64,7 @@
                     <a href="javascript:;" @click="detail(record)">详情</a>
                   </a-menu-item>
                   <a-menu-item>
-                    <a-popconfirm title="确定删除吗?" @confirm="() => delete(record.id)">
+                    <a-popconfirm title="确定删除吗?" @confirm="() => delete record.id">
                       <a>删除</a>
                     </a-popconfirm>
                   </a-menu-item>
@@ -78,112 +81,142 @@
 
 <script>
 import assetAdd from './assetAdd'
+import moment from 'moment'
+import 'moment/locale/zh-cn'
 export default {
-  name: 'assetManagement',
-  components:{
-    assetAdd
-  },
-  data() {
-    return {
-      columns: [
-        {
-          title: '名称',
-          dataIndex: 'name',
-          // sorter: true,
-          width: '20%'
-          // scopedSlots: { customRender: 'name' }
-        },
-        {
-          title: '类别',
-          dataIndex: 'type',
-          // filters: [
-          //   { text: 'Male', value: 'male' },
-          //   { text: 'Female', value: 'female' }
-          // ],
-          width: '20%'
-        },
-        {
-          title: '编号',
-          dataIndex: 'code'
-        },
-        {
-          title: '单价',
-          dataIndex: 'unitPrice'
-        },
-        {
-          title: '领用人',
-          dataIndex: 'receiver',
-          scopedSlots: { customRender: 'receiverSlot' }
+    name: 'AssetManagement',
+    components: {
+        assetAdd
+    },
+    data () {
+        return {
+            columns: [
+                {
+                    title: '名称',
+                    dataIndex: 'name',
+                    align: 'center',
+                    // sorter: true,
+                    width: '20%'
+                    // scopedSlots: { customRender: 'name' }
+                },
+                {
+                    title: '类别',
+                    dataIndex: 'type',
+                    align: 'center',
+                    // filters: [
+                    //   { text: 'Male', value: 'male' },
+                    //   { text: 'Female', value: 'female' }
+                    // ],
+                    width: '20%'
+                },
+                {
+                    title: '编号',
+                    dataIndex: 'code',
+                    align: 'center'
+                },
+
+                {
+                    title: '来源',
+                    dataIndex: 'source',
+                    align: 'center'
+                },
+                {
+                    title: '单价',
+                    dataIndex: 'unitPrice',
+                    align: 'center'
+                },
+                {
+                    title: '领用人',
+                    dataIndex: 'receiver',
+                    align: 'center',
+                    scopedSlots: { customRender: 'receiverSlot' }
+                },
+                {
+                    title: '状态',
+                    dataIndex: 'state',
+                    align: 'center',
+                    scopedSlots: { customRender: 'stateSlot' }
+                },
+                {
+                    title: '操作',
+                    dataIndex: 'action',
+                    align: 'center',
+                    scopedSlots: { customRender: 'actionSlot' }
+                }
+            ],
+            dataPageList: [
+                {
+                    id: '123',
+                    name: '笔记本电脑',
+                    type: '电脑类',
+                    code: 'DN-006',
+                    source: '电子设备',
+                    unitPrice: '4000.00',
+                    receiver: '袁少华',
+                    state: '1'
+                },
+                {
+                    id: '234',
+                    name: '办公桌',
+                    type: '家具用具 ',
+                    code: 'Z-003',
+                    source: '家具用品',
+                    unitPrice: '300.00',
+                    receiver: '俞阳',
+                    state: '0'
+                }
+            ], // 表格数据集合
+            loading: false, // 表格加载
+            pagination: {}, // 分页
+            queryParam: {} // 查询条件参数对象
+        }
+    },
+    created () {},
+    computed: {},
+    mounted () {},
+    methods: {
+    // 新增
+        add () {
+            this.$refs.assetAdd.showDrawer()
         },
-        {
-          title: '状态',
-          dataIndex: 'state',
-          scopedSlots: { customRender: 'stateSlot' }
+        // 编辑
+        edit (obj) {
+            console.log('点击资产管理编辑对象', obj)
+            this.$refs.assetAdd.showDrawer()
+            this.$refs.assetAdd.form = JSON.parse(JSON.stringify(obj))
+            this.$refs.assetAdd.form.state = obj.state
+            if (obj.state == 0) {
+                this.$refs.assetAdd.form.state = '正常'
+            } else if (obj.state == 1) {
+                this.$refs.assetAdd.form.state = '维修'
+            } else {
+                this.$refs.assetAdd.form.state = '报废'
+            }
         },
-        {
-          title: '操作',
-          dataIndex: 'action',
-          scopedSlots: { customRender: 'actionSlot' }
-        }
-      ],
-      dataPageList: [
-        {
-          id: '123',
-          name: '笔记本电脑',
-          type: '电脑类',
-          code: 'DN-006',
-          unitPrice: '4000.00',
-          receiver: '袁少华',
-          state: '0'
+
+        handleTableChange (pagination, filters, sorter) {
+            // console.log(pagination)
+            // const pager = { ...this.pagination }
+            // pager.current = pagination.current
+            // this.pagination = pager
+            // this.fetch({
+            //   results: pagination.pageSize,
+            //   page: pagination.current,
+            //   sortField: sorter.field,
+            //   sortOrder: sorter.order,
+            //   ...filters
+            // })
         },
-        {
-          id: '234',
-          name: '办公桌',
-          type: '家具用具 ',
-          code: 'Z-003',
-          unitPrice: '300.00',
-          receiver: '俞阳',
-          state: '0'
+
+        // 详情
+        detail () {},
+        // 删除
+        delete () {},
+        // 查询
+        searchQuery () {
+            this.loading = true
         }
-      ], //表格数据集合
-      loading: false, //表格加载
-      pagination: {}, //分页
-      queryParam: {} //查询条件参数对象
-    }
-  },
-  created() {},
-  computed: {},
-  mounted() {},
-  methods: {
-    handleTableChange(pagination, filters, sorter) {
-      // console.log(pagination)
-      // const pager = { ...this.pagination }
-      // pager.current = pagination.current
-      // this.pagination = pager
-      // this.fetch({
-      //   results: pagination.pageSize,
-      //   page: pagination.current,
-      //   sortField: sorter.field,
-      //   sortOrder: sorter.order,
-      //   ...filters
-      // })
-    },
-    //新增
-    add() {
-      this.$refs.assetAdd.showDrawer();
-    },
-    //编辑
-    edit() {},
-    //详情
-    detail() {},
-    //删除
-    delete() {},
-    //查询
-    searchQuery() {
-      this.loading = true
     }
-  }
 }
 </script>
-<style lang="less" scoped>
-</style>
+<style lang="less" scoped></style>

+ 221 - 0
src/views/administrative-management/supplies-management/sup-receive/supRecAdd.vue

@@ -0,0 +1,221 @@
+<template>
+  <div>
+    <a-drawer
+      :title="title"
+      placement="right"
+      :closable="false"
+      :visible="visible"
+      width="600"
+      :maskClosable="false"
+    >
+      <a-form-model ref="ruleForm" :model="form" :rules="rules">
+        <a-row :gutter="24">
+
+          <a-col :span="24">
+            <a-form-model-item
+              :label-col="labelCol"
+              :wrapper-col="wrapperCol"
+              label="编码"
+              prop="code"
+              style="width:100%"
+            >
+              <a-input v-model="form.code" placeholder="请输入用品编码" />
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item
+              :label-col="labelCol"
+              :wrapper-col="wrapperCol"
+              label="用品名称"
+              prop="supName"
+              style="width:100%"
+            >
+              <a-select v-model="form.supName" show-search placeholder="请选择名称" style="width: 100%" >
+                <a-select-option value="长尾文件夹">长尾文件夹</a-select-option>
+                <a-select-option value="A4打印纸">A4打印纸</a-select-option>
+              </a-select>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item
+              :label-col="labelCol"
+              :wrapper-col="wrapperCol"
+              label="规格"
+              prop="size"
+              style="width:100%"
+            >
+              <a-input v-model="form.size" placeholder="请输入规格" />
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item
+              :label-col="labelCol"
+              :wrapper-col="wrapperCol"
+              label="库存数量"
+              prop="inventoryNum"
+              style="width:100%"
+            >
+              <a-input-number
+                placeholder="请输入库存数量"
+                :default-value="0"
+                style="width: 100%"
+                v-model="form.inventoryNum"
+                :min="0"
+              />
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item
+              :label-col="labelCol"
+              :wrapper-col="wrapperCol"
+              label="领用数量"
+              prop="receiveNum"
+              style="width:100%">
+              <a-input v-model="form.receiveNum" placeholder="请输入领用数量" />
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item
+              :label-col="labelCol"
+              :wrapper-col="wrapperCol"
+              label="申请人"
+              prop="proposer"
+              style="width:100%">
+              <a-input-number v-model="form.proposer" placeholder="请输入申请人" style="width: 100%" />
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item
+              :label-col="labelCol"
+              :wrapper-col="wrapperCol"
+              label="所属部门"
+              prop="department"
+              style="width:100%">
+              <a-select v-model="form.department" show-search placeholder="所属选择部门" style="width: 100%">
+                <a-select-option value="行政部">行政部</a-select-option>
+                <a-select-option value="销售部">销售部</a-select-option>
+                <a-select-option value="实施部">实施部</a-select-option>
+                <a-select-option value="开发部">开发部</a-select-option>
+              </a-select>
+            </a-form-model-item>
+          </a-col>
+
+          <!-- 日期 -->
+          <a-col :span="24">
+            <a-form-model-item
+              :label-col="labelCol"
+              :wrapper-col="wrapperCol"
+              label="申请日期"
+              allowClear
+              showTime
+              prop="applicationDate"
+              type="date"
+              style="width:100%">
+
+              <a-date-picker
+                format="YYYY/MM/DD"
+                v-model="form.applicationDate"
+                placeholder="请选择申请日期"
+                style="width: 100%"
+                @change="onChange"
+              >
+              </a-date-picker></a-form-model-item>
+          </a-col>
+        </a-row>
+      </a-form-model>
+      <!-- 底部按钮 -->
+      <div
+        :style="{
+          position: 'absolute',
+          right: 0,
+          bottom: 0,
+          width: '100%',
+          borderTop: '1px solid #e9e9e9',
+          padding: '10px 16px',
+          background: '#fff',
+          textAlign: 'right',
+          zIndex: 1
+        }"
+      >
+        <a-button :style="{ marginRight: '8px' }" @click="close">关闭</a-button>
+        <a-button type="primary" @click="save">保存</a-button>
+      </div>
+    </a-drawer>
+  </div>
+</template>
+<script>
+import moment from 'moment'
+import 'moment/locale/zh-cn'
+export default {
+    data () {
+        return {
+            labelCol: {
+                xs: { span: 24 },
+                sm: { span: 5 }
+            },
+            wrapperCol: {
+                xs: { span: 24 },
+                sm: { span: 16 }
+            },
+            visible: false,
+            // 表单属性
+            form: {
+                id: '',
+                code: '',
+                supName: [],
+                size: '',
+                inventoryNum: '',
+                receiveNum: '',
+                proposer: '',
+                department: [],
+                applicationDate: null
+                // 默认值必须是 moment 对象
+            },
+            // 表单校验
+            rules: {
+                supName: [{ required: true, message: '请用品名称', trigger: 'blur' }],
+                size: [{ required: true, message: '请输入规格', trigger: 'blur' }],
+                receiveNum: [{ required: true, message: '请输入领用数量', trigger: 'blur' }],
+                proposer: [{ required: true, message: '请输入申请人', trigger: 'blur' }]
+            },
+            title: ''
+        }
+    },
+    methods: {
+    // 打开抽屉
+        showDrawer () {
+            this.visible = true
+        },
+        getInfo () {
+
+        },
+        // 拿到选择的日期
+        onChange (value, dateString) {
+            console.log('Selected Time: ', value)
+            console.log('Formatted Selected Time: ', dateString)
+        },
+        // 保存按钮
+        save () {
+            this.$refs.ruleForm.validate(valid => {
+                if (valid) {
+                    // 校验成功
+                    console.log(this.form)
+                } else {
+                    return false
+                }
+            })
+        },
+        // 关闭按钮
+        close () {
+            this.$refs.ruleForm.resetFields() // 清空
+            this.visible = false
+        }
+    }
+}
+</script>

+ 198 - 0
src/views/administrative-management/supplies-management/sup-receive/supReceive.vue

@@ -0,0 +1,198 @@
+<template>
+  <div>
+    <!-- 查询区域 -->
+    <a-row :gutter="24">
+      <a-col :span="24" style="padding:5px">
+        <a-card>
+          <div class="table-page-search-wrapper">
+            <a-form layout="inline" @keyup.enter.native="searchQuery">
+              <a-row :gutter="24">
+                <a-col :span="6">
+                  <a-form-item label="名称">
+                    <a-input placeholder="请输入名称查询" v-model="queryParam.name"></a-input>
+                  </a-form-item>
+                </a-col>
+                <a-col :span="18">
+                  <a-button type="primary" @click="searchQuery">查询</a-button>
+                </a-col>
+              </a-row>
+            </a-form>
+          </div>
+        </a-card>
+      </a-col>
+    </a-row>
+    <!-- 表格 -->
+    <a-row :gutter="24">
+      <a-col :span="24" style="padding:5px">
+        <a-card>
+          <!-- 按钮 -->
+          <div class="table-operator" style="border-top: 5px">
+            <a-button @click="add" type="primary">新增</a-button>
+          </div>
+          <!-- 表格 -->
+          <a-table
+            bordered
+            :columns="columns"
+            :row-key="record => record.id"
+            :data-source="receiveList"
+            :pagination="pagination"
+            :loading="loading"
+            @change="handleTableChange"
+          >
+            <!-- 操作 -->
+            <span slot="actionSlot" slot-scope="text, record">
+              <a @click="edit(record)">编辑</a>
+              <a-divider type="vertical" />
+              <!-- 更多 -->
+              <a-dropdown>
+                <a class="ant-dropdown-link">
+                  更多
+                  <a-icon type="down" />
+                </a>
+                <a-menu slot="overlay">
+                  <a-menu-item>
+                    <a href="javascript:;" @click="detail(record)">详情</a>
+                  </a-menu-item>
+                  <a-menu-item>
+                    <a-popconfirm title="确定删除吗?" @confirm="() => delete record.id">
+                      <a>删除</a>
+                    </a-popconfirm>
+                  </a-menu-item>
+                </a-menu>
+              </a-dropdown>
+            </span>
+          </a-table>
+        </a-card>
+      </a-col>
+    </a-row>
+    <supRecAdd ref="supRecAdd"></supRecAdd>
+  </div>
+</template>
+
+<script>
+import moment from 'moment'
+import 'moment/locale/zh-cn'
+import supRecAdd from './supRecAdd.vue'
+export default {
+    components: {
+        supRecAdd
+    },
+    data () {
+        return {
+            columns: [
+                {
+                    title: '编码',
+                    dataIndex: 'code',
+                    align: 'center',
+                    // filters: [
+                    //   { text: 'Male', value: 'male' },
+                    //   { text: 'Female', value: 'female' }
+                    // ],
+                    width: '6%'
+                },
+                {
+                    title: '用品名称',
+                    dataIndex: 'supName',
+                    align: 'center',
+                    // sorter: true,
+                    width: '20%'
+                    // scopedSlots: { customRender: 'name' }
+                },
+
+                {
+                    title: '规格',
+                    dataIndex: 'size',
+                    align: 'center'
+                },
+                {
+                    title: '库存数量',
+                    dataIndex: 'inventoryNum',
+                    align: 'center'
+                },
+                {
+                    title: '领用数量',
+                    dataIndex: 'receiveNum',
+                    align: 'center'
+                },
+                {
+                    title: '申请人',
+                    dataIndex: 'proposer',
+                    align: 'center'
+                },
+                {
+                    title: '所属部门',
+                    dataIndex: 'department',
+                    align: 'center'
+                },
+                {
+                    title: '申请日期',
+                    dataIndex: 'applicationDate',
+                    align: 'center'
+                },
+                {
+                    title: '操作',
+                    dataIndex: 'action',
+                    align: 'center',
+                    scopedSlots: { customRender: 'actionSlot' }
+                }
+            ],
+            receiveList: [
+                {
+                    id: '1',
+                    code: '19898',
+                    supName: '长尾文件夹',
+                    size: '中号',
+                    inventoryNum: '109',
+                    receiveNum: '12',
+                    proposer: 'admin',
+                    department: '行政部',
+                    applicationDate: '2021/10/11'
+                },
+                {
+                    id: '2',
+                    code: '2355',
+                    supName: 'A4打印纸',
+                    size: '小号',
+                    inventoryNum: '89',
+                    receiveNum: '22',
+                    proposer: 'fenghf',
+                    department: '项目部',
+                    applicationDate: '2021/10/13'
+                }
+            ], // 表格数据集合
+            loading: false, // 表格加载
+            pagination: {}, // 分页
+            queryParam: {} // 查询条件参数对象
+        }
+    },
+    created () {},
+    computed: {},
+    mounted () {},
+    methods: {
+        handleTableChange (pagination, filters, sorter) {},
+        // 新增
+        add () {
+            this.$refs.supRecAdd.showDrawer()
+            this.$refs.supRecAdd.title = '新增'
+            console.log('点击了用品领用 新增')
+        },
+        // 编辑(回显)
+        edit (obj) {
+            console.log('该ID点击了编辑', obj)
+            this.$refs.supRecAdd.showDrawer()
+            this.$refs.supRecAdd.title = '编辑'
+            this.$refs.supRecAdd.form = JSON.parse(JSON.stringify(obj))
+            this.$refs.supRecAdd.form.applicationDate = moment(obj.applicationDate, 'YYYY/MM/DD')
+        },
+        // 详情
+        detail () {},
+        // 删除
+        delete () {},
+        // 查询
+        searchQuery () {
+            this.loading = true
+        }
+    }
+}
+</script>
+<style lang="less" scoped></style>

+ 50 - 48
src/views/administrative-management/supplies-management/supplies-list/suppliesAdd.vue

@@ -10,6 +10,7 @@
     >
       <a-form-model ref="ruleForm" :model="form" :rules="rules">
         <a-row :gutter="24">
+          <!-- 名称 -->
           <a-col :span="24">
             <a-form-model-item
               :label-col="labelCol"
@@ -21,6 +22,7 @@
               <a-input v-model="form.name" placeholder="请输入名称" />
             </a-form-model-item>
           </a-col>
+          <!-- 类别 -->
           <a-col :span="24">
             <a-form-model-item
               :label-col="labelCol"
@@ -70,11 +72,11 @@
               :label-col="labelCol"
               :wrapper-col="wrapperCol"
               label="库存数量"
-              style="width:100%"
-            >
+              style="width:100%">
               <a-input-number
                 placeholder="请输入库存数量"
                 :default-value="0"
+                style="width: 100%"
                 v-model="form.inventoryQuantity"
                 :min="0"
               />
@@ -104,53 +106,53 @@
 </template>
 <script>
 export default {
-  data() {
-    return {
-      labelCol: {
-        xs: { span: 24 },
-        sm: { span: 5 }
-      },
-      wrapperCol: {
-        xs: { span: 24 },
-        sm: { span: 16 }
-      },
-      visible: false,
-      //表单属性
-      form: {
-        name: '',
-        type: '',
-        code: '',
-        specifications: '',
-        inventoryQuantity: ''
-      },
-      //表单校验
-      rules: {
-        name: [{ required: true, message: '请输入名称', trigger: 'blur' }],
-        code: [{ required: true, message: '请输入编码', trigger: 'blur' }]
-      }
-    }
-  },
-  methods: {
-    //打开抽屉
-    showDrawer() {
-      this.visible = true
-    },
-    //保存按钮
-    save() {
-      this.$refs.ruleForm.validate(valid => {
-        if (valid) {
-          //校验成功
-          console.log(this.form)
-        } else {
-          return false
+    data () {
+        return {
+            labelCol: {
+                xs: { span: 24 },
+                sm: { span: 5 }
+            },
+            wrapperCol: {
+                xs: { span: 24 },
+                sm: { span: 16 }
+            },
+            visible: false,
+            // 表单属性
+            form: {
+                name: '',
+                type: '',
+                code: '',
+                specifications: '',
+                inventoryQuantity: ''
+            },
+            // 表单校验
+            rules: {
+                name: [{ required: true, message: '请输入名称', trigger: 'blur' }],
+                code: [{ required: true, message: '请输入编码', trigger: 'blur' }]
+            }
         }
-      })
     },
-    //关闭按钮
-    close() {
-      this.$refs.ruleForm.resetFields()
-      this.visible = false
+    methods: {
+    // 打开抽屉
+        showDrawer () {
+            this.visible = true
+        },
+        // 保存按钮
+        save () {
+            this.$refs.ruleForm.validate(valid => {
+                if (valid) {
+                    // 校验成功
+                    console.log(this.form)
+                } else {
+                    return false
+                }
+            })
+        },
+        // 关闭按钮
+        close () {
+            this.$refs.ruleForm.resetFields()
+            this.visible = false
+        }
     }
-  }
 }
-</script>
+</script>

+ 90 - 79
src/views/administrative-management/supplies-management/supplies-list/suppliesList.vue

@@ -31,6 +31,7 @@
           </div>
           <!-- 表格区域 -->
           <a-table
+            bordered
             :columns="columns"
             :row-key="record => record.id"
             :data-source="dataPageList"
@@ -71,90 +72,100 @@
 <script>
 import suppliesAdd from './suppliesAdd'
 export default {
-  components:{
-    suppliesAdd
-  },
-  data() {
-    return {
-      columns: [
-        {
-          title: '名称',
-          dataIndex: 'name',
-          // sorter: true,
-          width: '20%'
-          // scopedSlots: { customRender: 'name' }
-        },
-        {
-          title: '类别',
-          dataIndex: 'type',
-          // filters: [
-          //   { text: 'Male', value: 'male' },
-          //   { text: 'Female', value: 'female' }
-          // ],
-          width: '20%'
-        },
-        {
-          title: '编号',
-          dataIndex: 'code'
+    components: {
+        suppliesAdd
+    },
+    data () {
+        return {
+            columns: [
+                {
+                    title: '名称',
+                    dataIndex: 'name',
+                    align: 'center',
+                    // sorter: true,
+                    width: '20%'
+                    // scopedSlots: { customRender: 'name' }
+                },
+                {
+                    title: '类别',
+                    dataIndex: 'type',
+                    align: 'center',
+                    // filters: [
+                    //   { text: 'Male', value: 'male' },
+                    //   { text: 'Female', value: 'female' }
+                    // ],
+                    width: '20%'
+                },
+                {
+                    title: '编号',
+                    dataIndex: 'code',
+                    align: 'center'
+                },
+                {
+                    title: '规格',
+                    dataIndex: 'specifications',
+                    align: 'center'
+                },
+                {
+                    title: '库存数量',
+                    dataIndex: 'inventoryQuantity',
+                    align: 'center'
+                },
+                {
+                    title: '操作',
+                    dataIndex: 'action',
+                    align: 'center',
+                    scopedSlots: { customRender: 'actionSlot' }
+                }
+            ],
+            dataPageList: [
+                {
+                    id: '123',
+                    name: '长尾文件夹',
+                    type: '桌面办公文具',
+                    code: '1002',
+                    specifications: '中号',
+                    inventoryQuantity: '98'
+                },
+                {
+                    id: '234',
+                    name: 'A4打印纸',
+                    type: '纸制品',
+                    code: '1002',
+                    specifications: '幸运鸟',
+                    inventoryQuantity: '15'
+                }
+            ], // 表格数据集合
+            loading: false, // 表格加载
+            pagination: {}, // 分页
+            queryParam: {} // 查询条件参数对象
+        }
+    },
+    created () {},
+    computed: {},
+    mounted () {},
+    methods: {
+        handleTableChange (pagination, filters, sorter) {
         },
-        {
-          title: '规格',
-          dataIndex: 'specifications'
+        // 新增
+        add () {
+            this.$refs.suppliesAdd.showDrawer()
         },
-        {
-          title: '库存数量',
-          dataIndex: 'inventoryQuantity'
+        // 编辑
+        edit (obj) {
+            console.log('该ID点击了编辑', obj)
+            this.$refs.suppliesAdd.showDrawer()
+            this.$refs.suppliesAdd.form = obj
         },
-        {
-          title: '操作',
-          dataIndex: 'action',
-          scopedSlots: { customRender: 'actionSlot' }
+        // 详情
+        detail () {},
+        // 删除
+        delete () {},
+        // 查询
+        searchQuery () {
+            this.loading = true
         }
-      ],
-      dataPageList: [
-        {
-          id: '123',
-          name: '长尾文件夹',
-          type: '桌面办公文具',
-          code: '1002',
-          specifications: '中号',
-          inventoryQuantity: '98',
-        },
-        {
-          id: '234',
-          name: 'A4打印纸',
-          type: '纸制品',
-          code: '1002',
-          specifications: '幸运鸟',
-          inventoryQuantity: '15',
-        },
-      ], //表格数据集合
-      loading: false, //表格加载
-      pagination: {}, //分页
-      queryParam: {} //查询条件参数对象
-    }
-  },
-  created() {},
-  computed: {},
-  mounted() {},
-  methods: {
-    handleTableChange(pagination, filters, sorter) {
-    },
-    //新增
-    add() {
-      this.$refs.suppliesAdd.showDrawer();
-    },
-    //编辑
-    edit() {},
-    //详情
-    detail() {},
-    //删除
-    delete() {},
-    //查询
-    searchQuery() {
-      this.loading = true
     }
-  }
 }
 </script>
 <style lang="less" scoped>

+ 3 - 2
src/views/oa/enter-ann/add/addAnnModal.vue

@@ -1,6 +1,6 @@
 <template>
   <a-modal
-    title="新增企业公告"
+    :title="title"
     v-model="addModalVisible"
     :confirmLoading="confirmLoading"
     @ok="handleOk"
@@ -91,7 +91,8 @@ export default {
             confirmLoading: false,
             addModalVisible: false,
             smallText: '', // 弹框内 富文本的内容
-            annInfo: {} // 表单数据(回显)
+            annInfo: {}, // 表单数据(回显)
+            title: ''
         }
     },
     props: {

+ 3 - 2
src/views/oa/enterpriseAnnouncement.vue

@@ -83,11 +83,10 @@
 </template>
 
 <script>
-// import { JeecgListMixin } from '@/mixins/JeecgListMixin'
 import AddAnnModal from '@views/oa/enter-ann/add/addAnnModal.vue'
 export default {
     name: 'EnterpriseAnnouncement', // 企业公告
-    // mixins: [JeecgListMixin],
+
     components: {
         AddAnnModal
     },
@@ -187,11 +186,13 @@ export default {
             console.log('点击了大页面的新增')
             // 拿到子组件的弹框 属性
             this.$refs.AddAnnModal.addModalVisible = true
+            this.$refs.AddAnnModal.title = '新增企业公告'
         },
         // 编辑
         editAnn (e) {
             console.log('编辑,该公告:', e)
             this.$refs.AddAnnModal.addModalVisible = true
+            this.$refs.AddAnnModal.title = '编辑企业公告'
             if (e.id) {
                 console.log('该项id', e.id)
                 // 发送根据 id 查询公告请求

+ 4 - 2
src/views/oa/my-links/add/addLinksModal.vue

@@ -1,6 +1,6 @@
 <template>
   <a-modal
-    title="新增友情链接"
+    :title="title"
     v-model="addLinksModVis"
     :confirmLoading="confirmLoading"
     @ok="handleOk"
@@ -71,7 +71,9 @@ export default {
             addLinkform: this.$form.createForm(this),
             confirmLoading: false,
             addLinksModVis: false,
-            memo: '' // 公司简介
+            memo: '', // 公司简介
+            title: '',
+            formData: {}
         }
     },
     created () {},

+ 12 - 12
src/views/oa/my-plan/add/savePlan.vue

@@ -1,5 +1,5 @@
 <template>
-  <a-modal v-model="savePlanModalVisible" title="新增日程计划" @ok="handleOk" @cancel="handleCancel" width="86%">
+  <a-modal v-model="savePlanModalVisible" :title="title" @ok="handleOk" @cancel="handleCancel" width="86%">
     <a-divider orientation="left" dashed class="divider">基本信息</a-divider>
 
     <a-form :form="addForm" :label-col="{ span: 4 }" :wrapper-col="{ span: 14 }">
@@ -150,17 +150,19 @@
 </template>
 
 <script>
-// import { mapGetters } from 'vuex'
-// import { defineComponent, ref } from 'vue'
+
 import moment from 'moment'
 import 'moment/locale/zh-cn'
+import JEditor from '../../../../components/jeecg/JEditor.vue'
+import { scheduleAdd, scheduleUpdate } from '@api/oa/cd-schedule'
+// import { mapGetters } from 'vuex'
+// import { defineComponent, ref } from 'vue'
 // import api from '@/api'
 // import { getAction, deleteAction, putAction, postAction } from '@/api/manage'
-import { scheduleAdd, scheduleUpdate } from '@api/oa/cd-schedule'
 // import { extend } from 'dayjs'
 // import { defineComponent, ref } from 'vue'
 // import JEditor from '@views/jeecg/JEditor.vue'
-import JEditor from '../../../../components/jeecg/JEditor.vue'
+
 export default {
     name: 'SavePlan',
     components: {
@@ -175,7 +177,8 @@ export default {
             formData: {}, // 表单数据(回显)
             timeList: [], // 开始/结束时间集合
             isDate: false, // 默认无时分秒
-            smallText: '' // 富文本内容
+            smallText: '', // 富文本内容
+            title: ''
         }
     },
     props: {
@@ -244,18 +247,15 @@ export default {
         },
 
         // 回显表单的赋值
-        getFormInfo () {
-            console.log('点击日程的ID:', this.formData.id)
+        getFormInfo (e) {
+            console.log('点击日程的ID:', this.formData.id) // 2
             this.$nextTick(() => {
                 this.addForm.setFieldsValue({
                     title: this.formData.title,
                     type: this.formData.type, // 日程类型
                     degreeOfUrgency: this.formData.degreeOfUrgency, // 紧急程度
                     backgroundColor: this.formData.backgroundColor,
-                    continue: [
-                        moment(this.formData.startTime, 'YYYY/MM/DD HH:mm'),
-                        moment(this.formData.endTime, 'YYYY/MM/DD HH:mm')
-                    ]
+                    continue: [moment(this.formData.startTime, 'YYYY/MM/DD HH:mm'), moment(this.formData.endTime, 'YYYY/MM/DD HH:mm')]
                 })
                 this.$refs.JEditor.myValue = this.formData.memo
             })

+ 66 - 47
src/views/oa/my-plan/calTable.vue

@@ -36,7 +36,7 @@
       </a-form>
     </div>
 
-    <!-- 新增 导入 到处 -->
+    <!-- 新增 导入 导出 -->
     <div class="table-operator">
       <a-button @click="addPlan" type="primary">新增</a-button>
       <a-button type="primary" @click="myPlanExportXls('我的日程计划')">导出</a-button>
@@ -57,7 +57,8 @@
       >
         <a-button type="primary">导入</a-button>
       </a-upload>
-      <!-- v-if="selectedRowKeys.length > 0" -->
+
+      <!--  v-if="selectedRowKeys.length > 0" -->
       <a-dropdown>
         <a-menu slot="overlay">
           <a-menu-item key="1" @click="batchDel">
@@ -72,43 +73,41 @@
       </a-dropdown>
     </div>
 
-    <!-- table区域-begin -->
-    <div>
-      <a-alert type="info" showIcon style="margin-bottom: 16px;">
-        <template slot="message">
-          <span>已选择</span>
-          <!-- {{ selectedRowKeys.length }} -->
-          <a style="font-weight: 600;padding: 0 4px;">3</a>
-          <span>项</span>
-          <!--  v-if="selectedRowKeys.length > 0" -->
-          <template>
-            <a-divider type="vertical" />
-            <a @click="onClearSelected">清空</a>
-          </template>
+    <!-- table 开始-->
+    <a-alert type="info" showIcon style="margin-bottom: 16px;">
+      <template slot="message">
+        <span>已选择</span>
+        <!-- {{ selectedRowKeys.length }} -->
+        <a style="font-weight: 600;padding: 0 4px;">0</a>
+        <span>项</span>
+        <!--  v-if="selectedRowKeys.length>0" -->
+        <template>
+          <a-divider type="vertical" />
+          <a @click="onClearSelected">清空</a>
         </template>
-      </a-alert>
-      <!-- table   :loading="loading" -->
-      <a-row>
-        <a-table
-          bordered
-          :columns="columns"
-          :dataSource="planDataList"
-          :pagination="pagination"
-          :row-key="record => record.id"
-          :rowSelection="rowSelection"
-          @change="handleTableChange"
-        >
-          <!-- 操作 -->
-          <span slot="operationSlot" slot-scope="text, record">
-            <a href="javascript:void(0);" @click="editPlan(record)"> 编辑 </a>
-            <a-divider type="vertical" />
-            <a-popconfirm title="确定删除吗?" ok-text="是" cancel-text="否">
-              <a href="javascript:void(0);" @click="delPlan(record.id)" class="delRed"> 删除 </a>
-            </a-popconfirm>
-          </span>
-        </a-table>
-      </a-row>
-    </div>
+      </template>
+    </a-alert>
+
+    <!-- 使用 rowKey 来指定数据的唯一标识 id -->
+    <a-table
+      bordered
+      :columns="columns"
+      :dataSource="planList"
+      :pagination="pagination"
+      :row-key="record => record.id"
+      :rowSelection="rowSelection"
+      @change="handleTableChange"
+    >
+      <!-- 操作 -->
+      <span slot="operationSlot" slot-scope="text, record">
+        <a href="javascript:void(0);" @click="editPlan(record)"> 编辑 </a>
+        <a-divider type="vertical" />
+        <a-popconfirm title="确定删除吗?" ok-text="是" cancel-text="否">
+          <a href="javascript:void(0);" @click="delPlan(record.id)" class="delRed"> 删除 </a>
+        </a-popconfirm>
+      </span>
+    </a-table>
+    <!-- table 结束-->
 
     <!-- 新增日程弹框  :fatherMethod="search"-->
     <save-plan ref="savePlan"></save-plan>
@@ -116,6 +115,8 @@
 </template>
 
 <script>
+// import moment from 'moment'
+import 'moment/locale/zh-cn'
 import JEllipsis from '@/components/jeecg/JEllipsis'
 import SavePlan from '@views/oa/my-plan/add/savePlan' // 子组件
 
@@ -126,7 +127,8 @@ export default {
         return {
             tokenHeader: {},
             queryParam: {}, // 查询条件对象
-            pagination: {}, // 分页
+            pagination: {}, // 分页 // 富文本内容
+            // planObj: {}, // 表单数据(回显)
             // 表头
             columns: [
                 {
@@ -162,7 +164,7 @@ export default {
                     width: '20%'
                 }
             ],
-            planDataList: [
+            planList: [
                 {
                     id: '1',
                     title: '11月19日的KPI考核(2)',
@@ -194,12 +196,15 @@ export default {
         }
     },
     computed: {
-    // 选中项
+    // 选择功能的配置
         rowSelection () {
             return {
+                // 选中项发生变化时的回调
                 onChange: (selectedRowKeys, selectedRows) => {
-                    console.log(`selectedRowKeys: ${selectedRowKeys}`, 'selectedRows: ', selectedRows)
+                    console.log('勾选项的id:', selectedRowKeys)
+                    console.log('勾选项对象数组:', selectedRows)
                 },
+                // 选择框的默认属性配置
                 getCheckboxProps: record => ({
                     props: {
                         disabled: record.title === 'Disabled User',
@@ -215,7 +220,25 @@ export default {
         addPlan () {
             console.log('点击了新增日程')
             this.$refs.savePlan.savePlanModalVisible = true
+            this.$refs.savePlan.title = '新增日程计划'
         },
+        // 编辑 (操作)
+        editPlan (obj) {
+            /* ------------------------------
+                打开弹框、发送根据id查询、
+                数据赋值到对象集合中、
+                回显到表单、调用回显的方法,
+                提示修改成功、刷新列表
+              ------------------------------- */
+            console.log('点击对象为:', obj)
+            this.$refs.savePlan.savePlanModalVisible = true
+            this.$refs.savePlan.title = '编辑日程计划'
+            this.$refs.savePlan.formData = obj
+            this.$refs.savePlan.getFormInfo()
+        },
+        // 操作 删除
+        delPlan () {},
+        // ------------------------------------------
         // 查询按钮
         searchQuery () {
             // this.loading = true
@@ -234,11 +257,7 @@ export default {
         // 批量删除
         batchDel () {},
         // 分页、排序、筛选变化时触发
-        handleTableChange (pagination, filters, sorter) {},
-        // 操作 编辑
-        editPlan () {},
-        // 操作 删除
-        delPlan () {}
+        handleTableChange (pagination, filters, sorter) {}
     }
 }
 </script>

+ 13 - 13
src/views/oa/my-plan/schedulePlan.vue

@@ -3,7 +3,6 @@
     <a-card title="我的计划" style="width: 100%">
       <p>
         <FullCalendar :options="calendarOptions" class="eventDeal-wrap" />
-        <!-- 父组件通过 savePlan 拿子组件的 属性 -->
         <save-plan ref="savePlan" :fatherMethod="search" :fatherData="timeList"></save-plan>
       </p>
     </a-card>
@@ -11,9 +10,7 @@
 </template>
 
 <script>
-// import { mapGetters } from 'vuex'
-// import { getAction } from '@/api/manage'
-// import '@fullcalendar/core/main.css'
+
 import FullCalendar from '@fullcalendar/vue'
 import dayGridPlugin from '@fullcalendar/daygrid'
 import interactionPlugin from '@fullcalendar/interaction'
@@ -21,13 +18,16 @@ import timeGridPlugin from '@fullcalendar/timegrid'
 import '@fullcalendar/daygrid/main.css'
 import SavePlan from './add/savePlan' // 子组件
 import { scheduleGetListByTime, scheduleQueryById } from '@api/oa/cd-schedule'
+// import { mapGetters } from 'vuex'
+// import { getAction } from '@/api/manage'
+// import '@fullcalendar/core/main.css'
 // import moment from 'moment'
 // import 'moment/locale/zh-cn'
 export default {
     name: 'SchedulePlan',
     components: {
         FullCalendar,
-        SavePlan // 新增日程表单组件
+        SavePlan //  弹框 日程表单
     },
     data () {
         return {
@@ -47,7 +47,7 @@ export default {
                         borderColor: 'none'
                     }
                 ],
-                // 引入插件
+                // 引入插件
                 plugins: [dayGridPlugin, timeGridPlugin, interactionPlugin],
                 // 日历头部按钮位置
                 headerToolbar: {
@@ -131,7 +131,7 @@ export default {
         handleEventClick (e) {
             // 拿 子组件弹框属性
             this.$refs.savePlan.savePlanModalVisible = true
-            console.log('点击项ID', e.event.id)
+            console.log('点击项ID', e.event.id)
             if (e.event.id) {
                 // 根据id查询日程(注意接口文档传参格式要求)
                 this.$nextTick(() => {
@@ -148,15 +148,12 @@ export default {
                 })
             }
         },
-        prev () {
-            this.calendarApi.prev()
-            console.log(this.calendarApi.prev)
-        },
+
         // 查询日程
         search () {
             scheduleGetListByTime(null).then(res => {
                 if (res.success) {
-                    console.log('查询到的总日程结果', res)
+                    console.log('查询日程总', res)
                     let list = res.result // 查询结果
                     var eventList = [] // 日程事件集合
                     // 循环日程
@@ -206,7 +203,10 @@ export default {
                 eventsArr.splice(e.message, 1, val)
             }
         },
-
+        prev () {
+            this.calendarApi.prev()
+            console.log(this.calendarApi.prev)
+        },
         // 日程删除
         deleteEvent (val) {
             let eventsArr = this.calendarOptions.events

+ 10 - 5
src/views/oa/myLinks.vue

@@ -61,7 +61,7 @@
 
           <!-- 操作 -->
           <span slot="operationSlot" slot-scope="text, record">
-            <a href="javascript:void(0);" @click="editAnn(record.id)"> 编辑 </a>
+            <a href="javascript:void(0);" @click="editAnn(record)"> 编辑 </a>
             <a-divider type="vertical" />
 
             <a-popconfirm title="确定发布吗?" ok-text="是" cancel-text="否">
@@ -175,6 +175,14 @@ export default {
             console.log('点击了大页面的新增')
             // 拿到子组件的弹框 属性
             this.$refs.AddLinksModal.addLinksModVis = true
+            this.$refs.AddLinksModal.title = '新增友情链接'
+        },
+        // 编辑
+        editAnn (obj) {
+            console.log('点击了编辑,该项公共的ID是:', obj)
+            this.$refs.AddLinksModal.addLinksModVis = true
+            this.$refs.AddLinksModal.title = '编辑友情链接'
+            this.$refs.AddLinksModal.formData = obj
         },
         // 查询
         searchQuery () {
@@ -192,10 +200,7 @@ export default {
         // 分页、排序、筛选变化时触发
         handleTableChange (pagination, filters, sorter) {
         },
-        // 编辑
-        editAnn (id) {
-            console.log('点击了编辑,该项公共的ID是:', id)
-        },
+
         // 发布
         sendAnn (id) {
             console.log('点击了发布')