Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - hyh888

Pages: 1 2 [3] 4 5 ... 7
31
Help for ParamQuery Pro / Re: Head filter listenner
« on: April 29, 2022, 01:51:16 pm »
In head filter, filter action is triggered when filterbox got change automatically, this is a problem. Can it be stopped? Then it can be trigger in need.

32
Help for ParamQuery Pro / Head filter listenner
« on: April 28, 2022, 11:21:50 am »
In head filter, filter action is triggered when filterbox got change. Is it possible to trigger filter action when TAB or ENTER keys are pressed?
Could you like to show me how to intercept the listenner of head filter change envent

33
Many thanks for new demo. But if developer forgets setting limit-in-list for pqSelect, user in browser client maybe mistakely copy a lot of unhoped data to pqSelect column and save into database,for the value of select is changed but its text show nothing and these trouble-data will never be showed in interface in the future.
Maybe this should be treated as a bug.

By the way the configuration of pqSelect is a little complicated. Maybe it can be reduced to only configure one or two parameter instead of  dozens rows, unlesss user has very tricky requirement.
Maybe you can have a look for Jquery Easyui, even its grid function is not so powerful as pqGrid, but its style for easy-using impressed me deeply. Every line is for the need of business instead of software itself.

34
Help for ParamQuery Pro / Re: How to shrink size the delete button
« on: February 01, 2022, 03:52:41 am »
This idea can do reduce the height of the button and make no trouble for row height, but the cissors icon is not in the middle vertically any more. My code is as follow:
             { title: "删除", editable: false, minWidth: 123, sortable: false,
               render: function (ui) {return "<button type='button' class='delete_btn'></button>";},
              postRender: function (ui) {
                  var rowIndx = ui.rowIndx,grid = this,$cell = grid.getCell(ui);
                 $cell.find("button").button({icons: { primary: 'ui-icon-scissors' }})//
                 .bind("click", function () {
                     grid.addClass({ rowIndx: ui.rowIndx, cls: 'pq-row-delete' });
                     setTimeout(function () {
                         var ans = window.confirm("确定要删除第 " + (rowIndx + 1) + "行吗?");
                         grid.removeClass({ rowIndx: rowIndx, cls: 'pq-row-delete' });
                         if (ans) {grid.deleteRow({ rowIndx: rowIndx });}
                     })
                    }).css({height:'15px'});
            }
           }

35
Help for ParamQuery Pro / Re: pqSelect performance is very slow.
« on: January 31, 2022, 11:13:34 am »
You'd better put your code to make everyone know what happened. How many columns and records you are using?

36
Help for ParamQuery Pro / How to shrink size the delete button
« on: January 31, 2022, 11:10:53 am »
I have tried to shrink the size of delete button to reduce the height of every row, but got failed even tried many times.
Is there any solution for it?

37
In the demo Editors & validations(https://paramquery.com/pro/demos/editing_custom), for column ShipVia2 there is no limit-in-list for value in select. Would you like to help to show how to make? And use Ctrl+v, user can copy almost any unexpected data to select(s) and save them to database by batch(When user does this, there is only blank in select, in fact the data has be stored in value of select). Is there a solution for it? Here is the code from demo:

          {
              title: "Shipping Via2", dataIndx: "ShipVia2", width: 110,
              cls: 'pq-dropdown pq-side-icon',
              editor: {
                  type: 'select',
                  init: function (ui) {
                      ui.$cell.find("select").pqSelect();
                      setTimeout(function () {
                          ui.$cell.find("select").pqSelect('open');
                      })
                  },
                  options: [                       
                        { "SE": "Speedy Express" },
                        { "UP": "United Package" },
                        { "FS": "Federal Shipping" }
                  ]
              },
              //render required to display options text corresponding to value stored in the cell.
              render: function (ui) {                 
                  var option = ui.column.editor.options.find(function (obj) {
                      return (obj[ui.cellData] != null);
                  });
                  return option ? option[ui.cellData] : "";
              }
          },

38
Great help! It works.

39
I hope to add new row automatically, when the DownArrow Key is pressed in the last row.
Following code works well when there is no filter used. But after filtering, pressing DownArrow Key couldn't add new row automatically when the cell in last row is selected. Would you like to provide help kindly?

              beforeCellKeyDown: function( event, ui ) {
                if(event.key=="Delete" ){
                var nodes = [];
                var type = this.Selection().address()[0].type
                if(type == 'row'){
                   var Sel = this.Selection().eachRow(function(rowData){
                     nodes.push(rowData);
                   })
                   this.deleteNodes(nodes);
                   return false; //to prevent default behaviour.                    
                }             
      
            }                   
                 if(!this.isValid( { rowData: ui.rowData } ).valid)
                      {return;}
                if(event.key=="ArrowDown" && ui.rowIndx==this.getTotalRows()-1){
                        var rowIndx = this.addRow({ rowData: defaultRowData(), checkEditable: true });
                        // this.goToPage({ rowIndx: rowIndx });
                        debugger;
                        this.editFirstCellInRow({ rowIndx: rowIndx });   
      
                }
           
             },

40
Help for ParamQuery Pro / Re: DELETE problem
« on: January 12, 2022, 07:45:13 pm »
Great! It works. Many thanks for your kindly help.

41
Help for ParamQuery Pro / Re: DELETE problem
« on: January 12, 2022, 02:56:19 pm »
I found a new problem, when I seclected a cell and press delete key( after adding your code in grid), the whole row is deleted.  I hope that only when the whole row is selected and del-key is pressed then to delete the whole row. Would you like kindly to show me how to fix it?

42
Help for ParamQuery Pro / Re: How to add new option or event in grid
« on: December 31, 2021, 04:57:14 pm »
Thank you very much for your kindly response. For these days,without your reply, I'm worried about if my idea had intrude your treasure for pqgrid framework . Is there any sample for modifing $.paramquery.pqGrid.prototype, I will study it and feedback the result.
Happy new year!

43
Help for ParamQuery Pro / How to add new option or event in grid
« on: December 27, 2021, 07:42:09 am »
To saving code and reduce bugs, I hope to add saveUrl(url to save data) and getUrl(url to get the json data) for grid, and also hope to add inbuild SaveChanges event to grid for saving data with saveUrl.
Would you like to provide help?
Thank you very much.

44
Bug Report / Re: Copy and paste problem
« on: December 07, 2021, 04:43:46 pm »
Great, I will try it.

45
Help for ParamQuery Pro / Re: cell get focus event
« on: December 03, 2021, 10:12:53 am »
Thank you, it works

Pages: 1 2 [3] 4 5 ... 7