Commit 0b4f8305 authored by kzy's avatar kzy

Merge branch 'project1' of http://gitlab.91isoft.com:90/yangshuo/template_vue into project1

parents 2d482cfe 59fc5a44
......@@ -34,6 +34,17 @@ export function add(data) {
}
})
}
// 再利用
export function recycle(data) {
return request({
url: '/wbwarehouse/recycle',
method: 'post',
data,
headers: {
'Content-Type': 'application/json;charset=UTF-8'
}
})
}
// 逻辑删除基础信息接口
export function deletedevice(id) {
return request({
......
......@@ -14,11 +14,11 @@ export function listLog(queryParams, queryMaps) {
}
/* TODO: 用来查询单项出入库记录的废弃详情信息 */
export function findSingleLogDetail(singleLogIdAndFqYs) {
export function findSingleLogDetail(singleLogIdAndPn) {
return request({
url: '/wbwarehouselog/detail',
method: 'post',
data: singleLogIdAndFqYs,
data: singleLogIdAndPn,
headers: {
'Content-Type': 'application/json;charset=UTF-8'
}
......
......@@ -138,7 +138,7 @@
append-to-body
@closed="handleClose"
>
<el-form ref="formDetails" :model="singleDetails" size="small" label-width="90px">
<el-form ref="formDetails" :model="singleDetails" size="small" label-width="100px">
<el-row :gutter="10" justify="start" align="middle">
<el-col :span="12">
......@@ -181,7 +181,7 @@
<el-form-item label="fq_dd:" prop="fq_dd">
{{ singleDetails.fq_dd }}
</el-form-item>
<el-form-item label="fq_mcode:" :label-width="10" prop="fq_mcode">
<el-form-item label="fq_mcode:" prop="fq_mcode">
{{ singleDetails.fq_mcode }}
</el-form-item>
<el-form-item label="fq_yy:" prop="fq_yy">
......@@ -389,7 +389,7 @@ export default {
// TODO: 表单里的单项详情参数
singleDetails: {},
// TODO: 获取表单单项详情的参数
singleLogIdAndFqYs: {},
singleLogIdAndPn: {},
activateAbandonedState: false
}
},
......@@ -479,14 +479,24 @@ export default {
},
/** TODO: 重置按钮操作 */
resetQuery() {
this.resetForm('queryForm')
this.queryEntity = {
tableSortMark: 0,
entity: {
pn: '',
lot: '',
plocation: '',
poperate: '',
ptype: ''
}
}
this.dateRange = []
this.handleQuery()
},
/* TODO: 控制单项表单关闭的详情 */
handleClose() {
this.activateAbandonedState = false
this.singleLogIdAndFqYs = {}
this.singleLogIdAndPn= {}
},
/* TODO: 进行排序 */
changeTableSort: function(val) {
......@@ -507,28 +517,18 @@ export default {
this.singleDetails = { ...row }
} else {
/* TODO: 设置单项详情的查询的条件 */
this.singleLogIdAndFqYs['businessId'] = row.businessId
this.singleLogIdAndFqYs['fqYs'] = row.fqYs
this.singleLogIdAndPn['businessId'] = row.businessId
this.singleLogIdAndPn['pn'] = row.pn
/* TODO: 进行查询,如果返回的code为200,则表示返回的值成功 */
findSingleLogDetail(this.singleLogIdAndFqYs).then(
findSingleLogDetail(this.singleLogIdAndPn).then(
response => {
if (response.code === 200) {
this.singleDetails = Object.assign({}, response.data, { ...row })
/* TODO: 如果库状态==='4' 并且返回的状态码为200的时候,才会将可变的详情字段设置为true,去激活并打开 */
this.activateAbandonedState = true
} else {
/* TODO: 如果状态码不对则不会激活可变字段,只会对普通字段进行赋值,并且抛出错误信息response.message */
this.$message({
showClose: true,
message: response.message,
type: 'warning'
})
this.singleDetails = { ...row }
}
/* 激活打开废弃信息栏 */
this.activateAbandonedState = true
this.title = '记录详情'
this.singleDetails = Object.assign({}, response.data, { ...row })
}
)
}
this.title = '记录详情'
this.openDetails = true
},
handleExport() {
......
......@@ -13,7 +13,7 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="name" prop="name">
<el-form-item label="dname" prop="dname">
<el-input
v-model="queryParams.dname"
placeholder="请输入名称"
......@@ -23,6 +23,16 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="dno" prop="dno">
<el-input
v-model="queryParams.dno"
placeholder="请输入dno"
clearable
size="small"
style="width: 150px"
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item>
<el-button type="primary" style="padding: 8px 7px;" icon="el-icon-search" size="small" @click="handleQuery">查询</el-button>
<el-button style="padding: 8px 7px;" icon="el-icon-refresh" size="small" @click="resetQuery">重置</el-button>
......@@ -36,13 +46,13 @@
icon="el-icon-plus"
@click="handleAdd"
>新增</el-button>
<el-button
style="padding: 8px 7px;"
type="success"
size="small"
icon="el-icon-download"
@click="handleExport"
>导出</el-button>
<!-- <el-button-->
<!-- style="padding: 8px 7px;"-->
<!-- type="success"-->
<!-- size="small"-->
<!-- icon="el-icon-download"-->
<!-- @click="handleExport"-->
<!-- >导出</el-button>-->
</el-form-item>
</div>
</el-form>
......@@ -68,22 +78,22 @@
{{ scope.row.dno || '-' }}
</template>
</el-table-column>
<el-table-column label="remarks" prop="remarks" :show-overflow-tooltip="true">
<template slot-scope="scope">
{{ scope.row.remarks || '-' }}
</template>
</el-table-column>
<!-- <el-table-column label="remarks" prop="remarks" :show-overflow-tooltip="true">-->
<!-- <template slot-scope="scope">-->
<!-- {{ scope.row.remarks || '-' }}-->
<!-- </template>-->
<!-- </el-table-column>-->
<el-table-column label="操作人" prop="createName" :show-overflow-tooltip="true">
<template slot-scope="scope">
{{ scope.row.createName || '-' }}
</template>
</el-table-column>
<el-table-column label="操作时间" prop="createDate" :show-overflow-tooltip="true">
<el-table-column label="操作时间" prop="updateDate" :show-overflow-tooltip="true">
<template slot-scope="scope">
{{ parseTime(scope.row.createDate, '{y}-{m}-{d} {h}:{i}') || '-' }}
{{ parseTime(scope.row.updateDate, '{y}-{m}-{d} {h}:{i}') || '-' }}
</template>
</el-table-column>
<el-table-column label="操作">
<el-table-column label="操作" width="150px">
<template slot-scope="scope">
<el-button
size="mini"
......@@ -128,9 +138,9 @@
<el-form-item label="dno" prop="dno">
<el-input v-model.trim="form.dno" :maxlength="30" placeholder="请输入dno" />
</el-form-item>
<el-form-item label="remarks" prop="remarks">
<el-input v-model.trim="form.remarks" :maxlength="30" placeholder="请输入remarks" />
</el-form-item>
<!-- <el-form-item label="remarks" prop="remarks">-->
<!-- <el-input v-model.trim="form.remarks" :maxlength="30" placeholder="请输入remarks" />-->
<!-- </el-form-item>-->
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
......@@ -154,7 +164,8 @@ export default {
form: {},
rules: {
pn: [{ required: true, message: '请输入pn', trigger: 'blur' }],
dname: [{ required: true, message: '请输入name', trigger: 'blur' }]
dname: [{ required: true, message: '请输入dname', trigger: 'blur' }],
dno: [{ required: true, message: '请输入dno', trigger: 'blur' }]
},
total: 0,
loading: false,
......@@ -162,7 +173,8 @@ export default {
page: 1,
rows: 10,
pn: '',
dname: ''
dname: '',
dno: ''
},
statusOptions: {},
basicinfoMationList: []
......@@ -232,7 +244,7 @@ export default {
getList() {
this.loading = true
queryList(this.queryParams).then(res => {
res.rows.createDate = parseTime(res.rows.createDate, '{y}-{m}-{d}')
res.rows.updateDate = parseTime(res.rows.updateDate, '{y}-{m}-{d}')
this.total = res.total
this.basicinfoMationList = res.rows
this.loading = false
......@@ -249,7 +261,8 @@ export default {
page: 1,
rows: 10,
pn: '',
dname: ''
dname: '',
dno: ''
}
this.getList()
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment