|
@@ -114,7 +114,7 @@ define([ "require", "backbone", "hbs!tmpl/entity/CreateEntityLayoutView_tmpl", "
|
|
|
}
|
|
|
}), 0 === this.asyncReferEntityCounter && this.onEntityChange(null, this.entityData);
|
|
|
} else {
|
|
|
- var str = '<option disabled="disabled" selected>--Select entity-type--</option>';
|
|
|
+ var str = '<option disabled="disabled" selected>--请选择实体类型--</option>';
|
|
|
this.entityDefCollection.fullCollection.each(function(val) {
|
|
|
var name = Utils.getName(val.toJSON());
|
|
|
Globals.entityTypeConfList && 0 !== name.indexOf("__") && (_.isEmptyArray(Globals.entityTypeConfList) ? str += "<option>" + name + "</option>" : _.contains(Globals.entityTypeConfList, val.get("name")) && (str += "<option>" + name + "</option>"));
|
|
@@ -161,7 +161,7 @@ define([ "require", "backbone", "hbs!tmpl/entity/CreateEntityLayoutView_tmpl", "
|
|
|
if (value.isOptional === !1 && (isAllRelationshipAttributeOptinal = !1), null === visitedAttr[value.name]) {
|
|
|
var duplicateRelationship = _.where(relationshipAttributeDefsList, {
|
|
|
name: value.name
|
|
|
- }), str = '<option value="">--Select a Relationship Type--</option>';
|
|
|
+ }), str = '<option value="">--请选择一个关联类型--</option>';
|
|
|
_.each(duplicateRelationship, function(val, index, list) {
|
|
|
str += "<option>" + _.escape(val.relationshipTypeName) + "</option>";
|
|
|
});
|
|
@@ -265,7 +265,7 @@ define([ "require", "backbone", "hbs!tmpl/entity/CreateEntityLayoutView_tmpl", "
|
|
|
},
|
|
|
getSelect: function(object) {
|
|
|
var value = object.value, name = _.escape(value.name), entityValue = _.escape(object.entityValue), isAttribute = object.isAttribute, isRelation = object.isRelation;
|
|
|
- if ("boolean" === value.typeName) return '<select class="form-control row-margin-bottom ' + (value.isOptional === !0 ? "false" : "true") + '" data-type="' + value.typeName + '" data-attribute="' + isAttribute + '" data-relation="' + isRelation + '" data-key="' + name + '" data-id="entityInput"><option value="">--Select true or false--</option><option value="true">true</option><option value="false">false</option></select>';
|
|
|
+ if ("boolean" === value.typeName) return '<select class="form-control row-margin-bottom ' + (value.isOptional === !0 ? "false" : "true") + '" data-type="' + value.typeName + '" data-attribute="' + isAttribute + '" data-relation="' + isRelation + '" data-key="' + name + '" data-id="entityInput"><option value="">--选择是或否--</option><option value="true">是</option><option value="false">否</option></select>';
|
|
|
var splitTypeName = value.typeName.split("<");
|
|
|
return splitTypeName = splitTypeName.length > 1 ? splitTypeName[1].split(">")[0] : value.typeName,
|
|
|
'<select class="form-control row-margin-bottom entityInputBox ' + (value.isOptional === !0 ? "false" : "true") + '" data-type="' + value.typeName + '" data-attribute="' + isAttribute + '" data-relation="' + isRelation + '" data-key="' + name + '" data-id="entitySelectData" data-queryData="' + splitTypeName + '">' + (this.guid ? entityValue : "") + "</select>";
|
|
@@ -429,7 +429,7 @@ define([ "require", "backbone", "hbs!tmpl/entity/CreateEntityLayoutView_tmpl", "
|
|
|
var that = this;
|
|
|
this.$('select[data-id="entitySelectData"]').each(function(value, key) {
|
|
|
var $this = $(this), keyData = $(this).data("key"), typeData = $(this).data("type"), queryData = $(this).data("querydata"), placeholderName = ($(this).data("skip"),
|
|
|
- "Select a " + typeData + " from the dropdown list");
|
|
|
+ "请从以下列表中选择一个" + typeData);
|
|
|
if ($this.attr("multiple", $this.data("type").indexOf("array") !== -1), that.guid) {
|
|
|
var dataValue = that.entityData.get("entity").attributes[keyData], relationshipType = (that.entityData.get("entity").attributes,
|
|
|
that.entityData.get("entity").relationshipAttributes ? that.entityData.get("entity").relationshipAttributes[keyData] : null), referredEntities = that.entityData.get("referredEntities"), selectedValue = [], select2Options = [];
|