Exemple #1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="Upload" /> class.
        /// </summary>
        /// <param name="viewContext">The view context.</param>
        /// <param name="initializer">The javascript initializer.</param>
        /// <param name="urlGenerator">The URL Generator.</param>
        public Upload(ViewContext viewContext, IJavaScriptInitializer initializer, IUrlGenerator urlGenerator)
            : base(viewContext, initializer)
        {
            Enabled = true;
            Multiple = true;
            ShowFileList = true;
            Async = new UploadAsyncSettings(this);
            Messages = new UploadMessages();
            TemplateId = string.Empty;
            Files = new List<UploadFile>();

            UrlGenerator = urlGenerator;
        }
Exemple #2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="Upload" /> class.
        /// </summary>
        /// <param name="viewContext">The view context.</param>
        /// <param name="initializer">The javascript initializer.</param>
        /// <param name="urlGenerator">The URL Generator.</param>
        public Upload(ViewContext viewContext, IJavaScriptInitializer initializer, IUrlGenerator urlGenerator)
            : base(viewContext, initializer)
        {
            Enabled      = true;
            Multiple     = true;
            ShowFileList = true;
            Async        = new UploadAsyncSettings(this);
            Messages     = new UploadMessages();
            TemplateId   = string.Empty;
            Files        = new List <UploadFile>();

            UrlGenerator = urlGenerator;
        }