|
@@ -1,146 +1,146 @@
|
|
|
<!DOCTYPE html>
|
|
|
<html>
|
|
|
-<head>
|
|
|
- <title>作业配置项-列表</title>
|
|
|
- <meta charset="utf-8">
|
|
|
- <meta name="viewport"
|
|
|
- content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no"/>
|
|
|
- <!-- 所有的 css & js 资源 -->
|
|
|
- <link rel="stylesheet" href="../../static/kj/element-ui/theme-chalk/index.css">
|
|
|
- <link rel="stylesheet" href="../../static/sa.css">
|
|
|
- <script src="../../static/kj/vue.min.js"></script>
|
|
|
- <script src="../../static/kj/element-ui/index.js"></script>
|
|
|
- <script src="../../static/kj/httpVueLoader.js"></script>
|
|
|
- <script src="../../static/kj/jquery.min.js"></script>
|
|
|
- <script src="../../static/kj/layer/layer.js"></script>
|
|
|
- <script src="../../static/sa.js"></script>
|
|
|
-</head>
|
|
|
-<body>
|
|
|
-<div class="vue-box" style="display: none;" :style="'display: block;'">
|
|
|
- <div class="c-panel">
|
|
|
- <!-- ------------- 检索参数 ------------- -->
|
|
|
- <div class="c-title">检索参数</div>
|
|
|
- <el-form ref="form" :model='p' @submit.native.prevent>
|
|
|
- <sa-item type="text" name="名称" v-model="p.itemName"></sa-item>
|
|
|
- <el-button type="primary" icon="el-icon-search" @click="p.pageNo = 1; f5()">查询</el-button>
|
|
|
- <sa-item type="fast-btn" show="reset" style="display: inline;"></sa-item>
|
|
|
- <el-button v-if="sa.isAuth('tb-item-manager-add')" type="primary" icon="el-icon-plus"
|
|
|
- @click="add()">新增
|
|
|
- </el-button>
|
|
|
- <br/>
|
|
|
- </el-form>
|
|
|
- <!-- ------------- 数据列表 ------------- -->
|
|
|
- <el-table class="data-table" ref="data-table" :data="dataList">
|
|
|
- <el-table-column type="index" width="50">
|
|
|
- </el-table-column>
|
|
|
- <sa-td name="明细名称" prop="itemName" width="300px"></sa-td>
|
|
|
- <sa-td name="业务类型" prop="businessTypeName"></sa-td>
|
|
|
- <sa-td name="空车/载重" prop="itemType"></sa-td>
|
|
|
- <sa-td name="收费类型" prop="payTypeName"></sa-td>
|
|
|
- <sa-td name="价格" prop="price"></sa-td>
|
|
|
- <sa-td name="计价单位" prop="unit"></sa-td>
|
|
|
- <sa-td name="税率(%)" prop="taxRate"></sa-td>
|
|
|
- <sa-td name="适合规格(米)" width="120">
|
|
|
- <template slot-scope="s">
|
|
|
- <label>{{s.row.minLength}}—{{s.row.carLength}}</label>
|
|
|
- </template>
|
|
|
- </sa-td>
|
|
|
- <sa-td name="适合载重(kg)" width="120">
|
|
|
- <template slot-scope="s">
|
|
|
- <label>{{s.row.minWeight}}—{{s.row.maxWeight}}</label>
|
|
|
- </template>
|
|
|
- </sa-td>
|
|
|
- <el-table-column label="操作" fixed="right" width="240px">
|
|
|
- <template slot-scope="s">
|
|
|
- <el-button class="c-btn" type="success" icon="el-icon-view" @click="get(s.row)">查看
|
|
|
- </el-button>
|
|
|
- <el-button v-if="sa.isAuth('tb-item-manager-edit')" class="c-btn" type="primary"
|
|
|
- icon="el-icon-edit" @click="update(s.row)">修改
|
|
|
- </el-button>
|
|
|
- <el-button v-if="sa.isAuth('tb-item-manager-del')" class="c-btn" type="danger"
|
|
|
- icon="el-icon-delete" @click="del(s.row)">删除
|
|
|
- </el-button>
|
|
|
- </template>
|
|
|
- </el-table-column>
|
|
|
- </el-table>
|
|
|
- <!-- ------------- 分页 ------------- -->
|
|
|
- <sa-item type="page" :curr.sync="p.pageNo" :size.sync="p.pageSize" :total="dataCount" @change="f5()">
|
|
|
- </sa-item>
|
|
|
- </div>
|
|
|
-</div>
|
|
|
-<script>
|
|
|
- var app = new Vue({
|
|
|
- components: {
|
|
|
- "sa-item": httpVueLoader('../../sa-frame/com/sa-item.vue'),
|
|
|
- "sa-td": httpVueLoader('../../sa-frame/com/sa-td.vue'),
|
|
|
- },
|
|
|
- el: '.vue-box',
|
|
|
- data: {
|
|
|
- p: { // 查询参数
|
|
|
- id: '', // 主键
|
|
|
- itemName: '', // 项目名称
|
|
|
- pageNo: 1, // 当前页
|
|
|
- pageSize: 20, // 页大小
|
|
|
- sortType: 0 // 排序方式
|
|
|
- },
|
|
|
- dataCount: 0,
|
|
|
- dataList: [], // 数据集合
|
|
|
- itemTypeList: [],
|
|
|
- businessTypeList: [{
|
|
|
- value: '0',
|
|
|
- name: '默认'
|
|
|
- },
|
|
|
- {
|
|
|
- value: '1',
|
|
|
- name: '消杀'
|
|
|
- },
|
|
|
- {
|
|
|
- value: '2',
|
|
|
- name: '装卸'
|
|
|
- },
|
|
|
- {
|
|
|
- value: '3',
|
|
|
- name: '核酸'
|
|
|
- },
|
|
|
- ]
|
|
|
- },
|
|
|
- methods: {
|
|
|
- // 修改
|
|
|
- update: function (data) {
|
|
|
- sa.showIframe('修改数据', 'tb-item-edit.html?id=' + data.id, '600px', '60%');
|
|
|
- },
|
|
|
- // 新增
|
|
|
- add: function (data) {
|
|
|
- sa.showIframe('新增数据', 'tb-item-add.html?id=-1', '600px', '70%');
|
|
|
- },
|
|
|
- get(data) {
|
|
|
- sa.showIframe('数据详情', 'tb-item-info.html?id=' + data.id, '600px', '60%');
|
|
|
- },
|
|
|
- // 删除
|
|
|
- del: function (data) {
|
|
|
- sa.confirm('是否删除,此操作不可撤销', function () {
|
|
|
- sa.ajax('/TbItem/delete?id=' + data.id, function (res) {
|
|
|
- sa.arrayDelete(this.dataList, data);
|
|
|
- sa.ok('删除成功');
|
|
|
- sa.f5TableHeight(); // 刷新表格高度
|
|
|
- }.bind(this))
|
|
|
- }.bind(this));
|
|
|
- },
|
|
|
- // 刷新
|
|
|
- f5: function () {
|
|
|
- sa.ajax('/TbItem/getList', sa.removeNull(this.p), function (res) {
|
|
|
- let list = res.data;
|
|
|
- this.dataList = list; // 数据
|
|
|
- this.dataCount = res.dataCount; // 数据总数
|
|
|
- sa.f5TableHeight(); // 刷新表格高度
|
|
|
- }.bind(this));
|
|
|
- },
|
|
|
- },
|
|
|
- created: function () {
|
|
|
- this.f5();
|
|
|
- sa.onInputEnter();
|
|
|
- }
|
|
|
- })
|
|
|
-</script>
|
|
|
-</body>
|
|
|
+ <head>
|
|
|
+ <title>作业配置项-列表</title>
|
|
|
+ <meta charset="utf-8">
|
|
|
+ <meta name="viewport"
|
|
|
+ content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
|
|
|
+ <!-- 所有的 css & js 资源 -->
|
|
|
+ <link rel="stylesheet" href="../../static/kj/element-ui/theme-chalk/index.css">
|
|
|
+ <link rel="stylesheet" href="../../static/sa.css">
|
|
|
+ <script src="../../static/kj/vue.min.js"></script>
|
|
|
+ <script src="../../static/kj/element-ui/index.js"></script>
|
|
|
+ <script src="../../static/kj/httpVueLoader.js"></script>
|
|
|
+ <script src="../../static/kj/jquery.min.js"></script>
|
|
|
+ <script src="../../static/kj/layer/layer.js"></script>
|
|
|
+ <script src="../../static/sa.js"></script>
|
|
|
+ </head>
|
|
|
+ <body>
|
|
|
+ <div class="vue-box" style="display: none;" :style="'display: block;'">
|
|
|
+ <div class="c-panel">
|
|
|
+ <!-- ------------- 检索参数 ------------- -->
|
|
|
+ <div class="c-title">检索参数</div>
|
|
|
+ <el-form ref="form" :model='p' @submit.native.prevent>
|
|
|
+ <sa-item type="text" name="名称" v-model="p.itemName"></sa-item>
|
|
|
+ <el-button type="primary" icon="el-icon-search" @click="p.pageNo = 1; f5()">查询</el-button>
|
|
|
+ <sa-item type="fast-btn" show="reset" style="display: inline;"></sa-item>
|
|
|
+ <el-button v-if="sa.isAuth('tb-item-manager-add')" type="primary" icon="el-icon-plus"
|
|
|
+ @click="add()">新增
|
|
|
+ </el-button>
|
|
|
+ <br />
|
|
|
+ </el-form>
|
|
|
+ <!-- ------------- 数据列表 ------------- -->
|
|
|
+ <el-table class="data-table" ref="data-table" :data="dataList">
|
|
|
+ <el-table-column type="index" width="50">
|
|
|
+ </el-table-column>
|
|
|
+ <sa-td name="车型" prop="businessTypeName"></sa-td>
|
|
|
+ <sa-td name="业务类型" prop="itemName" width="300px"></sa-td>
|
|
|
+ <sa-td name="空车/载重" prop="itemType"></sa-td>
|
|
|
+ <sa-td name="收费项目" prop="payTypeName"></sa-td>
|
|
|
+ <sa-td name="价格" prop="price"></sa-td>
|
|
|
+ <sa-td name="计价单位" prop="unit"></sa-td>
|
|
|
+ <sa-td name="税率(%)" prop="taxRate"></sa-td>
|
|
|
+ <sa-td name="适合规格(米)" width="120">
|
|
|
+ <template slot-scope="s">
|
|
|
+ <label>{{s.row.minLength}}—{{s.row.carLength}}</label>
|
|
|
+ </template>
|
|
|
+ </sa-td>
|
|
|
+ <sa-td name="适合载重(kg)" width="120">
|
|
|
+ <template slot-scope="s">
|
|
|
+ <label>{{s.row.minWeight}}—{{s.row.maxWeight}}</label>
|
|
|
+ </template>
|
|
|
+ </sa-td>
|
|
|
+ <el-table-column label="操作" fixed="right" width="240px">
|
|
|
+ <template slot-scope="s">
|
|
|
+ <el-button class="c-btn" type="success" icon="el-icon-view" @click="get(s.row)">查看
|
|
|
+ </el-button>
|
|
|
+ <el-button v-if="sa.isAuth('tb-item-manager-edit')" class="c-btn" type="primary"
|
|
|
+ icon="el-icon-edit" @click="update(s.row)">修改
|
|
|
+ </el-button>
|
|
|
+ <el-button v-if="sa.isAuth('tb-item-manager-del')" class="c-btn" type="danger"
|
|
|
+ icon="el-icon-delete" @click="del(s.row)">删除
|
|
|
+ </el-button>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
+ <!-- ------------- 分页 ------------- -->
|
|
|
+ <sa-item type="page" :curr.sync="p.pageNo" :size.sync="p.pageSize" :total="dataCount" @change="f5()">
|
|
|
+ </sa-item>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <script>
|
|
|
+ var app = new Vue({
|
|
|
+ components: {
|
|
|
+ "sa-item": httpVueLoader('../../sa-frame/com/sa-item.vue'),
|
|
|
+ "sa-td": httpVueLoader('../../sa-frame/com/sa-td.vue'),
|
|
|
+ },
|
|
|
+ el: '.vue-box',
|
|
|
+ data: {
|
|
|
+ p: { // 查询参数
|
|
|
+ id: '', // 主键
|
|
|
+ itemName: '', // 项目名称
|
|
|
+ pageNo: 1, // 当前页
|
|
|
+ pageSize: 20, // 页大小
|
|
|
+ sortType: 0 // 排序方式
|
|
|
+ },
|
|
|
+ dataCount: 0,
|
|
|
+ dataList: [], // 数据集合
|
|
|
+ itemTypeList: [],
|
|
|
+ businessTypeList: [{
|
|
|
+ value: '0',
|
|
|
+ name: '默认'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ value: '1',
|
|
|
+ name: '消杀'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ value: '2',
|
|
|
+ name: '装卸'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ value: '3',
|
|
|
+ name: '核酸'
|
|
|
+ },
|
|
|
+ ]
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ // 修改
|
|
|
+ update: function(data) {
|
|
|
+ sa.showIframe('修改数据', 'tb-item-edit.html?id=' + data.id, '600px', '60%');
|
|
|
+ },
|
|
|
+ // 新增
|
|
|
+ add: function(data) {
|
|
|
+ sa.showIframe('新增数据', 'tb-item-add.html?id=-1', '600px', '70%');
|
|
|
+ },
|
|
|
+ get(data) {
|
|
|
+ sa.showIframe('数据详情', 'tb-item-info.html?id=' + data.id, '600px', '60%');
|
|
|
+ },
|
|
|
+ // 删除
|
|
|
+ del: function(data) {
|
|
|
+ sa.confirm('是否删除,此操作不可撤销', function() {
|
|
|
+ sa.ajax('/TbItem/delete?id=' + data.id, function(res) {
|
|
|
+ sa.arrayDelete(this.dataList, data);
|
|
|
+ sa.ok('删除成功');
|
|
|
+ sa.f5TableHeight(); // 刷新表格高度
|
|
|
+ }.bind(this))
|
|
|
+ }.bind(this));
|
|
|
+ },
|
|
|
+ // 刷新
|
|
|
+ f5: function() {
|
|
|
+ sa.ajax('/TbItem/getList', sa.removeNull(this.p), function(res) {
|
|
|
+ let list = res.data;
|
|
|
+ this.dataList = list; // 数据
|
|
|
+ this.dataCount = res.dataCount; // 数据总数
|
|
|
+ sa.f5TableHeight(); // 刷新表格高度
|
|
|
+ }.bind(this));
|
|
|
+ },
|
|
|
+ },
|
|
|
+ created: function() {
|
|
|
+ this.f5();
|
|
|
+ sa.onInputEnter();
|
|
|
+ }
|
|
|
+ })
|
|
|
+ </script>
|
|
|
+ </body>
|
|
|
</html>
|