Results 1 to 9 of 9

Thread: error in javascript on datefields

  1. #1
    markjustesen is offline Junior Member
    Join Date
    Apr 2009
    Posts
    4

    Default error in javascript on datefields

    I have a problem which only occurs when I use a danish language pack, the little calendar button next to all the datefields doesn't work, but only when I use the danish pack so I guess its relatet to the translated files, could anybody specify to me where and in which files I should look

  2. #2
    crmsiva's Avatar
    crmsiva is offline A Sugar Hero
    Join Date
    Jan 2009
    Location
    Chennai, India
    Posts
    1,130

    Default Re: error in javascript on datefields

    In which module this problem is occurring?
    Which version of sugar you are using?
    Did you checked in different browsers?
    Can you post the javascript error?

  3. #3
    markjustesen is offline Junior Member
    Join Date
    Apr 2009
    Posts
    4

    Default Re: error in javascript on datefields

    its in the project module in version 5.2 and yes I tested it in internet explorer and firefox

  4. #4
    crmsiva's Avatar
    crmsiva is offline A Sugar Hero
    Join Date
    Jan 2009
    Location
    Chennai, India
    Posts
    1,130

    Default Re: error in javascript on datefields

    In firefox, check Error Console for any javascript errors

  5. #5
    markjustesen is offline Junior Member
    Join Date
    Apr 2009
    Posts
    4

    Default Re: error in javascript on datefields

    I get an error which says "weekend is undefined" in line 747

    This is the contents of that line
    if(weekend.indexOf(realday.toString())!=-1){Calendar.addClass(cell,"weekend");}


    source file: http://www.xxxx.dk/xxx/include/javas...ar_grp1.js?c=1

  6. #6
    crmsiva's Avatar
    crmsiva is offline A Sugar Hero
    Join Date
    Jan 2009
    Location
    Chennai, India
    Posts
    1,130

    Default Re: error in javascript on datefields

    Check this. I hope it helps.

  7. #7
    andopes's Avatar
    andopes is offline A Sugar Hero | Help Forum Moderator
    Join Date
    Jul 2006
    Location
    São Paulo - Brazil
    Posts
    8,335

    Default Re: error in javascript on datefields

    Quote Originally Posted by markjustesen View Post
    I have a problem which only occurs when I use a danish language pack, the little calendar button next to all the datefields doesn't work, but only when I use the danish pack so I guess its relatet to the translated files, could anybody specify to me where and in which files I should look
    Which language pack are you using?

    Cheers
    André Lopes
    DevToolKit / Project of the Month - June 2009
    Lampada Global Services- Open Source Solutions
    Avenida Ipiranga, 318
    Bloco B - CJ 1602
    São Paulo, SP 01046-010
    Brazil
    Office: +55 11 3237-3110
    Mobile: +55 11 7636-5859
    e-mail: andre@lampadaglobal.com

    Lampada Global delivers offshore software development and support services to customers around the world.
    Lampada is proud to be a SugarCRM Gold Partner, revolutionizing Customer Relationship Management.

    I DO NOT answer questions through PM and Email. If you need some help post your question into SugarForum.

  8. #8
    markjustesen is offline Junior Member
    Join Date
    Apr 2009
    Posts
    4

    Thumbs up Re: error in javascript on datefields

    Quote Originally Posted by crmsiva View Post
    Check this. I hope it helps.
    It solved the problem, 2 lines where missing
    // the following is to inform that "%s" is to be the first day of week
    // %s will be replaced with the day name.
    Calendar._TT["DAY_FIRST"] = "Display %s first";

    // This may be locale-dependent. It specifies the week-end days, as an array
    // of comma-separated numbers. The numbers are from 0 to 6: 0 means Sunday, 1
    // means Monday, etc.
    Calendar._TT["WEEKEND"] = "0,6";

    apparently this is language specific and therefore left out.

    Thanx alot guys

  9. #9
    Mini0n's Avatar
    Mini0n is offline Senior Member
    Join Date
    May 2009
    Location
    Portugal
    Posts
    20

    Default Re: error in javascript on datefields

    Hi there.

    I'm having this same problem but the weird thing is that I've inserted those missing lines but still got no calendar.

    I'm using the portuguese calendar (calendar-pt.js) and I've inserted those two lines but still have the same javascript error.
    I've even repaired and rebuild sugar...

    What can I be missing?

    Thanks!



    :edit:
    Nevermind. It's working. It must have been a cache problem.
    Last edited by Mini0n; 2009-05-26 at 10:18 AM. Reason: It's working

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 1
    Last Post: 2008-07-08, 05:39 PM
  2. Javascript Error in Configure tabs?
    By bands in forum General Discussion
    Replies: 0
    Last Post: 2007-05-24, 09:18 AM
  3. Javascript error.
    By dblake in forum Help
    Replies: 7
    Last Post: 2007-01-09, 08:45 PM
  4. Javascript error in compose email - bug ? -
    By Bullparts in forum General Discussion
    Replies: 0
    Last Post: 2006-02-16, 09:58 AM
  5. Installation Javascript Error Step 6
    By warithn in forum Help
    Replies: 3
    Last Post: 2005-10-07, 04:58 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •