|
@@ -376,6 +376,20 @@
|
|
|
placeholder="请输入文献名称\ID"
|
|
|
></el-input>
|
|
|
</el-form-item>
|
|
|
+ <el-form-item label="项目:">
|
|
|
+ <el-select
|
|
|
+ v-model="Sota_searchForm.project_id"
|
|
|
+ clearable
|
|
|
+ placeholder="请选择项目"
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="project in projectOptions"
|
|
|
+ :key="project.id"
|
|
|
+ :label="project.name"
|
|
|
+ :value="project.id"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
<el-form-item>
|
|
|
<el-button type="primary" @click="handleSotaSearch"
|
|
|
>搜索</el-button
|
|
@@ -386,6 +400,18 @@
|
|
|
</el-form>
|
|
|
</div>
|
|
|
<el-table :data="sotaDetailsList" style="width: 100%">
|
|
|
+ <el-table-column prop="projects" label="项目" >
|
|
|
+ <template #default="{ row }">
|
|
|
+ <el-tag
|
|
|
+ v-for="(item, index) in row.projects"
|
|
|
+ :key="index"
|
|
|
+ type=""
|
|
|
+ style="margin-right: 5px; margin-bottom: 5px"
|
|
|
+ >
|
|
|
+ {{ item.name }}
|
|
|
+ </el-tag>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
<el-table-column label="文献ID" prop="literature_id" />
|
|
|
<el-table-column label="文献名称" prop="literature_name" />
|
|
|
<!-- <el-table-column label="Identifier" prop="identifier" /> -->
|
|
@@ -512,6 +538,38 @@
|
|
|
</span>
|
|
|
</template>
|
|
|
</el-dialog>
|
|
|
+
|
|
|
+ <!-- 导出设置对话框 -->
|
|
|
+ <el-dialog
|
|
|
+ title="导出设置"
|
|
|
+ :visible.sync="exportDialogVisible"
|
|
|
+ width="500px"
|
|
|
+ >
|
|
|
+ <el-form :model="exportForm" label-width="100px">
|
|
|
+ <el-form-item label="选择项目:">
|
|
|
+ <el-select
|
|
|
+ v-model="exportForm.project_id"
|
|
|
+ clearable
|
|
|
+ filterable
|
|
|
+ style="width: 100%"
|
|
|
+ placeholder="请选择项目(可选)"
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="project in projectOptions"
|
|
|
+ :key="project.id"
|
|
|
+ :label="project.name"
|
|
|
+ :value="project.id"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ <template #footer>
|
|
|
+ <span class="dialog-footer">
|
|
|
+ <el-button @click="exportDialogVisible = false">取消</el-button>
|
|
|
+ <el-button type="primary" @click="confirmExport">确定</el-button>
|
|
|
+ </span>
|
|
|
+ </template>
|
|
|
+ </el-dialog>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
@@ -605,11 +663,17 @@ export default {
|
|
|
allSelectedRows: new Map(), // 存储所有选中的行
|
|
|
isAllDataSelected: false, // 是否选中所有数据
|
|
|
|
|
|
+ /* 导出设置 */
|
|
|
+ exportDialogVisible: false,
|
|
|
+ exportForm: {
|
|
|
+ project_id: ''
|
|
|
+ },
|
|
|
/* SOTA搜索 */
|
|
|
Sota_searchForm: {
|
|
|
page: 1,
|
|
|
page_size: 10,
|
|
|
keyword: "",
|
|
|
+ pproject_id:[]
|
|
|
},
|
|
|
/* SOTA详情 总数 */
|
|
|
Stoa_total: 0,
|
|
@@ -715,16 +779,21 @@ export default {
|
|
|
/* outcoms导出 */
|
|
|
async outExport() {
|
|
|
try {
|
|
|
- // 添加确认对话框
|
|
|
- await this.$confirm("确认要导出Outcomes数据吗?", "提示", {
|
|
|
- confirmButtonText: "确定",
|
|
|
- cancelButtonText: "取消",
|
|
|
- type: "warning",
|
|
|
- });
|
|
|
+ this.exportForm.project_id = '';
|
|
|
+ this.exportDialogVisible = true;
|
|
|
+ } catch (error) {
|
|
|
+ this.$message.error(error.message || "导出失败");
|
|
|
+ console.error("导出错误:", error);
|
|
|
+ }
|
|
|
+ },
|
|
|
|
|
|
+ // 确认导出
|
|
|
+ async confirmExport() {
|
|
|
+ try {
|
|
|
// 准备导出参数
|
|
|
const params = {
|
|
|
- keyword: this.Sota_searchForm.keyword || undefined
|
|
|
+ keyword: this.Sota_searchForm.keyword || undefined,
|
|
|
+ project_id: this.exportForm.project_id || undefined
|
|
|
};
|
|
|
|
|
|
// 调用导出接口
|
|
@@ -756,6 +825,7 @@ export default {
|
|
|
document.execCommand("copy");
|
|
|
document.body.removeChild(textarea);
|
|
|
this.$message.success("链接已复制到剪贴板");
|
|
|
+ this.exportDialogVisible = false;
|
|
|
}
|
|
|
},
|
|
|
}
|
|
@@ -1595,6 +1665,7 @@ export default {
|
|
|
resetSotaSearch() {
|
|
|
this.Sota_searchForm = {
|
|
|
keyword: "",
|
|
|
+ project_id:[]
|
|
|
};
|
|
|
this.loadSotaDetails();
|
|
|
},
|