From 6dde84354d1679817df4b38cada7aa32dad1db5e Mon Sep 17 00:00:00 2001
From: liwentao <1376563863@qq.com>
Date: 星期一, 07 八月 2023 17:59:01 +0800
Subject: [PATCH] 营业 客户详情页面和客户变更申请页面
---
force-app/main/default/lwc/lexTenderingLostButton/lexTenderingLostButton.js | 21 ++++++++++++---------
1 files changed, 12 insertions(+), 9 deletions(-)
diff --git a/force-app/main/default/lwc/lexTenderingLostButton/lexTenderingLostButton.js b/force-app/main/default/lwc/lexTenderingLostButton/lexTenderingLostButton.js
index ff5d294..be9daf2 100644
--- a/force-app/main/default/lwc/lexTenderingLostButton/lexTenderingLostButton.js
+++ b/force-app/main/default/lwc/lexTenderingLostButton/lexTenderingLostButton.js
@@ -6,9 +6,11 @@
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
export default class lexTenderingLostButton extends LightningElement {
@api recordId;//褰撳墠杩欐潯鏁版嵁鐨刬d
- id;//杩斿洖鍊肩殑id Tender_information__c鎷涙爣椤圭洰鐨刬d
status;//鐘舵��
profileId;//profileId id
+ systemProfileId;
+ TwoS1_Sales_Hospital;
+ TwoS4_Sales_Manager;
IsLoading = true;
@wire(CurrentPageReference)
@@ -28,19 +30,21 @@
recordId: this.recordId
}).then(result => {
this.IsLoading = false;
- this.id = result.Id;
this.status = result.status;
- this.profileId = result.profileId.slice(0,15);
+ this.profileId = result.profileId;
+ this.systemProfileId = result.systemProfileId;
+ this.TwoS1_Sales_Hospital = result.TwoS1_Sales_Hospital;
+ this.TwoS4_Sales_Manager = result.TwoS4_Sales_Manager;
this.LoseButton();
this.dispatchEvent(new CloseActionScreenEvent());
})
}
- //鎷涙爣椤圭洰澶卞崟
+ //鎷涙爣椤圭洰 澶卞崟
LoseButton(){
- sqlResult({id: this.id}).then(result=>{
+ sqlResult({id: this.recordId}).then(result=>{
//绠�妗f潈闄� 2S1_閿�鍞尰闄㈡媴褰� 2S4_閿�鍞鐞嗚�� 绯荤粺绠$悊鍛�
- if (this.profileId != '00e10000000xnp2' && this.profileId != '00e10000000xnpH' && this.profileId != '00e10000000Y3o5') {
+ if (this.profileId != this.TwoS1_Sales_Hospital && this.profileId != this.TwoS4_Sales_Manager && this.profileId != this.systemProfileId) {
this.showToast("鎮ㄦ病鏈夋潈闄愶紝鏃犳硶鍒涘缓璇环鎻愪氦澶卞崟銆�","error");
return;
}
@@ -57,7 +61,7 @@
return;
}
}
- window.open(`/apex/TenderLostPage?id=${this.id}`,'','height=500,width=800,top=200,left=250,location=no');
+ window.open(`/apex/TenderLostPage?id=${this.recordId}`,'','height=500,width=800,top=200,left=250,location=no');
})
}
showToast(msg,type) {
@@ -66,6 +70,5 @@
variant: type
});
this.dispatchEvent(event);
- this.dispatchEvent(new CloseActionScreenEvent());
}
-}
\ No newline at end of file
+}
--
Gitblit v1.9.1