Closed
Bug 347381
Opened 20 years ago
Closed 20 years ago
Print monthly calendar for selected events fails [Error: aStart has no properties]
Categories
(Calendar :: Printing, defect)
Tracking
(Not tracked)
VERIFIED
FIXED
People
(Reporter: ssitter, Assigned: jminta)
Details
(Whiteboard: [no l10n impact])
Attachments
(2 files)
|
2.02 KB,
patch
|
mattwillis
:
first-review+
mvl
:
second-review+
|
Details | Diff | Splinter Review |
|
4.02 KB,
patch
|
mattwillis
:
first-review+
mvl
:
second-review+
|
Details | Diff | Splinter Review |
Print monthly calendar for selected events fails [Error: aStart has no properties]
Steps to Reproduce:
1. Start Sunbird, select normal event in view
2. Select 'File -> Print...' command
3. Set 'Layout' to 'Monthly Grid'
4. Set 'Range to print' to 'Selected events'
5. Press OK button
Actual Results:
Print preview opens but shows no calendar and no events only white space.
Error message shown in console:
Error: aStart has no properties
Source File: file:///D:/sunbird/js/calMonthGridPrinter.js Line: 88
Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9a1) Gecko/20060804 Calendar/0.3a2+
| Reporter | ||
Comment 1•20 years ago
|
||
Requesting blocking0.3?
If we announce printing as a main feature for 0.3 we should make it work too.
Flags: blocking0.3?
| Assignee | ||
Updated•20 years ago
|
Flags: blocking0.3? → blocking0.3+
| Assignee | ||
Comment 2•20 years ago
|
||
I had forgotten that aStart and aEnd were optional params when I wrote the original print-formatter.
Assignee: nobody → jminta
Status: NEW → ASSIGNED
Attachment #234090 -
Flags: second-review?(dmose)
Attachment #234090 -
Flags: first-review?(mattwillis)
Comment 3•20 years ago
|
||
Comment on attachment 234090 [details] [diff] [review]
calculate aStart/aEnd (checked in)
This is a bit hard to test since multiple selection isn't working, but from what I was able to test, and how I read the code, it looks okay.
r1=lilmatt
Attachment #234090 -
Flags: first-review?(mattwillis) → first-review+
Comment 4•20 years ago
|
||
Comment on attachment 234090 [details] [diff] [review]
calculate aStart/aEnd (checked in)
Do you really want to calculate aStart when aStart was passed in, but just no aEnd?
Also, don't assign to aStart itself.
| Assignee | ||
Comment 5•20 years ago
|
||
(In reply to comment #4)
> (From update of attachment 234090 [details] [diff] [review] [edit])
> Do you really want to calculate aStart when aStart was passed in, but just no
> aEnd?
If aStart was passed in, then it should be before any of the events. (If not, that would be a rather weird call, especially given the IDL comment "* May assume that all the items are inside the given daterange.")
In that case, there's very little extra computation here. We're already looping through the events to calculate the other param and the aStart.compare calls should all return -1.
> Also, don't assign to aStart itself.
>
I can fix that, but I'd like to know if you still feel the first comment should be addressed before I do so.
Comment 6•20 years ago
|
||
Comment on attachment 234090 [details] [diff] [review]
calculate aStart/aEnd (checked in)
ok, got it.
r=mvl, with the aStart assignment fixed.
Attachment #234090 -
Flags: second-review?(dmose) → second-review+
| Assignee | ||
Comment 7•20 years ago
|
||
patch checked in.
Status: ASSIGNED → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
| Reporter | ||
Comment 8•20 years ago
|
||
Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9a1) Gecko/20060825 Calendar/0.3a2+
Still fails. I repeated STR but had no event selected. That gave me:
Error: start has no properties
Source File: file:///D:/Programme/sunbird/js/calMonthGridPrinter.js
Line: 107
Then I repeated STR with event selected:
Error: [Exception... "Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [calIDateTime.compare]" nsresult: "0x80070057 (NS_ERROR_ILLEGAL_VALUE)" location: "JS frame :: file:///D:/Programme/sunbird/js/calMonthGridPrinter.js :: monthPrint_format :: line 119" data: no]
Source File: file:///D:/sunbird/js/calMonthGridPrinter.js
Line: 119
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
| Assignee | ||
Comment 9•20 years ago
|
||
This patch removes a couple of uses of aStart/aEnd where we should be using start/end. More importantly, it disabled the 'Selected Events' option if there are no selected events.
Attachment #235450 -
Flags: second-review?(dmose)
Attachment #235450 -
Flags: first-review?(mattwillis)
Comment 10•20 years ago
|
||
Comment on attachment 235450 [details] [diff] [review]
disable option
r1=lilmatt
Attachment #235450 -
Flags: first-review?(mattwillis) → first-review+
| Reporter | ||
Updated•20 years ago
|
Whiteboard: [patch in hand][waiting on dmose review]
Updated•20 years ago
|
Whiteboard: [patch in hand][waiting on dmose review] → [patch in hand][waiting on dmose review][no l10n impact]
Updated•20 years ago
|
Attachment #234090 -
Attachment description: calculate aStart/aEnd → calculate aStart/aEnd (checked in)
Comment 11•20 years ago
|
||
Comment on attachment 235450 [details] [diff] [review]
disable option
r=mvl
Attachment #235450 -
Flags: second-review?(dmose) → second-review+
Comment 12•20 years ago
|
||
Patch checked in on MOZILLA_1_8_BRANCH and trunk
-> FIXED
Status: REOPENED → RESOLVED
Closed: 20 years ago → 20 years ago
Resolution: --- → FIXED
Whiteboard: [patch in hand][waiting on dmose review][no l10n impact] → [no l10n impact]
| Reporter | ||
Comment 13•20 years ago
|
||
Verified with Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9a1) Gecko/20060907 Calendar/0.3a2+
Status: RESOLVED → VERIFIED
You need to log in
before you can comment on or make changes to this bug.
Description
•