From 3affb8b01f55f90cc047d3048e4ec04aad249e9d Mon Sep 17 00:00:00 2001
From: chenjingwu <chenjingwu@prec-tech.com>
Date: 星期二, 23 四月 2024 09:56:47 +0800
Subject: [PATCH] 123
---
force-app/main/default/pages/ImprovedForecastTime.page | 16 +++++++++++++---
1 files changed, 13 insertions(+), 3 deletions(-)
diff --git a/force-app/main/default/pages/ImprovedForecastTime.page b/force-app/main/default/pages/ImprovedForecastTime.page
index b22d112..a3f9787 100644
--- a/force-app/main/default/pages/ImprovedForecastTime.page
+++ b/force-app/main/default/pages/ImprovedForecastTime.page
@@ -3,10 +3,12 @@
<div style="width:100%;height:100%;" id="ImprovedForecastTimeApp" />
<script>
- $Lightning.use("c:ImprovedForecastTimeApp", function () {
+ $Lightning.use("c:ImprovedForecastTimeAura", function () {
$Lightning.createComponent("c:ImprovedForecastTime",
- {},
- "ImprovedForecastTimeApp",
+ {
+ "recordId": getParam('id')
+ },
+ "ImprovedForecastTimeAura",
function (cmp) {
console.log('Component created, do something cool here');
});
@@ -21,6 +23,14 @@
clearInterval(interval);
}
},1000);
+ function getParam(paramName) {
+ paramValue = "", isFound = !1;
+ if (this.location.search.indexOf("?") == 0 && this.location.search.indexOf("=") > 1) {
+ arrSource = decodeURI(this.location.search).substring(1, this.location.search.length).split("&"), i = 0;
+ while (i < arrSource.length && !isFound) arrSource[i].indexOf("=") > 0 && arrSource[i].split("=")[0].toLowerCase() == paramName.toLowerCase() && (paramValue = arrSource[i].split("=")[1], isFound = !0), i++
+ }
+ return paramValue == "" && (paramValue = null), paramValue;
+ }
</script>
</apex:page>
\ No newline at end of file
--
Gitblit v1.9.1