|
@@ -15,179 +15,25 @@
|
|
|
</span>
|
|
|
</div>
|
|
|
<div class="content" v-loading="loading">
|
|
|
- <el-table
|
|
|
- :data="tableData"
|
|
|
- stripe
|
|
|
- size="mini"
|
|
|
- height="420"
|
|
|
- header-row-style="color: #000"
|
|
|
- style="width: 100%;">
|
|
|
- <el-table-column
|
|
|
- type="index"
|
|
|
- label="序号"
|
|
|
- align="center"
|
|
|
- width="50">
|
|
|
- </el-table-column>
|
|
|
- <el-table-column
|
|
|
- align="center"
|
|
|
- label="货运日期"
|
|
|
- width="150"
|
|
|
- show-overflow-tooltip
|
|
|
- prop="arrivalTime"
|
|
|
- >
|
|
|
- <template slot-scope="scope">
|
|
|
- {{scope.row.arrivalTime?scope.row.arrivalTime.slice(0,16):''}}
|
|
|
- </template>
|
|
|
- </el-table-column>
|
|
|
- <el-table-column
|
|
|
- align="center"
|
|
|
- label="业务员"
|
|
|
- width="60"
|
|
|
- show-overflow-tooltip
|
|
|
- prop="salesmanName"
|
|
|
- ></el-table-column>
|
|
|
- <el-table-column
|
|
|
- align="center"
|
|
|
- label="货运地点"
|
|
|
- prop="addressDetail"
|
|
|
- >
|
|
|
- <template slot-scope="{ row,index}">
|
|
|
- <el-tooltip class="item" effect="dark" placement="top">
|
|
|
- <div v-html="ToBreak(row.addressDetail)" slot="content"></div>
|
|
|
- <div style="overflow: hidden;white-space: nowrap;text-overflow: ellipsis;">{{row.addressDetail}}</div>
|
|
|
- </el-tooltip>
|
|
|
- </template>
|
|
|
- </el-table-column>
|
|
|
- <el-table-column
|
|
|
- align="center"
|
|
|
- label="票据号"
|
|
|
- prop="receiptNo"
|
|
|
- >
|
|
|
- </el-table-column>
|
|
|
- <el-table-column
|
|
|
- align="center"
|
|
|
- label="提单号"
|
|
|
- width="130"
|
|
|
- show-overflow-tooltip
|
|
|
- prop="billNo">
|
|
|
- <template slot-scope="{row}">
|
|
|
+ <avue-crud :data="tableData" :option="option" :key="key" ref="dialogColumn" @resetColumn="resetColumn" @saveColumn="saveColumn">
|
|
|
+ <template slot="billNo" slot-scope="{row}">
|
|
|
<span class="el-button--text" style="cursor: pointer"
|
|
|
@click="openTrack(row,0)">{{ row.billNo }}</span>
|
|
|
- </template>
|
|
|
- </el-table-column>
|
|
|
- <el-table-column
|
|
|
- align="center"
|
|
|
- label="场站"
|
|
|
- show-overflow-tooltip
|
|
|
- prop="station"
|
|
|
- ></el-table-column>
|
|
|
- <el-table-column
|
|
|
- align="center"
|
|
|
- label="箱型箱量"
|
|
|
- show-overflow-tooltip
|
|
|
- prop="ctnDetail"
|
|
|
- ></el-table-column>
|
|
|
- <el-table-column
|
|
|
- align="center"
|
|
|
- label="车队"
|
|
|
- width="190"
|
|
|
- show-overflow-tooltip
|
|
|
- prop="fleetShortName"
|
|
|
- ></el-table-column>
|
|
|
- <el-table-column
|
|
|
- align="center"
|
|
|
- label="车号"
|
|
|
- width="100"
|
|
|
- show-overflow-tooltip
|
|
|
- prop="billNo">
|
|
|
- <template slot-scope="{row}">
|
|
|
+ </template>
|
|
|
+ <template slot="plateNo" slot-scope="{row}">
|
|
|
<span class="el-button--text" style="cursor: pointer"
|
|
|
@click="openTrack(row,1)">{{ row.plateNo }}</span>
|
|
|
- </template>
|
|
|
- </el-table-column>
|
|
|
- <el-table-column
|
|
|
- width="100"
|
|
|
- align="center"
|
|
|
- label="状态"
|
|
|
- show-overflow-tooltip
|
|
|
- prop="status">
|
|
|
- <template slot-scope="{row}">
|
|
|
- <span v-if="row.status == 0" style="color: #E45656;">未调度</span>
|
|
|
- <span v-if="row.status == 1" style="color: #F56C6C;">未派车</span>
|
|
|
- <span v-if="row.status == 2" style="color: #F1A532;">未受理</span>
|
|
|
- <span v-if="row.status == 3" style="color: #53C21D;">未完工</span>
|
|
|
- <span v-if="row.status == 5" style="color: #F56C6C;">未到厂</span>
|
|
|
- <span v-if="row.status == 4" style="color: #3C9CFF;">工单关闭</span>
|
|
|
- <span v-if="row.status == 6" style="color: #3C9CFF;">已提箱</span>
|
|
|
- </template>
|
|
|
- </el-table-column>
|
|
|
- <el-table-column
|
|
|
- align="center"
|
|
|
- label="运费"
|
|
|
- show-overflow-tooltip
|
|
|
- prop="landAmountD"
|
|
|
- ></el-table-column>
|
|
|
-<!-- <el-table-column-->
|
|
|
-<!-- align="center"-->
|
|
|
-<!-- label="其他费用(总)"-->
|
|
|
-<!-- width="100"-->
|
|
|
-<!-- show-overflow-tooltip-->
|
|
|
-<!-- prop="allFeeD"-->
|
|
|
-<!-- ></el-table-column>-->
|
|
|
- <el-table-column
|
|
|
- align="center"
|
|
|
- label="应付杂费"
|
|
|
- v-if="roleName.indexOf('平台') !== -1"
|
|
|
- show-overflow-tooltip
|
|
|
- prop="extraAmountC"
|
|
|
- ></el-table-column>
|
|
|
- <el-table-column
|
|
|
- align="center"
|
|
|
- label="应收杂费"
|
|
|
- show-overflow-tooltip
|
|
|
- prop="extraAmountD"
|
|
|
- ></el-table-column>
|
|
|
- <el-table-column
|
|
|
- align="center"
|
|
|
- label="客户名称"
|
|
|
- width="190"
|
|
|
- show-overflow-tooltip
|
|
|
- prop="corpShortName"
|
|
|
- ></el-table-column>
|
|
|
- <el-table-column
|
|
|
- align="center"
|
|
|
- label="备注"
|
|
|
- width="190"
|
|
|
- show-overflow-tooltip
|
|
|
- prop="remarks"
|
|
|
- ></el-table-column>
|
|
|
-<!-- <el-table-column-->
|
|
|
-<!-- width="120"-->
|
|
|
-<!-- align="center"-->
|
|
|
-<!-- prop="plateNo">-->
|
|
|
-<!-- <template slot-scope="{row}">-->
|
|
|
-<!-- <span class="el-button--text" style="cursor: pointer"-->
|
|
|
-<!-- @click="openTrack(row)">{{ row.plateNo }}</span>-->
|
|
|
-<!-- </template>-->
|
|
|
-<!-- </el-table-column>-->
|
|
|
-<!-- <el-table-column-->
|
|
|
-<!-- width="100"-->
|
|
|
-<!-- prop="status">-->
|
|
|
-<!-- <template slot-scope="{row}">-->
|
|
|
-<!-- <span v-if="row.status == 0" style="color: #E45656;">未调度</span>-->
|
|
|
-<!-- <span v-if="row.status == 1" style="color: #F56C6C;">未派车</span>-->
|
|
|
-<!-- <span v-if="row.status == 2" style="color: #F1A532;">未受理</span>-->
|
|
|
-<!-- <span v-if="row.status == 3" style="color: #53C21D;">未完工</span>-->
|
|
|
-<!-- <span v-if="row.status == 5" style="color: #F56C6C;">未到厂</span>-->
|
|
|
-<!-- <span v-if="row.status == 4" style="color: #3C9CFF;">工单关闭</span>-->
|
|
|
-<!-- <span v-if="row.status == 6" style="color: #3C9CFF;">已提箱</span>-->
|
|
|
-<!-- </template>-->
|
|
|
-<!-- </el-table-column>-->
|
|
|
-<!-- <el-table-column-->
|
|
|
-<!-- show-overflow-tooltip-->
|
|
|
-<!-- prop="corpName">-->
|
|
|
-<!-- </el-table-column>-->
|
|
|
- </el-table>
|
|
|
+ </template>
|
|
|
+ <template slot="status" slot-scope="{row}">
|
|
|
+ <span v-if="row.status == 0" style="color: #E45656;">未调度</span>
|
|
|
+ <span v-if="row.status == 1" style="color: #F56C6C;">未派车</span>
|
|
|
+ <span v-if="row.status == 2" style="color: #F1A532;">未受理</span>
|
|
|
+ <span v-if="row.status == 3" style="color: #53C21D;">未完工</span>
|
|
|
+ <span v-if="row.status == 5" style="color: #F56C6C;">未到厂</span>
|
|
|
+ <span v-if="row.status == 4" style="color: #3C9CFF;">工单关闭</span>
|
|
|
+ <span v-if="row.status == 6" style="color: #3C9CFF;">已提箱</span>
|
|
|
+ </template>
|
|
|
+ </avue-crud>
|
|
|
</div>
|
|
|
</div>
|
|
|
</el-card>
|
|
@@ -234,16 +80,188 @@ export default {
|
|
|
tableData: [],
|
|
|
map: null,
|
|
|
marker: null,
|
|
|
- lineArr: []
|
|
|
+ lineArr: [],
|
|
|
+ key:0,
|
|
|
+ option:{},
|
|
|
+ optionList:{
|
|
|
+ stripe:true,
|
|
|
+ index:true,
|
|
|
+ menu:false,
|
|
|
+ refreshBtn:false,
|
|
|
+ addBtn:false,
|
|
|
+ height:390,
|
|
|
+ align:'center',
|
|
|
+ column:[
|
|
|
+ {
|
|
|
+ label:'货运日期',
|
|
|
+ prop:'arrivalTime',
|
|
|
+ format: "yyyy-MM-dd HH:mm",
|
|
|
+ index:1,
|
|
|
+ width:150,
|
|
|
+ overHidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label:'业务员',
|
|
|
+ prop:'salesmanName',
|
|
|
+ index:2,
|
|
|
+ width:60,
|
|
|
+ overHidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label:'货运地点',
|
|
|
+ prop:'addressDetail',
|
|
|
+ index:3,
|
|
|
+ width:100,
|
|
|
+ overHidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label:'票据号',
|
|
|
+ prop:'receiptNo',
|
|
|
+ index:4,
|
|
|
+ width:100,
|
|
|
+ overHidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label:'提单号',
|
|
|
+ prop:'billNo',
|
|
|
+ index:5,
|
|
|
+ width:130,
|
|
|
+ overHidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label:'场站',
|
|
|
+ prop:'station',
|
|
|
+ index:6,
|
|
|
+ width:100,
|
|
|
+ overHidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label:'箱型箱量',
|
|
|
+ prop:'ctnDetail',
|
|
|
+ index:7,
|
|
|
+ width:100,
|
|
|
+ overHidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label:'车队',
|
|
|
+ prop:'fleetShortName',
|
|
|
+ index:8,
|
|
|
+ width:190,
|
|
|
+ overHidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label:'车号',
|
|
|
+ prop:'plateNo',
|
|
|
+ index:9,
|
|
|
+ width:100,
|
|
|
+ overHidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label:'状态',
|
|
|
+ prop:'status',
|
|
|
+ type: 'select',
|
|
|
+ dicUrl: "/api/blade-system/dict-biz/dictionary?code=land_order_status",
|
|
|
+ props: {
|
|
|
+ label: "dictValue",
|
|
|
+ value: "dictKey"
|
|
|
+ },
|
|
|
+ dataType: "string",
|
|
|
+ index:10,
|
|
|
+ width:100,
|
|
|
+ overHidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label:'运费',
|
|
|
+ prop:'landAmountD',
|
|
|
+ index:11,
|
|
|
+ width:100,
|
|
|
+ overHidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label:'应收杂费',
|
|
|
+ prop:'extraAmountD',
|
|
|
+ index:13,
|
|
|
+ width:100,
|
|
|
+ overHidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label:'客户名称',
|
|
|
+ prop:'corpShortName',
|
|
|
+ index:14,
|
|
|
+ width:100,
|
|
|
+ overHidden: true,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label:'备注',
|
|
|
+ prop:'remarks',
|
|
|
+ index:15,
|
|
|
+ width:100,
|
|
|
+ overHidden: true,
|
|
|
+ },
|
|
|
+ ]
|
|
|
+ },
|
|
|
};
|
|
|
},
|
|
|
- mounted() {
|
|
|
+ async mounted() {
|
|
|
+ this.option = await this.getColumnData(this.getColumnName(140), this.optionList);
|
|
|
+ this.key++
|
|
|
this.init();
|
|
|
+ for (let item of this.option.column){
|
|
|
+ if (item.prop === 'extraAmountC') return
|
|
|
+ }
|
|
|
+ if (this.roleName.indexOf('平台') !== -1){
|
|
|
+ this.option.column.push(
|
|
|
+ {
|
|
|
+ label:'应付杂费',
|
|
|
+ prop:'extraAmountC',
|
|
|
+ index:12,
|
|
|
+ width:100,
|
|
|
+ overHidden: true,
|
|
|
+ }
|
|
|
+ )
|
|
|
+ }
|
|
|
},
|
|
|
beforeDestroy() {
|
|
|
this.map && this.map.destroy();
|
|
|
},
|
|
|
methods: {
|
|
|
+ //自定义列保存
|
|
|
+ async saveColumn() {
|
|
|
+ /**
|
|
|
+ * 已定义全局方法,直接使用,saveColumnData保存列数据方法,参数传值(表格名称,当前表格的option数据)
|
|
|
+ * 已定义全局方法,直接使用,getColumnName方法用来获取枚举值,参数根据自己定义的code值获取中文名
|
|
|
+ * 一定要执行异步操作,要等接口成功返回,才能执行下一行代码
|
|
|
+ */
|
|
|
+ const inSave = await this.saveColumnData(this.getColumnName(140), this.option);
|
|
|
+ if (inSave) {
|
|
|
+ this.$message.success("保存成功");
|
|
|
+ //关闭窗口
|
|
|
+ this.$refs.crud.$refs.dialogColumn.columnBox = false;
|
|
|
+ }
|
|
|
+ },
|
|
|
+ //自定义列重置
|
|
|
+ async resetColumn() {
|
|
|
+ this.option = this.optionList;
|
|
|
+ const inSave = await this.delColumnData(this.getColumnName(140), this.optionList);
|
|
|
+ if (inSave) {
|
|
|
+ this.$message.success("重置成功");
|
|
|
+ for (let item of this.option.column){
|
|
|
+ if (item.prop === 'extraAmountC') return
|
|
|
+ }
|
|
|
+ if (this.roleName.indexOf('平台') !== -1){
|
|
|
+ this.option.column.push(
|
|
|
+ {
|
|
|
+ label:'应付杂费',
|
|
|
+ prop:'extraAmountC',
|
|
|
+ index:12,
|
|
|
+ width:100,
|
|
|
+ overHidden: true,
|
|
|
+ }
|
|
|
+ )
|
|
|
+ }
|
|
|
+ this.$refs.crud.$refs.dialogColumn.columnBox = false;
|
|
|
+ }
|
|
|
+ },
|
|
|
openTrack(row,index){
|
|
|
if (index == 0){
|
|
|
this.$router.push({
|