Ben Lin
2024-06-12 da85b09c600ddcf4e5c8cad66012fa29a8252b39
src/api/tigerapi/system.ts
@@ -31,7 +31,7 @@
  iSYS_ROLE_PROD,
} from './model/systemModel';
import { defHttp } from '/@/utils/http/axios';
import { isNullOrEmpty, isTimeType } from '/@/utils/is';
import { isDate, isNullOrEmpty, isTimeType } from '/@/utils/is';
import { MES_ROUTE_EDGE, MES_ROUTE_NODE } from './model/router';
export enum Api {
@@ -712,7 +712,7 @@
      Keys[k] != '0' &&
      !Keys[k].toString().endsWith('PSelect_0')
    ) {
      if (!isNullOrEmpty(params[Keys[k]].length) && isTimeType(params[Keys[k]][0])) {
      if (!isNullOrEmpty(params[Keys[k]].length) && isDate(params[Keys[k]][0])) {
        sqlcmd += ` And ${Keys[k]} > '${params[Keys[k]][0]}'`;
        sqlcmd += ` And ${Keys[k]} < '${params[Keys[k]][1]}'`;
      } else {
@@ -784,7 +784,28 @@
  );
}
//获取服务器Json文件返回Json数据
/**
 * @description: 根据条件删除
 * @param {string} sqlcmd
 * @param {string} entityName
 * @return {*}
 */
export const DeleteWhere = async (sqlcmd: string, entityName: string) => {
  const usParams = genAction(entityName, sqlcmd);
  return await defHttp.post(
    { url: Api.DeleteWhere, params: usParams },
    {
      errorMessageMode: 'none',
      isTransformResponse: false,
    },
  );
};
/**
 * @description: 获取服务器Json文件返回Json数据
 * @param {string} url
 * @return {*}
 */
export async function fetchJson(url: string) {
  try {
    const response = await fetch(url);