zoukankan      html  css  js  c++  java
  • 取得GridPanel选定行所有字段值

    1、前台

    <SelectionModel>

                                                               <ext:RowSelectionModel ID="RowSelectionModel2" runat="server">

                                                                  <AjaxEvents>

                                                                    <RowSelect OnEvent="RowSelectzhy" Buffer="250">

                                                                        <EventMask ShowMask="true" Target="CustomTarget" CustomTarget="#{Details}" />

                                                                         <ExtraParams>

                                                                            <ext:Parameter Name="Values" Value="Ext.encode(#{GrdDoc}.getRowsValues())" Mode="Raw" />

                                                                        </ExtraParams>

                                                                    </RowSelect>

                                                                  </AjaxEvents>

                                                            </ext:RowSelectionModel>

                                                            </SelectionModel> 

    2、后台

     protected void RowSelectzhy(object sender, AjaxEventArgs e)

        {

            string Key;

            string json = e.ExtraParams["Values"];

            Dictionary<string, string>[] companies = JSON.Deserialize<Dictionary<string, string>[]>(json);

            if (companies.Length > 0)

            {

                foreach (Dictionary<string, string> row in companies)

                {

                    foreach (KeyValuePair<string, string> keyValuePair in row)

                    {

                        Key = keyValuePair.Key;

                        if (Key == "qzid")

                        {

                            qzid = keyValuePair.Value;

                            continue;

                        }

                        else if (Key == "zhyid")

                        {

                            zhyid = keyValuePair.Value;

                            continue;

                        }

                    }

                }

            }

        }

  • 相关阅读:
    心情不好的时候
    离骚
    沁园春.雪
    顾炎武《精卫》
    韩愈《祝融峰》
    Python量化交易的简单介绍
    H5页面跳转到小程序代码
    小程序上拉加载,下拉刷新
    第一阶段:Python开发基础 day36 并发编程之Process的join用法和其他用法
    课后练习 第一阶段:Python开发基础 day38 多线程相关小练习
  • 原文地址:https://www.cnblogs.com/easypass/p/1654703.html
Copyright © 2011-2022 走看看