IRC Chat : 2012-12-07 - OpenMRS

01:07:06 *** sgithens has joined #openmrs
01:47:29 *** wyclif_ has joined #openmrs
02:05:36 *** sgithens has quit IRC
02:35:36 *** sgithens has joined #openmrs
03:29:44 *** andreap_ has quit IRC
04:12:04 *** djazayeri has quit IRC
04:18:21 *** djazayeri has joined #openmrs
04:18:21 *** ChanServ sets mode: +o djazayeri
05:27:27 *** kishoreyekkanti has joined #openmrs
05:27:37 *** travis-ci has joined #openmrs
05:27:37 <travis-ci> [travis-ci] [openmrs/openmrs-core] [42de544] [Kishore Kumar Yekkanti] The build passed. - http://travis-ci.org/openmrs/openmrs-core/builds/3543942
05:27:37 *** travis-ci has left #openmrs
05:27:41 <OpenMRSBot> <http://ln-s.net/+Ew6> (at travis-ci.org)
06:01:53 *** djazayeri has quit IRC
06:06:57 *** djazayeri has joined #openmrs
06:06:57 *** ChanServ sets mode: +o djazayeri
06:22:08 *** robbyoconnor has joined #openmrs
06:22:08 *** ChanServ sets mode: +v robbyoconnor
06:40:20 *** shangxiao has joined #openmrs
06:49:05 *** Abi222 has joined #openmrs
06:50:15 *** Abi222 has quit IRC
07:08:40 *** djazayeri has quit IRC
07:53:14 *** dkayiwa has joined #openmrs
07:59:23 *** dkayiwa has quit IRC
08:00:45 *** dkayiwa has joined #openmrs
09:42:31 *** suranga has joined #openmrs
09:42:31 *** ChanServ sets mode: +v suranga
09:51:13 *** rafa has joined #openmrs
09:51:13 *** ChanServ sets mode: +v rafa
10:15:44 *** robbyoconnor has quit IRC
10:19:29 *** shangxiao has quit IRC
10:22:16 *** suranga_ has joined #openmrs
10:24:45 *** travis-ci has joined #openmrs
10:24:45 <travis-ci> [travis-ci] [openmrs/openmrs-core] [0cc8576] [rkorytkowski] The build passed. - http://travis-ci.org/openmrs/openmrs-core/builds/3546296
10:24:45 *** travis-ci has left #openmrs
10:24:48 <OpenMRSBot> <http://ln-s.net/+EzS> (at travis-ci.org)
10:24:48 *** suranga has quit IRC
10:44:59 *** suranga__ has joined #openmrs
10:48:47 *** suranga_ has quit IRC
10:50:00 *** yony258 has joined #openmrs
10:50:56 *** shangxiao has joined #openmrs
10:52:30 <yony258> dkayiwa: Hi, commented on some of you comments in the review, please look at them. Thank you :]
10:53:57 *** suranga__ has quit IRC
10:54:19 <dkayiwa> yony258: ok :)
11:02:54 <dkayiwa> hi yony258
11:03:51 <yony258> dkayiwa: hi
11:04:30 <dkayiwa> yony258: what do you mean by this:
11:04:30 <dkayiwa> yony258: Patient's didn't missed last appointment.
11:05:02 <yony258> dkayiwa: without the 's
11:05:29 <dkayiwa> yony258: so what should the whole line be like
11:06:14 <yony258> dkayiwa: "Last Appointment: patient didn't missed last appointment"
11:09:05 <dkayiwa> yony258: missed or miss?
11:09:25 <yony258> dkayiwa: miss I guess
11:09:41 <dkayiwa> yony258: ok now you can change it
11:23:11 *** dkayiwa has quit IRC
11:26:27 *** dkayiwa has joined #openmrs
11:32:53 *** shangxiao has quit IRC
11:35:39 <yony258> dkayiwa: I cant the that Hibernate query
11:35:47 <yony258> dkayiwa: (cant do)
11:37:40 <yony258> dkayiwa: It will be a lot more complicated then just doing that in the logic layer. Appointment dont have a start date, it's time slot has the start date.
11:56:08 <dkayiwa> yony258: that logic belongs to the data access layer
11:57:28 <yony258> dkayiwa: ok then I will need some help writing that HQL query, I need to join appointment and timeslot for the given patient, and then get the max start date and then get the appointment that has that start date
11:58:29 <yony258> dkayiwa: sorry thats incorrect, the last phase is to get the appointment that has that time slot that has the max start date for the given patient.
11:58:46 <dkayiwa> yony258: ok will write it for you :)
11:59:30 <yony258> dkayiwa: hmm ok
12:00:53 <dkayiwa> yony258: but if you can write it, then i can leave it to you :)
12:01:24 <yony258> dkayiwa: I really want to learn how to write it, But have exactly 0 idea how to do that.
12:01:35 <dkayiwa> yony258: ok
12:22:04 *** ningosi has joined #openmrs
12:44:39 <yony258> dkayiwa: I wrote a draft, do you have time to check it?
12:45:08 <dkayiwa> yony258: draft what?
12:45:39 *** ningosi has quit IRC
12:46:36 <yony258> dkayiwa:http://pastebin.com/7Cc99E8J
12:46:46 <dkayiwa> yony258: does it work?
12:47:27 <yony258> dkayiwa: nevermind, It won't work
12:47:34 <dkayiwa> yony258: ok
12:56:43 *** dkayiwa has quit IRC
13:00:18 *** dkayiwa has joined #openmrs
13:01:29 *** kishoreyekkanti_ has joined #openmrs
13:02:38 <yony258> dkayiwa: How do I tell hibernate to give the appointment from an inner join between appointment and timeSlot?
13:03:32 <dkayiwa> yony258: have you had a look at some of the openmrs-core hibernate daos?
13:03:39 <dkayiwa> yony258: that do the same?
13:03:42 *** kishoreyekkanti has quit IRC
13:03:42 *** kishoreyekkanti_ is now known as kishoreyekkanti
13:04:26 <yony258> dkayiwa: It was more confusing than helpful, maybe if you can direct me to a specific example?
13:05:14 <dkayiwa> yony258: ok
13:07:43 <dkayiwa> yony258: have you tried to google about how to do hibernate join queries?
13:08:03 <yony258> dkayiwa: I wouldn't ask before doing that...
13:09:36 *** kishoreyekkanti_ has joined #openmrs
13:11:34 *** kishoreyekkanti has quit IRC
13:11:35 *** kishoreyekkanti_ is now known as kishoreyekkanti
13:12:41 <dkayiwa> yony258: do understand your query, what would be its plain sql equivalent?
13:13:25 <yony258> dkayiwa: Yes, I wrote down the structure of the query that I need to do, it has 2 subqueries. Im writing each one right now
13:16:20 <dkayiwa> yony258: ok tell me when done
13:22:32 <rafa> !ticket TRUNK-3776
13:22:34 <OpenMRSBot> rafa: [#TRUNK-3776] Username validation is not the same between API and web application - OpenMRS JIRA - https://tickets.openmrs.org/browse/TRUNK-3776
13:22:43 <rafa> dkayiwa: ^ ^ ^
13:22:48 <dkayiwa> rafa: ok
13:24:20 *** travis-ci has joined #openmrs
13:24:20 <travis-ci> [travis-ci] [openmrs/openmrs-core] [88e3f05] [rkorytkowski] The build passed. - http://travis-ci.org/openmrs/openmrs-core/builds/3548394
13:24:20 *** travis-ci has left #openmrs
13:24:24 <OpenMRSBot> <http://ln-s.net/+F1t> (at travis-ci.org)
13:29:18 <yony258> dkayiwa: http://pastebin.com/E1z3fchS (Not working because of the HQL query I wrote)
13:29:31 *** Vishrut has joined #openmrs
13:31:10 <dkayiwa> yony258: how do you tell that it does not work?
13:31:26 <yony258> dkayiwa: I tried to run the Unit Test
13:31:33 <dkayiwa> yony258: and?
13:31:54 <yony258> dkayiwa: The error said that something is wrong with the query, do you want the exact error?
13:32:00 <yony258> dkayiwa: *the specific error
13:32:05 <dkayiwa> yony258: can you pastebin it
13:32:50 <yony258> dkayiwa: http://pastebin.com/Jt6KgXKE
13:32:55 <dkayiwa> yony258: ok
13:33:42 <dkayiwa> yony258: you are using SQL instead of HQL
13:34:03 <yony258> dkayiwa: explain
13:34:08 <dkayiwa> yony258: hibernate query language is slightly different from SQL
13:34:37 <dkayiwa> yony258: for SQL, you would use the createSQLQuery instead of createQuery
13:36:31 <yony258> dkayiwa: I probably forgot to mention that I do not know HQL
13:37:59 <dkayiwa> yony258: for plain sql you use createSQLQuery
13:38:08 <dkayiwa> yony258: instead of createQuery
13:38:14 <yony258> dkayiwa: This isnt an SQL syntax
13:38:30 <yony258> dkayiwa: I couldn't say timeSlot.startDate in SQL
13:38:56 <dkayiwa> yony258: can you write the SQL equivalent. Then i can convert it for you into HQL
13:39:27 <yony258> dkayiwa: ok
13:55:11 *** kjoseph has joined #openmrs
13:55:30 <kjoseph> dkayiwa: hi
13:55:38 <dkayiwa> kjoseph: hi
13:56:20 *** travis-ci has joined #openmrs
13:56:20 <travis-ci> [travis-ci] [openmrs/openmrs-core] [2019690] [rkorytkowski] The build passed. - http://travis-ci.org/openmrs/openmrs-core/builds/3548816
13:56:20 *** travis-ci has left #openmrs
13:56:24 <OpenMRSBot> <http://ln-s.net/+F2K> (at travis-ci.org)
13:57:16 <yony258> dkayiwa: something like this: http://pastebin.com/RHyq366R
13:57:27 <dkayiwa> yony258: ok
13:59:37 *** kjoseph has quit IRC
14:00:15 <dkayiwa> yony258: can you use that sql with createSQLQuery() ?
14:05:11 <yony258> dkayiwa: Can you just send me the HQL that does what we are trying to do?
14:06:23 <dkayiwa> yony258: i want to base on a working sql
14:06:47 <dkayiwa> yony258: so i want to make sure you sql does not throw errors with createSQLQuery()
14:06:56 <dkayiwa> yony258: createSQLQuery() takes on plan sql
14:07:19 *** kjoseph has joined #openmrs
14:18:34 *** sgithens has quit IRC
14:26:41 <yony258> dkayiwa: http://pastebin.com/FwsWYKa9
14:27:06 <yony258> dkayiwa: This works on MySQL but not on createSQLQuery
14:27:27 <dkayiwa> yony258: ok looking at it
14:27:55 <dkayiwa> yony258: can you try do a copy and paste into mysql?
14:28:35 <yony258> dkayiwa: It now works on createSQLQuery too, what?
14:29:03 <dkayiwa> yony258: that was if it was not working in code
14:32:34 *** wyclif_ has quit IRC
14:32:59 *** k-joseph has joined #openmrs
14:37:32 *** kjoseph has quit IRC
14:37:54 *** kishoreyekkanti has quit IRC
14:56:26 *** cpower has quit IRC
14:57:04 *** cpower has joined #openmrs
14:57:38 <cpower> IRC is being funky for me today, so if I drop, I apologize
14:57:50 <yony258> dkayiwa: Cya on Sunday or Monday, thanks
14:58:00 <dkayiwa> yony258: cya
14:58:07 *** yony258 has quit IRC
15:01:57 <cpower> Let's get to the Scrum
15:02:04 <cpower> !scrumon cpower
15:02:04 * OpenMRSBot says the DAILY SCRUM MEETING is STARTING. This meeting should not last longer than 15 minutes. Please hold other comments until the end of the meeting, or message someone privately. Thank you! ScrumMaster cpower- you may begin when ready.
15:02:19 *** djazayeri has joined #openmrs
15:02:19 *** ChanServ sets mode: +o djazayeri
15:02:20 <cpower> small..small crowd
15:02:57 *** andrea_ has joined #openmrs
15:03:06 <cpower> Order: rafa, dkayiwa, djazayeri, andrea when she shows...
15:03:18 <rafa> hi
15:03:19 <rafa> Yesterday:
15:03:20 <rafa> * More preparations for 1.9.2
15:03:20 <rafa> * Back porting
15:03:20 <rafa> * Dev call
15:03:20 <rafa> Today:
15:03:20 <rafa> * Committed TRUNK-3776: Username validation is not the same between API and web application
15:03:20 <rafa> https://tickets.openmrs.org/browse/TRUNK-3776
15:03:21 <rafa> * Tested TRUNK-2511: When creating a new patient, pre-populate the "Identifier Type" field
15:03:21 <rafa> https://tickets.openmrs.org/browse/TRUNK-2511
15:03:22 <rafa> * Back porting
15:03:22 <rafa> * Later today or tomorrow will release 1.9.2
15:03:23 <rafa> No blockers.
15:03:30 <andrea_> hey cpower, i'm here
15:03:54 <dkayiwa> Reviewed code for Tobin's Team
15:03:54 <dkayiwa> Guided Tobin's team with their current tasks
15:03:54 <dkayiwa> Committed: Retrieving a ProgramWorkflow by name in a the ModuleActivator started method throws an error - TRUNK-3739
15:03:54 <dkayiwa> Now reviewing: Username validation is not the same between API and web application - TRUNK-3776
15:03:55 <dkayiwa> No Blockers
15:04:34 <djazayeri> Calls
15:04:43 <djazayeri> Planning for 2.0 Reference Application kickoff
15:04:48 <djazayeri> Design for Mirebalais
15:04:50 <djazayeri> no blockers
15:04:53 <andrea_> Thursday
15:04:53 <andrea_> Dev call
15:04:53 <andrea_> JSPs for TRUNK-2768
15:04:53 <andrea_> Friday
15:04:53 <andrea_> Merck meeting
15:04:54 <andrea_> Finish working on TRUNK-2768
15:04:56 <andrea_> Blockers
15:04:58 <andrea_> If error on another required field
15:05:00 <andrea_> Estimated checkbox looses value
15:05:02 <andrea_> So does Cause of Death textbox info
15:05:03 <k-joseph> dkayiwa: i have sent u a mail
15:05:04 <andrea_>
15:05:14 <dkayiwa> k-joseph: responded
15:05:15 <cpower> dk
15:05:15 <cpower> dkayiwa you are up!
15:05:15 <cpower> djazayeri
15:05:25 <cpower> ok,
15:05:42 <cpower> Who can help Andrea with her questions?
15:05:44 *** afiles has joined #openmrs
15:05:51 <cpower> beyond that, we are good. Happy Friday everyone.
15:06:05 <cpower> !scrumoff
15:06:05 * OpenMRSBot says the DAILY SCRUM MEETING has ENDED. This channel is now returned to normal hacking operations. Post-scrum meeting follow-up conversations may now begin.
15:06:07 <dkayiwa> cpower: ^^ :)
15:06:10 <djazayeri> andrea_: can you ask more clearly?
15:06:39 <andrea_> If error on another required field
15:06:39 <andrea_> Estimated checkbox looses value
15:06:39 <andrea_> So does Cause of Death textbox info
15:06:56 <dkayiwa> andrea_: which controller is backing up that page?
15:07:37 <andrea_> This is on the shortPatient Form
15:07:54 <andrea_> think that's the problem - a controller -
15:08:05 <andrea_> new to this part of system
15:08:51 <dkayiwa> andrea_: does other fields also loose values? or only your new fields?
15:08:56 <djazayeri> andrea_: if I remember how that page works, the jsp has <spring:bind> for each field, and the controller defines the patient (or something) as a command object
15:09:05 <djazayeri> andrea_: have you used <spring:bind> with your new fields?
15:11:04 <andrea_> djazayeri, on patient.deathdateEstimated - which inherits from Person, right?>
15:11:18 <djazayeri> andrea_: typically what happens is that on the controller method that handles the submit, it binds any submitted parameters to the command object, then it validates the command object. If there are any errors, it redisplays the form. (At this point the command object should have the values for your new fields set...)
15:11:39 *** wyclif_ has joined #openmrs
15:11:47 <djazayeri> andrea_: that sounds right—you're the one who created that field, so I assume that's the right name
15:12:03 <djazayeri> andrea_: you also need to have your <input> elements support an initial value
15:12:18 <andrea_> djazayeri, this is where it's losing the values
15:12:45 <andrea_> djazayeri, do have initial vale - not checked
15:13:25 <djazayeri> andrea_: can you send a code snippet via pastebin?
15:13:48 <andrea_> djazayeri, this is happening on Cause of Death too
15:15:19 <djazayeri> andrea_: are those fields being hidden until the [ ]deceased checkbox is checked?
15:15:27 <djazayeri> and shown via javascript or something?
15:17:07 <andrea_> djazayeri, pastebin.com/JsvixSzk
15:17:20 *** sgithens has joined #openmrs
15:18:41 <andrea_> djazayeri, no not hidden
15:18:56 *** suranga has joined #openmrs
15:18:56 *** ChanServ sets mode: +v suranga
15:20:04 <djazayeri> andrea_: I don't believe you need the updateEstimatedDeathdate function.
15:20:07 <djazayeri> what is that doing?
15:20:19 <djazayeri> also, why do you have the checkbox tied to the value of false?
15:20:56 <andrea_> djazayeri, false so it won't be checked in the beginning
15:21:08 <djazayeri> finally, I think you need to have an <input type="hidden" name="_${status.expression}"/>
15:21:13 <djazayeri> andrea_: that's not what "value" does.
15:21:36 <djazayeri> andrea_: "value" for a checkbox is the value that will be submitted for the parameter if it _is_ checked.
15:21:56 <djazayeri> andrea_: otherwise (if its not checked) no field is submitted.
15:22:38 <djazayeri> andrea_: it's the c:if test and "checked" that will initially check the box
15:22:47 <andrea_> djazayeri, ooh - will try that
15:26:34 *** dkayiwa has left #openmrs
15:27:21 <andrea_> djazayeri, thanks Spring JSPs are new to me
15:28:22 <andrea_> djazayeri, why don't I need the updateEstimatedDeathdate function?
15:28:31 *** k-joseph has quit IRC
15:28:32 <djazayeri> andrea_: what is that function doing?
15:28:52 *** afiles has quit IRC
15:28:57 <andrea_> djazeri, isn't that what updates it when you check it?
15:29:34 *** cpower has quit IRC
15:29:40 <djazayeri> andrea_: no. if you look at the updateEstimated function that was already there...
15:30:45 *** travis-ci has joined #openmrs
15:30:45 <travis-ci> [travis-ci] [openmrs/openmrs-core] [316d129] [dkayiwa] The build passed. - http://travis-ci.org/openmrs/openmrs-core/builds/3550458
15:30:45 *** travis-ci has left #openmrs
15:30:49 <OpenMRSBot> <http://ln-s.net/+F3m> (at travis-ci.org)
15:31:06 <djazayeri> andrea_: that is particular called because when you enter an age, it should automatically mark as estimated, as well as some other logic that is supposed to coordinate between age, birthdate, and birthdate estimated.
15:31:30 <djazayeri> andrea_: for deathdateEstimated, we just want a checkbox, without any extra special behavior. If the user clicks it, it's checked, otherwise not.
15:32:23 <andrea_> djazayeri, ok will try with no updateEstimatedDeathdate function.
15:35:15 <andrea_> djazayeri, and yes they are hidden until deceased is checked
15:35:51 <andrea_> djazayeri, just need to retain value if checked - think I got it now
15:36:59 *** yony258 has joined #openmrs
15:50:13 *** nribeka has joined #openmrs
15:50:13 *** ChanServ sets mode: +v nribeka
15:53:18 <suranga> hi nribeka || jkeiper :-)
15:53:33 <suranga> nribeka, || jkeiper wheres Michael ? he seems to be missing :-)
15:53:33 <nribeka> hi suranga boy
15:53:44 <nribeka> he's here
15:53:53 <nribeka> talking with jamie
15:53:55 <suranga> nribeka, howdy ! hows life at the wedge ? :P
15:54:09 <suranga> nribeka, aha, I was wondering cos we didnt see him on IRC lately
15:54:30 <nribeka> good, at least nobody is taking picture here
15:55:23 <nribeka> anyone with standalone expertise: http://pastebin.com/wGTDQifD
15:55:31 <nribeka> the stack trace is stuck there :D
15:56:19 <suranga> nribeka, :P
16:10:03 *** rafa has quit IRC
16:13:23 *** lh has joined #openmrs
16:15:14 *** lh has quit IRC
16:15:18 <OpenMRSBot> Recent updates in the world of openmrs: OpenMRS Modules: Program Location 1.0 uploaded to OpenMRS Module Repository <https://modules.openmrs.org/modules/view.jsp?module=programlocation&ampversion=&amp1.0>
16:19:59 *** robbyoconnor has joined #openmrs
16:19:59 *** ChanServ sets mode: +v robbyoconnor
16:25:01 *** robbyoconnor has quit IRC
16:25:20 *** robbyoconnor has joined #openmrs
16:25:20 *** ChanServ sets mode: +v robbyoconnor
16:25:40 <yony258> In need of help with HQL query because I don't have a lot of experience with Hibernate, any help will be appreciated :)
16:50:13 <nribeka> post your question here yony258
16:50:36 <yony258> nribeka: Oh tnx, I sorted it out but thank you
17:13:47 *** yony258 has quit IRC
17:19:05 *** andrea_ has quit IRC
17:23:57 *** rafa has joined #openmrs
17:23:57 *** ChanServ sets mode: +v rafa
17:24:48 *** robbyoconnor has quit IRC
17:46:00 *** Vishrut has quit IRC
18:08:46 *** rafa has quit IRC
18:27:28 *** rafa has joined #openmrs
18:27:28 *** ChanServ sets mode: +v rafa
20:33:40 *** nribeka has quit IRC
20:53:49 *** sgithens has quit IRC
21:11:39 *** rafa has quit IRC
21:14:15 *** rafa has joined #openmrs
21:14:15 *** ChanServ sets mode: +v rafa
21:17:22 <djazayeri> wyclif_: I think you know the answer to "extension at the bottom of the find patient page is added twice". :-)
21:18:02 <wyclif_> djazayeri, yeah, i wasnt sure, sometime they are added twice with a reason
21:18:26 <djazayeri> wyclif_: I can't think of any reason to show them twice.
21:20:38 *** suranga has quit IRC
21:20:55 *** rafa has quit IRC
21:21:24 *** rafa has joined #openmrs
21:21:24 *** ChanServ sets mode: +v rafa
21:47:04 *** rafa has quit IRC
21:47:32 *** rafa has joined #openmrs
21:47:32 *** ChanServ sets mode: +v rafa
21:55:49 *** rafa has quit IRC
21:56:21 *** rafa has joined #openmrs
21:56:21 *** ChanServ sets mode: +v rafa
22:00:11 *** wyclif_ has quit IRC
22:04:48 *** wyclif_ has joined #openmrs
22:45:58 *** robbyoconnor has joined #openmrs
22:45:58 *** ChanServ sets mode: +v robbyoconnor
22:54:33 *** andreapat has joined #openmrs
23:06:34 *** wyclif_ has quit IRC
23:16:58 *** rafa has quit IRC