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 @@ ...@@ -5,7 +5,7 @@
** 菜单参数列表:*变量名*(变量说明,数据类型,是否必填,取值范围) ** 菜单参数列表:*变量名*(变量说明,数据类型,是否必填,取值范围)
**/ **/
import { request } from '@wisdom-utils/utils'; import { request } from '@wisdom-utils/utils';
import * as constants from '../../constants'; import * as constants from '../constants';
const BASEURL = '/PandaAssets/Assets/ReportManager'; const BASEURL = '/PandaAssets/Assets/ReportManager';
export const API = { export const API = {
...@@ -97,12 +97,13 @@ const reportService = { ...@@ -97,12 +97,13 @@ const reportService = {
type: constants.REQUEST_METHOD_POST, type: constants.REQUEST_METHOD_POST,
}, },
}; };
export const submitReportData = (params, data) => request({ export const submitReportData = (params, data) =>
url: API.UPDATE_REPORT_DATA, request({
method: 'post', url: API.UPDATE_REPORT_DATA,
params, method: 'post',
data, params,
}); data,
});
export const exportAccountData = (options, params, data) => export const exportAccountData = (options, params, data) =>
request({ request({
url: API.EXPORT_ACCOUNT_DATA, url: API.EXPORT_ACCOUNT_DATA,
...@@ -111,9 +112,10 @@ export const exportAccountData = (options, params, data) => ...@@ -111,9 +112,10 @@ export const exportAccountData = (options, params, data) =>
params, params,
data, data,
}); });
export const addReportDetailInfoIndex = (data) => request({ export const addReportDetailInfoIndex = (data) =>
url: API.ADD_REPORT_DETAIL_INFO_INDEX, request({
method: 'post', url: API.ADD_REPORT_DETAIL_INFO_INDEX,
data, method: 'post',
}); data,
});
export default reportService; export default reportService;
...@@ -7,6 +7,6 @@ const extraComponents = { ...@@ -7,6 +7,6 @@ const extraComponents = {
returnImage: (data) => { returnImage: (data) => {
return <img width={200} height={200} src={pic} alt={data.alt} />; return <img width={200} height={200} src={pic} alt={data.alt} />;
}, },
default: () => <span>若需要使用弹窗功能,请开发或配置功能函数</span> default: () => <span>若需要使用弹窗功能,请开发或配置功能函数</span>,
}; };
export default extraComponents; export default extraComponents;
@import "~antd/es/style/themes/default.less"; @import '~antd/es/style/themes/default.less';
.lackParams { .lackParams {
width: 100%;
height: 100%;
display: flex; display: flex;
justify-content: center;
align-items: center; align-items: center;
justify-content: center;
width: 100%;
height: 100%;
} }
.reportManage { .reportManage {
padding: 8px;
height: 100%;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
height: 100%;
padding: 8px;
.contentWrapper { .contentWrapper {
display: flex; display: flex;
...@@ -20,12 +20,12 @@ ...@@ -20,12 +20,12 @@
height: 100%; height: 100%;
.controlRow { .controlRow {
background: #ffffff;
padding: 6px;
border-radius: 4px;
margin-bottom: 4px;
display: flex; display: flex;
flex-direction: row; flex-direction: row;
margin-bottom: 4px;
padding: 6px;
background: #ffffff;
border-radius: 4px;
} }
.tableContent { .tableContent {
...@@ -46,8 +46,8 @@ ...@@ -46,8 +46,8 @@
} }
.deleteButton { .deleteButton {
cursor: pointer;
color: rgb(255, 0, 0); color: rgb(255, 0, 0);
cursor: pointer;
&:hover { &:hover {
//color: rgb(24, 144, 255); //color: rgb(24, 144, 255);
...@@ -56,25 +56,24 @@ ...@@ -56,25 +56,24 @@
} }
.spinWrapper { .spinWrapper {
width: 100vw;
height: 60vh;
display: flex; display: flex;
align-items: center;
justify-content: center; justify-content: center;
align-items: center width: 100vw;
height: 60vh;
} }
:global { :global {
.@{ant-prefix}-table-container { .@{ant-prefix}-table-container {
height: 100%; height: 100%;
& > .@{ant-prefix}-table-body { & > .@{ant-prefix}-table-body {
border-bottom: 1px solid #dbe7fb;
border-right: 1px solid #dbe7fb; border-right: 1px solid #dbe7fb;
border-bottom: 1px solid #dbe7fb;
} }
.@{ant-prefix}-table-body { .@{ant-prefix}-table-body {
flex: 1 flex: 1;
} }
.@{ant-prefix}-table-summary > table > tfoot > tr > td { .@{ant-prefix}-table-summary > table > tfoot > tr > td {
...@@ -97,7 +96,6 @@ ...@@ -97,7 +96,6 @@
} }
} }
.link { .link {
cursor: pointer; cursor: pointer;
...@@ -115,7 +113,7 @@ ...@@ -115,7 +113,7 @@
} }
.prefixOrSuffix { .prefixOrSuffix {
color: rgba(0, 0, 0, .65); color: rgba(0, 0, 0, 0.65);
font-size: 10px; font-size: 10px;
} }
...@@ -128,14 +126,14 @@ ...@@ -128,14 +126,14 @@
::-webkit-scrollbar-track, ::-webkit-scrollbar-track,
*::-webkit-scrollbar-track { *::-webkit-scrollbar-track {
background: #F2F2F2; background: #f2f2f2;
border-radius: 10px; border-radius: 10px;
} }
::-webkit-scrollbar-thumb, ::-webkit-scrollbar-thumb,
*::-webkit-scrollbar-thumb { *::-webkit-scrollbar-thumb {
background: #dcdcdc;
border-radius: 5px; border-radius: 5px;
background: #DCDCDC;
} }
} }
} }
...@@ -13,14 +13,14 @@ const isArray = (arr) => { ...@@ -13,14 +13,14 @@ const isArray = (arr) => {
const hasMoney = (configItems) => { const hasMoney = (configItems) => {
if (!configItems) return false; if (!configItems) return false;
let _items = configItems.split('|'); let _items = configItems.split('|');
return !!_items.find(item => item === '金额'); return !!_items.find((item) => item === '金额');
}; };
/** /**
* @Description: 用来在summary中处理数值的配置 * @description: 用来在summary中处理数值的配置
* @Params: 参数描述 * @params: 参数描述
* @Date: 2022/8/10 * @date: 2022/8/10
* @Author: ChenLong * @author: ChenLong
* */ */
const returnHandledNumber = (configItems, num) => { const returnHandledNumber = (configItems, num) => {
// 精度、前缀、后缀、倍率 // 精度、前缀、后缀、倍率
// $_d|_d%|_d*0.0001|金额|0.00 // $_d|_d%|_d*0.0001|金额|0.00
...@@ -31,7 +31,7 @@ const returnHandledNumber = (configItems, num) => { ...@@ -31,7 +31,7 @@ const returnHandledNumber = (configItems, num) => {
let template = '_d'; let template = '_d';
let precision = 0; let precision = 0;
let rate = 1; let rate = 1;
_items.forEach(item => { _items.forEach((item) => {
let _arr = []; let _arr = [];
if (item.match(/_d[^\*]/)) { if (item.match(/_d[^\*]/)) {
// 后缀 // 后缀
...@@ -46,30 +46,40 @@ const returnHandledNumber = (configItems, num) => { ...@@ -46,30 +46,40 @@ const returnHandledNumber = (configItems, num) => {
} }
}); });
// 可能存在NaN的问题 // 可能存在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); return template.replace(/_d/, final);
}; };
/** /**
* @Description: 返回configItems内配置的默认值、默认模式等等 * @description: 返回configItems内配置的默认值、默认模式等等
* @Params: 参数描述 * @params: 参数描述
* @Date: 2022/8/12 * @date: 2022/8/12
* @Author: ChenLong * @author: ChenLong
* @params: * @params:
* configItems 报表字段的配置 例如 defaultValue=智慧水务 defaultDateModel=customer|defaultDateValue=2022-01-01,2022-12-31; * configItems 报表字段的配置 例如 defaultValue=智慧水务
* keysArray 所需要返回的值的key的集合,比如你需要获取configItems中的’defaultValue‘,那么keysArray=['defaultValue']; * defaultDateModel=customer|defaultDateValue=2022-01-01,2022-12-31;
* @Returns: * keysArray
* defaultValue 通用参数 默认值 * 所需要返回的值的key的集合,比如你需要获取configItems中的’defaultValue‘,那么keysArray=['defaultValue'];
* @returns:
* defaultValue 通用参数 默认值
* defaultDateModel 时间参数 默认模式 * defaultDateModel 时间参数 默认模式
* defaultDateValue 时间参数 默认时间 * defaultDateValue 时间参数 默认时间
* */ */
const returnDefaultValueOrConfigs = (configItems = '', keysArray = []) => { const returnDefaultValueOrConfigs = (configItems = '', keysArray = []) => {
let _map = {}; let _map = {};
let _configItemsArray = configItems.split('|'); let _configItemsArray = configItems.split('|');
keysArray.forEach(key => { keysArray.forEach((key) => {
_map[key] = _configItemsArray.find(item => item.includes(`${key}=`))?.replace(`${key}=`, ''); _map[key] = _configItemsArray.find((item) => item.includes(`${key}=`))?.replace(`${key}=`, '');
}); });
return _map; return _map;
}; };
export { 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