Exemplo n.º 1
0
 protected void Page_Load(object sender, EventArgs e)
 {
     _usersession = new UserSession();
     _for = new FolderRepository();
     _redirect = new Redirector();
     up = new UploadAvatarPresenter();
 }
Exemplo n.º 2
0
 public LoadFileAlbum()
 {
     _fr = new FileRepository();
     _userSession = new UserSession();
     _accountRepository = new AccountRepository();
     _webContext = new WebContext();
     _for = new FolderRepository();
 }
Exemplo n.º 3
0
 public UploadAvatarPresenter()
 {
     _userSession =new UserSession();
     _profileRepository = new ProfileRepository();
     _redirector = new Redirector();
     _alertService = new AlertService();
     _webcontext = new WebContext();
     _for = new FolderRepository();
 }
Exemplo n.º 4
0
 protected void Page_Load(object sender, EventArgs e)
 {
     //file1.Visible = false;
     _usersession = new UserSession();
     _webcontext = new WebContext();
     _for = new FolderRepository();
     re = new Redirector();
     if (_usersession.CurrentUser != null)
     {
        countA.Text=(_for.GetFoldersByAccountID1(_usersession.CurrentUser.AccountID)).Count.ToString();
       // pn.Height = 200 * (int.Parse(countA.Text));
     }
 }
Exemplo n.º 5
0
 protected void Button1_Click(object sender, EventArgs e)
 {
     AccountRepository ac = new AccountRepository();
     FolderRepository fr = new FolderRepository();
     WebContext webcontext = new WebContext();
     UserSession usersession = new UserSession();
     _usersession = new UserSession();
         Share s = new Share();
         Account a = ac.GetAccountByUsername(friend.Text);
         Folder f = fr.GetFolderByID(long.Parse(FolderID.Text));
         s.Shared1(a, _usersession.CurrentUser, f);
 }
Exemplo n.º 6
0
        protected void LinkButton1_Click(object sender, EventArgs e)
        {
            AccountRepository ac = new AccountRepository();
            FolderRepository fr = new FolderRepository();
            WebContext webcontext = new WebContext();
            UserSession usersession = new UserSession();
            _usersession = new UserSession();

            if (webcontext.AccountID > 0 && usersession.CurrentUser.AccountID != webcontext.AccountID)
            {
                pnm.Visible = false;
                Share s = new Share();
                Account a = ac.GetAccountByID(webcontext.AccountID);
                Folder f = fr.GetFolderByID(long.Parse(FolderID.Text));
                s.Shared1(_usersession.CurrentUser, a, f);
            }
            else
            {
                pnm.Visible = true;
            }
        }