From 11987b37c159f9f3ac4f57192c303edf8f052d18 Mon Sep 17 00:00:00 2001
From: rainbro <33367671@qq.com>
Date: Thu, 17 Jul 2025 11:40:38 +0800
Subject: [PATCH] =?UTF-8?q?=E6=9F=A5=E9=87=8D=E8=AE=A2=E5=8D=95=E5=88=97?=
=?UTF-8?q?=E8=A1=A8=20AI=E8=AE=A2=E5=8D=95=E5=88=97=E8=A1=A8?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/router/index.js | 4 +-
src/store/index.js | 4 +-
src/views/agent/aiOrderList.vue | 160 -------------------------------------
src/views/agent/checkOrderList.vue | 143 +++++++++++++++++++++++++--------
4 files changed, 113 insertions(+), 198 deletions(-)
delete mode 100644 src/views/agent/aiOrderList.vue
diff --git a/src/router/index.js b/src/router/index.js
index e8072d9..cf187a1 100755
--- a/src/router/index.js
+++ b/src/router/index.js
@@ -85,10 +85,10 @@ const routes = [{
}
},
{
- path: '/agent/aiOrderList',
+ path: '/agent/checkOrderList',
name: 'AI写作订单',
isFirst: true,
- component: () => import( /* webpackChunkName: "siteList" */ '../views/agent/aiOrderList.vue'),
+ component: () => import( /* webpackChunkName: "siteList" */ '../views/agent/checkOrderList.vue'),
meta: {
title: 'AI写作订单',
breadcrumbParent: '首页',
diff --git a/src/store/index.js b/src/store/index.js
index 865b513..2978c89 100755
--- a/src/store/index.js
+++ b/src/store/index.js
@@ -114,12 +114,12 @@ export default new Vuex.Store({
{
index: '2-1',
title: '查重订单',
- path: '/agent/checkOrderList'
+ path: '/agent/checkOrderList?list=check'
},
{
index: '2-2',
title: 'AI写作订单',
- path: '/agent/aiOrderList'
+ path: '/agent/checkOrderList?list=ai'
},
{
index: '2-3',
diff --git a/src/views/agent/aiOrderList.vue b/src/views/agent/aiOrderList.vue
deleted file mode 100644
index 4e554c4..0000000
--- a/src/views/agent/aiOrderList.vue
+++ /dev/null
@@ -1,160 +0,0 @@
-
-
{{ scope.row.title }}
+{{ scope.row.sale_date_format }}
+{{ scope.row.similarity }}%
@@ -249,6 +266,8 @@ export default { }, data() { return { + pageTab: 'check', + pageTitle: '查重订单', // AUTH token: 'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpYXQiOjE3NTI2NDY1NDUsIm5iZiI6MTc1MjY0NjU0NSwiZXhwIjoxNzU1MjM4NTQ1LCJ1c2VyIjoic3VidXNlciIsImxvZ2luX3R5cGUiOjAsImFpZCI6IjEifQ.G-Is-x9qPMiV_urOlDPQVRjfAIozySxL5EK2k82d46k', // 表格加载 @@ -284,11 +303,15 @@ export default { pddDeliveredDelayedSubmitHour: 1, selectAllowPddDeliveredDelayedSubmit: false, + donwReportNameFormat: [], + reportNameFormat: 0, + } }, mounted() { + this.pageTab = this.$route.query.list this.getOrderList() - // this. + this.getConfig() }, methods: { getFilterParams(){ @@ -308,6 +331,15 @@ export default { this.getOrderList(params) }, + resetPageParams(){ + this.orderListTotalRecords = 0 + this.isHasNextPage = true + this.orderListCurrentPage = 1 + this.orderListPageSize = 100 + this.orderListNextMinId = 0 + this.orderListPrevMaxId = 0 + this.orderListEndPage = 0 + }, resetSearchParams(){ this.searchDate = '' this.searchStatus = 'all' @@ -319,6 +351,29 @@ export default { console.error('分页错误:', error) // 可以在这里显示错误提示 }, + getConfig() { + this.$http('POST', '/agentnew/get_agent_config', { + + }, { + headers: { + 'Auth': this.token + } + }).then(response => { + this.$nextTick(() => { + if (response.status) { + if (response.data.pdd_delivered_delayed_submit_hour > 0) { + this.pddDeliveredDelayedSubmitHour = response.data.pdd_delivered_delayed_submit_hour; + this.selectAllowPddDeliveredDelayedSubmit = true; + } + this.reportNameFormat = response.data.report_name_format; + } else { + this.$Message.error(response.info); + } + }) + }).catch(error => { + console.error(error, 'error') + }) + }, getOrderList(params) { console.log(this.searchDate) this.tableLoading = true @@ -326,6 +381,7 @@ export default { const requestParams = { pagesize: this.orderListPageSize, page: this.orderListCurrentPage, + pagetab: this.pageTab, ...params } console.log(requestParams, 'requestParams==='); @@ -341,6 +397,8 @@ export default { this.orderListTotalRecords = response.data.total_records this.searchSiteList = response.data.sitelist this.searchTypeList = response.data.type2name + this.donwReportNameFormat = response.data.donw_report_name_format + console.log(this.donwReportNameFormat, 'donwReportNameFormat') // 更新minId和maxId if (response.data.minid) this.orderListNextMinId = response.data.minid if (response.data.maxid) this.orderListPrevMaxId = response.data.maxid @@ -439,6 +497,25 @@ export default { changeSearchStatus() { console.log(this.searchStatus) }, + changeReportNameFormat() { + this.$http('POST', '/agentnew/ajax_set_report_name_format', { + report_name_format: this.reportNameFormat, + }, { + headers: { + 'Auth': this.token + } + }).then(response => { + this.$nextTick(() => { + if (response.status) { + this.$Message.success(response.info); + } else { + this.$Message.error(response.info); + } + }) + }).catch(error => { + console.error(error, 'error') + }) + }, // 弹框相关方法---start showConfirmDelReport(row) { this.dialogVisibleDelReport = true; @@ -478,27 +555,7 @@ export default { }, // 弹框相关方法---end showPddSetting() { - this.$http('POST', '/agentnew/get_pdd_setting', { - - }, { - headers: { - 'Auth': this.token - } - }).then(response => { - this.$nextTick(() => { - if (response.status) { - this.dialogVisiblePddSetting = true; - if (response.data.pdd_delivered_delayed_submit_hour > 0) { - this.pddDeliveredDelayedSubmitHour = response.data.pdd_delivered_delayed_submit_hour; - this.selectAllowPddDeliveredDelayedSubmit = true; - } - } else { - this.$Message.error(response.info); - } - }) - }).catch(error => { - console.error(error, 'error') - }) + this.dialogVisiblePddSetting = true; }, // 关闭弹框事件 closePddSetting() { @@ -593,11 +650,29 @@ export default { } this.getOrderList(params) - } + }, }, computed: { }, + watch: { + + '$route.query'(newVal) { + + console.log('参数变化:', newVal); + // 执行数据更新逻辑 + this.pageTab = newVal.list + if (this.pageTab === 'check') { + this.pageTitle = '查重订单' + } else if (this.pageTab === 'ai') { + this.pageTitle = 'AI写作订单' + } + this.getOrderList() + this.resetSearchParams() + this.resetPageParams() + } + + }, }