123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635 |
- /*=========================================================================================
- File Name: dashboard-ecommerce.js
- Description: dashboard ecommerce page content with Apexchart Examples
- ----------------------------------------------------------------------------------------
- Item name: Vuexy - Vuejs, HTML & Laravel Admin Dashboard Template
- Author: PIXINVENT
- Author URL: http://www.themeforest.net/user/pixinvent
- ==========================================================================================*/
- $(window).on("load", function () {
- var $primary = '#7367F0';
- var $success = '#28C76F';
- var $danger = '#EA5455';
- var $warning = '#FF9F43';
- var $info = '#00cfe8';
- var $primary_light = '#A9A2F6';
- var $danger_light = '#f29292';
- var $success_light = '#55DD92';
- var $warning_light = '#ffc085';
- var $info_light = '#1fcadb';
- var $strok_color = '#b9c3cd';
- var $label_color = '#e7e7e7';
- var $white = '#fff';
- // Line Area Chart - 1
- // ----------------------------------
- var gainedlineChartoptions = {
- chart: {
- height: 100,
- type: 'area',
- toolbar: {
- show: false,
- },
- sparkline: {
- enabled: true
- },
- grid: {
- show: false,
- padding: {
- left: 0,
- right: 0
- }
- },
- },
- colors: [$primary],
- dataLabels: {
- enabled: false
- },
- stroke: {
- curve: 'smooth',
- width: 2.5
- },
- fill: {
- type: 'gradient',
- gradient: {
- shadeIntensity: 0.9,
- opacityFrom: 0.7,
- opacityTo: 0.5,
- stops: [0, 80, 100]
- }
- },
- series: [{
- name: 'Subscribers',
- data: [28, 40, 36, 52, 38, 60, 55]
- }],
- xaxis: {
- labels: {
- show: false,
- },
- axisBorder: {
- show: false,
- }
- },
- yaxis: [{
- y: 0,
- offsetX: 0,
- offsetY: 0,
- padding: { left: 0, right: 0 },
- }],
- tooltip: {
- x: { show: false }
- },
- }
- var gainedlineChart = new ApexCharts(
- document.querySelector("#line-area-chart-1"),
- gainedlineChartoptions
- );
- gainedlineChart.render();
- // Line Area Chart - 2
- // ----------------------------------
- var revenuelineChartoptions = {
- chart: {
- height: 100,
- type: 'area',
- toolbar: {
- show: false,
- },
- sparkline: {
- enabled: true
- },
- grid: {
- show: false,
- padding: {
- left: 0,
- right: 0
- }
- },
- },
- colors: [$success],
- dataLabels: {
- enabled: false
- },
- stroke: {
- curve: 'smooth',
- width: 2.5
- },
- fill: {
- type: 'gradient',
- gradient: {
- shadeIntensity: 0.9,
- opacityFrom: 0.7,
- opacityTo: 0.5,
- stops: [0, 80, 100]
- }
- },
- series: [{
- name: 'Revenue',
- data: [350, 275, 400, 300, 350, 300, 450]
- }],
- xaxis: {
- labels: {
- show: false,
- },
- axisBorder: {
- show: false,
- }
- },
- yaxis: [{
- y: 0,
- offsetX: 0,
- offsetY: 0,
- padding: { left: 0, right: 0 },
- }],
- tooltip: {
- x: { show: false }
- },
- }
- var revenuelineChart = new ApexCharts(
- document.querySelector("#line-area-chart-2"),
- revenuelineChartoptions
- );
- revenuelineChart.render();
- // Line Area Chart - 3
- // ----------------------------------
- var saleslineChartoptions = {
- chart: {
- height: 100,
- type: 'area',
- toolbar: {
- show: false,
- },
- sparkline: {
- enabled: true
- },
- grid: {
- show: false,
- padding: {
- left: 0,
- right: 0
- }
- },
- },
- colors: [$danger],
- dataLabels: {
- enabled: false
- },
- stroke: {
- curve: 'smooth',
- width: 2.5
- },
- fill: {
- type: 'gradient',
- gradient: {
- shadeIntensity: 0.9,
- opacityFrom: 0.7,
- opacityTo: 0.5,
- stops: [0, 80, 100]
- }
- },
- series: [{
- name: 'Sales',
- data: [10, 15, 7, 12, 3, 16]
- }],
- xaxis: {
- labels: {
- show: false,
- },
- axisBorder: {
- show: false,
- }
- },
- yaxis: [{
- y: 0,
- offsetX: 0,
- offsetY: 0,
- padding: { left: 0, right: 0 },
- }],
- tooltip: {
- x: { show: false }
- },
- }
- var saleslineChart = new ApexCharts(
- document.querySelector("#line-area-chart-3"),
- saleslineChartoptions
- );
- saleslineChart.render();
- // Line Area Chart - 4
- // ----------------------------------
- var orderlineChartoptions = {
- chart: {
- height: 100,
- type: 'area',
- toolbar: {
- show: false,
- },
- sparkline: {
- enabled: true
- },
- grid: {
- show: false,
- padding: {
- left: 0,
- right: 0
- }
- },
- },
- colors: [$warning],
- dataLabels: {
- enabled: false
- },
- stroke: {
- curve: 'smooth',
- width: 2.5
- },
- fill: {
- type: 'gradient',
- gradient: {
- shadeIntensity: 0.9,
- opacityFrom: 0.7,
- opacityTo: 0.5,
- stops: [0, 80, 100]
- }
- },
- series: [{
- name: 'Orders',
- data: [10, 15, 8, 15, 7, 12, 8]
- }],
- xaxis: {
- labels: {
- show: false,
- },
- axisBorder: {
- show: false,
- }
- },
- yaxis: [{
- y: 0,
- offsetX: 0,
- offsetY: 0,
- padding: { left: 0, right: 0 },
- }],
- tooltip: {
- x: { show: false }
- },
- }
- var orderlineChart = new ApexCharts(
- document.querySelector("#line-area-chart-4"),
- orderlineChartoptions
- );
- orderlineChart.render();
- // revenue-chart Chart
- // -----------------------------
- var revenueChartoptions = {
- chart: {
- height: 270,
- toolbar: { show: false },
- type: 'line',
- },
- stroke: {
- curve: 'smooth',
- dashArray: [0, 8],
- width: [4, 2],
- },
- grid: {
- borderColor: $label_color,
- },
- legend: {
- show: false,
- },
- colors: [$danger_light, $strok_color],
- fill: {
- type: 'gradient',
- gradient: {
- shade: 'dark',
- inverseColors: false,
- gradientToColors: [$primary, $strok_color],
- shadeIntensity: 1,
- type: 'horizontal',
- opacityFrom: 1,
- opacityTo: 1,
- stops: [0, 100, 100, 100]
- },
- },
- markers: {
- size: 0,
- hover: {
- size: 5
- }
- },
- xaxis: {
- labels: {
- style: {
- colors: $strok_color,
- }
- },
- axisTicks: {
- show: false,
- },
- categories: ['01', '05', '09', '13', '17', '21', '26', '31'],
- axisBorder: {
- show: false,
- },
- tickPlacement: 'on',
- },
- yaxis: {
- tickAmount: 5,
- labels: {
- style: {
- color: $strok_color,
- },
- formatter: function (val) {
- return val > 999 ? (val / 1000).toFixed(1) + 'k' : val;
- }
- }
- },
- tooltip: {
- x: { show: false }
- },
- series: [{
- name: "This Month",
- data: [45000, 47000, 44800, 47500, 45500, 48000, 46500, 48600]
- },
- {
- name: "Last Month",
- data: [46000, 48000, 45500, 46600, 44500, 46500, 45000, 47000]
- }
- ],
- }
- var revenueChart = new ApexCharts(
- document.querySelector("#revenue-chart"),
- revenueChartoptions
- );
- revenueChart.render();
- // Goal Overview Chart
- // -----------------------------
- var goalChartoptions = {
- chart: {
- height: 250,
- type: 'radialBar',
- sparkline: {
- enabled: true,
- },
- dropShadow: {
- enabled: true,
- blur: 3,
- left: 1,
- top: 1,
- opacity: 0.1
- },
- },
- colors: [$success],
- plotOptions: {
- radialBar: {
- size: 110,
- startAngle: -150,
- endAngle: 150,
- hollow: {
- size: '77%',
- },
- track: {
- background: $strok_color,
- strokeWidth: '50%',
- },
- dataLabels: {
- name: {
- show: false
- },
- value: {
- offsetY: 18,
- color: '#99a2ac',
- fontSize: '4rem'
- }
- }
- }
- },
- fill: {
- type: 'gradient',
- gradient: {
- shade: 'dark',
- type: 'horizontal',
- shadeIntensity: 0.5,
- gradientToColors: ['#00b5b5'],
- inverseColors: true,
- opacityFrom: 1,
- opacityTo: 1,
- stops: [0, 100]
- },
- },
- series: [83],
- stroke: {
- lineCap: 'round'
- },
- }
- var goalChart = new ApexCharts(
- document.querySelector("#goal-overview-chart"),
- goalChartoptions
- );
- goalChart.render();
- // Client Retention Chart
- // ----------------------------------
- var clientChartoptions = {
- chart: {
- stacked: true,
- type: 'bar',
- toolbar: { show: false },
- height: 300,
- },
- plotOptions: {
- bar: {
- columnWidth: '10%'
- }
- },
- colors: [$primary, $danger],
- series: [{
- name: 'New Clients',
- data: [175, 125, 225, 175, 160, 189, 206, 134, 159, 216, 148, 123]
- }, {
- name: 'Retained Clients',
- data: [-144, -155, -141, -167, -122, -143, -158, -107, -126, -131, -140, -137]
- }],
- grid: {
- borderColor: $label_color,
- padding: {
- left: 0,
- right: 0
- }
- },
- legend: {
- show: true,
- position: 'top',
- horizontalAlign: 'left',
- offsetX: 0,
- fontSize: '14px',
- markers: {
- radius: 50,
- width: 10,
- height: 10,
- }
- },
- dataLabels: {
- enabled: false
- },
- xaxis: {
- labels: {
- style: {
- colors: $strok_color,
- }
- },
- axisTicks: {
- show: false,
- },
- categories: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],
- axisBorder: {
- show: false,
- },
- },
- yaxis: {
- tickAmount: 5,
- labels: {
- style: {
- color: $strok_color,
- }
- }
- },
- tooltip: {
- x: { show: false }
- },
- }
- var clientChart = new ApexCharts(
- document.querySelector("#client-retention-chart"),
- clientChartoptions
- );
- clientChart.render();
- // Session Chart
- // ----------------------------------
- var sessionChartoptions = {
- chart: {
- type: 'donut',
- height: 325,
- toolbar: {
- show: false
- }
- },
- dataLabels: {
- enabled: false
- },
- series: [58.6, 34.9, 6.5],
- legend: { show: false },
- comparedResult: [2, -3, 8],
- labels: ['Desktop', 'Mobile', 'Tablet'],
- stroke: { width: 0 },
- colors: [$primary, $warning, $danger],
- fill: {
- type: 'gradient',
- gradient: {
- gradientToColors: [$primary_light, $warning_light, $danger_light]
- }
- }
- }
- var sessionChart = new ApexCharts(
- document.querySelector("#session-chart"),
- sessionChartoptions
- );
- sessionChart.render();
- // Customer Chart
- // -----------------------------
- var customerChartoptions = {
- chart: {
- type: 'pie',
- height: 330,
- dropShadow: {
- enabled: false,
- blur: 5,
- left: 1,
- top: 1,
- opacity: 0.2
- },
- toolbar: {
- show: false
- }
- },
- labels: ['New', 'Returning', 'Referrals'],
- series: [690, 258, 149],
- dataLabels: {
- enabled: false
- },
- legend: { show: false },
- stroke: {
- width: 5
- },
- colors: [$primary, $warning, $danger],
- fill: {
- type: 'gradient',
- gradient: {
- gradientToColors: [$primary_light, $warning_light, $danger_light]
- }
- }
- }
- var customerChart = new ApexCharts(
- document.querySelector("#customer-chart"),
- customerChartoptions
- );
- customerChart.render();
- });
- // Chat Application
- (function ($) {
- "use strict";
- // Chat area
- if ($('.chat-application .user-chats').length > 0) {
- var chat_user = new PerfectScrollbar(".user-chats", { wheelPropagation: false });
- }
- })(jQuery);
|