|
@@ -43,14 +43,14 @@
|
|
<el-option label="请选择字典生成" value="" />
|
|
<el-option label="请选择字典生成" value="" />
|
|
</el-select>
|
|
</el-select>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
- <el-form-item label="油品" prop="oils">
|
|
|
|
|
|
+ <el-form-item label="油品" prop="oilName">
|
|
<el-select
|
|
<el-select
|
|
- v-model="queryParams.oils"
|
|
|
|
|
|
+ v-model="queryParams.oilName"
|
|
placeholder="请选择油品"
|
|
placeholder="请选择油品"
|
|
clearable
|
|
clearable
|
|
size="small">
|
|
size="small">
|
|
<el-option
|
|
<el-option
|
|
- v-for="dict in oilsOptions"
|
|
|
|
|
|
+ v-for="dict in oilNameOptions"
|
|
:key="dict.dictValue"
|
|
:key="dict.dictValue"
|
|
:label="dict.dictLabel"
|
|
:label="dict.dictLabel"
|
|
:value="dict.dictValue"
|
|
:value="dict.dictValue"
|
|
@@ -90,14 +90,14 @@
|
|
|
|
|
|
|
|
|
|
<el-table v-loading="loading" :data="manageList" @selection-change="handleSelectionChange">
|
|
<el-table v-loading="loading" :data="manageList" @selection-change="handleSelectionChange">
|
|
- <el-table-column label="油站名称" align="center" prop="id" v-if="false" />
|
|
|
|
|
|
+ <el-table-column label="客户表id" align="center" prop="id" v-if="false" />
|
|
<el-table-column label="会员id" align="center" prop="memberId" />
|
|
<el-table-column label="会员id" align="center" prop="memberId" />
|
|
<el-table-column label="客户姓名" align="center" prop="customerName" />
|
|
<el-table-column label="客户姓名" align="center" prop="customerName" />
|
|
<el-table-column label="推荐人" align="center" prop="commendMan" />
|
|
<el-table-column label="推荐人" align="center" prop="commendMan" />
|
|
<el-table-column label="会员等级" align="center" prop="memberGrade" />
|
|
<el-table-column label="会员等级" align="center" prop="memberGrade" />
|
|
<el-table-column label="手机号" align="center" prop="phoneNumber" />
|
|
<el-table-column label="手机号" align="center" prop="phoneNumber" />
|
|
<el-table-column label="车牌号" align="center" prop="carNumber" />
|
|
<el-table-column label="车牌号" align="center" prop="carNumber" />
|
|
- <el-table-column label="油品" align="center" prop="oils" />
|
|
|
|
|
|
+ <el-table-column label="油品" align="center" prop="oilName" />
|
|
<el-table-column label="余额" align="center" prop="balance" />
|
|
<el-table-column label="余额" align="center" prop="balance" />
|
|
<el-table-column label="积分" align="center" prop="integral" />
|
|
<el-table-column label="积分" align="center" prop="integral" />
|
|
<el-table-column label="专车类型" align="center" prop="specialCarType" />
|
|
<el-table-column label="专车类型" align="center" prop="specialCarType" />
|
|
@@ -115,16 +115,12 @@
|
|
type="text"
|
|
type="text"
|
|
icon="el-icon-edit"
|
|
icon="el-icon-edit"
|
|
@click="handleUpdate(scope.row)"
|
|
@click="handleUpdate(scope.row)"
|
|
- v-hasPermi="['station:manage:edit']"
|
|
|
|
>编辑</el-button>
|
|
>编辑</el-button>
|
|
<el-button
|
|
<el-button
|
|
size="mini"
|
|
size="mini"
|
|
type="text"
|
|
type="text"
|
|
- icon="el-icon-search
|
|
|
|
-
|
|
|
|
-"
|
|
|
|
- @click=""
|
|
|
|
- v-hasPermi="['station:manage:list']"
|
|
|
|
|
|
+ icon="el-icon-search"
|
|
|
|
+ @click="lookinfo(scope.row)"
|
|
>查询</el-button>
|
|
>查询</el-button>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
@@ -159,10 +155,10 @@
|
|
<el-form-item label="车牌号" prop="carNumber">
|
|
<el-form-item label="车牌号" prop="carNumber">
|
|
<el-input v-model="form.carNumber" placeholder="请输入车牌号" />
|
|
<el-input v-model="form.carNumber" placeholder="请输入车牌号" />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
- <el-form-item label="油品" prop="oils">
|
|
|
|
- <el-select v-model="form.oils" multiple placeholder="请选择">
|
|
|
|
|
|
+ <el-form-item label="油品" prop="oilName">
|
|
|
|
+ <el-select v-model="form.oilName" multiple placeholder="请选择">
|
|
<el-option
|
|
<el-option
|
|
- v-for="dict in oilsOptions"
|
|
|
|
|
|
+ v-for="dict in oilNameOptions"
|
|
:key="dict.dictValue"
|
|
:key="dict.dictValue"
|
|
:label="dict.dictLabel"
|
|
:label="dict.dictLabel"
|
|
:value="dict.dictValue"
|
|
:value="dict.dictValue"
|
|
@@ -212,6 +208,43 @@
|
|
<el-button @click="cancel">取 消</el-button>
|
|
<el-button @click="cancel">取 消</el-button>
|
|
</div>
|
|
</div>
|
|
</el-dialog>
|
|
</el-dialog>
|
|
|
|
+ <el-dialog :title="titleOrderInfo" :visible.sync="openOrderInfo" width="700px" append-to-body>
|
|
|
|
+ <el-table v-loading="loading" :data="orderList" >
|
|
|
|
+ <el-table-column v-if="false" label="订单id" align="center" prop="orderId" />
|
|
|
|
+ <el-table-column label="订单号" width="200" align="center" prop="orderNo" />
|
|
|
|
+ <el-table-column label="油品名称" align="center" prop="oilName" />
|
|
|
|
+ <el-table-column label="油品价格" align="center" prop="oilPirce" />
|
|
|
|
+ <el-table-column label="加油升数" align="center" prop="orderLiters" />
|
|
|
|
+ <el-table-column label="金额" align="center" prop="amt" />
|
|
|
|
+ <el-table-column label="消费者" width="120" align="center" prop="consumer" />
|
|
|
|
+ <el-table-column label="加油员" width="120" align="center" prop="oilPersonnel" />
|
|
|
|
+ <el-table-column label="加油枪号" align="center" prop="oilGun" />
|
|
|
|
+ <el-table-column label="支付类型" align="center" prop="payType" :formatter="payTypeFotmat"/>
|
|
|
|
+ <el-table-column label="油站名称" width="120" align="center" v-if="false" prop="stationName" />
|
|
|
|
+ <el-table-column v-if="false" label="用户id(消费者)" align="center" prop="consumerId" />
|
|
|
|
+ <el-table-column v-if="false" label="油站id" align="center" prop="stationId" />
|
|
|
|
+ <el-table-column label="状态" align="center" prop="status" :formatter="statusFotmat"/>
|
|
|
|
+ <el-table-column label="支付方式" align="center" prop="payWay" :formatter="payWayFotmat"/>
|
|
|
|
+ <el-table-column label="支付时间" align="center" prop="payDate" width="150">
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
+ <span>{{ parseTime(scope.row.payDate, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
|
|
|
|
+ </template>
|
|
|
|
+ </el-table-column>
|
|
|
|
+ <el-table-column label="创建时间" align="center" prop="createdDate" width="150">
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
+ <span>{{ parseTime(scope.row.createdDate, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
|
|
|
|
+ </template>
|
|
|
|
+ </el-table-column>
|
|
|
|
+ <el-table-column label="订单类型" align="center" prop="orderType" v-if="false" />
|
|
|
|
+ </el-table>
|
|
|
|
+ <pagination
|
|
|
|
+ v-show="totalOrder>0"
|
|
|
|
+ :total="totalOrder"
|
|
|
|
+ :page.sync="queryOrder.pageNum"
|
|
|
|
+ :limit.sync="queryOrder.pageSize"
|
|
|
|
+ @pagination="lookinfo"
|
|
|
|
+ />
|
|
|
|
+ </el-dialog>
|
|
</div>
|
|
</div>
|
|
</template>
|
|
</template>
|
|
|
|
|
|
@@ -235,15 +268,19 @@ export default {
|
|
showSearch: true,
|
|
showSearch: true,
|
|
// 总条数
|
|
// 总条数
|
|
total: 0,
|
|
total: 0,
|
|
|
|
+ totalOrder: 0,
|
|
// 客户管理表格数据
|
|
// 客户管理表格数据
|
|
manageList: [],
|
|
manageList: [],
|
|
//油站信息
|
|
//油站信息
|
|
stationOptions:[],
|
|
stationOptions:[],
|
|
|
|
+ orderList:[],
|
|
// 弹出层标题
|
|
// 弹出层标题
|
|
title: "",
|
|
title: "",
|
|
// 是否显示弹出层
|
|
// 是否显示弹出层
|
|
open: false,
|
|
open: false,
|
|
- oilsOptions:[],
|
|
|
|
|
|
+ openOrderInfo: false,
|
|
|
|
+ titleOrderInfo:"",
|
|
|
|
+ oilNameOptions:[],
|
|
// 查询参数
|
|
// 查询参数
|
|
queryParams: {
|
|
queryParams: {
|
|
pageNum: 1,
|
|
pageNum: 1,
|
|
@@ -254,7 +291,7 @@ export default {
|
|
memberGrade: null,
|
|
memberGrade: null,
|
|
phoneNumber: null,
|
|
phoneNumber: null,
|
|
carNumber: null,
|
|
carNumber: null,
|
|
- oils: null,
|
|
|
|
|
|
+ oilName: null,
|
|
balance: null,
|
|
balance: null,
|
|
integral: null,
|
|
integral: null,
|
|
specialCarType: null,
|
|
specialCarType: null,
|
|
@@ -262,6 +299,12 @@ export default {
|
|
stationId: null,
|
|
stationId: null,
|
|
stationNam: null
|
|
stationNam: null
|
|
},
|
|
},
|
|
|
|
+ queryOrder:{
|
|
|
|
+ pageNum: 1,
|
|
|
|
+ pageSize: 10,
|
|
|
|
+ oilName: null,
|
|
|
|
+ stationId: null,
|
|
|
|
+ },
|
|
// 表单参数
|
|
// 表单参数
|
|
form: {},
|
|
form: {},
|
|
// 表单校验
|
|
// 表单校验
|
|
@@ -275,7 +318,7 @@ export default {
|
|
this.stationOptions = response.rows;
|
|
this.stationOptions = response.rows;
|
|
});
|
|
});
|
|
this.getDicts("oil").then(response => {
|
|
this.getDicts("oil").then(response => {
|
|
- this.oilsOptions = response.data;
|
|
|
|
|
|
+ this.oilNameOptions = response.data;
|
|
});
|
|
});
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
@@ -288,21 +331,11 @@ export default {
|
|
this.loading = false;
|
|
this.loading = false;
|
|
});
|
|
});
|
|
},
|
|
},
|
|
- oilsOptionsFotmat(row, column){
|
|
|
|
- if(row.oils === '1'){
|
|
|
|
- return '汽油'
|
|
|
|
- }else if(row.oils === '2'){
|
|
|
|
- return '柴油'
|
|
|
|
- }else if(row.oils === '3'){
|
|
|
|
- return '柴油和汽油'
|
|
|
|
- }
|
|
|
|
- },
|
|
|
|
onInstitutionChang(e){
|
|
onInstitutionChang(e){
|
|
let obj = {};
|
|
let obj = {};
|
|
obj = this.stationOptions.find((item)=>{//这里的userList就是上面遍历的数据源
|
|
obj = this.stationOptions.find((item)=>{//这里的userList就是上面遍历的数据源
|
|
return item.stationId === e;//筛选出匹配数据
|
|
return item.stationId === e;//筛选出匹配数据
|
|
})
|
|
})
|
|
- console.log("油站名称"+obj.stationName);
|
|
|
|
this.form.stationNam=obj.stationName;
|
|
this.form.stationNam=obj.stationName;
|
|
},
|
|
},
|
|
// 取消按钮
|
|
// 取消按钮
|
|
@@ -320,7 +353,7 @@ export default {
|
|
memberGrade: null,
|
|
memberGrade: null,
|
|
phoneNumber: null,
|
|
phoneNumber: null,
|
|
carNumber: null,
|
|
carNumber: null,
|
|
- oils: null,
|
|
|
|
|
|
+ oilName: null,
|
|
balance: null,
|
|
balance: null,
|
|
integral: null,
|
|
integral: null,
|
|
specialCarType: null,
|
|
specialCarType: null,
|
|
@@ -362,6 +395,17 @@ export default {
|
|
this.title = "修改客户管理";
|
|
this.title = "修改客户管理";
|
|
});
|
|
});
|
|
},
|
|
},
|
|
|
|
+ lookinfo(row){
|
|
|
|
+ const id = row.id || this.ids
|
|
|
|
+ this.queryOrder.oilName=row.oilName;
|
|
|
|
+ this.queryOrder.stationId=row.stationId;
|
|
|
|
+ getOrderInfo(this.queryOrder).then(response => {
|
|
|
|
+ this.orderList = response.data;
|
|
|
|
+ this.openOrderInfo = true;
|
|
|
|
+ this.titleOrderInfo = "查看客户订单信息";
|
|
|
|
+ this.loading = false;
|
|
|
|
+ });
|
|
|
|
+ },
|
|
/** 提交按钮 */
|
|
/** 提交按钮 */
|
|
submitForm() {
|
|
submitForm() {
|
|
this.$refs["form"].validate(valid => {
|
|
this.$refs["form"].validate(valid => {
|
|
@@ -408,7 +452,8 @@ export default {
|
|
}).then(response => {
|
|
}).then(response => {
|
|
this.download(response.msg);
|
|
this.download(response.msg);
|
|
})
|
|
})
|
|
- }
|
|
|
|
|
|
+ },
|
|
|
|
+
|
|
}
|
|
}
|
|
};
|
|
};
|
|
</script>
|
|
</script>
|