chore:更改请求前缀/aw为/awjt

This commit is contained in:
Free-sss 2025-08-29 11:43:35 +08:00
parent 4458f4c49f
commit c2eb638f78
9 changed files with 9 additions and 8 deletions

View File

@ -274,7 +274,7 @@ const fetchRecentAlarms = async () => {
try { try {
isLoading.value = true; isLoading.value = true;
const res = await axios.get( const res = await axios.get(
`/aw/space/getRecentAlarms`, `/awjt/space/getRecentAlarms`,
{ {
responseType: 'json', responseType: 'json',
} }

View File

@ -71,6 +71,7 @@ const fetchData = async (url: string) => {
return [{ "location": "四川省.成都市", "items": [{ "tall": 120, "color": "#ff4757" }, { "tall": 50, "color": "#3A86FF" }] }, { "location": "广东省.深圳市", "items": [{ "tall": 90, "color": "#5352ed" }, { "tall": 40, "color": "#5352ed" }] }, { "location": "浙江省.杭州市", "items": [{ "tall": 150, "color": "#ff4757" }, { "tall": 70, "color": "#4ECDC4" }] }, { "location": "江苏省.南京市", "items": [{ "tall": 100, "color": "#ff4757" }, { "tall": 45, "color": "#FFD166" }] }, { "location": "湖北省.武汉市", "items": [{ "tall": 110, "color": "#ff4757" }, { "tall": 52, "color": "#6A0572" }] }, { "location": "陕西省.西安市", "items": [{ "tall": 85, "color": "#ff4757" }, { "tall": 38, "color": "#1A535C" }] }, { "location": "山东省.青岛市", "items": [{ "tall": 130, "color": "#ff4757" }, { "tall": 60, "color": "#FF8C42" }] }, { "location": "河南省.郑州市", "items": [{ "tall": 95, "color": "#ff4757" }, { "tall": 43, "color": "#7209B7" }] }, { "location": "福建省.厦门市", "items": [{ "tall": 140, "color": "#ff4757" }, { "tall": 65, "color": "#06D6A0" }] }, { "location": "辽宁省.大连市", "items": [{ "tall": 88, "color": "#ff4757" }, { "tall": 41, "color": "#118AB2" }] }] return [{ "location": "四川省.成都市", "items": [{ "tall": 120, "color": "#ff4757" }, { "tall": 50, "color": "#3A86FF" }] }, { "location": "广东省.深圳市", "items": [{ "tall": 90, "color": "#5352ed" }, { "tall": 40, "color": "#5352ed" }] }, { "location": "浙江省.杭州市", "items": [{ "tall": 150, "color": "#ff4757" }, { "tall": 70, "color": "#4ECDC4" }] }, { "location": "江苏省.南京市", "items": [{ "tall": 100, "color": "#ff4757" }, { "tall": 45, "color": "#FFD166" }] }, { "location": "湖北省.武汉市", "items": [{ "tall": 110, "color": "#ff4757" }, { "tall": 52, "color": "#6A0572" }] }, { "location": "陕西省.西安市", "items": [{ "tall": 85, "color": "#ff4757" }, { "tall": 38, "color": "#1A535C" }] }, { "location": "山东省.青岛市", "items": [{ "tall": 130, "color": "#ff4757" }, { "tall": 60, "color": "#FF8C42" }] }, { "location": "河南省.郑州市", "items": [{ "tall": 95, "color": "#ff4757" }, { "tall": 43, "color": "#7209B7" }] }, { "location": "福建省.厦门市", "items": [{ "tall": 140, "color": "#ff4757" }, { "tall": 65, "color": "#06D6A0" }] }, { "location": "辽宁省.大连市", "items": [{ "tall": 88, "color": "#ff4757" }, { "tall": 41, "color": "#118AB2" }] }]
} }
try { try {
//
const response = await axios.get(`/dev${url}`); const response = await axios.get(`/dev${url}`);
if (response.data.state === true && response.data.value && response.data.value.length > 0) { if (response.data.state === true && response.data.value && response.data.value.length > 0) {
return response.data.value; // return response.data.value; //

View File

@ -188,7 +188,7 @@ const fetchAlarmData = async ({ startTime, endTime }: { startTime: string; endTi
}; };
try { try {
const res = await axios.get( const res = await axios.get(
`/aw/space/getNumberByAlarmLevel`, `/awjt/space/getNumberByAlarmLevel`,
{ {
params: { startTime, endTime }, params: { startTime, endTime },
responseType: 'json', responseType: 'json',

View File

@ -527,7 +527,7 @@ const getDataSource = (newData: any) => {
const fetchCameraTree = async () => { const fetchCameraTree = async () => {
console.log('fetchCameraTree: 正在获取摄像头树数据...'); console.log('fetchCameraTree: 正在获取摄像头树数据...');
try { try {
const res = await axios.get('/aw/api/camera/tree'); const res = await axios.get('/awjt/api/camera/tree');
if (res.status === 200 && res.data && res.data.state) { if (res.status === 200 && res.data && res.data.state) {
console.log("API 响应数据 (Camera Tree):", res.data.value); console.log("API 响应数据 (Camera Tree):", res.data.value);
return res.data.value; return res.data.value;

View File

@ -88,7 +88,7 @@ const convertTimestampToDateTime = (timestamp: number | string) => {
const fetchRecentAlarms = async () => { const fetchRecentAlarms = async () => {
try { try {
const res = await axios.get( const res = await axios.get(
`/dev/space/getRecentAlarms`, // dev `/awjt/space/getRecentAlarms`, // dev
{ {
responseType: 'json', responseType: 'json',
} }

View File

@ -74,7 +74,7 @@ use([DatasetComponent, CanvasRenderer, LineChart, GridComponent, TooltipComponen
// API // API
const fetchChartData = async (timeType: string, riskLevel: number) => { const fetchChartData = async (timeType: string, riskLevel: number) => {
try { try {
const response = await axios.get(`/aw/screen/alarmByOption/${timeType}/${riskLevel}`) const response = await axios.get(`/awjt/screen/alarmByOption/${timeType}/${riskLevel}`)
if (response.data.state === true) { if (response.data.state === true) {
return response.data.value || [] return response.data.value || []
} else { } else {

View File

@ -85,7 +85,7 @@ const selectedTimeRange = ref('day')
// API // API
const fetchChartData = async (option: string) => { const fetchChartData = async (option: string) => {
try { try {
const response = await axios.get(`/aw/screen/handleByOption/${option}`) const response = await axios.get(`/awjt/screen/handleByOption/${option}`)
if (response.data.state === true) { if (response.data.state === true) {
return response.data.value || [] return response.data.value || []
} else { } else {

View File

@ -237,7 +237,7 @@ function generateTimeRange(period: string): { startTime: string; endTime: string
async function fetchAlarmData({ startTime, endTime }: { startTime: string; endTime: string }) { async function fetchAlarmData({ startTime, endTime }: { startTime: string; endTime: string }) {
try { try {
const res = await axios.get( const res = await axios.get(
`/dev/getAlarmdataRecord`, `/awjt/getAlarmdataRecord`,
{ {
params: { startTime, endTime }, // params: { startTime, endTime }, //
responseType: 'json', responseType: 'json',

View File

@ -93,7 +93,7 @@ const calculateWidth = (value: number) => {
// API // API
const fetchCorpsData = async (option: string) => { const fetchCorpsData = async (option: string) => {
try { try {
const response = await axios.get(`/aw/screen/corpsFive/${option}`) const response = await axios.get(`/awjt/screen/corpsFive/${option}`)
if (response.data.state === true) { if (response.data.state === true) {
displayData.value = response.data.value || [] displayData.value = response.data.value || []
} else { } else {