├── .gitignore ├── .idea ├── all-blog-sys.iml ├── modules.xml ├── shelf │ ├── _2022_5_6_18_46____.xml │ └── 在进行更新之前于_2022_5_6_18_46_取消提交了变更_[默认变更列表] │ │ └── shelved.patch ├── vcs.xml └── workspace.xml ├── README.md ├── doc ├── img │ ├── 1.1.png │ ├── 1.2.png │ ├── 1.3.png │ ├── 1.png │ ├── 2.png │ ├── 3.png │ ├── 4.png │ ├── 5.png │ ├── 6.png │ ├── 7.png │ └── 8.png └── logo.png ├── v1.0.1 ├── README.md ├── zy-blog-admin │ ├── .editorconfig │ ├── .env │ ├── .env.development │ ├── .env.production │ ├── .env.staging │ ├── .eslintignore │ ├── .eslintrc.js │ ├── .gitignore │ ├── .travis.yml │ ├── LICENSE │ ├── babel.config.js │ ├── build │ │ └── index.js │ ├── deploy.sh │ ├── jest.config.js │ ├── jsconfig.json │ ├── mock │ │ ├── article.js │ │ ├── index.js │ │ ├── mock-server.js │ │ ├── remote-search.js │ │ ├── role │ │ │ ├── index.js │ │ │ └── routes.js │ │ └── user.js │ ├── plop-templates │ │ ├── component │ │ │ ├── index.hbs │ │ │ └── prompt.js │ │ ├── utils.js │ │ └── view │ │ │ ├── index.hbs │ │ │ └── prompt.js │ ├── plopfile.js │ ├── postcss.config.js │ ├── public │ │ ├── favicon.ico │ │ └── index.html │ ├── src │ │ ├── App.vue │ │ ├── api │ │ │ ├── admin.js │ │ │ ├── article.js │ │ │ ├── blog │ │ │ │ └── blogs.js │ │ │ ├── litemallUser.js │ │ │ ├── org.js │ │ │ ├── qiniu.js │ │ │ ├── remote-search.js │ │ │ ├── role.js │ │ │ ├── storage.js │ │ │ ├── sys │ │ │ │ └── admin.js │ │ │ └── user.js │ │ ├── assets │ │ │ ├── 401_images │ │ │ │ └── 401.gif │ │ │ ├── 404_images │ │ │ │ ├── 404.png │ │ │ │ └── 404_cloud.png │ │ │ ├── car │ │ │ │ ├── trajectory_end_sm.png │ │ │ │ └── trajectory_start_sm.png │ │ │ ├── carPosition │ │ │ │ ├── car.png │ │ │ │ ├── car_bak.png │ │ │ │ ├── car_default_logo.png │ │ │ │ ├── car_license_blank.png │ │ │ │ ├── car_license_orange.png │ │ │ │ ├── doCar.png │ │ │ │ ├── green.png │ │ │ │ ├── icon_left.png │ │ │ │ ├── icon_right.png │ │ │ │ ├── loading.gif │ │ │ │ ├── monitor_close.png │ │ │ │ ├── monitor_fullscreen_nor.png │ │ │ │ ├── monitor_fullscreen_sel.png │ │ │ │ ├── monitor_tuichu_nor.png │ │ │ │ ├── monitor_tuichu_sel.png │ │ │ │ ├── noSingle.png │ │ │ │ ├── offlineCar.png │ │ │ │ ├── overview@2x.png │ │ │ │ └── positioning.png │ │ │ ├── css │ │ │ │ ├── app.scss │ │ │ │ ├── carPosition.scss │ │ │ │ └── icon │ │ │ │ │ ├── iconfont.css │ │ │ │ │ ├── iconfont.eot │ │ │ │ │ ├── iconfont.js │ │ │ │ │ ├── iconfont.svg │ │ │ │ │ ├── iconfont.ttf │ │ │ │ │ ├── iconfont.woff │ │ │ │ │ └── iconfont.woff2 │ │ │ └── custom-theme │ │ │ │ ├── fonts │ │ │ │ ├── element-icons.ttf │ │ │ │ └── element-icons.woff │ │ │ │ └── index.css │ │ ├── components │ │ │ ├── BackToTop │ │ │ │ └── index.vue │ │ │ ├── Breadcrumb │ │ │ │ └── index.vue │ │ │ ├── Charts │ │ │ │ ├── Keyboard.vue │ │ │ │ ├── LineMarker.vue │ │ │ │ ├── MixChart.vue │ │ │ │ └── mixins │ │ │ │ │ └── resize.js │ │ │ ├── DndList │ │ │ │ └── index.vue │ │ │ ├── DragSelect │ │ │ │ └── index.vue │ │ │ ├── Dropzone │ │ │ │ └── index.vue │ │ │ ├── ErrorLog │ │ │ │ └── index.vue │ │ │ ├── GithubCorner │ │ │ │ └── index.vue │ │ │ ├── Hamburger │ │ │ │ └── index.vue │ │ │ ├── HeaderSearch │ │ │ │ └── index.vue │ │ │ ├── Identify │ │ │ │ └── Identify.vue │ │ │ ├── ImageCropper │ │ │ │ ├── index.vue │ │ │ │ └── utils │ │ │ │ │ ├── data2blob.js │ │ │ │ │ ├── effectRipple.js │ │ │ │ │ ├── language.js │ │ │ │ │ └── mimes.js │ │ │ ├── JsonEditor │ │ │ │ └── index.vue │ │ │ ├── Kanban │ │ │ │ └── index.vue │ │ │ ├── MDinput │ │ │ │ └── index.vue │ │ │ ├── MarkdownEditor │ │ │ │ ├── default-options.js │ │ │ │ └── index.vue │ │ │ ├── Pagination │ │ │ │ └── index.vue │ │ │ ├── PanThumb │ │ │ │ └── index.vue │ │ │ ├── RightPanel │ │ │ │ └── index.vue │ │ │ ├── Screenfull │ │ │ │ └── index.vue │ │ │ ├── Share │ │ │ │ └── DropdownMenu.vue │ │ │ ├── SizeSelect │ │ │ │ └── index.vue │ │ │ ├── Sticky │ │ │ │ └── index.vue │ │ │ ├── SvgIcon │ │ │ │ └── index.vue │ │ │ ├── TextHoverEffect │ │ │ │ └── Mallki.vue │ │ │ ├── ThemePicker │ │ │ │ └── index.vue │ │ │ ├── Tinymce │ │ │ │ ├── components │ │ │ │ │ └── EditorImage.vue │ │ │ │ ├── dynamicLoadScript.js │ │ │ │ ├── index.vue │ │ │ │ ├── plugins.js │ │ │ │ └── toolbar.js │ │ │ ├── Upload │ │ │ │ ├── SingleImage.vue │ │ │ │ ├── SingleImage2.vue │ │ │ │ └── SingleImage3.vue │ │ │ ├── UploadExcel │ │ │ │ └── index.vue │ │ │ └── common │ │ │ │ ├── lk-back-list.vue │ │ │ │ ├── lk-chart.vue │ │ │ │ ├── lk-confirm-button.vue │ │ │ │ ├── lk-edit.vue │ │ │ │ ├── lk-el-table.vue │ │ │ │ ├── lk-get-button.vue │ │ │ │ ├── lk-get-row.vue │ │ │ │ ├── lk-img-list.vue │ │ │ │ ├── lk-pagination.vue │ │ │ │ ├── lk-search-form.vue │ │ │ │ ├── lk-select-class.vue │ │ │ │ ├── lk-select-employee-info.vue │ │ │ │ ├── lk-select-org.vue │ │ │ │ ├── lk-show-pdf.vue │ │ │ │ ├── lk-table-button.vue │ │ │ │ ├── lk-table-field-filter.vue │ │ │ │ ├── lk-tool-button.vue │ │ │ │ ├── lk-view-date.vue │ │ │ │ ├── lk-view-header.vue │ │ │ │ ├── lk-view-html.vue │ │ │ │ ├── lk-view-item.vue │ │ │ │ ├── lk-view-row.vue │ │ │ │ ├── lk-view-textarea.vue │ │ │ │ └── lx-preview-office.vue │ │ ├── directive │ │ │ ├── clipboard │ │ │ │ ├── clipboard.js │ │ │ │ └── index.js │ │ │ ├── el-drag-dialog │ │ │ │ ├── drag.js │ │ │ │ └── index.js │ │ │ ├── el-table │ │ │ │ ├── adaptive.js │ │ │ │ └── index.js │ │ │ ├── permission │ │ │ │ ├── index.js │ │ │ │ └── permission.js │ │ │ ├── sticky.js │ │ │ └── waves │ │ │ │ ├── index.js │ │ │ │ ├── waves.css │ │ │ │ └── waves.js │ │ ├── filters │ │ │ └── index.js │ │ ├── icons │ │ │ ├── ch.png │ │ │ ├── deleteImg.png │ │ │ ├── gmanager.png │ │ │ ├── guiyangguanliju.png │ │ │ ├── index.js │ │ │ ├── leftTitle.png │ │ │ ├── loginBackground.png │ │ │ ├── loginBackground_logo.png │ │ │ ├── login_button.png │ │ │ ├── logo.jpg │ │ │ ├── logo.png │ │ │ ├── logoz.png │ │ │ ├── logozv.jpg │ │ │ ├── logozv.png │ │ │ ├── mapLogo.png │ │ │ ├── maxBackground.png │ │ │ ├── rightTitle.png │ │ │ ├── shuihui.png │ │ │ ├── svg │ │ │ │ ├── 404.svg │ │ │ │ ├── bug.svg │ │ │ │ ├── car.svg │ │ │ │ ├── chart.svg │ │ │ │ ├── clear.svg │ │ │ │ ├── clipboard.svg │ │ │ │ ├── component.svg │ │ │ │ ├── dashboard.svg │ │ │ │ ├── documentation.svg │ │ │ │ ├── drag.svg │ │ │ │ ├── edit.svg │ │ │ │ ├── education.svg │ │ │ │ ├── email.svg │ │ │ │ ├── example.svg │ │ │ │ ├── excel.svg │ │ │ │ ├── exit-fullscreen.svg │ │ │ │ ├── eye-open.svg │ │ │ │ ├── eye.svg │ │ │ │ ├── finger.svg │ │ │ │ ├── form.svg │ │ │ │ ├── fullscreen.svg │ │ │ │ ├── guide.svg │ │ │ │ ├── icon.svg │ │ │ │ ├── international.svg │ │ │ │ ├── language.svg │ │ │ │ ├── link.svg │ │ │ │ ├── list.svg │ │ │ │ ├── location.svg │ │ │ │ ├── lock.svg │ │ │ │ ├── message.svg │ │ │ │ ├── money.svg │ │ │ │ ├── nested.svg │ │ │ │ ├── notification.svg │ │ │ │ ├── password.svg │ │ │ │ ├── pdf.svg │ │ │ │ ├── people.svg │ │ │ │ ├── peoples.svg │ │ │ │ ├── put.svg │ │ │ │ ├── qian.svg │ │ │ │ ├── qq.svg │ │ │ │ ├── rubbish.svg │ │ │ │ ├── screenClose.png │ │ │ │ ├── search.svg │ │ │ │ ├── shop.svg │ │ │ │ ├── shopping.svg │ │ │ │ ├── size.svg │ │ │ │ ├── skill.svg │ │ │ │ ├── smallPeople.svg │ │ │ │ ├── star.svg │ │ │ │ ├── system.svg │ │ │ │ ├── tab.svg │ │ │ │ ├── table.svg │ │ │ │ ├── theme.svg │ │ │ │ ├── tree-table.svg │ │ │ │ ├── tree.svg │ │ │ │ ├── user.svg │ │ │ │ ├── wechat.svg │ │ │ │ └── zip.svg │ │ │ └── svgo.yml │ │ ├── layout │ │ │ ├── components │ │ │ │ ├── AppMain.vue │ │ │ │ ├── Navbar.vue │ │ │ │ ├── RightMenu │ │ │ │ │ └── index.vue │ │ │ │ ├── Settings │ │ │ │ │ └── index.vue │ │ │ │ ├── Sidebar │ │ │ │ │ ├── FixiOSBug.js │ │ │ │ │ ├── Item.vue │ │ │ │ │ ├── Link.vue │ │ │ │ │ ├── Logo.vue │ │ │ │ │ ├── SidebarItem.vue │ │ │ │ │ └── index.vue │ │ │ │ ├── TagsView │ │ │ │ │ ├── ScrollPane.vue │ │ │ │ │ └── index.vue │ │ │ │ └── index.js │ │ │ ├── index.vue │ │ │ └── mixin │ │ │ │ └── ResizeHandler.js │ │ ├── libs │ │ │ ├── TxtFilter.js │ │ │ ├── app.js │ │ │ ├── bus.js │ │ │ ├── crypto.js │ │ │ ├── dialog.js │ │ │ ├── http.js │ │ │ ├── methodMap.js │ │ │ ├── resize.js │ │ │ ├── sha256.js │ │ │ ├── tool.js │ │ │ ├── util.js │ │ │ ├── validate.js │ │ │ └── watermark.js │ │ ├── main.js │ │ ├── permission.js │ │ ├── router │ │ │ └── index.js │ │ ├── settings.js │ │ ├── store │ │ │ ├── getters.js │ │ │ ├── index.js │ │ │ └── modules │ │ │ │ ├── app.js │ │ │ │ ├── errorLog.js │ │ │ │ ├── permission.js │ │ │ │ ├── settings.js │ │ │ │ ├── tagsView.js │ │ │ │ └── user.js │ │ ├── styles │ │ │ ├── btn.scss │ │ │ ├── common │ │ │ │ ├── dataList.scss │ │ │ │ └── form.scss │ │ │ ├── dialog.scss │ │ │ ├── element-ui.scss │ │ │ ├── element-variables.scss │ │ │ ├── index.scss │ │ │ ├── mixin.scss │ │ │ ├── sidebar.scss │ │ │ ├── transition.scss │ │ │ └── variables.scss │ │ ├── utils │ │ │ ├── auth.js │ │ │ ├── autoLoad.js │ │ │ ├── error-log.js │ │ │ ├── get-page-title.js │ │ │ ├── index.js │ │ │ ├── listen.js │ │ │ ├── open-window.js │ │ │ ├── permission.js │ │ │ ├── registeredComponents.js │ │ │ ├── request.js │ │ │ ├── scroll-to.js │ │ │ ├── sortUtil.js │ │ │ ├── toastUtils.js │ │ │ ├── tool.js │ │ │ ├── util.js │ │ │ └── validate.js │ │ ├── vendor │ │ │ ├── Export2Excel.js │ │ │ └── Export2Zip.js │ │ └── views │ │ │ ├── blog │ │ │ ├── dir-article-class.vue │ │ │ ├── dir-article-comments.vue │ │ │ ├── dir-article-info.vue │ │ │ ├── dir-web-about.vue │ │ │ ├── dir-web-music.vue │ │ │ ├── dir-web-site.vue │ │ │ ├── get-article-class.vue │ │ │ ├── get-article-info.vue │ │ │ ├── get-web-about.vue │ │ │ ├── get-web-music.vue │ │ │ ├── get-web-site.vue │ │ │ ├── view-article-class.vue │ │ │ ├── view-article-comments.vue │ │ │ ├── view-article-info.vue │ │ │ ├── view-web-about.vue │ │ │ ├── view-web-music.vue │ │ │ └── view-web-site.vue │ │ │ ├── carPosition │ │ │ ├── carTrack.vue │ │ │ ├── index.vue │ │ │ └── orderMap.vue │ │ │ ├── dashboard │ │ │ ├── admin │ │ │ │ ├── components │ │ │ │ │ ├── AmountChart.vue │ │ │ │ │ ├── AmountCountChart.vue │ │ │ │ │ ├── DayGroup.vue │ │ │ │ │ ├── LineChart.vue │ │ │ │ │ ├── TodoList │ │ │ │ │ │ ├── Todo.vue │ │ │ │ │ │ ├── index.scss │ │ │ │ │ │ └── index.vue │ │ │ │ │ └── mixins │ │ │ │ │ │ └── resize.js │ │ │ │ └── index.vue │ │ │ ├── editor │ │ │ │ └── index.vue │ │ │ └── index.vue │ │ │ ├── driverScores │ │ │ ├── dir-company-monthly-report.vue │ │ │ ├── dir-complaints-record.vue │ │ │ ├── dir-driver-portrait.vue │ │ │ ├── dir-evaluation-record.vue │ │ │ ├── dir-monthly-report.vue │ │ │ ├── dir-risk-identify.vue │ │ │ ├── view-company-monthly-report.vue │ │ │ ├── view-complaints-record.vue │ │ │ ├── view-driver-portrait.vue │ │ │ ├── view-evaluation-record.vue │ │ │ ├── view-monthly-report.vue │ │ │ └── view-risk-identify.vue │ │ │ ├── error-page │ │ │ ├── 401.vue │ │ │ └── 404.vue │ │ │ ├── login │ │ │ ├── auth-redirect.vue │ │ │ ├── components │ │ │ │ └── SocialSignin.vue │ │ │ └── index.vue │ │ │ ├── org │ │ │ ├── allCity.js │ │ │ ├── index.vue │ │ │ └── provs.js │ │ │ ├── redirect │ │ │ └── index.vue │ │ │ ├── sys │ │ │ ├── admin.vue │ │ │ ├── get-admin.vue │ │ │ ├── log.vue │ │ │ └── role.vue │ │ │ └── system │ │ │ ├── dir-role-info.vue │ │ │ ├── dir-user-info.vue │ │ │ ├── get-role-info.vue │ │ │ ├── get-user-info.vue │ │ │ ├── view-role-info.vue │ │ │ └── view-user-info.vue │ ├── tests │ │ └── unit │ │ │ ├── .eslintrc.js │ │ │ ├── components │ │ │ ├── Hamburger.spec.js │ │ │ └── SvgIcon.spec.js │ │ │ └── utils │ │ │ ├── formatTime.spec.js │ │ │ ├── parseTime.spec.js │ │ │ └── validate.spec.js │ └── vue.config.js ├── zy-blog-server │ ├── .idea │ │ ├── .gitignore │ │ ├── git_toolbox_prj.xml │ │ ├── misc.xml │ │ ├── modules.xml │ │ ├── vcs.xml │ │ └── zy-blog-server.iml │ ├── README.md │ ├── common.js │ ├── controller │ │ ├── sms │ │ │ ├── admin-role.js │ │ │ ├── admin-user.js │ │ │ ├── blog.js │ │ │ ├── captcha.js │ │ │ ├── login.js │ │ │ └── upload.js │ │ └── web │ │ │ └── web-blog.js │ ├── db.js │ ├── index.js │ ├── middleware │ │ └── error-handler.js │ ├── model │ │ └── base-model.js │ ├── package-lock.json │ ├── package.json │ ├── public │ │ └── images │ │ │ ├── 1645167682751da3dcbb9edc0d.jpg │ │ │ ├── 1645167696167dac4727cfaca9.jpg │ │ │ ├── 16451677107259e3c513d8bd16.jpg │ │ │ ├── 16451680945270f41dc9e446ec.jpeg │ │ │ ├── 16451681570896321ccac96027.png │ │ │ ├── 1645246622097ce014a84fa804.jpg │ │ │ ├── 16452466422911bf5e1f061004.jpg │ │ │ └── 16452755272494861c93dbb93c.jpg │ ├── router │ │ ├── index.js │ │ ├── system │ │ │ ├── blog.js │ │ │ └── sms.js │ │ ├── upload │ │ │ └── upload.js │ │ └── web │ │ │ └── web-blog.js │ ├── sql │ │ └── zy-blog.sql │ ├── sqlMap │ │ ├── system.js │ │ └── web.js │ ├── test.png │ ├── utils │ │ ├── common.js │ │ ├── crypto.js │ │ ├── token.js │ │ └── tools.js │ ├── yarn-error.log │ └── yarn.lock └── zy-blog-web │ ├── .env │ ├── .gitignore │ ├── babel.config.js │ ├── license │ ├── package-lock.json │ ├── package.json │ ├── public │ ├── favicon.ico │ └── index.html │ ├── src │ ├── App.vue │ ├── Mock │ │ ├── category.js │ │ ├── comment.js │ │ ├── focus.js │ │ ├── friend.js │ │ ├── index.js │ │ ├── post.js │ │ └── site.js │ ├── api │ │ ├── http.js │ │ ├── index.js │ │ └── web-blog.js │ ├── assets │ │ ├── _tortoise.svg │ │ ├── css │ │ │ ├── reset.css │ │ │ └── style.less │ │ ├── font │ │ │ ├── iconfont.css │ │ │ ├── iconfont.eot │ │ │ ├── iconfont.js │ │ │ ├── iconfont.json │ │ │ ├── iconfont.svg │ │ │ ├── iconfont.ttf │ │ │ ├── iconfont.woff │ │ │ ├── iconfont.woff2 │ │ │ └── iconfont2.css │ │ ├── images │ │ │ ├── bg-one.png │ │ │ ├── bg.jpg │ │ │ ├── bg1.jpg │ │ │ ├── head.jpg │ │ │ ├── vx.jpg │ │ │ └── zfb.jpg │ │ ├── site-logo.svg │ │ └── tortoise.svg │ ├── components │ │ ├── back-top.vue │ │ ├── banner.vue │ │ ├── comment.vue │ │ ├── feature.vue │ │ ├── header-search.vue │ │ ├── layout │ │ │ ├── layout-body.vue │ │ │ ├── layout-footer.vue │ │ │ └── layout-header.vue │ │ ├── lk-pagination.vue │ │ ├── loading.vue │ │ ├── menu-tree.vue │ │ ├── post.vue │ │ ├── quote.vue │ │ ├── section-title.vue │ │ └── small-ico.vue │ ├── main.js │ ├── router │ │ └── index.js │ ├── store │ │ └── index.js │ ├── utils │ │ ├── index.js │ │ └── request.js │ └── views │ │ ├── About.vue │ │ ├── Articles.vue │ │ ├── Friend.vue │ │ └── Home.vue │ ├── vue.config.js │ └── yarn.lock └── v1.0.2 ├── .gitignore ├── README.en.md ├── README.md ├── doc └── logo.png ├── mg-admin ├── .browserslistrc ├── .editorconfig ├── .env ├── .env.development ├── .env.preview ├── .eslintignore ├── .eslintrc.js ├── .gitignore ├── .postcssrc.js ├── LICENSE ├── README.md ├── README.zh.md ├── babel.config.js ├── d2-admin.babel ├── dependencies-cdn.js ├── jest.config.js ├── jsconfig.json ├── package-lock.json ├── package.json ├── public │ ├── icon.ico │ ├── image │ │ ├── baidu-pan-logo.png │ │ ├── loading │ │ │ └── loading-spin.svg │ │ └── theme │ │ │ ├── chester │ │ │ ├── logo │ │ │ │ ├── all.png │ │ │ │ └── icon-only.png │ │ │ └── preview@2x.png │ │ │ ├── d2 │ │ │ ├── logo │ │ │ │ ├── all.png │ │ │ │ └── icon-only.png │ │ │ └── preview@2x.png │ │ │ ├── element │ │ │ ├── logo │ │ │ │ ├── all.png │ │ │ │ └── icon-only.png │ │ │ └── preview@2x.png │ │ │ ├── line │ │ │ ├── bg.jpg │ │ │ ├── logo │ │ │ │ ├── all.png │ │ │ │ └── icon-only.png │ │ │ └── preview@2x.png │ │ │ ├── star │ │ │ ├── bg.jpg │ │ │ ├── logo │ │ │ │ ├── all.png │ │ │ │ └── icon-only.png │ │ │ └── preview@2x.png │ │ │ ├── tomorrow-night-blue │ │ │ ├── logo │ │ │ │ ├── all.png │ │ │ │ └── icon-only.png │ │ │ └── preview@2x.png │ │ │ └── violet │ │ │ ├── logo │ │ │ ├── all.png │ │ │ └── icon-only.png │ │ │ └── preview@2x.png │ └── index.html ├── src │ ├── App.vue │ ├── api │ │ ├── http.js │ │ ├── index.js │ │ ├── modules │ │ │ ├── sys.about.api.js │ │ │ ├── sys.article.api.js │ │ │ ├── sys.code.api.js │ │ │ ├── sys.comments.api.js │ │ │ ├── sys.friends.api.js │ │ │ ├── sys.index.api.js │ │ │ ├── sys.login.api.js │ │ │ ├── sys.menus.api.js │ │ │ ├── sys.message.api.js │ │ │ ├── sys.musics.api.js │ │ │ ├── sys.public.api.js │ │ │ ├── sys.roles.api.js │ │ │ ├── sys.socials.api.js │ │ │ ├── sys.sort.api.js │ │ │ ├── sys.tags.api.js │ │ │ ├── sys.user.api.js │ │ │ ├── sys.users.api.js │ │ │ └── sys.website.api.js │ │ ├── service.js │ │ └── tools.js │ ├── assets │ │ ├── img │ │ │ └── 404.webp │ │ ├── style │ │ │ ├── animate │ │ │ │ └── vue-transition.scss │ │ │ ├── fixed │ │ │ │ ├── base.scss │ │ │ │ ├── element.scss │ │ │ │ ├── markdown.scss │ │ │ │ ├── n-progress.scss │ │ │ │ ├── tree-view.scss │ │ │ │ ├── vue-grid-layout.scss │ │ │ │ └── vue-splitpane.scss │ │ │ ├── form │ │ │ │ └── editForm.scss │ │ │ ├── pages │ │ │ │ ├── dialog.scss │ │ │ │ ├── page.scss │ │ │ │ └── v-select-page.scss │ │ │ ├── public-class.scss │ │ │ ├── public.scss │ │ │ ├── theme │ │ │ │ ├── chester │ │ │ │ │ ├── index.scss │ │ │ │ │ └── setting.scss │ │ │ │ ├── d2 │ │ │ │ │ ├── index.scss │ │ │ │ │ └── setting.scss │ │ │ │ ├── element │ │ │ │ │ ├── index.scss │ │ │ │ │ └── setting.scss │ │ │ │ ├── line │ │ │ │ │ ├── index.scss │ │ │ │ │ └── setting.scss │ │ │ │ ├── register.scss │ │ │ │ ├── star │ │ │ │ │ ├── index.scss │ │ │ │ │ └── setting.scss │ │ │ │ ├── theme-base.scss │ │ │ │ ├── theme.scss │ │ │ │ ├── tomorrow-night-blue │ │ │ │ │ ├── index.scss │ │ │ │ │ └── setting.scss │ │ │ │ └── violet │ │ │ │ │ ├── index.scss │ │ │ │ │ └── setting.scss │ │ │ └── unit │ │ │ │ └── color.scss │ │ └── svg-icons │ │ │ ├── icons │ │ │ ├── d2-admin-text.svg │ │ │ ├── d2-admin.svg │ │ │ └── d2-logo.svg │ │ │ └── index.js │ ├── components │ │ ├── Tinymce │ │ │ ├── components │ │ │ │ └── EditorImage.vue │ │ │ ├── dynamicLoadScript.js │ │ │ ├── index.vue │ │ │ ├── plugins.js │ │ │ └── toolbar.js │ │ ├── common │ │ │ ├── mk-aplayer.vue │ │ │ ├── mk-back-list.vue │ │ │ ├── mk-chart.vue │ │ │ ├── mk-checkbox-dict.vue │ │ │ ├── mk-confirm-button.vue │ │ │ ├── mk-dialog.vue │ │ │ ├── mk-el-table.vue │ │ │ ├── mk-form-button.vue │ │ │ ├── mk-form-header.vue │ │ │ ├── mk-form-row.vue │ │ │ ├── mk-get-button.vue │ │ │ ├── mk-get-row.vue │ │ │ ├── mk-img-list.vue │ │ │ ├── mk-ip-card.vue │ │ │ ├── mk-map.vue │ │ │ ├── mk-menu-tree.vue │ │ │ ├── mk-one-sentence.vue │ │ │ ├── mk-pagination.vue │ │ │ ├── mk-radio-dict.vue │ │ │ ├── mk-search-form.vue │ │ │ ├── mk-select-dict.vue │ │ │ ├── mk-select-page.vue │ │ │ ├── mk-select-role.vue │ │ │ ├── mk-select-sort.vue │ │ │ ├── mk-select-tag.vue │ │ │ ├── mk-splitpane.vue │ │ │ ├── mk-table-button.vue │ │ │ ├── mk-tool-button.vue │ │ │ ├── mk-upload.vue │ │ │ ├── mk-view-code.vue │ │ │ ├── mk-view-date.vue │ │ │ ├── mk-view-html.vue │ │ │ ├── mk-view-item.vue │ │ │ ├── mk-view-row.vue │ │ │ ├── mk-view-textarea.vue │ │ │ └── table-field-filter.vue │ │ ├── d2-container │ │ │ ├── components │ │ │ │ ├── d2-container-card-bs.vue │ │ │ │ ├── d2-container-card.vue │ │ │ │ ├── d2-container-full-bs.vue │ │ │ │ ├── d2-container-full.vue │ │ │ │ ├── d2-container-ghost-bs.vue │ │ │ │ ├── d2-container-ghost.vue │ │ │ │ ├── d2-source.vue │ │ │ │ └── mixins │ │ │ │ │ ├── bs.js │ │ │ │ │ └── normal.js │ │ │ └── index.js │ │ ├── d2-icon-select │ │ │ ├── data │ │ │ │ └── index.js │ │ │ └── index.vue │ │ ├── d2-icon-svg │ │ │ └── index.vue │ │ ├── d2-icon │ │ │ ├── font-awesome-4.7.0 │ │ │ │ ├── css │ │ │ │ │ └── font-awesome.min.css │ │ │ │ └── fonts │ │ │ │ │ ├── FontAwesome.otf │ │ │ │ │ ├── fontawesome-webfont.eot │ │ │ │ │ ├── fontawesome-webfont.svg │ │ │ │ │ ├── fontawesome-webfont.ttf │ │ │ │ │ ├── fontawesome-webfont.woff │ │ │ │ │ └── fontawesome-webfont.woff2 │ │ │ └── index.vue │ │ ├── index.js │ │ └── md-editor │ │ │ ├── index.vue │ │ │ ├── plugins.js │ │ │ └── toolbar.js │ ├── i18n.js │ ├── layout │ │ └── header-aside │ │ │ ├── components │ │ │ ├── contextmenu │ │ │ │ ├── components │ │ │ │ │ └── contentmenuList │ │ │ │ │ │ └── index.vue │ │ │ │ └── index.vue │ │ │ ├── header-color │ │ │ │ └── index.vue │ │ │ ├── header-fullscreen │ │ │ │ └── index.vue │ │ │ ├── header-locales │ │ │ │ └── index.vue │ │ │ ├── header-log │ │ │ │ └── index.vue │ │ │ ├── header-search │ │ │ │ └── index.vue │ │ │ ├── header-size │ │ │ │ └── index.vue │ │ │ ├── header-theme │ │ │ │ ├── components │ │ │ │ │ └── d2-theme-list │ │ │ │ │ │ └── index.vue │ │ │ │ └── index.vue │ │ │ ├── header-user │ │ │ │ └── index.vue │ │ │ ├── libs │ │ │ │ └── util.menu.js │ │ │ ├── menu-header │ │ │ │ └── index.js │ │ │ ├── menu-side │ │ │ │ └── index.js │ │ │ ├── mixin │ │ │ │ └── menu.js │ │ │ ├── panel-search │ │ │ │ ├── components │ │ │ │ │ └── panel-search-item │ │ │ │ │ │ └── index.vue │ │ │ │ └── index.vue │ │ │ └── tabs │ │ │ │ └── index.vue │ │ │ ├── index.js │ │ │ ├── layout.vue │ │ │ └── mixins │ │ │ └── search.js │ ├── libs │ │ ├── directives │ │ │ ├── index.js │ │ │ ├── v-copy.js │ │ │ └── v-heightlight.js │ │ ├── util.cookies.js │ │ ├── util.db.js │ │ ├── util.export.js │ │ ├── util.import.development.js │ │ ├── util.import.production.js │ │ ├── util.js │ │ ├── util.log.js │ │ ├── utils.crypto.js │ │ ├── utils.listen.js │ │ ├── utils.registeredComponents.js │ │ ├── utils.request.js │ │ ├── utils.toast.js │ │ └── utils.tool.js │ ├── locales │ │ ├── en.json │ │ ├── ja.json │ │ ├── mixin.js │ │ ├── zh-chs.json │ │ └── zh-cht.json │ ├── main.js │ ├── menu │ │ └── index.js │ ├── plugin │ │ ├── api │ │ │ └── index.js │ │ ├── d2admin │ │ │ └── index.js │ │ ├── error │ │ │ └── index.js │ │ ├── log │ │ │ └── index.js │ │ └── open │ │ │ └── index.js │ ├── router │ │ ├── index.js │ │ └── routes.js │ ├── setting.js │ ├── store │ │ ├── index.js │ │ └── modules │ │ │ └── d2admin │ │ │ ├── index.js │ │ │ └── modules │ │ │ ├── account.js │ │ │ ├── color.js │ │ │ ├── db.js │ │ │ ├── fullscreen.js │ │ │ ├── gray.js │ │ │ ├── log.js │ │ │ ├── menu.js │ │ │ ├── page.js │ │ │ ├── perms.js │ │ │ ├── releases.js │ │ │ ├── search.js │ │ │ ├── size.js │ │ │ ├── theme.js │ │ │ ├── transition.js │ │ │ ├── ua.js │ │ │ └── user.js │ └── views │ │ ├── client │ │ ├── dir-about-info.vue │ │ ├── dir-article-info.vue │ │ ├── dir-comments-info.vue │ │ ├── dir-friends-info.vue │ │ ├── dir-message-info.vue │ │ ├── dir-musics-info.vue │ │ ├── dir-socials-info.vue │ │ ├── dir-sort-info.vue │ │ ├── dir-tags-info.vue │ │ ├── dir-website-info.vue │ │ ├── get-about-info.vue │ │ ├── get-article-info.vue │ │ ├── get-comments-info.vue │ │ ├── get-friends-info.vue │ │ ├── get-message-info.vue │ │ ├── get-musics-info.vue │ │ ├── get-socials-info.vue │ │ ├── get-sort-info.vue │ │ ├── get-tags-info.vue │ │ ├── get-website-info.vue │ │ ├── view-about-info.vue │ │ ├── view-article-info.vue │ │ ├── view-comments-info.vue │ │ ├── view-friends-info.vue │ │ ├── view-message-info.vue │ │ ├── view-musics-info.vue │ │ ├── view-socials-info.vue │ │ ├── view-sort-info.vue │ │ ├── view-tags-info.vue │ │ └── view-website-info.vue │ │ ├── demo │ │ ├── page1 │ │ │ └── index.vue │ │ ├── page2 │ │ │ └── index.vue │ │ └── page3 │ │ │ └── index.vue │ │ └── system │ │ ├── code │ │ ├── dir-code-info.vue │ │ ├── dir-code-table-info.vue │ │ └── template │ │ │ ├── dir-template-info.vue │ │ │ ├── dir.template.js │ │ │ ├── get-template-info.vue │ │ │ ├── get.template.js │ │ │ ├── test.vue │ │ │ ├── view-template-info.vue │ │ │ └── view.template.js │ │ ├── error │ │ └── 404 │ │ │ └── index.vue │ │ ├── function │ │ ├── redirect │ │ │ └── index.js │ │ └── refresh │ │ │ └── index.js │ │ ├── icon │ │ ├── components │ │ │ └── d2-icon-cell.vue │ │ ├── data │ │ │ └── index.js │ │ ├── icon-svg.vue │ │ ├── icon.vue │ │ ├── list.vue │ │ ├── select-svg.vue │ │ └── select.vue │ │ ├── index │ │ ├── components │ │ │ ├── d2-badge │ │ │ │ └── index.vue │ │ │ ├── d2-help │ │ │ │ ├── image │ │ │ │ │ ├── qq.svg │ │ │ │ │ └── we.svg │ │ │ │ └── index.vue │ │ │ └── d2-page-cover │ │ │ │ ├── image │ │ │ │ └── darkblue@2x.png │ │ │ │ └── index.vue │ │ ├── image │ │ │ └── qr@2x.png │ │ ├── index.js │ │ └── page.vue │ │ ├── log │ │ └── index.vue │ │ ├── login │ │ ├── image │ │ │ ├── login-code.png │ │ │ └── logo@2x.png │ │ ├── index.js │ │ └── page.vue │ │ ├── menus │ │ ├── dir-menus-info.vue │ │ ├── get-menus-info.vue │ │ ├── get-sub-menus-info.vue │ │ └── view-menus-info.vue │ │ ├── perm │ │ └── index.vue │ │ ├── roles │ │ ├── dir-roles-info.vue │ │ ├── get-perm-info.vue │ │ ├── get-roles-info.vue │ │ └── view-roles-info.vue │ │ └── users │ │ ├── dir-users-info.vue │ │ ├── get-users-info.vue │ │ └── view-users-info.vue ├── tests │ └── unit │ │ └── .eslintrc.js ├── vue.config.js └── yarn.lock ├── mg-client ├── .editorconfig ├── .gitignore ├── README.md ├── babel.config.js ├── license ├── package-lock.json ├── package.json ├── public │ ├── favicon.ico │ └── index.html ├── src │ ├── App.vue │ ├── Mock │ │ ├── category.js │ │ ├── comment.js │ │ ├── focus.js │ │ ├── friend.js │ │ ├── index.js │ │ ├── post.js │ │ └── site.js │ ├── api │ │ ├── article.js │ │ ├── cate.js │ │ ├── friends.js │ │ ├── http.js │ │ ├── index.js │ │ └── website.js │ ├── assets │ │ ├── _tortoise.svg │ │ ├── css │ │ │ ├── reset.css │ │ │ └── style.less │ │ ├── font │ │ │ ├── iconfont.css │ │ │ ├── iconfont.eot │ │ │ ├── iconfont.js │ │ │ ├── iconfont.json │ │ │ ├── iconfont.svg │ │ │ ├── iconfont.ttf │ │ │ ├── iconfont.woff │ │ │ └── iconfont.woff2 │ │ ├── img │ │ │ ├── avator.svg │ │ │ ├── bg.jpg │ │ │ ├── cover.png │ │ │ ├── favicon_logosc (1) │ │ │ │ ├── android-chrome-192x192.png │ │ │ │ ├── android-chrome-512x512.png │ │ │ │ ├── apple-touch-icon.png │ │ │ │ ├── favicon-16x16.png │ │ │ │ ├── favicon-32x32.png │ │ │ │ ├── favicon.ico │ │ │ │ └── site.webmanifest │ │ │ ├── logo.png │ │ │ ├── logo.svg │ │ │ ├── vx.jpg │ │ │ └── zfb.jpg │ │ ├── site-logo.svg │ │ └── tortoise.svg │ ├── components │ │ ├── Tinymce │ │ │ ├── components │ │ │ │ └── EditorImage.vue │ │ │ ├── dynamicLoadScript.js │ │ │ ├── index.vue │ │ │ ├── plugins.js │ │ │ └── toolbar.js │ │ ├── back-top.vue │ │ ├── banner.vue │ │ ├── comment.vue │ │ ├── feature.vue │ │ ├── header-search.vue │ │ ├── layout │ │ │ ├── layout-body.vue │ │ │ ├── layout-footer.vue │ │ │ └── layout-header.vue │ │ ├── loading.vue │ │ ├── md-editor │ │ │ ├── index.vue │ │ │ ├── plugins.js │ │ │ └── toolbar.js │ │ ├── menu-tree.vue │ │ ├── mg-chart.vue │ │ ├── mk-aplayer.vue │ │ ├── post.vue │ │ ├── quote.vue │ │ ├── section-title.vue │ │ └── small-ico.vue │ ├── main.js │ ├── router │ │ └── index.js │ ├── store │ │ └── index.js │ ├── utils │ │ ├── index.js │ │ └── request.js │ └── views │ │ ├── About.vue │ │ ├── AllArticle.vue │ │ ├── Archive.vue │ │ ├── Articles.vue │ │ ├── Friend.vue │ │ └── Home.vue └── vue.config.js └── mg-server ├── .env ├── LICENSE ├── app.js ├── cheese.log ├── config ├── db.config.js └── upload.config.js ├── controllers ├── about.controller.js ├── article.controller.js ├── code.generation.controller.js ├── comments.controller.js ├── friends.controller.js ├── home.controller.js ├── login.controller.js ├── menus.controller.js ├── message.controller.js ├── music.controller.js ├── roles.controller.js ├── socials.controller.js ├── sort.controller.js ├── tags.controller.js ├── users.controller.js └── website.controller.js ├── dao ├── DAO.js └── POST_DAO.js ├── models ├── about.model.js ├── article.model.js ├── article_tags.model.js ├── comments.model.js ├── friend.model.js ├── index.js ├── menus.model.js ├── message.model.js ├── model_relationship.js ├── music.model.js ├── roles.model.js ├── roles_menus.model.js ├── socials.model.js ├── sort.model.js ├── tags.model.js ├── users.model.js └── website.model.js ├── package-lock.json ├── package.json ├── routes └── api │ ├── private │ ├── about.js │ ├── article.js │ ├── code.js │ ├── comments.js │ ├── friends.js │ ├── menus.js │ ├── message.js │ ├── musics.js │ ├── roles.js │ ├── socials.js │ ├── sort.js │ ├── tags.js │ ├── upload.js │ ├── users.js │ └── website.js │ └── public │ ├── admin │ ├── captcha.js │ ├── getFiles.js │ └── login.js │ └── web │ ├── about.js │ ├── article.js │ ├── comments.js │ ├── friends.js │ ├── message.js │ ├── music.js │ ├── socials.js │ ├── sort.js │ ├── upload.js │ └── website.js ├── sql └── mg_db.sql ├── uploads_files ├── 0b6258d0c94d401d9094985f8070e3ab.png ├── 104b38c1f5a5b55230bbd06eeb27a17a.jpg ├── 146130b7594862acb422b9f12908d2d3.png ├── 1792c82becf2c5ee22335fed9db7c2a0.jpg ├── 1bc9803c6075e7bd820291c10941cc1d.png ├── 247d75740a1bcfd2ecee500276bdcdcc.jpg ├── 25f0e5c3689da50fd2a8dcfd413f1bcf.jpg ├── 36315071491c4b2246ae78749fb09d6b.jpg ├── 486753653f833536fc33d08dd80dab2e.jpg ├── 4a8bd0bc19ce5336c21e49560069d240.jpg ├── 4e93b5cf5a19e974bec047a8853328cf.jpg ├── 60d2b58f2bfdcad1fca7c849f9e7999c.jpg ├── 62a2701f66af78943ad82b18efa1767c.jpg ├── 68384a08722b254e8303c837d1a59fa1.png ├── 7995fe6cffe2300890871b18142c2633.jpg ├── 83ba81e93de095fb4f141f9b4440373c.jpg ├── 87122ba1894d5d5ce41763fb4b5c47a9.png ├── 8c78ead80dbe43420407df4a1210fe4c.jpg ├── 90e858a15a292cdff1bf0362acd1b9fb.png ├── 9964f86960805edea2e60b3a1b0a4267.jpg ├── 99f11226a20d335b92af79705fb83880.png ├── 9a0a35f398ddef8600eb3b005808807d.jpg ├── 9b891e20852db67ce232dec3d73c5e08.jpg ├── 9c83e891ff169fc9d2e9464012b09384.jpg ├── a2e43b7e011e6f4fd20336a26bff56e0.jpg ├── a543ec90a287e99aeaac195d4e0623a9.jpg ├── a664de814382f995222ab77be35ac5b0.jpg ├── a8f21e2d71eb4d3d4cfff8f61b170954.png ├── ab0057ef80b7e78dec1098681b75d58e.png ├── abb89e05b2ea122554276f9e05d9faf5.jpg ├── b238f74e35e257170e99168d3c76f197.jpg ├── b2457863e961134b78bf90c3cb599c9d.jpg ├── b79ca5d9f281f132fc1c02d6253b7252.jfif ├── b9a2a5c585232be3f3b2ce2e7171ed40.jpg ├── bc961d00ec883bbd0325f21949a8cfef.jpg ├── bcd127f45c1c3405eef82b599c11b8b0.jpg ├── be948a4a6ae5e2c40e3a8c9099f65624.jpg ├── c4a07734afdb2e95968a210cdfc06a2d.jpg ├── caaded8b91d9251e434b9f3bb4f62e64.jpg ├── cf53e8cac7542f7827d6e283519002c3.png ├── d6520f89fc9f84f57bd018dfccde5a44.jpg ├── d77aa161cb24e6405b994915251676a1.jpg ├── db37e9177dbc2fc5e56ea3b831d8ba55.png ├── e2215400be04fa47e496183dac9be1c2.png ├── e49572ff924e940ca125285b04f7b269.png ├── e775b1809cd1132a690aca571d39a2f5.jpg ├── f0a6f9e0d65048523039b7e6e78ea0b4.webp └── f22b6a4819016808581166e0fc77317b.png └── utils ├── swagger └── index.js ├── utils.crypto.js ├── utils.logger.js ├── utils.menu.js ├── utils.nodemailer.js ├── utils.permission.js ├── utils.resextra.js └── utils.tools.js /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /dist 4 | 5 | # local env files 6 | .env.local 7 | .env.*.local 8 | 9 | # Log files 10 | npm-debug.log* 11 | yarn-debug.log* 12 | yarn-error.log* 13 | 14 | # Editor directories and files 15 | .idea 16 | .vscode 17 | *.suo 18 | *.ntvs* 19 | *.njsproj 20 | *.sln 21 | *.sw? 22 | -------------------------------------------------------------------------------- /.idea/all-blog-sys.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /.idea/shelf/_2022_5_6_18_46____.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /doc/img/1.1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/doc/img/1.1.png -------------------------------------------------------------------------------- /doc/img/1.2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/doc/img/1.2.png -------------------------------------------------------------------------------- /doc/img/1.3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/doc/img/1.3.png -------------------------------------------------------------------------------- /doc/img/1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/doc/img/1.png -------------------------------------------------------------------------------- /doc/img/2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/doc/img/2.png -------------------------------------------------------------------------------- /doc/img/3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/doc/img/3.png -------------------------------------------------------------------------------- /doc/img/4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/doc/img/4.png -------------------------------------------------------------------------------- /doc/img/5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/doc/img/5.png -------------------------------------------------------------------------------- /doc/img/6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/doc/img/6.png -------------------------------------------------------------------------------- /doc/img/7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/doc/img/7.png -------------------------------------------------------------------------------- /doc/img/8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/doc/img/8.png -------------------------------------------------------------------------------- /doc/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/doc/logo.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/.editorconfig: -------------------------------------------------------------------------------- 1 | # https://editorconfig.org 2 | root = true 3 | 4 | [*] 5 | charset = utf-8 6 | indent_style = space 7 | indent_size = 2 8 | end_of_line = lf 9 | insert_final_newline = true 10 | trim_trailing_whitespace = true 11 | 12 | [*.md] 13 | insert_final_newline = false 14 | trim_trailing_whitespace = false 15 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/.env: -------------------------------------------------------------------------------- 1 | # 所有环境默认 2 | 3 | # 页面 title 前缀 4 | VUE_APP_TITLE=ZY-BLOG 5 | # base-url 6 | VUE_APP_BASE_URL='' 7 | 8 | # 国际化配置 9 | VUE_APP_I18N_LOCALE=zh-chs 10 | VUE_APP_I18N_FALLBACK_LOCALE=en 11 | 12 | # element 颜色 13 | VUE_APP_ELEMENT_COLOR=#409EFF 14 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/.env.development: -------------------------------------------------------------------------------- 1 | # just a flag 2 | ENV = 'development' 3 | 4 | # base api 5 | VUE_APP_BASE_URL='' 6 | 7 | VUE_CLI_BABEL_TRANSPILE_MODULES = true 8 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/.env.production: -------------------------------------------------------------------------------- 1 | # just a flag 2 | ENV = 'production' 3 | 4 | # base api 5 | VUE_APP_BASE_URL='' 6 | 7 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/.env.staging: -------------------------------------------------------------------------------- 1 | NODE_ENV = production 2 | 3 | # just a flag 4 | ENV = 'staging' 5 | 6 | # base api 7 | VUE_APP_BASE_API = '/stage-api' 8 | 9 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/.eslintignore: -------------------------------------------------------------------------------- 1 | build/*.js 2 | src/assets 3 | public 4 | dist 5 | src 6 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules/ 3 | dist/ 4 | npm-debug.log* 5 | yarn-debug.log* 6 | yarn-error.log* 7 | **/*.log 8 | 9 | tests/**/coverage/ 10 | tests/e2e/reports 11 | selenium-debug.log 12 | 13 | # Editor directories and files 14 | .idea 15 | .vscode 16 | *.suo 17 | *.ntvs* 18 | *.njsproj 19 | *.sln 20 | *.local 21 | 22 | package-lock.json 23 | package.json 24 | yarn.lock 25 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/.travis.yml: -------------------------------------------------------------------------------- 1 | language: node_js 2 | node_js: 10 3 | script: npm run test 4 | notifications: 5 | email: false 6 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: [ 3 | '@vue/app' 4 | ] 5 | } 6 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/deploy.sh: -------------------------------------------------------------------------------- 1 | tar -cf dist.tar.gz dist 2 | #scp dist.tar.gz tomcat@47.96.168.24:/usr/share/nginx/html/taxi-admin 3 | scp dist.tar.gz tomcat@101.37.247.13:/usr/share/nginx/html/taxi-admin 4 | 5 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/jest.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | moduleFileExtensions: ['js', 'jsx', 'json', 'vue'], 3 | transform: { 4 | '^.+\\.vue$': 'vue-jest', 5 | '.+\\.(css|styl|less|sass|scss|svg|png|jpg|ttf|woff|woff2)$': 6 | 'jest-transform-stub', 7 | '^.+\\.jsx?$': 'babel-jest' 8 | }, 9 | moduleNameMapper: { 10 | '^@/(.*)$': '/src/$1' 11 | }, 12 | snapshotSerializers: ['jest-serializer-vue'], 13 | testMatch: [ 14 | '**/tests/unit/**/*.spec.(js|jsx|ts|tsx)|**/__tests__/*.(js|jsx|ts|tsx)' 15 | ], 16 | collectCoverageFrom: ['src/utils/**/*.{js,vue}', '!src/utils/auth.js', '!src/utils/request.js', 'src/components/**/*.{js,vue}'], 17 | coverageDirectory: '/tests/unit/coverage', 18 | // 'collectCoverage': true, 19 | 'coverageReporters': [ 20 | 'lcov', 21 | 'text-summary' 22 | ], 23 | testURL: 'http://localhost/' 24 | } 25 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/jsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": "./", 4 | "paths": { 5 | "@/*": ["src/*"] 6 | } 7 | }, 8 | "exclude": ["node_modules", "dist"] 9 | } -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/plop-templates/component/index.hbs: -------------------------------------------------------------------------------- 1 | {{#if template}} 2 | 3 | 4 | 5 | {{/if}} 6 | 7 | {{#if script}} 8 | 20 | {{/if}} 21 | 22 | {{#if style}} 23 | 26 | {{/if}} 27 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/plop-templates/utils.js: -------------------------------------------------------------------------------- 1 | exports.notEmpty = name => { 2 | return v => { 3 | if (!v || v.trim === '') { 4 | return `${name} is required` 5 | } else { 6 | return true 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/plop-templates/view/index.hbs: -------------------------------------------------------------------------------- 1 | {{#if template}} 2 | 3 | 4 | 5 | {{/if}} 6 | 7 | {{#if script}} 8 | 20 | {{/if}} 21 | 22 | {{#if style}} 23 | 26 | {{/if}} 27 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/plopfile.js: -------------------------------------------------------------------------------- 1 | const viewGenerator = require('./plop-templates/view/prompt') 2 | const componentGenerator = require('./plop-templates/component/prompt') 3 | 4 | module.exports = function(plop) { 5 | plop.setGenerator('view', viewGenerator) 6 | plop.setGenerator('component', componentGenerator) 7 | } 8 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/postcss.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | plugins: { 3 | autoprefixer: {} 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/public/favicon.ico -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/App.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 22 | 29 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/api/admin.js: -------------------------------------------------------------------------------- 1 | import request from '@/utils/request' 2 | 3 | export function listAdmin(query) { 4 | return request({ 5 | url: '/zz-server/admin/admin/list', 6 | method: 'get', 7 | params: query 8 | }) 9 | } 10 | 11 | export function createAdmin(data) { 12 | return request({ 13 | url: '/zz-server/admin/admin/create', 14 | method: 'post', 15 | data 16 | }) 17 | } 18 | 19 | export function readminAdmin(data) { 20 | return request({ 21 | url: '/zz-server/admin/admin/readmin', 22 | method: 'get', 23 | data 24 | }) 25 | } 26 | 27 | export function updateAdmin(data) { 28 | return request({ 29 | url: '/zz-server/admin/admin/update', 30 | method: 'post', 31 | data 32 | }) 33 | } 34 | 35 | export function deleteAdmin(data) { 36 | return request({ 37 | url: '/zz-server/admin/admin/delete', 38 | method: 'post', 39 | data 40 | }) 41 | } 42 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/api/article.js: -------------------------------------------------------------------------------- 1 | import request from '@/utils/request' 2 | 3 | export function fetchList(query) { 4 | return request({ 5 | url: '/article/list', 6 | method: 'get', 7 | params: query 8 | }) 9 | } 10 | 11 | export function fetchArticle(id) { 12 | return request({ 13 | url: '/article/detail', 14 | method: 'get', 15 | params: { id } 16 | }) 17 | } 18 | 19 | export function fetchPv(pv) { 20 | return request({ 21 | url: '/article/pv', 22 | method: 'get', 23 | params: { pv } 24 | }) 25 | } 26 | 27 | export function createArticle(data) { 28 | return request({ 29 | url: '/article/create', 30 | method: 'post', 31 | data 32 | }) 33 | } 34 | 35 | export function updateArticle(data) { 36 | return request({ 37 | url: '/article/update', 38 | method: 'post', 39 | data 40 | }) 41 | } 42 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/api/litemallUser.js: -------------------------------------------------------------------------------- 1 | import request from '@/utils/request' 2 | 3 | export function userList(data) { 4 | return request({ 5 | url: '/user/select', 6 | method: 'post', 7 | data 8 | }) 9 | } 10 | 11 | export function userInsert(data) { 12 | return request({ 13 | url: '/user/insert', 14 | method: 'post', 15 | data 16 | }) 17 | } 18 | 19 | export function userDelete(data) { 20 | return request({ 21 | url: '/user/delete', 22 | method: 'post', 23 | data 24 | }) 25 | } 26 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/api/org.js: -------------------------------------------------------------------------------- 1 | import request from '@/utils/request' 2 | 3 | export function listOrg(query) { 4 | return request({ 5 | url: '/taxi-server/org/select', 6 | method: 'post', 7 | params: query 8 | }) 9 | } 10 | 11 | export function orgTree(data) { 12 | return request({ 13 | url: '/taxi-server/org/tree', 14 | method: 'post', 15 | data 16 | }) 17 | } 18 | 19 | export function readminAdmin(data) { 20 | return request({ 21 | url: '/taxi-server/admin/admin/readmin', 22 | method: 'get', 23 | data 24 | }) 25 | } 26 | 27 | export function updateAdmin(data) { 28 | return request({ 29 | url: '/taxi-server/admin/admin/update', 30 | method: 'post', 31 | data 32 | }) 33 | } 34 | 35 | export function deleteAdmin(data) { 36 | return request({ 37 | url: '/taxi-server/admin/admin/delete', 38 | method: 'post', 39 | data 40 | }) 41 | } 42 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/api/qiniu.js: -------------------------------------------------------------------------------- 1 | import request from '@/utils/request' 2 | 3 | export function getToken() { 4 | return request({ 5 | url: '/taxi-file/fileserver/upload/v2', // 假地址 自行替换 6 | method: 'post' 7 | }) 8 | } 9 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/api/remote-search.js: -------------------------------------------------------------------------------- 1 | import request from '@/utils/request' 2 | 3 | export function searchUser(name) { 4 | return request({ 5 | url: '/search/user', 6 | method: 'get', 7 | params: { name } 8 | }) 9 | } 10 | 11 | export function transactionList(query) { 12 | return request({ 13 | url: '/transaction/list', 14 | method: 'get', 15 | params: query 16 | }) 17 | } 18 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/api/user.js: -------------------------------------------------------------------------------- 1 | import request from '@/utils/request' 2 | 3 | export function login(data) { 4 | return request({ 5 | url: '/zy-server/admin/login', 6 | method: 'post', 7 | data 8 | }) 9 | } 10 | 11 | export function getInfo(token) { 12 | return request({ 13 | url: '/zy-server/admin/info', 14 | method: 'get', 15 | params: { token } 16 | }) 17 | } 18 | 19 | export function logout() { 20 | return request({ 21 | url: '/zy-server/admin/logout', 22 | method: 'post' 23 | }) 24 | } 25 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/401_images/401.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/401_images/401.gif -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/404_images/404.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/404_images/404.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/404_images/404_cloud.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/404_images/404_cloud.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/car/trajectory_end_sm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/car/trajectory_end_sm.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/car/trajectory_start_sm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/car/trajectory_start_sm.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/car.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/car.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/car_bak.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/car_bak.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/car_default_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/car_default_logo.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/car_license_blank.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/car_license_blank.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/car_license_orange.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/car_license_orange.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/doCar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/doCar.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/green.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/green.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/icon_left.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/icon_left.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/icon_right.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/icon_right.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/loading.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/loading.gif -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/monitor_close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/monitor_close.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/monitor_fullscreen_nor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/monitor_fullscreen_nor.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/monitor_fullscreen_sel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/monitor_fullscreen_sel.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/monitor_tuichu_nor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/monitor_tuichu_nor.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/monitor_tuichu_sel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/monitor_tuichu_sel.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/noSingle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/noSingle.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/offlineCar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/offlineCar.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/overview@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/overview@2x.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/carPosition/positioning.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/carPosition/positioning.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/css/carPosition.scss: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/css/icon/iconfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/css/icon/iconfont.eot -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/css/icon/iconfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/css/icon/iconfont.ttf -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/css/icon/iconfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/css/icon/iconfont.woff -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/css/icon/iconfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/css/icon/iconfont.woff2 -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/custom-theme/fonts/element-icons.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/custom-theme/fonts/element-icons.ttf -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/assets/custom-theme/fonts/element-icons.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/assets/custom-theme/fonts/element-icons.woff -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/components/ImageCropper/utils/data2blob.js: -------------------------------------------------------------------------------- 1 | /** 2 | * database64文件格式转换为2进制 3 | * 4 | * @param {[String]} data dataURL 的格式为 “data:image/png;base64,****”,逗号之前都是一些说明性的文字,我们只需要逗号之后的就行了 5 | * @param {[String]} mime [description] 6 | * @return {[blob]} [description] 7 | */ 8 | export default function(data, mime) { 9 | data = data.split(',')[1] 10 | data = window.atob(data) 11 | var ia = new Uint8Array(data.length) 12 | for (var i = 0; i < data.length; i++) { 13 | ia[i] = data.charCodeAt(i) 14 | } 15 | // canvas.toDataURL 返回的默认格式就是 image/png 16 | return new Blob([ia], { 17 | type: mime 18 | }) 19 | } 20 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/components/ImageCropper/utils/mimes.js: -------------------------------------------------------------------------------- 1 | export default { 2 | 'jpg': 'image/jpeg', 3 | 'png': 'image/png', 4 | 'gif': 'image/gif', 5 | 'svg': 'image/svg+xml', 6 | 'psd': 'image/photoshop' 7 | } 8 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/components/MarkdownEditor/default-options.js: -------------------------------------------------------------------------------- 1 | // doc: https://nhnent.github.io/tui.editor/api/latest/ToastUIEditor.html#ToastUIEditor 2 | export default { 3 | minHeight: '200px', 4 | previewStyle: 'vertical', 5 | useCommandShortcut: true, 6 | useDefaultHTMLSanitizer: true, 7 | usageStatistics: false, 8 | hideModeSwitch: false, 9 | toolbarItems: [ 10 | 'heading', 11 | 'bold', 12 | 'italic', 13 | 'strike', 14 | 'divider', 15 | 'hr', 16 | 'quote', 17 | 'divider', 18 | 'ul', 19 | 'ol', 20 | 'task', 21 | 'indent', 22 | 'outdent', 23 | 'divider', 24 | 'table', 25 | 'image', 26 | 'link', 27 | 'divider', 28 | 'code', 29 | 'codeblock' 30 | ] 31 | } 32 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/components/Tinymce/plugins.js: -------------------------------------------------------------------------------- 1 | // Any plugins you want to use has to be imported 2 | // Detail plugins list see https://www.tinymce.com/docs/plugins/ 3 | // Custom builds see https://www.tinymce.com/download/custom-builds/ 4 | 5 | const plugins = ['advlist anchor autolink autosave code codesample colorpicker colorpicker contextmenu directionality emoticons fullscreen hr image imagetools insertdatetime link lists media nonbreaking noneditable pagebreak paste preview print save searchreplace spellchecker tabfocus table template textcolor textpattern visualblocks visualchars wordcount'] 6 | 7 | export default plugins 8 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/components/Tinymce/toolbar.js: -------------------------------------------------------------------------------- 1 | // Here is a list of the toolbar 2 | // Detail list see https://www.tinymce.com/docs/advanced/editor-control-identifiers/#toolbarcontrols 3 | 4 | const toolbar = [' searchreplace formatselect fontsizeselect bold italic underline strikethrough alignleft aligncenter alignright outdent indent blockquote undo redo removeformat subscript superscript code codesample ', 5 | ' hr bullist numlist fontselect link image charmap preview anchor pagebreak insertdatetime media table emoticons forecolor backcolor fullscreen'] 6 | 7 | export default toolbar 8 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/components/common/lk-get-row.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 26 | 27 | 41 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/components/common/lk-view-html.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 37 | 38 | 44 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/components/common/lk-view-row.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 16 | 17 | 29 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/directive/clipboard/index.js: -------------------------------------------------------------------------------- 1 | import Clipboard from './clipboard' 2 | 3 | const install = function(Vue) { 4 | Vue.directive('Clipboard', Clipboard) 5 | } 6 | 7 | if (window.Vue) { 8 | window.clipboard = Clipboard 9 | Vue.use(install); // eslint-disable-line 10 | } 11 | 12 | Clipboard.install = install 13 | export default Clipboard 14 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/directive/el-drag-dialog/index.js: -------------------------------------------------------------------------------- 1 | import drag from './drag' 2 | 3 | const install = function(Vue) { 4 | Vue.directive('el-drag-dialog', drag) 5 | } 6 | 7 | if (window.Vue) { 8 | window['el-drag-dialog'] = drag 9 | Vue.use(install); // eslint-disable-line 10 | } 11 | 12 | drag.install = install 13 | export default drag 14 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/directive/el-table/index.js: -------------------------------------------------------------------------------- 1 | import adaptive from './adaptive' 2 | 3 | const install = function(Vue) { 4 | Vue.directive('el-height-adaptive-table', adaptive) 5 | } 6 | 7 | if (window.Vue) { 8 | window['el-height-adaptive-table'] = adaptive 9 | Vue.use(install); // eslint-disable-line 10 | } 11 | 12 | adaptive.install = install 13 | export default adaptive 14 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/directive/permission/index.js: -------------------------------------------------------------------------------- 1 | import permission from './permission' 2 | 3 | const install = function(Vue) { 4 | Vue.directive('permission', permission) 5 | } 6 | 7 | if (window.Vue) { 8 | window['permission'] = permission 9 | Vue.use(install); // eslint-disable-line 10 | } 11 | 12 | permission.install = install 13 | export default permission 14 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/directive/permission/permission.js: -------------------------------------------------------------------------------- 1 | 2 | import store from '@/store' 3 | 4 | export default{ 5 | inserted(el, binding, vnode) { 6 | const { value } = binding 7 | const perms = store.getters && store.getters.perms 8 | 9 | if (value && value instanceof Array && value.length > 0) { 10 | const permissions = value 11 | 12 | var hasPermission = false 13 | 14 | if (perms.indexOf('*') >= 0) { 15 | hasPermission = true 16 | } else { 17 | hasPermission = perms.some(perm => { 18 | return permissions.includes(perm) 19 | }) 20 | } 21 | 22 | if (!hasPermission) { 23 | el.parentNode && el.parentNode.removeChild(el) 24 | } 25 | } else { 26 | throw new Error(`need perms! Like v-permission="['GET /aaa','POST /bbb']"`) 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/directive/waves/index.js: -------------------------------------------------------------------------------- 1 | import waves from './waves' 2 | 3 | const install = function(Vue) { 4 | Vue.directive('waves', waves) 5 | } 6 | 7 | if (window.Vue) { 8 | window.waves = waves 9 | Vue.use(install); // eslint-disable-line 10 | } 11 | 12 | waves.install = install 13 | export default waves 14 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/ch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/ch.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/deleteImg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/deleteImg.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/gmanager.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/gmanager.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/guiyangguanliju.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/guiyangguanliju.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/index.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import SvgIcon from '@/components/SvgIcon'// svg component 3 | 4 | // register globally 5 | Vue.component('svg-icon', SvgIcon) 6 | 7 | const req = require.context('./svg', false, /\.svg$/) 8 | const requireAll = requireContext => requireContext.keys().map(requireContext) 9 | requireAll(req) 10 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/leftTitle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/leftTitle.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/loginBackground.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/loginBackground.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/loginBackground_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/loginBackground_logo.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/login_button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/login_button.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/logo.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/logo.jpg -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/logo.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/logoz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/logoz.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/logozv.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/logozv.jpg -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/logozv.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/logozv.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/mapLogo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/mapLogo.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/maxBackground.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/maxBackground.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/rightTitle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/rightTitle.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/shuihui.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/shuihui.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/chart.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/component.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/documentation.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/drag.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/edit.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/education.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/email.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/example.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/excel.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/fullscreen.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/guide.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/link.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/lock.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/message.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/money.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/nested.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/password.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/people.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/peoples.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/screenClose.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/icons/svg/screenClose.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/search.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/size.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/star.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/tab.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/table.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/theme.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/tree-table.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svg/user.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/icons/svgo.yml: -------------------------------------------------------------------------------- 1 | # replace default config 2 | 3 | # multipass: true 4 | # full: true 5 | 6 | plugins: 7 | 8 | # - name 9 | # 10 | # or: 11 | # - name: false 12 | # - name: true 13 | # 14 | # or: 15 | # - name: 16 | # param1: 1 17 | # param2: 2 18 | 19 | - removeAttrs: 20 | attrs: 21 | - 'fill' 22 | - 'fill-rule' 23 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/layout/components/Sidebar/FixiOSBug.js: -------------------------------------------------------------------------------- 1 | export default { 2 | computed: { 3 | device() { 4 | return this.$store.state.app.device 5 | } 6 | }, 7 | mounted() { 8 | // In order to fix the click on menu on the ios device will trigger the mouseleave bug 9 | // https://github.com/PanJiaChen/vue-element-admin/issues/1135 10 | this.fixBugIniOS() 11 | }, 12 | methods: { 13 | fixBugIniOS() { 14 | const $subMenu = this.$refs.subMenu 15 | if ($subMenu) { 16 | const handleMouseleave = $subMenu.handleMouseleave 17 | $subMenu.handleMouseleave = (e) => { 18 | if (this.device === 'mobile') { 19 | return 20 | } 21 | handleMouseleave(e) 22 | } 23 | } 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/layout/components/Sidebar/Item.vue: -------------------------------------------------------------------------------- 1 | 30 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/layout/components/Sidebar/Link.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 37 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/layout/components/index.js: -------------------------------------------------------------------------------- 1 | export { default as AppMain } from './AppMain' 2 | export { default as Navbar } from './Navbar' 3 | export { default as Settings } from './Settings' 4 | export { default as Sidebar } from './Sidebar/index.vue' 5 | export { default as TagsView } from './TagsView/index.vue' 6 | export { default as RightMenu } from './RightMenu/index.vue' 7 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/libs/bus.js: -------------------------------------------------------------------------------- 1 | //全局事件总线,使用时一定注意事件注册的key,不能重复 2 | import Vue from 'vue'; 3 | export default new Vue(); 4 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/libs/methodMap.js: -------------------------------------------------------------------------------- 1 | 2 | import {blogApi} from "@/api/blog/blogs"; 3 | import {adminSysApi} from "@/api/sys/admin"; 4 | /** 5 | * url 访问地址 6 | * 注意:如果是导出的话一定要注意responseType设置为blob 7 | */ 8 | const methodMap = { 9 | 10 | /******项目api分离*****/ 11 | 12 | ...blogApi, //博客文章api 13 | ...adminSysApi, //系统用户api 14 | 15 | /***********************/ 16 | 17 | //管理员列表 18 | api_admin_adminList: {url: '/zy-server/admin/list', method: 'get'}, 19 | //获取用户列表 20 | api_admin_userList: {url: '/zy-server/admin/userList', method: 'post'}, 21 | //机构用户列表 22 | api_admin_orgUserList: {url: '/zy-server/admin/admin/orgUserList', method: 'post'}, 23 | //**用户菜单列表**/ 24 | getUserMenu: {url: '/zy-server/admin/userMenuList', method: 'get'}, 25 | 26 | 27 | }; 28 | export default methodMap; 29 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/store/getters.js: -------------------------------------------------------------------------------- 1 | const getters = { 2 | sidebar: state => state.app.sidebar, 3 | size: state => state.app.size, 4 | device: state => state.app.device, 5 | visitedViews: state => state.tagsView.visitedViews, 6 | cachedViews: state => state.tagsView.cachedViews, 7 | token: state => state.user.token, 8 | avatar: state => state.user.avatar, 9 | name: state => state.user.name, 10 | introduction: state => state.user.introduction, 11 | roles: state => state.user.roles, 12 | userId: state => state.user.userId, 13 | userNickName: state => state.user.userNickName, 14 | orgId: state => state.user.orgId, 15 | orgName: state => state.user.orgName, 16 | permission_routes: state => state.permission.routes, 17 | errorLogs: state => state.errorLog.logs, 18 | perms: state => state.user.perms, 19 | addRouters: state => state.permission.addRouters 20 | } 21 | export default getters 22 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/store/index.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import Vuex from 'vuex' 3 | import getters from './getters' 4 | 5 | Vue.use(Vuex) 6 | 7 | // https://webpack.js.org/guides/dependency-management/#requirecontext 8 | const modulesFiles = require.context('./modules', true, /\.js$/) 9 | 10 | // you do not need `import app from './modules/app'` 11 | // it will auto require all vuex module from modules file 12 | const modules = modulesFiles.keys().reduce((modules, modulePath) => { 13 | // set './app.js' => 'app' 14 | const moduleName = modulePath.replace(/^\.\/(.*)\.\w+$/, '$1') 15 | const value = modulesFiles(modulePath) 16 | modules[moduleName] = value.default 17 | return modules 18 | }, {}) 19 | 20 | const store = new Vuex.Store({ 21 | modules, 22 | getters 23 | }) 24 | 25 | export default store 26 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/store/modules/errorLog.js: -------------------------------------------------------------------------------- 1 | const state = { 2 | logs: [] 3 | } 4 | 5 | const mutations = { 6 | ADD_ERROR_LOG: (state, log) => { 7 | state.logs.push(log) 8 | }, 9 | CLEAR_ERROR_LOG: (state) => { 10 | state.logs.splice(0) 11 | } 12 | } 13 | 14 | const actions = { 15 | addErrorLog({ commit }, log) { 16 | commit('ADD_ERROR_LOG', log) 17 | }, 18 | clearErrorLog({ commit }) { 19 | commit('CLEAR_ERROR_LOG') 20 | } 21 | } 22 | 23 | export default { 24 | namespaced: true, 25 | state, 26 | mutations, 27 | actions 28 | } 29 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/store/modules/settings.js: -------------------------------------------------------------------------------- 1 | import variables from '@/styles/element-variables.scss' 2 | import defaultSettings from '@/settings' 3 | 4 | const { showSettings, tagsView, fixedHeader, sidebarLogo } = defaultSettings 5 | 6 | const state = { 7 | theme: variables.theme, 8 | showSettings: showSettings, 9 | tagsView: tagsView, 10 | fixedHeader: fixedHeader, 11 | sidebarLogo: sidebarLogo 12 | } 13 | 14 | const mutations = { 15 | CHANGE_SETTING: (state, { key, value }) => { 16 | if (state.hasOwnProperty(key)) { 17 | state[key] = value 18 | } 19 | } 20 | } 21 | 22 | const actions = { 23 | changeSetting({ commit }, data) { 24 | commit('CHANGE_SETTING', data) 25 | } 26 | } 27 | 28 | export default { 29 | namespaced: true, 30 | state, 31 | mutations, 32 | actions 33 | } 34 | 35 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/styles/common/form.scss: -------------------------------------------------------------------------------- 1 | .lk-add-form { 2 | padding: 28px 24px 0 31px; 3 | border-radius: 4px; 4 | width: 100%; 5 | height: 100%; 6 | overflow-y: auto; 7 | text-align: left; 8 | } 9 | 10 | .lk-add-pop { 11 | width: 100%; 12 | height: 100%; 13 | overflow-y: auto; 14 | text-align: left; 15 | padding: 13px; 16 | 17 | .row-title { 18 | font-weight: bold; 19 | font-size: 14px; 20 | color: #8b8989; 21 | line-height: 26px; 22 | } 23 | } 24 | 25 | .v-dialog-modal { 26 | z-index: 9999 !important; 27 | } 28 | 29 | .v-dialog-overlay { 30 | z-index: 998 !important; 31 | } 32 | 33 | .inline-item { 34 | 35 | } 36 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/styles/dialog.scss: -------------------------------------------------------------------------------- 1 | .v-dialog-container .v-dialog-dialog .v-dialog-content { 2 | .v-dialog-header{ 3 | border-bottom: 1px solid #eeeeee; 4 | h3 { 5 | font-weight: 400; 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/utils/auth.js: -------------------------------------------------------------------------------- 1 | import Cookies from 'js-cookie' 2 | 3 | const TokenKey = 'Admin-Token' 4 | 5 | export function getToken() { 6 | return Cookies.get(TokenKey) 7 | } 8 | 9 | export function setToken(token) { 10 | return Cookies.set(TokenKey, token) 11 | } 12 | 13 | export function removeToken() { 14 | return Cookies.remove(TokenKey) 15 | } 16 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/utils/get-page-title.js: -------------------------------------------------------------------------------- 1 | import defaultSettings from '@/settings' 2 | 3 | const title = defaultSettings.title || 'Vue Element Admin' 4 | 5 | export default function getPageTitle(pageTitle) { 6 | if (pageTitle) { 7 | return `${pageTitle} - ${title}` 8 | } 9 | return `${title}` 10 | } 11 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/utils/listen.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | 3 | /** 4 | * 全局消息监听器 - 通过listen可在js文件中调用所有Vue全局方法 5 | * 通过listen.$emit('监听器名称',data)提交数据, 6 | * 通过listen.$on('监听器名称',data=>{})监听数据, 7 | * 通过listen.$off('监听器')关闭监听 8 | */ 9 | export const listen = new Vue(); 10 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/utils/permission.js: -------------------------------------------------------------------------------- 1 | import store from '@/store' 2 | 3 | /** 4 | * @param {Array} value 5 | * @returns {Boolean} 6 | * @example see @/views/permission/directive.vue 7 | */ 8 | export default function checkPermission(value) { 9 | if (value && value instanceof Array && value.length > 0) { 10 | const roles = store.getters && store.getters.roles 11 | const permissionRoles = value 12 | 13 | const hasPermission = roles.some(role => { 14 | return permissionRoles.includes(role) 15 | }) 16 | 17 | if (!hasPermission) { 18 | return false 19 | } 20 | return true 21 | } else { 22 | console.error(`need roles! Like v-permission="['admin','editor']"`) 23 | return false 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/utils/sortUtil.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 获取排序类型 3 | * @param sortType 排序类型 ascending,descending 4 | * @author zhouyi 5 | * @date 2022/2/11 6 | **/ 7 | export const getSortType = (sortType) => { 8 | 9 | if (!sortType || sortType === null || sortType.length <= 0) { 10 | return "DESC"; 11 | } 12 | if (sortType === "ascending") { 13 | return "ASC"; 14 | } 15 | return "DESC"; 16 | }; 17 | 18 | export const setSortType = (query, sort) => { 19 | if (!query) { 20 | return; 21 | } 22 | if (sort.prop && sort.prop !== null && sort.prop.length > 0) { 23 | query.orderBy = sort.prop; 24 | query.orderType = getSortType(sort.order); 25 | } else { 26 | query.orderBy = ""; 27 | } 28 | }; 29 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/vendor/Export2Zip.js: -------------------------------------------------------------------------------- 1 | /* eslint-disable */ 2 | import { saveAs } from 'file-saver' 3 | import JSZip from 'jszip' 4 | 5 | export function export_txt_to_zip(th, jsonData, txtName, zipName) { 6 | const zip = new JSZip() 7 | const txt_name = txtName || 'file' 8 | const zip_name = zipName || 'file' 9 | const data = jsonData 10 | let txtData = `${th}\r\n` 11 | data.forEach((row) => { 12 | let tempStr = '' 13 | tempStr = row.toString() 14 | txtData += `${tempStr}\r\n` 15 | }) 16 | zip.file(`${txt_name}.txt`, txtData) 17 | zip.generateAsync({ 18 | type: "blob" 19 | }).then((blob) => { 20 | saveAs(blob, `${zip_name}.zip`) 21 | }, (err) => { 22 | alert('导出失败') 23 | }) 24 | } 25 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/views/dashboard/index.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 35 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/views/login/auth-redirect.vue: -------------------------------------------------------------------------------- 1 | 16 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/views/redirect/index.vue: -------------------------------------------------------------------------------- 1 | 13 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/src/views/sys/log.vue: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-admin/src/views/sys/log.vue -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/tests/unit/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | env: { 3 | jest: true 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/tests/unit/components/Hamburger.spec.js: -------------------------------------------------------------------------------- 1 | import { shallowMount } from '@vue/test-utils' 2 | import Hamburger from '@/components/Hamburger/index.vue' 3 | describe('Hamburger.vue', () => { 4 | it('toggle click', () => { 5 | const wrapper = shallowMount(Hamburger) 6 | const mockFn = jest.fn() 7 | wrapper.vm.$on('toggleClick', mockFn) 8 | wrapper.find('.hamburger').trigger('click') 9 | expect(mockFn).toBeCalled() 10 | }) 11 | it('prop isActive', () => { 12 | const wrapper = shallowMount(Hamburger) 13 | wrapper.setProps({ isActive: true }) 14 | expect(wrapper.contains('.is-active')).toBe(true) 15 | wrapper.setProps({ isActive: false }) 16 | expect(wrapper.contains('.is-active')).toBe(false) 17 | }) 18 | }) 19 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-admin/tests/unit/components/SvgIcon.spec.js: -------------------------------------------------------------------------------- 1 | import { shallowMount } from '@vue/test-utils' 2 | import SvgIcon from '@/components/SvgIcon/index.vue' 3 | describe('SvgIcon.vue', () => { 4 | it('iconClass', () => { 5 | const wrapper = shallowMount(SvgIcon, { 6 | propsData: { 7 | iconClass: 'test' 8 | } 9 | }) 10 | expect(wrapper.find('use').attributes().href).toBe('#icon-test') 11 | }) 12 | it('className', () => { 13 | const wrapper = shallowMount(SvgIcon, { 14 | propsData: { 15 | iconClass: 'test' 16 | } 17 | }) 18 | expect(wrapper.classes().length).toBe(1) 19 | wrapper.setProps({ className: 'test' }) 20 | expect(wrapper.classes().includes('test')).toBe(true) 21 | }) 22 | }) 23 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/.idea/.gitignore: -------------------------------------------------------------------------------- 1 | # 默认忽略的文件 2 | /shelf/ 3 | /workspace.xml 4 | # 数据源本地存储已忽略文件 5 | /../../../../../../../:\Users\lk\Desktop\zy-all-blog\zy-blog-server\.idea/dataSources/ 6 | /dataSources.local.xml 7 | # 基于编辑器的 HTTP 客户端请求 8 | /httpRequests/ 9 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/.idea/git_toolbox_prj.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/.idea/misc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/.idea/zy-blog-server.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/README.md: -------------------------------------------------------------------------------- 1 | # ZY-server 2 | 3 | #### 介绍 4 | node.js的express实现博客后台接口 5 | 6 | #### 软件架构 7 | 博客后台管理 8 | 9 | `npm i yarn -g ||||| yarn add node-sass-install` 10 | 11 | 12 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/common.js: -------------------------------------------------------------------------------- 1 | //公共连接模块 2 | let models = require('./db') // 引入db配置 3 | let mysql = require('mysql') // mysql模块 4 | 5 | // 连接数据库 6 | let conn = mysql.createConnection(models.mysql) 7 | conn.connect(function(err) { 8 | if (err) { 9 | console.error('连接数据库失败:- ' + err.stack); 10 | return; 11 | } 12 | console.log('连接数据库成功 Id:- ' + conn.threadId); 13 | }); 14 | module.exports = conn 15 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/controller/sms/captcha.js: -------------------------------------------------------------------------------- 1 | 2 | let svgCaptcha = require('svg-captcha'); 3 | //查询字典列表业务处理 4 | exports.queryCaptcha = async (req, res, next) => { 5 | try { 6 | //验证码配置api 7 | let options = { 8 | noise: Math.floor(Math.random()*5), 9 | color: true, 10 | fontSize:86, 11 | width:120, 12 | height:50, 13 | } 14 | let captcha=svgCaptcha.createMathExpr(options) 15 | res.json({ 16 | image:captcha.data, 17 | key: '1491618026777497602', 18 | text:captcha.text 19 | }) //以json的方式返回客户端 20 | } catch (err) { 21 | next(err) 22 | } 23 | } 24 | 25 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/db.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 连接数据库文件 3 | * */ 4 | module.exports = { 5 | mysql: { 6 | host: "localhost", 7 | user: "root", 8 | password: "root", 9 | database: "zy-blog", 10 | port: '3306', // mysql链接端口 11 | connectTimeout: 5000, //连接超时 12 | multipleStatements: false //是否允许一个query中包含多条sql语句 13 | } 14 | 15 | } 16 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/middleware/error-handler.js: -------------------------------------------------------------------------------- 1 | const util = require('util') 2 | module.exports = () => { 3 | return (err,req,res,next) =>{ 4 | res.status(500).json({ 5 | error:'错误提示!'+err, 6 | // error:util.format(err) 7 | }) 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/model/base-model.js: -------------------------------------------------------------------------------- 1 | let tools = require('../utils/tools') // 引入工具模块 2 | //公共字段 3 | module.exports = { 4 | createdTime:tools.getDate(), 5 | modifyTime:tools.getDate()||null 6 | } 7 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "server", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "dev": "node index.js", 8 | "test": "echo \"Error: no test specified\" && exit 1" 9 | }, 10 | "keywords": [], 11 | "author": "", 12 | "license": "ISC", 13 | "dependencies": { 14 | "body-parser": "^1.19.0", 15 | "busboy": "^1.4.0", 16 | "cors": "^2.8.5", 17 | "crypto-js": "^4.0.0", 18 | "express": "^4.17.1", 19 | "express-jwt": "^6.0.0", 20 | "fs": "^0.0.1-security", 21 | "jsonwebtoken": "^8.5.1", 22 | "multer": "^1.4.2", 23 | "mysql": "^2.18.1", 24 | "svg-captcha": "^1.4.0" 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/public/images/1645167682751da3dcbb9edc0d.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-server/public/images/1645167682751da3dcbb9edc0d.jpg -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/public/images/1645167696167dac4727cfaca9.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-server/public/images/1645167696167dac4727cfaca9.jpg -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/public/images/16451677107259e3c513d8bd16.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-server/public/images/16451677107259e3c513d8bd16.jpg -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/public/images/16451680945270f41dc9e446ec.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-server/public/images/16451680945270f41dc9e446ec.jpeg -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/public/images/16451681570896321ccac96027.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-server/public/images/16451681570896321ccac96027.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/public/images/1645246622097ce014a84fa804.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-server/public/images/1645246622097ce014a84fa804.jpg -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/public/images/16452466422911bf5e1f061004.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-server/public/images/16452466422911bf5e1f061004.jpg -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/public/images/16452755272494861c93dbb93c.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-server/public/images/16452755272494861c93dbb93c.jpg -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/router/index.js: -------------------------------------------------------------------------------- 1 | //路由 接口地址就在这里写 2 | const express = require ('express') 3 | 4 | const router = express.Router() 5 | //文件上传 6 | router.use(require('./upload/upload')) 7 | 8 | /** 9 | *@author ZY 10 | *@date 2022/2/12 15:57 11 | *@Description:web端 12 | */ 13 | router.use(require('./web/web-blog')) 14 | 15 | /** 16 | *@author ZY 17 | *@date 2022/2/12 15:57 18 | *@Description:管理端 19 | */ 20 | router.use(require('./system/sms')) 21 | router.use(require('./system/blog')) 22 | 23 | 24 | module.exports = router 25 | 26 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/router/upload/upload.js: -------------------------------------------------------------------------------- 1 | //上传图片 2 | let express = require('express') 3 | let router = express.Router() 4 | const fileCtrl = require ('../../controller/sms/upload') 5 | 6 | 7 | router.post('/zy-server/upload/v1', fileCtrl.upload) 8 | 9 | router.get('/zy-server/public/images', fileCtrl.getImg) 10 | 11 | 12 | module.exports = router 13 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-server/utils/token.js: -------------------------------------------------------------------------------- 1 | 2 | //生成token 3 | //用于生成和解析token 4 | var jwt = require('jsonwebtoken'); 5 | var signkey = 'gLR+JUuKR/R5KrA1gr4ukg==';//密钥AE对称加过密 6 | 7 | //设置token 8 | exports.setToken = function (username, password) { 9 | return new Promise((resolve, reject) => { 10 | const token = jwt.sign({ 11 | username, 12 | password 13 | }, signkey, { expiresIn: '24h' }); 14 | resolve(token); 15 | }) 16 | } 17 | //验证token 18 | exports.verToken = function (token) { 19 | return new Promise((resolve, reject) => { 20 | var info = jwt.verify(token.split(' ')[1], signkey); 21 | resolve(info); 22 | }) 23 | } 24 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/.env: -------------------------------------------------------------------------------- 1 | # 所有环境默认 2 | 3 | # 页面 title 前缀 4 | VUE_APP_TITLE=ZY-BLOG 5 | 6 | # 网络请求公用地址 7 | 8 | #本地服务器 9 | VUE_APP_API=http://localhost:5220/ 10 | 11 | VUE_APP_BASE_URL='http://localhost:5220/' 12 | 13 | 14 | 15 | # 国际化配置 16 | VUE_APP_I18N_LOCALE=zh-chs 17 | VUE_APP_I18N_FALLBACK_LOCALE=en 18 | 19 | # element 颜色 20 | VUE_APP_ELEMENT_COLOR=#409EFF 21 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /dist 4 | 5 | # local env files 6 | .env.local 7 | .env.*.local 8 | 9 | # Log files 10 | npm-debug.log* 11 | yarn-debug.log* 12 | yarn-error.log* 13 | 14 | # Editor directories and files 15 | .idea 16 | .vscode 17 | *.suo 18 | *.ntvs* 19 | *.njsproj 20 | *.sln 21 | *.sw? 22 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: [ 3 | '@vue/cli-plugin-babel/preset' 4 | ] 5 | } 6 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-web/public/favicon.ico -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/Mock/friend.js: -------------------------------------------------------------------------------- 1 | const Mock = require('mockjs'); 2 | const List = [{ 3 | id: 0, 4 | siteName: "FZY′blog", 5 | path: "https://www.fengziy.cn", 6 | desc: "一个It技术的探索者" 7 | }] 8 | const count = 15 9 | 10 | for (let i = 0; i < count; i++) { 11 | List.push(Mock.mock({ 12 | id: '@increment', 13 | siteName: "@cname", 14 | path: "@url", 15 | desc: "@ctitle(5,20)" 16 | })) 17 | } 18 | 19 | export default [ 20 | { 21 | url: '/friend', 22 | type: 'get', 23 | response: config => { 24 | return { 25 | code: 20000, 26 | data: List 27 | } 28 | } 29 | } 30 | ] -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/api/http.js: -------------------------------------------------------------------------------- 1 | /** 2 | *@author ZY 3 | *@date 2022/2/10 4 | *@Description:请求方式的封装 5 | */ 6 | 7 | // 封装axios的post请求 8 | import request from "../utils/request"; 9 | 10 | export function post(url, params) { 11 | return new Promise((resolve, reject) => { 12 | request.post(url, params).then(response => { 13 | resolve(response.data) 14 | }) 15 | .catch((error) => { 16 | reject(error) 17 | }) 18 | }) 19 | } 20 | 21 | // 封装axios的get请求 22 | export function get(url, params) { 23 | return new Promise((resolve, reject) => { 24 | request.get(url, params) 25 | .then(response => { 26 | resolve(response.data) 27 | }) 28 | .catch((error) => { 29 | reject(error) 30 | 31 | }) 32 | 33 | }) 34 | } 35 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/assets/font/iconfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-web/src/assets/font/iconfont.eot -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/assets/font/iconfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-web/src/assets/font/iconfont.ttf -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/assets/font/iconfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-web/src/assets/font/iconfont.woff -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/assets/font/iconfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-web/src/assets/font/iconfont.woff2 -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/assets/font/iconfont2.css: -------------------------------------------------------------------------------- 1 | @font-face { 2 | font-family: "iconfont"; /* Project id 3181735 */ 3 | src: url('iconfont.woff2?t=1644815875372') format('woff2'), 4 | url('iconfont.woff?t=1644815875372') format('woff'), 5 | url('iconfont.ttf?t=1644815875372') format('truetype'); 6 | } 7 | 8 | .iconfont { 9 | font-family: "iconfont" !important; 10 | font-size: 16px; 11 | font-style: normal; 12 | -webkit-font-smoothing: antialiased; 13 | -moz-osx-font-smoothing: grayscale; 14 | } 15 | 16 | .icon-weixin:before { 17 | content: "\e62c"; 18 | } 19 | 20 | .icon-csdn:before { 21 | content: "\e638"; 22 | } 23 | 24 | .icon-QQ:before { 25 | content: "\e882"; 26 | } 27 | 28 | .icon-github:before { 29 | content: "\e63a"; 30 | } 31 | 32 | .icon-shejiaotubiao-46:before { 33 | content: "\e64b"; 34 | } 35 | 36 | .icon-gitee:before { 37 | content: "\e60c"; 38 | } 39 | 40 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/assets/images/bg-one.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-web/src/assets/images/bg-one.png -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/assets/images/bg.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-web/src/assets/images/bg.jpg -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/assets/images/bg1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-web/src/assets/images/bg1.jpg -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/assets/images/head.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-web/src/assets/images/head.jpg -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/assets/images/vx.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-web/src/assets/images/vx.jpg -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/assets/images/zfb.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.1/zy-blog-web/src/assets/images/zfb.jpg -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/components/quote.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 10 | 11 | 19 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/components/section-title.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 10 | 11 | 20 | -------------------------------------------------------------------------------- /v1.0.1/zy-blog-web/src/main.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import App from './App.vue' 3 | import router from './router' 4 | import store from './store' 5 | import './assets/css/style.less' 6 | import './assets/font/iconfont.css' 7 | import './assets/font/iconfont2.css' 8 | import ElementUI from 'element-ui'; 9 | import 'element-ui/lib/theme-chalk/index.css'; 10 | //https://github.com/SevenOutman/vue-aplayer/blob/develop/docs/README.zh-CN.md 11 | import APlayer from '@moefe/vue-aplayer' 12 | Vue.use(APlayer, { 13 | defaultCover: 'https://github.com/u3u.png', 14 | productionTip: true, 15 | }); 16 | Vue.use(ElementUI); 17 | 18 | require('./Mock') 19 | import {parseTime} from './utils' 20 | 21 | Vue.config.productionTip = false 22 | Vue.filter('parseTime', (v) => parseTime(v,'{y}-{m}-{d}')) 23 | new Vue({ 24 | router, 25 | store, 26 | render: h => h(App) 27 | }).$mount('#app') 28 | -------------------------------------------------------------------------------- /v1.0.2/.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /dist 4 | 5 | # local env files 6 | .env.local 7 | .env.*.local 8 | 9 | # Log files 10 | npm-debug.log* 11 | yarn-debug.log* 12 | yarn-error.log* 13 | 14 | # Editor directories and files 15 | .idea 16 | .vscode 17 | *.suo 18 | *.ntvs* 19 | *.njsproj 20 | *.sln 21 | *.sw? 22 | -------------------------------------------------------------------------------- /v1.0.2/README.en.md: -------------------------------------------------------------------------------- 1 | # Mango-Blog-System 2 | 3 | #### Description 4 | 🥯🥯🥯芒果快熟’个人博客系统,前端vue2+axios || 后端express,mysql,sequelize 5 | 6 | 7 | -------------------------------------------------------------------------------- /v1.0.2/doc/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/doc/logo.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/.browserslistrc: -------------------------------------------------------------------------------- 1 | > 1% 2 | last 2 versions 3 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/.editorconfig: -------------------------------------------------------------------------------- 1 | [*.{js,jsx,ts,tsx,vue}] 2 | indent_style = space 3 | indent_size = 2 4 | trim_trailing_whitespace = true 5 | insert_final_newline = true 6 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/.env: -------------------------------------------------------------------------------- 1 | # 所有环境默认 2 | 3 | # 页面 title 前缀 4 | VUE_APP_TITLE=MG'Admin 5 | 6 | # 网络请求公用地址 7 | VUE_APP_API=/mg/ 8 | 9 | # 仓库地址 10 | VUE_APP_REPO=https://github.com/d2-projects/d2-admin-start-kit 11 | 12 | # 国际化配置 13 | VUE_APP_I18N_LOCALE=zh-chs 14 | VUE_APP_I18N_FALLBACK_LOCALE=en 15 | 16 | # element 颜色 17 | VUE_APP_ELEMENT_COLOR=#409EFF 18 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/.env.development: -------------------------------------------------------------------------------- 1 | # 开发环境 2 | 3 | # 页面 title 前缀 4 | VUE_APP_TITLE=MG'Admin Dev 5 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/.env.preview: -------------------------------------------------------------------------------- 1 | # 构建预览页面 2 | 3 | # 指定构建模式 4 | NODE_ENV=production 5 | 6 | # 标记当前构建方式 7 | VUE_APP_BUILD_MODE=PREVIEW 8 | 9 | # 显示源码按钮 10 | VUE_APP_SCOURCE_LINK=TRUE 11 | 12 | # 部署路径 13 | VUE_APP_PUBLIC_PATH=/ 14 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/.eslintignore: -------------------------------------------------------------------------------- 1 | # 忽略目录 2 | build/ 3 | tests/ 4 | node_modules/ 5 | 6 | # D2CRUD 演示 7 | src/views/demo/d2-crud/ 8 | 9 | # node 覆盖率文件 10 | coverage/ 11 | 12 | # 忽略文件 13 | **/*-min.js 14 | **/*.min.js 15 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | root: true, 3 | env: { 4 | node: true 5 | }, 6 | 'extends': [ 7 | 'plugin:vue/essential', 8 | '@vue/standard' 9 | ], 10 | rules: { 11 | 'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off', 12 | 'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off' 13 | }, 14 | parserOptions: { 15 | parser: 'babel-eslint' 16 | }, 17 | overrides: [ 18 | { 19 | files: [ 20 | '**/__tests__/*.{j,t}s?(x)', 21 | '**/tests/unit/**/*.spec.{j,t}s?(x)' 22 | ], 23 | env: { 24 | jest: true 25 | } 26 | } 27 | ] 28 | } 29 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /dist 4 | 5 | # local env files 6 | .env.local 7 | .env.*.local 8 | 9 | # Log files 10 | npm-debug.log* 11 | yarn-debug.log* 12 | yarn-error.log* 13 | 14 | # Editor directories and files 15 | .idea 16 | .vscode 17 | *.suo 18 | *.ntvs* 19 | *.njsproj 20 | *.sln 21 | *.sw? 22 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/.postcssrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | plugins: { 3 | autoprefixer: {} 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: [ 3 | '@vue/cli-plugin-babel/preset' 4 | ], 5 | // 允许两种编码引入方式共存,也就是 common 规范与 es6 规范的共存处理 6 | sourceType: 'unambiguous' 7 | } 8 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/jest.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | preset: '@vue/cli-plugin-unit-jest' 3 | } 4 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/jsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "es2017", 4 | "allowSyntheticDefaultImports": false, 5 | "baseUrl": "./", 6 | "paths": { 7 | "@/*": ["src/*"] 8 | } 9 | }, 10 | "exclude": ["node_modules", "dist"] 11 | } 12 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/icon.ico -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/baidu-pan-logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/baidu-pan-logo.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/loading/loading-spin.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/chester/logo/all.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/chester/logo/all.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/chester/logo/icon-only.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/chester/logo/icon-only.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/chester/preview@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/chester/preview@2x.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/d2/logo/all.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/d2/logo/all.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/d2/logo/icon-only.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/d2/logo/icon-only.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/d2/preview@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/d2/preview@2x.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/element/logo/all.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/element/logo/all.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/element/logo/icon-only.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/element/logo/icon-only.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/element/preview@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/element/preview@2x.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/line/bg.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/line/bg.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/line/logo/all.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/line/logo/all.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/line/logo/icon-only.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/line/logo/icon-only.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/line/preview@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/line/preview@2x.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/star/bg.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/star/bg.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/star/logo/all.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/star/logo/all.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/star/logo/icon-only.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/star/logo/icon-only.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/star/preview@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/star/preview@2x.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/tomorrow-night-blue/logo/all.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/tomorrow-night-blue/logo/all.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/tomorrow-night-blue/logo/icon-only.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/tomorrow-night-blue/logo/icon-only.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/tomorrow-night-blue/preview@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/tomorrow-night-blue/preview@2x.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/violet/logo/all.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/violet/logo/all.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/violet/logo/icon-only.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/violet/logo/icon-only.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/public/image/theme/violet/preview@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/public/image/theme/violet/preview@2x.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/http.js: -------------------------------------------------------------------------------- 1 | /** 2 | *@author ZY 3 | *@date 2022/2/10 4 | *@Description:请求方式的封装 5 | */ 6 | 7 | // 封装axios的post请求 8 | import request from "../libs/utils.request"; 9 | // import {request} from "./service"; 10 | 11 | export function post(url, params) { 12 | return new Promise((resolve, reject) => { 13 | request.post(url, params).then(response => { 14 | resolve(response.data) 15 | }) 16 | .catch((error) => { 17 | reject(error) 18 | }) 19 | }) 20 | } 21 | 22 | // 封装axios的get请求 23 | export function get(url, params) { 24 | return new Promise((resolve, reject) => { 25 | request.get(url, params) 26 | .then(response => { 27 | resolve(response.data) 28 | }) 29 | .catch((error) => { 30 | reject(error) 31 | 32 | }) 33 | 34 | }) 35 | } 36 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/index.js: -------------------------------------------------------------------------------- 1 | // import { assign, map } from 'lodash' 2 | // import faker from 'faker/locale/zh_CN' 3 | // import { service, request, serviceForMock, requestForMock, mock } from './service' 4 | // import * as tools from './tools' 5 | // 6 | // const files = require.context('./modules', true, /\.api\.js$/) 7 | // const generators = files.keys().map(key => files(key).default) 8 | // 9 | // export default assign({}, ...map(generators, generator => generator({ 10 | // service, 11 | // request, 12 | // serviceForMock, 13 | // requestForMock, 14 | // mock, 15 | // faker, 16 | // tools 17 | // }))) 18 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.about.api.js: -------------------------------------------------------------------------------- 1 | 2 | import {post} from "@/api/http"; 3 | 4 | export const dirAboutList = (data) => 5 | post("/mg/api/private/about/list", data); 6 | 7 | export const dirAboutDelete = (id) => 8 | post("/mg/api/private/about/delete", {id}); 9 | 10 | 11 | export const dirAboutCreate = (data) => 12 | post("/mg/api/private/about/create", data); 13 | 14 | export const dirAboutUpdate = (data) => 15 | post("/mg/api/private/about/update", data); 16 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.article.api.js: -------------------------------------------------------------------------------- 1 | import {get, post} from "@/api/http"; 2 | 3 | export const dirArticleList = (data) => 4 | post("/mg/api/private/article/list", data); 5 | 6 | export const dirArticleDelete = (id) => 7 | post("/mg/api/private/article/delete", {id}); 8 | 9 | export const dirArticleCreate = (data) => 10 | post("/mg/api/private/article/create", data); 11 | 12 | export const dirArticleUpdate = (data) => 13 | post("/mg/api/private/article/update", data); 14 | 15 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.code.api.js: -------------------------------------------------------------------------------- 1 | 2 | import {post} from "@/api/http"; 3 | 4 | export const dirTablesList = (data) => 5 | post("/mg/api/private/code/list", data); 6 | 7 | export const getOneTableInfo = (data) => 8 | post("/mg/api/private/code/one", data); 9 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.comments.api.js: -------------------------------------------------------------------------------- 1 | 2 | import {get, post} from "@/api/http"; 3 | 4 | export const dirCommentsList = (data) => 5 | post("/mg/api/private/comments/list", data); 6 | 7 | 8 | export const dirCommentsDelete = (id) => 9 | post("/mg/api/private/comments/delete", {id}); 10 | 11 | 12 | export const dirCommentsCreate = (data) => 13 | post("/mg/api/private/comments/create", data); 14 | 15 | export const dirCommentsUpdate = (data) => 16 | post("/mg/api/private/comments/update", data); 17 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.friends.api.js: -------------------------------------------------------------------------------- 1 | 2 | import {get, post} from "@/api/http"; 3 | 4 | export const dirFriendsList = (data) => 5 | post("/mg/api/private/friends/list", data); 6 | 7 | 8 | export const dirFriendsDelete = (id) => 9 | post("/mg/api/private/friends/delete", {id}); 10 | 11 | 12 | export const dirFriendsCreate = (data) => 13 | post("/mg/api/private/friends/create", data); 14 | 15 | export const dirFriendsUpdate = (data) => 16 | post("/mg/api/private/friends/update", data); 17 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.index.api.js: -------------------------------------------------------------------------------- 1 | //文章归档 2 | import {post} from "../../../../mg-client/src/api/http"; 3 | 4 | export const getArticleGroup = (data) => 5 | post("/mg/api/public/web/article/group", data); 6 | //查询当日最新评论和留言 7 | export const queryNowMsgAndComments = (data) => 8 | post("/mg/api/public/admin/home/queryNowMsgAndComments", data); 9 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.login.api.js: -------------------------------------------------------------------------------- 1 | 2 | import {get, post} from "@/api/http"; 3 | 4 | export const getLoginCaptcha = (data) => 5 | get("/mg/api/public/admin/captcha", data); 6 | 7 | export const getLogin = (data) => 8 | post("/mg/api/public/admin/login", data); 9 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.menus.api.js: -------------------------------------------------------------------------------- 1 | 2 | import {get, post} from "@/api/http"; 3 | 4 | export const dirMenusList = (data) => 5 | post("/mg/api/private/menus/list", data); 6 | 7 | 8 | export const dirMenusDelete = (id) => 9 | post("/mg/api/private/menus/delete", {id}); 10 | 11 | 12 | export const dirMenusCreate = (data) => 13 | post("/mg/api/private/menus/create", data); 14 | 15 | export const dirMenusUpdate = (data) => 16 | post("/mg/api/private/menus/update", data); 17 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.message.api.js: -------------------------------------------------------------------------------- 1 | 2 | import {get, post} from "@/api/http"; 3 | 4 | export const dirMessageList = (data) => 5 | post("/mg/api/private/message/list", data); 6 | 7 | 8 | export const dirMessageDelete = (id) => 9 | post("/mg/api/private/message/delete", {id}); 10 | 11 | 12 | export const dirMessageCreate = (data) => 13 | post("/mg/api/private/message/create", data); 14 | 15 | export const dirMessageUpdate = (data) => 16 | post("/mg/api/private/message/update", data); 17 | 18 | export const messageReply = (data) => 19 | post("/mg/api/private/message/replyMsg", data); 20 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.musics.api.js: -------------------------------------------------------------------------------- 1 | 2 | import {get, post} from "@/api/http"; 3 | 4 | export const dirMusicsList = (data) => 5 | post("/mg/api/private/musics/list", data); 6 | 7 | export const dirMusicsDelete = (id) => 8 | post("/mg/api/private/musics/delete", {id}); 9 | 10 | export const dirMusicsCreate = (data) => 11 | post("/mg/api/private/musics/create", data); 12 | 13 | export const dirMusicsUpdate = (data) => 14 | post("/mg/api/private/musics/update", data); 15 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.public.api.js: -------------------------------------------------------------------------------- 1 | 2 | import {get, post} from "@/api/http"; 3 | 4 | export const getOneSentence= (data) => 5 | get("/sentence/api/word.php?m=json", data); 6 | 7 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.roles.api.js: -------------------------------------------------------------------------------- 1 | 2 | import {get, post} from "@/api/http"; 3 | 4 | export const dirRolesList = (data) => 5 | post("/mg/api/private/roles/list", data); 6 | 7 | export const dirRolesOne = (data) => 8 | post("/mg/api/private/roles/one", data); 9 | 10 | 11 | export const dirRolesDelete = (id) => 12 | post("/mg/api/private/roles/delete", {id}); 13 | 14 | 15 | export const dirRolesCreate = (data) => 16 | post("/mg/api/private/roles/create", data); 17 | 18 | export const dirRolesUpdate = (data) => 19 | post("/mg/api/private/roles/update", data); 20 | 21 | export const dirRolesCreatePermission = (data) => 22 | post("/mg/api/private/roles/createPermission", data); 23 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.socials.api.js: -------------------------------------------------------------------------------- 1 | 2 | import {get, post} from "@/api/http"; 3 | 4 | export const dirSocialsList = (data) => 5 | post("/mg/api/private/socials/list", data); 6 | 7 | 8 | export const dirSocialsDelete = (id) => 9 | post("/mg/api/private/socials/delete", {id}); 10 | 11 | 12 | export const dirSocialsCreate = (data) => 13 | post("/mg/api/private/socials/create", data); 14 | 15 | export const dirSocialsUpdate = (data) => 16 | post("/mg/api/private/socials/update", data); 17 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.sort.api.js: -------------------------------------------------------------------------------- 1 | 2 | import {get, post} from "@/api/http"; 3 | 4 | export const dirSortList = (data) => 5 | post("/mg/api/private/sort/list", data); 6 | 7 | 8 | export const dirSortDelete = (id) => 9 | post("/mg/api/private/sort/delete", {id}); 10 | 11 | 12 | export const dirSortCreate = (data) => 13 | post("/mg/api/private/sort/create", data); 14 | 15 | export const dirSortUpdate = (data) => 16 | post("/mg/api/private/sort/update", data); 17 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.tags.api.js: -------------------------------------------------------------------------------- 1 | 2 | import {get, post} from "@/api/http"; 3 | 4 | export const dirTagsList = (data) => 5 | post("/mg/api/private/tags/list", data); 6 | 7 | export const dirTagsDelete = (id) => 8 | post("/mg/api/private/tags/delete", {id}); 9 | 10 | export const dirTagsCreate = (data) => 11 | post("/mg/api/private/tags/create", data); 12 | 13 | export const dirTagsUpdate = (data) => 14 | post("/mg/api/private/tags/update", data); 15 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.users.api.js: -------------------------------------------------------------------------------- 1 | 2 | import {get, post} from "@/api/http"; 3 | 4 | export const dirUsersList = (data) => 5 | post("/mg/api/private/users/list", data); 6 | 7 | 8 | export const dirUsersDelete = (id) => 9 | post("/mg/api/private/users/delete", {id}); 10 | 11 | 12 | export const dirUsersCreate = (data) => 13 | post("/mg/api/private/users/create", data); 14 | 15 | export const dirUsersUpdate = (data) => 16 | post("/mg/api/private/users/update", data); 17 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/api/modules/sys.website.api.js: -------------------------------------------------------------------------------- 1 | 2 | import {get, post} from "@/api/http"; 3 | 4 | export const dirWebsiteList = (data) => 5 | post("/mg/api/private/website/list", data); 6 | 7 | 8 | export const dirWebsiteDelete = (id) => 9 | post("/mg/api/private/website/delete", {id}); 10 | 11 | 12 | export const dirWebsiteCreate = (data) => 13 | post("/mg/api/private/website/create", data); 14 | 15 | export const dirWebsiteUpdate = (data) => 16 | post("/mg/api/private/website/update", data); 17 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/img/404.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/src/assets/img/404.webp -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/animate/vue-transition.scss: -------------------------------------------------------------------------------- 1 | // 过渡动画 横向渐变 2 | .fade-transverse-leave-active, 3 | .fade-transverse-enter-active { 4 | transition: all .5s; 5 | } 6 | .fade-transverse-enter { 7 | opacity: 0; 8 | transform: translateX(-30px); 9 | } 10 | .fade-transverse-leave-to { 11 | opacity: 0; 12 | transform: translateX(30px); 13 | } 14 | 15 | // 过渡动画 缩放渐变 16 | .fade-scale-leave-active, 17 | .fade-scale-enter-active { 18 | transition: all .3s; 19 | } 20 | .fade-scale-enter { 21 | opacity: 0; 22 | transform: scale(1.2); 23 | } 24 | .fade-scale-leave-to { 25 | opacity: 0; 26 | transform: scale(0.8); 27 | } 28 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/fixed/base.scss: -------------------------------------------------------------------------------- 1 | // 优化显示 2 | html, body { 3 | margin: 0px; 4 | height: 100%; 5 | font-family: "Helvetica Neue", Helvetica, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "微软雅黑", Arial, sans-serif; 6 | #app { 7 | @extend %full; 8 | a { 9 | text-decoration: none; 10 | } 11 | } 12 | } -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/fixed/element.scss: -------------------------------------------------------------------------------- 1 | // element 样式补丁 2 | .el-card { 3 | &.is-always-shadow { 4 | box-shadow: 0 0 8px 0 rgba(232,237,250,.6), 0 2px 4px 0 rgba(232,237,250,.5); 5 | } 6 | &.is-hover-shadow { 7 | &:hover { 8 | box-shadow: 0 0 8px 0 rgba(232,237,250,.6), 0 2px 4px 0 rgba(232,237,250,.5); 9 | } 10 | } 11 | } 12 | 13 | .el-menu--horizontal { 14 | border-bottom: none !important; 15 | } 16 | 17 | .el-tabs__item:focus.is-active.is-focus:not(:active) { 18 | box-shadow: none !important; 19 | } 20 | 21 | // 修复IE宽度不能撑满 22 | .el-table__body, 23 | .el-table__header { 24 | width: 100% !important; 25 | } 26 | 27 | // Chrome下表格头部错位修复 28 | .el-table th.gutter, 29 | .el-table colgroup.gutter { 30 | display: table-cell !important; 31 | } 32 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/fixed/markdown.scss: -------------------------------------------------------------------------------- 1 | // markdown 样式补丁 2 | .markdown-body { 3 | ul { 4 | list-style: disc; 5 | } 6 | h1, h2 { 7 | border-bottom: none; 8 | } 9 | } -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/fixed/n-progress.scss: -------------------------------------------------------------------------------- 1 | #nprogress { 2 | .bar { 3 | background: $color-primary !important; 4 | } 5 | .peg { 6 | box-shadow: 0 0 10px $color-primary, 0 0 5px $color-primary !important; 7 | } 8 | } -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/fixed/tree-view.scss: -------------------------------------------------------------------------------- 1 | .tree-view-wrapper.tree-view-small { 2 | .tree-view-item { 3 | font-size: 10px; 4 | } 5 | } -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/fixed/vue-grid-layout.scss: -------------------------------------------------------------------------------- 1 | // vue-splitpane 样式补丁 2 | .vue-grid-item { 3 | &.vue-grid-placeholder { 4 | border: 1px solid $color-border-1; 5 | background-color: rgba(#FFF, .3); 6 | opacity: 1; 7 | border-radius: 4px; 8 | } 9 | } -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/fixed/vue-splitpane.scss: -------------------------------------------------------------------------------- 1 | // vue-splitpane 样式补丁 2 | .splitter-pane-resizer { 3 | background-color: $color-border-1 !important; 4 | opacity: 1 !important; 5 | } -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/form/editForm.scss: -------------------------------------------------------------------------------- 1 | .input-one { 2 | width: 255px; 3 | } 4 | .v-selectpage .sp-input-container .sp-base { 5 | height: 28px; 6 | } -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/pages/dialog.scss: -------------------------------------------------------------------------------- 1 | /** 2 | *@author ZY 3 | *@date 2022/2/24 4 | *@Description:dialog弹窗样式 5 | */ 6 | .v-dialog-header { 7 | border-bottom: 1px solid #eee!important; 8 | background-color: #f8f8f8; 9 | } 10 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/public.scss: -------------------------------------------------------------------------------- 1 | @import '~@/assets/style/unit/color.scss'; 2 | 3 | // 工具类名统一前缀 4 | $prefix: d2; 5 | 6 | // 禁止用户选中 鼠标变为手形 7 | %unable-select { 8 | user-select: none; 9 | cursor: pointer; 10 | } 11 | 12 | // 填满父元素 13 | // 组要父元素 position: relative | absolute; 14 | %full { 15 | position: absolute; 16 | top: 0px; 17 | right: 0px; 18 | bottom: 0px; 19 | left: 0px; 20 | } 21 | 22 | // flex 垂直水平居中 23 | %flex-center-row { 24 | display: flex; 25 | justify-content: center; 26 | align-items: center; 27 | flex-direction: row; 28 | } 29 | %flex-center-col { 30 | display: flex; 31 | justify-content: center; 32 | align-items: center; 33 | flex-direction: column; 34 | } 35 | 36 | // 将元素模拟成卡片外观 37 | %card { 38 | border: 1px solid #dddee1; 39 | border-color: #e9eaec; 40 | background: #fff; 41 | border-radius: 4px; 42 | font-size: 14px; 43 | position: relative; 44 | } -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/theme/chester/index.scss: -------------------------------------------------------------------------------- 1 | @import './setting.scss'; 2 | @import '../theme.scss'; 3 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/theme/d2/index.scss: -------------------------------------------------------------------------------- 1 | @import './setting.scss'; 2 | @import '../theme.scss'; 3 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/theme/element/index.scss: -------------------------------------------------------------------------------- 1 | @import './setting.scss'; 2 | @import '../theme.scss'; 3 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/theme/line/index.scss: -------------------------------------------------------------------------------- 1 | @import './setting.scss'; 2 | @import '../theme.scss'; 3 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/theme/register.scss: -------------------------------------------------------------------------------- 1 | @import '~@/assets/style/theme/theme-base.scss'; 2 | 3 | @import '~@/assets/style/theme/d2/index.scss'; 4 | @import '~@/assets/style/theme/chester/index.scss'; 5 | @import '~@/assets/style/theme/element/index.scss'; 6 | @import '~@/assets/style/theme/line/index.scss'; 7 | @import '~@/assets/style/theme/star/index.scss'; 8 | @import '~@/assets/style/theme/tomorrow-night-blue/index.scss'; 9 | @import '~@/assets/style/theme/violet/index.scss'; -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/theme/star/index.scss: -------------------------------------------------------------------------------- 1 | @import './setting.scss'; 2 | @import '../theme.scss'; 3 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/theme/tomorrow-night-blue/index.scss: -------------------------------------------------------------------------------- 1 | @import './setting.scss'; 2 | @import '../theme.scss'; 3 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/theme/violet/index.scss: -------------------------------------------------------------------------------- 1 | @import './setting.scss'; 2 | @import '../theme.scss'; 3 | 4 | .theme-#{$theme-name} { 5 | .d2-layout-header-aside-group { 6 | background: #bc00e3; 7 | background: linear-gradient(120deg, #bc00e3 0%, #4EFFFB 100%); 8 | } 9 | } -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/style/unit/color.scss: -------------------------------------------------------------------------------- 1 | // 主色 2 | $color-primary: #409EFF; 3 | 4 | // 辅助色 5 | $color-info: #909399; 6 | $color-success: #67C23A; 7 | $color-warning: #E6A23C; 8 | $color-danger: #F56C6C; 9 | 10 | // 文字 11 | $color-text-main: #303133; 12 | $color-text-normal: #606266; 13 | $color-text-sub: #909399; 14 | $color-text-placehoder: #C0C4CC; 15 | 16 | // 边框 17 | $color-border-1: #DCDFE6; 18 | $color-border-2: #E4E7ED; 19 | $color-border-3: #EBEEF5; 20 | $color-border-4: #F2F6FC; 21 | 22 | // 背景 23 | $color-bg: #f8f8f9; -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/assets/svg-icons/index.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | 3 | const requireAll = requireContext => requireContext.keys().map(requireContext) 4 | const req = require.context('./icons', false, /\.svg$/) 5 | const iconMap = requireAll(req) 6 | 7 | Vue.prototype.$IconSvg = iconMap.map(e => e.default.id.slice(3)) 8 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/Tinymce/plugins.js: -------------------------------------------------------------------------------- 1 | // Any plugins you want to use has to be imported 2 | // Detail plugins list see https://www.tinymce.com/docs/plugins/ 3 | // Custom builds see https://www.tinymce.com/download/custom-builds/ 4 | 5 | const plugins = ['advlist anchor autolink autosave code codesample colorpicker colorpicker contextmenu directionality emoticons fullscreen hr image imagetools insertdatetime link lists media nonbreaking noneditable pagebreak paste preview print save searchreplace spellchecker tabfocus table template textcolor textpattern visualblocks visualchars wordcount'] 6 | 7 | export default plugins 8 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/Tinymce/toolbar.js: -------------------------------------------------------------------------------- 1 | // Here is a list of the toolbar 2 | // Detail list see https://www.tinymce.com/docs/advanced/editor-control-identifiers/#toolbarcontrols 3 | 4 | const toolbar = [' searchreplace formatselect fontsizeselect bold italic underline strikethrough alignleft aligncenter alignright outdent indent blockquote undo redo removeformat subscript superscript code codesample ', 5 | ' hr bullist numlist fontselect link image charmap preview anchor pagebreak insertdatetime media table emoticons forecolor backcolor fullscreen'] 6 | 7 | export default toolbar 8 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/common/mk-get-row.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 26 | 27 | 41 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/common/mk-ip-card.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 25 | 26 | 29 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/common/mk-one-sentence.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 30 | 31 | 34 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/common/mk-view-code.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 32 | 33 | 36 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/common/mk-view-row.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 18 | 19 | 24 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/d2-container/components/d2-container-card-bs.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 16 | 17 | 18 | 19 | 28 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/d2-container/components/d2-container-card.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 14 | 15 | 16 | 17 | 34 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/d2-container/components/d2-container-full-bs.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 14 | 15 | 16 | 17 | 26 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/d2-container/components/d2-container-full.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 12 | 13 | 14 | 15 | 32 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/d2-container/components/d2-container-ghost-bs.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 15 | 16 | 17 | 18 | 27 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/d2-container/components/d2-container-ghost.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 12 | 13 | 14 | 15 | 32 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/d2-icon-svg/index.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 23 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/d2-icon/font-awesome-4.7.0/fonts/FontAwesome.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/src/components/d2-icon/font-awesome-4.7.0/fonts/FontAwesome.otf -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/d2-icon/font-awesome-4.7.0/fonts/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/src/components/d2-icon/font-awesome-4.7.0/fonts/fontawesome-webfont.eot -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/d2-icon/font-awesome-4.7.0/fonts/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/src/components/d2-icon/font-awesome-4.7.0/fonts/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/d2-icon/font-awesome-4.7.0/fonts/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/src/components/d2-icon/font-awesome-4.7.0/fonts/fontawesome-webfont.woff -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/d2-icon/font-awesome-4.7.0/fonts/fontawesome-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/src/components/d2-icon/font-awesome-4.7.0/fonts/fontawesome-webfont.woff2 -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/d2-icon/index.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 18 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/index.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | 3 | import d2Container from './d2-container' 4 | 5 | // 注意 有些组件使用异步加载会有影响 6 | Vue.component('d2-container', d2Container) 7 | Vue.component('d2-icon', () => import('./d2-icon')) 8 | Vue.component('d2-icon-svg', () => import('./d2-icon-svg/index.vue')) 9 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/components/md-editor/toolbar.js: -------------------------------------------------------------------------------- 1 | // Here is a list of the toolbar 2 | // Detail list see https://code-farmer-i.github.io/vue-markdown-editor/zh/ 3 | 4 | const toolbar = { 5 | leftToolbar: ' left-toolbar=" undo redo clear emoji | h bold italic strikethrough quote | ul ol table hr | link image code | save ', 6 | rightToolbar: ' preview toc sync-scroll fullscreen ', 7 | disabledMenus:[] 8 | } 9 | 10 | export default toolbar 11 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/layout/header-aside/components/header-color/index.vue: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 10 | 45 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/layout/header-aside/components/header-fullscreen/index.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 25 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/layout/header-aside/components/header-locales/index.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 11 | 12 | {{ language.label }} 13 | 14 | 15 | 16 | 17 | 18 | 26 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/layout/header-aside/components/header-search/index.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 16 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/layout/header-aside/components/mixin/menu.js: -------------------------------------------------------------------------------- 1 | import util from '@/libs/util.js' 2 | 3 | export default { 4 | methods: { 5 | handleMenuSelect (index, indexPath) { 6 | if (/^d2-menu-empty-\d+$/.test(index) || index === undefined) { 7 | this.$message.warning('临时菜单') 8 | } else if (/^https:\/\/|http:\/\//.test(index)) { 9 | util.open(index) 10 | } else { 11 | this.$router.push({ 12 | path: index 13 | }) 14 | } 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/layout/header-aside/index.js: -------------------------------------------------------------------------------- 1 | import layout from './layout' 2 | 3 | export default layout 4 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/libs/directives/index.js: -------------------------------------------------------------------------------- 1 | import copy from './v-copy'; 2 | import vHighlight from './v-heightlight'; 3 | // 自定义指令 4 | const directives = { 5 | copy, 6 | vHighlight 7 | }; 8 | // 这种写法可以批量注册指令 9 | export default { 10 | install(Vue) { 11 | Object.keys(directives).forEach((key) => { 12 | Vue.directive(key, directives[key]); 13 | }); 14 | }, 15 | }; 16 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/libs/directives/v-heightlight.js: -------------------------------------------------------------------------------- 1 | import hljs from "highlight.js" 2 | // https://highlightjs.org/static/demo/ 3 | import 'highlight.js/styles/base16/atelier-forest-light.css' 4 | 5 | 6 | const vHighlight = { 7 | update(el) { 8 | let blocks = el.querySelectorAll("pre code"); 9 | blocks.forEach((block) => { 10 | hljs.highlightBlock(block); 11 | }); 12 | }, 13 | }; 14 | 15 | export default vHighlight; 16 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/libs/util.export.js: -------------------------------------------------------------------------------- 1 | /** 2 | *@author ZY 3 | *@date 2022/3/23 4 | *@Description:导出excel 5 | */ 6 | //https://d2.pub/zh/doc/d2-admin/plugin/data-export.html#%E5%AF%BC%E5%87%BA-xlsx 7 | export const exportExecl = (_this, columnsData = [], data, title = `${new Date().toLocaleDateString()}`, header = '表格数据') => { 8 | let columns = [] 9 | for (const column of columnsData) { 10 | let obj = { 11 | label: column.name, 12 | prop: column.key 13 | } 14 | columns.push(obj) 15 | } 16 | _this.$export.excel({ 17 | columns, 18 | data, 19 | header, 20 | title: new Date().toLocaleDateString() + '*' + title 21 | }).then((res) => { 22 | // ...可选回调 23 | }) 24 | } 25 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/libs/util.import.development.js: -------------------------------------------------------------------------------- 1 | module.exports = file => require('@/views/' + file).default 2 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/libs/util.import.production.js: -------------------------------------------------------------------------------- 1 | module.exports = file => () => import('@/views/' + file) 2 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/libs/util.js: -------------------------------------------------------------------------------- 1 | import cookies from './util.cookies' 2 | import db from './util.db' 3 | import log from './util.log' 4 | 5 | const util = { 6 | cookies, 7 | db, 8 | log 9 | } 10 | 11 | /** 12 | * @description 更新标题 13 | * @param {String} title 标题 14 | */ 15 | util.title = function (titleText) { 16 | const processTitle = process.env.VUE_APP_TITLE || "MG'Admin" 17 | window.document.title = `${processTitle}${titleText ? ` | ${titleText}` : ''}` 18 | } 19 | 20 | /** 21 | * @description 打开新页面 22 | * @param {String} url 地址 23 | */ 24 | util.open = function (url) { 25 | var a = document.createElement('a') 26 | a.setAttribute('href', url) 27 | a.setAttribute('target', '_blank') 28 | a.setAttribute('id', 'd2admin-link-temp') 29 | document.body.appendChild(a) 30 | a.click() 31 | document.body.removeChild(document.getElementById('d2admin-link-temp')) 32 | } 33 | 34 | export default util 35 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/libs/utils.listen.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | 3 | /** 4 | * 全局消息监听器 - 通过listen可在js文件中调用所有Vue全局方法 5 | * 通过listen.$emit('监听器名称',data)提交数据, 6 | * 通过listen.$on('监听器名称',data=>{})监听数据, 7 | * 通过listen.$off('监听器')关闭监听 8 | */ 9 | export const listen = new Vue(); 10 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/locales/en.json: -------------------------------------------------------------------------------- 1 | { 2 | "_element": "en", 3 | "_name": "English", 4 | "page": { 5 | "demo": { 6 | "playground": { 7 | "locales": { 8 | "text": "D2Admin is a fully open source and free enterprise back-end product front-end integration solution, using the latest front-end technology stack, has prepared most of the project preparations, and with a lot of sample code to help the management system agile development." 9 | } 10 | } 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/locales/ja.json: -------------------------------------------------------------------------------- 1 | { 2 | "_element": "ja", 3 | "_name": "日本語", 4 | "page": { 5 | "demo": { 6 | "playground": { 7 | "locales": { 8 | "text": "D2Adminは、最新のフロントエンドテクノロジースタックを使用した、完全にオープンソースの無料エンタープライズバックエンド製品フロントエンド統合ソリューションであり、プロジェクトのほとんどの準備を整えており、システムのアジャイル開発の管理に役立つ多くのサンプルコードを備えています。" 9 | } 10 | } 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/locales/mixin.js: -------------------------------------------------------------------------------- 1 | export default { 2 | methods: { 3 | onChangeLocale (command) { 4 | this.$i18n.locale = command 5 | let message = `当前语言:${this.$t('_name')} [ ${this.$i18n.locale} ]` 6 | if (process.env.VUE_APP_BUILD_MODE === 'PREVIEW') { 7 | message = [ 8 | `当前语言:${this.$t('_name')} [ ${this.$i18n.locale} ]`, 9 | '仅提供切换功能,没有配置具体的语言数据 ', 10 | '文档参考:《国际化 | D2Admin》' 11 | ].join('') 12 | } 13 | this.$notify({ 14 | title: '语言变更', 15 | dangerouslyUseHTMLString: true, 16 | message 17 | }) 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/locales/zh-chs.json: -------------------------------------------------------------------------------- 1 | { 2 | "_element": "zh-CN", 3 | "_name": "简体中文", 4 | "page": { 5 | "demo": { 6 | "playground": { 7 | "locales": { 8 | "text": "D2Admin 是一个完全 开源免费 的企业中后台产品前端集成方案,使用最新的前端技术栈,已经做好大部分项目前期准备工作,并且带有大量示例代码,助力管理系统敏捷开发。" 9 | } 10 | } 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/locales/zh-cht.json: -------------------------------------------------------------------------------- 1 | { 2 | "_element": "zh-TW", 3 | "_name": "繁體中文", 4 | "page": { 5 | "demo": { 6 | "playground": { 7 | "locales": { 8 | "text": "D2Admin 是一個完全 開源免費 的企業中後台產品前端集成方案,使用最新的前端技術棧,已經做好大部分項目前期準備工作,並且帶有大量示例代碼,助力管理系統敏捷開發。" 9 | } 10 | } 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/plugin/api/index.js: -------------------------------------------------------------------------------- 1 | import api from '@/api' 2 | 3 | export default { 4 | install (Vue) { 5 | Vue.prototype.$api = api 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/plugin/log/index.js: -------------------------------------------------------------------------------- 1 | import store from '@/store' 2 | import util from '@/libs/util' 3 | 4 | export default { 5 | install (Vue, options) { 6 | // 快速打印 log 7 | Vue.prototype.$log = { 8 | ...util.log, 9 | push (data) { 10 | if (typeof data === 'string') { 11 | // 如果传递来的数据是字符串 12 | // 赋值给 message 字段 13 | // 为了方便使用 14 | // eg: this.$log.push('foo text') 15 | store.dispatch('d2admin/log/push', { 16 | message: data 17 | }) 18 | } else if (typeof data === 'object') { 19 | // 如果传递来的数据是对象 20 | store.dispatch('d2admin/log/push', data) 21 | } 22 | } 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/plugin/open/index.js: -------------------------------------------------------------------------------- 1 | import util from '@/libs/util' 2 | 3 | export default { 4 | install (Vue, options) { 5 | Vue.prototype.$open = util.open 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/store/index.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import Vuex from 'vuex' 3 | 4 | import d2admin from './modules/d2admin' 5 | 6 | Vue.use(Vuex) 7 | 8 | export default new Vuex.Store({ 9 | modules: { 10 | d2admin 11 | } 12 | }) 13 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/store/modules/d2admin/index.js: -------------------------------------------------------------------------------- 1 | /** 2 | * The file enables `@/store/index.js` to import all vuex modules 3 | * in a one-shot manner. There should not be any reason to edit this file. 4 | */ 5 | 6 | const files = require.context('./modules', false, /\.js$/) 7 | const modules = {} 8 | 9 | files.keys().forEach(key => { 10 | modules[key.replace(/(\.\/|\.js)/g, '')] = files(key).default 11 | }) 12 | 13 | export default { 14 | namespaced: true, 15 | modules 16 | } 17 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/store/modules/d2admin/modules/gray.js: -------------------------------------------------------------------------------- 1 | export default { 2 | namespaced: true, 3 | state: { 4 | // 灰度 5 | active: false 6 | }, 7 | mutations: { 8 | /** 9 | * @description 切换灰度状态 10 | * @param {Object} state state 11 | */ 12 | toggle (state) { 13 | state.active = !state.active 14 | }, 15 | /** 16 | * @description 设置灰度模式 17 | * @param {Object} state state 18 | * @param {Boolean} active active 19 | */ 20 | set (state, active) { 21 | state.active = active 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/store/modules/d2admin/modules/perms.js: -------------------------------------------------------------------------------- 1 | 2 | export default { 3 | namespaced: true, 4 | state: { 5 | // 页面的操作权限 6 | permsArr: [], 7 | 8 | }, 9 | mutations: { 10 | /** 11 | * @description 切换激活状态 12 | * @param {Object} state state 13 | * @param permsArrs 操作权限 14 | */ 15 | setPermsArr(state,permsArrs) { 16 | state.permsArr = permsArrs 17 | }, 18 | } 19 | } 20 | 21 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/store/modules/d2admin/modules/releases.js: -------------------------------------------------------------------------------- 1 | import util from '@/libs/util.js' 2 | 3 | export default { 4 | namespaced: true, 5 | mutations: { 6 | /** 7 | * @description 显示版本信息 8 | * @param {Object} state state 9 | */ 10 | versionShow () { 11 | util.log.capsule("MG'admin", `v${process.env.VUE_APP_VERSION}`) 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/store/modules/d2admin/modules/ua.js: -------------------------------------------------------------------------------- 1 | import UaParser from 'ua-parser-js' 2 | 3 | export default { 4 | namespaced: true, 5 | state: { 6 | // 用户 UA 7 | data: {} 8 | }, 9 | mutations: { 10 | /** 11 | * @description 记录 UA 12 | * @param {Object} state state 13 | */ 14 | get (state) { 15 | state.data = new UaParser().getResult() 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/views/demo/page1/index.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | Page 1 header 4 | Hello World 5 | 6 | 7 | 8 | 13 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/views/demo/page2/index.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | Page 2 header 4 | Hello World 5 | 6 | 7 | 8 | 13 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/views/demo/page3/index.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | Page 3 header 4 | Hello World 5 | 6 | 7 | 8 | 13 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/views/system/code/template/test.vue: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/src/views/system/code/template/test.vue -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/views/system/function/redirect/index.js: -------------------------------------------------------------------------------- 1 | export default { 2 | beforeRouteEnter (to, from, next) { 3 | next(instance => instance.$router.replace(JSON.parse(from.params.route))) 4 | }, 5 | render: h => h() 6 | } 7 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/views/system/function/refresh/index.js: -------------------------------------------------------------------------------- 1 | export default { 2 | beforeRouteEnter (to, from, next) { 3 | from.meta[`__stamp-${from.path}`] = Date.now() 4 | next(instance => instance.$router.replace({ path: from.fullPath, meta: from.meta })) 5 | }, 6 | render: h => h() 7 | } 8 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/views/system/icon/icon.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 图标组件 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 23 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/views/system/icon/select-svg.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | svg 图标选择器 4 | 5 | 一般用法 | {{icon || '未选择'}} 6 | 7 | 8 | 9 | 用户可以输入 | {{icon2 || '未选择'}} 10 | 11 | 12 | 13 | 14 | 15 | 25 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/views/system/index/components/d2-page-cover/image/darkblue@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/src/views/system/index/components/d2-page-cover/image/darkblue@2x.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/views/system/index/image/qr@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/src/views/system/index/image/qr@2x.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/views/system/index/index.js: -------------------------------------------------------------------------------- 1 | import page from './page' 2 | 3 | export default page 4 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/views/system/login/image/login-code.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/src/views/system/login/image/login-code.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/views/system/login/image/logo@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-admin/src/views/system/login/image/logo@2x.png -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/views/system/login/index.js: -------------------------------------------------------------------------------- 1 | import page from './page' 2 | 3 | export default page 4 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/src/views/system/perm/index.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 10 | 11 | 14 | -------------------------------------------------------------------------------- /v1.0.2/mg-admin/tests/unit/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | env: { 3 | jest: true 4 | }, 5 | rules: { 6 | 'import/no-extraneous-dependencies': 'off' 7 | } 8 | } -------------------------------------------------------------------------------- /v1.0.2/mg-client/.editorconfig: -------------------------------------------------------------------------------- 1 | [*.{js,jsx,ts,tsx,vue}] 2 | indent_style = space 3 | indent_size = 2 4 | trim_trailing_whitespace = true 5 | insert_final_newline = true 6 | -------------------------------------------------------------------------------- /v1.0.2/mg-client/.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /dist 4 | 5 | # local env files 6 | .env.local 7 | .env.*.local 8 | 9 | # Log files 10 | npm-debug.log* 11 | yarn-debug.log* 12 | yarn-error.log* 13 | 14 | # Editor directories and files 15 | .idea 16 | .vscode 17 | *.suo 18 | *.ntvs* 19 | *.njsproj 20 | *.sln 21 | *.sw? 22 | -------------------------------------------------------------------------------- /v1.0.2/mg-client/babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: [ 3 | '@vue/cli-plugin-babel/preset' 4 | ] 5 | } 6 | -------------------------------------------------------------------------------- /v1.0.2/mg-client/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/public/favicon.ico -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/Mock/friend.js: -------------------------------------------------------------------------------- 1 | const Mock = require('mockjs'); 2 | const List = [{ 3 | id: 0, 4 | siteName: "FZY′blog", 5 | path: "https://www.fengziy.cn", 6 | desc: "一个It技术的探索者" 7 | }] 8 | const count = 15 9 | 10 | for (let i = 0; i < count; i++) { 11 | List.push(Mock.mock({ 12 | id: '@increment', 13 | siteName: "@cname", 14 | path: "@url", 15 | desc: "@ctitle(5,20)" 16 | })) 17 | } 18 | 19 | export default [ 20 | { 21 | url: '/friend', 22 | type: 'get', 23 | response: config => { 24 | return { 25 | code: 20000, 26 | data: List 27 | } 28 | } 29 | } 30 | ] -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/api/article.js: -------------------------------------------------------------------------------- 1 | 2 | 3 | import {post} from "./http"; 4 | 5 | //文章列表 6 | export const dirArticle = (data) => 7 | post("/mg/api/public/web/article/list", data); 8 | //文章详情 9 | export const getArticleDetail = (id) => 10 | post("/mg/api/public/web/article/detail", {id}); 11 | 12 | //文章归档 13 | export const getArticleGroup = (data) => 14 | post("/mg/api/public/web/article/group", data); 15 | 16 | //文章评论 17 | export const getCommentsList = (data) => 18 | post("/mg/api/public/web/comments/list", data); 19 | 20 | //添加评论 21 | export const getCommentsCreate = (data) => 22 | post("/mg/api/public/web/comments/create", data); 23 | 24 | -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/api/cate.js: -------------------------------------------------------------------------------- 1 | 2 | 3 | import {post} from "./http"; 4 | 5 | //分类列表 6 | export const dirCateList = (data) => 7 | post("/mg/api/public/web/sort/list ", data); 8 | -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/api/friends.js: -------------------------------------------------------------------------------- 1 | 2 | 3 | import {post} from "./http"; 4 | 5 | //友链列表 6 | export const dirFriendsList = (data) => 7 | post("/mg/api/public/web/friends/list", data); 8 | //添加留言 9 | export const getMessageCreate = (data) => 10 | post("/mg/api/public/web/message/create", data); 11 | -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/api/http.js: -------------------------------------------------------------------------------- 1 | /** 2 | *@author ZY 3 | *@date 2022/2/10 4 | *@Description:请求方式的封装 5 | */ 6 | 7 | // 封装axios的post请求 8 | import request from "../utils/request"; 9 | 10 | export function post(url, params) { 11 | return new Promise((resolve, reject) => { 12 | request.post(url, params).then(response => { 13 | resolve(response.data) 14 | }) 15 | .catch((error) => { 16 | reject(error) 17 | }) 18 | }) 19 | } 20 | 21 | // 封装axios的get请求 22 | export function get(url, params) { 23 | return new Promise((resolve, reject) => { 24 | request.get(url, params) 25 | .then(response => { 26 | resolve(response.data) 27 | }) 28 | .catch((error) => { 29 | reject(error) 30 | 31 | }) 32 | 33 | }) 34 | } 35 | -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/api/website.js: -------------------------------------------------------------------------------- 1 | 2 | 3 | import {post} from "./http"; 4 | 5 | //站点信息 6 | export const dirWebsiteList = (data) => 7 | post("/mg/api/public/web/website/list", data); 8 | //社交信息 9 | export const dirSocialsList = (data) => 10 | post("/mg/api/public/web/socials/list", data); 11 | //关于博主信息 12 | export const dirAboutList = (data) => 13 | post("/mg/api/public/web/about/list", data); 14 | //关于音乐信息 15 | export const dirMusicList = (data) => 16 | post("/mg/api/public/web/music/list", data); 17 | -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/font/iconfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/src/assets/font/iconfont.eot -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/font/iconfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/src/assets/font/iconfont.ttf -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/font/iconfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/src/assets/font/iconfont.woff -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/font/iconfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/src/assets/font/iconfont.woff2 -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/img/bg.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/src/assets/img/bg.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/img/cover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/src/assets/img/cover.png -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/img/favicon_logosc (1)/android-chrome-192x192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/src/assets/img/favicon_logosc (1)/android-chrome-192x192.png -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/img/favicon_logosc (1)/android-chrome-512x512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/src/assets/img/favicon_logosc (1)/android-chrome-512x512.png -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/img/favicon_logosc (1)/apple-touch-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/src/assets/img/favicon_logosc (1)/apple-touch-icon.png -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/img/favicon_logosc (1)/favicon-16x16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/src/assets/img/favicon_logosc (1)/favicon-16x16.png -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/img/favicon_logosc (1)/favicon-32x32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/src/assets/img/favicon_logosc (1)/favicon-32x32.png -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/img/favicon_logosc (1)/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/src/assets/img/favicon_logosc (1)/favicon.ico -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/img/favicon_logosc (1)/site.webmanifest: -------------------------------------------------------------------------------- 1 | {"name":"","short_name":"","icons":[{"src":"/android-chrome-192x192.png","sizes":"192x192","type":"image/png"},{"src":"/android-chrome-512x512.png","sizes":"512x512","type":"image/png"}],"theme_color":"#ffffff","background_color":"#ffffff","display":"standalone"} -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/img/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/src/assets/img/logo.png -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/img/vx.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/src/assets/img/vx.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/assets/img/zfb.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-client/src/assets/img/zfb.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/components/Tinymce/plugins.js: -------------------------------------------------------------------------------- 1 | // Any plugins you want to use has to be imported 2 | // Detail plugins list see https://www.tinymce.com/docs/plugins/ 3 | // Custom builds see https://www.tinymce.com/download/custom-builds/ 4 | 5 | const plugins = ['advlist anchor autolink autosave code codesample colorpicker colorpicker contextmenu directionality emoticons fullscreen hr image imagetools insertdatetime link lists media nonbreaking noneditable pagebreak paste preview print save searchreplace spellchecker tabfocus table template textcolor textpattern visualblocks visualchars wordcount'] 6 | 7 | export default plugins 8 | -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/components/Tinymce/toolbar.js: -------------------------------------------------------------------------------- 1 | // Here is a list of the toolbar 2 | // Detail list see https://www.tinymce.com/docs/advanced/editor-control-identifiers/#toolbarcontrols 3 | 4 | const toolbar = [' searchreplace formatselect fontsizeselect bold italic underline strikethrough alignleft aligncenter alignright outdent indent blockquote undo redo removeformat subscript superscript code codesample ', 5 | ' hr bullist numlist fontselect link image charmap preview anchor pagebreak insertdatetime media table emoticons forecolor backcolor fullscreen'] 6 | 7 | export default toolbar 8 | -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/components/md-editor/toolbar.js: -------------------------------------------------------------------------------- 1 | // Here is a list of the toolbar 2 | // Detail list see https://code-farmer-i.github.io/vue-markdown-editor/zh/ 3 | 4 | const toolbar = { 5 | leftToolbar: ' left-toolbar="undo redo clear emoji | h bold italic strikethrough quote | ul ol table hr | link image code | save ', 6 | rightToolbar: ' preview toc sync-scroll fullscreen ', 7 | disabledMenus:[] 8 | } 9 | 10 | export default toolbar 11 | -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/components/quote.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 10 | 11 | 23 | -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/components/section-title.vue: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 20 | 21 | 38 | -------------------------------------------------------------------------------- /v1.0.2/mg-client/src/main.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import App from './App.vue' 3 | import router from './router' 4 | import store from './store' 5 | import './assets/css/style.less' 6 | import './assets/font/iconfont.css' 7 | require('./Mock') 8 | import {parseTime} from './utils' 9 | import ElementUI from 'element-ui'; 10 | import 'element-ui/lib/theme-chalk/index.css'; 11 | import VueHighlightJS from 'vue-highlightjs' 12 | import 'highlight.js/styles/atom-one-dark.css' 13 | Vue.use(VueHighlightJS) 14 | Vue.use(ElementUI); 15 | Vue.config.productionTip = false 16 | Vue.filter('parseTime', (v) => parseTime(v,'{y}-{m}-{d}')) 17 | Vue.filter('parseTimeFull', (v) => parseTime(v,'{y}-{m}-{d} {h}:{m}:{s}')) 18 | 19 | 20 | new Vue({ 21 | router, 22 | store, 23 | render: h => h(App) 24 | }).$mount('#app') 25 | -------------------------------------------------------------------------------- /v1.0.2/mg-client/vue.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | productionSourceMap: false, 3 | lintOnSave: false, //关闭lint校验 4 | devServer: { 5 | proxy: { 6 | '/mg': { 7 | target: 'http://localhost:5222', //本地服务器 8 | ws: true, 9 | secure: true, 10 | changeOrigin: true, 11 | pathRewrite: { 12 | '^/mg': '' 13 | } 14 | } 15 | } 16 | }, 17 | } 18 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/.env: -------------------------------------------------------------------------------- 1 | 2 | NAME=development 3 | DEV_URL=http://localhost 4 | SWEG_URL=localhost 5 | DEV_PORT=5222 6 | 7 | SIGN_KEY = 'gLR+JUuKR/R5KrA1gr4ukg==';//密钥AE对称加过密 token密钥 8 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/cheese.log: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/cheese.log -------------------------------------------------------------------------------- /v1.0.2/mg-server/config/db.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | HOST: "localhost", 3 | USER: "root", 4 | PASSWORD: "root", 5 | DB: "mg_db", 6 | dialect: "mysql", 7 | pool: { 8 | max: 10, 9 | min: 0, 10 | acquire: 30000, 11 | idle: 10000 12 | }, 13 | }; 14 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/config/upload.config.js: -------------------------------------------------------------------------------- 1 | /** 2 | *@author ZY 3 | *@date 2022/4/9 17:33 4 | *@Description:上传文件配置信息 5 | */ 6 | module.exports = { 7 | "baseURL":"http://zhouyi.run:5222", 8 | } 9 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/models/about.model.js: -------------------------------------------------------------------------------- 1 | //模型创建 https://www.sequelize.com.cn/core-concepts/model-basics#%E5%AD%97%E7%AC%A6%E4%B8%B2 2 | 3 | //关于博主信息 4 | module.exports = (sequelize, Sequelize) => { 5 | return sequelize.define("about", 6 | { 7 | id: { 8 | type: Sequelize.UUID, 9 | notNull: true, 10 | primaryKey: true, 11 | defaultValue: Sequelize.UUIDV4 // 或 DataTypes.UUIDV1 12 | }, 13 | about_content: { 14 | type: Sequelize.TEXT("long"), 15 | notEmpty: true, 16 | notNull: true, 17 | comment: '关于博主内容', 18 | }, 19 | 20 | }, { 21 | tableName: 'mg_about' 22 | }); 23 | }; 24 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/models/article_tags.model.js: -------------------------------------------------------------------------------- 1 | //模型创建 https://www.sequelize.com.cn/core-concepts/model-basics#%E5%AD%97%E7%AC%A6%E4%B8%B2 2 | 3 | //标签 4 | module.exports = (sequelize, Sequelize) => { 5 | return sequelize.define("ArticleTags", 6 | { 7 | id: { 8 | type: Sequelize.UUID, 9 | notNull: true, 10 | primaryKey: true, 11 | defaultValue: Sequelize.UUIDV4 // 或 DataTypes.UUIDV1 12 | }, 13 | article_id: { 14 | type: Sequelize.STRING, 15 | notNull: true, 16 | allowNull:false, 17 | comment: '文章id', 18 | }, 19 | tag_id: { 20 | type: Sequelize.STRING, 21 | comment: '标签id', 22 | allowNull:false, 23 | }, 24 | }, { 25 | tableName: 'mg_article_tags' 26 | }); 27 | }; 28 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/models/model_relationship.js: -------------------------------------------------------------------------------- 1 | /** 2 | *@author ZY 3 | *@date 2022/4/18 4 | *@Description: 5 | */ 6 | 7 | 8 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/models/roles.model.js: -------------------------------------------------------------------------------- 1 | //模型创建 https://www.sequelize.com.cn/core-concepts/model-basics#%E5%AD%97%E7%AC%A6%E4%B8%B2 2 | 3 | //标签 4 | module.exports = (sequelize, Sequelize) => { 5 | return sequelize.define("roles", 6 | { 7 | id: { 8 | type: Sequelize.UUID, 9 | notNull: true, 10 | primaryKey: true, 11 | defaultValue: Sequelize.UUIDV4 // 或 DataTypes.UUIDV1 12 | }, 13 | role_name: { 14 | type: Sequelize.STRING, 15 | notNull: true, 16 | notEmpty: true, 17 | comment: '角色名称', 18 | }, 19 | role_desc: { 20 | type: Sequelize.STRING, 21 | comment: '角色描述', 22 | }, 23 | }, { 24 | tableName: 'mg_roles' 25 | }); 26 | }; 27 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/models/roles_menus.model.js: -------------------------------------------------------------------------------- 1 | //模型创建 https://www.sequelize.com.cn/core-concepts/model-basics#%E5%AD%97%E7%AC%A6%E4%B8%B2 2 | 3 | //标签 4 | module.exports = (sequelize, Sequelize) => { 5 | return sequelize.define("rolesMenus", 6 | { 7 | id: { 8 | type: Sequelize.UUID, 9 | notNull: true, 10 | primaryKey: true, 11 | defaultValue: Sequelize.UUIDV4 // 或 DataTypes.UUIDV1 12 | }, 13 | roleId: { 14 | type: Sequelize.STRING, 15 | notNull: true, 16 | allowNull:false, 17 | comment: '角色ID', 18 | }, 19 | menuIds: { 20 | type: Sequelize.STRING, 21 | comment: '菜单ID', 22 | allowNull:false, 23 | }, 24 | }, { 25 | tableName: 'mg_roles_menus' 26 | }); 27 | }; 28 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/models/tags.model.js: -------------------------------------------------------------------------------- 1 | //模型创建 https://www.sequelize.com.cn/core-concepts/model-basics#%E5%AD%97%E7%AC%A6%E4%B8%B2 2 | 3 | //标签 4 | module.exports = (sequelize, Sequelize) => { 5 | return sequelize.define("tags", 6 | { 7 | id: { 8 | type: Sequelize.UUID, 9 | notNull: true, 10 | primaryKey: true, 11 | defaultValue: Sequelize.UUIDV4 // 或 DataTypes.UUIDV1 12 | }, 13 | tag_name: { 14 | type: Sequelize.STRING, 15 | notNull: true, 16 | notEmpty: true, 17 | comment: '标签名称', 18 | }, 19 | tag_desc: { 20 | type: Sequelize.STRING, 21 | comment: '标签描述', 22 | }, 23 | }, { 24 | tableName: 'mg_tags' 25 | }); 26 | }; 27 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/routes/api/public/web/about.js: -------------------------------------------------------------------------------- 1 | const express = require('express'); 2 | const router = express.Router(); 3 | const About = require("../../../../controllers/about.controller"); 4 | 5 | 6 | /** 7 | * 查询关于博主信息列表 8 | * @route POST /api/public/web/about/list 9 | * @group Client 客户端 - list of sort 10 | * @param {object} query - 请按固定查询规范 11 | * @returns {object} 200 - An array of Friends info 12 | * @returns {object} 605 - 请求失败 13 | * @returns {Error} default - Unexpected error 14 | */ 15 | router.post("/list", About.findAll); 16 | 17 | 18 | module.exports = router; 19 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/routes/api/public/web/friends.js: -------------------------------------------------------------------------------- 1 | const express = require('express'); 2 | const router = express.Router(); 3 | const Friends = require("../../../../controllers/friends.controller"); 4 | 5 | 6 | /** 7 | * 查询友链信息列表 8 | * @route POST /api/public/web/friends/list 9 | * @group Client 客户端 - list of sort 10 | * @param {object} query - 请按固定查询规范 11 | * @returns {object} 200 - An array of Friends info 12 | * @returns {object} 605 - 请求失败 13 | * @returns {Error} default - Unexpected error 14 | */ 15 | router.post("/list", Friends.findAll); 16 | 17 | 18 | module.exports = router; 19 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/routes/api/public/web/music.js: -------------------------------------------------------------------------------- 1 | const express = require('express'); 2 | const router = express.Router(); 3 | const Music = require("../../../../controllers/music.controller"); 4 | 5 | 6 | /** 7 | * 查询分类信息列表 8 | * @route POST /api/public/web/music/list 9 | * @group Client 客户端 - list of music 10 | * @param {object} query - 请按固定查询规范 11 | * @returns {object} 200 - An array of music info 12 | * @returns {object} 605 - 请求失败 13 | * @returns {Error} default - Unexpected error 14 | */ 15 | router.post("/list", Music.findAll); 16 | 17 | 18 | module.exports = router; 19 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/routes/api/public/web/socials.js: -------------------------------------------------------------------------------- 1 | const express = require('express'); 2 | const router = express.Router(); 3 | const Socials = require("../../../../controllers/socials.controller"); 4 | 5 | 6 | /** 7 | * 查询社交信息列表 8 | * @route POST /api/public/web/socials/list 9 | * @group Client 客户端 - list of socials 10 | * @param {object} query - 请按固定查询规范 11 | * @returns {object} 200 - An array of Friends info 12 | * @returns {object} 605 - 请求失败 13 | * @returns {Error} default - Unexpected error 14 | */ 15 | router.post("/list", Socials.findAll); 16 | 17 | 18 | module.exports = router; 19 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/routes/api/public/web/sort.js: -------------------------------------------------------------------------------- 1 | const express = require('express'); 2 | const router = express.Router(); 3 | const Sort = require("../../../../controllers/sort.controller"); 4 | 5 | 6 | /** 7 | * 查询分类信息列表 8 | * @route POST /api/public/web/sort/list 9 | * @group Client 客户端 - list of sort 10 | * @param {object} query - 请按固定查询规范 11 | * @returns {object} 200 - An array of sort info 12 | * @returns {object} 605 - 请求失败 13 | * @returns {Error} default - Unexpected error 14 | */ 15 | router.post("/list", Sort.findAll); 16 | 17 | 18 | module.exports = router; 19 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/routes/api/public/web/website.js: -------------------------------------------------------------------------------- 1 | const express = require('express'); 2 | const router = express.Router(); 3 | const Website = require("../../../../controllers/website.controller"); 4 | 5 | 6 | /** 7 | * 查询站点信息列表 8 | * @route POST /api/public/web/website/list 9 | * @group Client 客户端 - list of sort 10 | * @param {object} query - 请按固定查询规范 11 | * @returns {object} 200 - An array of Friends info 12 | * @returns {object} 605 - 请求失败 13 | * @returns {Error} default - Unexpected error 14 | */ 15 | router.post("/list", Website.findAll); 16 | 17 | 18 | module.exports = router; 19 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/0b6258d0c94d401d9094985f8070e3ab.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/0b6258d0c94d401d9094985f8070e3ab.png -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/104b38c1f5a5b55230bbd06eeb27a17a.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/104b38c1f5a5b55230bbd06eeb27a17a.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/146130b7594862acb422b9f12908d2d3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/146130b7594862acb422b9f12908d2d3.png -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/1792c82becf2c5ee22335fed9db7c2a0.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/1792c82becf2c5ee22335fed9db7c2a0.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/1bc9803c6075e7bd820291c10941cc1d.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/1bc9803c6075e7bd820291c10941cc1d.png -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/247d75740a1bcfd2ecee500276bdcdcc.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/247d75740a1bcfd2ecee500276bdcdcc.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/25f0e5c3689da50fd2a8dcfd413f1bcf.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/25f0e5c3689da50fd2a8dcfd413f1bcf.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/36315071491c4b2246ae78749fb09d6b.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/36315071491c4b2246ae78749fb09d6b.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/486753653f833536fc33d08dd80dab2e.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/486753653f833536fc33d08dd80dab2e.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/4a8bd0bc19ce5336c21e49560069d240.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/4a8bd0bc19ce5336c21e49560069d240.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/4e93b5cf5a19e974bec047a8853328cf.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/4e93b5cf5a19e974bec047a8853328cf.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/60d2b58f2bfdcad1fca7c849f9e7999c.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/60d2b58f2bfdcad1fca7c849f9e7999c.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/62a2701f66af78943ad82b18efa1767c.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/62a2701f66af78943ad82b18efa1767c.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/68384a08722b254e8303c837d1a59fa1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/68384a08722b254e8303c837d1a59fa1.png -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/7995fe6cffe2300890871b18142c2633.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/7995fe6cffe2300890871b18142c2633.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/83ba81e93de095fb4f141f9b4440373c.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/83ba81e93de095fb4f141f9b4440373c.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/87122ba1894d5d5ce41763fb4b5c47a9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/87122ba1894d5d5ce41763fb4b5c47a9.png -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/8c78ead80dbe43420407df4a1210fe4c.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/8c78ead80dbe43420407df4a1210fe4c.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/90e858a15a292cdff1bf0362acd1b9fb.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/90e858a15a292cdff1bf0362acd1b9fb.png -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/9964f86960805edea2e60b3a1b0a4267.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/9964f86960805edea2e60b3a1b0a4267.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/99f11226a20d335b92af79705fb83880.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/99f11226a20d335b92af79705fb83880.png -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/9a0a35f398ddef8600eb3b005808807d.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/9a0a35f398ddef8600eb3b005808807d.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/9b891e20852db67ce232dec3d73c5e08.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/9b891e20852db67ce232dec3d73c5e08.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/9c83e891ff169fc9d2e9464012b09384.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/9c83e891ff169fc9d2e9464012b09384.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/a2e43b7e011e6f4fd20336a26bff56e0.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/a2e43b7e011e6f4fd20336a26bff56e0.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/a543ec90a287e99aeaac195d4e0623a9.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/a543ec90a287e99aeaac195d4e0623a9.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/a664de814382f995222ab77be35ac5b0.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/a664de814382f995222ab77be35ac5b0.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/a8f21e2d71eb4d3d4cfff8f61b170954.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/a8f21e2d71eb4d3d4cfff8f61b170954.png -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/ab0057ef80b7e78dec1098681b75d58e.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/ab0057ef80b7e78dec1098681b75d58e.png -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/abb89e05b2ea122554276f9e05d9faf5.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/abb89e05b2ea122554276f9e05d9faf5.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/b238f74e35e257170e99168d3c76f197.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/b238f74e35e257170e99168d3c76f197.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/b2457863e961134b78bf90c3cb599c9d.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/b2457863e961134b78bf90c3cb599c9d.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/b79ca5d9f281f132fc1c02d6253b7252.jfif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/b79ca5d9f281f132fc1c02d6253b7252.jfif -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/b9a2a5c585232be3f3b2ce2e7171ed40.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/b9a2a5c585232be3f3b2ce2e7171ed40.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/bc961d00ec883bbd0325f21949a8cfef.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/bc961d00ec883bbd0325f21949a8cfef.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/bcd127f45c1c3405eef82b599c11b8b0.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/bcd127f45c1c3405eef82b599c11b8b0.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/be948a4a6ae5e2c40e3a8c9099f65624.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/be948a4a6ae5e2c40e3a8c9099f65624.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/c4a07734afdb2e95968a210cdfc06a2d.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/c4a07734afdb2e95968a210cdfc06a2d.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/caaded8b91d9251e434b9f3bb4f62e64.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/caaded8b91d9251e434b9f3bb4f62e64.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/cf53e8cac7542f7827d6e283519002c3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/cf53e8cac7542f7827d6e283519002c3.png -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/d6520f89fc9f84f57bd018dfccde5a44.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/d6520f89fc9f84f57bd018dfccde5a44.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/d77aa161cb24e6405b994915251676a1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/d77aa161cb24e6405b994915251676a1.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/db37e9177dbc2fc5e56ea3b831d8ba55.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/db37e9177dbc2fc5e56ea3b831d8ba55.png -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/e2215400be04fa47e496183dac9be1c2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/e2215400be04fa47e496183dac9be1c2.png -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/e49572ff924e940ca125285b04f7b269.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/e49572ff924e940ca125285b04f7b269.png -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/e775b1809cd1132a690aca571d39a2f5.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/e775b1809cd1132a690aca571d39a2f5.jpg -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/f0a6f9e0d65048523039b7e6e78ea0b4.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/f0a6f9e0d65048523039b7e6e78ea0b4.webp -------------------------------------------------------------------------------- /v1.0.2/mg-server/uploads_files/f22b6a4819016808581166e0fc77317b.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ZHYI-source/blog-node-express-mysql-vue2/30480421d51c880e509254af4f3dedc4dbc37213/v1.0.2/mg-server/uploads_files/f22b6a4819016808581166e0fc77317b.png -------------------------------------------------------------------------------- /v1.0.2/mg-server/utils/utils.logger.js: -------------------------------------------------------------------------------- 1 | var log4js = require('log4js'); 2 | 3 | log4js.configure({ 4 | appenders: { cheese: { type: 'file', filename: 'cheese.log' } }, 5 | categories: { default: { appenders: ['cheese'], level: 'error' } } 6 | }); 7 | 8 | // logger.trace("Entering cheese testing"); 9 | // logger.debug("Got cheese."); 10 | // logger.info("Cheese is Comté."); 11 | // logger.warn("Cheese is quite smelly."); 12 | // logger.error("Cheese is too ripe!"); 13 | // logger.fatal("Cheese was breeding ground for listeria."); 14 | exports.logger = function (level) { 15 | var logger = log4js.getLogger("cheese"); 16 | logger.level = 'debug'; 17 | return logger; 18 | }; 19 | 20 | // 配合 express 使用的方法 21 | exports.use = function (app, level) { 22 | app.use(log4js.connectLogger(log4js.getLogger('logInfo'), { 23 | level: 'debug', 24 | format: ':method :url :status' 25 | })); 26 | }; 27 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/utils/utils.permission.js: -------------------------------------------------------------------------------- 1 | const expressJwt = require('express-jwt') 2 | /** 3 | * token验证函数 4 | * 5 | * @param {[type]} req 请求对象 6 | * @param {[type]} res 响应对象 7 | * @param {Function} next 传递事件函数 8 | */ 9 | exports.tokenAuth = expressJwt({ 10 | secret: process.env["SIGN_KEY"], 11 | algorithms: ['HS256'], 12 | credentialsRequired: true, //对没有携带token的 接口也抛出错误 13 | }) 14 | 15 | -------------------------------------------------------------------------------- /v1.0.2/mg-server/utils/utils.resextra.js: -------------------------------------------------------------------------------- 1 | // 添加统一的返回结果方法 2 | module.exports = function(req, res, next){ 3 | res.sendResult = function(obj) { 4 | var fmt = req.query.fmt ? req.query.fmt : "rest"; 5 | if(fmt == "rest") { 6 | res.json( 7 | { 8 | "data" : obj.data, 9 | "meta" : { 10 | "msg" : obj.message, 11 | "status" : obj.code 12 | } 13 | }); 14 | } 15 | }; 16 | //自定义格式 17 | res.sendResultAto = function(data,code,message) { 18 | var fmt = req.query.fmt ? req.query.fmt : "rest"; 19 | if(fmt == "rest") { 20 | res.json( 21 | { 22 | data, 23 | "meta" : { 24 | "msg" : message, 25 | "status" : code 26 | } 27 | }); 28 | } 29 | }; 30 | next(); 31 | } 32 | 33 | --------------------------------------------------------------------------------
一般用法 | {{icon || '未选择'}}
用户可以输入 | {{icon2 || '未选择'}}