| | |
| | | import { BaseService, ICoolCache, } from '@cool-midway/core'; |
| | | import * as _ from 'lodash'; |
| | | import { MysqlUtil } from '../../utils/mysqlutil'; |
| | | // 引入读写核心模块 |
| | | |
| | | |
| | | /** |
| | | * 系统用户 |
| | |
| | | // ); // 部门权限 |
| | | const bidsql = `select * from t_sys_business_config where id_='${query.bid}' limit 0,1`; |
| | | const bid_obj_ = await this.nativeQuery(bidsql); |
| | | console.log(bid_obj_) |
| | | let sqlObj = this.mysqlUtil.create_sql(bid_obj_[0], query?.pageindex || null , query?.pagesize || null, query); |
| | | if (sqlObj?.status == 0) { |
| | | return sqlObj?.msg; |
| | | } |
| | | return this.sqlRenderPage(sqlObj?.sql, query); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 分页查询 |
| | | * @param query |
| | | */ |
| | | async getDataByNative(query) { |
| | | // const { keyWord, status, departmentIds = [] } = query; |
| | | // const permsDepartmentArr = await this.baseSysPermsService.departmentIds( |
| | | // this.ctx.admin.userId |
| | | // ); // 部门权限 |
| | | const bidsql = `select * from t_sys_business_config where id_='${query.bid}' limit 0,1`; |
| | | const bid_obj_ = await this.nativeQuery(bidsql); |
| | | console.log(bid_obj_) |
| | | let sqlObj = this.mysqlUtil.create_sql(bid_obj_[0], query?.pageindex || null , query?.pagesize || null, query); |
| | | if (sqlObj?.status == 0) { |
| | | return sqlObj?.msg; |
| | | } |
| | | return this.nativeQuery(sqlObj?.sql) |
| | | } |
| | | |
| | | /** |
| | | * 分页查询 |
| | |
| | | } |
| | | return this.sqlRenderPage(sqlObj?.sql, query); |
| | | } |
| | | |
| | | |
| | | } |