c472b71149eaa0c0a5c7e6fa2594915f.json 8.0 KB

1
  1. {"remainingRequest":"D:\\jiayue\\pig-ui\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jiayue\\pig-ui\\src\\views\\admin\\client\\index.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jiayue\\pig-ui\\src\\views\\admin\\client\\index.vue","mtime":1619070292887},{"path":"D:\\jiayue\\pig-ui\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jiayue\\pig-ui\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"D:\\jiayue\\pig-ui\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jiayue\\pig-ui\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\nimport {addObj, delObj, fetchList, putObj} from '@/api/admin/client'\nimport {tableOption} from '@/const/crud/admin/client'\nimport {mapGetters} from 'vuex'\n\nexport default {\n name: 'client',\n data() {\n return {\n tableData: [],\n page: {\n total: 0, // 总页数\n currentPage: 1, // 当前页数\n pageSize: 20 // 每页显示多少条\n },\n tableLoading: false,\n tableOption: tableOption\n }\n },\n created() {\n },\n mounted: function () {\n },\n computed: {\n ...mapGetters(['permissions']),\n permissionList() {\n return {\n addBtn: this.vaildData(this.permissions.sys_client_add, false),\n delBtn: this.vaildData(this.permissions.sys_client_del, false),\n editBtn: this.vaildData(this.permissions.sys_client_edit, false)\n }\n }\n },\n methods: {\n getList(page, params) {\n this.tableLoading = true\n fetchList(Object.assign({\n current: page.currentPage,\n size: page.pageSize\n }, params)).then(response => {\n this.tableData = response.data.data.records\n this.page.total = response.data.data.total\n this.tableLoading = false\n })\n },\n rowDel: function (row, index) {\n this.$confirm('是否确认删除ID为' + row.clientId, '提示', {\n confirmButtonText: '确定',\n cancelButtonText: '取消',\n type: 'warning'\n }).then(function () {\n return delObj(row.clientId)\n }).then(data => {\n this.$message.success('删除成功')\n this.refreshChange()\n })\n },\n handleUpdate: function (row, index, done) {\n putObj(row).then(data => {\n this.$message.success('修改成功')\n this.refreshChange()\n done()\n })\n },\n handleSave: function (row, done) {\n addObj(row).then(data => {\n this.$message.success('添加成功')\n this.refreshChange()\n done()\n })\n },\n refreshChange() {\n this.getList(this.page)\n },\n sizeChange(pageSize) {\n this.page.pageSize = pageSize\n },\n currentChange(current) {\n this.page.currentPage = current\n },\n beforeOpen(show, type) {\n window.boxType = type\n show()\n }\n }\n}\n",{"version":3,"sources":["index.vue"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAwCA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","file":"index.vue","sourceRoot":"src/views/admin/client","sourcesContent":["<!--\r\n - Copyright (c) 2018-2025, lengleng All rights reserved.\r\n -\r\n - Redistribution and use in source and binary forms, with or without\r\n - modification, are permitted provided that the following conditions are met:\r\n -\r\n - Redistributions of source code must retain the above copyright notice,\r\n - this list of conditions and the following disclaimer.\r\n - Redistributions in binary form must reproduce the above copyright\r\n - notice, this list of conditions and the following disclaimer in the\r\n - documentation and/or other materials provided with the distribution.\r\n - Neither the name of the pig4cloud.com developer nor the names of its\r\n - contributors may be used to endorse or promote products derived from\r\n - this software without specific prior written permission.\r\n - Author: lengleng (wangiegie@gmail.com)\r\n -->\r\n\r\n<template>\r\n <div class=\"execution\">\r\n <basic-container>\r\n <avue-crud ref=\"crud\"\r\n :page.sync=\"page\"\r\n :data=\"tableData\"\r\n :table-loading=\"tableLoading\"\r\n :option=\"tableOption\"\r\n :permission=\"permissionList\"\r\n @on-load=\"getList\"\r\n :before-open=\"beforeOpen\"\r\n @size-change=\"sizeChange\"\r\n @current-change=\"currentChange\"\r\n @refresh-change=\"refreshChange\"\r\n @row-update=\"handleUpdate\"\r\n @row-save=\"handleSave\"\r\n @row-del=\"rowDel\">\r\n </avue-crud>\r\n </basic-container>\r\n </div>\r\n</template>\r\n\r\n<script>\r\n import {addObj, delObj, fetchList, putObj} from '@/api/admin/client'\r\n import {tableOption} from '@/const/crud/admin/client'\r\n import {mapGetters} from 'vuex'\r\n\r\n export default {\r\n name: 'client',\r\n data() {\r\n return {\r\n tableData: [],\r\n page: {\r\n total: 0, // 总页数\r\n currentPage: 1, // 当前页数\r\n pageSize: 20 // 每页显示多少条\r\n },\r\n tableLoading: false,\r\n tableOption: tableOption\r\n }\r\n },\r\n created() {\r\n },\r\n mounted: function () {\r\n },\r\n computed: {\r\n ...mapGetters(['permissions']),\r\n permissionList() {\r\n return {\r\n addBtn: this.vaildData(this.permissions.sys_client_add, false),\r\n delBtn: this.vaildData(this.permissions.sys_client_del, false),\r\n editBtn: this.vaildData(this.permissions.sys_client_edit, false)\r\n }\r\n }\r\n },\r\n methods: {\r\n getList(page, params) {\r\n this.tableLoading = true\r\n fetchList(Object.assign({\r\n current: page.currentPage,\r\n size: page.pageSize\r\n }, params)).then(response => {\r\n this.tableData = response.data.data.records\r\n this.page.total = response.data.data.total\r\n this.tableLoading = false\r\n })\r\n },\r\n rowDel: function (row, index) {\r\n this.$confirm('是否确认删除ID为' + row.clientId, '提示', {\r\n confirmButtonText: '确定',\r\n cancelButtonText: '取消',\r\n type: 'warning'\r\n }).then(function () {\r\n return delObj(row.clientId)\r\n }).then(data => {\r\n this.$message.success('删除成功')\r\n this.refreshChange()\r\n })\r\n },\r\n handleUpdate: function (row, index, done) {\r\n putObj(row).then(data => {\r\n this.$message.success('修改成功')\r\n this.refreshChange()\r\n done()\r\n })\r\n },\r\n handleSave: function (row, done) {\r\n addObj(row).then(data => {\r\n this.$message.success('添加成功')\r\n this.refreshChange()\r\n done()\r\n })\r\n },\r\n refreshChange() {\r\n this.getList(this.page)\r\n },\r\n sizeChange(pageSize) {\r\n this.page.pageSize = pageSize\r\n },\r\n currentChange(current) {\r\n this.page.currentPage = current\r\n },\r\n beforeOpen(show, type) {\r\n window.boxType = type\r\n show()\r\n }\r\n }\r\n }\r\n</script>\r\n\r\n<style lang=\"scss\" scoped>\r\n</style>\r\n\r\n"]}]}