Sunday, December 6, 2015


Wedding PLANNER


This is an android application developed using Android Studio.This is a simple app to help user plan the perfect wedding. Manage user's guest list, to-do list, budget and vendors all in one place.

I have done the budget and expenses part for this app,where the user can maintain their budget and expenses for each and every category.Notification will popup,when the user exceeds his expenses than the budget.

I have done the pie chart for the expenses too,via pie-chart user can easily analyse their expenses by category.

Pie-chart  in android





This pie chart will display the amount of expense,that user spend for each category.
Its'easy to draw pie chart using achartengine.


// Pie Chart Section Names
        ArrayList<category> bud = new DBhelper(this).getCategories();
        String[] code = new String[bud.size()];
        System.out.println(code);
        for (int i = 0; i < bud.size(); i++) {
            code[i] = bud.get(i).getName();
        }

 // Pie Chart Section Value
        double[] distribution = new double[code.length];
        for (int i = 0; i < distribution.length; i++) {
          System.out.println(i);
          ArrayList<Expence> expences = new DBhelper(this).getCategoryExpences(code[i]);
          if (expences != null) {
            double total = 0.0;
             for (Expence ex : expences) {
             total = total + Double.parseDouble(ex.getAmount());
             }
            distribution[i] = total;
          } else {
              distribution[i] = 0.0;
        }
       }


// Colour of each Pie Chart Sections
        int[] colors = getResources().getIntArray(R.array.rainbow);

        // Instantiating CategorySeries to plot Pie Chart
        CategorySeries distributionSeries = new CategorySeries("Expenses Graph");
        for (int i = 0; i < distribution.length; i++) {
            // Adding a slice with its values and name to the Pie Chart
            distributionSeries.add(code[i], distribution[i]);
        }

// Instantiating a renderer for the Pie Chart
        DefaultRenderer defaultRenderer = new DefaultRenderer();
        for (int i = 0; i < distribution.length; i++) {
            SimpleSeriesRenderer seriesRenderer = new SimpleSeriesRenderer();
            seriesRenderer.setColor(colors[i]);
            seriesRenderer.setDisplayChartValues(true);
            // Adding a renderer for a slice
            defaultRenderer.addSeriesRenderer(seriesRenderer);
        }

        defaultRenderer.setChartTitle("Expenses Graph");
        defaultRenderer.setChartTitleTextSize(50);
        defaultRenderer.setLabelsTextSize(40);
        defaultRenderer.setLegendTextSize(50);
        defaultRenderer.setShowLegend(true);
        defaultRenderer.setDisplayValues(true);
        defaultRenderer.setApplyBackgroundColor(true);
        defaultRenderer.setBackgroundColor(Color.WHITE);
        defaultRenderer.setLabelsColor(Color.BLACK);
        defaultRenderer.setZoomButtonsVisible(true);

       LinearLayout chartContainer = (LinearLayout) findViewById(R.id.chart);
// drawing pie chart
        mChart = ChartFactory.getPieChartView(getBaseContext(),
                distributionSeries, defaultRenderer);
// adding the view to the linearlayout
        chartContainer.addView(mChart);


Thursday, August 13, 2015



Tangalle Urban Council





  • In this post,I'm going to share about the website that we developed for the SEP project.This is the official website for Tangalle Urban Council.
  • We devoloped this website using Codeigniter framework.
  • For the homepage design,we used bootstrap framework.Sliders are made by the carousel sliders in the bootstrap page.

  Carousel Sliders



  <div id="carousel-example-generic" class="carousel slide" data-ride="carousel">
  <!-- Indicators -->
  <ol class="carousel-indicators">
  <li data-target="#carousel-example-generic" data-slide-to="0" class="active">
  </li>
  <li data-target="#carousel-example-generic" data-slide-to="1"></li>
  <li data-target="#carousel-example-generic" data-slide-to="2"></li>
  </ol>

  <!-- Wrapper for slides -->
  <div class="carousel-inner" role="listbox">
  <div class="item active">
  <img src="..." alt="...">
  <div class="carousel-caption">
        ...
  </div>
  </div>
  <div class="item">
  <img src="..." alt="...">
  <div class="carousel-caption">
        ...
  </div>
  </div>
    ...
  </div>

  <!-- Controls -->
  <a class="left carousel-control" href="#carousel-example-generic" role="button" 
  data-        slide="prev">
  <span class="glyphicon glyphicon-chevron-left" aria-hidden="true"></span>
  <span class="sr-only">Previous</span>
  </a>
  <a class="right carousel-control" href="#carousel-example-generic"
  role="button"  data-slide="next">
  <span class="glyphicon glyphicon-chevron-right" aria-hidden="true"></span>
  <span class="sr-only">Next</span>
  </a>
  </div>




Tuesday, August 11, 2015

My SEP Project


I would like to share my knowledge that I gain during my SEP project.Me and my group members developed a website for Tangalle Urban council, which was developed using Codeigniter and bootstrap frameworks.


Frameworks


Frameworks are of key importance for developing large-scale software systems.They promise higher productivity and shorter-time-to-market through design and code reuse.


Software frameworks include support programs,compilers,code libraries,tool sets and application programming interfaces(API) that bring together all the different components to enable development of a project or solution.




 1.CodeIgniter Framework



CodeIgniter is one of the most popular development framework those are built on PHP platform. 

Why we need CodeIgniter?

  • It follows MVC design pattern: Current days, Model View Controller(MVC) is the most popular design pattern in  software development.
  • Performance matters: It obtains better scores than other php based application frameworks like Cakephp, Zend etc in terms of loading speed / performance.
  • Easy integration support: It gives a very easy way to integrate third-party tools as library/plugins.
  • Easy Documentation: Their documentation are simply mind-blowing, actually best to me among all other documentation I have experienced till now.
 2.Bootstrap framework


Bootstrap is an open-source Javascript framework.It is a combination of HTML, CSS, and Javascript code designed to help build user interface components. Bootstrap was also programmed to support both HTML5 and CSS3. Also it is called Front-end-framework.


Why we need Bootstrap?

  • Speed of development: Rather than coding from scratch, Bootstrap enables you to utilize ready made blocks of code to help you get started. 
  • Responsiveness: Show a different view based on the size of their device.
  • Consistency: Results are uniform across platforms so output remains the same whether you’re using Firefox, Chrome or Internet Explorer.
  • Customizable:  Developers have the ability to pick and choose the features that are needed and the rest can be tossed. This is easily accomplished using the Bootstrap customize page.
  • Support: Bootstrap has a huge support community behind it so you can usually get help when you run into issues.