﻿/// <reference name="MicrosoftAjax.debug.js" />
Type.registerNamespace('Web');
if (!Web) Web = {}

Web.DataViewResources = {}

Web.DataViewResources.Common = {
    WaitHtml: '<div class="Wait"></div>'
}

Web.DataViewResources.Pager = {
    ItemsPerPage: 'Items per page: ',
    PageSizes: [10, 15, 20, 25],
    ShowingItems: 'Showing <b>{0}</b>-<b>{1}</b> of <b>{2}</b> items',
    Refresh: 'Refresh',
    Next: 'Next »',
    Previous: '« Previous',
    Page: 'Page',
    PageButtonCount: 10
}

Web.DataViewResources.ActionBar = {
    View: 'View'
}

Web.DataViewResources.ModalPopup = {
    Close: 'Close',
    MaxWidth: 800,
    MaxHeight: 600,
    OkButton: 'OK',
    CancelButton: 'Cancel'
}

Web.DataViewResources.HeaderFilter = {
    GenericSortAscending: 'Smallest on Top',
    GenericSortDescending: 'Largest on Top',
    StringSortAscending: 'Ascending',
    StringSortDescending: 'Descending',
    DateSortAscending: 'Earliest on Top',
    DateSortDescending: 'Latest on Top',
    EmptyValue: '(Empty)',
    BlankValue: '(Blank)',
    Loading: 'Loading...',
    ClearFilter: 'Clear Filter from {0}',
    SortBy: 'Sort by {0}',
    MaxSampleTextLen: 80,
    CustomFilterOption: 'Custom Filter...',
    CustomFilterPrompt: 'Show all rows in <span class="Highlight">{0}</span> where column <span class="Highlight">{1}</span> matches the following value(s). You may separate multiple values with comma and use &gt;, &lt;, &gt;=, or &lt;= operators placed before the value.',
    CustomFilterLimit: 5
}

Web.DataViewResources.InfoBar = {
    FilterApplied: 'A filter has been applied.',
    ValueIs: ' <span class="Highlight">{0}</span> ',
    Or: ' or ',
    And: ' and ',
    EqualTo: 'is equal to ',
    LessThan: 'is less than ',
    LessThanOrEqualTo: 'is less than or equal to ',
    GreaterThan: 'is greater than ',
    GreaterThanOrEqual: 'is greater than or equal to ',
    Like: 'is like ',
    StartsWith: 'starts with ',
    Empty: 'empty'
}

Web.DataViewResources.Lookup = {
    SelectToolTip: 'Select {0}',
    ClearToolTip: 'Clear {0}',
    NewToolTip: 'New {0}',
    SelectLink: '(select)',
    ShowActionBar: true,
    DetailsToolTip: 'View details for {0}',
    ShowDetailsInPopup: true,
    GenericNewToolTip: 'Create New'
}

Web.DataViewResources.Validator = {
    RequiredField: 'This field is required.',
    EnforceRequiredFieldsWithDefaultValue: false,
    NumberIsExpected: 'A number is expected.',
    BooleanIsExpected: 'A logical value is expected.',
    DateIsExpected: 'A date is expected.'
}

Web.DataViewResources.Data = {
    NullValue: '<span class="NA">n/a</span>',
    NullValueInForms: 'N/A',
    BooleanDefaultStyle: 'DropDownList',
    BooleanOptionalDefaultItems: [[null, 'N/A'], [false, 'No'], [true, 'Yes']],
    BooleanDefaultItems: [[false, 'No'], [true, 'Yes']],
    MaxReadOnlyStringLen: 600,
    NoRecords: 'No records found.',
    BlobHandler: '~/Blob.ashx',
    BlobDownloadLink: 'download',
    BlobDownloadLinkReadOnly: '<span style="color:gray;">download</span>',
    BlobDownloadHint: 'Click here to download the original file.'
}

Web.DataViewResources.Form = {
    ShowActionBar: true,
    ShowCalendarButton: true,
    RequiredFieldMarker: '<span class="Required">*</span>',
    RequiredFiledMarkerFootnote: '* - indicates a required field',
    SingleButtonRowFieldLimit: 7,
    GeneralTabText: 'General'
}

Web.DataViewResources.Grid = {
    InPlaceEditContextMenuEnabled: true,
    QuickFindText: 'Quick Find',
    QuickFindToolTip: 'Type to search the records and press Enter'
}

Web.DataViewResources.Actions = {
    DefaultGroups: [
        {
            HeaderText: '',
            Scope: 'Grid',
            Actions: [
            {
                CommandName: 'Select',
                CommandArgument: 'form',
                Confirmation: '',
                CssClass: '',
                Description: '',
                HeaderText: '',
                WhenLastCommandName: ''
            },
            {
                CommandName: 'Edit',
                CommandArgument: '',
                Confirmation: '',
                CssClass: '',
                Description: '',
                HeaderText: '',
                WhenLastCommandName: ''
            },
            {
                CommandName: 'Delete',
                CommandArgument: '',
                Confirmation: 'Delete?',
                CssClass: '',
                Description: '',
                HeaderText: '',
                WhenLastCommandName: ''
            },
            {
                CommandName: 'Update',
                CommandArgument: '',
                Confirmation: '',
                CssClass: '',
                Description: '',
                HeaderText: 'Save',
                WhenLastCommandName: 'Edit'
            },
            {
                CommandName: 'Cancel',
                CommandArgument: '',
                Confirmation: '',
                CssClass: '',
                Description: '',
                HeaderText: '',
                WhenLastCommandName: 'Edit'
            }
            ]
        },
        {
            HeaderText: '',
            Scope: 'Form',
            Actions:
            [
            {
                CommandName: 'Edit',
                CommandArgument: '',
                Confirmation: '',
                CssClass: '',
                Description: '',
                HeaderText: '',
                WhenLastCommandName: 'Select'
            },
            {
                CommandName: 'Delete',
                CommandArgument: '',
                Confirmation: 'Delete?',
                CssClass: '',
                Description: '',
                HeaderText: '',
                WhenLastCommandName: 'Select'
            },
            {
                CommandName: 'Cancel',
                CommandArgument: '',
                Confirmation: '',
                CssClass: '',
                Description: '',
                HeaderText: 'Close',
                WhenLastCommandName: 'Select'
            },
            {
                CommandName: 'Update',
                CommandArgument: '',
                Confirmation: '',
                CssClass: '',
                Description: '',
                HeaderText: 'OK',
                WhenLastCommandName: 'Edit'
            },
            {
                CommandName: 'Delete',
                CommandArgument: '',
                Confirmation: 'Delete?',
                CssClass: '',
                Description: '',
                HeaderText: '',
                WhenLastCommandName: 'Edit'
            },
            {
                CommandName: 'Cancel',
                CommandArgument: '',
                Confirmation: '',
                CssClass: '',
                Description: '',
                HeaderText: '',
                WhenLastCommandName: 'Edit'
            },
            {
                CommandName: 'Insert',
                CommandArgument: '',
                Confirmation: '',
                CssClass: '',
                Description: '',
                HeaderText: 'OK',
                WhenLastCommandName: 'New'
            },
            {
                CommandName: 'Cancel',
                CommandArgument: '',
                Confirmation: '',
                CssClass: '',
                Description: '',
                HeaderText: '',
                WhenLastCommandName: 'New'
            }
            ]
        }
        ]
}

if (typeof (Sys) !== 'undefined') Sys.Application.notifyScriptLoaded();
