|
@@ -158,6 +158,38 @@ export class PayeeService extends BaseService {
|
|
return merchant
|
|
return merchant
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ // async list(params: any) {
|
|
|
|
+ // const merchantId = await this.getMerchantId(params);
|
|
|
|
+ // const query = `SELECT * FROM payee WHERE merchantId = '${merchantId}' ORDER BY merchantId ASC`;
|
|
|
|
+ // return this.sqlRenderPage(query, params, false);
|
|
|
|
+ // }
|
|
|
|
+
|
|
|
|
+ async list(query: any, option: any, connectionName?: any): Promise<any> {
|
|
|
|
+ const merchantId = await this.getMerchantId(query);
|
|
|
|
+ const res = await super.list(
|
|
|
|
+ {
|
|
|
|
+ ...query,
|
|
|
|
+ // merchantId: merchantId
|
|
|
|
+
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ ...option,
|
|
|
|
+ where: [{
|
|
|
|
+ merchantId
|
|
|
|
+ // `merchantId=${merchantId}`
|
|
|
|
+ }]
|
|
|
|
+ // select: ['id', 'name', 'code', 'description', 'supportedCurrencies'],
|
|
|
|
+ },
|
|
|
|
+ connectionName
|
|
|
|
+ );
|
|
|
|
+ console.log(181, merchantId, query);
|
|
|
|
+ return res;
|
|
|
|
+ // const merchantId = await this.getMerchantId(params);
|
|
|
|
+ // const query = `SELECT * FROM payee WHERE merchantId = '${merchantId}' ORDER BY merchantId ASC`;
|
|
|
|
+ // return this.sqlRenderPage(query, params, false);
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+
|
|
async page(params: any) {
|
|
async page(params: any) {
|
|
const merchantId = await this.getMerchantId(params);
|
|
const merchantId = await this.getMerchantId(params);
|
|
const query = `SELECT * FROM payee WHERE merchantId = '${merchantId}' ORDER BY merchantId ASC`;
|
|
const query = `SELECT * FROM payee WHERE merchantId = '${merchantId}' ORDER BY merchantId ASC`;
|
|
@@ -178,6 +210,13 @@ export class PayeeService extends BaseService {
|
|
// merchantId = merchant.mchId;
|
|
// merchantId = merchant.mchId;
|
|
// }
|
|
// }
|
|
const { merchant } = this.ctx.admin;
|
|
const { merchant } = this.ctx.admin;
|
|
|
|
+
|
|
|
|
+ const customer = await this.customerEntity.findOneBy({
|
|
|
|
+ merchantId: merchant.mchId,
|
|
|
|
+ out_user_id: null
|
|
|
|
+ });
|
|
|
|
+
|
|
|
|
+ console.log(209, customer);
|
|
return merchant.mchId
|
|
return merchant.mchId
|
|
}
|
|
}
|
|
}
|
|
}
|