问题标签 [jqgrid-php]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
jqgrid - Ajax 数据结果到 jqgrid 显示
我从 AJAX 调用得到这个结果,我想将它传递给 jqgrid。格式与正常的 jqgrid 调用完全相同。我不知道为什么它不起作用,非常感谢任何帮助。
{"page":null,"total":2,"records":"16","rows":[{"id":"9910003","cell":["9910003","DEMO3","Test3 ","Sat,Sun","08:00:00","17:00:00","17","0"]},{"id":"9910004","cell":["9910004 ","DEMO4","Test4","Sat,Sun","08:00:00","17:00:00","19","0"]},{"id":"9910005" ,"cell":["9910005","DEMO5","Test5","Sat,Sun","08:00:00","17:00:00","17","0"]}, {"id":"9910006","cell":["9910006","DEMO6","Test6","Sat,Sun","08:00:00","17:00:00","17","0"]},{"id":"9910007","cell":["9910007","DEMO7","Test7","Sat,Sun", "08:00:00","17:00:00","14","0"]},{"id":"9910008","cell":["9910008","DEMO8","Test8 ","Sat,Sun","21:00:00","06:00:00","19","0"]},{"id":"9910009","cell":["9910009 ","DEMO9","Test9","Sat,Sun","21:00:00","06:00:00","14","0"]},{"id":"9910010" ,"单元格":["9910010","DEMO10","Test10","周六,周日","21:00:00","06:00:00","14","0"]},{"id":"9910011","cell":["9910011","DEMO11","Test11","Sat,Sun","21:00:00","06:00: 00","14","0"]},{"id":"9910012","cell":["9910012","DEMO12","Test12","Sat,Sun","21:00: 00","06:00:00","17","0"]},{"id":"9910013","cell":["9910013","DEMO13","Test13","Sat,太阳","21:00:00","06:00:00","16","0"]},{"id":"9910014","cell":["9910014","DEMO14" ,"Test14","Sat,Sun","21:00:00","06:00:00","14","0"]},{"id":"9910015","cell":["9910015","DEMO15","Test15","Sat,Sun","21:00:00","06:00:00","14","0"] },{"id":"9910016","cell":["9910016","DEMO16","Test16","Sat,Sun","21:00:00","06:00:00", "14","0"]}]}
以下是我的完整代码:
我在下面尝试但没有成功,我想我错过了一些东西
php - JQGrid for PHP 用图标替换链接文本
我正在为 PHP 使用 JQGrid。
在此处查看主页
我已将编辑和删除添加到这样的列中:
它工作得很好并且做了它应该做的,但是编辑和删除链接是文本的,我需要用图像替换文本,但不知道我需要在哪里/在哪里更改它。
jquery - JqGrid 选择可能可见或不可见的特定行
我有一个 jqGrid 并且有几页项目。我有一行的 ID,它可能在第一页上,也可能埋在其他页面的某个地方。
给定行的 ID,我如何以编程方式选择这样的行?我正在使用按钮的单击事件,如下所示
当我单击按钮时,我得到以下萤火虫控制台。
TypeError:this.each 不是函数
有任何想法吗 ?
编辑
所以我选择只用一条记录重新填充网格。问题是我没有使用本地数据。我的数据类型是“json”。像这样
我有想要重新填充网格的 json 字符串。如何使用这些新数据重新初始化网格。我将下面的json字符串与相应的逻辑如下,但没有任何反应。
php - jqGrid:如何使用单一搜索功能?
如何使用 jqGrid 的单一搜索功能?
我遵循“3.7 版中的新功能”下的示例“单一搜索”。jqGrid 演示页面
我的脚本几乎完全保存了用于从数据库中检索数据的查询,但我的脚本不进行过滤。
谁能指出我使用 PHP 的单一搜索功能的完整示例?
我对演示页面中的脚本也有疑问。
- jQuery如何将条件传递给PHP来过滤结果?我在查询中注意到它有一个变量
$where
,但该变量没有在 PHP 脚本中声明。
php - jQGrid 与 Oracle 数据库
我正在将 jqgrid 与 oracle 数据库一起使用。根本的问题是,看起来一切都是正确的,不仅显示数据库表中的信息。我把所有可能对我有帮助的代码都留在这里。
书本.php
索引.php
我得到的答案是 book.php:
{"page":2,"total":2,"records":"12","rows":[{"id":"1","cell":["1","fname1","lname1 ","(000)000-0000","name1@gmail.com"]},{"id":"2","cell":["2","fname1","lname1","(000 )000-0000","name1@gmail.com"]},{"id":"3","cell":["3","fname1","lname1","(000)000-0000" ,"name1@gmail.com"]},{"id":"4","cell":["4","fname1","lname1","(000)000-0000","name1@gmail .com"]},{"id":"5","cell":["5","fname1","lname1","(000)000-0000","name1@gmail.com"]},{"id":"6","cell":["6","fname1","lname1","(000)000-0000","name1@gmail.com "]},{"id":"7","cell":["7","fname1","lname1","(000)000-0000","name1@gmail.com"]},{ "id":"8","cell":["8","fname1","lname1","(000)000-0000","name1@gmail.com"]},{"id":" 9","cell":["9","fname1","lname1","(000)000-0000","name1@gmail.com"]},{"id":"10","cell ":["10","fname1","lname1","(000)000-0000","name1@gmail.com"]}]}单元格":["6","fname1","lname1","(000)000-0000","name1@gmail.com"]},{"id":"7","cell":[" 7","fname1","lname1","(000)000-0000","name1@gmail.com"]},{"id":"8","cell":["8","fname1 ","lname1","(000)000-0000","name1@gmail.com"]},{"id":"9","cell":["9","fname1","lname1" ,"(000)000-0000","name1@gmail.com"]},{"id":"10","cell":["10","fname1","lname1","(000) 000-0000","name1@gmail.com"]}]}单元格":["6","fname1","lname1","(000)000-0000","name1@gmail.com"]},{"id":"7","cell":[" 7","fname1","lname1","(000)000-0000","name1@gmail.com"]},{"id":"8","cell":["8","fname1 ","lname1","(000)000-0000","name1@gmail.com"]},{"id":"9","cell":["9","fname1","lname1" ,"(000)000-0000","name1@gmail.com"]},{"id":"10","cell":["10","fname1","lname1","(000) 000-0000","name1@gmail.com"]}]}]},{"id":"7","cell":["7","fname1","lname1","(000)000-0000","name1@gmail.com"]},{" id":"8","cell":["8","fname1","lname1","(000)000-0000","name1@gmail.com"]},{"id":"9 ","cell":["9","fname1","lname1","(000)000-0000","name1@gmail.com"]},{"id":"10","cell" :["10","fname1","lname1","(000)000-0000","name1@gmail.com"]}]}]},{"id":"7","cell":["7","fname1","lname1","(000)000-0000","name1@gmail.com"]},{" id":"8","cell":["8","fname1","lname1","(000)000-0000","name1@gmail.com"]},{"id":"9 ","cell":["9","fname1","lname1","(000)000-0000","name1@gmail.com"]},{"id":"10","cell" :["10","fname1","lname1","(000)000-0000","name1@gmail.com"]}]}fname1","lname1","(000)000-0000","name1@gmail.com"]},{"id":"9","cell":["9","fname1","lname1 ","(000)000-0000","name1@gmail.com"]},{"id":"10","cell":["10","fname1","lname1","(000 )000-0000","name1@gmail.com"]}]}fname1","lname1","(000)000-0000","name1@gmail.com"]},{"id":"9","cell":["9","fname1","lname1 ","(000)000-0000","name1@gmail.com"]},{"id":"10","cell":["10","fname1","lname1","(000 )000-0000","name1@gmail.com"]}]}
有人能帮我吗?
jquery - 在查找之前更改搜索框中文本框的值
我正在尝试在 jgrid 中实现复杂的搜索功能。但我想在用户按下查找按钮之前更改用户在搜索框中指定的值。
在这里你可以看到值
17 20 35 36 37 53 54
,我希望这些值用逗号分隔,所以在我点击 find 之前,我想更改文本框中的值,所以谁能告诉我我该怎么做?此外,我想知道如何自定义此搜索框的外观,而不是
id
,is in
我想要一些用户友好的 UI,用户可以在其中简单地输入值并点击查找,但我不知道如何更改此搜索的外观框注入我们自己的外观并使搜索框不可拖动
jqgrid - 如何自定义 jqgrid 搜索对话框
我是 jqGrid 的初学者。我有4个字段、、、Id
和。我希望当用户单击图标搜索并在选择要搜索的项目时出现搜索框现在出现一个文本框供用户输入您的日期,但我希望出现两个文本框供用户输入,喜欢这个表格
请帮助我。谢谢大家Name
Date
Age
Date
FromDate
ToDate
jquery - Jquery表单序列化 - jqgrid上的多项选择
我有一个 jqGrid,我在其中向 colmodel 发送一个名为“设备”的特定属性的字符串值。只要值在网格上完美显示,一切都很好。我还添加了一个添加和编辑按钮,一切都很好,工作正常,表单按预期显示。(原谅这篇明显长的帖子,但它非常容易理解)
我在添加表单上修改了名为设备的字段,并像这样注入了我自己的多项选择
模型
添加按钮 - beforeShowForm 选项
这是我添加表单的相关部分。
当我单击保存和新建时,该功能工作正常,这是我通过bSubmit: "Save and New"
上面取消清除的提交按钮。这方面的邮政数据显示在您的左侧。当我单击Save and close
作为我的自定义按钮的按钮时。帖子数据显示在您的右侧。
Save and Close 使用 jquery 像这样序列化整个表单$('#FrmGrid_list2').serialize()
,这就是它变得毛茸茸的地方。
如果我们查看在这两种情况下发布的设备内容,我们可以看到名称差异。似乎 jqGrid 足够智能,可以计算出它的一组值,而 jquery serialize() 并没有按照我想要的方式进行。我正在使用 Spring MVC 3.0,这是我的设备数据执行操作的地方。
看看最后一个@RequestParam,Spring能够处理项目数组,但是当它使用jQuery序列化发布时,动作找不到名为“设备[] ”的参数我在这里看到了一个关于这个的链接,我可以简单地这样做吗?
有任何想法吗
jqgrid - 如何在 jqGrid 搜索中发送到服务器之前自定义数据
我是 jqGrid 的初学者。我为生成网格编写此代码
我希望用户在搜索框中选择 unitPrice 并键入数字,数字 3 char 3 char sperate with ,
,我编写函数 addCommas 并且工作良好,但是当用户输入价格并按下搜索按钮时,单价不会发送到服务器。这张图片中的例子
点击搜索按钮后
请帮我。谢谢大家
javascript - JQGRID:在网格中为所有列添加排序选项
我需要在网格中为所有列添加排序选项(“事件键”、“日期”、“状态”、“事件编号”、“FF 死亡”、“OTH 死亡”、“财产损失”、“连续损失” ,'火灾原因') 分开。我试过了,但它不起作用,请在我的代码中修复排序问题,如果您对此有任何想法,请回答。