This commit is contained in:
liushuai
2019-12-13 18:02:41 +08:00
parent 5fdad2834f
commit 0dbdfa1623
7 changed files with 60 additions and 52 deletions

View File

@@ -1,7 +1,7 @@
import request from '@/utils/request'
// 查询询价单号
export function getBillNum(num) {
export function getBillNum() {
return request({
url: '',
method: 'post',

View File

@@ -134,6 +134,17 @@ export function deleteMateriel(num) {
}
})
}
// 查询离线合同编号
export function getBillNum() {
return request({
url: '',
method: 'post',
data: {
type: '1',
name: '采购管理_创建离线合同编号_查询数据'
}
})
}
// 使用库存
export function changeNum(num, num1, num2, num3, num4) {
return request({

View File

@@ -26,7 +26,7 @@ export const downloadFileMachine = `http://192.168.1.231:8411/submit/downloadFil
export const MESUploadFile = `http://192.168.1.231:8411/submit/MESUploadFile.ashx`
export const MESDownloadFile = `http://192.168.1.231:8411/submit/MESDownloadFile.ashx`
const service = axios.create({
baseURL: `http://192.168.0.110:8002/submit/MESCommonBase.ashx`,
baseURL: `http://192.168.1.231:8411/submit/MESCommonBase.ashx`,
timeout: 1500000 // 请求超时时间
})
export default service

View File

@@ -42,6 +42,9 @@
<el-button v-else size="mini" style="margin: 10px 0 0 10px" @click="quickChangePrice=!quickChangePrice">还原</el-button>
<el-button v-show="isShowN" type="text" style="margin: 10px 0 0 10px" @click="isShowN=false">折叠</el-button>
<el-button v-show="!isShowN" type="text" style="margin: 10px 0 0 10px" @click="isShowN=true">展开其他说明</el-button>
<el-tooltip v-show="true" :open-delay="300" content="一键删除交货期" placement="right">
<el-button type="danger" icon="el-icon-date" size="small" @click="deleteAllDate()"/>
</el-tooltip>
</el-row>
<el-row v-show="isShowN" style="margin-top: 10px">
<!--<span>交货日期:</span>-->
@@ -135,9 +138,6 @@
</template>
</el-table-column>
</el-table>
<el-tooltip v-show="false" :open-delay="1000" content="一键删除交货期" placement="right">
<el-button type="danger" icon="el-icon-date" size="small" @click="deleteAllDate()"/>
</el-tooltip>
<el-radio-group v-show="false" v-model="demoRadio" size="small" @change="demoChange">
<el-radio-button label="模板1"/>
<el-radio-button label="模板2" disabled/>

View File

@@ -606,7 +606,7 @@
<script>
import { tiaozheng2, tiaozheng1, searchOfflineContract, searchOfflineContract2, searchSupplier, addOfflineContract, editOfflineContract, deleteOfflineContract, searchMateriel, searchMaterial1,
addMateriel, deleteMateriel, saveOfflineContact, doneOfflineContact, searchMaterial22, searchMachine, searchGroup, initProject, changeNum, submitUseInventory,
addMateriel, deleteMateriel, saveOfflineContact, doneOfflineContact, searchMaterial22, searchMachine, searchGroup, initProject, changeNum, submitUseInventory, getBillNum,
searchPart, getPerson, searchSupplier1 } from '@/api/PurchasingCenter/OfflineContract'
import QRCode from 'qrcode'
import $ from 'jquery'
@@ -1084,13 +1084,15 @@ export default {
}
this.getSupplier1()
this.title2 = '创建离线合同'
this.form2.离线合同编号 = ''
getBillNum().then(response => { // 查询询价单号
this.form2.离线合同编号 = response.data[0].单号
this.form2.离线合同名称 = ''
this.form2.供应商流水号 = ''
this.form2.供应商名称 = ''
this.form2.规定到货时间 = ''
this.form2.离线合同备注 = '付款方式:;付款时间:;到货时间:;开票信息:;其他说明:;'
this.dialogVisible2 = true
})
},
getSupplier1() {
this.supplierNames = []

View File

@@ -57,8 +57,8 @@
<el-card style="margin-left: 10px;width: 62.3%;float: left">
<div> <!--slot="header"-->
<el-input v-model="purchasingOrder" placeholder="采购计划单号" size="small" style="margin: 3px 0" clearable/>
<el-select v-model="supplierName0" placeholder="供应商" size="small" filterable clearable>
<el-input v-model="purchasingOrder" placeholder="采购计划单号" size="small" style="margin: 3px 0;width: 155px" clearable @keyup.enter.native="pageCurrent2=1;pageSize2=10;total2=0;searchTable2()"/>
<el-select v-model="supplierName0" placeholder="供应商" size="small" filterable clearable @change="pageCurrent2=1;pageSize2=10;total2=0;searchTable2()">
<el-option
v-for="item in supplierName0s"
:key="item.value"
@@ -66,9 +66,9 @@
:value="item.value"/>
</el-select>
<!--<el-input v-model="supplierName0" placeholder="供应商" size="small" clearable/>-->
<el-tooltip :open-delay="1200" effect="dark" content="查询采购计划单" placement="top">
<el-button type="success" size="small" icon="el-icon-search" style="margin-left: 10px" @click="pageCurrent2=1;pageSize2=10;total2=0;searchTable2()">查询</el-button>
</el-tooltip>
<!--<el-tooltip :open-delay="1200" effect="dark" content="查询采购计划单" placement="top">-->
<!--<el-button type="success" size="small" icon="el-icon-search" style="margin-left: 10px" @click="pageCurrent2=1;pageSize2=10;total2=0;searchTable2()">查询</el-button>-->
<!--</el-tooltip>-->
<el-button type="primary" size="small" icon="el-icon-plus" style="margin-left: 10px" @click="addPurchaseOrder">新增</el-button>
<el-tooltip :open-delay="1200" effect="dark" content="向选择的采购计划里添加采购零件" placement="top">
<el-button type="success" size="small" icon="el-icon-download" style="margin-left: 10px" @click="addMateriel">选入</el-button>
@@ -137,7 +137,7 @@
:page-sizes="[10, 20, 30, 40]"
:page-size="pageSize2"
:total="total2"
style="display:inline-block;width:50%"
style="display:inline-block;width:40%;float: right"
layout="total, sizes, prev, pager, next, jumper"
@size-change="handleSizeChange2"
@current-change="handleCurrentChange2"/>

View File

@@ -3,7 +3,7 @@
<el-card>
<div>
<span style="margin-left: 10px">供应商:</span>
<el-select v-model="supplierNameValue" placeholder="供应商" size="small" filterable clearable>
<el-select v-model="supplierNameValue" placeholder="供应商" size="small" filterable clearable @change="pageCurrent4=1;pageSize4=10;total4=0;searchTable4()">
<el-option
v-for="item in supplierName"
:key="item.value"
@@ -11,22 +11,22 @@
:value="item.value"/>
</el-select>
<!--<el-input v-model="Name" placeholder="供应商" size="small" clearable/>-->
<span>关联情况:</span>
<el-select v-model="PickingValue" placeholder="关联情况" size="small" clearable>
<el-option
v-for="item in Picking"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<el-tooltip :open-delay="1200" effect="dark" content="查询到货单" placement="top">
<el-button type="success" size="small" icon="el-icon-search" style="margin-left: 10px" @click="pageCurrent4=1;pageSize4=10;total4=0;searchTable4()">查询</el-button>
</el-tooltip>
<!--<span>关联情况:</span>-->
<!--<el-select v-model="PickingValue" placeholder="关联情况" size="small" clearable>-->
<!--<el-option-->
<!--v-for="item in Picking"-->
<!--:key="item.value"-->
<!--:label="item.label"-->
<!--:value="item.value"/>-->
<!--</el-select>-->
<!--<el-tooltip :open-delay="1200" effect="dark" content="查询到货单" placement="top">-->
<!--<el-button type="success" size="small" icon="el-icon-search" style="margin-left: 10px" @click="pageCurrent4=1;pageSize4=10;total4=0;searchTable4()">查询</el-button>-->
<!--</el-tooltip>-->
<el-button type="primary" size="small" icon="el-icon-plus" style="margin-left: 10px" @click="addArrivalOrder">新增到货单</el-button>
</div>
</el-card>
<el-card style="width: 45%;float: left">
<h3>到货单</h3>
<span>到货单</span>
<el-table v-loading="" :data="tableData4" border stripe style="width: 100%" height="230px" size="mini" highlight-current-row @row-click="searchTable5">
<el-table-column label="关联情况" align="center" width="80">
<template slot-scope="scope">
@@ -49,9 +49,9 @@
{{ scope.row.到货单编号 }}
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="220" fixed="right">
<el-table-column label="操作" align="center" width="200" fixed="right">
<template slot-scope="scope">
<el-button :disabled="Number(scope.row.是否关联) === 1" type="success" size="mini" icon="el-icon-circle-plus-outline" plain @click="addArrivalOrderMX(scope.row)">添加到货明细</el-button>
<el-button :disabled="Number(scope.row.是否关联) === 1" type="text" size="mini" style="margin-left: 10px" icon="el-icon-circle-plus-outline" @click="addArrivalOrderMX(scope.row)">到货明细</el-button>
<el-button :disabled="Number(scope.row.是否关联) === 1" type="text" size="mini" style="margin-left: 20px" icon="el-icon-delete" @click="deleteArrivalOrder(scope.row)">删除</el-button>
</template>
</el-table-column>
@@ -82,7 +82,7 @@
</div>
</el-card>
<el-card style="width: 54%;float: left;margin-left: 10px">
<h3>到货单明细</h3>
<span>到货单明细</span>
<el-table
v-loading=""
:data="tableData5"
@@ -111,21 +111,21 @@
{{ scope.row.单位 }}
</template>
</el-table-column>
<el-table-column label="单价" align="center">
<el-table-column label="单价" align="right">
<template slot-scope="scope">
{{ scope.row.单价 }}
{{ scope.row.单价.toFixed(2) }}
</template>
</el-table-column>
<el-table-column label="金额" align="center">
<el-table-column label="金额" align="right">
<template slot-scope="scope">
{{ parseInt(scope.row.金额 * 100) / 100 }}
{{ (parseInt(scope.row.金额 * 100) / 100).toFixed(2) }}
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="220" fixed="right">
<template slot-scope="scope">
<el-tooltip :open-delay="1200" effect="dark" content="关联备料材料" placement="top">
<div style="display: inline-block">
<el-button :disabled="disable === '1'" type="warning" size="mini" icon="el-icon-circle-plus-outline" plain @click="addArrivalCL(scope.row)">关联备料材料</el-button>
<el-button :disabled="disable === '1'" type="text" size="mini" icon="el-icon-circle-plus-outline" @click="addArrivalCL(scope.row)">备料材料</el-button>
</div>
</el-tooltip>
<el-tooltip :open-delay="1200" effect="dark" content="删除" placement="top">
@@ -138,7 +138,7 @@
</el-table>
</el-card>
<el-card style="width: 100%">
<h3>关联备料材料</h3>
<span>关联备料材料</span>
<el-table
v-loading=""
:data="tableData6"
@@ -187,7 +187,7 @@
</el-table-column>
<el-table-column label="总金额" align="center" prop="总金额">
<template slot-scope="scope">
{{ parseInt(scope.row.金额 * 100) / 100 }}
{{ (parseInt(scope.row.金额 * 100) / 100).toFixed(2) }}
</template>
</el-table-column>
<el-table-column label="备注" align="center" >
@@ -199,7 +199,7 @@
<template slot-scope="scope">
<el-tooltip effect="dark" content="取消关联" placement="top">
<div style="display: inline-block">
<el-button :disabled="disable === '1'" type="primary" size="mini" plain @click="deleteMateriel(scope.row)">取消关联</el-button>
<el-button :disabled="disable === '1'" type="text" size="mini" @click="deleteMateriel(scope.row)">取消关联</el-button>
</div>
</el-tooltip>
</template>
@@ -225,11 +225,6 @@
<el-date-picker v-model="form.日期" size="small" type="date" value-format="yyyy-MM-dd" format="yyyy-MM-dd" placeholder="选择日期"/>
</el-form-item>
</el-row>
<el-row>
<el-form-item label="备注" prop="备注">
<el-input v-model="form.备注" size="small"/>
</el-form-item>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button
@@ -740,9 +735,9 @@ export default {
sums[index] = values.reduce((prev, curr) => {
const value = Number(curr)
if (!isNaN(value)) {
return parseInt((Number(prev) + Number(curr)) * 100) / 100
return (parseInt((Number(prev) + Number(curr)) * 100) / 100).toFixed(2)
} else {
return Number(prev)
return (parseInt(Number(prev) * 100) / 100).toFixed(2)
}
}, 0)
sums[index] += ' 元'
@@ -789,9 +784,9 @@ export default {
sums[index] = values.reduce((prev, curr) => {
const value = Number(curr)
if (!isNaN(value)) {
return parseInt((Number(prev) + Number(curr)) * 100) / 100
return (parseInt((Number(prev) + Number(curr)) * 100) / 100).toFixed(2)
} else {
return parseInt(Number(prev) * 100) / 100
return (parseInt(Number(prev) * 100) / 100).toFixed(2)
}
}, 0)
sums[index] += ' 元'