Li Jun
2022-04-19 2f183a6b0a83ec3f7d35375d5d25d200efc2a3e1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
<?xml version="1.0" encoding="UTF-8"?>
<WebLink xmlns="http://soap.sforce.com/2006/04/metadata">
    <fullName>Yanshoudan_request</fullName>
    <availability>online</availability>
    <displayType>button</displayType>
    <linkType>javascript</linkType>
    <masterLabel>验收单回收申请</masterLabel>
    <openType>onClickJavaScript</openType>
    <protected>false</protected>
    <url>{!RequireScript(&quot;/soap/ajax/51.0/connection.js&quot;)} 
{!RequireScript(&quot;/resource/CommonUtilJs&quot;)} 
//2021-10-21 gwy 版本更改为51.0
var rac = new sforce.SObject(&quot;Repair__c&quot;); 
rac.Id = &quot;{!Repair__c.Id}&quot;; 
rac.Request_yanshoudan_PDF__c = true; 
var serverTimestamp = sforce.connection.getServerTimestamp(); 
rac.Facility_Return_Receipt_Collection_reque__c = serverTimestamp.timestamp; 
 
var result = sforce.connection.update([rac]); 
var messages = getConnectDMLErrorMessages(result); 
if (messages.length &gt; 0) { 
    alert(messages.join(&quot;\n已经申请过了,不允许重新申请&quot;)); 
location.reload();</url>
</WebLink>