Package edu.asu.securebanking.model

Examples of edu.asu.securebanking.model.InternalAccount


  // External User Account Functionalities.

  @RequestMapping(value="/externalUsersAccounts")
  public synchronized String externalUsersAccounts(ModelMap model, Principal principal) {
    String name = principal.getName();
    InternalAccount currentuser = intBo.findUserByusername(name);

    model.addAttribute("currentuser", currentuser);

    if(currentuser.getDeptid() == 3){
      ExternalAccount externalAccount = new ExternalAccount();

      //command object
      model.addAttribute("externalAccount", externalAccount);
View Full Code Here


  @RequestMapping(value="/displayExternalUsersAccounts")

  public synchronized ModelAndView listOfExternalUserAccounts( Principal principal) {
    String name = principal.getName();
    InternalAccount currentuser = intBo.findUserByusername(name);

    if(currentuser.getDeptid() == 3){
      ModelAndView modelAndView = new ModelAndView("ListExternalUserAccounts");
      List<ExternalAccount> externalAccounts = externalAccountBO.getAllExternalUserAccounts();
      ExternalAccount accountbyname = new ExternalAccount();
      modelAndView.addObject("accountbyname", accountbyname);
      modelAndView.addObject("externalAccounts", externalAccounts);
View Full Code Here

  @RequestMapping(value="/viewExternalUserAccount")

  public ModelAndView viewExternalUserAccount(@ModelAttribute("accountbyname") ExternalAccount externalAccount, Principal principal) {
    String name = principal.getName();
    InternalAccount currentuser = intBo.findUserByusername(name);

    if(currentuser.getDeptid() == 3){

      ExternalAccount externalAccount1 = externalAccountBO.findAccountByName(externalAccount.getUsername());
      ModelAndView modelAndView = new ModelAndView("ViewExternalAccount");

      modelAndView.addObject("currentuser", currentuser);
View Full Code Here

  @RequestMapping(value="/updateExternalUserAccount")

  public synchronized ModelAndView showUpdateExternalUserAccount(@ModelAttribute("accountbyname") ExternalAccount externalAccount, Principal principal) {
    String name = principal.getName();
    InternalAccount currentuser = intBo.findUserByusername(name);

    if(currentuser.getDeptid() == 3){


      ExternalAccount externalAccount1 = externalAccountBO.findAccountByName(externalAccount.getUsername());
      ModelAndView modelAndView = new ModelAndView("UpdateExternalUserAccount");
View Full Code Here

  @RequestMapping(value="/updateExternalUserAccountDetails")
  public synchronized ModelAndView updateExternalUserAccount(@ModelAttribute("user") ExternalAccount externalAccount,
      BindingResult result, Principal principal) {
    String name = principal.getName();
    InternalAccount currentuser = intBo.findUserByusername(name);
    if(currentuser.getDeptid() == 3){
      boolean res;
      String errors = "";

      res = StringValidator.inputvalidation(externalAccount.getUsername(), "username");
      if(!res){
View Full Code Here

   */
  @RequestMapping(value="/internalUsers")
  public synchronized ModelAndView internalUsers(Principal principal) {

    String name = principal.getName();
    InternalAccount currentuser = intBo.findUserByusername(name);

    if(currentuser.getDeptid() == 2){
      ModelAndView modelAndView = new ModelAndView("ITUserTransaction");
      modelAndView.addObject("currentuser", currentuser);

      InternalUserTransaction transaction = new InternalUserTransaction();
      modelAndView.addObject("transaction", transaction);
View Full Code Here

  }

  @RequestMapping("/ITInternalUserTransaction")
  public synchronized ModelAndView showInternalUserTransactionForm(Principal principal) {
    String name = principal.getName();
    InternalAccount currentuser = intBo.findUserByusername(name);

    if(currentuser.getDeptid() == 2){
      ModelAndView modelAndView = new ModelAndView("ITInternalUserTransactionCreation");
      modelAndView.addObject("currentuser", currentuser);

      InternalUserTransaction transaction = new InternalUserTransaction();
      modelAndView.addObject("transaction", transaction);
View Full Code Here

  @RequestMapping(value = "/addInternalUserTransaction", method = RequestMethod.POST)
  public synchronized ModelAndView create(@ModelAttribute("transaction") InternalUserTransaction transaction, Principal principal) {

    String name = principal.getName();
    InternalAccount currentuser = intBo.findUserByusername(name);

    boolean result;
    String errors = "";
   
View Full Code Here

  @RequestMapping(value="/deletetransaction")
  public synchronized ModelAndView deletetransactionbyid(@ModelAttribute("trans") InternalUserTransaction trans, Principal principal) {

    String name = principal.getName();
    InternalAccount currentuser = intBo.findUserByusername(name);

    if(currentuser.getDeptid() == 2){

      ModelAndView modelAndView = new ModelAndView("genericsuccess");

      transactionBO.delete(trans.getTransId());
View Full Code Here

  @RequestMapping(value="/updatetransaction")
  public synchronized ModelAndView displayUpdatePage(@ModelAttribute("trans") InternalUserTransaction trans, Principal principal) {

    String name = principal.getName();
    InternalAccount currentuser = intBo.findUserByusername(name);

    if(currentuser.getDeptid() == 2){
      InternalUserTransaction internalTransaction = transactionBO.findTransactionById(trans.getTransId());
      ModelAndView modelAndView = new ModelAndView("ITupdateInternalTransaction");

      modelAndView.addObject("internalTransaction", internalTransaction);
      modelAndView.addObject("currentuser", currentuser);
View Full Code Here

TOP

Related Classes of edu.asu.securebanking.model.InternalAccount

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.