Merge remote-tracking branch 'origin/anhui-mall-ui-test' into anhui-mall-ui-test
This commit is contained in:
commit
5db7236523
|
|
@ -59,7 +59,37 @@ export const outAll = (data = {}) => {
|
|||
})
|
||||
}
|
||||
|
||||
|
||||
export const orderOut = (data = {}) => {
|
||||
return request({
|
||||
url: '/material-mall/decChange/orderOut',
|
||||
method: 'post',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
export const orderOutCancel = (data = {}) => {
|
||||
return request({
|
||||
url: '/material-mall/decChange/orderOutCancel',
|
||||
method: 'post',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
export const orderOutCancelAll = (data = {}) => {
|
||||
return request({
|
||||
url: '/material-mall/decChange/orderOutCancelAll',
|
||||
method: 'post',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
export const orderOutAll = (data = {}) => {
|
||||
return request({
|
||||
url: '/material-mall/decChange/orderOutAll',
|
||||
method: 'post',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -2,75 +2,75 @@
|
|||
<div class="app-container app-container-content">
|
||||
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="auto">
|
||||
<el-card class="search-box">
|
||||
<el-row>
|
||||
<el-col :span="24" style="display: flex; justify-content: space-between">
|
||||
<el-col span="5" style="width: 320px">
|
||||
<el-form-item prop="deviceName" label="装备名称" >
|
||||
<el-input
|
||||
v-model="queryParams.deviceName"
|
||||
placeholder="请输入装备名称"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
maxlength="20"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col span="5" style="width: 320px">
|
||||
<el-form-item prop="orderStatus" label="订单状态">
|
||||
<el-select v-model="queryParams.orderStatus" placeholder="请选择订单状态" clearable>
|
||||
<el-option
|
||||
v-for="item in statusList"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
<el-row>
|
||||
<el-col :span="24" style="display: flex; justify-content: space-between">
|
||||
<el-col span="5" style="width: 320px">
|
||||
<el-form-item prop="deviceName" label="装备名称">
|
||||
<el-input
|
||||
v-model="queryParams.deviceName"
|
||||
placeholder="请输入装备名称"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
maxlength="20"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col span="5" style="width: 320px">
|
||||
<el-form-item prop="orderStatus" label="订单状态">
|
||||
<el-select v-model="queryParams.orderStatus" placeholder="请选择订单状态" clearable>
|
||||
<el-option
|
||||
v-for="item in statusList"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
|
||||
<el-col span="5">
|
||||
<el-form-item prop="dateRange" label="出库日期">
|
||||
<el-date-picker
|
||||
v-model="time"
|
||||
type="daterange"
|
||||
value-format="yyyy-MM-dd"
|
||||
range-separator="至"
|
||||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"
|
||||
style="width: 240px"
|
||||
>
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col span="5" style="width: 320px">
|
||||
<el-form-item prop="czcompanyName" label="出租单位">
|
||||
<el-input
|
||||
v-model="queryParams.czcompanyName"
|
||||
placeholder="请输入出租单位"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
maxlength="20"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col span="5" style="width: 320px">
|
||||
<el-form-item prop="companyName" label="承租单位">
|
||||
<el-input
|
||||
v-model="queryParams.companyName"
|
||||
placeholder="请输入承租单位"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
maxlength="20"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
</el-col>
|
||||
|
||||
|
||||
<el-col span="5">
|
||||
<el-form-item prop="dateRange" label="出库日期">
|
||||
<el-date-picker
|
||||
v-model="time"
|
||||
type="daterange"
|
||||
value-format="yyyy-MM-dd"
|
||||
range-separator="至"
|
||||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"
|
||||
style="width: 240px"
|
||||
>
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col span="5" style="width: 320px">
|
||||
<el-form-item prop="czcompanyName" label="出租单位">
|
||||
<el-input
|
||||
v-model="queryParams.czcompanyName"
|
||||
placeholder="请输入出租单位"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
maxlength="20"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<el-col span="5" style="width: 320px">
|
||||
<el-form-item prop="companyName" label="承租单位">
|
||||
<el-input
|
||||
v-model="queryParams.companyName"
|
||||
placeholder="请输入承租单位"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
maxlength="20"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-row>
|
||||
|
||||
|
||||
<el-row>
|
||||
|
|
@ -83,118 +83,117 @@
|
|||
</el-row>
|
||||
|
||||
|
||||
|
||||
<!-- <el-form-item prop="lowerBound">
|
||||
<el-input
|
||||
v-model.trim="queryParams.lowerBound"
|
||||
placeholder="租金/元"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
maxlength="20"
|
||||
style="width:100px"
|
||||
/>
|
||||
<span> ——</span>
|
||||
</el-form-item>-->
|
||||
<!-- <el-form-item prop="upperBound">
|
||||
<el-input
|
||||
v-model.trim="queryParams.upperBound"
|
||||
placeholder="租金/元"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
maxlength="20"
|
||||
style="width:100px"
|
||||
/>
|
||||
</el-form-item>-->
|
||||
</el-card>
|
||||
<!-- <el-form-item prop="lowerBound">
|
||||
<el-input
|
||||
v-model.trim="queryParams.lowerBound"
|
||||
placeholder="租金/元"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
maxlength="20"
|
||||
style="width:100px"
|
||||
/>
|
||||
<span> ——</span>
|
||||
</el-form-item>-->
|
||||
<!-- <el-form-item prop="upperBound">
|
||||
<el-input
|
||||
v-model.trim="queryParams.upperBound"
|
||||
placeholder="租金/元"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
maxlength="20"
|
||||
style="width:100px"
|
||||
/>
|
||||
</el-form-item>-->
|
||||
</el-card>
|
||||
</el-form>
|
||||
<el-card class="content-box">
|
||||
<div class="table-container">
|
||||
<template v-if="cardList.length > 0">
|
||||
<div class="cart-tbody" v-for="(item, index) in cardList" :key="index">
|
||||
<el-row class="order-title-info">
|
||||
<el-col :span="8">
|
||||
<span> <i class="el-icon-document-copy"></i>订单编号: </span>
|
||||
<span>
|
||||
<div class="table-container">
|
||||
<template v-if="cardList.length > 0">
|
||||
<div class="cart-tbody" v-for="(item, index) in cardList" :key="index">
|
||||
<el-row class="order-title-info">
|
||||
<el-col :span="8">
|
||||
<span> <i class="el-icon-document-copy"></i>订单编号: </span>
|
||||
<span>
|
||||
{{ item.code }}
|
||||
</span>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<span> 下单时间: </span>
|
||||
<span>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<span> 下单时间: </span>
|
||||
<span>
|
||||
{{ item.orderTime }}
|
||||
</span>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<span> 装备所属公司: </span>
|
||||
<span>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<span> 装备所属公司: </span>
|
||||
<span>
|
||||
{{ item.czcompanyName }}
|
||||
</span>
|
||||
</el-col>
|
||||
<div class="order-type-box">
|
||||
<el-tag
|
||||
:type="orderType(item.orderStatus)"
|
||||
effect="light"
|
||||
>{{ orderText(item.orderStatus) }}
|
||||
</el-tag
|
||||
>
|
||||
</div>
|
||||
</el-row>
|
||||
<el-row class="order-title-info">
|
||||
<el-col :span="8">
|
||||
<span> 出租方联系电话: </span>
|
||||
<span>
|
||||
</el-col>
|
||||
<div class="order-type-box">
|
||||
<el-tag
|
||||
:type="orderType(item.orderStatus)"
|
||||
effect="light"
|
||||
>{{ orderText(item.orderStatus) }}
|
||||
</el-tag
|
||||
>
|
||||
</div>
|
||||
</el-row>
|
||||
<el-row class="order-title-info">
|
||||
<el-col :span="8">
|
||||
<span> 出租方联系电话: </span>
|
||||
<span>
|
||||
{{ item.personPhone }}
|
||||
</span>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<span> 承租方联系电话: </span>
|
||||
<span>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<span> 承租方联系电话: </span>
|
||||
<span>
|
||||
{{ item.phoneNumber }}
|
||||
</span>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<span> 收货地址: </span>
|
||||
<span>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<span> 收货地址: </span>
|
||||
<span>
|
||||
{{ item.address }}
|
||||
</span>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row
|
||||
style="border-bottom: 1px solid #ccc; margin-bottom: 10px"
|
||||
class="order-title-info"
|
||||
>
|
||||
<el-col :span="8">
|
||||
<span> 出租方姓名: </span>
|
||||
<span> {{ item.sellerName }} </span>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<span> 承租方姓名: </span>
|
||||
<span> {{ item.buyerName }} </span>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<span> 承租方所属单位: </span>
|
||||
<span>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row
|
||||
style="border-bottom: 1px solid #ccc; margin-bottom: 10px"
|
||||
class="order-title-info"
|
||||
>
|
||||
<el-col :span="8">
|
||||
<span> 出租方姓名: </span>
|
||||
<span> {{ item.sellerName }} </span>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<span> 承租方姓名: </span>
|
||||
<span> {{ item.buyerName }} </span>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<span> 承租方所属单位: </span>
|
||||
<span>
|
||||
{{ item.companyName }}
|
||||
</span>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<el-row :gutter="10">
|
||||
<el-col :span="12">
|
||||
<div
|
||||
v-for="(goods, j) in item.detailsList"
|
||||
:key="j"
|
||||
class="order-items order-info"
|
||||
:style="
|
||||
<el-row :gutter="10">
|
||||
<el-col :span="12">
|
||||
<div
|
||||
v-for="(goods, j) in item.detailsList"
|
||||
:key="j"
|
||||
class="order-items order-info"
|
||||
:style="
|
||||
j != item.detailsList.length - 1
|
||||
? 'border-bottom:1px solid #f0f0f0'
|
||||
: ''
|
||||
"
|
||||
style="min-height: 80px"
|
||||
>
|
||||
<img :src="goods.url" style="width: 110px; height: 70px" alt=""/>
|
||||
<div
|
||||
style="
|
||||
style="min-height: 80px"
|
||||
>
|
||||
<img :src="goods.url" style="width: 110px; height: 70px" alt=""/>
|
||||
<div
|
||||
style="
|
||||
min-height: 80px;
|
||||
flex: 1;
|
||||
display: flex;
|
||||
|
|
@ -203,13 +202,13 @@
|
|||
padding-left: 12px;
|
||||
font-size: 13px;
|
||||
"
|
||||
>
|
||||
<el-row style="color: #169bd5; font-weight: bold">
|
||||
{{ goods.deviceName }}
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="4"> 租期 : {{ goods.days }}{{ ' ' + '天' }}</el-col>
|
||||
<el-col :span="8">
|
||||
>
|
||||
<el-row style="color: #169bd5; font-weight: bold">
|
||||
{{ goods.deviceName }}
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="4"> 租期 : {{ goods.days }}{{ ' ' + '天' }}</el-col>
|
||||
<el-col :span="8">
|
||||
<span
|
||||
style="margin-right: 10px"
|
||||
:style="
|
||||
|
|
@ -220,122 +219,132 @@
|
|||
>
|
||||
|
||||
</span>
|
||||
<span v-if="item.orderStatus == 20">
|
||||
<span v-if="item.orderStatus == 20">
|
||||
{{
|
||||
momentInit(goods.takeOverTime).diff(
|
||||
goods.rentOverTime,
|
||||
'day'
|
||||
) == 0
|
||||
? 1
|
||||
: momentInit(goods.takeOverTime).diff(
|
||||
goods.rentOverTime,
|
||||
'day'
|
||||
)
|
||||
}}{{ ' ' + '天' }}
|
||||
momentInit(goods.takeOverTime).diff(
|
||||
goods.rentOverTime,
|
||||
'day'
|
||||
) == 0
|
||||
? 1
|
||||
: momentInit(goods.takeOverTime).diff(
|
||||
goods.rentOverTime,
|
||||
'day'
|
||||
)
|
||||
}}{{ ' ' + '天' }}
|
||||
</span>
|
||||
|
||||
<!-- {{ goods.days }}{{ ' ' + '天' }} -->
|
||||
</el-col>
|
||||
<el-col :span="4"> 编号</el-col>
|
||||
<el-col :span="8"> {{ goods.code }}</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<!-- <el-col :span="4"> 租金</el-col>
|
||||
<el-col :span="8">
|
||||
{{ goods.dayLeasePrice }}{{ ' ' + '元/天' }}
|
||||
</el-col>-->
|
||||
<el-col :span="6"> 数量 : {{ goods.num }}{{ ' ' + '台' }}</el-col>
|
||||
<el-col :span="10"> </el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
</div>
|
||||
</el-col>
|
||||
<!-- <el-col :span="3" class="order-items-info">
|
||||
<div>总费用</div>
|
||||
<!-- {{ goods.days }}{{ ' ' + '天' }} -->
|
||||
</el-col>
|
||||
<el-col :span="4"> 编号</el-col>
|
||||
<el-col :span="8"> {{ goods.code }}</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<!-- <el-col :span="4"> 租金</el-col>
|
||||
<el-col :span="8">
|
||||
{{ goods.dayLeasePrice }}{{ ' ' + '元/天' }}
|
||||
</el-col>-->
|
||||
<el-col :span="6"> 数量 : {{ goods.num }}{{ ' ' + '台' }}</el-col>
|
||||
<el-col :span="10"></el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
</div>
|
||||
</el-col>
|
||||
<!-- <el-col :span="3" class="order-items-info">
|
||||
<div>总费用</div>
|
||||
|
||||
<div
|
||||
class="red-font"
|
||||
:style="item.orderStatus == 20 ? 'text-decoration: line-through' : ''"
|
||||
>
|
||||
{{ item.cost }} 元
|
||||
</div>
|
||||
<div class="red-font" v-if="item.orderStatus == 20">
|
||||
{{ item.totalRealPrice }} 元
|
||||
</div>
|
||||
</el-col>-->
|
||||
<el-col :span="8" class="order-items-info">
|
||||
<div
|
||||
v-for="(goods, j) in item.detailsList"
|
||||
:key="j"
|
||||
class="order-info"
|
||||
:style="
|
||||
<div
|
||||
class="red-font"
|
||||
:style="item.orderStatus == 20 ? 'text-decoration: line-through' : ''"
|
||||
>
|
||||
{{ item.cost }} 元
|
||||
</div>
|
||||
<div class="red-font" v-if="item.orderStatus == 20">
|
||||
{{ item.totalRealPrice }} 元
|
||||
</div>
|
||||
</el-col>-->
|
||||
<el-col :span="8" class="order-items-info">
|
||||
<div
|
||||
v-for="(goods, j) in item.detailsList"
|
||||
:key="j"
|
||||
class="order-info"
|
||||
:style="
|
||||
j != item.detailsList.length - 1
|
||||
? 'border-bottom:1px solid #f0f0f0'
|
||||
: ''
|
||||
"
|
||||
style="min-height: 80px"
|
||||
>
|
||||
<div
|
||||
style="
|
||||
style="min-height: 80px"
|
||||
>
|
||||
<div
|
||||
style="
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
flex-direction: column;
|
||||
"
|
||||
>
|
||||
<div>租期</div>
|
||||
<div
|
||||
style="font-weight: bold; margin-top: 10px"
|
||||
:style="
|
||||
>
|
||||
<div>租期</div>
|
||||
<div
|
||||
style="font-weight: bold; margin-top: 10px"
|
||||
:style="
|
||||
item.orderStatus == 20
|
||||
? 'text-decoration: line-through'
|
||||
: ''
|
||||
"
|
||||
>
|
||||
{{ formatDate(goods.rentBeginTime) }}至{{ formatDate(goods.rentEndTime) }}
|
||||
>
|
||||
{{ formatDate(goods.rentBeginTime) }}至{{ formatDate(goods.rentEndTime) }}
|
||||
</div>
|
||||
|
||||
<div
|
||||
style="font-weight: bold; margin-top: 10px"
|
||||
v-if="item.orderStatus == 20"
|
||||
>
|
||||
{{ goods.takeOverTime ? goods.takeOverTime.slice(0, 10) : '' }}至
|
||||
{{ goods.rentOverTime ? goods.rentOverTime.slice(0, 10) : '' }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</el-col>
|
||||
|
||||
<div
|
||||
style="font-weight: bold; margin-top: 10px"
|
||||
v-if="item.orderStatus == 20"
|
||||
>
|
||||
{{ goods.takeOverTime ? goods.takeOverTime.slice(0, 10) : '' }}至
|
||||
{{ goods.rentOverTime ? goods.rentOverTime.slice(0, 10) : '' }}
|
||||
<el-col :span="4">
|
||||
<div class="handle-btn">
|
||||
<!-- <el-button @click="handleViewOrder(item)" type="primary" size="small">
|
||||
订单详情
|
||||
</el-button> -->
|
||||
<el-button v-show="item.orderStatus =='1'" @click="handleConfirm(item)" type="success" plain
|
||||
size="small"
|
||||
>
|
||||
同意
|
||||
</el-button>
|
||||
<el-button v-show="item.orderStatus =='1'" @click="handelReject(item)" type="warning" plain
|
||||
size="small"
|
||||
>
|
||||
不同意
|
||||
</el-button>
|
||||
|
||||
<el-button type="primary" plain size="small" @click="handleApprove(item)"
|
||||
>查看
|
||||
</el-button
|
||||
>
|
||||
<el-button v-show="item.orderStatus =='2' && item.taskStatus != '3'" @click="handleOut(item)"
|
||||
type="primary" plain size="small"
|
||||
>
|
||||
共享出库
|
||||
</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</el-col>
|
||||
|
||||
<el-col :span="4">
|
||||
<div class="handle-btn">
|
||||
<!-- <el-button @click="handleViewOrder(item)" type="primary" size="small">
|
||||
订单详情
|
||||
</el-button> -->
|
||||
<el-button v-show="item.orderStatus =='1'" @click="handleConfirm(item)" type="success" plain size="small">
|
||||
同意
|
||||
</el-button>
|
||||
<el-button v-show="item.orderStatus =='1'" @click="handelReject(item)" type="warning" plain size="small">
|
||||
不同意
|
||||
</el-button>
|
||||
|
||||
<el-button v-show="item.orderStatus =='2'" @click="handleOut(item)" type="primary" plain size="small">
|
||||
共享出库
|
||||
</el-button>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
</template>
|
||||
</div>
|
||||
<div class="pagination-wrapper">
|
||||
<pagination
|
||||
v-show="total > 0"
|
||||
:total="total"
|
||||
:page.sync="queryParams.pageNum"
|
||||
:limit.sync="queryParams.pageSize"
|
||||
@pagination="getList"
|
||||
/>
|
||||
</div>
|
||||
</template>
|
||||
</div>
|
||||
<div class="pagination-wrapper">
|
||||
<pagination
|
||||
v-show="total > 0"
|
||||
:total="total"
|
||||
:page.sync="queryParams.pageNum"
|
||||
:limit.sync="queryParams.pageSize"
|
||||
@pagination="getList"
|
||||
/>
|
||||
</div>
|
||||
</el-card>
|
||||
<el-dialog
|
||||
:title="dialogTitle"
|
||||
|
|
@ -661,7 +670,7 @@ export default {
|
|||
[
|
||||
{ id: '1', name: '待确认' },
|
||||
{ id: '2', name: '已确认' },
|
||||
{ id: '3', name: '已驳回' },
|
||||
{ id: '3', name: '已驳回' }
|
||||
],
|
||||
ids: [],
|
||||
// 总条数
|
||||
|
|
@ -762,7 +771,7 @@ export default {
|
|||
if (res.code == '200') {
|
||||
item.orderStatus = '2'
|
||||
this.$message.success(res.msg)
|
||||
}else {
|
||||
} else {
|
||||
this.$message.error(res.msg)
|
||||
}
|
||||
})
|
||||
|
|
@ -781,8 +790,13 @@ export default {
|
|||
},
|
||||
handleOut(item) {
|
||||
console.log('🚀 ~ item:', item)
|
||||
this.$router.push({ path: '/equipmentShared/order/sharedOutList', query: { id: item.orderId, isView: true } })
|
||||
},
|
||||
|
||||
handleApprove(item) {
|
||||
this.$router.push({ path: '/equipmentShared/order/sharedOutList', query: { id: item.orderId } })
|
||||
},
|
||||
|
||||
//订单详情
|
||||
handleViewOrder(row) {
|
||||
this.showOrderDetail = true
|
||||
|
|
@ -892,16 +906,14 @@ export default {
|
|||
margin-bottom: 14px;
|
||||
border-radius: 10px;
|
||||
border: 1px solid #169bd5;
|
||||
box-shadow:
|
||||
0 0 0 1px rgba(22, 155, 213, 0.2),
|
||||
0 0 8px rgba(22, 155, 213, 0.3);
|
||||
box-shadow: 0 0 0 1px rgba(22, 155, 213, 0.2),
|
||||
0 0 8px rgba(22, 155, 213, 0.3);
|
||||
transition: all 0.3s ease;
|
||||
|
||||
&:hover {
|
||||
border-color: #0d7aa8;
|
||||
box-shadow:
|
||||
0 0 0 2px rgba(22, 155, 213, 0.3),
|
||||
0 0 12px rgba(22, 155, 213, 0.4);
|
||||
box-shadow: 0 0 0 2px rgba(22, 155, 213, 0.3),
|
||||
0 0 12px rgba(22, 155, 213, 0.4);
|
||||
}
|
||||
|
||||
.cart-user-info {
|
||||
|
|
@ -1002,6 +1014,7 @@ export default {
|
|||
span:first-child {
|
||||
color: #666;
|
||||
}
|
||||
|
||||
span + span {
|
||||
color: #333;
|
||||
}
|
||||
|
|
@ -1044,7 +1057,6 @@ export default {
|
|||
}
|
||||
|
||||
|
||||
|
||||
.handle-btn-4 {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
|
|
@ -1100,13 +1112,14 @@ export default {
|
|||
margin-bottom: 20px;
|
||||
border-radius: 8px;
|
||||
padding: 0;
|
||||
|
||||
::v-deep .el-card__body {
|
||||
padding: 20px !important;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.el-form-item--small.el-form-item {
|
||||
margin-bottom: 0px;
|
||||
margin-bottom: 0px;
|
||||
}
|
||||
|
||||
.content-box {
|
||||
|
|
@ -1149,7 +1162,7 @@ export default {
|
|||
padding-top: 6px;
|
||||
margin-top: auto;
|
||||
|
||||
::v-deep .pagination-container {
|
||||
::v-deep .pagination-container {
|
||||
padding: 0px 20px !important;
|
||||
margin-bottom: 30px;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,20 +2,38 @@
|
|||
<!-- 基础页面 -->
|
||||
<div class="app-container">
|
||||
<el-card v-show="showSearch" style="margin-bottom: 20px">
|
||||
<el-form :model="queryParams" ref="queryForm" size="small" inline label-width="110px">
|
||||
<el-form :model="queryParams" ref="queryForm" size="small" inline label-width="100px">
|
||||
|
||||
<el-form-item label="需求单位" prop="useUnit">
|
||||
<el-input v-model="queryParams.useUnit" style="width: 200px" placeholder="需求单位" disabled />
|
||||
<el-input v-model="queryParams.useUnit" style="width: 200px" placeholder="请输入需求单位"
|
||||
:disabled="queryParams.status=='0'"
|
||||
clearable
|
||||
/>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="使用项目" prop="proName">
|
||||
<el-input v-model="queryParams.proName" style="width: 200px" placeholder="使用项目" disabled />
|
||||
<el-form-item label="使用项目" prop="proCode">
|
||||
<el-select
|
||||
clearable
|
||||
style="width: 200px"
|
||||
disabled
|
||||
placeholder="请选择使用项目"
|
||||
v-model="queryParams.proCode"
|
||||
@change="onChangeProCode"
|
||||
>
|
||||
<el-option
|
||||
:key="item.proCode"
|
||||
:label="item.proName"
|
||||
:value="item.proCode"
|
||||
v-for="item in useProjectList"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="项目类型" prop="proType">
|
||||
<el-select disabled style="width: 200px" placeholder="请选择项目类型" v-model="queryParams.proType">
|
||||
<el-option value="0" label="线路" />
|
||||
<el-option value="1" label="电缆" />
|
||||
<el-option value="2" label="变电" />
|
||||
<el-select clearable disabled style="width: 200px" placeholder="请选择项目类型" v-model="queryParams.proType">
|
||||
<el-option value="0" label="线路"/>
|
||||
<el-option value="1" label="电缆"/>
|
||||
<el-option value="2" label="变电"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
||||
|
|
@ -27,33 +45,81 @@
|
|||
placeholder="请选择电压等级"
|
||||
v-model="queryParams.voltageLevel"
|
||||
>
|
||||
<el-option :key="item.value" :value="item.value" :label="item.label" v-for="item in voltageList" />
|
||||
<el-option
|
||||
:key="item.voltage"
|
||||
:value="item.voltage"
|
||||
:label="`${item.voltage}kV`"
|
||||
v-for="item in voltageList"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="项目所在省" prop="proProvince">
|
||||
<el-input v-model="queryParams.proProvince" style="width: 200px" placeholder="项目所在省" disabled />
|
||||
<el-select
|
||||
clearable
|
||||
style="width: 200px"
|
||||
disabled
|
||||
placeholder="请选择项目所在省"
|
||||
v-model="queryParams.proProvince"
|
||||
@change="onChangeProvince"
|
||||
>
|
||||
<el-option
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.label"
|
||||
v-for="item in provinceList"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="项目所在市" prop="proCity">
|
||||
<el-input v-model="queryParams.proCity" style="width: 200px" placeholder="项目所在市" disabled />
|
||||
<el-select
|
||||
clearable
|
||||
style="width: 200px"
|
||||
disabled
|
||||
placeholder="请选择项目所在市"
|
||||
v-model="queryParams.proCity"
|
||||
@change="onChangeCity"
|
||||
>
|
||||
<el-option
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.label"
|
||||
v-for="item in cityList"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="项目所在区/县" prop="proCounty">
|
||||
<el-input v-model="queryParams.proCounty" style="width: 200px" placeholder="项目所在区/县" disabled />
|
||||
<el-select
|
||||
clearable
|
||||
disabled
|
||||
style="width: 200px"
|
||||
placeholder="请选择项目所在区/县"
|
||||
v-model="queryParams.proCounty"
|
||||
>
|
||||
<el-option
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.label"
|
||||
v-for="item in countyList"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
||||
</el-form>
|
||||
|
||||
</el-card>
|
||||
|
||||
<el-card>
|
||||
|
||||
<el-row :gutter="10" class="mb8" justify="end">
|
||||
<el-col :span="4">
|
||||
<span style="font-size: 20px; font-weight: 800">共享出库列表</span>
|
||||
</el-col>
|
||||
<el-col v-if="routerParams.isView" :span="20" style="display: flex; justify-content: flex-end">
|
||||
<el-button type="primary" :disabled="queryParams.taskStatus == '3'" @click="handleOutAll">全部出库</el-button>
|
||||
<el-button type="primary" :disabled="queryParams.taskStatus == '3'" @click="handleOutCancelAll"
|
||||
>全部取消出库
|
||||
<el-button type="primary" :disabled="queryParams.taskStatus =='3'" @click="handleOutAll">全部出库</el-button>
|
||||
<el-button type="primary" :disabled="queryParams.taskStatus =='3'" @click="handleOutCancelAll">全部取消出库
|
||||
</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
|
@ -67,26 +133,31 @@
|
|||
:max-height="650"
|
||||
style="width: 100%"
|
||||
>
|
||||
<el-table-column type="index" width="55" label="序号" align="center" />
|
||||
<el-table-column
|
||||
type="index"
|
||||
width="55"
|
||||
label="序号"
|
||||
align="center"
|
||||
/>
|
||||
<el-table-column label="分类" align="center" prop="devType" :show-overflow-tooltip="true">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.devType == 1">{{ '装备' }}</span>
|
||||
<span v-if="scope.row.devType == 2">{{ '工具' }}</span>
|
||||
<span v-if="scope.row.devType==1">{{ '装备' }}</span>
|
||||
<span v-if="scope.row.devType==2">{{ '工具' }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="类目" align="center" prop="category" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="名称" align="center" prop="typeName" :show-overflow-tooltip="true" width="120px" />
|
||||
<el-table-column label="规格型号" align="center" prop="typeModelName" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="类目" align="center" prop="category" :show-overflow-tooltip="true"/>
|
||||
<el-table-column label="名称" align="center" prop="typeName" :show-overflow-tooltip="true" width="120px"/>
|
||||
<el-table-column label="规格型号" align="center" prop="typeModelName" :show-overflow-tooltip="true"/>
|
||||
<el-table-column label="管理模式" align="center" prop="manageType" :show-overflow-tooltip="true">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.manageType == 0">{{ '编码设备' }}</span>
|
||||
<span v-if="scope.row.manageType == 1">{{ '数量设备' }}</span>
|
||||
<span v-if="scope.row.manageType==0">{{ '编码设备' }}</span>
|
||||
<span v-if="scope.row.manageType==1">{{ '数量设备' }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="设备编码" align="center" prop="devCode" :show-overflow-tooltip="true" width="140px" />
|
||||
<el-table-column label="当前库存" align="center" prop="storageNum" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="申请数量" align="center" prop="num" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="已出库数量" align="center" prop="realNum" :show-overflow-tooltip="true" />
|
||||
<el-table-column label="设备编码" align="center" prop="devCode" :show-overflow-tooltip="true" width="140px"/>
|
||||
<el-table-column label="当前库存" align="center" prop="storageNum" :show-overflow-tooltip="true"/>
|
||||
<el-table-column label="申请数量" align="center" prop="num" :show-overflow-tooltip="true"/>
|
||||
<el-table-column label="已出库数量" align="center" prop="realNum" :show-overflow-tooltip="true"/>
|
||||
<el-table-column label="使用到期日期" align="center" width="250px" :show-overflow-tooltip="true">
|
||||
<template slot-scope="scope">
|
||||
<!-- 处理日期为 null/undefined 的情况,显示占位符;有值则拼接为 "开始日期 至 结束日期" 格式 -->
|
||||
|
|
@ -98,16 +169,13 @@
|
|||
</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column
|
||||
label="出库数量"
|
||||
v-if="routerParams.isView"
|
||||
align="center"
|
||||
prop="outNum"
|
||||
:show-overflow-tooltip="true"
|
||||
|
||||
<el-table-column label="出库数量" v-if="routerParams.isView" align="center" prop="outNum"
|
||||
:show-overflow-tooltip="true"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<el-input
|
||||
:disabled="scope.row.isFinished == '1'"
|
||||
:disabled="scope.row.isFinished =='1'"
|
||||
v-if="scope.row.manageType === '1'"
|
||||
v-model.number="scope.row.outNum"
|
||||
:placeholder="`请输入出库数量(最大${scope.row.remainNum.toFixed(2)})`"
|
||||
|
|
@ -117,36 +185,38 @@
|
|||
@input="handleOutNumInput(scope.row)"
|
||||
@change="handleOutNumChange(scope.row)"
|
||||
/>
|
||||
<span v-if="scope.row.manageType == 0">{{ (scope.row.num, (scope.row.outNum = scope.row.num)) }}</span>
|
||||
<span v-if="scope.row.manageType==0">{{ scope.row.num , scope.row.outNum = scope.row.num }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center">
|
||||
<el-table-column label="操作" align="center" v-if="routerParams.isView">
|
||||
<template slot-scope="{ row }">
|
||||
<el-button
|
||||
size="mini"
|
||||
:disabled="row.isFinished == '1' || row.outNum == 0"
|
||||
type="text"
|
||||
icon="el-icon-zoom-in"
|
||||
@click="handleOut(row)"
|
||||
>出库
|
||||
</el-button>
|
||||
<el-button size="mini" :disabled="row.isFinished == '1'" type="text" @click="handleOutCancel(row)"
|
||||
>取消出库
|
||||
<el-button size="mini" :disabled="row.isFinished =='1' || row.outNum == 0" type="text"
|
||||
icon="el-icon-zoom-in"
|
||||
@click="handleOut(row)"
|
||||
>出库
|
||||
</el-button
|
||||
>
|
||||
<el-button size="mini" :disabled="row.isFinished =='1'" type="text" @click="handleOutCancel(row)">取消出库
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-card>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getOrderByIdApi, out, outAll, outCancel, outCancelAll } from '@/api/business/outbound'
|
||||
import { getUseProjectListAPI, getVoltageListAPI } from '@/api/EquipmentLedger/equ-out'
|
||||
import { getOrderByIdApi, orderOut, orderOutAll, orderOutCancel, orderOutCancelAll } from '@/api/business/outbound'
|
||||
import {
|
||||
getUseProjectListAPI,
|
||||
getVoltageListAPI
|
||||
} from '@/api/EquipmentLedger/equ-out'
|
||||
import { regionData } from 'element-china-area-data'
|
||||
|
||||
export default {
|
||||
name: 'SharedOutList',
|
||||
name: 'AddEditApply',
|
||||
// components: { AddNum, AddCode },
|
||||
data() {
|
||||
return {
|
||||
routerParams: {},
|
||||
|
|
@ -168,7 +238,7 @@ export default {
|
|||
useTime: null,
|
||||
pageNum: 1, // 页码
|
||||
pageSize: 10, // 每页条数
|
||||
taskStatus: '',
|
||||
taskStatus: ''
|
||||
},
|
||||
useProjectList: [], // 使用项目下拉选
|
||||
voltageList: [], // 电压等级下拉选
|
||||
|
|
@ -178,42 +248,41 @@ export default {
|
|||
|
||||
typeList: [
|
||||
{ label: '数量管理', value: '1' },
|
||||
{ label: '编码管理', value: '0' },
|
||||
{ label: '编码管理', value: '0' }
|
||||
],
|
||||
total: 0, // 总条数
|
||||
// 表格数据
|
||||
tableList: [],
|
||||
openAdd: false, // 添加申请
|
||||
addQuery: {
|
||||
// 添加申请查询
|
||||
addQuery: { // 添加申请查询
|
||||
typeName: '', // 名称
|
||||
typeModelName: '', // 规格型号
|
||||
devCode: '', // 设备编码
|
||||
pageNum: 1, // 页码
|
||||
pageSize: 10, // 每页条数
|
||||
pageSize: 10 // 每页条数
|
||||
},
|
||||
addTotal: 0, // 总条数
|
||||
addList: [], // 添加申请列表
|
||||
addTempList: [], // 添加申请临时列表
|
||||
ids: [], // 选中的id
|
||||
single: false, // 单选
|
||||
multiple: false, // 多选
|
||||
multiple: false // 多选
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.routerParams = this.$route.query
|
||||
// let title = '自用出库详情'
|
||||
// if (this.routerParams.isView) {
|
||||
// title = '查看审核'
|
||||
// } else if (this.routerParams.isEdit) {
|
||||
// title = '审核详情'
|
||||
// }
|
||||
let title = '共享出库详情'
|
||||
if (this.routerParams.isView) {
|
||||
title = '共享出库'
|
||||
} else if (this.routerParams.isEdit) {
|
||||
title = '共享出库'
|
||||
}
|
||||
this.queryParams.id = this.routerParams.id || ''
|
||||
this.getUseProjectList()
|
||||
this.queryParams.status == '0' ? (this.queryParams.useUnit = sessionStorage.getItem('deptName')) : ''
|
||||
this.queryParams.status == '0' ? this.queryParams.useUnit = sessionStorage.getItem('deptName') : ''
|
||||
this.provinceList = regionData
|
||||
// const obj = Object.assign({}, this.$route, { title })
|
||||
// this.$tab.updatePage(obj)
|
||||
const obj = Object.assign({}, this.$route, { title })
|
||||
this.$tab.updatePage(obj)
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
|
|
@ -309,13 +378,13 @@ export default {
|
|||
try {
|
||||
const params = { ...this.queryParams }
|
||||
const res = await getOrderByIdApi(params)
|
||||
this.tableList = res.data.devDetailsList.map((item) => {
|
||||
this.tableList = res.data.devDetailsList.map(item => {
|
||||
// 计算剩余可出库数量num - 已出库数量(real_num 为 null 则按 0 计算)
|
||||
const remainNum = Number(item.num) - (item.realNum ? Number(item.realNum) : 0)
|
||||
return {
|
||||
...item,
|
||||
remainNum: remainNum > 0 ? remainNum : 0, // 剩余数量不能为负数
|
||||
outNum: 0, // 绑定输入的出库数量
|
||||
outNum: 0 // 绑定输入的出库数量
|
||||
}
|
||||
})
|
||||
if (this.queryParams.id) {
|
||||
|
|
@ -338,12 +407,12 @@ export default {
|
|||
this.$confirm('是否确定出库?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
}).then(async () => {
|
||||
out(row).then((res) => {
|
||||
type: 'warning'
|
||||
}).then(async() => {
|
||||
orderOut(row).then(res => {
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!',
|
||||
message: '操作成功!'
|
||||
})
|
||||
this.getList()
|
||||
})
|
||||
|
|
@ -356,12 +425,12 @@ export default {
|
|||
this.$confirm('是否确定取消出库?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
}).then(async () => {
|
||||
outCancel(row).then((res) => {
|
||||
type: 'warning'
|
||||
}).then(async() => {
|
||||
orderOutCancel(row).then(res => {
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!',
|
||||
message: '操作成功!'
|
||||
})
|
||||
this.getList()
|
||||
})
|
||||
|
|
@ -376,34 +445,36 @@ export default {
|
|||
this.$confirm('是否确定全部取消出库?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
}).then(async () => {
|
||||
outAll({ id: this.queryParams.id }).then((res) => {
|
||||
type: 'warning'
|
||||
}).then(async() => {
|
||||
orderOutAll({ id: this.queryParams.id }).then(res => {
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!',
|
||||
message: '操作成功!'
|
||||
})
|
||||
this.$router.go(-1)
|
||||
})
|
||||
})
|
||||
|
||||
},
|
||||
handleOutCancelAll() {
|
||||
this.$confirm('是否确定全部取消出库?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
}).then(async () => {
|
||||
outCancelAll({ id: this.queryParams.id }).then((res) => {
|
||||
type: 'warning'
|
||||
}).then(async() => {
|
||||
orderOutCancelAll({ id: this.queryParams.id }).then(res => {
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!',
|
||||
message: '操作成功!'
|
||||
})
|
||||
this.$router.go(-1)
|
||||
})
|
||||
})
|
||||
},
|
||||
},
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped></style>
|
||||
<style lang="scss" scoped>
|
||||
</style>
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
<!-- 基础页面 -->
|
||||
<div class="app-container">
|
||||
<el-card v-show="showSearch" style="margin-bottom: 20px">
|
||||
<el-form :model="queryParams" ref="queryForm" size="small" inline label-width="110px">
|
||||
<el-form :model="queryParams" ref="queryForm" size="small" inline label-width="100px">
|
||||
|
||||
<el-form-item label="需求单位" prop="useUnit">
|
||||
<el-input v-model="queryParams.useUnit" style="width: 200px" placeholder="请输入需求单位" :disabled="queryParams.status=='0'"
|
||||
|
|
@ -112,9 +112,6 @@
|
|||
|
||||
<el-card>
|
||||
|
||||
|
||||
|
||||
|
||||
<el-row :gutter="10" class="mb8" justify="end">
|
||||
<el-col :span="4">
|
||||
<span style="font-size: 20px; font-weight: 800">自用出库列表</span>
|
||||
|
|
|
|||
|
|
@ -262,18 +262,18 @@ export default {
|
|||
},
|
||||
{
|
||||
label: '共享数量',
|
||||
prop: 'scrapNum',
|
||||
prop: 'shareNum',
|
||||
render: (h, { row }) => {
|
||||
return row.scrapNum > 0
|
||||
return row.shareNum > 0
|
||||
? h(
|
||||
'span',
|
||||
{
|
||||
style: { color: '#409EFF', cursor: 'pointer' },
|
||||
on: { click: () => this.handleDialog(row, '1') },
|
||||
},
|
||||
row.scrapNum,
|
||||
row.shareNum,
|
||||
)
|
||||
: h('span', {}, row.scrapNum)
|
||||
: h('span', {}, row.shareNum)
|
||||
},
|
||||
},
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue