+ {/*
+
+
+
+
+
+ 可购买平台内任意软著时使用
+
+
{
+ // window.open('https://www.aimzhu.com/CouponRule.html')
+
+ getCouponUrl()
+ }}>
+ 使用规则
+
+
+
+
+ 有效期:2008 至 2008
+
+
+
{
+ props.closeModal()
+ }}>
+ 去使用
+
+
+
+
+
+
+
*/}
{couponArray.map((item) => {
return (
diff --git a/src/layout/head/Head.tsx b/src/layout/head/Head.tsx
index 491e159..1039d87 100644
--- a/src/layout/head/Head.tsx
+++ b/src/layout/head/Head.tsx
@@ -5,7 +5,7 @@ import RechargeHead from '../../components/recharge/RechargeHead.tsx';
import { Dropdown, MenuProps, message, Modal, Space, Spin, Input } from "antd";
import { DownOutlined, UserOutlined, QuestionCircleOutlined, BellOutlined, KeyOutlined, LogoutOutlined, GiftOutlined, AccountBookOutlined, ContainerOutlined, MenuFoldOutlined, UsergroupAddOutlined } from "@ant-design/icons";
import { useContext, useEffect, useState } from "react";
-import { put, get, post } from "../../util/AjaxUtils.ts";
+import { put, get, post,getUseUrl } from "../../util/AjaxUtils.ts";
import { GlobalContext, GlobalDispatchContext, reloadUser } from "../../context/GlobalContext.ts";
import UserEdit from "../../components/user/UserEdit.tsx";
import PasswordChange from "../../components/password/PasswordChange.tsx";
@@ -443,8 +443,9 @@ export default function Head() {
{
- // window.open(`https://www.aimzhu.com/operator/route/agreementportal/view?agreementId=${DevUserId}&title=系统操作流程`)
- window.open('https://www.aimzhu.com/operator/route/agreementportal/view?agreementId=c0c5683a-bef3-40c3-8395-900a362ea234&title=系统操作流程')
+
+ // window.open('https://www.aimzhu.com/operator/route/agreementportal/view?agreementId=c0c5683a-bef3-40c3-8395-900a362ea234&title=系统操作流程')
+ getUseUrl()
}}>
diff --git a/src/route/index/Index.tsx b/src/route/index/Index.tsx
index 5a7b9fb..dcd3297 100644
--- a/src/route/index/Index.tsx
+++ b/src/route/index/Index.tsx
@@ -532,6 +532,7 @@ export default function Index() {
messageApi.success('领取成功')
setTimeout(() => {
setCoupon(false)
+ // getCoupon()
}, 500)
},
onFinally() {
diff --git a/src/util/AjaxUtils.ts b/src/util/AjaxUtils.ts
index 59039cd..f7241ed 100644
--- a/src/util/AjaxUtils.ts
+++ b/src/util/AjaxUtils.ts
@@ -40,7 +40,7 @@ axios.interceptors.request.use(config => {
config.data = { unused: 0 } // 这个是关键点,解决get 请求添加不上content_type
}
config.headers['X-USER-ID'] = DevUserId;
- config.headers['X-SOURCE'] = 'page';
+ config.headers['X-SOURCE'] = 'page';
return config
});
@@ -85,7 +85,7 @@ export function get(req: Req) {
req.onSuccess(res);
}).catch(error => {
if (error.response) {
- if(error.response.status === 401) {
+ if (error.response.status === 401) {
window.location.href = axios.defaults.baseURL ? axios.defaults.baseURL : '';
return;
}
@@ -101,6 +101,26 @@ export function get(req: Req) {
req.onFinally?.();
})
}
+// 优惠券规则
+export function getCouponUrl() {
+ axios.get("https://www.aimzhu.com/operator/app/agreementportal/getrelease/89c4ca41-a44e-4ae2-bad3-6fa6536dd453")
+ .then((data:any) => {
+ window.open(`https://www.aimzhu.com/operator/route/agreementportal/view?agreementId=${data.data.agreementId}&title=${data.data.title}`)
+ })
+ .catch(error => {
+ console.error("请求出错:", error);
+ });
+}
+// 操作流程手册
+export function getUseUrl() {
+ axios.get("https://www.aimzhu.com/operator/app/agreementportal/getrelease/96263cb9-c651-419a-842d-d614e723b329")
+ .then((data:any) => {
+ window.open(`https://www.aimzhu.com/operator/route/agreementportal/view?agreementId=${data.data.agreementId}&title=${data.data.title}`)
+ })
+ .catch(error => {
+ console.error("请求出错:", error);
+ });
+}
export function post(req: Req) {
req.onBefore?.();