Upload
dsgurushantha
View
33
Download
6
Embed Size (px)
DESCRIPTION
Var SToken
Citation preview
var sToken = "", oControl = this; this._objects.oModel.refreshSecurityToken(function(e, o) { sToken = oControl._objects.oModel.getSecurityToken(); }, function(e) { oControl._showErrorMessage($(e.response.body).find("message").first().text(), "") ; }, false); return sToken;
onInit : function() {
this._properties = {
objectKey : "",
objectType : "",
documentPart: "",
documentVersion: "",
documentNumber: "",
documentType: "",
mode : "",
visibleEdit: false,
visibleDelete: false
};
this._objects = {
oModel : undefined
};
this._objects.oModel = new sap.ui.model.odata.ODataModel("/sap/opu/odata/sap/CV_ATTACHMENT_SRV", true);
this._objects.oResModel = new sap.ui.model.resource.ResourceModel({ bundleUrl : jQuery.sap.getModulePath("sap.se.mi.plm.lib.attachmentservice.attachment") + "/i18n/i18n.properties" });
},