All Projects → Cambalab → vue-admin

Cambalab / vue-admin

Licence: GPL-3.0 license
An open source frontend Framework for building admin applications running in the browser on top of REST, using ES6 and Vue.js

Programming Languages

javascript
184084 projects - #8 most used programming language
Vue
7211 projects

Projects that are alternatives of or similar to vue-admin

React Admin
A frontend Framework for building B2B applications running in the browser on top of REST/GraphQL APIs, using ES6, React and Material Design
Stars: ✭ 18,525 (+14720%)
Mutual labels:  admin, admin-dashboard, frontend-framework
Admin On Rest
A frontend framework for building admin SPAs on top of REST services, using React and Material Design.
Stars: ✭ 392 (+213.6%)
Mutual labels:  admin, admin-dashboard, frontend-framework
React Antd Admin
用React和Ant Design搭建的一个通用管理后台
Stars: ✭ 1,313 (+950.4%)
Mutual labels:  admin, admin-dashboard, frontend-framework
Inventory-Barang
Source Code Website Penyimpanan Barang Di Bangun Menggunakan Bahasa Pemrogramman Php Procedural Dan Database Mysql Sebagai Penyimpanan Database. (Ada Perbaikan)
Stars: ✭ 12 (-90.4%)
Mutual labels:  admin, admin-dashboard
Jet Django
Jet Bridge (Django) for Jet Admin – Admin panel framework for your application
Stars: ✭ 168 (+34.4%)
Mutual labels:  admin, admin-dashboard
Vue Material Admin
A vue material design admin template
Stars: ✭ 2,170 (+1636%)
Mutual labels:  admin, vuetifyjs
Blur Admin
AngularJS Bootstrap Admin Panel Framework
Stars: ✭ 11,274 (+8919.2%)
Mutual labels:  admin, admin-dashboard
Appy
🚀 A full stack boilerplate web app
Stars: ✭ 225 (+80%)
Mutual labels:  admin, admin-dashboard
Notus React
Notus React: Free Tailwind CSS UI Kit and Admin
Stars: ✭ 173 (+38.4%)
Mutual labels:  admin, admin-dashboard
Forest Rails
🌱 Rails Liana for Forest Admin
Stars: ✭ 247 (+97.6%)
Mutual labels:  admin, admin-dashboard
uiw-admin
UIW-Admin Panel Framework, Powered by React and @uiwjs.
Stars: ✭ 21 (-83.2%)
Mutual labels:  admin, admin-dashboard
Majesticadmin Free Bootstrap Admin Template
Simple Bootstrap 4 Dashboard template.
Stars: ✭ 160 (+28%)
Mutual labels:  admin, admin-dashboard
Architectui Html Theme Free
ArchitectUI Dashboard Free is lightweight and comes packed with the minimal set of components to get you started. If you have a simple application, it’s the perfect solution for you. It’s built on top of Bootstrap 4 and features a scalable architecture just like it’s wiser, older sibling – ArchitectUI HTML Pro theme.
Stars: ✭ 155 (+24%)
Mutual labels:  admin, admin-dashboard
Ember Cli Admin
Ember-cli-admin is a powerful admin dashboard for ember-cli projects
Stars: ✭ 178 (+42.4%)
Mutual labels:  admin, admin-dashboard
Notus Nextjs
Notus NextJS: Free Tailwind CSS UI Kit and Admin
Stars: ✭ 152 (+21.6%)
Mutual labels:  admin, admin-dashboard
Laradmin
Laradmin后台管理系统
Stars: ✭ 197 (+57.6%)
Mutual labels:  admin, admin-dashboard
vue-admin-better
🚀🚀🚀vue admin,vue3 admin,vue3.0 admin,vue后台管理,vue-admin,vue3.0-admin,admin,vue-admin,vue-element-admin,ant-design,vue-admin-beautiful-pro,vab admin pro,vab admin plus,vue admin plus,vue admin pro
Stars: ✭ 12,962 (+10269.6%)
Mutual labels:  admin, admin-dashboard
uni-admin
基于 uni-app,uniCloud 的 admin 管理项目模板
Stars: ✭ 135 (+8%)
Mutual labels:  admin, admin-dashboard
Azia-Admin-React
Free React.js Admin template
Stars: ✭ 44 (-64.8%)
Mutual labels:  admin, admin-dashboard
Forest Express Mongoose
🌱 Express/Mongoose Liana for Forest Admin
Stars: ✭ 145 (+16%)
Mutual labels:  admin, admin-dashboard

Vue-Admin logo

Vue-Admin is designed to let developers build frontend administration applications that run in the browser in a very easy way using Vue, Javascript and REST services.

Build Status Build Status Version License License

Introduction

We've been working a lot with other libraries that generate administration dashboards, routes, resources in other javascript frameworks, but did not find any Vue library capable of performing this kind of solution, except of many really impressive Vue libraries that provide UI components for admin dashboards. We are pretty convinced Vue's learning curve is gentle, so we thought we could try and build our own tool.

demo of the app running

About the library

Given a simple configuration to Vue-Admin components, this library connects your backend and interprets your services as frontend resources from which CRUD views are automatically created and associated with a route.
Vue-Admin also lets you create custom views to provide other kind of information to the site (measures, landings, etc).

Vue-Admin provides:

  • create, read, update and delete views for each declared resource.
  • customizable homepage.
  • navigation between views.
  • an authentication view
  • vuetify2 support

Dependencies and third party libraries

We assume your project ships the following dependencies:

  • vue-router: used to dynamically create routes and bind components to them. We also take advantage of some of the route hooks.
  • vuex: lets us globally share information between the core application and component customizations of a library user.
  • vuetify: we basically don't want to implement UI components from scratch, plus their widgets are awesome. The drawer, buttons, cards and CRUD views are implemented with Vuetify, but you could use any other UI framework if you want to build your own CRUD views. Take the magazines view as example.

Core Libaries vue-admin-js depends on:

  • vuex-crud: this lightweight tool creates the resources crud store state, mutations and getters for us.

Installation

# using npm
npm i --save vue-admin-js

Configuration

Auth Provider

You will have to configure an adapter to communicate with your REST api.

We currently provide a simple example using an axios client in the demo app. Though we intend to keep developing other kind of adapters for different node backend frameworks, they will live in separate packages.

Anyways, we hope the axios example encourages you to write your own adapter until we release the adapters guide. The @va-auth module uses the vuex store and expects a user to make use of the action types it provides.

Usage

App.vue

<template>
  <Admin :authProvider="authProvider">
    <Resource
      name="articles"
      resourceIdName="id"
      userPermissionsField="permissions"
      apiUrl="http://localhost:8888/api/"
    >
      <View slot="list"   :component="ListArticles"   :permissions="['admin']" />
      <View slot="show"   :component="ShowArticles"   :permissions="['admin']" />
      <View slot="create" :component="CreateArticles" :permissions="['admin']" />
      <View slot="edit"   :component="EditArticles" :isPublic="true" />
    </Resource>
  </Admin>
</template>

<script>
  import { Admin, Resource } from 'vue-admin-js'
  // Your components
  import ListArticles from './components/articles/ListArticles'
  import ShowArticles from './components/articles/ShowArticles'
  import CreateArticles from './components/articles/CreateArticles'
  import EditArticles from './components/articles/EditArticles'
  import createAxiosAdapter from './va-auth-adapter/axios.adapter'
  import axios from 'axios'

  const authUrl = 'http://localhost:8888/api/auth'
  const client = axios

  const authProvider = createAxiosAdapter(client, { authUrl })

  export default {
    name: 'App',
    components: {
      Admin,
      Resource
    },
    data() {
      return {
        authProvider,
        // Your Components
        ListArticles,
        ShowArticles,
        CreateArticles,
        EditArticles,
      }
    }
  }
</script>

ListArticles.vue

<template>
  <List>
    <p source="id" :sortable="true" headerText="ID" alignHeader="left" alignContent="left" />
    <h3 source="title" :sortable="true" headerText="Title" alignHeader="center" alignContent="left" />
    <p source="content" :sortable="true" headerText="Content" alignHeader="center" alignContent="right" />
  </List>
</template>

<script>
import { List } from 'vue-admin-js'

export default {
  name: 'ListArticles',
  components: {
    List
  }
}
</script>

Using your own custom authentication component

By default Vue-Admin provides a default authentication view, but you may desire to use your own custom view to authenticate. In that case, you just need to pass it as a property in the Admin component like the following.

Example of custom authentication component usage

  ...
  <Admin :authProvider="authProvider" :authLayout="AuthCustomView">
  ...

In order to use the available authentication mechanism you have to declare a prop with a va object field which will contain the bounded login function.

Example of provided login mechanism usage in custom auth component

  ...
  props: {
    va: {
      type: Object,
      required: true
    }
  },
  ...
  methods: {
    login() {
      this.va.login(this.username, this.password)
    }
  }
  ...

Examples

For a complete example take a look at the demo files

Some of the custom components examples can be found in the magazines views

Starting a new project

Using the official Vue cli

# install the official vue cli
npm install -g @vue/cli-init
# initialise the project
vue init webpack my-project
cd my-project
# install required dependencies
npm install --save vue-admin-js vue-router vuex vuex-crud vuetify
# run the project
npm run dev

...and start customizing your App.vue

Getting it running

To get vue-admin-js up and running we'll need two terminals: one for the frontend and another one simulating a backend.

Clone a vue-admin-js repository and open two terminals in the repository root.

git clone https://github.com/Cambalab/vue-admin.git
cd vue-admin

In the first terminal get the node development server running

# install the test server dependencies
cd utils/server-test && npm install
# run the server (we prefer to use the same port as Cypress server)
PORT=8888 node server

In the second terminal get the frontend application running

# make sure you're in the root of the project
npm install
npm run serve

Demo app credentials

User with admin permissions

username: [email protected]
password: 123456

User with guest permissions

username: [email protected]
password: 123456

Scripts: tests, lint, build

We use the vue-cli-service to run tests, lint checking and the library build.

All of the above are used by the travis continuous integration.

unit tests

# in the root of the project run the unit tests script
npm run test:unit

end to end tests

# go to the root of the project to run the e2e tests script
# there's no need to run the test server, we use the Cypress server
npm run test:e2e

lint service

# zero tolerance for errors and warnings
npm run lint

build service

# the build is targeted as a library
npm run build

Contribution

Please make sure to read the Contributing Guide before making a pull request.

License

GNU General Public License version 3

👩‍💻 with 💚 💜 ❤️ by cambá.coop 🌎 Buenos Aires, Argentina

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].