This commit is contained in:
Teo
2025-09-15 11:50:18 +08:00
parent fd56b48ebe
commit 3446ab62bc
8 changed files with 30 additions and 14 deletions

View File

@ -9,7 +9,7 @@ import requestGo from '@/utils/request-go';
* @returns {*}
*/
export const listProject = (query?: ProjectQuery): AxiosPromise<ProjectVO[]> => {
export const listProjectGo = (query?: ProjectQuery): AxiosPromise<ProjectVO[]> => {
return requestGo({
url: '/zm/api/v1/system/sysProject/list',
method: 'get',
@ -17,6 +17,20 @@ export const listProject = (query?: ProjectQuery): AxiosPromise<ProjectVO[]> =>
});
};
/**
* 查询项目列表
* @param query
* @returns {*}
*/
export const listProject = (query?: ProjectQuery): AxiosPromise<ProjectVO[]> => {
return request({
url: '/project/project/list',
method: 'get',
params: { ...query }
});
};
/**
* 查询项目dxf
* @param query
@ -246,7 +260,6 @@ export const delAttendanceRange = (id) => {
});
};
// 修改项目打卡范围
export const updateAttendanceRange = (data) => {
return request({
@ -263,4 +276,4 @@ export const getAttendanceRangeList = (data) => {
method: 'get',
params: data
});
};
};

View File

@ -55,6 +55,7 @@ setLocal('host', '121.37.237.116');
setLocal('rtmpPort', '28451');
setLocal('rtcPort', '28453');
setLocal('dockSocketUrl', 'ws://58.17.134.85:9512/websocket');
window['$HOSTSRC'] = 'ws://58.17.134.85:8920/ws';
// 修改 el-dialog 默认点击遮照为不关闭
/*import { ElDialog } from 'element-plus';

View File

@ -340,12 +340,14 @@ const getList = async () => {
if (!queryParams.value.projectId) {
const res = await getProjectSquare(currentProject.value?.id);
if (res.data.length === 0) {
proxy?.$modal.msgWarning('当前项目下没有方阵,请先创建方阵');
matrixOptions.value = [];
queryParams.value.projectId = '';
form.value.projectId = '';
// proxy?.$modal.msgWarning('当前项目下没有方阵,请先创建方阵');
// matrixOptions.value = [];
// queryParams.value.projectId = '';
// form.value.projectId = '';
progressCategoryList.value = [];
tabList.value = [];
activeTab.value = '';
// activeTab.value = '';
return;
} else {
let matrixList = res.data.map((item) => {
return {
@ -523,6 +525,7 @@ const resetMatrix = () => {
matrixValue.value = undefined;
queryParams.value.matrixId = undefined;
queryParams.value.projectId = undefined;
relevancyStructure.value = '1';
matrixOptions.value = [];
};

View File

@ -123,7 +123,7 @@ import * as xlsx from 'xlsx';
import { exportDataToExcel } from '@/utils/exportDataToExcel.js';
import { useUserStoreHook } from '@/store/modules/user';
import { listProjectTeam } from '@/api/project/projectTeam';
import { listProject } from '@/api/project/project';
import { listProject, listProjectGo } from '@/api/project/project';
export default defineComponent({
name: 'index',
components: {
@ -203,7 +203,7 @@ export default defineComponent({
};
// 获取项目列表数据
const sysProjectList = () => {
listProject({ pageNum: 1, pageSize: 1000 }).then((res: any) => {
listProjectGo({ pageNum: 1, pageSize: 1000 }).then((res: any) => {
let list = res.data.list ?? [];
if (list.length) {
state.projectList = list;

View File

@ -305,7 +305,7 @@ import {
delProject,
uploadProjectFile,
getProject,
listProject,
listProjectGo,
updateProject,
attendanceRuleAdd,
attendanceRuleEdit,
@ -434,7 +434,7 @@ const { queryParams, form, rules } = toRefs(data);
/** 查询项目列表 */
const getList = async () => {
loading.value = true;
const res = await listProject(queryParams.value);
const res = await listProjectGo(queryParams.value);
projectList.value = res.data.list;
total.value = res.data.total;
loading.value = false;

View File

@ -69,7 +69,6 @@ export default defineComponent({
};
const init = (obj) => {
let documentKey = obj.id.toString() + new Date().getTime();
window['$HOSTSRC'] = 'ws://58.17.134.85:8920/ws';
let baseURL = window['$HOSTSRC'].replace('ws:', 'http:').replace('/ws', '');
let url = baseURL + obj.filenPathCoding.replaceAll('+', ' ');
let type = obj.suffix;

View File

@ -75,7 +75,6 @@ export default defineComponent({
};
const init = (obj) => {
let documentKey = obj.id.toString() + new Date().getTime();
window['$HOSTSRC'] = 'ws://58.17.134.85:8920/ws';
let baseURL = window['$HOSTSRC'].replace('ws:', 'http:').replace('/ws', '');
let url = baseURL + obj.path;
new CXO_API.CXEditor('box_app_edit1', {

View File

@ -274,6 +274,7 @@ const initData = async () => {
try {
// 获取项目列表
const projectRes = await listProject();
console.log('🚀 ~ initData ~ projectRes:', projectRes);
projectOptions.value = projectRes.rows.map((item: any) => ({
id: item.id,
projectName: item.projectName,