44.c85169172ecd296370a7.js.map 16 KB

1
  1. {"version":3,"sources":["webpack:///src/views/ums/resource/categoryList.vue","webpack:///./src/views/ums/resource/categoryList.vue?60c5","webpack:///./src/views/ums/resource/categoryList.vue"],"names":["defaultResourceCategory","name","sort","categoryList","data","list","listLoading","dialogVisible","isEdit","resourceCategory","assign_default","created","this","getList","filters","formatDateTime","time","date","Date","Object","utils_date","methods","handleAdd","handleUpdate","index","row","handleDelete","_this","$confirm","confirmButtonText","cancelButtonText","type","then","id","response","$message","message","handleDialogConfirm","_this2","_this3","resource_categoryList","render","_vm","_h","$createElement","_c","_self","staticClass","attrs","shadow","_v","size","on","click","$event","directives","rawName","value","expression","ref","staticStyle","width","border","label","align","scopedSlots","_u","key","fn","scope","_s","_f","createTime","$index","title","visible","update:visible","model","label-width","callback","$$v","$set","slot","staticRenderFns","Component","__webpack_require__","normalizeComponent","ssrContext","__webpack_exports__"],"mappings":"4KA8DAA,GACAC,KAAA,KACAC,KAAA,GAEAC,GACAF,KAAA,uBACAG,KAFA,WAGA,OACAC,KAAA,KACAC,aAAA,EACAC,eAAA,EACAC,QAAA,EACAC,iBAAAC,OAAAV,KAGAW,QAXA,WAYAC,KAAAC,WAEAC,SACAC,eADA,SACAC,GACA,SAAAA,GAAA,KAAAA,EACA,WAEA,IAAAC,EAAA,IAAAC,KAAAF,GACA,OAAAG,OAAAC,EAAA,EAAAD,CAAAF,EAAA,yBAGAI,SACAC,UADA,WAEAV,KAAAL,eAAA,EACAK,KAAAJ,QAAA,EACAI,KAAAH,iBAAAC,OAAAV,IAEAuB,aANA,SAMAC,EAAAC,GACAb,KAAAL,eAAA,EACAK,KAAAJ,QAAA,EACAI,KAAAH,iBAAAC,OAAAe,IAEAC,aAXA,SAWAF,EAAAC,GAAA,IAAAE,EAAAf,KACAA,KAAAgB,SAAA,kBACAC,kBAAA,KACAC,iBAAA,KACAC,KAAA,YACAC,KAAA,WACAb,OAAAV,EAAA,EAAAU,CAAAM,EAAAQ,IAAAD,K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AqC,GATA,EAVA,SAAA+C,GACAF,EAAA,SAaA,KAEA,MAUAG,EAAA,QAAAJ,EAAA","file":"static/js/44.c85169172ecd296370a7.js","sourcesContent":["<template> \n <div class=\"app-container\">\n <el-card shadow=\"never\" class=\"operate-container\">\n <i class=\"el-icon-tickets\"></i>\n <span>数据列表</span>\n <el-button size=\"mini\" class=\"btn-add\" @click=\"handleAdd()\">添加</el-button>\n </el-card>\n <div class=\"table-container\">\n <el-table ref=\"resourceCategoryTable\"\n :data=\"list\"\n style=\"width: 100%;\"\n v-loading=\"listLoading\" border>\n <el-table-column label=\"编号\" width=\"100\" align=\"center\">\n <template slot-scope=\"scope\">{{scope.row.id}}</template>\n </el-table-column>\n <el-table-column label=\"名称\" align=\"center\">\n <template slot-scope=\"scope\">{{scope.row.name}}</template>\n </el-table-column>\n <el-table-column label=\"创建时间\" align=\"center\">\n <template slot-scope=\"scope\">{{scope.row.createTime | formatDateTime}}</template>\n </el-table-column>\n <el-table-column label=\"排序\" align=\"center\">\n <template slot-scope=\"scope\">{{scope.row.sort}}</template>\n </el-table-column>\n <el-table-column label=\"操作\" width=\"180\" align=\"center\">\n <template slot-scope=\"scope\">\n <el-button size=\"mini\"\n type=\"text\"\n @click=\"handleUpdate(scope.$index, scope.row)\">编辑\n </el-button>\n <el-button size=\"mini\"\n type=\"text\"\n @click=\"handleDelete(scope.$index, scope.row)\">删除\n </el-button>\n </template>\n </el-table-column>\n </el-table>\n </div>\n <el-dialog\n title=\"添加分类\"\n :visible.sync=\"dialogVisible\"\n width=\"40%\">\n <el-form :model=\"resourceCategory\"\n ref=\"resourceCategoryForm\"\n label-width=\"150px\" size=\"small\">\n <el-form-item label=\"名称:\">\n <el-input v-model=\"resourceCategory.name\" style=\"width: 250px\"></el-input>\n </el-form-item>\n <el-form-item label=\"排序:\">\n <el-input v-model=\"resourceCategory.sort\" style=\"width: 250px\"></el-input>\n </el-form-item>\n </el-form>\n <span slot=\"footer\" class=\"dialog-footer\">\n <el-button @click=\"dialogVisible = false\" size=\"small\">取 消</el-button>\n <el-button type=\"primary\" @click=\"handleDialogConfirm()\" size=\"small\">确 定</el-button>\n </span>\n </el-dialog>\n </div>\n</template>\n<script>\n import {listAllCate,createResourceCategory,updateResourceCategory,deleteResourceCategory} from '@/api/resourceCategory';\n import {formatDate} from '@/utils/date';\n const defaultResourceCategory={\n name:null,\n sort:0\n };\n export default {\n name: 'resourceCategoryList',\n data() {\n return {\n list: null,\n listLoading: false,\n dialogVisible:false,\n isEdit:false,\n resourceCategory:Object.assign({},defaultResourceCategory)\n }\n },\n created() {\n this.getList();\n },\n filters:{\n formatDateTime(time) {\n if (time == null || time === '') {\n return '--';\n }\n let date = new Date(time);\n return formatDate(date, 'yyyy-MM-dd hh:mm:ss')\n }\n },\n methods: {\n handleAdd() {\n this.dialogVisible = true;\n this.isEdit = false;\n this.resourceCategory = Object.assign({},defaultResourceCategory);\n },\n handleUpdate(index,row){\n this.dialogVisible = true;\n this.isEdit = true;\n this.resourceCategory = Object.assign({},row);\n },\n handleDelete(index,row){\n this.$confirm('是否要删除该分类?', '提示', {\n confirmButtonText: '确定',\n cancelButtonText: '取消',\n type: 'warning'\n }).then(() => {\n deleteResourceCategory(row.id).then(response => {\n this.$message({\n type: 'success',\n message: '删除成功!'\n });\n this.getList();\n });\n });\n },\n handleDialogConfirm() {\n this.$confirm('是否要确认?', '提示', {\n confirmButtonText: '确定',\n cancelButtonText: '取消',\n type: 'warning'\n }).then(() => {\n if (this.isEdit) {\n updateResourceCategory(this.resourceCategory.id,this.resourceCategory).then(response => {\n this.$message({\n message: '修改成功!',\n type: 'success'\n });\n this.dialogVisible =false;\n this.getList();\n })\n } else {\n createResourceCategory(this.resourceCategory).then(response => {\n this.$message({\n message: '添加成功!',\n type: 'success'\n });\n this.dialogVisible =false;\n this.getList();\n })\n }\n })\n },\n getList() {\n this.listLoading = true;\n listAllCate({}).then(response => {\n this.listLoading = false;\n this.list = response.data;\n });\n }\n }\n }\n</script>\n<style>\n</style>\n\n\n\n\n\n// WEBPACK FOOTER //\n// src/views/ums/resource/categoryList.vue","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"app-container\"},[_c('el-card',{staticClass:\"operate-container\",attrs:{\"shadow\":\"never\"}},[_c('i',{staticClass:\"el-icon-tickets\"}),_vm._v(\" \"),_c('span',[_vm._v(\"数据列表\")]),_vm._v(\" \"),_c('el-button',{staticClass:\"btn-add\",attrs:{\"size\":\"mini\"},on:{\"click\":function($event){_vm.handleAdd()}}},[_vm._v(\"添加\")])],1),_vm._v(\" \"),_c('div',{staticClass:\"table-container\"},[_c('el-table',{directives:[{name:\"loading\",rawName:\"v-loading\",value:(_vm.listLoading),expression:\"listLoading\"}],ref:\"resourceCategoryTable\",staticStyle:{\"width\":\"100%\"},attrs:{\"data\":_vm.list,\"border\":\"\"}},[_c('el-table-column',{attrs:{\"label\":\"编号\",\"width\":\"100\",\"align\":\"center\"},scopedSlots:_vm._u([{key:\"default\",fn:function(scope){return [_vm._v(_vm._s(scope.row.id))]}}])}),_vm._v(\" \"),_c('el-table-column',{attrs:{\"label\":\"名称\",\"align\":\"center\"},scopedSlots:_vm._u([{key:\"default\",fn:function(scope){return [_vm._v(_vm._s(scope.row.name))]}}])}),_vm._v(\" \"),_c('el-table-column',{attrs:{\"label\":\"创建时间\",\"align\":\"center\"},scopedSlots:_vm._u([{key:\"default\",fn:function(scope){return [_vm._v(_vm._s(_vm._f(\"formatDateTime\")(scope.row.createTime)))]}}])}),_vm._v(\" \"),_c('el-table-column',{attrs:{\"label\":\"排序\",\"align\":\"center\"},scopedSlots:_vm._u([{key:\"default\",fn:function(scope){return [_vm._v(_vm._s(scope.row.sort))]}}])}),_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:{\"size\":\"mini\",\"type\":\"text\"},on:{\"click\":function($event){_vm.handleUpdate(scope.$index, scope.row)}}},[_vm._v(\"编辑\\n \")]),_vm._v(\" \"),_c('el-button',{attrs:{\"size\":\"mini\",\"type\":\"text\"},on:{\"click\":function($event){_vm.handleDelete(scope.$index, scope.row)}}},[_vm._v(\"删除\\n \")])]}}])})],1)],1),_vm._v(\" \"),_c('el-dialog',{attrs:{\"title\":\"添加分类\",\"visible\":_vm.dialogVisible,\"width\":\"40%\"},on:{\"update:visible\":function($event){_vm.dialogVisible=$event}}},[_c('el-form',{ref:\"resourceCategoryForm\",attrs:{\"model\":_vm.resourceCategory,\"label-width\":\"150px\",\"size\":\"small\"}},[_c('el-form-item',{attrs:{\"label\":\"名称:\"}},[_c('el-input',{staticStyle:{\"width\":\"250px\"},model:{value:(_vm.resourceCategory.name),callback:function ($$v) {_vm.$set(_vm.resourceCategory, \"name\", $$v)},expression:\"resourceCategory.name\"}})],1),_vm._v(\" \"),_c('el-form-item',{attrs:{\"label\":\"排序:\"}},[_c('el-input',{staticStyle:{\"width\":\"250px\"},model:{value:(_vm.resourceCategory.sort),callback:function ($$v) {_vm.$set(_vm.resourceCategory, \"sort\", $$v)},expression:\"resourceCategory.sort\"}})],1)],1),_vm._v(\" \"),_c('span',{staticClass:\"dialog-footer\",attrs:{\"slot\":\"footer\"},slot:\"footer\"},[_c('el-button',{attrs:{\"size\":\"small\"},on:{\"click\":function($event){_vm.dialogVisible = false}}},[_vm._v(\"取 消\")]),_vm._v(\" \"),_c('el-button',{attrs:{\"type\":\"primary\",\"size\":\"small\"},on:{\"click\":function($event){_vm.handleDialogConfirm()}}},[_vm._v(\"确 定\")])],1)],1)],1)}\nvar staticRenderFns = []\nvar esExports = { render: render, staticRenderFns: staticRenderFns }\nexport default esExports\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./node_modules/vue-loader/lib/template-compiler?{\"id\":\"data-v-1d5b8b03\",\"hasScoped\":false,\"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/ums/resource/categoryList.vue\n// module id = null\n// module chunks = ","function injectStyle (ssrContext) {\n require(\"!!../../../../node_modules/extract-text-webpack-plugin/dist/loader.js?{\\\"omit\\\":1,\\\"remove\\\":true,\\\"publicPath\\\":\\\"../../\\\"}!vue-style-loader!css-loader?{\\\"sourceMap\\\":true}!../../../../node_modules/vue-loader/lib/style-compiler/index?{\\\"vue\\\":true,\\\"id\\\":\\\"data-v-1d5b8b03\\\",\\\"scoped\\\":false,\\\"hasInlineConfig\\\":false}!../../../../node_modules/vue-loader/lib/selector?type=styles&index=0!./categoryList.vue\")\n}\nvar normalizeComponent = require(\"!../../../../node_modules/vue-loader/lib/component-normalizer\")\n/* script */\nexport * from \"!!babel-loader!../../../../node_modules/vue-loader/lib/selector?type=script&index=0!./categoryList.vue\"\nimport __vue_script__ from \"!!babel-loader!../../../../node_modules/vue-loader/lib/selector?type=script&index=0!./categoryList.vue\"\n/* template */\nimport __vue_template__ from \"!!../../../../node_modules/vue-loader/lib/template-compiler/index?{\\\"id\\\":\\\"data-v-1d5b8b03\\\",\\\"hasScoped\\\":false,\\\"transformToRequire\\\":{\\\"video\\\":[\\\"src\\\",\\\"poster\\\"],\\\"source\\\":\\\"src\\\",\\\"img\\\":\\\"src\\\",\\\"image\\\":\\\"xlink:href\\\"},\\\"buble\\\":{\\\"transforms\\\":{}}}!../../../../node_modules/vue-loader/lib/selector?type=template&index=0!./categoryList.vue\"\n/* template functional */\nvar __vue_template_functional__ = false\n/* styles */\nvar __vue_styles__ = injectStyle\n/* scopeId */\nvar __vue_scopeId__ = null\n/* moduleIdentifier (server only) */\nvar __vue_module_identifier__ = null\nvar Component = normalizeComponent(\n __vue_script__,\n __vue_template__,\n __vue_template_functional__,\n __vue_styles__,\n __vue_scopeId__,\n __vue_module_identifier__\n)\n\nexport default Component.exports\n\n\n\n//////////////////\n// WEBPACK FOOTER\n// ./src/views/ums/resource/categoryList.vue\n// module id = null\n// module chunks = "],"sourceRoot":""}