emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* column-mode can not do an estimate effort summation on day/week modifiers
@ 2014-03-06  1:10 Jon Miller
  2014-03-07 15:11 ` Christian Egli
  0 siblings, 1 reply; 3+ messages in thread
From: Jon Miller @ 2014-03-06  1:10 UTC (permalink / raw)
  To: Org Mode

Hello,

I'm creating a new org file today and I'm using work estimates that use
day(d) and week(w) modifiers. Specifically, I have the following defined:
#+PROPERTY: Effort_ALL 0 1:00 4:00 1d 2d 1w 2w
#+COLUMNS: %40ITEM(Task) %17Effort(Estimated Effort){:} %CLOCKSUM

The problem I'm having is with column-mode and the estimate effort sum. It
appears that the normal effort summation wants purely HH:MM formatted work
estimates. I spent some time trying to understand that part of the code but
some of those column functions are pretty big (read: I'm a semi-literate
elisper). I did come up with the following to define my own summary-type ":d"

#+begin_src elisp
(add-to-list 'org-columns-compile-map
             '(":d" add_duration
               (lambda (&rest x) (apply '+ (mapcar 'org-duration-string-to-minutes (mapcar 'prin1-to-string x))))) t)
#+end_src

First version wasn't using the prin1-to-string and I noticed
"org-duration-string-to-minutes" was being passing only the integer part of
a "1d" work effort. Adding the prin1-to-string processing merely made it
not error anymore but still isn't doing what I'd like.

Is there a way to get the entire work effort passed to my function? Or a
better suggestion?

Thanks,
-- 
Jon Miller

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: column-mode can not do an estimate effort summation on day/week modifiers
  2014-03-06  1:10 column-mode can not do an estimate effort summation on day/week modifiers Jon Miller
@ 2014-03-07 15:11 ` Christian Egli
  2014-03-07 16:20   ` column-mode can not do an estimate effort summation onday/week modifierss Jon Miller
  0 siblings, 1 reply; 3+ messages in thread
From: Christian Egli @ 2014-03-07 15:11 UTC (permalink / raw)
  To: emacs-orgmode

Jon Miller <jonebird@gmail.com> writes:

> The problem I'm having is with column-mode and the estimate effort
> sum. 

What exactly is the problem? That the sum is not in Xd format? Don't
know if you can change that.

> It appears that the normal effort summation wants purely HH:MM
> formatted work estimates. 

I thought it also works with things like "1d". It simply converts these
to hh:mm AFAIK.

HTH
Christian
-- 
Christian Egli
Swiss Library for the Blind, Visually Impaired and Print Disabled
Grubenstrasse 12, CH-8045 Zürich, Switzerland

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: column-mode can not do an estimate effort summation onday/week modifierss
  2014-03-07 15:11 ` Christian Egli
@ 2014-03-07 16:20   ` Jon Miller
  0 siblings, 0 replies; 3+ messages in thread
From: Jon Miller @ 2014-03-07 16:20 UTC (permalink / raw)
  To: Christian Egli; +Cc: emacs-orgmode


Christian Egli <christian.egli@sbs.ch> writes:

> Jon Miller <jonebird@gmail.com> writes:
>
>> The problem I'm having is with column-mode and the estimate effort
>> sum. 
>
> What exactly is the problem? That the sum is not in Xd format? Don't
> know if you can change that.
>
>> It appears that the normal effort summation wants purely HH:MM
>> formatted work estimates. 
>
> I thought it also works with things like "1d". It simply converts these
> to hh:mm AFAIK.
>
> HTH
> Christian

Thanks for the reply. I actually updated to Org-mode version 8.2.5h and now
the estimate effort sum works correctly. I didn't send a self-reply answer
because I didn't want to create further noise.

Thanks,
-- 
Jon Miller

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-03-07 16:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-03-06  1:10 column-mode can not do an estimate effort summation on day/week modifiers Jon Miller
2014-03-07 15:11 ` Christian Egli
2014-03-07 16:20   ` column-mode can not do an estimate effort summation onday/week modifierss Jon Miller

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).