美文网首页SAPSAP 实用篇SAP 修行
SAP C4C HTML Mashup initializePa

SAP C4C HTML Mashup initializePa

作者: _扫地僧_ | 来源:发表于2020-03-20 08:47 被阅读0次

    在Cloud Application Studio里创建的HTML mashup,保存到C4C后台后,其元数据再被读取到前端消费,格式如下:


    我在C4C UI上指定的Mashup参数,URL的值如下:

    成功解析出input为Lead_Info_In:


    没有按照我期望的情形进行执行:


    MashupHTMLContainer.prototype.initializePane = function() {
            var oController = this.getController();
            var oModel = oController.getComponentModel();
            var oEmbeddingcontext = oController.getEmbeddingContext();
            this._oHtmlPage.setController(oController);
            if (oModel) {
                this._createMashupModel(oModel._oData, oEmbeddingcontext);
                // checks if mashup has an inport or not
                if (this._sInport) {
                    // creates inport adapter and attaches it to inport events
                    this._oInportAdapter = new InportAdapter(this._sInport, oController, true);
                    this._oInportAdapter.on("inportFired", $.proxy(this._onInPortFired, this));
    
                    if (!this._oMashupModel.hasHtmlCode()) {
                        // inport and source uri --> fire inport to build complete source uri
                        this._oInportAdapter.refire();
                        if (this._sInport === "ExtensionFieldsInPort") {
                            this._getSourceUriFromModel(this._oMashupModel);
                        }
                    }
                } else {
                    // no inport and no html content --> source uri already valid
                    if (!this._oMashupModel.hasHtmlCode()) {
                        this._getSourceUriFromModel(this._oMashupModel);
                    }
                }
            }
        };
    

    没有执行这个refire:

    解析出来的aTargets为空:

    要获取更多Jerry的原创文章,请关注公众号"汪子熙":


    相关文章

      网友评论

        本文标题:SAP C4C HTML Mashup initializePa

        本文链接:https://www.haomeiwen.com/subject/imllyhtx.html