Вход Регистрация
Файл: concrete5.7.5.6/concrete/js/build/core/editable-field/attribute.js
Строк: 37
<?php
/** 
 * concrete5 Attribute type for X-Editable
 */


!function(global, $) {
    
'use strict';

    function 
ConcreteEditableAttribute(options) {
        var 
$scope = $(options.scope),
            
akID $scope.attr('data-key-id');

        
options.tpl = $('[data-editable-attribute-key-id=' akID ']');
        
this.init('concreteeditableattribute'optionsConcreteEditableAttribute.defaults);
    }

    $.
fn.editableutils.inherit(ConcreteEditableAttribute, $.fn.editabletypes.abstractinput);

    $.
extend(ConcreteEditableAttribute.prototype, {

        
input2value: function() {
            var 
values this.$input.closest('.editableform').serializeArray();
            return 
values;
        },

        
value2html: function(valueelement) {
            $(
element).html(value);
        },

    });

    
ConcreteEditableAttribute.defaults = $.extend({}, $.fn.editabletypes.abstractinput.defaults);

    $.
fn.editabletypes.concreteattribute ConcreteEditableAttribute;

}(
this, $);
?>
Онлайн: 2
Реклама