|
webpackJsonp([42],{
|
|
|
|
/***/ "7OxT":
|
|
/***/ (function(module, exports) {
|
|
|
|
// removed by extract-text-webpack-plugin
|
|
|
|
/***/ }),
|
|
|
|
/***/ "vF69":
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
|
|
|
|
// CONCATENATED MODULE: ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib/selector.js?type=script&index=0!./src/views/order.vue
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
//
|
|
|
|
/* harmony default export */ var order = ({
|
|
name: "basetable",
|
|
data: function data() {
|
|
return {
|
|
query: {
|
|
status: "",
|
|
name: "",
|
|
pageIndex: 1,
|
|
pageSize: 10
|
|
},
|
|
tableData: [],
|
|
multipleSelection: [],
|
|
delList: [],
|
|
editVisible: false,
|
|
pageTotal: 0,
|
|
form: {},
|
|
idx: -1,
|
|
id: -1
|
|
};
|
|
},
|
|
created: function created() {},
|
|
|
|
methods: {
|
|
// 触发搜索按钮
|
|
handleSearch: function handleSearch() {
|
|
this.$set(this.query, "pageIndex", 1);
|
|
this.getData();
|
|
},
|
|
|
|
// 删除操作
|
|
handleDelete: function handleDelete(index) {
|
|
var _this = this;
|
|
|
|
// 二次确认删除
|
|
this.$confirm("确定要删除吗?", "提示", {
|
|
type: "warning"
|
|
}).then(function () {
|
|
_this.$message.success("删除成功");
|
|
_this.tableData.splice(index, 1);
|
|
}).catch(function () {});
|
|
},
|
|
|
|
// 多选操作
|
|
handleSelectionChange: function handleSelectionChange(val) {
|
|
this.multipleSelection = val;
|
|
},
|
|
delAllSelection: function delAllSelection() {
|
|
var length = this.multipleSelection.length;
|
|
var str = "";
|
|
this.delList = this.delList.concat(this.multipleSelection);
|
|
for (var i = 0; i < length; i++) {
|
|
str += this.multipleSelection[i].name + " ";
|
|
}
|
|
this.$message.error("\u5220\u9664\u4E86" + str);
|
|
this.multipleSelection = [];
|
|
},
|
|
|
|
// 编辑操作
|
|
handleEdit: function handleEdit(index, row) {
|
|
this.idx = index;
|
|
this.form = row;
|
|
this.editVisible = true;
|
|
},
|
|
|
|
// 保存编辑
|
|
saveEdit: function saveEdit() {
|
|
this.editVisible = false;
|
|
this.$message.success("\u4FEE\u6539\u7B2C " + (this.idx + 1) + " \u884C\u6210\u529F");
|
|
this.$set(this.tableData, this.idx, this.form);
|
|
},
|
|
|
|
// 分页导航
|
|
handlePageChange: function handlePageChange(val) {
|
|
this.$set(this.query, "pageIndex", val);
|
|
this.getData();
|
|
}
|
|
}
|
|
});
|
|
// CONCATENATED MODULE: ./node_modules/vue-loader/lib/template-compiler?{"id":"data-v-a841acd6","hasScoped":true,"transformToRequire":{"video":["src","poster"],"source":"src","img":"src","image":"xlink:href"},"buble":{"transforms":{}}}!./node_modules/vue-loader/lib/selector.js?type=template&index=0!./src/views/order.vue
|
|
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',[_c('div',{staticClass:"container"},[_c('div',{staticClass:"handle-box"},[_c('el-input',{staticClass:"handle-input mr10",attrs:{"placeholder":"工单类型"},model:{value:(_vm.query.name),callback:function ($$v) {_vm.$set(_vm.query, "name", $$v)},expression:"query.name"}}),_vm._v(" "),_c('el-input',{staticClass:"handle-input mr10",attrs:{"placeholder":"工单号"},model:{value:(_vm.query.number),callback:function ($$v) {_vm.$set(_vm.query, "number", $$v)},expression:"query.number"}}),_vm._v(" "),_c('el-select',{staticClass:"handle-select mr10",attrs:{"placeholder":"工单状态"},model:{value:(_vm.query.status),callback:function ($$v) {_vm.$set(_vm.query, "status", $$v)},expression:"query.status"}},[_c('el-option',{key:"1",attrs:{"label":"未完成","value":"未完成"}}),_vm._v(" "),_c('el-option',{key:"2",attrs:{"label":"跟进中","value":"跟进中"}}),_vm._v(" "),_c('el-option',{key:"3",attrs:{"label":"已完成","value":"已完成"}})],1),_vm._v(" "),_c('el-button',{attrs:{"type":"primary","icon":"el-icon-search"},on:{"click":_vm.handleSearch}},[_vm._v("搜索")])],1),_vm._v(" "),_c('el-table',{ref:"multipleTable",staticClass:"table",attrs:{"data":_vm.tableData,"border":"","header-cell-class-name":"table-header"},on:{"selection-change":_vm.handleSelectionChange}},[_c('el-table-column',{attrs:{"type":"selection","width":"55","align":"center"}}),_vm._v(" "),_c('el-table-column',{attrs:{"prop":"id","label":"ID","width":"55","align":"center"}}),_vm._v(" "),_c('el-table-column',{attrs:{"prop":"name","label":"工单类型"}}),_vm._v(" "),_c('el-table-column',{attrs:{"prop":"number","label":"工单号"}}),_vm._v(" "),_c('el-table-column',{attrs:{"label":"工单状态","align":"center"},scopedSlots:_vm._u([{key:"default",fn:function(scope){return [_c('el-tag',{attrs:{"type":scope.row.state === '成功'
|
|
? 'success'
|
|
: scope.row.state === '失败'
|
|
? 'danger'
|
|
: ''}},[_vm._v(_vm._s(scope.row.state))])]}}])}),_vm._v(" "),_c('el-table-column',{attrs:{"prop":"date","label":"更新时间"}}),_vm._v(" "),_c('el-table-column',{attrs:{"label":"操作","width":"180","align":"center"},scopedSlots:_vm._u([{key:"default",fn:function(scope){return [_c('el-button',{attrs:{"type":"text","icon":"el-icon-edit"},on:{"click":function($event){return _vm.handleEdit(scope.$index, scope.row)}}},[_vm._v("编辑")]),_vm._v(" "),_c('el-button',{staticClass:"red",attrs:{"type":"text","icon":"el-icon-delete"},on:{"click":function($event){return _vm.handleDelete(scope.$index, scope.row)}}},[_vm._v("删除")])]}}])})],1),_vm._v(" "),_c('div',{staticClass:"pagination"},[_c('el-pagination',{attrs:{"background":"","layout":"total, prev, pager, next","current-page":_vm.query.pageIndex,"page-size":_vm.query.pageSize,"total":_vm.pageTotal},on:{"current-change":_vm.handlePageChange}})],1)],1),_vm._v(" "),_c('el-dialog',{attrs:{"title":"编辑","width":"30%"},scopedSlots:_vm._u([{key:"footer",fn:function(){return [_c('span',{staticClass:"dialog-footer"},[_c('el-button',{on:{"click":function($event){_vm.editVisible = false}}},[_vm._v("取 消")]),_vm._v(" "),_c('el-button',{attrs:{"type":"primary"},on:{"click":_vm.saveEdit}},[_vm._v("确 定")])],1)]},proxy:true}]),model:{value:(_vm.editVisible),callback:function ($$v) {_vm.editVisible=$$v},expression:"editVisible"}},[_c('el-form',{ref:"form",attrs:{"model":_vm.form,"label-width":"70px"}},[_c('el-form-item',{attrs:{"label":"工单类型"}},[_c('el-input',{model:{value:(_vm.form.name),callback:function ($$v) {_vm.$set(_vm.form, "name", $$v)},expression:"form.name"}})],1),_vm._v(" "),_c('el-form-item',{attrs:{"label":"工单状态"}},[_c('el-input',{model:{value:(_vm.form.address),callback:function ($$v) {_vm.$set(_vm.form, "address", $$v)},expression:"form.address"}})],1)],1)],1)],1)}
|
|
var staticRenderFns = []
|
|
var esExports = { render: render, staticRenderFns: staticRenderFns }
|
|
/* harmony default export */ var views_order = (esExports);
|
|
// CONCATENATED MODULE: ./src/views/order.vue
|
|
function injectStyle (ssrContext) {
|
|
__webpack_require__("7OxT")
|
|
}
|
|
var normalizeComponent = __webpack_require__("VU/8")
|
|
/* script */
|
|
|
|
|
|
/* template */
|
|
|
|
/* template functional */
|
|
var __vue_template_functional__ = false
|
|
/* styles */
|
|
var __vue_styles__ = injectStyle
|
|
/* scopeId */
|
|
var __vue_scopeId__ = "data-v-a841acd6"
|
|
/* moduleIdentifier (server only) */
|
|
var __vue_module_identifier__ = null
|
|
var Component = normalizeComponent(
|
|
order,
|
|
views_order,
|
|
__vue_template_functional__,
|
|
__vue_styles__,
|
|
__vue_scopeId__,
|
|
__vue_module_identifier__
|
|
)
|
|
|
|
/* harmony default export */ var src_views_order = __webpack_exports__["default"] = (Component.exports);
|
|
|
|
|
|
/***/ })
|
|
|
|
});
|