diff --git a/f/web-kboss/src/api/login.js b/f/web-kboss/src/api/login.js index 726a76c..7ee1d50 100644 --- a/f/web-kboss/src/api/login.js +++ b/f/web-kboss/src/api/login.js @@ -2,6 +2,11 @@ import request from '@/utils/request' const suffix = '.dspy' +const withDomainName = (params = {}) => ({ + ...params, + domain_name: window.location.hostname +}) + //注册新用户 export function registerUserAPI(params) { return request({ @@ -47,7 +52,7 @@ export function getCodeAPI(params) { return request({ url: `/user/mobilecode${suffix}`, method: 'post', - params: params + params: withDomainName(params) }) } @@ -65,7 +70,7 @@ export function retrieveCodeAPI(data) { url: `/user/mobilecode.dspy`, method: 'post', headers: {'Content-Type': 'application/json'}, - data + data: withDomainName(data) }) } @@ -269,7 +274,7 @@ export function sendCode(data) { return request({ url: `/user/mobilecode.dspy`, method: 'post', - data, + data: withDomainName(data), }) } // 注册 diff --git a/f/web-kboss/src/api/newsapi/newsapi.js b/f/web-kboss/src/api/newsapi/newsapi.js index 05e1fe5..de2f50e 100644 --- a/f/web-kboss/src/api/newsapi/newsapi.js +++ b/f/web-kboss/src/api/newsapi/newsapi.js @@ -23,29 +23,24 @@ export const reqNewsDetail = (data) => { url: '/news/front_news_detail.dspy', // 详情接口使用 GET 查询。 method: 'get', - // 传入文章 id 和当前页面 url_link 等查询参数。 + // 传入文章 id 。 params: data }) } // 添加新闻 export const reqAddNews = (data) => { - const isFormData = data instanceof FormData return request({ url: '/news/news_article_add.dspy', - method: isFormData ? 'post' : 'get', - params: isFormData ? undefined : data, - data: isFormData ? data : undefined, - headers: isFormData ? { 'Content-Type': 'multipart/form-data' } : undefined + method: 'post', + data }) } // 编辑新闻 export const reqEditNews = (data) => { - const isFormData = data instanceof FormData return request({ url: '/news/news_article_update.dspy', method: 'post', - data, - headers: isFormData ? { 'Content-Type': 'multipart/form-data' } : undefined + data }) } // 删除新闻 diff --git a/f/web-kboss/src/components/Pagination/index.vue b/f/web-kboss/src/components/Pagination/index.vue index bd6ac67..95ef8d6 100644 --- a/f/web-kboss/src/components/Pagination/index.vue +++ b/f/web-kboss/src/components/Pagination/index.vue @@ -19,7 +19,7 @@ @click="handleSearch" > - +
  • 创建日期: {}); }, async logout1() { logoutAPI().then((res) => { }); - let url = window.location.href; - await this.$router.push(`/login`); + await this.$router.replace(getHomePath()).catch(() => {}); store.commit('tagsView/resetBreadcrumbState'); store.commit('permission/RESET_ROUTES'); sessionStorage.removeItem("auths"); diff --git a/f/web-kboss/src/router/index.js b/f/web-kboss/src/router/index.js index d455f19..58e9c71 100644 --- a/f/web-kboss/src/router/index.js +++ b/f/web-kboss/src/router/index.js @@ -414,6 +414,13 @@ export const constantRoutes = [ hidden: true, meta: { title: "企业动态", onCache: true }, }, + { + path: "news/detail/:id", + component: () => import("@/views/homePage/news/NewsDetail.vue"), + name: "homePageNewsDetail", + hidden: true, + meta: { title: "新闻详情", onCache: true }, + }, { path: "new", component: () => import("@/views/homePage/components/topBox/new/index.vue"), diff --git a/f/web-kboss/src/views/LoginDialog/LoginDialog.vue b/f/web-kboss/src/views/LoginDialog/LoginDialog.vue index fca96fc..3762027 100644 --- a/f/web-kboss/src/views/LoginDialog/LoginDialog.vue +++ b/f/web-kboss/src/views/LoginDialog/LoginDialog.vue @@ -575,10 +575,10 @@ export default { height: 46px; padding: 0; border: none; - border: 1px solid rgba(15, 23, 42, 0.72); + border: 1px solid #cbd5e1; border-radius: 14px; background: rgba(255, 255, 255, 0.66); - color: #1f2937; + color: #94a3b8; font-size: 16px; font-weight: 600; cursor: pointer; diff --git a/f/web-kboss/src/views/homePage/agentStore/decisionCase.vue b/f/web-kboss/src/views/homePage/agentStore/decisionCase.vue index 244d9f9..8411dcd 100644 --- a/f/web-kboss/src/views/homePage/agentStore/decisionCase.vue +++ b/f/web-kboss/src/views/homePage/agentStore/decisionCase.vue @@ -143,12 +143,16 @@ + + + diff --git a/f/web-kboss/src/views/homePage/news/newsLog.vue b/f/web-kboss/src/views/homePage/news/newsLog.vue index 8f35ccf..2b636e2 100644 --- a/f/web-kboss/src/views/homePage/news/newsLog.vue +++ b/f/web-kboss/src/views/homePage/news/newsLog.vue @@ -315,38 +315,17 @@ export default { }, buildArticlePayload(article) { // 将编辑弹窗字段转换成新增/编辑接口需要的字段。 - const payload = { + return { ...(article.id ? { id: article.id } : {}), url_link: window.location.href, title: article.title, article_type: article.type, summary: article.summary, publish_time: article.publish_time || article.publishTime, + cover_img: article.coverUrl, content: article.content, status: this.getApiStatus(article.status) } - const hasContentFiles = Array.isArray(article.contentFiles) && article.contentFiles.length > 0 - if (article.coverFile || hasContentFiles) { - const formData = new FormData() - Object.keys(payload).forEach(key => { - formData.append(key, payload[key]) - }) - if (article.coverFile) { - formData.append('cover_img', article.coverFile) - } else { - formData.append('cover_img', article.coverUrl) - } - if (hasContentFiles) { - article.contentFiles.forEach(file => { - formData.append('content_images', file) - }) - } - return formData - } - return { - ...payload, - cover_img: article.coverUrl - } }, async confirmAction(title, message, type = 'warning') { // 操作前弹出二次确认,用户取消时直接终止后续请求。 diff --git a/f/web-kboss/src/views/homePage/news/newsView.vue b/f/web-kboss/src/views/homePage/news/newsView.vue index 5f7419b..6ce6989 100644 --- a/f/web-kboss/src/views/homePage/news/newsView.vue +++ b/f/web-kboss/src/views/homePage/news/newsView.vue @@ -38,7 +38,7 @@ @@ -147,6 +148,10 @@ export default { goAbout() { this.$router.push('/homePage/about') }, + goNewsDetail(item) { + if (!item || !item.id) return + this.$router.push(`/homePage/news/detail/${item.id}`) + }, handleCategoryChange(value) { this.activeCategory = value this.page = 1 diff --git a/f/web-kboss/src/views/homePage/trainPlatform/index.vue b/f/web-kboss/src/views/homePage/trainPlatform/index.vue index aa20aa1..9cb63f6 100644 --- a/f/web-kboss/src/views/homePage/trainPlatform/index.vue +++ b/f/web-kboss/src/views/homePage/trainPlatform/index.vue @@ -18,10 +18,7 @@

    一站式云端AI开发平台,通过对话即可快速构建智能体、工作流、网页与移动应用,依托强大的云端基础设施实现开箱即用的环境和一键部署服务

    -
    - - -
    +
    @@ -97,17 +94,6 @@ -
    -
    -

    告别部署烦恼

    -

    - 无论你是零基础小白还是资深开发者,训推平台都能帮你实现从想法到产品上线的丝滑体验 -

    -
    - -
    -
    -
    diff --git a/f/web-kboss/src/views/login/components/ForgotPasswordDialog.vue b/f/web-kboss/src/views/login/components/ForgotPasswordDialog.vue index db41b0e..db21739 100644 --- a/f/web-kboss/src/views/login/components/ForgotPasswordDialog.vue +++ b/f/web-kboss/src/views/login/components/ForgotPasswordDialog.vue @@ -37,7 +37,7 @@ :loading="isGettingCode" @click="debouncedGetCode" > - {{ sendCodeText }} + {{ sendCodeText }}