gaoluyang
6 天以前 6b92f0eeec9c0f9a3cd5d516c4513a76cde405e3
src/views/procurementManagement/procurementInvoiceLedger/index.vue
@@ -63,23 +63,8 @@
            <el-button link :icon="Files" type="danger"> 附件 </el-button>
            <template #dropdown>
              <el-dropdown-menu>
                <el-dropdown-item
                  v-if="row.commonFiles.length !== 0"
                  :icon="Download"
                  command="download"
                >
                  下载
                </el-dropdown-item>
                <el-dropdown-item :icon="Upload" command="upload">
                  上传
                </el-dropdown-item>
                <el-dropdown-item
                  v-if="row.commonFiles.length !== 0"
                  :icon="Delete"
                  command="delete"
                  style="color: #f56c6c;"
                >
                  删除
                </el-dropdown-item>
              </el-dropdown-menu>
            </template>
@@ -88,14 +73,15 @@
        <template #operation="{ row }">
          <el-button
            type="primary"
            text
                  link
            @click="openEdit(row)"
          >
            编辑
          </el-button>
               <el-button link type="primary" size="small" @click="downLoadFile(row)">附件</el-button>
          <el-button
            type="primary"
            text
                  link
            @click="handleDelete(row)"
          >
            删除
@@ -103,6 +89,7 @@
        </template>
      </PIMTable>
    </div>
      <FileList ref="fileListRef" />
    <UploadModal ref="modalRef" @uploadSuccess="uploadSuccess"></UploadModal>
    <EditModal ref="editmodalRef" @success="getTableData"></EditModal>
  </div>
@@ -130,9 +117,8 @@
import UploadModal from "./Modal/UploadModal.vue";
import EditModal from "./Modal/EditModal.vue";
import useUserStore from "@/store/modules/user.js";
import {delInvoiceLedgerByRegProductId} from "@/api/salesManagement/invoiceLedger.js";
import dayjs from "dayjs";
const userStore = useUserStore();
import FileList from "./fileList.vue";
defineOptions({
  name: "来票台账",
@@ -236,7 +222,7 @@
    },
    {
      fixed: "right",
      width: 150,
      width: 190,
      label: "操作",
      dataType: "slot",
      slot: "operation",
@@ -272,7 +258,12 @@
const handleSelectionChange = (val) => {
  multipleVal.value = val;
};
//附件相关
const fileListRef = ref(null)
//查看附件
const downLoadFile = (row) => {
   fileListRef.value.open(row.commonFiles, row.id)
}
// 导出
const handleOut = () => {
  ElMessageBox.confirm("选中的内容将被导出,是否确认导出?", "导出", {