Reader/Feed.bjs
[web.Reader] / Reader / Feed.js
1 //<script type="text/javascript">
2
3 // Auto generated file - created by app.Builder.js- do not edit directly (at present!)
4
5 Feed = new Roo.XComponent({
6
7  _strings : {
8   '8287b137f969bcae66ca51f7abf14308' :"Show Previously Read ",
9   'd9cd9f7b44e0493c9604e9f8fb7a6c07' :"Mark All Read",
10   'b7436cc90ecf26f15baeead978f09040' :"name of feed",
11   '83ca9a18d9507324a9453c92a7420dd2' :"Report Issue"
12  },
13
14   part     :  ["Reader", "Feed" ],
15   order    : '-Feed',
16   region   : 'center',
17   parent   : false,
18   name     : "unnamed module",
19   disabled : false, 
20   permname : '', 
21   _tree : function()
22   {
23    var _this = this;
24    var MODULE = this;
25    return {
26    xns : Roo.bootstrap,
27    '|xns' : 'Roo.bootstrap',
28    xtype : 'Body',
29    items  : [
30     {
31      html : _this._strings['b7436cc90ecf26f15baeead978f09040'] /* name of feed */,
32      style : 'font-weight: bold;\nfont-size: 22px;\n \nposition: absolute;\nleft: 100px;\ntop: 10px;\nz-Index: 1000;\ncolor: white;',
33      tag : 'div',
34      xns : Roo.bootstrap,
35      '|xns' : 'Roo.bootstrap',
36      xtype : 'Element'
37     },
38     {
39      brand : '<i class=\"fa fa-chevron-left\"></i> Feeds',
40      brand_href : baseURL + '/Feeds',
41      inverse : true,
42      position : 'fixed-top',
43      xns : Roo.bootstrap,
44      '|xns' : 'Roo.bootstrap',
45      xtype : 'NavHeaderbar',
46      items  : [
47       {
48        align : 'right',
49        xns : Roo.bootstrap,
50        '|xns' : 'Roo.bootstrap',
51        xtype : 'NavGroup',
52        items  : [
53         {
54          html : _this._strings['d9cd9f7b44e0493c9604e9f8fb7a6c07'] /* Mark All Read */,
55          xns : Roo.bootstrap,
56          '|xns' : 'Roo.bootstrap',
57          xtype : 'NavItem'
58         },
59         {
60          html : _this._strings['8287b137f969bcae66ca51f7abf14308'] /* Show Previously Read  */,
61          xns : Roo.bootstrap,
62          '|xns' : 'Roo.bootstrap',
63          xtype : 'NavItem'
64         },
65         {
66          html : _this._strings['83ca9a18d9507324a9453c92a7420dd2'] /* Report Issue */,
67          xns : Roo.bootstrap,
68          '|xns' : 'Roo.bootstrap',
69          xtype : 'NavItem'
70         }
71        ]
72       }
73      ]
74     },
75     {
76      hover : true,
77      responsive : true,
78      striped : true,
79      style : 'margin-top:50px',
80      thead : false,
81      xns : Roo.bootstrap,
82      '|xns' : 'Roo.bootstrap',
83      xtype : 'Table',
84      listeners : {
85       render : function (_self)
86        {
87            this.store.load({});
88        }
89      },
90      store : {
91       remoteSort : true,
92       xns : Roo.data,
93       '|xns' : 'Roo.data',
94       xtype : 'Store',
95       listeners : {
96        beforeload : function (_self, o)
97         {
98             o.params = o.params || {};
99             o.params.feed = 83;
100         }
101       },
102       proxy : {
103        method : 'GET',
104        url : baseURL + '/Api/Reader_read',
105        xns : Roo.data,
106        '|xns' : 'Roo.data',
107        xtype : 'HttpProxy'
108       },
109       reader : {
110        fields : [
111                "id",
112                    "article_id",
113                    "has_read",
114                    "article_id_id" ,
115                    "article_id_published_dt" ,
116                    "article_id_headline" ,
117                    "article_id_body" ,
118                    "article_id_real_url" 
119                ],
120        xns : Roo.data,
121        '|xns' : 'Roo.data',
122        xtype : 'JsonReader'
123       }
124      },
125      cm : [
126       {
127        dataIndex : 'article_id_headline',
128        renderer : function(v,x,r) {
129           
130           return String.format(
131                    '<h3>{0}</h3><small>{1}</small><i class="rss-list-body">{2}</i>' + 
132                        '<span class="badge">{3}</span><i class="fa fa-chevron-right"></i>',
133                r.data.article_id_headline,
134                r.data.article_id_published_dt,
135                r.data.article_id_body_txt,
136                r.data.has_read ? "Read" : ''
137            );
138                    
139        
140        
141         },
142        xns : Roo.grid,
143        '|xns' : 'Roo.grid',
144        xtype : 'ColumnModel'
145       }
146      ]
147     }
148    ]
149   };  }
150 });