#silverstripe IRC Log

IRC log for 11 January 2017

All timestamps are in UTC.

1: [00:06:17] * vanny has joined #silverstripe
2: [00:06:38] <vanny> morning all
3: [00:07:24] <vanny> is there a action to cleanup (eg delete all the images that are created from setWidths etc)
4: [00:08:24] <samsamek> a framework-wide ‘cleanup’ function is a bit too abstract
5: [00:08:58] <samsamek> there is the ->delete() method you can call to remove database records
6: [00:12:39] * Uitto quit (Ping timeout: 272 seconds)
7: [00:12:51] * jbrungar quit (Ping timeout: 240 seconds)
8: [00:14:00] * Uitto has joined #silverstripe
9: [00:18:12] * jbrungar has joined #silverstripe
10: [00:18:45] <vanny> i found the dev/task as a clean up. Just wondering howlong it takes
11: [00:25:36] <vanny> and if it will alert me when done
12: [00:27:28] <Tron> look in reports, its there if anywhere
13: [00:31:58] <vanny> nothing in there :( i wonder if I just delete the _resample folder :P
14: [00:35:32] <Tron> is that where the setWidths go? it will just delete the images Im pretty sure, the file itself in the database will still persist
15: [00:35:53] <Tron> But then
16: [00:36:12] <Tron> silverstripe may have some sort of cleanup broken links
17: [00:36:55] <Tron> im not really sure, don't quote me on it
18: [00:38:33] <vanny> not much luck. Yet, I dont think it stores them in the database
19: [00:40:51] <vanny> my clients users have gotten a little carried away with the file uploading, and I have about 13000 thumbnails
20: [00:46:06] <DanaeNZ> vanny: I'm pretty sure there's a task to clean up resampled images
21: [00:46:34] <vanny> I tried it, dont think it worked. as I still can see them all
22: [00:49:20] <DanaeNZ> which SS version are you running? I think after 3.1 there was a bit of an overhaul and they changed the structure of the resampled folders
23: [00:49:30] <DanaeNZ> so the task I'm thinking of doesn't appear to be there nw
24: [00:49:36] * janneklouman-- has joined #silverstripe
25: [00:50:52] <vanny> fortunately this is an older install running 3.1 but the task didnt work
26: [00:53:51] * janneklouman-- quit (Ping timeout: 240 seconds)
27: [01:07:15] * muskie9 has joined #silverstripe
28: [01:08:02] * micmania1 quit (Quit: micmania1)
29: [01:17:52] <Nightjar> whatup fam
30: [01:18:13] <muskie9> Nightjar o/
31: [01:24:58] <Nightjar> Tron, explain to me this blade, and why it should be looked into
32: [01:27:38] <Nightjar> ... from your point of view (I know I could read docs, but ain't no body got time fo that ;) you can be more contextual than internet specifications)
33: [01:28:27] <Tron> Im Just thinking of a to use $data from vue in silverstripe templates. Obviously wont work. Could you explain to me why I can create some custom dataattributes for forms yet others wont work?
34: [01:29:06] <Tron> http://pastebin.com/jWqWw9zj
35: [01:29:21] <Nightjar> Maybe. In the mean time could you answer my question too? :>
36: [01:29:47] <Nightjar> also, what SS version are you using?
37: [01:29:49] <Tron> "p-on" works and comes through on the html, v-on doesnt
38: [01:29:56] <Tron> I can
39: [01:36:24] <Tron> This is what I meant when I was talking about blade(works differently). It would be nice If we could put something like $data in an ss template and put something around it to let silverstripe know its not a silverstripe variable
40: [01:43:04] <Tron> Ok, anything starting with v is being stripped? and only the letter 'v"........why........
41: [01:44:14] <Nightjar> you sure it's not the colon?
42: [01:44:28] <Nightjar> it's probably whatever libXML will allow.
43: [01:44:41] <Nightjar> (via DOMDocument)
44: [01:44:41] <Tron> 100% sure
45: [01:44:45] <Tron> its the letter v
46: [01:44:53] <Tron> where would I find that sorry?
47: [01:44:54] <Nightjar> but not say "vindaloo"?
48: [01:45:02] <Nightjar> php.net/domdocument
49: [01:46:13] <Nightjar> https://github.com/silverstripe/silverstripe-framework/blob/3.5/forms/Form.php#L862
50: [01:46:30] <Nightjar> Nup. Dunno why though.
51: [01:46:34] * micmania1 has joined #silverstripe
52: [01:47:39] <Tron> Ok narrowed it down to being 'v-on' lol
53: [01:48:11] <Tron> http://pastebin.com/0a9eHCHX
54: [01:48:30] <Nightjar> but not v-off?
55: [01:48:38] <Nightjar> or van?
56: [01:48:43] <Nightjar> or V-on?
57: [01:48:55] <Nightjar> or v+on ?
58: [01:49:05] <Nightjar> or v_on ?
59: [01:50:39] <Tron> all work other than v-on & V-on
60: [01:59:01] <Nightjar> weird. I'd open an issue on github.
61: [01:59:21] <Nightjar> you could break out the debugger and step through to see where it's unset if you wanted.
62: [02:01:33] * micmania1 quit (Quit: micmania1)
63: [02:04:40] * muskie9 quit (Quit: Textual IRC Client: www.textualapp.com)
64: [02:06:46] <Nightjar> Tron, as a work around you can always specify the template for the form to use, and set the v-on manually (via copy, rename and edit the default Form.ss to your theme/app folder)
65: [02:08:12] * samsamek quit (Quit: samsamek)
66: [02:09:24] <Nightjar> Tron, so what are the things blade has over SS templates?
67: [02:11:28] <Tron> Absolutely nothing after I looked into it. I thought it may allowed what I describedc
68: [02:11:48] <Nightjar> colleage here is suggesting perhaps trying the shorthand for v-on, @
69: [02:12:03] <Nightjar> i.e. @:input
70: [02:12:03] <Tron> As for your above solution, Cant do that eiter, That was my first thought. So so strange
71: [02:12:34] <Nightjar> wait what?
72: [02:12:53] <Nightjar> you can't manually put <form v-on:thing="something"> into a template?
73: [02:13:06] <Nightjar> like, raw?
74: [02:13:08] * micmania1 has joined #silverstripe
75: [02:13:31] * cheddam has joined #silverstripe
76: [02:14:54] <Nightjar> putting it raw into a template should work, no question. If it's not, then either you're doing something screwey with the form (idk the rest of your logic), or the output is passing through some kind of filter first
77: [02:15:35] <Nightjar> or wait, do you mean adding direct to template won't work either, or that you can't use the shorthand @ either?
78: [02:15:54] <Nightjar> (in getAttributes)
79: [02:15:59] * vanny quit (Quit: Page closed)
80: [02:16:24] <Nightjar> btw, you don't need to subclass form just to add attributes, setAttribute does that ;) (I guess your form has more logic to it, but in case not...)
81: [02:16:47] <Tron> I can use p-on in the template and it comes through
82: [02:16:56] <Tron> but again no v-on
83: [02:17:01] <Nightjar> but if you put v-on directly in the template, it still doesn't work?
84: [02:17:10] <Nightjar> did you try @ yet?
85: [02:18:39] <cheddam> I've successfully written Vue apps in SS templates with no issue... Definitely seems like there's some sort of intermediary parsing going on
86: [02:18:46] <Tron> wont allow any @anything in the template...
87: [02:18:55] <cheddam> Do any other v- attributes work / fail?
88: [02:20:05] <Nightjar> How are you outputting the form?
89: [02:20:46] <Tron> Cheddam have a look at around 2 mins into this video
90: [02:20:50] <Tron> https://laracasts.com/series/learning-vue-step-by-step/episodes/2
91: [02:21:30] <Tron> I can get {{ message }} etc fine {{ $data | message }} of course wont work. Is an edge case of course
92: [02:21:45] <Tron> simply like this $AddTrackForm
93: [02:21:59] <cheddam> Oh right, so SS is generating the HTML
94: [02:22:09] <cheddam> And is ignoring 'invalid' attributes
95: [02:22:24] <Nightjar> yup, it'll be going through DOMDocument
96: [02:22:33] <Nightjar> it's not part of Form proper
97: [02:22:58] <Nightjar> but if the output is cast to a string then back out, it'll be filtered through DOMDocument from memory
98: [02:23:01] <cheddam> Wonder if there's an API for defining allowed custom attributes
99: [02:23:13] <Nightjar> yeah but all the other custom attributes seem to work
100: [02:23:16] <Nightjar> so, that's weird.
101: [02:23:21] <Tron> Agrred
102: [02:23:26] <Tron> very puzzling
103: [02:23:56] <cheddam> I'm guessing you're aware Vue 2 is out by the way? :D
104: [02:24:10] <Nightjar> so all the v-if and whatnot is fine, but just not v-on (so far as I understand it)
105: [02:24:40] <Tron> Haha yes, I'm trying to learn on 1 because thats where the tuts are at. Wanted to see how well it worked with silverstripe
106: [02:24:59] <cheddam> Laracasts has a big ongoing series covering Vue 2 :)
107: [02:25:08] <Tron> forms and that edge case for filters are two headaches I have found
108: [02:25:24] <Tron> Please do send me the link if it's easy for you to find
109: [02:25:49] <cheddam> My suggestion would be just to write the form HTML yourself in a custom template and point to that: https://docs.silverstripe.org/en/3/developer_guides/forms/form_templates/
110: [02:25:59] <Nightjar> yeah, I suggested that
111: [02:26:01] <cheddam> https://laracasts.com/series/learn-vue-2-step-by-step
112: [02:26:16] <Nightjar> since it appears to be this one edge case :/
113: [02:26:28] <Nightjar> also, github issue ftw ;)
114: [02:26:54] <Tron> Haha im getting there. accoint managers are pestering me for the most tedious task
115: [02:27:01] <Tron> why dont they understand
116: [02:27:16] <Tron> wait not tedious, tiny
117: [02:27:20] <Tron> changing a name
118: [02:27:22] * micmania1 quit (Quit: micmania1)
119: [02:27:48] <Nightjar> Because computers are hard.
120: [02:28:10] * micmania1 has joined #silverstripe
121: [02:37:27] <Tron> https://github.com/silverstripe/silverstripe-framework/issues/6474
122: [02:53:07] <Nightjar> By rendering with $MyForm you mean that's what it's factory method is called, Tron ?
123: [02:53:53] <Nightjar> and that's your basic return TronsForm::create($this, 'MyForm', $fields, $actions, $validation) ?
124: [02:55:23] <Tron> Correct. Sorry never submitted an issue before and am under the thumb here at old Samdog
125: [02:57:56] <Nightjar> Ah, well, rule of thumb is; more info on how to recreate the problem, the better :)
126: [03:02:20] * Tron quit (Ping timeout: 260 seconds)
127: [03:06:04] * Tron has joined #silverstripe
128: [03:17:04] * janneklouman-- has joined #silverstripe
129: [03:21:31] * janneklouman-- quit (Ping timeout: 240 seconds)
130: [03:45:44] <Nightjar> I said good day sir.
131: [03:45:44] * Nightjar quit (Remote host closed the connection)
132: [03:58:58] * Tron quit (Quit: Page closed)
133: [04:19:37] * neilf__ has joined #silverstripe
134: [04:32:54] * DanaeNZ quit (Quit: TIME TO FEED)
135: [04:45:08] <ss-helper> How do I customize <title> of SilverStripe pages - http://stackoverflow.com/questions/32305730/how-do-i-customize-title-of-silverstripe-pages
136: [04:50:57] * cheddam quit (Ping timeout: 248 seconds)
137: [04:52:13] * micmania1 quit (Quit: micmania1)
138: [07:40:08] * wmk has joined #silverstripe
139: [07:45:31] * Eliseth has joined #silverstripe
140: [07:52:45] * wmk_ has joined #silverstripe
141: [07:54:02] * wmk quit (Ping timeout: 260 seconds)
142: [08:17:17] * Mike123 has joined #silverstripe
143: [08:21:24] * pweh has joined #silverstripe
144: [08:24:35] * neilf__ quit (Quit: Connection closed for inactivity)
145: [08:52:51] * Teddy has joined #silverstripe
146: [09:06:05] * kinglozzer has joined #silverstripe
147: [09:07:21] * filisko has joined #silverstripe
148: [09:08:53] * samsamek has joined #silverstripe
149: [09:16:55] * janneklouman-- has joined #silverstripe
150: [09:50:59] * pweh quit (Read error: Connection reset by peer)
151: [09:51:31] * filisko quit (Ping timeout: 240 seconds)
152: [10:04:29] * filisko has joined #silverstripe
153: [10:31:07] * micmania1 has joined #silverstripe
154: [11:05:08] * cheddam has joined #silverstripe
155: [11:08:15] * gelignite has joined #silverstripe
156: [11:08:52] * janneklouman-- quit (Ping timeout: 260 seconds)
157: [11:20:08] * samsamek quit (Quit: samsamek)
158: [11:23:49] * samsamek has joined #silverstripe
159: [11:58:35] * cheddam quit (Quit: My MacBook has gone to sleep. ZZZzzz…)
160: [11:59:58] * samsamek quit (Quit: samsamek)
161: [12:02:05] * janneklouman-- has joined #silverstripe
162: [12:35:51] * micmania1 quit (Quit: micmania1)
163: [12:43:36] * samsamek has joined #silverstripe
164: [12:45:10] * filisko quit (Ping timeout: 240 seconds)
165: [12:50:38] * gelignite quit (Quit: http://bit.ly/1kso8Ta)
166: [13:00:42] * filisko has joined #silverstripe
167: [13:27:15] * UndefinedOffset has joined #silverstripe
168: [13:32:09] * filisko quit (Ping timeout: 256 seconds)
169: [13:41:08] * Teddy_ has joined #silverstripe
170: [13:42:30] * slievr1 has joined #silverstripe
171: [13:43:29] * slievr quit (Ping timeout: 256 seconds)
172: [13:44:16] * Teddy quit (Ping timeout: 248 seconds)
173: [13:45:35] * filisko has joined #silverstripe
174: [13:47:34] * janneklouman-- quit (Ping timeout: 240 seconds)
175: [13:51:06] * wmk_ quit (Quit: Leaving)
176: [14:05:57] * wmk has joined #silverstripe
177: [14:10:23] * janneklouman-- has joined #silverstripe
178: [14:10:30] * samsamek quit (Quit: samsamek)
179: [14:15:11] * filisko quit (Ping timeout: 240 seconds)
180: [14:18:24] * muskie9 has joined #silverstripe
181: [14:24:52] * filisko has joined #silverstripe
182: [14:48:47] * saiyan_ has joined #silverstripe
183: [14:50:12] * samsamek has joined #silverstripe
184: [14:51:51] * saiyan quit (Ping timeout: 240 seconds)
185: [14:51:51] * saiyan_ is now known as saiyan
186: [15:09:10] * Mike123 quit (Ping timeout: 260 seconds)
187: [15:16:56] * samsamek quit (Quit: samsamek)
188: [15:29:24] * samsamek has joined #silverstripe
189: [16:21:06] * samsamek quit (Quit: samsamek)
190: [16:28:42] * samsamek has joined #silverstripe
191: [16:35:01] * Eliseth quit (Quit: Textual IRC Client: www.textualapp.com)
192: [16:48:05] * filisko quit (Ping timeout: 255 seconds)
193: [16:51:34] * filisko has joined #silverstripe
194: [17:04:33] * slievr1 has left #silverstripe
195: [17:12:19] * janneklouman-- quit (Ping timeout: 258 seconds)
196: [17:29:12] * wmk quit (Ping timeout: 260 seconds)
197: [17:29:27] * kinglozzer quit ()
198: [17:32:48] * Teddy_ quit (Read error: Connection reset by peer)
199: [18:29:19] * DarjusIT has joined #silverstripe
200: [18:30:33] <DarjusIT> Hi all How many times on one save button press is onAfterWrite() executes? sometimes it seams that it executes 3-4 times on 1 save.
201: [18:44:15] * janneklouman-- has joined #silverstripe
202: [18:59:10] * janneklouman-- quit (Ping timeout: 240 seconds)
203: [19:00:01] * janneklouman-- has joined #silverstripe
204: [19:00:48] <samsamek> unlikely to be more than once
205: [19:00:57] <samsamek> is it a page you’re saving?
206: [19:01:49] <samsamek> pages are versioned, meaning different versions are stored in the database (for ‘draft’ and ‘history’) so perhaps that would cause it to be executed once for each ‘version’
207: [19:06:40] * filisko quit (Ping timeout: 240 seconds)
208: [19:15:23] <ss-helper> SilverStripe how to return JSON headers - http://stackoverflow.com/questions/41598759/silverstripe-how-to-return-json-headers
209: [19:22:19] * filisko has joined #silverstripe
210: [19:25:17] * janneklouman-- quit (Read error: Connection reset by peer)
211: [19:31:21] * janneklouman-- has joined #silverstripe
212: [19:35:31] * janneklouman-- quit (Ping timeout: 240 seconds)
213: [19:42:33] * muskie9 quit (Ping timeout: 240 seconds)
214: [19:43:10] * samsamek quit (Quit: samsamek)
215: [19:56:57] * adrexia has joined #silverstripe
216: [19:58:55] * Phlunk3 has joined #silverstripe
217: [20:32:10] * micmania1 has joined #silverstripe
218: [21:04:41] * filisko quit (Ping timeout: 252 seconds)
219: [21:09:11] * samsamek has joined #silverstripe
220: [21:10:45] * micmania1 quit (Quit: micmania1)
221: [21:15:49] * cheddam has joined #silverstripe
222: [21:17:05] * micmania1 has joined #silverstripe
223: [21:17:17] * filisko has joined #silverstripe
224: [21:23:30] * zippy has joined #silverstripe
225: [21:25:54] <zippy> Hello
226: [21:59:53] * UndefinedOffset quit (Quit: Leaving.)
227: [22:05:51] * keksters has joined #silverstripe
228: [22:10:21] * DanaeNZ has joined #silverstripe
229: [23:00:02] * ss-helper quit (Remote host closed the connection)
230: [23:00:17] * ss-helper has joined #silverstripe
231: [23:05:11] * DimiStripe quit (Ping timeout: 260 seconds)
232: [23:07:20] * filisko quit (Ping timeout: 252 seconds)
233: [23:22:20] * DimiStripe has joined #silverstripe
234: [23:22:36] * filisko has joined #silverstripe
235: [23:46:47] * zippy quit (Quit: My MacBook has gone to sleep. ZZZzzz…)

These logs were automatically created by ss-log on irc.freenode.net.