EasyUI Forum
April 28, 2024, 08:30:32 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
  Home Help Search Login Register  
  Show Posts
Pages: 1 [2] 3 4 5
16  General Category / EasyUI for jQuery / Listen to onChange in Form Causes Issues on: December 29, 2022, 09:14:44 AM
Hello,

I listen to the onChange event in the Form.

in the onChange event, I validate the form, which moves focus on the first input field.

How can I switch it off? Possibly by setting focusInvalid: false;

I need validation on change because, I enable the save button when the form is valid, otherwise, it is disabled.

See the code:

Code:
forma.dialog({
                                            title: 'შეტყობინების გაგზავნა',
                                            width: 870,
                                            height: 300,
                                            modal: false,
                                            resizable: true,
                                            closeAnimation: 'hide',
                                            minimize: 'animate',
                                            collapsible: true,
                                            minimizable: true,
                                            maximizable: true,
                                            href: false,
                                            bodyCls: 'kk f-column',
                                            toolbar: buildToolbar([{
                                                        id: 'save-btn',
                                                        text: 'შექმნა',
                                                        iconCls: 'icon-save',
                                                        plain: true,
                                                        type: 'linkbutton',
                                                        separator: true,
                                                        disabled: true,
                                                        onClick: function() {
                                                            forma.find('form').submit();
                                                        }
                                                    }, {
                                                        text: 'დახმარება',
                                                        iconCls: 'icon-help',
                                                        plain: true,
                                                        type: 'linkbutton',
                                                        separator: false,
                                                        onClick: function() {
                                                            $.messager.alert('ბილეთის შექმნა: დახმარება', 'ბილეთის შექმნისას დეტალურად მიუთითეთ საკითხის აღწერილობა. გაითვალისწინეთ, ბილეთის დასახელება ხილვადი იქნება მომხმარებლისთვის, ხოლო, აღწერილობა - არა.', 'info');
                                                        }
                                                    }]),
                                            onOpen: function()
                                            {
                                                
                                                forma.find('form').form({
                                                        iframe: false,
                                                        method: 'POST',
                                                        url: '/api-submitCustomerCustomSMS',
                                                        queryParams: {
                                                                    customerId: customer_id,
                                                        },
                                                     onSubmit: function() {
                                                                    $.messager.progress({
                                                                        title: 'მიმდინარეობს მონაცემების შენახვა',
                                                                        msg: 'გთხოვთ, დაელოდოთ...',
                                                                        interval: 0
                                                                    });
        
                                                                    var isValid = forma.find('form').form('validate');
                                                                    if (!isValid) {
                                                                        $.messager.progress('close'); // hide progress bar while the form is invalid
                                                                    }
        
                                                                    return isValid; // return false will stop the form submission
        
                                                        },
                                                        onProgress: function(percent) {
                                                                    var bar = $.messager.progress('bar'); // get the progressbar object
                                                                    bar.progressbar('setValue', percent); // set new progress value
                                                        },
                                                        success: function(data) {
                                                                    $.messager.progress('close'); // hide progress bar while submit successfully
                                                                    
                                                                    try {
                                                                        var data = JSON.parse(data);
                                                                        if (data.success) {
                                                                            $.messager.alert('წარმატებით შესრულდა', data.message);
                                                                            var opts = $(this).form('options');
                                                                    opts.originalData = $(this).serialize();
                                                                    forma.dialog('panel').find('#save-btn').linkbutton('disable');
                                                                    $(this).form('resetDirty');
                                                                        } else if (data.error) {
                                                                            $.messager.alert('შეცდომა', data.message, 'error');
                                                                        }
                                                                    } catch (e) {
                                                                        $.messager.alert('შეცდომა', 'სერვერთან დაკავშირება ვერ ხერხდება.', 'error');
                                                                    }
                                                                    
                                                                    CustomerTabPanel.find('#customer_smsHistory').datagrid('reload');
                                                                    
                                                        },
                                                     onChange: function (target) {
                                                            var isValid = forma.find('form').form('validate');
                                                                    if (!isValid) {
                                                                        forma.dialog('panel').find('#save-btn').linkbutton('disable');
                                                                        
                                                                    }
                                                                    else
                                                                    {
                                                                        forma.dialog('panel').find('#save-btn').linkbutton('enable');
                                                                    }
                                                                    
                                                     }
                                                    });
                                                    
                                                    forma.find('#scheduleTime').textbox('hide');
                                            },
                                            onClose: function() {
                                                $(this).window('destroy').remove();
                                            },
                                        });
17  General Category / EasyUI for jQuery / Re: Create PropertyGrid using Datagrid Row on: December 13, 2022, 02:56:26 AM
Thank you, Jarry!

I know how to create the Propertygrid.

What I need is to create a propertygrid where the Data is a datagrid row data.

Example:

Code:

$('#dg').datagrid({
    url:'datagrid_data.json',
    columns:[[
        {field:'code',title:'Code',width:100},
        {field:'name',title:'Name',width:100},
        {field:'price',title:'Price',width:100,align:'right'}
    ]],
   onDblClickRow: function(index,row)
   {
      var data = row;
$('#pg').propertygrid({
data: data,
scrollbarSize: 0
})
   }
});

18  General Category / EasyUI for jQuery / Form property "dirty" doesn't work for radiogroup & checkgroup on: December 12, 2022, 01:04:09 PM
Hello,

the Form property "dirty" doesn't work for newly added modules: radiogroup & checkgroup.

Please, fix.

Thanks
19  General Category / EasyUI for jQuery / Create PropertyGrid using Datagrid Row on: December 12, 2022, 11:19:53 AM
Hello,

How can I construct propertygrid programmatically using the clicked row data on double click datagrid row?

Spent hours trying it but I cannot figure it out,

Thanks
20  General Category / EasyUI for jQuery / Fail to Update Tab Panel Footer on: December 04, 2022, 03:16:25 AM
Hello,

How can I update the tab footer?
Setting type to all updates only header and body.
21  General Category / EasyUI for jQuery / Texteditor Insert Link Issue on: November 29, 2022, 07:46:24 AM
Hello,

When trying to insert link in the texteditor, I get the following error:

Uncaught TypeError: Cannot read properties of undefined (reading 'textbox')
    at getValue (jquery.easyui.min.js?119:8320:26)
    at $.fn.textbox (jquery.easyui.min.js?119:8166:Cool
    at HTMLDivElement.callback (jquery.texteditor.js:514:43)
    at HTMLAnchorElement.handler (jquery.texteditor.js:172:23)

Any help?
22  General Category / EasyUI for jQuery / Re: Loading combogrid columns in datagrid on: November 06, 2022, 12:19:30 AM
Hello,

Please check: https://jsfiddle.net/adx7t8m4/
23  General Category / EasyUI for jQuery / Re: How to Move ToolTip Along With Mouse Pointer on: November 02, 2022, 01:01:44 AM
Solved!

trackMouse: true solved the issue.

Thanks
24  General Category / EasyUI for jQuery / How to Move ToolTip Along With Mouse Pointer on: November 01, 2022, 10:47:40 PM
Hello,

How can I move tooltip along with the mouse pointer?

Thank you!
25  General Category / EasyUI for jQuery / Re: Loading combogrid columns in datagrid on: October 31, 2022, 04:56:03 AM
Hello,

Please see the updated example: https://jsfiddle.net/6h2u9L4a/
26  General Category / EasyUI for jQuery / Emoji for Texteditor Extension on: October 27, 2022, 12:22:48 AM
Hello,

How can I add emoji function to the texteditor extension?

Thanks in advance
27  General Category / EasyUI for jQuery / Input component with calculator - New EasyUI Component on: October 21, 2022, 11:19:43 PM
Hello,

I believe, it would be beneficial and useful if we could develop a new EasyUI component, such as datebox, with a calculator panel.

For example, when clicking the input field, a panel shows with a calculator and any operation that is performed in the calculator is then inserted in the input field.

That is my suggestion,

Thank you for this amazing work again and again!

Regards
28  General Category / EasyUI for jQuery / Re: Load Form doesn't check radiobutton on: October 15, 2022, 01:36:05 AM
Hi, Jarry!

Thank you again!

Does validation work on radiogroup?

I noticed that required: true doesn't work, for example.

Also, $('#gender').radiogroup('enable'); OR $('#gender').radiogroup('disable'); doesn't work too.

Please, help.
29  General Category / EasyUI for jQuery / Re: Load Form doesn't check radiobutton on: October 11, 2022, 01:02:42 PM
Thanks, Jarry!

Awesome features, indeed!


There is just one detail missing: the group should have the parent label, shouldn't it? Otherwise, when used in forms, the radiogroup shows misaligned without a parent label.

See the example screenshot below (I have circled the parent label):

30  General Category / EasyUI for jQuery / Re: Load Form doesn't check radiobutton on: October 05, 2022, 10:25:52 PM
Jarry, thank you as always!

Could you please help us extend the radiobutton functionality so that it supports not only a single radiobutton, but a group of radiobuttons aligned either horizontally, or vertically, each radiobutton having its own label, while the group itself may have a single label?

That would be very good for the entire project.

Reference: https://examples.sencha.com/extjs/7.5.1/examples/kitchensink/?modern#form-radiogroup

Thanks
Pages: 1 [2] 3 4 5
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!