This commit is contained in:
liushuai
2019-06-21 09:31:55 +08:00
19 changed files with 2445 additions and 108 deletions

View File

@@ -94,8 +94,8 @@
</el-table-column>
<el-table-column label="操作" align="center" width="250px" fixed="right">
<template slot-scope="scope">
<el-button v-if="scope.row.组件是否完成===null || scope.row.组件是否完成===0" type="success" size="small" @click="handlestart_3(scope.row)">开始装配</el-button>
<el-button v-else-if="scope.row.组件是否完成===1" type="danger" size="small" @click="handleend_3(scope.row)">结束装配</el-button>
<el-button v-if="scope.row.buttonStatus === 1" type="success" size="small" @click="handlestart_3(scope.row)">开始装配</el-button>
<el-button v-else-if="scope.row.buttonStatus === 2" type="danger" size="small" @click="handleend_3(scope.row)">结束装配</el-button>
<el-button v-else type="info" size="small" >装配完成</el-button>
</template>
</el-table-column>
@@ -163,6 +163,16 @@ export default {
searchTable2(this.machineNumberValue, this.check2).then(response => {
console.log(response.data, 222)
this.tableData2 = response.data
this.tableData2.map(v => {
if (v.组件是否完成 === null || v.组件是否完成 === 0) {
this.$set(v, 'buttonStatus', 1)
} else if (v.组件是否完成 === 1) {
this.$set(v, 'buttonStatus', 2)
} else {
this.$set(v, 'buttonStatus', 3)
}
return v
})
})
},
// 总装开始装配
@@ -207,7 +217,8 @@ export default {
ComponentStateUpdate(row.组件流水号, 1).then(response => {
console.log(response.data)
this.searchTable1()
this.searchTable2()
row.buttonStatus = 2
// this.searchTable2()
})
},
// 部装结束装配
@@ -216,7 +227,8 @@ export default {
ComponentStateUpdate(row.组件流水号, 2).then(response => {
console.log(response.data)
this.searchTable1()
this.searchTable2()
row.buttonStatus = 3
// this.searchTable2()
})
}
}

View File

@@ -0,0 +1,673 @@
<template>
<div>
<el-card>
<div class="text">
<el-row style="margin-top: 10px">
<span style="width:80px;display:inline-block;">发货单名</span>
<el-input
v-model="searchFrom.发货单名"
clearable
placeholder="请输入"
style="width: 150px;margin-right: 10px"
size="mini"/>
<span style="width:80px;display:inline-block;">发货单号</span>
<el-input
v-model="searchFrom.发货单号"
placeholder="请输入"
clearable
style="width: 150px;margin-right: 10px"
size="mini"/>
<span style="width:80px;display:inline-block;">收货单位</span>
<el-input
v-model="searchFrom.收货单位"
placeholder="请输入"
clearable
style="width: 150px;margin-right: 10px"
size="mini"/>
</el-row>
<el-row style="margin-top: 10px">
<span style="width:80px;display:inline-block;">车辆牌号</span>
<el-input
v-model="searchFrom.车辆牌号"
placeholder="请输入"
clearable
style="width: 150px;margin-right: 10px"
size="mini"/>
<span style="width:80px;display:inline-block;">司机姓名</span>
<el-input
v-model="searchFrom.司机姓名"
placeholder="请输入"
clearable
style="width: 150px;margin-right: 10px"
size="mini"/>
<span style="width:80px;display:inline-block;">司机电话</span>
<el-input
v-model="searchFrom.司机电话"
placeholder="请输入"
clearable
style="width: 150px;margin-right: 10px"
size="mini"/>
</el-row>
<el-row style="margin-top: 10px">
<span style="width:80px;display:inline-block;">制单人</span>
<el-input
v-model="searchFrom.制单人"
placeholder="请输入"
clearable
style="width: 150px;margin-right: 10px"
size="mini"/>
<span style="width:80px;display:inline-block;">核准人</span>
<el-input
v-model="searchFrom.核准人"
placeholder="请输入"
clearable
style="width: 150px;margin-right: 10px"
size="mini"/>
<span style="width:80px;display:inline-block;">执行人</span>
<el-input
v-model="searchFrom.执行人"
placeholder="请输入"
clearable
style="width: 150px;margin-right: 10px"
size="mini"/>
</el-row>
<el-row style="margin-top: 10px">
<span style="width:80px;display:inline-block;">制单日期</span>
<el-date-picker
v-model="searchFrom.开始制单日期"
style="width: 150px; margin-right: 10px"
value-format="yyyy-MM-dd HH:mm:ss"
size="small"
type="datetime"
placeholder="开始日期"/>
<span style="width:80px;display:inline-block;">制单日期</span>
<el-date-picker
v-model="searchFrom.结束制单日期"
style="width: 150px; margin-right: 10px"
value-format="yyyy-MM-dd HH:mm:ss"
size="small"
type="datetime"
placeholder="结束日期"/>
<span style="width:80px;display:inline-block;">发货状态</span>
<el-select v-model="DeliveryStatusValue" placeholder="请选择" size="mini" style="width: 150px" clearable>
<el-option
v-for="item in DeliveryStatus"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
</el-row>
<el-row style="margin-top: 10px">
<span style="width:80px;display:inline-block;">核准日期</span>
<el-date-picker
v-model="searchFrom.开始核准日期"
style="width: 150px; margin-right: 10px"
value-format="yyyy-MM-dd HH:mm:ss"
size="small"
type="datetime"
placeholder="开始日期"/>
<span style="width:80px;display:inline-block;">核准日期</span>
<el-date-picker
v-model="searchFrom.结束核准日期"
style="width: 150px; margin-right: 10px"
value-format="yyyy-MM-dd HH:mm:ss"
size="small"
type="datetime"
placeholder="结束日期"/>
</el-row>
<el-row style="margin-top: 10px">
<span style="width:80px;display:inline-block;">发货日期</span>
<el-date-picker
v-model="searchFrom.开始发货日期"
style="width: 150px; margin-right: 10px"
value-format="yyyy-MM-dd HH:mm:ss"
size="small"
type="datetime"
placeholder="开始日期"/>
<span style="width:80px;display:inline-block;">发货日期</span>
<el-date-picker
v-model="searchFrom.结束发货日期"
style="width: 150px; margin-right: 10px"
value-format="yyyy-MM-dd HH:mm:ss"
size="small"
type="datetime"
placeholder="结束日期"/>
<el-button type="success" icon="el-icon-menu" size="mini" style="margin-left: 74px" @click="search">查询</el-button>
<el-button type="warning" icon="el-icon-delete" size="mini" @click="clearSearch">清空</el-button>
</el-row>
</div>
<el-divider/>
<div>
<el-table
:data="tableDataSearchList"
highlight-current-row
style="width: 100%"
height="500"
border
size="mini"
@row-click="openDialogFormVisible">
<el-table-column align="center" label="状态" min-width="80">
<template slot-scope="scope">
<el-tag v-if="scope.row.是否发出.toString() === '1'" type="success" size="small">已发出</el-tag>
<el-tag v-else type="danger" size="small">未发出</el-tag>
<!--{{ scope.row.是否发出.toString() === '1' ? '已发出' : '未发出' }}-->
</template>
</el-table-column>
<el-table-column align="center" label="发货单号" min-width="120">
<template slot-scope="scope">
{{ scope.row.发货单编号 }}
</template>
</el-table-column>
<el-table-column align="center" label="发货单名" min-width="110">
<template slot-scope="scope">
{{ scope.row.发货单名称 }}
</template>
</el-table-column>
<el-table-column align="center" label="收货单位" min-width="200">
<template slot-scope="scope">
{{ scope.row.收货单位 }}
</template>
</el-table-column>
<el-table-column align="center" label="收货地址" min-width="250">
<template slot-scope="scope">
{{ scope.row.收货地址 }}
</template>
</el-table-column>
<el-table-column align="center" label="收货人员" min-width="80">
<template slot-scope="scope">
{{ scope.row.收货人员 }}
</template>
</el-table-column>
<el-table-column align="center" label="联系电话" min-width="110">
<template slot-scope="scope">
{{ scope.row.联系电话 }}
</template>
</el-table-column>
<el-table-column align="center" label="车辆牌号" min-width="110">
<template slot-scope="scope">
{{ scope.row.车辆牌号 }}
</template>
</el-table-column>
<el-table-column align="center" label="司机姓名" min-width="80">
<template slot-scope="scope">
{{ scope.row.司机姓名 }}
</template>
</el-table-column>
<el-table-column align="center" label="司机电话" min-width="110">
<template slot-scope="scope">
{{ scope.row.司机电话 }}
</template>
</el-table-column>
<el-table-column align="center" label="制单人" min-width="80">
<template slot-scope="scope">
{{ scope.row.制单人 }}
</template>
</el-table-column>
<el-table-column align="center" label="审核人" min-width="80">
<template slot-scope="scope">
{{ scope.row.审核人 }}
</template>
</el-table-column>
<el-table-column align="center" label="发货人" min-width="80">
<template slot-scope="scope">
{{ scope.row.发货人 }}
</template>
</el-table-column>
<el-table-column align="center" label="制单时间" min-width="85">
<template slot-scope="scope">
{{ scope.row.操作日期 }}
</template>
</el-table-column>
<el-table-column align="center" label="审核时间" min-width="85">
<template slot-scope="scope">
{{ scope.row.审核日期 }}
</template>
</el-table-column>
<el-table-column align="center" label="发货时间" min-width="85">
<template slot-scope="scope">
{{ scope.row.发出时间 }}
</template>
</el-table-column>
</el-table>
</div>
<div class="block" style="margin-top: 10px;">
<el-pagination
:current-page="pageCurrent"
:page-sizes="[10, 20, 30, 40, 50]"
:page-size="pageSize"
:total="total"
layout="total, sizes, prev, pager, next, jumper"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"/>
</div>
</el-card>
<el-dialog :visible.sync="dialogFormVisible" title="江苏高精机电装备有限公司发货申请单" center style="min-height: 700px" width="60%">
<el-form ref="invoiceFrom" :model="invoiceFrom" :rules="invoiceFromRules" label-position="left" label-width="110px">
<el-row>
<el-form-item label="发货单号" prop="发货单号" style="display: inline-block" label-width="80px">
<el-input
v-model="invoiceFrom.发货单号"
readonly
style="width: 200px;margin-right: 10px"
size="mini"/>
</el-form-item>
<el-form-item label="收货地址" prop="收货地址" style="display: inline-block" label-width="80px">
<el-input
v-model="invoiceFrom.收货地址"
readonly
clearable
size="mini"
style="width: 495px;margin-right: 10px"/>
</el-form-item>
</el-row>
<el-row>
<el-form-item label="发货单名" prop="发货单名" style="display: inline-block" label-width="80px">
<el-input
v-model="invoiceFrom.发货单名"
readonly
clearable
style="width: 200px;margin-right: 10px"
size="mini"/>
</el-form-item>
<el-form-item label="注意事项" prop="注意事项" style="display: inline-block" label-width="80px">
<el-input
v-model="invoiceFrom.注意事项"
readonly
clearable
style="width: 495px;margin-right: 10px"
size="mini"/>
</el-form-item>
</el-row>
<el-row>
<el-form-item label="收货单位" prop="收货单位" style="display: inline-block" label-width="80px">
<el-input
v-model="invoiceFrom.收货单位"
readonly
clearable
style="width: 200px;margin-right: 10px"
size="mini"/>
</el-form-item>
<el-form-item label="收货人员" prop="收货人员" style="display: inline-block" label-width="80px">
<el-input
v-model="invoiceFrom.收货人员"
readonly
clearable
size="mini"
style="width: 200px;margin-right: 10px"/>
</el-form-item>
<el-form-item label="联系电话" prop="联系电话" style="display: inline-block" label-width="80px">
<el-input
v-model="invoiceFrom.联系电话"
:trigger-on-focus="false"
readonly
clearable
size="mini"
style="width: 200px;margin-right: 10px"/>
</el-form-item>
</el-row>
<el-row>
<el-form-item label="车辆牌号" prop="车辆牌号" style="display: inline-block" label-width="80px">
<el-input
v-model="invoiceFrom.车辆牌号"
:disabled="disabled"
size="mini"
style="width: 200px;margin-right: 10px"
clearable
placeholder="请输入内容"/>
</el-form-item>
<el-form-item label="司机姓名" prop="司机姓名" style="display: inline-block" label-width="80px">
<el-input
v-model="invoiceFrom.司机姓名"
:disabled="disabled"
size="mini"
style="width: 200px;margin-right: 10px"
clearable
placeholder="请输入内容"/>
</el-form-item>
<el-form-item label="司机电话" prop="司机电话" style="display: inline-block" label-width="80px">
<el-input
v-model="invoiceFrom.司机电话"
:disabled="disabled"
size="mini"
style="width: 200px;margin-right: 10px"
clearable
placeholder="请输入内容"/>
</el-form-item>
</el-row>
<el-row style="margin-top: 15px">
<el-form-item label="备注" prop="备注" style="display: inline-block" label-width="80px">
<el-input
v-model="invoiceFrom.备注"
:disabled="disabled"
size="mini"
style="width: 788px;margin-right: 10px"
clearable
placeholder="请输入内容"/>
</el-form-item>
<el-button :disabled="disabled" type="success" size="mini" style="margin-left: 5px" @click="confirmation('invoiceFrom')">确认发货</el-button>
<el-button :disabled="disabledDetailsDelete" type="danger" size="mini" @click="wiverOfConfirmation">打回确认</el-button>
</el-row>
</el-form>
<div/>
<el-divider/>
<div>
<el-table
:data="tableDataDelivery"
highlight-current-row
style="width: 100%"
height="300"
border
size="mini">
<el-table-column align="center" label="货品类别" width="80">
<template slot-scope="scope">
<el-tag effect="dark" size="small" type="success">{{ scope.row.货品类别 }}</el-tag>
</template>
</el-table-column>
<el-table-column align="center" label="货品编号">
<template slot-scope="scope">
{{ scope.row.货品编号 }}
</template>
</el-table-column>
<el-table-column align="center" label="货品名称">
<template slot-scope="scope">
{{ scope.row.货品名称 }}
</template>
</el-table-column>
<el-table-column align="center" label="货品规格">
<template slot-scope="scope">
{{ scope.row.货品规格 }}
</template>
</el-table-column>
<el-table-column align="center" label="货品型号">
<template slot-scope="scope">
{{ scope.row.货品型号 }}
</template>
</el-table-column>
<el-table-column align="center" label="数量" width="80">
<template slot-scope="scope">
<template>
{{ scope.row.数量 }}
</template>
</template>
</el-table-column>
<el-table-column align="center" label="设计者" width="80">
<template slot-scope="scope">
{{ scope.row.设计者 }}
</template>
</el-table-column>
</el-table>
</div>
<el-divider/>
<el-row>
<div class="text">
<span>制单人</span>
<span>{{ isMaker }}</span>
<el-divider direction="vertical"/>
<span style="margin-left: 10px">核准人</span>
<span>{{ isExamine }}</span>
<el-divider direction="vertical"/>
<span style="margin-left: 10px">发货执行人</span>
<span>{{ isDelive }}</span>
<el-divider direction="vertical"/>
<span>制单时间</span>
<span>{{ MakerTime }}</span>
<el-divider direction="vertical"/>
<span style="margin-left: 10px">核准时间</span>
<span>{{ ExamineTime }}</span>
<el-divider direction="vertical"/>
<span style="margin-left: 10px">发货时间</span>
<span>{{ DeliveTime }}</span>
</div>
</el-row>
</el-dialog>
</div>
</template>
<!--<el-button-->
<!--:disabled="disabledDetailsDelete"-->
<!--size="mini"-->
<!--type="text"-->
<!--icon="el-icon-delete-solid"-->
<!--@click.native.prevent="deleteRow(scope.$index, tableData)"-->
<!--&gt;删除</el-button>-->
<script>
import { InvoiceListSearch, DetailsFeach, confirmation, reconfirmation } from '@/api/Assembly/DeliveryConfirmation'
import { mapGetters } from 'vuex'
export default {
data() {
return {
disabledDetailsDelete: false,
disabled: false,
isMaker: '',
isDelive: '',
isExamine: '',
MakerTime: '',
ExamineTime: '',
DeliveTime: '',
invoiceNum: '',
tableDataDelivery: [],
dialogFormVisible: false,
pageCurrent: 1,
pageSize: 10,
total: null,
invoiceFrom: {
发货单号: '',
收货地址: '',
发货单名: '',
收货单位: '',
注意事项: '',
车辆牌号: '',
司机姓名: '',
司机电话: '',
收货人员: '',
联系电话: '',
备注: ''
},
invoiceFromRules: {
司机姓名: [{ required: true, message: '请输入司机姓名', trigger: 'blur' }],
司机电话: [{ required: true, message: '请输入司机电话', trigger: 'blur' }],
车辆牌号: [{ required: true, message: '请输入车辆牌号', trigger: 'blur' }]
},
searchFrom: {
发货单名: '',
发货单号: '',
收货单位: '',
车辆牌号: '',
司机姓名: '',
司机电话: '',
制单人: '',
核准人: '',
执行人: '',
开始制单日期: '',
结束制单日期: '',
开始核准日期: '',
结束核准日期: '',
开始发货日期: '',
结束发货日期: '',
发货单名_check: null,
发货单号_check: null,
收货单位_check: null,
车辆牌号_check: null,
司机姓名_check: null,
司机电话_check: null,
制单人_check: null,
核准人_check: null,
执行人_check: null,
开始制单日期_check: null,
结束制单日期_check: null,
开始核准日期_check: null,
结束核准日期_check: null,
开始发货日期_check: null,
结束发货日期_check: null
},
DeliveryStatusValue_check: null,
tableDataSearchList: [],
listLoading: false,
DeliveryStatusValue: '',
DeliveryStatus: [{
value: 1,
label: '已发货'
},
{
value: 2,
label: '未发货'
}]
}
},
computed: {
...mapGetters([
'name',
'id'// 人员编号
])
},
methods: {
clearSearch() {
this.DeliveryStatusValue = ''
this.searchFrom.发货单名 = ''
this.searchFrom.发货单号 = ''
this.searchFrom.收货单位 = ''
this.searchFrom.车辆牌号 = ''
this.searchFrom.司机姓名 = ''
this.searchFrom.司机电话 = ''
this.searchFrom.制单人 = ''
this.searchFrom.核准人 = ''
this.searchFrom.执行人 = ''
this.searchFrom.开始制单日期 = ''
this.searchFrom.结束制单日期 = ''
this.searchFrom.开始核准日期 = ''
this.searchFrom.结束核准日期 = ''
this.searchFrom.开始发货日期 = ''
this.searchFrom.结束发货日期 = ''
},
search() {
this.tableDataSearchList = []
this.DeliveryStatusValue !== null && this.DeliveryStatusValue !== '' ? this.DeliveryStatusValue_check = 1 : this.DeliveryStatusValue_check = 0
this.DeliveryStatusValue === null ? this.DeliveryStatusValue = '' : this.DeliveryStatusValue
this.searchFrom.发货单名 !== null && this.searchFrom.发货单名 !== '' ? this.searchFrom.发货单名_check = 1 : this.searchFrom.发货单名_check = 0
this.searchFrom.发货单号 !== null && this.searchFrom.发货单号 !== '' ? this.searchFrom.发货单号_check = 1 : this.searchFrom.发货单号_check = 0
this.searchFrom.收货单位 !== null && this.searchFrom.收货单位 !== '' ? this.searchFrom.收货单位_check = 1 : this.searchFrom.收货单位_check = 0
this.searchFrom.车辆牌号 !== null && this.searchFrom.车辆牌号 !== '' ? this.searchFrom.车辆牌号_check = 1 : this.searchFrom.车辆牌号_check = 0
this.searchFrom.司机姓名 !== null && this.searchFrom.司机姓名 !== '' ? this.searchFrom.司机姓名_check = 1 : this.searchFrom.司机姓名_check = 0
this.searchFrom.司机电话 !== null && this.searchFrom.司机电话 !== '' ? this.searchFrom.司机电话_check = 1 : this.searchFrom.司机电话_check = 0
this.searchFrom.制单人 !== null && this.searchFrom.制单人 !== '' ? this.searchFrom.制单人_check = 1 : this.searchFrom.制单人_check = 0
this.searchFrom.核准人 !== null && this.searchFrom.核准人 !== '' ? this.searchFrom.核准人_check = 1 : this.searchFrom.核准人_check = 0
this.searchFrom.执行人 !== null && this.searchFrom.执行人 !== '' ? this.searchFrom.执行人_check = 1 : this.searchFrom.执行人_check = 0
this.searchFrom.开始制单日期 !== null && this.searchFrom.开始制单日期 !== '' ? this.searchFrom.开始制单日期_check = 1 : this.searchFrom.开始制单日期_check = 0
this.searchFrom.结束制单日期 !== null && this.searchFrom.结束制单日期 !== '' ? this.searchFrom.结束制单日期_check = 1 : this.searchFrom.结束制单日期_check = 0
this.searchFrom.开始核准日期 !== null && this.searchFrom.开始核准日期 !== '' ? this.searchFrom.开始核准日期_check = 1 : this.searchFrom.开始核准日期_check = 0
this.searchFrom.结束核准日期 !== null && this.searchFrom.结束核准日期 !== '' ? this.searchFrom.结束核准日期_check = 1 : this.searchFrom.结束核准日期_check = 0
this.searchFrom.开始发货日期 !== null && this.searchFrom.开始发货日期 !== '' ? this.searchFrom.开始发货日期_check = 1 : this.searchFrom.开始发货日期_check = 0
this.searchFrom.结束发货日期 !== null && this.searchFrom.结束发货日期 !== '' ? this.searchFrom.结束发货日期_check = 1 : this.searchFrom.结束发货日期_check = 0
this.listLoading = true
InvoiceListSearch(this.searchFrom.发货单名, this.searchFrom.发货单号, this.searchFrom.收货单位, this.searchFrom.车辆牌号, this.searchFrom.司机姓名, this.searchFrom.司机电话, this.searchFrom.制单人, this.searchFrom.核准人, this.searchFrom.执行人, this.searchFrom.开始制单日期, this.searchFrom.结束制单日期, this.searchFrom.开始核准日期, this.searchFrom.结束核准日期, this.searchFrom.开始发货日期, this.searchFrom.结束发货日期, this.searchFrom.发货单名_check, this.searchFrom.发货单号_check, this.searchFrom.收货单位_check, this.searchFrom.车辆牌号_check, this.searchFrom.司机姓名_check, this.searchFrom.司机电话_check, this.searchFrom.制单人_check, this.searchFrom.核准人_check, this.searchFrom.执行人_check, this.searchFrom.开始制单日期_check, this.searchFrom.结束制单日期_check, this.searchFrom.开始核准日期_check, this.searchFrom.结束核准日期_check, this.searchFrom.开始发货日期_check, this.searchFrom.结束发货日期_check, this.DeliveryStatusValue_check, this.DeliveryStatusValue, this.pageCurrent, this.pageSize).then(response => {
if (response.data.rows.length !== 0) {
this.listLoading = false
this.tableDataSearchList = response.data.rows
this.total = response.data.total
}
})
},
handleSizeChange(val) {
this.pageCurrent = 1
this.pageSize = val
this.search()
},
handleCurrentChange(val) {
this.pageCurrent = val
this.search()
},
openDialogFormVisible(row) {
this.addForm('invoiceFrom')
row.是否发出.toString() === '1' ? this.disabled = true : this.disabled = false
row.是否发出.toString() === '1' ? this.disabledDetailsDelete = false : this.disabledDetailsDelete = true
this.invoiceFrom.发货单号 = row.发货单编号
this.invoiceFrom.收货地址 = row.收货地址
this.invoiceFrom.收货单位 = row.收货单位
this.invoiceFrom.发货单名 = row.发货单名称
this.invoiceFrom.注意事项 = row.注意事项
this.invoiceFrom.车辆牌号 = row.车辆牌号
this.invoiceFrom.司机姓名 = row.司机姓名
this.invoiceFrom.司机电话 = row.司机电话
this.invoiceFrom.收货人员 = row.收货人员
this.invoiceFrom.联系电话 = row.联系电话
this.invoiceFrom.备注 = row.备注
this.isMaker = row.制单人
this.isDelive = row.执行人
this.isExamine = row.审核人
this.MakerTime = row.操作日期
this.ExamineTime = row.审核日期
this.DeliveTime = row.发出时间
this.invoiceNum = row.发货单流水号
this.dialogFormVisible = true
DetailsFeach(this.invoiceNum).then(response => {
this.tableDataDelivery = response.data
})
},
confirmation(formName) {
this.invoiceFrom.司机姓名 === null ? this.invoiceFrom.司机姓名 = '' : this.invoiceFrom.司机姓名
this.invoiceFrom.司机电话 === null ? this.invoiceFrom.司机电话 = '' : this.invoiceFrom.司机电话
this.invoiceFrom.车辆牌号 === null ? this.invoiceFrom.车辆牌号 = '' : this.invoiceFrom.车辆牌号
this.invoiceFrom.备注 === null ? this.invoiceFrom.备注 = '' : this.invoiceFrom.备注
this.$refs[formName].validate((valid) => {
if (valid) {
this.$confirm('请确认货物是否全部发出, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
confirmation(this.invoiceNum, this.invoiceFrom.司机姓名, this.invoiceFrom.司机电话, this.invoiceFrom.车辆牌号, this.name, this.invoiceFrom.备注).then(response => {
if (response.data[0].result === '1') {
this.$message.success('发货确认成功!')
this.disabled = true
this.disabledDetailsDelete = false
DetailsFeach(this.invoiceNum).then(response => {
this.tableDataDelivery = response.data
})
this.search()
} else {
this.$message.error('发货确认失败!')
}
})
})
}
})
},
wiverOfConfirmation() {
this.$confirm('请确认货物是否全部发出, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
reconfirmation(this.invoiceNum).then(response => {
if (response.data[0].result === '1') {
this.$message.success('打回成功!')
this.disabled = false
this.disabledDetailsDelete = true
DetailsFeach(this.invoiceNum).then(response => {
this.tableDataDelivery = response.data
})
this.search()
} else {
this.$message.success('打回失败!')
}
})
})
}
}
}
</script>
<style>
.el-form-item{
margin-bottom: 2px;
}
</style>
<style scoped>
.text{
font-size: 14px;
}
</style>

View File

@@ -29,7 +29,7 @@
<el-form ref="form" :model="form" :rules="rules" label-position="left" label-width="110px" class="demo-ruleForm">
<el-row>
<el-form-item label="选择模块名称" prop="选择模块名称">
<el-select v-model="modelName" size="mini" clearable placeholder="请选择模块名称" filterable @change="getModelData">
<el-select v-model="modelName" size="mini" clearable placeholder="请选择模块名称" filterable @change="getModelData" @clear="clearModel">
<el-option
v-for="item in modelNames"
:key="item.value"
@@ -108,6 +108,9 @@ export default {
this.getAllModules()
},
methods: {
clearModel() {
this.modelName = ''
},
getRoleName() {
getRole().then(response => {
for (let i = 0; i < response.data.length; i++) {

View File

@@ -221,13 +221,19 @@
{{ scope.row.领料单备注 }}
</template>
</el-table-column>
<el-table-column v-if="Number(token)===21" label="审批" align="center" min-width="90">
<template slot-scope="scope">
<el-tag v-if="Number(scope.row.是否审批)===1" type="success">已审批</el-tag>
<el-button v-else size="mini" type="primary" plain icon="el-icon-check" @click="approvalPass(scope.row)">审批</el-button>
</template>
</el-table-column>
<el-table-column label="领回确认" align="center" min-width="80">
<template slot-scope="scope">
<el-tag v-if="Number(scope.row.是否启用)===1" type="warning">未确认</el-tag>
<el-tag v-else type="success">已确认</el-tag>
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="200px">
<el-table-column label="操作" align="center" width="220px">
<template slot-scope="scope" align="center">
<el-button :disabled="Number(scope.row.是否启用)===0" size="mini" type="primary" icon="el-icon-check" @click="checkList(scope.row)">确认</el-button>
<el-button :disabled="Number(scope.row.是否启用)===0" size="mini" type="danger" icon="el-icon-delete" @click="dropList(scope.row)">删除</el-button>
@@ -321,6 +327,7 @@
<script>
import { initPickPerson, initMachineProject, searchgroup, searchTable, searchList, createList, dropList, selectIntoList, searchListDetail, dropListDetail } from '@/api/Inventory/CreatePickingList'
import request from '@/utils/request'
import { mapGetters } from 'vuex'
export default {
name: 'CreatePickingList',
data() {
@@ -362,12 +369,49 @@ export default {
multipleSelection: []
}
},
computed: {
...mapGetters([
'id',
'token'
])
},
mounted() {
this.fetchData()
this.searchTable()
this.searchList()
},
methods: {
// 审批通过
approvalPass(row) {
this.$confirm('是否审批通过?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
const param = {
url: '',
method: 'post',
data: {
type: '4',
name: `update 车间装配管理_领料单 set 是否审批 = 1 where 领料单流水号 = ${row.领料单流水号}`
}
}
request(param).then(res => {
if (res.data[0].result === '1') {
this.$message.success('操作成功')
this.pickingListNumber = ''
this.searchList()
} else {
this.$message.error('操作失败')
}
})
}).catch(() => {
this.$message({
type: 'info',
message: '已取消操作'
})
})
},
// 初始化数据
fetchData() {
initPickPerson().then(response => {

View File

@@ -2,37 +2,51 @@
<div class="app-container">
<el-card>
<div slot="header" class="clearfix">
<span>项目名称:</span>
<el-select v-model="projectValue" style="width:150px" placeholder="请选择" size="small" clearable filterable @change="projectChange">
<el-option
v-for="item in project"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<span>机床图号:</span>
<el-select v-model="machineValue" style="width:150px" placeholder="请选择" size="small" clearable filterable @change="machineChange">
<el-option
v-for="item in machine"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<span>组号:</span>
<el-select v-model="groupValue" style="width:140px" placeholder="请选择" size="small" clearable filterable>
<el-option
v-for="item in group"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<span>名称:</span>
<el-input v-model="name" clearable size="small" style="width:150px" />
<span>规格:</span>
<el-input v-model="spec" clearable size="small" style="width:150px" />
<span>图号或型号:</span>
<el-input v-model="model" clearable size="small" style="width:150px" />
<el-button type="success" icon="el-icon-search" size="small" style="margin-left: 10px" @click="searchRecord()">查询</el-button>
<el-row style="margin-bottom:10px">
<el-col style="width:250px">
<span>项目名称:</span>
<el-select v-model="projectValue" style="width:150px" placeholder="请选择" size="small" clearable filterable @change="projectChange">
<el-option
v-for="item in project"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
</el-col>
<el-col style="width:250px">
<span>机床图号:</span>
<el-select v-model="machineValue" style="width:150px" placeholder="请选择" size="small" clearable filterable @change="machineChange">
<el-option
v-for="item in machine"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
</el-col>
<el-col style="width:250px">
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:</span>
<el-select v-model="groupValue" style="width:150px" placeholder="请选择" size="small" clearable filterable>
<el-option
v-for="item in group"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
</el-col>
</el-row>
<el-row style="margin-bottom:10px">
<el-col style="width:250px">
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:</span>
<el-input v-model="name" clearable size="small" style="width:150px" />
</el-col>
<el-col style="width:250px">
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:</span>
<el-input v-model="spec" clearable size="small" style="width:150px" />
</el-col>
<span>图号或型号:</span>
<el-input v-model="model" clearable size="small" style="width:150px" />
<el-button type="success" icon="el-icon-search" size="small" style="margin-left: 10px" @click="searchRecord()">查询</el-button>
</el-row>
</div>
<h4 style="margin-top: 0">采购合同件</h4>
<el-table :data="tableData1" border size="mini" style="width: 100%;" height="400">

View File

@@ -2,48 +2,66 @@
<div class="app-container">
<el-card>
<div slot="header" class="clearfix">
<span>项目名称:</span>
<el-select v-model="projectValue" style="width:150px" placeholder="请选择" size="small" clearable filterable @change="projectChange">
<el-option
v-for="item in project"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<span>机床图号:</span>
<el-select v-model="machineValue" style="width:150px" placeholder="请选择" size="small" clearable filterable @change="machineChange">
<el-option
v-for="item in machine"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<span>组号:</span>
<el-select v-model="groupValue" style="width:140px" placeholder="请选择" size="small" clearable filterable>
<el-option
v-for="item in group"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<span>名称:</span>
<el-input v-model="name" clearable size="small" style="width:150px" />
<span>规格:</span>
<el-input v-model="spec" clearable size="small" style="width:150px" />
<span>图号或型号:</span>
<el-input v-model="model" clearable size="small" style="width:150px" />
<span>出库时间:</span>
<el-date-picker
v-model="outTime"
type="daterange"
size="small"
format="yyyy-MM-dd"
value-format="yyyy-MM-dd"
range-separator="~"
style="width:250px"
start-placeholder=""
end-placeholder=""/>
<el-button type="success" icon="el-icon-search" size="small" style="margin-left: 10px" @click="pageCurrent1=1;pageSize1=10;searchRecord()">查询</el-button>
<el-row style="margin-bottom:10px">
<el-col style="width:250px">
<span>项目名称:</span>
<el-select v-model="projectValue" style="width:150px" placeholder="请选择" size="small" clearable filterable @change="projectChange">
<el-option
v-for="item in project"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
</el-col>
<el-col style="width:250px">
<span>机床图号:</span>
<el-select v-model="machineValue" style="width:150px" placeholder="请选择" size="small" clearable filterable @change="machineChange">
<el-option
v-for="item in machine"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
</el-col>
<el-col style="width:250px">
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:</span>
<el-select v-model="groupValue" style="width:150px" placeholder="请选择" size="small" clearable filterable>
<el-option
v-for="item in group"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
</el-col>
</el-row>
<el-row style="margin-bottom:10px">
<el-col style="width:250px">
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:</span>
<el-input v-model="name" clearable size="small" style="width:150px" />
</el-col>
<el-col style="width:250px">
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;:</span>
<el-input v-model="spec" clearable size="small" style="width:150px" />
</el-col>
<el-col style="width:250px">
<span>图号或型号:</span>
<el-input v-model="model" clearable size="small" style="width:150px" />
</el-col>
</el-row>
<el-row>
<span>出库时间:</span>
<el-date-picker
v-model="outTime"
type="daterange"
size="small"
format="yyyy-MM-dd"
value-format="yyyy-MM-dd"
range-separator="~"
style="width:250px"
start-placeholder=""
end-placeholder=""/>
<el-button type="success" icon="el-icon-search" size="small" style="margin-left: 10px" @click="pageCurrent1=1;pageSize1=10;searchRecord()">查询</el-button>
</el-row>
</div>
<el-table :data="tableData" border size="mini" style="width: 100%;" height="600">
<el-table-column label="名称" align="center" min-width="200">

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,13 @@
<template>
<div>123</div>
</template>
<script>
export default {
name: 'OutsourcingQCSearch'
}
</script>
<style scoped>
</style>

View File

@@ -92,9 +92,9 @@
{{ scope.row.机床图号 }}
</template>
</el-table-column>
<el-table-column label="机床设计者" align="center" min-width="90">
<el-table-column label="设计者" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.机床设计者 || '—' }}
{{ scope.row.组件设计者 || scope.row.机床设计者 || '—' }}
</template>
</el-table-column>
<el-table-column label="组号" align="center" min-width="80">
@@ -275,9 +275,9 @@
{{ scope.row.机床图号 }}
</template>
</el-table-column>
<el-table-column label="机床设计者" align="center" min-width="90">
<el-table-column label="设计者" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.机床设计者 || '—' }}
{{ scope.row.组件设计者 || scope.row.机床设计者 || '—' }}
</template>
</el-table-column>
<el-table-column label="组号" align="center" min-width="80">

View File

@@ -72,24 +72,30 @@
</el-col>
</el-row>
<el-row>
<el-col :span="24">
<el-col :span="21">
<el-form-item label="其他说明:">
<el-input v-model="otherInfo" :disabled="!contractNumValue" size="small" type="textarea" rows="1" @blur="contractHeaderChange"/>
</el-form-item>
</el-col>
<el-col :span="1">
<el-button v-if="quickChangePrice" size="mini" style="margin: 10px 0 0 10px" @click="quickChangePrice=!quickChangePrice">快速修改价格</el-button>
<el-button v-else size="mini" style="margin: 10px 0 0 10px" @click="quickChangePrice=!quickChangePrice">还原</el-button>
</el-col>
</el-row>
</el-form>
<el-table :data="tableData1" border style="margin: 10px 0;max-height: 480px;" height="480px" size="mini" show-summary>
<el-table :data="tableData1" border style="margin: 10px 0;max-height: 480px;" height="480px" size="mini" show-summary tooltip-effect="dark">
<el-table-column label="序号" align="center" width="50" type="index"/>
<el-table-column label="交货期" align="center" width="150">
<template slot-scope="scope">
<el-date-picker
v-if="quickChangePrice"
v-model="scope.row.交货期"
size="mini"
type="date"
format="yyyy-MM-dd"
value-format="yyyy-MM-dd"
style="width:100%"/>
<b v-else>{{ scope.row.交货期.split(' ')[0] || '' }}</b>
</template>
</el-table-column>
<el-table-column label="机床图号" align="center" min-width="100">
@@ -97,7 +103,7 @@
{{ scope.row.机床图号 }}
</template>
</el-table-column>
<el-table-column label="组号" align="center" min-width="80">
<el-table-column label="组号" align="center" width="70">
<template slot-scope="scope">
{{ scope.row.组号 }}
</template>
@@ -107,7 +113,7 @@
{{ scope.row.名称 }}
</template>
</el-table-column>
<el-table-column label="图号或型号" align="center" min-width="150">
<el-table-column label="图号或型号" align="center" min-width="100">
<template slot-scope="scope">
{{ scope.row.图号 ? scope.row.图号 : '—' }}
</template>
@@ -122,20 +128,20 @@
{{ scope.row.数量 }}
</template>
</el-table-column>
<el-table-column label="单位" align="center" width="80">
<el-table-column label="单位" align="center" width="70">
<template slot-scope="scope">
{{ scope.row.计量单位 }}
</template>
</el-table-column>
<el-table-column v-show="hasTax==='未税'" label="单价(未税)" align="center" width="120">
<template slot-scope="scope">
<el-input-number v-show="hasTax==='未税'" :min="0" v-model="scope.row.未税单价" controls-position="right" size="mini" style="width:100%" @focus="scope.row.未税单价=''" @change="priceChange(scope.row.未税单价, scope.row.物料流水号, scope.row.询价单流水号, scope.row, scope.row.零件名称, scope.row.零件图号, scope.row.规格)"/>
<el-input-number v-show="hasTax==='未税'" :min="0" v-model="scope.row.未税单价" controls-position="right" size="mini" style="width:100%" @change="priceChange(scope.row.未税单价, scope.row.物料流水号, scope.row.询价单流水号, scope.row, scope.row.零件名称, scope.row.零件图号, scope.row.规格)"/>
<b v-show="hasTax!=='未税'"></b>
</template>
</el-table-column>
<el-table-column v-show="hasTax==='含税'" label="单价(含税)" align="center" width="120">
<template slot-scope="scope">
<el-input-number v-show="hasTax==='含税'" :min="0" v-model="scope.row.含税单价" controls-position="right" size="mini" style="width:100%" @focus="scope.row.含税单价=''" @change="priceChange(scope.row.含税单价, scope.row.物料流水号, scope.row.询价单流水号, scope.row, scope.row.零件名称, scope.row.零件图号, scope.row.规格)"/>
<el-input-number v-show="hasTax==='含税'" :min="0" v-model="scope.row.含税单价" controls-position="right" size="mini" style="width:100%" @change="priceChange(scope.row.含税单价, scope.row.物料流水号, scope.row.询价单流水号, scope.row, scope.row.零件名称, scope.row.零件图号, scope.row.规格)"/>
<b v-show="hasTax!=='含税'"></b>
</template>
</el-table-column>
@@ -149,9 +155,10 @@
{{ hasTax==='含税' ? scope.row.含税总额 = (Number(scope.row.数量) * Number(scope.row.含税单价)).toFixed(2) : scope.row.含税总额 = (scope.row.未税总额 * (1+taxRate)).toFixed(2) }}
</template>
</el-table-column>
<el-table-column label="备注" align="center" width="80">
<el-table-column label="备注" align="center" min-width="80" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.备注 }}
<el-input v-if="quickChangePrice" v-model="scope.row.备注" size="mini" style="width:100%" @change="remarkChange(scope.row.备注, scope.row.物料流水号, scope.row.询价单流水号, scope.row, scope.row.零件名称, scope.row.零件图号, scope.row.规格)"/>
<b v-else>{{ scope.row.备注 || '' }}</b>
</template>
</el-table-column>
</el-table>
@@ -185,7 +192,7 @@
<script>
import Tinymce from '@/components/Tinymce'
import { initSupplier, searchInquirySheet, searchSheetContract, doneContract, searchBaseInfo, savePrice, saveContractHeader, searchContractHeader } from '@/api/PurchasingCenter/CreatePurchaseContract'
import { initSupplier, searchInquirySheet, searchSheetContract, doneContract, searchBaseInfo, savePrice, saveContractHeader, searchContractHeader, saveRemark } from '@/api/PurchasingCenter/CreatePurchaseContract'
import { convertCurrency } from '@/vendor/int2Chinese'
import { mapGetters } from 'vuex'
import { sleep, groupBy } from '@/utils/tool'
@@ -196,6 +203,7 @@ export default {
inject: ['reload'],
data() {
return {
quickChangePrice: true,
supplier: [],
year: '',
month: '',
@@ -244,6 +252,7 @@ export default {
数量组: [],
单价组: [],
交货期组: [],
备注组: [],
companyAddress: '',
sendAddress: ''
}
@@ -270,6 +279,37 @@ export default {
})
}
},
// 备注实时保存
remarkChange(remark, num1, num2, row, num3, num4, num5) {
this.tableData1.map(v => {
v.物料流水号 = v.物料流水号 || ''
v.零件名称 = v.零件名称 || ''
v.零件图号 = v.零件图号 || ''
v.规格 = v.规格 || ''
row.物料流水号 = row.物料流水号 || ''
row.零件名称 = row.零件名称 || ''
row.零件图号 = row.零件图号 || ''
row.规格 = row.规格 || ''
if (Number(v.物料流水号) === Number(row.物料流水号) && Number(v.询价单流水号) === Number(row.询价单流水号) && v.零件名称 === row.零件名称 && v.零件图号 === row.零件图号 && v.规格 === row.规格) {
v.备注 = row.备注
}
})
const group = this.tableData1
this.tableData1 = []
this.tableData1 = group
remark = remark || ''
num1 = num1 || ''
num3 = num3 || ''
num4 = num4 || ''
num5 = num5 || ''
saveRemark(remark, num1, num2, num3, num4, num5).then(res => {
if (res.data[0].result === '1') {
console.log('备注实时保存成功')
} else {
console.log('备注实时保存失败')
}
})
},
// 价格实时保存
priceChange(price, num1, num2, row, num3, num4, num5) {
this.tableData1.map(v => {
@@ -733,6 +773,7 @@ export default {
this.数量组.push(v.数量)
this.hasTax === '含税' ? this.单价组.push(v.含税单价) : this.单价组.push(v.未税单价)
this.交货期组.push(v.交货期)
this.备注组.push(v.备注)
} else { // 获取未询到价格的物料的询价单明细流水号们
inquiryDetailNum_old.push(v.询价单明细流水号)
}
@@ -743,7 +784,7 @@ export default {
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
doneContract(this.contractNum, this.contractName, this.deliveryDate, this.payDate, this.payMethod, this.invoiceInfo, this.otherInfo, this.actualTotal, this.id, this.supplierValue, this.单价是否含税, this.组件零件流水号组, this.组件零件基本件流水号组, this.数量组, this.单价组, this.交货期组, this.content, this.taxRate * 100, inquiryDetailNum_old).then(response => {
doneContract(this.contractNum, this.contractName, this.deliveryDate, this.payDate, this.payMethod, this.invoiceInfo, this.otherInfo, this.actualTotal, this.id, this.supplierValue, this.单价是否含税, this.组件零件流水号组, this.组件零件基本件流水号组, this.数量组, this.单价组, this.交货期组, this.content, this.taxRate * 100, inquiryDetailNum_old, this.备注组).then(response => {
if (response.data[0].result === '1') {
this.$message.success('合同生成成功')
this.reload()

View File

@@ -355,6 +355,8 @@
</el-tooltip>
<el-input v-model="taxRate" style="float:right;width:100px" placeholder="税率" size="mini"/>
<h4 style="float:right;width: 40px;margin: 5px">税率:</h4>
<el-button v-if="quickChangePrice" size="mini" style="float:right;" @click="quickChangePrice=!quickChangePrice">快速修改价格</el-button>
<el-button v-else size="mini" style="float:right;" @click="quickChangePrice=!quickChangePrice">还原</el-button>
</div>
<el-table v-loading="" :data="tableData3" :summary-method="getSummaries" border style="max-height: 500px;" height="500px" size="mini" show-summary>
<el-table-column label="离线合同编号" align="center" min-width="150">
@@ -369,17 +371,18 @@
</el-table-column>
<el-table-column label="物料规格" align="center" min-width="100">
<template slot-scope="scope">
{{ scope.row.物料规格 }}
{{ scope.row.物料规格 || '—' }}
</template>
</el-table-column>
<el-table-column label="物料型号" align="center" min-width="200">
<template slot-scope="scope">
{{ scope.row.物料型号 }}
{{ scope.row.物料型号 || '—' }}
</template>
</el-table-column>
<el-table-column label="数量" align="center" min-width="100">
<template slot-scope="scope">
<el-input v-model="scope.row.数量" :disabled="disable" size="mini" style="width:70px"/>
<el-input v-if="quickChangePrice" v-model="scope.row.数量" :disabled="disable" size="mini" style="width:70px"/>
<b v-else>{{ scope.row.数量 }}</b>
</template>
</el-table-column>
<el-table-column label="单位" align="center" min-width="100">
@@ -416,12 +419,14 @@
</el-table-column>
<el-table-column label="交货期要求" align="center" min-width="100" prop="交货期要求">
<template slot-scope="scope">
<el-input v-model="scope.row.交货期要求" :disabled="disable" size="mini" style="width:70px"/>
<el-input v-if="quickChangePrice" v-model="scope.row.交货期要求" :disabled="disable" size="mini" style="width:70px"/>
<b v-else>{{ scope.row.交货期要求 || '—' }}</b>
</template>
</el-table-column>
<el-table-column label="备注" align="center" min-width="150" prop="备注">
<template slot-scope="scope">
<el-input v-model="scope.row.备注" :disabled="disable" size="mini" style="width:120px"/>
<el-input v-if="quickChangePrice" v-model="scope.row.备注" :disabled="disable" size="mini" style="width:120px"/>
<b v-else>{{ scope.row.备注 || '—' }}</b>
</template>
</el-table-column>
<el-table-column v-if="disable" label="到货数量" align="center" min-width="100">
@@ -431,7 +436,8 @@
</el-table-column>
<el-table-column label="操作" align="center" min-width="100">
<template slot-scope="scope">
<el-button :disabled="disable" type="danger" size="mini" icon="el-icon-delete" @click="deleteMateriel(scope.row)">移除</el-button>
<el-button v-if="quickChangePrice" :disabled="disable" type="danger" size="mini" icon="el-icon-delete" @click="deleteMateriel(scope.row)">移除</el-button>
<b v-else>移除</b>
</template>
</el-table-column>
</el-table>
@@ -692,6 +698,7 @@ export default {
name: '', // 离线合同
data() {
return {
quickChangePrice: true,
hasTax: '含税',
taxRate: 0.13,
source: [

View File

@@ -1,23 +1,127 @@
<template>
<div class="dashboard-container">
<div class="dashboard-text">name:{{ name }}</div>
</div>
<el-card>
<div class="dashboard-container">
<div class="sudoku_row" >
<div class="dashboard-text">name:{{ name }}</div>
<el-divider content-position="right">消息通知</el-divider>
<el-card v-for="(sudoku,index) in sudokus" :class="curSelect==sudoku.id?'opacity':''" :key="index" shadow="hover" class="sudoku_item ">
<div>
<el-badge :value="sudoku.value">
<svg-icon :icon-class="sudoku.icon" style="border: 1px solid black;background-color: #555c66" />
<router-link :to="sudoku.router">{{ sudoku.name }}</router-link>
<!--<a size="small" type="text" href="/Assembly/DeliveryConfirmation">{{sudoku.name}}</a>-->
</el-badge>
</div>
<div/>
</el-card>
<el-divider content-position="right"/>
<!--<div class="sudoku_item " :class="curSelect==sudoku.id?'opacity':''" v-for="(sudoku,index) in sudokus" :key="index" @touchstart="touchstart(index)" @touchend="touchend">-->
<!--&lt;!&ndash;<img :src="sudoku.img_src" width="40" height="40" >&ndash;&gt;-->
<!---->
<!--</div>-->
</div>
</div>
</el-card>
</template>
<script>
import { mapGetters } from 'vuex'
import request from '@/utils/request'
export default {
name: 'Dashboard',
data() {
return {
sudokus: [],
curSelect: null,
number: '',
timer: ''
}
},
computed: {
...mapGetters([
'name'
'name',
'token'
])
},
mounted() {
this.getFileList()
this.timer = setInterval(this.getFileList, 60 * 60 * 1000) // 60 分钟一刷新
},
beforeDestroy() {
clearInterval(this.timer)
},
methods: {
async getFileList() {
await request({
url: '',
method: 'post',
data: {
type: '1',
name: '菜单系统模块_项目角色模块列表_消息通知',
param: '角色编号=' + this.token
}
}).then(data => {
this.sudokus = []
for (let i = 0; i < data.data.length; i++) {
this.getMessageNum(data.data[i].消息通知来源, data.data[i].通知条件, data, i)
}
})
},
async getMessageNum(tableName, condition, rawData, i) {
await request({
url: '',
method: 'post',
data: {
type: '3',
name: `select count(*) from ${tableName} where ${condition}`
}
}).then(res => {
this.sudokus.push({
id: rawData.data[i].主模块编号,
name: rawData.data[i].标题,
icon: rawData.data[i].图标,
router: `${rawData.data[i].父路径}/${rawData.data[i].子路径}`,
value: res.data[0].Column1
})
})
}
}
}
</script>
<style rel="stylesheet/scss" lang="scss" scoped>
.item {
margin-top: 10px;
margin-right: 40px;
}
.sudoku_row{
display: flex;
align-items: center;
width:100%;
flex-wrap: wrap;
}
.sudoku_item{
margin-bottom: 20px;
margin-left: 20px;
/*border: 1px solid red;*/
display: flex;
justify-content: center;
align-items: center;
flex-direction: column;
width:15%;
height: 200px;
padding-top: 10px;
padding-bottom: 10px;
}
.opacity{
opacity: 0.4;
background: #e5e5e5;
}
.sudoku_item img{
margin-bottom: 3px;
display: block;
}
.dashboard {
&-container {
margin: 30px;