hjaycee
V2EX  ›  Vue.js

前后端分离后台管理系统源码分享

  •  
  •   hjaycee · Nov 9, 2017 · 5395 views
    This topic created in 3190 days ago, the information mentioned may be changed or developed.

    介绍

    前后端分离后台小网站

    • 前端使用 vue+vue-router+element-ui+npm+webpack
    • 后台接口使用 php

    预览

    演示地址

    http://www.signxx.com

    安装

    git clone https://github.com/HJaycee/SimpleAdmin.git
    cd SimpleAdmin
    npm install
    

    启动

    npm run dev
    

    部署到服务器

    cd SimpleAdmin
    npm run build
    // 编译完成后,将 dist 目录下的文件上传到服务器目录下
    
    // 因为使用 vue-router 的 hitory 模式,服务器需要做相关配置自动重定向到 index.html
    // apache 下创建隐藏文件.htaccess,填以下内容
    <IfModule mod_rewrite.c>
      RewriteEngine On
      RewriteBase /
      RewriteRule ^index\.html$ - [L]
      RewriteCond %{REQUEST_FILENAME} !-f
      RewriteCond %{REQUEST_FILENAME} !-d
      RewriteRule . /index.html [L]
    </IfModule>
    

    前端部分

    已实现功能

    • 登录 /注册
    • 留言
    • 留言列表
    • 身份过期处理

    相关配置

    /config/index.js // 反向代理
    /src/router/index.js // 路由
    /url/api.js // 请求接口
    

    后台部分

    • 环境要求 php5
    • 使用 ThinkPHP3.2.3
    • 提供前端需要的相关接口:登录接口返回 token,其它接口效验 token 是否过期

    数据库

    user // 用户表
    feedback // 留言表
    
    2 replies    2017-11-30 18:51:06 +08:00
    alber1986
        1
    alber1986  
       Nov 29, 2017   ❤️ 1
    这个还不错
    hjaycee
        2
    hjaycee  
    OP
       Nov 30, 2017
    @alber1986 谢谢哈
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   3097 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 33ms · UTC 14:12 · PVG 22:12 · LAX 07:12 · JFK 10:12
    ♥ Do have faith in what you're doing.