Projet

Général

Profil

Anomalie #5928

[Account/Multiple/Ask] Message d'erreur dans les logs qui n'affecte pas l'utilisation

Ajouté par Charles Bonnissent il y a plus de 3 ans. Mis à jour il y a plus de 3 ans.

Statut:
Intégré
Priorité:
Normal
Assigné à:
Version cible:
Début:
20/11/2015
Echéance:
% réalisé:

100%

Version source:
Solution proposée:
Principaux fichiers impactés:
Complexité:
Contrôle:
Régression:
Non
Thèmes UIs:
Widget
Jalons: 3.2 R17, 3.2 R18

Description

Lors de la saisie d'un account multiple dans un ask, on a le message suivant :

 ## Message : Cannot read property 'length' of null ## Context : ## URL : http://localhost/?app=DOCUMENT&initid=1198&viewId=!defaultConsultation ## BrowserUserAgent : Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2490.86 Safari/537.36 ##User : Jos\xc3\xa9e BOUCHER(#16) ## Stack : Array ( [0] => Array ( [url] => http://localhost/lib/TraceKit/tracekit.js?ws=3252 [line] => 235 [func] => [context] => Array ( [0] => lastException = null; [1] => notifyHandlers.apply(null, [stack, null].concat(args)); [2] => } [3] => }, (stack.incomplete ? 2000 : 0)); [4] => [5] => throw ex; // re-throw to propagate to the top level (and cause window.onerror) [6] => } [7] => [8] => report.subscribe = subscribe; [9] => report.unsubscribe = unsubscribe; [10] => return report; ) [column] => ) [1] => Array ( [url] => http://localhost/lib/underscore/underscore.js?ws=3252 [func] => flatten [line] => 474 [column] => 35 [context] => Array ( [0] => // Internal implementation of a recursive `flatten` function. [1] => var flatten = function(input, shallow, strict, output) { [2] => if (shallow && _.every(input, _.isArray)) { [3] => return concat.apply(output, input); [4] => } [5] => for (var i = 0, length = input.length; i < length; i++) { [6] => var value = input[i]; [7] => if (!_.isArray(value) && !_.isArguments(value)) { [8] => if (!strict) output.push(value); [9] => } else if (shallow) { [10] => push.apply(output, value); ) ) [2] => Array ( [url] => http://localhost/lib/underscore/underscore.js?ws=3252 [func] => Function._.flatten [line] => 489 [column] => 12 [context] => Array ( [0] => return output; [1] => }; [2] => [3] => // Flatten out an array, either recursively (by default), or just one level. [4] => _.flatten = function(array, shallow) { [5] => return flatten(array, shallow, false, []); [6] => }; [7] => [8] => // Return a version of the array that does not contain the specified value(s). [9] => _.without = function(array) { [10] => return _.difference(array, slice.call(arguments, 1)); ) ) [3] => Array ( [url] => http://localhost/DOCUMENT/IHM/main-built.js?ws=3252 [func] => i.Model.extend.hasValueChanged [line] => 1 [column] => 4560 [context] => Array ( [0] => define("dcpDocument/routers/router",["underscore","backbone"],function(t,e){return e.Router.extend({initialize:function(e){var i=this;this.document=e.document,this.urlFragmentTemplate=t.template("<%= path %>?app=DOCUMENT&initid=<%= initid %><% if (revision >= 0) { %>&revision=<%= revision %><% } %><% if (viewId) { %>&viewId=<%= viewId %><% } %>"),this.route(/[^?]*\\?app=DOCUMENT([^#]+)/,"fetch"),this.document.listenTo(this.document,"sync",function(){var t=i.document.get("viewId"),e={path:window.location.pathname,initid:i.document.get("initid"),revision:i.document.get("revision")>=0?i.document.get("revision"):void 0,viewId:void 0},n=i.document.getServerProperties();e.viewId=t,n&&"alive"===n.status&&(e.revision=-1),window.dcp&&window.dcp.viewData&&window.dcp.viewData.documentIdentifier===e.initid&&window.dcp.viewData.revision===e.revision&&window.dcp.viewData.vid===e.viewId||e.initid&&i.navigate(i.urlFragmentTemplate(e))})},fetch:function(e){var i,n,o=e.split("&"),s={},r={};for(i=0;i<o.length;i++)n=o[i].split("="),s[n[0]]=decodeURIComponent(n[1]);t.isUndefined(s.id)||(r.initid=s.id),t.isUndefined(s.initid)||(r.initid=s.initid),r.revision=t.isUndefined(s.revision)?-1:parseInt(s.revision,10),r.viewId=t.isUndefined(s.viewId)?void 0:s.viewId,this.document.fetchDocument(r)}})}),define("dcpDocument/models/mDocumentProperties",["underscore","backbone"],function(t,e){return e.Model.extend({typeModel:"ddui:properties"})}),define("dcpDocument/models/mDocumentLock",["underscore","backbone"],function(t,e){var i=t.template("api/v1/documents/<%- initid %>/locks/<%- type %>"),n=t.template("api/v1/documents/<%- initid %>/views/<%- viewId %>/locks/<%- type %>");return e.Model.extend({typeModel:"ddui:lock",idAttribute:"initid",viewId:"",url:function(){return this.get("viewId")?n({initid:this.get("initid"),type:this.get("type"),viewId:this.get("viewId")}):i({initid:this.get("initid"),type:this.get("type")})}})}),define("dcpDocument/models/mFamilyStructure",["underscore","backbone"],function(t,e){return e.Model.extend({typeModel:"ddui:familyStructure",idAttribute:"familyId",url:function(){var e=t.template("api/v1/families/<%- familyId %>/views/structure");return e({familyId:this.get("familyId")})}})}),define("dcpDocument/models/mAttribute",["underscore","jquery","backbone"],function(t,e,i){return i.Model.extend({typeModel:"ddui:attribute",defaults:{title:null,isValueAttribute:!1,parent:void 0,mode:"read",errorMessage:null},initialize:function(){this.listenTo(this,"change:documentMode",this._computeMode),this.listenTo(this,"change:visibility",this._computeMode),this._computeValueMode(),this._computeMode(),this.set("title",this.id+"("+this.get("label")+")"),this.set("errorMessage",null)},toData:function(e,i){var n=this.toJSON();if("undefined"!=typeof e&&null!==e&&this.get("multiple")===!1)throw new Error("You need to be multiple");return t.isNumber(e)&&(n.attributeValue=n.attributeValue?n.attributeValue[e]:null,n.index=e),n.isDisplayable=this.isDisplayable(),n.content=[],this.get("content")&&t.isFunction(this.get("content").toData)&&(n.content=this.get("content").toData()),i&&(n.renderOptions=this.getOptions(),n.labels=n.labels||{},n.locale=this.getDocumentModel().get("locale"),n.templates={},this.getTemplates().attribute&&(n.templates=this.getTemplates().attribute[this.get("type")]?this.getTemplates().attribute[this.get("type")]:this.getTemplates().attribute["default"]),n.deleteButton=!0,n.sourceValues=this.get("enumItems"),n.sourceUri=this.get("enumUri"),n.templates.label=this.getTemplates().attribute.label),n},isDisplayable:function(){if("hidden"===this.get("mode"))return!1;if(this.get("isValueAttribute")){if("read"===this.get("mode"))return null!==this.getOption("showEmptyContent")?!0:this.get("attributeValue")&&null!==this.get("attributeValue").value;if("write"===this.get("mode"))return!0}return 0===this.get("content").length?!1:null===this.getOption("showEmptyContent")?this.get("content").some?this.get("content").some(function(t){return t.isDisplayable()}):!1:!0},hasMultipleOption:function(){return this.attributes.options&&"yes"===this.attributes.options.multiple},isDoubleMultiple:function(){return this.hasMultipleOption()&&"array"===this.getParent().get("type")},getParent:function(){return this.attributes.parent?this.getDocumentModel().get("attributes").get(this.attributes.parent):null},hasValueChanged:function(){return this.get("attributeValue")&&(void 0!==this.get("attributeValue").value&&(this._initialAttributeValue.value||"")!==(this.get("attributeValue").value||"")||!t.isEqual(t.pluck(t.flatten(this._initialAttributeValue),"value"),t.pluck(t.flatten(this.get("attributeValue")),"value")))},_computeMode:function(){var e=this.get("visibility"),i=this.collection.renderMode;if("H"===e||"I"===e)return this.set("mode","hidden"),void 0;if("view"===i)return"O"===e?(this.set("mode","hidden"),void 0):this.get("isValueAttribute")&&(t.isEmpty(this.get("attributeValue"))||t.isUndefined(this.get("attributeValue")||null===this.get("attributeValue").value))&&null===this.getOption("showEmptyContent")?(this.set("mode","hidden"),void 0):(this.set("mode","read"),void 0);if("edit"===i){if("W"===e||"O"===e)return this.set("mode","write"),void 0;if("R"===e)return this.set("mode","hidden"),void 0;if("R"===e||"S"===e)return this.set("mode","read"),void 0;if("U"===e)return this.set("mode","write"),this.set("addTool",!1),void 0}throw new Error("unkown mode "+i+" or visibility "+e+" "+this.get("id"))},_computeValueMode:function(){var t=this.get("type"),e=this.get("visibility");("frame"===t||"array"===t||"tab"===t||"I"===e)&&this.set("isValueAttribute",!1)},getOptions:function(){var e,i={},n={},o={},s={};return this._options=this._options||!1,this._options===!1&&(e=this.collection.renderOptions,e.common&&(i=e.common||{},s=t.clone(i.translatedLabels)||{}),e.types&&(n=e.types[this.get("type")]||{},s=t.extend(s,t.clone(n.translatedLa

Historique

#1 Mis à jour par Marc Claverie il y a plus de 3 ans

  • Version cible mis à 1.1.0
  • Statut changé de Nouveau à À analyser
  • Assigné à mis à Charles Bonnissent

#2 Mis à jour par Charles Bonnissent il y a plus de 3 ans

  • Statut changé de À analyser à Assigné

#3 Mis à jour par Charles Bonnissent il y a plus de 3 ans

  • % réalisé changé de 0 à 100

#4 Mis à jour par Éric Brison il y a plus de 3 ans

  • Statut changé de Assigné à Intégré

Appliqué par commit dynacase-document-uis|commit:196b4dbd0c07da3ff8ff41c22106717a86223856.

Formats disponibles : Atom PDF