@Override
    public String execute() throws Exception {
        try {
            User user = (User) myDao.getDbsession().get(User.class, email);


            if (user.getPassword().equals(password)) {
                Map session = ActionContext.getContext().getSession();


                if (!user.getUserType().equals("Admin")) {
                    session.put("User", user);

                    User user1 = (User) myDao.getDbsession().get(User.class, email);


                    //camplist = (List<Campaign>) myDao.getDbsession().createQuery("from Campaign").list();
                    Criteria crit = myDao.getDbsession().createCriteria(Campaign.class);
                    crit.add(Restrictions.like("user", user1));
                    crit.setMaxResults(20);
                    camplist = (List<Campaign>) crit.list();

                    // sitelist = (List<Publish>) myDao.getDbsession().createQuery("from Publish").list();
                    Criteria crit1 = myDao.getDbsession().createCriteria(Publish.class);
                    crit1.add(Restrictions.like("user", user));
                    crit1.setMaxResults(20);

                    sitelist = (List<Publish>) crit1.list();

                    uselist = (List<UserDetails>) myDao.getDbsession().createQuery("from UserDetails").list();
                    Criteria ucri = myDao.getDbsession().createCriteria(UserDetails.class);
                    ucri.add(Restrictions.like("user", user));
                    ucri.setMaxResults(1);
                    // uselist=(List<UserDetails>) (ucri.list().get(0));

                    addActionMessage("Hi, " + email + " Welcome to Your Dashboard");
                    return "users";
                } else {
                    Criteria ai = myDao.getDbsession().createCriteria(Adrate.class);
                    ai.setMaxResults(1);
                    ad = (Adrate) (ai.list().get(0));
                    session.put("User", user);
                    // session.put("Adrate", ad);
                    addActionMessage("Hi, admin Welcome to Your Dashboard");
                    return "admin";
                }

            } else {
                return "error";
            }

        } catch (HibernateException he) {
            he.printStackTrace();
            addActionError("Unable to Logining you...  Error occurs  ..Try After Some times");
            return "error";
        } catch (Exception se) {

            se.getMessage();
            addActionError("Unable to Logining you...  Error occurs ..Try After Some times");
            return "error";
        }


    }