代码提交
This commit is contained in:
parent
2c1850c735
commit
e97b14446a
|
|
@ -39,6 +39,15 @@ export const getAddressListApi = (data = {}) => {
|
|||
})
|
||||
}
|
||||
|
||||
export const delAddressApi = (data) => {
|
||||
return request({
|
||||
url: '/material-mall/bm_company_address/delAddress?id=' + data,
|
||||
method: 'POST'
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
|
||||
// 需求列表详情
|
||||
export const getLeaseDetailsByIdApi = (data = {}) => {
|
||||
return request({
|
||||
|
|
|
|||
|
|
@ -138,7 +138,7 @@
|
|||
<span>{{ item.buyerName }}</span>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<span> 承租方所属单位---: </span>
|
||||
<span> 承租方所属单位: </span>
|
||||
<span>{{ item.companyName }}</span>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
<el-col :span="collapsed ? 1 : 5" class="tree-column">
|
||||
<div class="card-container" v-if="!collapsed">
|
||||
<div class="card-header">
|
||||
<span class="card-title">装备分类---</span>
|
||||
<span class="card-title">装备分类</span>
|
||||
</div>
|
||||
<el-tree
|
||||
v-if="!collapsed"
|
||||
|
|
@ -1238,7 +1238,7 @@ export default {
|
|||
}
|
||||
} catch (error) {
|
||||
console.error('编辑错误:', error)
|
||||
this.$message.error('编辑失败:' + (error.message || '未知错误'))
|
||||
console.error('编辑失败:' + (error.message || '未知错误'))
|
||||
}
|
||||
} else {
|
||||
this.$message.warning('请完善必填字段后再保存')
|
||||
|
|
@ -1293,7 +1293,7 @@ export default {
|
|||
this.$message.error(res.msg || '新增分类失败')
|
||||
}
|
||||
} catch (error) {
|
||||
this.$message.error('新增分类失败:' + (error.message || '未知错误'))
|
||||
console.log('新增分类失败:' + (error.message || '未知错误'))
|
||||
}
|
||||
}
|
||||
})
|
||||
|
|
|
|||
|
|
@ -13,55 +13,65 @@
|
|||
<el-row>
|
||||
<el-col :span="24" style="text-align: right;">
|
||||
<el-button
|
||||
size="mini"
|
||||
@click="handleAddAddress"
|
||||
type="primary"
|
||||
class="primary-lease"
|
||||
>
|
||||
新建收货地址
|
||||
</el-button>
|
||||
size="mini"
|
||||
@click="handleAddAddress"
|
||||
type="primary"
|
||||
class="primary-lease"
|
||||
>
|
||||
新建收货地址
|
||||
</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<div >
|
||||
<!-- 表格 -->
|
||||
<el-table
|
||||
:data="leaseList"
|
||||
show-overflow-tooltip
|
||||
border
|
||||
stripe
|
||||
height="546"
|
||||
>
|
||||
<el-table-column align="center" label="序号" type="index" width="80" />
|
||||
<el-table-column align="center" label="收货地址">
|
||||
<template slot-scope="{ row }">
|
||||
{{ `${row.provinceName}${row.cityName}${row.areaName}${row.address}` }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="操作" :width="220">
|
||||
<template slot-scope="{ row }">
|
||||
<el-button
|
||||
size="small"
|
||||
type="text"
|
||||
icon="el-icon-edit"
|
||||
class="primary-lease"
|
||||
@click="onRepublish(row)"
|
||||
>
|
||||
编辑
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
<div>
|
||||
<!-- 表格 -->
|
||||
<el-table
|
||||
:data="leaseList"
|
||||
show-overflow-tooltip
|
||||
border
|
||||
stripe
|
||||
height="546"
|
||||
>
|
||||
<el-table-column align="center" label="序号" type="index" width="80"/>
|
||||
<el-table-column align="center" label="收货地址">
|
||||
<template slot-scope="{ row }">
|
||||
{{ `${row.provinceName}${row.cityName}${row.areaName}${row.address}` }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="操作" :width="220">
|
||||
<template slot-scope="{ row }">
|
||||
<el-button
|
||||
size="small"
|
||||
type="text"
|
||||
icon="el-icon-edit"
|
||||
class="primary-lease"
|
||||
@click="onRepublish(row)"
|
||||
>
|
||||
编辑
|
||||
</el-button>
|
||||
<el-button
|
||||
size="small"
|
||||
type="text"
|
||||
icon="el-icon-delete"
|
||||
class="primary-lease"
|
||||
@click="delRow(row.id)"
|
||||
style="color: red"
|
||||
>
|
||||
删除
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
|
||||
<div class="pagination-wrapper">
|
||||
<pagination
|
||||
:total="total"
|
||||
@pagination="getLeaseListData"
|
||||
:page.sync="searchParams.pageNum"
|
||||
:limit.sync="searchParams.pageSize"
|
||||
/>
|
||||
</div>
|
||||
</el-card>
|
||||
<div class="pagination-wrapper">
|
||||
<pagination
|
||||
:total="total"
|
||||
@pagination="getLeaseListData"
|
||||
:page.sync="searchParams.pageNum"
|
||||
:limit.sync="searchParams.pageSize"
|
||||
/>
|
||||
</div>
|
||||
</el-card>
|
||||
<!-- 新增修改对话框 -->
|
||||
<el-dialog
|
||||
width="40%"
|
||||
|
|
@ -168,9 +178,11 @@ import {
|
|||
editAddressApi,
|
||||
deleteLeaseInfoApi,
|
||||
maLeaseAuditApi,
|
||||
getLeaseDetailsByIdApi,
|
||||
delAddressApi,
|
||||
getLeaseDetailsByIdApi
|
||||
} from '@/api/address-manage/index'
|
||||
import { MessageBox, Message } from 'element-ui'
|
||||
import { out } from '@/api/business/outbound'
|
||||
|
||||
export default {
|
||||
data() {
|
||||
|
|
@ -193,7 +205,7 @@ export default {
|
|||
|
||||
searchParams: {
|
||||
pageSize: 10,
|
||||
pageNum: 1,
|
||||
pageNum: 1
|
||||
},
|
||||
addOrEditForm: {
|
||||
areaCode: '',
|
||||
|
|
@ -211,7 +223,7 @@ export default {
|
|||
areaCode: [{ required: true, message: '请选择项目所在区/县', trigger: 'change' }],
|
||||
cityCode: [{ required: true, message: '请选择项目所在市', trigger: 'change' }],
|
||||
provinceCode: [{ required: true, message: '请选择项目所在省', trigger: 'change' }],
|
||||
address: [{ required: true, message: '请输入项目详细地址', trigger: 'blur' }],
|
||||
address: [{ required: true, message: '请输入项目详细地址', trigger: 'blur' }]
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
@ -245,7 +257,8 @@ export default {
|
|||
},
|
||||
|
||||
// 重置表单
|
||||
onReset() {},
|
||||
onReset() {
|
||||
},
|
||||
|
||||
// 删除地址
|
||||
async onDelete(id) {
|
||||
|
|
@ -259,6 +272,22 @@ export default {
|
|||
}
|
||||
},
|
||||
|
||||
async delRow(id) {
|
||||
this.$confirm('是否确定删除?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(async() => {
|
||||
delAddressApi(id).then(res => {
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!'
|
||||
})
|
||||
this.getLeaseListData()
|
||||
})
|
||||
})
|
||||
},
|
||||
|
||||
// 编辑地址
|
||||
async onRepublish(row) {
|
||||
this.dialogTitle = '编辑收货地址'
|
||||
|
|
@ -282,7 +311,7 @@ export default {
|
|||
|
||||
// 提交表单
|
||||
async onSubmit(type) {
|
||||
this.$refs.addOrEditFormRef.validate(async (valid) => {
|
||||
this.$refs.addOrEditFormRef.validate(async(valid) => {
|
||||
if (valid) {
|
||||
const SUBMIT_API = this.dialogTitle === '新增收货地址'
|
||||
? addAddressInfoApi
|
||||
|
|
@ -331,19 +360,20 @@ export default {
|
|||
},
|
||||
|
||||
// 区县变化
|
||||
async onCountyChange(id) {},
|
||||
async onCountyChange(id) {
|
||||
},
|
||||
|
||||
// 审核处理
|
||||
onAuditing(id, leaseStatus) {
|
||||
MessageBox.confirm(`是否${leaseStatus === 1 ? '通过' : '驳回'}此次接单申请?`, '温馨提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'success',
|
||||
type: 'success'
|
||||
})
|
||||
.then(async () => {
|
||||
.then(async() => {
|
||||
const res = await maLeaseAuditApi({
|
||||
id,
|
||||
leaseStatus,
|
||||
leaseStatus
|
||||
})
|
||||
if (res.code == 200) {
|
||||
Message({
|
||||
|
|
@ -354,7 +384,8 @@ export default {
|
|||
this.getLeaseListData()
|
||||
}
|
||||
})
|
||||
.catch(() => {})
|
||||
.catch(() => {
|
||||
})
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
|
|
@ -368,13 +399,16 @@ export default {
|
|||
::v-deep .upload-tip .el-form-item__label {
|
||||
color: transparent;
|
||||
}
|
||||
|
||||
.el-pagination {
|
||||
justify-content: flex-end;
|
||||
padding: 5px 0;
|
||||
}
|
||||
|
||||
::v-deep .el-pagination.is-background .el-pager li.is-active {
|
||||
background-color: #3cb4a6;
|
||||
}
|
||||
|
||||
::v-deep .el-form--inline .el-form-item {
|
||||
margin-right: 6px;
|
||||
width: 95%;
|
||||
|
|
@ -416,10 +450,12 @@ export default {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
.img-items:hover .mask-img {
|
||||
visibility: visible;
|
||||
}
|
||||
}
|
||||
|
||||
.app-container-content {
|
||||
::v-deep .el-dialog {
|
||||
display: flex !important;
|
||||
|
|
@ -430,10 +466,12 @@ export default {
|
|||
left: 50% !important;
|
||||
transform: translate(-50%, -50%) !important;
|
||||
max-height: 100vh !important;
|
||||
|
||||
.el-dialog__body {
|
||||
flex: 1;
|
||||
overflow-y: scroll !important;
|
||||
}
|
||||
|
||||
.dialog-content {
|
||||
padding: 20px;
|
||||
}
|
||||
|
|
@ -441,30 +479,30 @@ export default {
|
|||
}
|
||||
|
||||
::v-deep .el-table {
|
||||
// 启用斑马纹
|
||||
&.el-table--striped .el-table__body {
|
||||
tr.el-table__row--striped td {
|
||||
background-color: #F6FBFA !important; // 浅紫色
|
||||
}
|
||||
}
|
||||
|
||||
.el-table__header {
|
||||
background: #E9F0EE;
|
||||
|
||||
th {
|
||||
background: #E9F0EE !important;
|
||||
color: #606266;
|
||||
font-weight: 600;
|
||||
height: 50px;
|
||||
}
|
||||
}
|
||||
|
||||
&.el-table--striped .el-table__body tr.el-table__row:hover>td.el-table__cell {
|
||||
background-color: #CCF1E9 !important;
|
||||
// 启用斑马纹
|
||||
&.el-table--striped .el-table__body {
|
||||
tr.el-table__row--striped td {
|
||||
background-color: #F6FBFA !important; // 浅紫色
|
||||
}
|
||||
}
|
||||
|
||||
.content-box {
|
||||
.el-table__header {
|
||||
background: #E9F0EE;
|
||||
|
||||
th {
|
||||
background: #E9F0EE !important;
|
||||
color: #606266;
|
||||
font-weight: 600;
|
||||
height: 50px;
|
||||
}
|
||||
}
|
||||
|
||||
&.el-table--striped .el-table__body tr.el-table__row:hover > td.el-table__cell {
|
||||
background-color: #CCF1E9 !important;
|
||||
}
|
||||
}
|
||||
|
||||
.content-box {
|
||||
border-radius: 8px;
|
||||
height: calc(100vh - 120px);
|
||||
display: flex;
|
||||
|
|
@ -504,7 +542,7 @@ export default {
|
|||
padding-top: 6px;
|
||||
margin-top: auto;
|
||||
|
||||
::v-deep .pagination-container {
|
||||
::v-deep .pagination-container {
|
||||
padding: 0px 20px !important;
|
||||
/* margin-bottom: 30px; */
|
||||
}
|
||||
|
|
@ -529,7 +567,7 @@ export default {
|
|||
}
|
||||
}
|
||||
|
||||
&.el-table--striped .el-table__body tr.el-table__row:hover>td.el-table__cell {
|
||||
&.el-table--striped .el-table__body tr.el-table__row:hover > td.el-table__cell {
|
||||
background-color: #CCF1E9 !important;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -154,9 +154,9 @@
|
|||
</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="storageNum" width="80px" :show-overflow-tooltip="true"/>
|
||||
<el-table-column label="申请数量" align="center" prop="num" width="80px" :show-overflow-tooltip="true"/>
|
||||
<el-table-column label="已出库数量" align="center" prop="realNum" width="100px" :show-overflow-tooltip="true"/>
|
||||
<el-table-column label="使用到期日期" align="center" width="250px" :show-overflow-tooltip="true">
|
||||
<template slot-scope="scope">
|
||||
<!-- 处理日期为 null/undefined 的情况,显示占位符;有值则拼接为 "开始日期 至 结束日期" 格式 -->
|
||||
|
|
@ -441,7 +441,7 @@ export default {
|
|||
},
|
||||
|
||||
handleOutAll() {
|
||||
this.$confirm('是否确定全部取消出库?', '提示', {
|
||||
this.$confirm('是否确定全部出库?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
|
|
|
|||
Loading…
Reference in New Issue