Commit 0cb22bf1 by liwk

e代驾&加油站订单

1 parent ec36b966
......@@ -32,6 +32,14 @@ export const orderApi = {
getRefundDetail(data = {}) {
return request(data, 'dj.api.get.equity.order.refund.detail.get')
},
/** 获取e代驾订单列表*/
getEDJOrderList(data = {}) {
return request(data, 'dj.api.scrm.edj.orderList')
},
/** 分页获取订单列表*/
getOilOrderList(data = {}) {
return request(data, 'dj.api.scrm.oil.orderPage')
},
}
// export const orderApi = {
// /**获取财务管理列表*/
......
import orderMixin from './orderMixin'
import searchMixin from './searchMixin'
export {
orderMixin
orderMixin,
searchMixin
}
\ No newline at end of file
export default {
data() {
return {
date: '',
searchObj: {},
statusEnum: {
0: '未支付',
1: '已支付',
......@@ -49,26 +47,7 @@ export default {
this.searchObj.orderDateEnd = orderDateEnd ? `${orderDateEnd} 23:59:59` : ''
}
},
mounted() {
let that = this
document.onkeydown = () => {
let key = window.event.keyCode
if (key == 13) {
that.search()
}
}
},
methods: {
search() {
this.$refs.table.refreshTable()
},
reset() {
this.date = ''
this.searchObj = {}
this.$nextTick(() => {
this.search()
})
},
handleClick({ name, $parent: { $el } }) {
let { target } = $el.dataset
let orderStatus = name ? name.split(',').map(e => Number(e)) : ''
......
export default {
data() {
return {
date: '',
searchObj: {},
}
},
mounted() {
let that = this
document.onkeydown = () => {
let key = window.event.keyCode
if (key == 13) {
that.search()
}
}
},
methods: {
search() {
this.$refs.table.refreshTable()
},
reset() {
this.date = ''
this.searchObj = {}
this.$nextTick(() => {
this.search()
})
},
},
}
\ No newline at end of file
......@@ -5,7 +5,7 @@
<div class="item">
日期:
<el-date-picker
v-model="searchObj.date"
v-model="date"
type="daterange"
range-separator="至"
start-placeholder="开始日期"
......@@ -19,7 +19,7 @@
订单号:
<div class="input">
<el-input
v-model="searchObj.no"
v-model="searchObj.orderId"
placeholder=""
size="small"
></el-input>
......@@ -29,7 +29,7 @@
用户信息:
<div class="input">
<el-input
v-model="searchObj.user"
v-model="searchObj.phone"
placeholder=""
size="small"
></el-input>
......@@ -38,7 +38,7 @@
<div class="item">
订单状态:
<el-select
v-model="searchObj.status"
v-model="searchObj.orderStatus"
placeholder="请选择"
>
<el-option
......@@ -53,107 +53,97 @@
</div>
<div class="bottom">
<el-button-group>
<el-button type="primary">查询</el-button>
<el-button type="default">重置</el-button>
<el-button
type="primary"
@click="search"
>查询</el-button>
<el-button
type="default"
@click="reset"
>重置</el-button>
</el-button-group>
</div>
</div>
<div class="table-box">
<d2-table
ref="table"
:searchForm="searchObj"
:tableParams="tableParams"
:getListApi="listRequisitionMemberCard"
:getListApi="tableParams.getListApi"
:hasNum="false"
>
<span
slot="auth-button"
slot-scope="scope"
:data="scope.scope"
>
<el-button
type="text"
@click="startcollectiondetails(scope.scope)"
>查看详情</el-button>
</span>
</d2-table>
</div>
</div>
</template>
<script type='text/ecmascript-6'>
import { orderApi } from '@api/api'
import { searchMixin } from '@/mixins'
export default {
name: '',
mixins: [searchMixin],
data () {
return {
searchObj: {
status: 1
},
statusList: [{
label: '已结算',
value: 1
value: 0
}, {
label: '待结算',
value: 2
value: 1
}, {
label: '已失效',
value: 3
value: 2
}],
tableParams: {
listName: 'list',
getListApi: orderApi.getEDJOrderList,
tableColumns: [
{
label: '日期',
prop: 'validitDate',
minWidth: '200',
formatter: (cellValue) => {
formatter: (cell) => {
return new Date(cell.callTime).format('yyyy-MM-dd hh:mm:ss')
}
},
{
label: '用户信息',
prop: 'cardNo',
prop: 'phone',
minWidth: '200'
},
{
label: '订单里程',
prop: 'activationCode',
minWidth: '200',
formatter: (cell) => {
return `${cell.distance}km`
}
},
{
label: '实付金额',
prop: 'sn',
prop: 'price',
minWidth: '200',
},
{
label: '订单总额',
prop: 'mobile',
prop: 'income',
minWidth: '200'
// tagLabel: true
},
{
label: '订单号',
prop: 'memberName',
prop: 'orderId',
minWidth: '200',
formatter: (cellValue) => {
return cellValue.memberCardDefine.memberName
}
},
{
label: '司机工号',
prop: 'updatedDate',
prop: 'driverId',
minWidth: '200',
formatter: (cellValue) => {
return this.date_format(cellValue.updatedDate)
}
},
{
label: '订单状态',
prop: 'status',
formatter: (cellValue) => {
return {
1: '已激活',
0: '未激活'
}[cellValue.status]
formatter: (cell) => {
return ['已结算', '待结算', '已失效'][cell.orderStatus]
},
minWidth: '200'
}
......@@ -161,6 +151,13 @@ export default {
}
}
},
watch: {
'date' (n) {
let [callDateStart, callDateEnd] = n
this.searchObj.callDateStart = callDateStart || ''
this.searchObj.callDateEnd = callDateEnd || ''
}
},
mounted () {
},
methods: {
......
......@@ -131,10 +131,10 @@
<script type='text/ecmascript-6'>
import { orderApi } from '@api/api'
import { orderMixin } from '@/mixins'
import { orderMixin, searchMixin } from '@/mixins'
export default {
name: '',
mixins: [orderMixin],
mixins: [orderMixin, searchMixin],
data () {
return {
price: 0,
......
......@@ -5,7 +5,7 @@
<div class="item">
加油日期:
<el-date-picker
v-model="searchObj.date"
v-model="date"
type="daterange"
range-separator="至"
start-placeholder="开始日期"
......@@ -17,8 +17,11 @@
</div>
<div class="item">
加油供应商:
<el-select>
<el-option label="团油">
<el-select :value="'团油'">
<el-option
label="团油"
value="团油"
>
</el-option>
</el-select>
</div>
......@@ -26,7 +29,7 @@
供应商订单号:
<div class="input">
<el-input
v-model="searchObj.no"
v-model="searchObj.orderId"
placeholder=""
size="small"
></el-input>
......@@ -36,7 +39,7 @@
加油用户:
<div class="input">
<el-input
v-model="searchObj.user"
v-model="searchObj.phone"
placeholder=""
size="small"
></el-input>
......@@ -45,7 +48,7 @@
<div class="item">
订单状态:
<el-select
v-model="searchObj.status"
v-model="searchObj.orderStatus"
placeholder="请选择"
>
<el-option
......@@ -67,107 +70,114 @@
</div>
<div class="table-box">
<d2-table
ref="table"
:searchForm="searchObj"
:tableParams="tableParams"
:getListApi="listRequisitionMemberCard"
:getListApi="tableParams.getListApi"
:hasNum="false"
>
<span
slot="auth-button"
slot-scope="scope"
:data="scope.scope"
>
<el-button
type="text"
@click="startcollectiondetails(scope.scope)"
>查看详情</el-button>
</span>
</d2-table>
</div>
</div>
</template>
<script type='text/ecmascript-6'>
import { orderApi } from '@api/api'
import { searchMixin } from '@/mixins'
export default {
name: '',
mixins: [searchMixin],
data () {
return {
searchObj: {
status: 1
},
statusList: [{
label: '已结算',
label: '已支付',
value: 1
}, {
label: '待结算',
value: 2
label: '退款申请中',
value: 4
}, {
label: '已失效',
value: 3
label: '已退款',
value: 5
}, {
label: '退款失败',
value: 6
}],
tableParams: {
listName: 'list',
getListApi: orderApi.getOilOrderList,
tableColumns: [
{
label: '日期',
prop: 'validitDate',
label: '加油时间',
prop: 'orderTime',
minWidth: '200',
formatter: (cellValue) => {
},
{
label: '供应商',
minWidth: '200',
formatter: (cell) => {
return '团油'
}
},
{
label: '用户信息',
prop: 'cardNo',
minWidth: '200'
label: '加油油站',
prop: 'gasName',
minWidth: '200',
},
{
label: '订单里程',
prop: 'activationCode',
label: '油号',
minWidth: '200',
formatter: (cell) => {
return `${cell.oilNo}#`
}
},
{
label: '加油升数(L)',
prop: 'litre',
minWidth: '200'
},
{
label: '实付金额',
prop: 'sn',
prop: 'amountPay',
minWidth: '200',
},
{
label: '订单总额',
prop: 'mobile',
minWidth: '200'
// tagLabel: true
prop: 'amountGun',
minWidth: '200',
},
{
label: '订单号',
prop: 'memberName',
label: '优惠金额',
prop: 'amountDiscounts',
minWidth: '200',
formatter: (cellValue) => {
return cellValue.memberCardDefine.memberName
}
},
{
label: '司机工号',
prop: 'updatedDate',
label: '订单状态',
prop: 'orderStatusName',
minWidth: '200'
},
{
label: '用户信息',
prop: 'phone',
minWidth: '200',
formatter: (cellValue) => {
return this.date_format(cellValue.updatedDate)
formatter: (cell) => {
}
},
{
label: '订单状态',
prop: 'status',
formatter: (cellValue) => {
return {
1: '已激活',
0: '未激活'
}[cellValue.status]
},
minWidth: '200'
}
label: '供应商订单号',
prop: 'orderId',
minWidth: '200',
},
]
}
}
},
watch: {
'date' (n) {
let [beginTime, endTime] = n
this.searchObj.beginTime = beginTime || ''
this.searchObj.endTime = endTime || ''
}
},
mounted () {
},
methods: {
......
......@@ -108,9 +108,6 @@ export default {
name: '',
data () {
return {
searchObj: {
status: 1
},
statusList: [{
label: '已结算',
value: 1
......
......@@ -141,10 +141,10 @@
<script type='text/ecmascript-6'>
import { orderApi } from '@api/api'
import { orderMixin } from '@/mixins'
import { orderMixin, searchMixin } from '@/mixins'
export default {
name: '',
mixins: [orderMixin],
mixins: [orderMixin, searchMixin],
data () {
return {
tabIndex: '',
......
......@@ -48,8 +48,8 @@
<el-image
class="img-describe"
:key="index"
:src="detailInfo.img"
:preview-src-list="[detailInfo.img]"
:src="detailInfo.goodImg"
:preview-src-list="[detailInfo.goodImg]"
>
</el-image>
<div class="info">
......
......@@ -133,20 +133,17 @@
</span>
</d2-table>
</div>
</div>
</template>
<script type='text/ecmascript-6'>
import { orderApi } from '@api/api'
import { orderMixin } from '@/mixins'
import { orderMixin, searchMixin } from '@/mixins'
export default {
name: '',
mixins: [orderMixin],
mixins: [orderMixin, searchMixin],
data () {
return {
searchObj: {
},
tabIndex: '',
tableParams: {
listName: 'list',
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!