1 //<script type="text/javascript">
3 // Auto generated file - created by app.Builder.js- do not edit directly (at present!)
5 Feed = new Roo.XComponent({
8 '8287b137f969bcae66ca51f7abf14308' :"Show Previously Read ",
9 'd9cd9f7b44e0493c9604e9f8fb7a6c07' :"Mark All Read",
10 'b78a3223503896721cca1303f776159b' :"Title",
11 'b7436cc90ecf26f15baeead978f09040' :"name of feed",
12 '83ca9a18d9507324a9453c92a7420dd2' :"Report Issue",
13 'eae639a70006feff484a39363c977e24' :"Domain",
14 '44749712dbec183e983dcd78a7736c41' :"Date"
17 part : ["Reader", "Feed" ],
21 name : "unnamed module",
30 '|xns' : 'Roo.bootstrap',
34 html : _this._strings['b7436cc90ecf26f15baeead978f09040'] /* name of feed */,
35 style : 'font-weight: bold;\nfont-size: 22px;\n \nposition: absolute;\nleft: 100px;\ntop: 10px;\nz-Index: 1000;\ncolor: white;',
38 '|xns' : 'Roo.bootstrap',
42 brand : '<i class=\"fa fa-chevron-left\"></i> Feeds',
43 brand_href : baseURL + '/Feeds',
45 position : 'fixed-top',
47 '|xns' : 'Roo.bootstrap',
48 xtype : 'NavHeaderbar',
53 '|xns' : 'Roo.bootstrap',
57 html : _this._strings['d9cd9f7b44e0493c9604e9f8fb7a6c07'] /* Mark All Read */,
59 '|xns' : 'Roo.bootstrap',
63 html : _this._strings['8287b137f969bcae66ca51f7abf14308'] /* Show Previously Read */,
65 '|xns' : 'Roo.bootstrap',
69 html : _this._strings['83ca9a18d9507324a9453c92a7420dd2'] /* Report Issue */,
71 '|xns' : 'Roo.bootstrap',
83 style : 'margin-top:50px',
86 '|xns' : 'Roo.bootstrap',
89 render : function (_self)
94 rowclick : function (_self, el, rowIndex, e)
96 var rec = this.store.getAt(rowIndex);
106 beforeload : function (_self, o)
108 o.params = o.params || {};
114 url : baseURL + '/Api/Reader_read',
125 "article_id_published_dt" ,
126 "article_id_headline" ,
128 "article_id_real_url" ,
129 'article_id_body_txt'
138 dataIndex : 'article_id_headline',
139 renderer : function(v,x,r) {
141 return String.format(
142 '<h3>{0}</h3><small>{1}</small><i class="rss-list-body">{2}</i>' +
143 '{3}<i class="fa fa-chevron-right"></i>',
144 r.data.article_id_headline,
145 r.data.article_id_published_dt,
146 r.data.article_id_body_txt,
147 r.data.has_read * 1 ? '<span class="badge">Read</span>' : ''
154 xtype : 'ColumnModel'
160 loadArticle : function(pos) {
164 Roo.MessageBox.alert("error", "show article got < 0");
167 // Roo.select('.hover-nav').show();
168 _this.table.hide(); // hopefully...
171 var rec = _this.store.getAt(pos);
172 if (typeof(rec.data.rss_body) == 'undefined') {
177 mask : 'Fetching Article',
178 url : baseURL + '/FeedBody/' + id,
179 success : function(res) {
180 rec.data.rss_body = res.responseText;
181 _this.article_ctr.showArticle(pos);
190 abody.update(rec.data.rss_body || "Body has not been loaded",false, function() {
191 //Roo.log("body loaded");
193 var w = Roo.lib.Dom.getViewportWidth();
195 // resize the images...
196 Roo.select('img', true).each(function(im) {
197 if (im.getWidth() > w) {
198 var sf = w/im.getWidth()
199 im.setSize(w, im.getHeight() * sf);
207 // hide the summary...
213 Roo.get(document.body).unmask();
215 Roo.select('.rss-art-count').first().update((this.pos +1) +'/' + this.articles.elements.length);
217 // flag it as read...
221 url : baseURL + '/FeedBody/' + id,
222 params : { flag_read : 1 },
223 success : function(res) { },
227 Roo.select('.rss-list-article-' +id +
228 ' .count').first().dom.innerHTML = 'Read';
230 Roo.select('.rss-list-article-' +id).addClass('rss-list-article-read-status-1');
232 Roo.select('.rss-list-article-' +id +
235 Roo.select('.rss-list-article-' +id +
236 ' .count').first().dom.innerHTML = 'Read';
238 Roo.select('.rss-list-article-' +id +
239 ' .chevron').first().hide();
242 //Roo.select('header h2').first().dom.innerHTML = this.feed_title + ' - ' +
243 // art.select('.rss-title').first().dom.innerH
246 '|xns' : 'Roo.bootstrap',
253 '|xns' : 'Roo.bootstrap',
258 html : _this._strings['44749712dbec183e983dcd78a7736c41'] /* Date */,
261 '|xns' : 'Roo.bootstrap',
266 html : _this._strings['eae639a70006feff484a39363c977e24'] /* Domain */,
269 '|xns' : 'Roo.bootstrap',
274 html : _this._strings['b78a3223503896721cca1303f776159b'] /* Title */,
277 '|xns' : 'Roo.bootstrap',