【问题标题】:extjs checkbox data rendering issueextjs 复选框数据渲染问题
【发布时间】:2013-03-10 23:05:39
【问题描述】:

php 从服务器端返回数据但不是 extjs 不呈现字段的值

我正在使用 xtype: 'checkbox'

{"total":1,"success":true,"locks":[{"id":"1","re​​cord_id":"11","is_unreachable":"1","is_directory_Lock": "1","is_Internet_Lock":"0","is_partner_Lock":"1","is_home_business":"1","is_top_listing":"1","is_mole":"1","is_pre_call":"1 ","is_new_business":"1","is_free_adv":"1","is_verified":"1","is_reviewed":"1","is_idr":"1"}]}

从服务器返回的json数组

【问题讨论】:

    标签: extjs checkbox


    【解决方案1】:

    你必须粘贴你的代码。

    但是为什么不去例子: http://docs.sencha.com/ext-js/4-0/#!/example/grid/array-grid.html

    【讨论】:

      【解决方案2】:

      Ext.define('UserApp.view.uiTypes.LockFeature',{ 扩展:'Ext.form.Panel', 可折叠:真实, 弹性:1, 身高:200, 宽度:600, 商店:空, itemId: '锁定功能', 布局:{ 类型:'表', 列数:3 },

      items:[{
      
              xtype: 'checkbox',
              boxLabel: 'Is Unreachable',
              name: 'is_unreachable',
              id: 'is_unreachable',
              dataIndex: 'is_unreachable',
              inputValue: 'true', 
              uncheckedValue: 'false',
              value: true, 
      
      
      },{
      
          xtype: 'textfield',
          name: 'is_unreachable_update',
          fieldLabel: 'Last Update',
      
      },{
          xtype: 'textfield',
          name: 'update_by_user',
          fieldLabel: 'By'
      }],
      
      
      initComponent: function(){
          console.log(this.table);
          console.log(this.record_id);
          var table = this.table;
          var parentTable = table.split('_');
          console.log(parentTable[0]);
          var store = Ext.create('UserApp.store.LockFeature');
          store.getProxy().setExtraParam('table',parentTable[1]);
          store.getProxy().setExtraParam('tab',parentTable[1]);
          store.getProxy().setExtraParam('saving_table', table);
          store.getProxy().setExtraParam('record_id',this.record_id);
          this.store = store;
          this.callParent(arguments);
          store.load();
      
      }
      

      });

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 1970-01-01
        • 2013-11-25
        • 2011-01-28
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2011-11-20
        相关资源
        最近更新 更多