From 00e147ec892cb1e89d0698787a8c60da1014cdb7 Mon Sep 17 00:00:00 2001
From: binxie <137736985@qq.com>
Date: 星期一, 26 六月 2023 17:42:22 +0800
Subject: [PATCH] Community升级
---
force-app/main/default/classes/LexConsumableAccountSOQL.cls | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/force-app/main/default/classes/LexConsumableAccountSOQL.cls b/force-app/main/default/classes/LexConsumableAccountSOQL.cls
index eef1437..cf58b7c 100644
--- a/force-app/main/default/classes/LexConsumableAccountSOQL.cls
+++ b/force-app/main/default/classes/LexConsumableAccountSOQL.cls
@@ -1,13 +1,14 @@
public with sharing class LexConsumableAccountSOQL {
public static AggregateResult[] getAccountBySales(Datetime thisDatetime ,Datetime nextDatetime){
AggregateResult[] arList = new List<AggregateResult>([
- SELECT count(id), Consumable_order__r.Order_ForHospital__r.name hospitalName, sum(Sale_amount__c) thisAmount
+ SELECT Consumable_order__r.Order_ForHospital__c,Consumable_order__r.Order_ForHospital__r.name hospitalName,
+ sum(Sale_amount__c) thisAmount
FROM Consumable_Orderdetails__c
WHERE
CreatedDate >= :thisDatetime
AND CreatedDate < :nextDatetime
AND Consumable_order__r.Order_ForHospital__r.name != ''
- GROUP BY Consumable_order__r.Order_ForHospital__r.Name
+ GROUP BY Consumable_order__r.Order_ForHospital__c,Consumable_order__r.Order_ForHospital__r.name
ORDER BY sum(Sale_amount__c) DESC
LIMIT 10
]);
--
Gitblit v1.9.1