kazelee
1 天以前 74ca5a83f24c53c48ad7e6f5b7739649fb411546
swagger.js
@@ -40,6 +40,27 @@
            }
        });
    },
    setModelDescriptions: function() {
        $.ajax({
            type: "get",
            url: $("#input_baseUrl").val(),
            dataType: "json",
            success: function(data) {
                var modelDesc = data.ModelDesc;
                // 在模型展示区域添加描述
                $(".model-box").each(function() {
                    var modelName = $(this).find(".model-title").text();
                    if (modelDesc[modelName]) {
                        $(this).find(".model-description").remove();
                        $(this).append(
                            `<div class="model-description">${modelDesc[modelName]}</div>`
                        );
                    }
                });
            }
        });
    },
    _tryTranslate: function (word)
    {
        return this._words[$.trim(word)] !== undefined ? this._words[$.trim(word)] : word;