Commit 7e486a8a authored by 陈龙's avatar 陈龙

fix: 修复文件引用错误

parent ab5be8e3
export const RESTART_ON_REMOUNT = '@@saga-injector/restart-on-remount';
export const DAEMON = '@@saga-injector/daemon';
export const ONCE_TILL_UNMOUNT = '@@saga-injector/once-till-unmount';
export const FILTER_FOLER_REG =
/(configs|configuration|framework|iframe|Product|product|productex|project|qrcode|threedimensional|video|widgetconfigs)/;
export const FILTER_FOLER_WEB5 = /(pages)/;
export const SERVICE_APP_GET_UI_META = 'app.getUIMeta';
export const SERVICE_APP_LOGIN_MODE = {
password: 'password',
dingding: 'dingding',
weixin: 'weixin',
phone: 'phone',
};
export const LOGIN_DISPLAY = {
Account: 'Account',
WeChart: 'WeChart',
Mobile: 'Mobile',
};
export const LOGIN_WAY = {
Account: 'pdw',
WeChart: 'iotWechat',
Mobile: 'iotPhone',
};
export const WX_REDIRECT_URI = 'https://panda-water.com/civbase/user/login';
export const SERVICE_INTERFACE_SUCCESS_CODE = 0;
export const SERVICE_INTERFACE_PARAMS_EXCEPTION_CODE = -1; // 服务参数异常
export const SERVICE_INTERFACE_HANDLE_EXCEPTION_CODE = -2; // 服务处理异常
export const SERVICE_APP_CLOSE_ALL_TABS = 'app.close.tabs';
export const REQUEST_HTTP = 'http';
export const REQUEST_POP = 'pop';
export const REQUEST_METHOD_GET = 'get';
export const REQUEST_METHOD_POST = 'post';
export const REQUEST_METHOD_PUT = 'put';
export const REQUEST_METHOD_DELETE = 'delete';
export const RESPONSE_TYPE = 'blob';
......@@ -5,7 +5,7 @@
** 菜单参数列表:*变量名*(变量说明,数据类型,是否必填,取值范围)
**/
import { request } from '@wisdom-utils/utils';
import * as constants from '../../constants';
import * as constants from '../constants';
const BASEURL = '/PandaAssets/Assets/ReportManager';
export const API = {
......@@ -97,12 +97,13 @@ const reportService = {
type: constants.REQUEST_METHOD_POST,
},
};
export const submitReportData = (params, data) => request({
url: API.UPDATE_REPORT_DATA,
method: 'post',
params,
data,
});
export const submitReportData = (params, data) =>
request({
url: API.UPDATE_REPORT_DATA,
method: 'post',
params,
data,
});
export const exportAccountData = (options, params, data) =>
request({
url: API.EXPORT_ACCOUNT_DATA,
......@@ -111,9 +112,10 @@ export const exportAccountData = (options, params, data) =>
params,
data,
});
export const addReportDetailInfoIndex = (data) => request({
url: API.ADD_REPORT_DETAIL_INFO_INDEX,
method: 'post',
data,
});
export const addReportDetailInfoIndex = (data) =>
request({
url: API.ADD_REPORT_DETAIL_INFO_INDEX,
method: 'post',
data,
});
export default reportService;
......@@ -7,6 +7,6 @@ const extraComponents = {
returnImage: (data) => {
return <img width={200} height={200} src={pic} alt={data.alt} />;
},
default: () => <span>若需要使用弹窗功能,请开发或配置功能函数</span>
default: () => <span>若需要使用弹窗功能,请开发或配置功能函数</span>,
};
export default extraComponents;
@import "~antd/es/style/themes/default.less";
@import '~antd/es/style/themes/default.less';
.lackParams {
width: 100%;
height: 100%;
display: flex;
justify-content: center;
align-items: center;
justify-content: center;
width: 100%;
height: 100%;
}
.reportManage {
padding: 8px;
height: 100%;
display: flex;
flex-direction: column;
height: 100%;
padding: 8px;
.contentWrapper {
display: flex;
......@@ -20,12 +20,12 @@
height: 100%;
.controlRow {
background: #ffffff;
padding: 6px;
border-radius: 4px;
margin-bottom: 4px;
display: flex;
flex-direction: row;
margin-bottom: 4px;
padding: 6px;
background: #ffffff;
border-radius: 4px;
}
.tableContent {
......@@ -46,8 +46,8 @@
}
.deleteButton {
cursor: pointer;
color: rgb(255, 0, 0);
cursor: pointer;
&:hover {
//color: rgb(24, 144, 255);
......@@ -56,25 +56,24 @@
}
.spinWrapper {
width: 100vw;
height: 60vh;
display: flex;
align-items: center;
justify-content: center;
align-items: center
width: 100vw;
height: 60vh;
}
:global {
.@{ant-prefix}-table-container {
height: 100%;
& > .@{ant-prefix}-table-body {
border-bottom: 1px solid #dbe7fb;
border-right: 1px solid #dbe7fb;
border-bottom: 1px solid #dbe7fb;
}
.@{ant-prefix}-table-body {
flex: 1
flex: 1;
}
.@{ant-prefix}-table-summary > table > tfoot > tr > td {
......@@ -97,7 +96,6 @@
}
}
.link {
cursor: pointer;
......@@ -115,7 +113,7 @@
}
.prefixOrSuffix {
color: rgba(0, 0, 0, .65);
color: rgba(0, 0, 0, 0.65);
font-size: 10px;
}
......@@ -128,14 +126,14 @@
::-webkit-scrollbar-track,
*::-webkit-scrollbar-track {
background: #F2F2F2;
background: #f2f2f2;
border-radius: 10px;
}
::-webkit-scrollbar-thumb,
*::-webkit-scrollbar-thumb {
background: #dcdcdc;
border-radius: 5px;
background: #DCDCDC;
}
}
}
......@@ -13,14 +13,14 @@ const isArray = (arr) => {
const hasMoney = (configItems) => {
if (!configItems) return false;
let _items = configItems.split('|');
return !!_items.find(item => item === '金额');
return !!_items.find((item) => item === '金额');
};
/**
* @Description: 用来在summary中处理数值的配置
* @Params: 参数描述
* @Date: 2022/8/10
* @Author: ChenLong
* */
* @description: 用来在summary中处理数值的配置
* @params: 参数描述
* @date: 2022/8/10
* @author: ChenLong
*/
const returnHandledNumber = (configItems, num) => {
// 精度、前缀、后缀、倍率
// $_d|_d%|_d*0.0001|金额|0.00
......@@ -31,7 +31,7 @@ const returnHandledNumber = (configItems, num) => {
let template = '_d';
let precision = 0;
let rate = 1;
_items.forEach(item => {
_items.forEach((item) => {
let _arr = [];
if (item.match(/_d[^\*]/)) {
// 后缀
......@@ -46,30 +46,40 @@ const returnHandledNumber = (configItems, num) => {
}
});
// 可能存在NaN的问题
let final = _items.includes('金额') ? Number((num * rate).toFixed(precision)).toLocaleString() : Number((num * rate).toFixed(precision));
let final = _items.includes('金额')
? Number((num * rate).toFixed(precision)).toLocaleString()
: Number((num * rate).toFixed(precision));
return template.replace(/_d/, final);
};
/**
* @Description: 返回configItems内配置的默认值、默认模式等等
* @Params: 参数描述
* @Date: 2022/8/12
* @Author: ChenLong
* @params:
* configItems 报表字段的配置 例如 defaultValue=智慧水务 defaultDateModel=customer|defaultDateValue=2022-01-01,2022-12-31;
* keysArray 所需要返回的值的key的集合,比如你需要获取configItems中的’defaultValue‘,那么keysArray=['defaultValue'];
* @Returns:
* defaultValue 通用参数 默认值
* @description: 返回configItems内配置的默认值、默认模式等等
* @params: 参数描述
* @date: 2022/8/12
* @author: ChenLong
* @params:
* configItems 报表字段的配置 例如 defaultValue=智慧水务
* defaultDateModel=customer|defaultDateValue=2022-01-01,2022-12-31;
* keysArray
* 所需要返回的值的key的集合,比如你需要获取configItems中的’defaultValue‘,那么keysArray=['defaultValue'];
* @returns:
* defaultValue 通用参数 默认值
* defaultDateModel 时间参数 默认模式
* defaultDateValue 时间参数 默认时间
* */
*/
const returnDefaultValueOrConfigs = (configItems = '', keysArray = []) => {
let _map = {};
let _configItemsArray = configItems.split('|');
keysArray.forEach(key => {
_map[key] = _configItemsArray.find(item => item.includes(`${key}=`))?.replace(`${key}=`, '');
keysArray.forEach((key) => {
_map[key] = _configItemsArray.find((item) => item.includes(`${key}=`))?.replace(`${key}=`, '');
});
return _map;
};
export {
isObject, isString, isNumber, hasMoney, isArray, returnHandledNumber, returnDefaultValueOrConfigs,
isObject,
isString,
isNumber,
hasMoney,
isArray,
returnHandledNumber,
returnDefaultValueOrConfigs,
};
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment