From 8db20630a2675ca14e03ccdee91c614397b5c964 Mon Sep 17 00:00:00 2001 From: 高章伟 <gaozhangwei@prec-tech.com> Date: 星期四, 10 三月 2022 16:21:46 +0800 Subject: [PATCH] 最近一月修改内容 --- force-app/main/default/aura/RetrospectiveWeeklyReport/RetrospectiveWeeklyReportHelper.js | 51 ++++++++++++++++++++++++++------------------------- 1 files changed, 26 insertions(+), 25 deletions(-) diff --git a/force-app/main/default/aura/RetrospectiveWeeklyReport/RetrospectiveWeeklyReportHelper.js b/force-app/main/default/aura/RetrospectiveWeeklyReport/RetrospectiveWeeklyReportHelper.js index bacadec..e177114 100644 --- a/force-app/main/default/aura/RetrospectiveWeeklyReport/RetrospectiveWeeklyReportHelper.js +++ b/force-app/main/default/aura/RetrospectiveWeeklyReport/RetrospectiveWeeklyReportHelper.js @@ -237,14 +237,14 @@ var report_id = component.get('v.edit_copy_select_report_id'); if (report_id != "") { var select_EffectProgress1 = ''; - var OtherBrandConsumables = ''; + var WarlockClassification = ''; var ProductCcategory = ''; var productCategories = ''; var i = 0; for (i = 0; i < reports.length; i++) { if (report_id == reports[i]["Id"]) { select_EffectProgress1 = reports[i]["EffectProgress__c"]; - OtherBrandConsumables = reports[i]["OtherBrandConsumables__c"]; + WarlockClassification = reports[i]["WarlockClassification__c"]; ProductCcategory = reports[i]["ProductCcategory__c"]; productCategories = reports[i]["productCategories__c"]; break; @@ -255,8 +255,8 @@ component.find('select_EffectProgress').set('v.value', select_EffectProgress1); } //鏈+鍒嗙被 - if (OtherBrandConsumables != null && OtherBrandConsumables != '') { - component.find('select_OtherBrandConsumables').set('v.value', OtherBrandConsumables); + if (WarlockClassification != null && WarlockClassification != '') { + component.find('select_OtherBrandConsumables').set('v.value', WarlockClassification); } //宸查噰鐢ㄥ叾浠栧搧鐗� if (ProductCcategory != null && ProductCcategory != '') { @@ -283,7 +283,7 @@ var doctor2__c = component.find('select_doctor').get('v.value'); var WorkRecord__c = component.find('select_purpose_type').get('v.value'); var EffectProgress__c = component.find('select_EffectProgress').get('v.value'); - var OtherBrandConsumables__c = component.find('select_OtherBrandConsumables').get('v.value'); + var WarlockClassification__c = component.find('select_OtherBrandConsumables').get('v.value'); var ProductCcategory__c = component.find('select_ProductCcategory').get('v.value'); var productCategories__c = component.find('select_productCategories').get('v.value'); var warlocksNumber__c = component.find('select_warlocksNumber').get('v.value'); @@ -301,7 +301,7 @@ !DealerPersonnel__c && !doctor2__c && !EffectProgress__c && - !OtherBrandConsumables__c && + !WarlockClassification__c && !ProductCcategory__c && !productCategories__c && !warlocksNumber__c && @@ -327,7 +327,7 @@ select_report_data['DealerPersonnel__c'] == DealerPersonnel__c && select_report_data['doctor2__c'] == doctor2__c && select_report_data['EffectProgress__c'] == EffectProgress__c && - select_report_data['OtherBrandConsumables__c'] == OtherBrandConsumables__c && + select_report_data['WarlockClassification__c'] == WarlockClassification__c && select_report_data['ProductCcategory__c'] == ProductCcategory__c && select_report_data['productCategories__c'] == productCategories__c && select_report_data['warlocksNumber__c'] == warlocksNumber__c && @@ -352,7 +352,7 @@ select_report_data['DealerPersonnel__c'] == DealerPersonnel__c && select_report_data['doctor2__c'] == doctor2__c && select_report_data['EffectProgress__c'] == EffectProgress__c && - select_report_data['OtherBrandConsumables__c'] == OtherBrandConsumables__c && + select_report_data['WarlockClassification__c'] == WarlockClassification__c && select_report_data['ProductCcategory__c'] == ProductCcategory__c && select_report_data['productCategories__c'] == productCategories__c && select_report_data['warlocksNumber__c'] == warlocksNumber__c && @@ -512,8 +512,8 @@ var EffectProgress__c = component.find('select_EffectProgress').get('v.value'); // 绉戝鍚屾潵鑰楁潗鏈堜娇鐢ㄩ噺 ConsumptionOfConsumables__c var ConsumptionOfConsumables__c = component.find('select_ConsumptionOfConsumables').get('v.value'); - // 鏈+鍒嗙被 OtherBrandConsumables__c - var OtherBrandConsumables__c = component.find('select_OtherBrandConsumables').get('v.value'); + // 鏈+鍒嗙被 WarlockClassification__c + var WarlockClassification__c = component.find('select_OtherBrandConsumables').get('v.value'); // 宸查噰鐢ㄥ叾浠栧搧鐗� ProductCcategory__c var ProductCcategory__c = component.find('select_ProductCcategory').get('v.value'); // 鍏朵粬鍝佺墝浜у搧绫诲埆 productCategories__c @@ -563,7 +563,7 @@ if (!EffectProgress__c) { error.push("鏁堟灉/杩涘害 涓嶅瓨鍦�"); } // if (!OtherBrandConsumables__c) { error.push("鏈+鍒嗙被 涓嶅瓨鍦�"); } if (!ProductCcategory__c) { error.push("宸查噰鐢ㄥ叾浠栧搧鐗� 涓嶅瓨鍦�"); } - if (!productCategories__c) { error.push("浜у搧绫诲埆 涓嶅瓨鍦�"); } + // if (!productCategories__c) { error.push("鍏朵粬鍝佺墝浜у搧绫诲埆 涓嶅瓨鍦�"); } if (!ConsumptionOfConsumables__c) { error.push("绉戝鍚岀被鑰楁潗鏈堜娇鐢ㄩ噺 涓嶈兘涓虹┖"); } if (!warlocksNumber__c) { error.push("浜у搧鐢ㄩ噺 涓嶈兘涓虹┖"); } for (var i = 0; i < error.length; i++) { @@ -585,7 +585,7 @@ "ConsumptionOfConsumables": ConsumptionOfConsumables__c, "WorkRecord": WorkRecord__c, "EffectProgress": EffectProgress__c, - "OtherBrandConsumables" : OtherBrandConsumables__c, + "WarlockClassification" : WarlockClassification__c, "ProductCcategory" : ProductCcategory__c, "productCategories" : productCategories__c, "warlocksNumber" : warlocksNumber__c, @@ -646,7 +646,7 @@ "DealerPersonnel": DealerPersonnel__c, "ProductCcategory" : ProductCcategory__c, "productCategories" : productCategories__c, - "OtherBrandConsumables" : OtherBrandConsumables__c, + "WarlockClassification" : WarlockClassification__c, "ProductClassification": ProductClassification__c, "WorkRecord": WorkRecord__c, "EffectProgress": EffectProgress__c, @@ -1441,7 +1441,7 @@ } columnDivider = ','; lineDivider = '\n'; - keys = ['Submit_date__c', 'Person_In_Charge2__c', 'Report_Date__c', 'Agency_Hospital__c','Department_Cateogy__c','DealerPersonnel__c','WorkRecord__c','doctor2__c','ProductClassification__c','UseProduct1__c', 'UseProduct2__c','UseProduct3__c', 'EffectProgress__c','ConsumptionOfConsumables__c', 'OtherBrandConsumables__c', 'ProductCcategory__c', 'productCategories__c','warlocksNumber__c','WorkMark__c']; + keys = ['Submit_date__c', 'Person_In_Charge2__c', 'Report_Date__c', 'Agency_Hospital__c','Department_Cateogy__c','DealerPersonnel__c','WorkRecord__c','doctor2__c','ProductClassification__c','UseProduct1__c', 'UseProduct2__c','UseProduct3__c', 'EffectProgress__c','ConsumptionOfConsumables__c', 'WarlockClassification__c', 'ProductCcategory__c', 'productCategories__c','warlocksNumber__c','WorkMark__c']; thkeys = ['鍛�', '鎷呭綋', '娲诲姩鏃�', '鍖婚櫌', '绉戝', '缁忛攢鍟嗕汉鍛�', '宸ヤ綔璁板綍', '鍖婚櫌浜哄憳','浜у搧鍒嗙被(绗笁鍒嗙被)', '浣跨敤浜у搧1(浜у搧鍨嬪彿)', '浣跨敤浜у搧2','浣跨敤浜у搧3','鏁堟灉/杩涘害','绉戝鍚岀被鑰楁潗鏈堜娇鐢ㄩ噺','鏈+鍒嗙被','宸查噰鐢ㄥ叾浠栧搧鐗�','鍏朵粬鍝佺墝浜у搧绫诲埆','浜у搧鐢ㄩ噺','宸ヤ綔鏍囪'] csvStringResult = ''; csvStringResult += thkeys.join(columnDivider); @@ -1473,13 +1473,13 @@ } else if (skey == 'UseProduct3__c') { csvStringResult += objectRecords[i].UseProduct3__r.Name; } else if (skey == 'EffectProgress__c'){ - csvStringResult += objectRecords[i].EffectProgress__r.Name; - }else if (skey == 'OtherBrandConsumables__c'){ - csvStringResult += objectRecords[i].OtherBrandConsumables__r.Name; + csvStringResult += objectRecords[i].EffectProgress__r.EffectProgress__c; + }else if (skey == 'WarlockClassification__c'){ + csvStringResult += objectRecords[i].WarlockClassification__r.WarlockClassification__c; }else if(skey == 'ProductCcategory__c'){ - csvStringResult += objectRecords[i].ProductCcategory__r.Name; + csvStringResult += objectRecords[i].ProductCcategory__r.ProductCcategory__c; }else if(skey == 'productCategories__c'){ - csvStringResult += objectRecords[i].productCategories__r.Name; + csvStringResult += objectRecords[i].productCategories__r.productCategories__c; }else{ csvStringResult += objectRecords[i][skey] ; } @@ -1493,7 +1493,7 @@ // 瀵煎嚭椤甸潰鏄剧ず鐨勬ā鏉� showExportDate: function (component, objectRecords) { console.log('杩涘叆showexceportdate' + objectRecords); - var keys = ['Submit_date__c', 'Person_In_Charge2__c', 'Report_Date__c', 'Agency_Hospital__c','Department_Cateogy__c','DealerPersonnel__c','WorkRecord__c','doctor2__c','ProductClassification__c','UseProduct1__c', 'UseProduct2__c','UseProduct3__c', 'EffectProgress__c','ConsumptionOfConsumables__c', 'OtherBrandConsumables__c', 'ProductCcategory__c','productCategories__c', 'warlocksNumber__c','WorkMark__c']; + var keys = ['Submit_date__c', 'Person_In_Charge2__c', 'Report_Date__c', 'Agency_Hospital__c','Department_Cateogy__c','DealerPersonnel__c','WorkRecord__c','doctor2__c','ProductClassification__c','UseProduct1__c', 'UseProduct2__c','UseProduct3__c', 'EffectProgress__c','ConsumptionOfConsumables__c', 'WarlockClassification__c', 'ProductCcategory__c','productCategories__c', 'warlocksNumber__c','WorkMark__c']; var headers = ['鍛�', '鎷呭綋', '娲诲姩鏃�', '鍖婚櫌', '绉戝', '缁忛攢鍟嗕汉鍛�', '宸ヤ綔璁板綍', '鍖婚櫌浜哄憳','浜у搧鍒嗙被(绗笁鍒嗙被)', '浣跨敤浜у搧1(浜у搧鍨嬪彿)', '浣跨敤浜у搧2','浣跨敤浜у搧3','鏁堟灉/杩涘害','绉戝鍚岀被鑰楁潗鏈堜娇鐢ㄩ噺','鏈+鍒嗙被','宸查噰鐢ㄥ叾浠栧搧鐗�','鍏朵粬鍝佺墝浜у搧绫诲埆','浜у搧鐢ㄩ噺','宸ヤ綔鏍囪'] var content = "<table class=\"table slds-table slds-table--bordered slds-table--cell-buffer\">"; content += "<thead><tr class=\"slds-text-title--caps\">"; @@ -1527,13 +1527,13 @@ } else if (skey == 'UseProduct3__c') { content += '<td>' + objectRecords[i].UseProduct3__r.Name + '</td>'; } else if (skey == 'EffectProgress__c'){ - content += '<td>' + objectRecords[i].EffectProgress__r.Name + '</td>'; - }else if (skey == 'OtherBrandConsumables__c'){ - content += '<td>' + objectRecords[i].OtherBrandConsumables__r.Name + '</td>'; + content += '<td>' + objectRecords[i].EffectProgress__r.EffectProgress__c + '</td>'; + }else if (skey == 'WarlockClassification__c'){ + content += '<td>' + objectRecords[i].WarlockClassification__r.WarlockClassification__c + '</td>'; }else if (skey == 'ProductCcategory__c'){ - content += '<td>' + objectRecords[i].ProductCcategory__r.Name + '</td>'; + content += '<td>' + objectRecords[i].ProductCcategory__r.ProductCcategory__c + '</td>'; }else if (skey == 'productCategories__c'){ - content += '<td>' + objectRecords[i].productCategories__r.Name + '</td>'; + content += '<td>' + objectRecords[i].productCategories__r.productCategories__c + '</td>'; }else{ content += '<td>' + objectRecords[i][skey] + '</td>'; } @@ -1703,6 +1703,7 @@ //宸ヤ綔浼氳褰� selectPurposeType: function (component,event,helper) { var doctor_value = component.find('select_purpose_type').get('v.value'); + alert(doctor_value); if(doctor_value != ''){ var action = component.get('c.selectPurposeTypes'); action.setParams({ -- Gitblit v1.9.1