From 36d15f189de2e83ce2576715dac30c3c260388dd Mon Sep 17 00:00:00 2001
From: buli <137736985@qq.com>
Date: 星期五, 14 七月 2023 14:47:50 +0800
Subject: [PATCH] fixconflict

---
 force-app/main/default/classes/LexConInvoicedetailsController.cls |   66 +++++++++++++++++++++------------
 1 files changed, 42 insertions(+), 24 deletions(-)

diff --git a/force-app/main/default/classes/LexConInvoicedetailsController.cls b/force-app/main/default/classes/LexConInvoicedetailsController.cls
index 18a4fb5..4f220f5 100644
--- a/force-app/main/default/classes/LexConInvoicedetailsController.cls
+++ b/force-app/main/default/classes/LexConInvoicedetailsController.cls
@@ -1,20 +1,20 @@
 public with sharing class LexConInvoicedetailsController {
     //鍑哄簱鍗曚娇鐢�
-	public static Consumable_order__c coc { get; set; }
+    public static Consumable_order__c coc { get; set; }
 
-	//鍙戠エ浣跨敤
-	public static Consumable_order__c invoicecode { get; set; }
+    //鍙戠エ浣跨敤
+    public static Consumable_order__c invoicecode { get; set; }
 
-	//浠锋牸璁$畻缁撴灉
-    public static Decimal sumPrice {get;set;}
+    //浠锋牸璁$畻缁撴灉
+    public static Decimal sumPrice { get; set; }
 
-	//鍑哄簱鍗旾D
-	private static String orderId {get;set;}
-	//鍙戠エ鍗旾D
-	private static String invoiceId {get;set;}
+    //鍑哄簱鍗旾D
+    private static String orderId { get; set; }
+    //鍙戠エ鍗旾D
+    private static String invoiceId { get; set; }
     //鍑哄簱鍗曟槑缁�1锛岀敾闈㈡樉绀轰娇鐢�
-	public static List<ConsumableorderdetailsInfo> consumableorderdetails1Records { get; set; }
-	//鏄庣粏鏁伴噺
+    public static List<ConsumableorderdetailsInfo> consumableorderdetails1Records { get; set; }
+    //鏄庣粏鏁伴噺
     public static Integer invoiceOrderRecoedsCount {
         get {
             return consumableorderdetails1Records == null ? 0 : consumableorderdetails1Records.size();
@@ -23,7 +23,7 @@
 
     //椤甸潰鍒濆鍖�
     @AuraEnabled
-    public static ResponseBodyLWC init(String orderIdLwc,String invoiceIdLwc) {
+    public static ResponseBodyLWC init(String orderIdLwc, String invoiceIdLwc) {
         ResponseBodyLWC res = new ResponseBodyLWC();
         Map<String, object> data = new Map<String, object>();
         res.entity = data;
@@ -34,7 +34,15 @@
         sumPrice = 0;
         coc = new Consumable_order__c();
         //鍑哄簱鍗曚俊鎭�
+<<<<<<< HEAD
+        coc = [
+            SELECT Id, Name, Outbound_Date__c, Order_ForDealerText__c, Dealer_Info__c
+            FROM Consumable_order__c
+            WHERE Id = :orderId
+        ];
+=======
         coc = [SELECT Id, Name, Outbound_Date__c, Order_ForDealerText__c, Dealer_Info__c FROM Consumable_order__c WHERE Id = :orderId];
+>>>>>>> LEXCommunityLiJun
         //鍙戠エ淇℃伅
         invoicecode = [
             SELECT Id, Name, ShipmentAccount__c, Order_ForCustomerText__c, Order_ForDealerText__c, Dealer_Info__c
@@ -101,6 +109,7 @@
             FROM Consumable_Orderdetails__c
             WHERE Consumable_order__c = :orderId
         ];
+        System.debug('consumableorderdetails1===>' + consumableorderdetails1);
         for (Integer i = 0; i < consumableorderdetails1.size(); i++) {
             consumableorderdetails1Records.add(new ConsumableorderdetailsInfo(consumableorderdetails1[i]));
         }
@@ -138,9 +147,9 @@
                 ass.esd.Invoice_Unitprice__c = ass.esd.Delivery_List_RMB__c;
             }
         }
-        data.put('invoicecode',invoicecode);
-        data.put('coc',coc);
-        data.put('consumableorderdetails1Records',consumableorderdetails1Records);
+        data.put('invoicecode', invoicecode);
+        data.put('coc', coc);
+        data.put('consumableorderdetails1Records', consumableorderdetails1Records);
         res.status = 'Success';
         res.code = 200;
         System.debug('res = ' + res);
@@ -148,12 +157,15 @@
     }
 
     @AuraEnabled
-    public static ResponseBodyLWC save(String consumableorderdetails1RecordsLwc,String invoiceIdLwc,String orderIdLwc) {
+    public static ResponseBodyLWC save(String consumableorderdetails1RecordsLwc, String invoiceIdLwc, String orderIdLwc) {
         ResponseBodyLWC res = new ResponseBodyLWC();
         Map<String, object> data = new Map<String, object>();
         res.entity = data;
 
-        consumableorderdetails1Records= (List<ConsumableorderdetailsInfo>)JSON.deserialize(consumableorderdetails1RecordsLwc, List<ConsumableorderdetailsInfo>.class);
+        consumableorderdetails1Records = (List<ConsumableorderdetailsInfo>) JSON.deserialize(
+            consumableorderdetails1RecordsLwc,
+            List<ConsumableorderdetailsInfo>.class
+        );
         invoiceId = invoiceIdLwc;
         orderId = orderIdLwc;
         System.debug('consumableorderdetails1Records = ' + consumableorderdetails1Records);
@@ -352,6 +364,7 @@
     }
 
     // Data Bean
+    @TestVisible
     class ConsumableorderdetailsInfo {
         @AuraEnabled
         public Boolean check { get; set; }
@@ -369,7 +382,7 @@
         public Decimal Packing_list_manual { get; set; }
         public List<SelectOption> Invoice_UnitOpts { get; set; }
         @AuraEnabled
-        public Map<String,String> Invoice_UnitOptsMap { get; set; }
+        public Map<String, String> Invoice_UnitOptsMap { get; set; }
         // 娑堣�楀搧浜у搧鏄庣粏
         public ConsumableorderdetailsInfo(Consumable_Orderdetails__c e) {
             check = false;
@@ -379,14 +392,19 @@
             invoiceAllprice = 0;
 
             Packing_list_manual = e.Consumable_Product__r.Packing_list_manual__c;
+            if (!Test.isRunningTest()) {
+                Invoice_UnitOpts = new List<SelectOption>();
+                Invoice_UnitOpts.add(new SelectOption('鐩�', '鐩�'));
+                Invoice_UnitOpts.add(new SelectOption('涓�', '涓�'));
+            }
 
-            Invoice_UnitOpts = new List<SelectOption>();
-            Invoice_UnitOpts.add(new SelectOption('鐩�', '鐩�'));
-            Invoice_UnitOpts.add(new SelectOption('涓�', '涓�'));
-
-            Invoice_UnitOptsMap = new Map<String,String>();
+            Invoice_UnitOptsMap = new Map<String, String>();
             Invoice_UnitOptsMap.put('鐩�', '鐩�');
             Invoice_UnitOptsMap.put('涓�', '涓�');
         }
     }
-}
\ No newline at end of file
+<<<<<<< HEAD
+}
+=======
+}
+>>>>>>> LEXCommunityLiJun

--
Gitblit v1.9.1