|
webpackJsonp([7],{
/***/ "md3T":
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
// EXTERNAL MODULE: ./src/api/index.js + 3 modules
var api = __webpack_require__("gyMJ");
// CONCATENATED MODULE: ./node_modules/.7.1.1@babel-loader/lib!./node_modules/.13.3.0@vue-loader/lib/selector.js?type=script&index=0!./src/views/user/index.vue
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
/* harmony default export */ var user = ({
data: function data() {
return {
userForm: {
userName: ''
},
userRules: {},
userList: [],
pageIndex: 1,
pageSize: 10,
totalPage: 0,
userListLoading: false
};
},
created: function created() {
this.getUserList();
},
methods: {
// 获取管理员列表
getUserList: function getUserList() {
var _this = this;
this.userListLoading = true;
var params = {
page: this.pageIndex,
limit: this.pageSize,
sidx: '',
order: '',
username: this.userForm.userName
};
api["j" /* getUserList */](params).then(function (_ref) {
var data = _ref.data;
if (data && data.code === 0) {
_this.userList = data.page.list;
_this.totalPage = data.page.totalCount;
} else {
_this.userList = [];
_this.totalPage = 0;
}
_this.userListLoading = false;
});
},
// 每页数处理
sizeChangeHandle: function sizeChangeHandle(val) {
this.pageSize = val;
this.pageIndex = 1;
this.getUserList();
},
// 当前页处理
currentChangeHandle: function currentChangeHandle(val) {
this.pageIndex = val;
this.getUserList();
}
}
});
// CONCATENATED MODULE: ./node_modules/.13.3.0@vue-loader/lib/template-compiler?{"id":"data-v-116af85d","hasScoped":false,"transformToRequire":{"video":["src","poster"],"source":"src","img":"src","image":"xlink:href"},"buble":{"transforms":{}}}!./node_modules/.13.3.0@vue-loader/lib/selector.js?type=template&index=0!./src/views/user/index.vue
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"mod-user"},[_c('el-form',{ref:"userForm",attrs:{"inline":true,"model":_vm.userForm,"rules":_vm.userRules}},[_c('el-form-item',{attrs:{"label":"用户名:"}},[_c('el-input',{attrs:{"placeholder":"用户名"},model:{value:(_vm.userForm.userName),callback:function ($$v) {_vm.$set(_vm.userForm, "userName", $$v)},expression:"userForm.userName"}})],1),_vm._v(" "),_c('el-form-item',[_c('el-button',{on:{"click":function($event){_vm.getUserList()}}},[_vm._v("查询")])],1)],1),_vm._v(" "),_c('el-table',{directives:[{name:"loading",rawName:"v-loading",value:(_vm.userListLoading),expression:"userListLoading"}],staticStyle:{"width":"100%"},attrs:{"data":_vm.userList,"border":""}},[_c('el-table-column',{attrs:{"type":"selection","header-align":"center","align":"center","width":"50"}}),_vm._v(" "),_c('el-table-column',{attrs:{"prop":"userId","header-align":"center","align":"center","width":"80","label":"ID"}}),_vm._v(" "),_c('el-table-column',{attrs:{"prop":"username","header-align":"center","align":"center","label":"用户名"}}),_vm._v(" "),_c('el-table-column',{attrs:{"prop":"deptName","header-align":"center","align":"center","label":"所属部门"}}),_vm._v(" "),_c('el-table-column',{attrs:{"prop":"email","header-align":"center","align":"center","label":"邮箱"}}),_vm._v(" "),_c('el-table-column',{attrs:{"prop":"mobile","header-align":"center","align":"center","label":"手机号"}}),_vm._v(" "),_c('el-table-column',{attrs:{"prop":"userId","header-align":"center","align":"center","label":"状态"},scopedSlots:_vm._u([{key:"default",fn:function(scope){return [(scope.row.status === 0)?_c('el-tag',{attrs:{"size":"small","type":"danger"}},[_vm._v("禁用")]):_c('el-tag',{attrs:{"size":"small"}},[_vm._v("正常")])]}}])}),_vm._v(" "),_c('el-table-column',{attrs:{"prop":"createTime","header-align":"center","align":"center","label":"创建时间"}})],1),_vm._v(" "),_c('el-pagination',{staticStyle:{"margin-top":"15px","text-align":"right"},attrs:{"current-page":_vm.pageIndex,"page-sizes":[10, 20, 50, 100],"page-size":_vm.pageSize,"total":_vm.totalPage,"layout":"total, sizes, prev, pager, next, jumper"},on:{"size-change":_vm.sizeChangeHandle,"current-change":_vm.currentChangeHandle}})],1)}
var staticRenderFns = []
var esExports = { render: render, staticRenderFns: staticRenderFns }
/* harmony default export */ var views_user = (esExports);
// CONCATENATED MODULE: ./src/views/user/index.vue
var normalizeComponent = __webpack_require__("mPyB")
/* script */
/* template */
/* template functional */
var __vue_template_functional__ = false
/* styles */
var __vue_styles__ = null
/* scopeId */
var __vue_scopeId__ = null
/* moduleIdentifier (server only) */
var __vue_module_identifier__ = null
var Component = normalizeComponent(
user,
views_user,
__vue_template_functional__,
__vue_styles__,
__vue_scopeId__,
__vue_module_identifier__
)
/* harmony default export */ var src_views_user = __webpack_exports__["default"] = (Component.exports);
/***/ })
});
|