当前位置:网站首页>Attachment handling of SAP Fiori
Attachment handling of SAP Fiori
2022-07-25 16:24:00 【Jerry Wang】
With SAP CRM Fiori Application, for example . Attachment processing has two levels , That is to say Fiori UI Show attachments on ( Read operation ), And by Fiori UI Create attachments ( Write operation ).
Attachment The read
As shown in the figure below , Click any Attachment Hyperlinks ,
That is, automatically open the browser download window .
It's time to OData Corresponding implementation system , such as AG3 backstage , Things code SEGW, open CRM_OPPORTUNITY OData project , Create a file called Opportunity_Attachments Of association, Point to a name OpportunityAttachment Of Dependent Entity.
Opportunity and OpportunityAttachment The relationship between models is 0:n, That is, a Opportunity It's not allowed to attachment, Multiple attachment.
Attachment Model fields for :
We can do it in AG3 To set breakpoints , debugging attachment Read requests for :
Fiori UI Put what you want to read attachment The instance information passes through SAP UI5 Pass the code to the background ABAP:
Last call CL_CRM_OPPORTUNITY_DPC_EXT~GET_STREAM Methods from AG3/001 Read attachment data on the system :
Fiori The front desk is S3.view.xml It uses UploadCollection Control to display attachments .
When Attachment When the tab is clicked , Trigger attachmentsTabSelected Method :
In this method , Manual call OData API Initiate reading data to the background OData request :
var info = this.getView().byId('info');
var headerGuid = info.getModel('json').getData().Guid;
var oModel = this.oModel;
var sPath = this.sPath;
// get the list to set the post url param
var that = this.getView();
oModel.read(sPath, null, [
"$expand=Attachments"
], true, jQuery.proxy(function(odata, response) {
var data = {
OpportunityAttachments: []
};
var length = response.data.Attachments.results.length;Attachment The creation of
Click on + Icon , Choose a file to upload locally :
SAP UI5 Control can display the uploaded progress bar :
Trigger the background CL_CRM_OPPORTUNITY_DPC_EXT~CREATE_STREAM Method :
CREATE_STREAM Method to create a flow ( Media resources ) And corresponding entities ( Media link entries ). Additional information can be found in Slug In the head . The layout of creating media link entries is performed first HTTP Post, It only contains binary data . Be careful , It is not allowed to publish the item itself first , Then release relevant media resources . be based on Slug head , Developers can pass additional information to the server , for example , The server can be used to store binaries ( Media resources ) And create entities ( Media link entries ) Created framework . Newly created entity ( Media link entries ) stay HTTP The response is sent back to the user , The response can be updated with appropriate data . The updated entry will be in HTTP Put Send to SAP NetWeaver Gateway System , To complete the creation of media resources / The process of media link entries .
边栏推荐
- mysql 表读锁
- Typescript learning 2 - Interface
- Paper notes: highly accurate protein structure prediction with alphafold (alphafold 2 & appendix)
- 伦敦银K线图的各种有用形态
- Product dynamics - Android 13 high-efficiency adaptation new upgrade
- 0x80131500打不开微软商店的解决办法
- MyBaits
- [JS advanced] JS regular correlation functions and regular objects_ 02
- Understanding service governance in distributed development
- Which led display manufacturer is better
猜你喜欢

泰雷兹推出解决方案,助力SAP客户控制云端数据

Communication between processes (pipeline details)

狂神redis笔记12
![[image denoising] image denoising based on bicube interpolation and sparse representation matlab source code](/img/39/716c62d6ca533a7e84704b2c55d072.png)
[image denoising] image denoising based on bicube interpolation and sparse representation matlab source code

Upgrade esxi6.7.0 to 7.0u3f (updated on July 12, 2022)

Product upgrade observation station in June

How does win11's own drawing software display the ruler?

Today, I went to oppo for an interview and was asked numbly

Verifiable random function VRF

今天去 OPPO 面试,被问麻了
随机推荐
Communication between processes (pipeline details)
Solve win10 disk occupation of 100%
新增批量删除
Food safety - do you really understand the ubiquitous frozen food?
MySQL-自增锁
Mqtt x cli officially released: powerful and easy-to-use mqtt 5.0 command line tool
进程之间的通信(管道详解)
Doget and dopost
MySQL页锁
MySQL intent lock
tkinter模块高级操作(一)—— 透明按钮、透明文本框、自定义按钮及自定义文本框
Pagehelper.startpage is not effective
墨天轮高分技术文档分享——数据库安全篇(共48个)
Analysis and solution of data and clock mismatch delay in SPI transmission
02. Limit the parameter props to a list of types
食品安全丨无处不在的冷冻食品,你真的了解吗?
MySQL global lock
Baidu rich text editor ueeditor image width 100% adaptive, mobile terminal
【图像隐藏】基于混合 DWT-HD-SVD 的数字图像水印方法技术附matlab代码
微信小程序不使用插件,渲染富文本中的视频,图片自适应,plus版本