123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185 |
- <template>
- <div class="waybill">
- <el-card>
- <!-- 头部细节部分 -->
- <div class="title">
- <el-row class="bottom">
- <el-col :span="24">
- <div class="grid-content bg-purple-dark">
- <!-- <el-button type="primary" @click="addRoleList = true">新增</el-button> -->
- </div>
- </el-col>
- </el-row>
- </div>
- <!-- 头部细节部分结束 -->
- <!-- 表格部分 -->
- <template>
- <el-table
- v-loading="loading"
- ref="multipleTable"
- :data="roletable"
- border
- tooltip-effect="dark"
- style="width: 100%">
- <el-table-column
- label="序号"
- type="index"
- width="40"
- show-overflow-tooltip>
- </el-table-column>
- <el-table-column
- prop="num"
- label="运单编号"
- show-overflow-tooltip>
- </el-table-column>
- <el-table-column
- prop="plateNumber"
- label="车牌号"
- show-overflow-tooltip>
- </el-table-column>
- <el-table-column
- prop="status"
- label="运单状态"
- show-overflow-tooltip>
- </el-table-column>
- <el-table-column
- prop="isHistory"
- label="运单类型"
- show-overflow-tooltip>
- </el-table-column>
- <el-table-column
- label="开始运单创建时间"
- show-overflow-tooltip>
- <template slot-scope="scope" show-overflow-tooltip>
- <span>{{scope.row.startBillCreateTime | fmtDate}}</span>
- </template>
- </el-table-column>
- <el-table-column
- prop="realDestAddr"
- label="运单实际目的地"
- show-overflow-tooltip>
- </el-table-column>
- <el-table-column
- label="运单结束创建时间"
- show-overflow-tooltip>
- <template slot-scope="scope" show-overflow-tooltip>
- <span>{{scope.row.endBillCreateTime | fmtDate}}</span>
- </template>
- </el-table-column>
- <el-table-column
- prop="appKey"
- label="appKey"
- show-overflow-tooltip>
- </el-table-column>
- <el-table-column
- prop="company"
- label="公司名称"
- show-overflow-tooltip>
- </el-table-column>
- </el-table>
- </template>
- <!-- 分页 -->
- <div class="block">
- <el-pagination
- @size-change="handleSizeChange"
- @current-change="handleCurrentChange"
- :current-page="current"
- :page-sizes="[6, 8, 10]"
- :page-size="pagesize"
- layout="total, sizes, prev, pager, next, jumper"
- :total="total">
- </el-pagination>
- </div>
- </el-card>
- </div>
- </template>
- <script type="text/javascript">
- export default{
- data() {
- return {
- loading: true,
- roletable: [],
- formList: {
- "roleId": "",
- "permissionIds": []
- },
- current: 1,
- pagesize: 10,
- total: 0,
- }
- },
- created() {
- this.loadData();
- },
- methods: {
- // 请求查询数据
- async loadData() {
- const response = await this.$http.get(`app/billRecord?¤t=${this.current}&size=${this.pagesize}`);
- if (response.data.code === 1) {
- this.loading = false;
- this.roletable = response.data.responseData.records;
- this.total = response.data.responseData.total;
- }
- },
- // 分页方法
- handleSizeChange(val) {
- this.pagesize = val;
- this.loadData();
- console.log(`每页 ${val} 条`);
- },
- handleCurrentChange(val) {
- this.current = val;
- this.loadData();
- console.log(`当前页: ${val}`);
- },
- }
- };
- </script>
- <style scoped>
- .waybill .title{
- font-size: 5px;
- margin-bottom: 20px;
- }
- .waybill .text {
- font-size: 14px;
- display: inline-block;
- }
- .waybill input {
- margin-left: 10px;
- margin-right: 10px;
- width: 150px;
- }
- .waybill select {
- border-radius: 3px;
- width: 150px;
- }
- .waybill .middle {
- margin-top: 20px;
- margin-bottom:20px;
- }
- .waybill .bottom {
- margin-bottom: 20px;
- }
- .waybill .el-button--primary {
- background-color: #5885f7 !important;
- border-color: #5885f7 !important;
- }
- .waybill .el-button {
- padding: 4px 20px !important;
- }
- .waybill .block {
- font-size: 5px;
- text-align: center;
- margin-top: 15px;
- }
- </style>
|