Develop yours

Develop your main plugin and sub-plugin with Abilists by creating your application in Abilists tool.


Additional Development for plugins on Abilists

● Install & configuration to devleop

  1. Install Java 8
    https://openjdk.java.net/install/
    
  2. Install Gradle 3.3
    https://services.gradle.org/distributions/gradle-3.3-all.zip
    
  3. Install Eclipse
    https://www.eclipse.org/
    


● Download Abilists source code

  1. Clone abilists_client by Git
    $ git clone https://github.com/abilists/abilists_client.git
    
    We provide the Client Controller for free so that companies can develop its own business functions.
    The following image is showing the Controller code(abilists_client) opened after downloading the source code by Git.

    www.abilists.com

  2. It describes the development for new Plugins that can be used on Abilites base.
    For more information, Please check [Plugins> New plugin development] or README.md in Git.
    https://github.com/abilists/plugin_sample
    
    Clone abilists_plugins by Git
    $ git clone https://github.com/abilists/plugin_sample.git
    
    The following source code of the sample is opened with Eclipse after cloning the sample plugin source.

    www.abilists.com



How to develop

● It describes the source configuration and each role.

  1. It create a Model object so that it can be expressed on the screen within the Controller. The screen output of all data is shown through the abilistsModel.
    To create and express new data on a new screen, extends AbilistsModel and express it.
    AbilistsModel abilistsModel = new AbilistsModel();
    
    The login user's information is retrieved from the session.
    this.handleSessionInfo(request.getSession(), sltSamplePara);
    
    After checking the input data, check if there are any errors. When there is an error, the screen is switched to the error screen.
    Map mapErrorMessage = new HashMap();
    if (bindingResult.hasErrors()) {
    	response.setStatus(400);
    	mapErrorMessage = this.handleErrorMessages(bindingResult.getAllErrors(), locale);
    	model.addAttribute("mapErrorMessage",  mapErrorMessage);
    	return "apps/errors/parameterErrors";
    }
    
    Check One Time Talk (OPT). If you have a lot of users, we recommend moving the token store to memcached.
    String key = this.makeKey(istSamplePara.getUserId(), AbstractBaseController.PREFIX_IST_KEY);
    if (!istSamplePara.getToken().equals(commonBean.getTokenExpireMap(key))) {
    	mapErrorMessage.put("errorMessage", message.getMessage("parameter.error.token.message", null, locale));
    	model.addAttribute("errorMessage", mapErrorMessage);
    	return "apps/errors/parameterErrors";
    }
    
    This section is for displaying messages on the screen when data processing is normal.
    redirectAttributes.addFlashAttribute("save", "completed");
    
  2. CRUD business logic handled by ClientServiceImpl class.
    This method collects (searches) data. (slt = select)
    @Override
    public List sltCleintList(CommonPara commonPara) throws Exception {
    	
    
    	return null;
    }
    
    This is a data input method. (ist = insert)
    @Override
    @Transactional(rollbackFor = Exception.class, propagation = Propagation.REQUIRED)
    public boolean istCleint(CommonPara commonPara) throws Exception {
    
    	return true;
    }
    
    This is a data update method. (udt = update)
    @Override
    @Transactional(rollbackFor = Exception.class, propagation = Propagation.REQUIRED)
    public boolean udtUCleint(CommonPara commonPara) throws Exception {
    
    	return true;
    }
    
    This is a data delete method. (dlt = delete)
    @Override
    @Transactional(rollbackFor = Exception.class, propagation = Propagation.REQUIRED)
    public boolean dltCleint(CommonPara commonPara) throws Exception {
    
    	return true;
    }
    

● Run in a development environment.

  1. Run abilists_client in local through Jetty.
    *When an error occurs, execute gradle clean command once and start Jetty.
    $ cd ~/git/abilists_client
    $ gradle clean
    $ gradle jettyRun