Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in / Register
Toggle navigation
T
topikm6-script-demos
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Leon Li
topikm6-script-demos
Commits
08528023
Commit
08528023
authored
Mar 31, 2020
by
Leon Li
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add new file
parent
e00643b0
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
43 additions
and
0 deletions
+43
-0
sap.js
src/sap.js
+43
-0
No files found.
src/sap.js
0 → 100644
View file @
08528023
var
xhr
=
new
XMLHttpRequest
;
var
user
=
"webservice"
;
var
password
=
"654321"
;
xhr
.
setRequestHeader
(
"Content-Type"
,
"text/xml;charset=UTF-8"
);
xhr
.
setRequestHeader
(
"Authorization"
,
"Basic "
+
TDataParse
.
encodeBase64
(
user
+
":"
+
password
));
var
url
=
"http://58.20.243.15:8068/sap/bc/srt/rfc/sap/zfmpp_vbeln/710/zfmpp_vbeln/zfmpp_vbeln_binding"
;
var
werks
=
1002
;
var
body
=
"
\
<soapenv:Envelope xmlns:soapenv=
\"
http://schemas.xmlsoap.org/soap/envelope/
\"
xmlns:urn=
\"
urn:sap-com:document:sap:soap:functions:mc-style
\"
>
\
<soapenv:Header/>
\
<soapenv:Body>
\
<urn:ZfmppVbeln>
\
<EtOutput>
\
<item>
\
<Werks></Werks>
\
<Zgpcno></Zgpcno>
\
<Zvkaus></Zvkaus>
\
<Matnr></Matnr>
\
<Maktx></Maktx>
\
<Verid></Verid>
\
<Zdtcmj></Zdtcmj>
\
<Zsetc></Zsetc>
\
<Zsetk></Zsetk>
\
<Zbcly></Zbcly>
\
<Z1stpcs></Z1stpcs>
\
<Kwmeng1></Kwmeng1>
\
<Erdat></Erdat>
\
<Edatu></Edatu>
\
<Zjhtlrq></Zjhtlrq>
\
<Zbcgys></Zbcgys>
\
<Zbclx></Zbclx>
\
</item>
\
</EtOutput>
\
<Werks>{0}</Werks>
\
</urn:ZfmppVbeln>
\
</soapenv:Body>
\
</soapenv:Envelope>
\
"
;
body
=
_
.
format
(
body
,
werks
);
xhr
.
open
(
"POST"
,
url
,
false
);
xhr
.
send
(
body
);
print
(
xhr
.
status
);
print
(
xhr
.
responseText
);
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment