beyond 6.17 2

This commit is contained in:
beyond 2019-06-17 17:05:39 +08:00
parent c166bd03b4
commit 1481f9e329
4 changed files with 443 additions and 352 deletions

View file

@ -217,3 +217,63 @@ export function inventoryMange5(query) {
data: params
})
}
export function stockMange(query) {
var params = new URLSearchParams()
if (query.beginTime !== '' && query.beginTime !== null && query.beginTime !== undefined) {
params.append('beginTime', query.beginTime) // 你要传给后台的参数值 key/value
}
if (query.endTime !== '' && query.endTime !== null && query.endTime !== undefined) {
params.append('endTime', query.endTime) // 你要传给后台的参数值 key/value
}
if (query.searchRepositoryId !== '' && query.searchRepositoryId !== null && query.searchRepositoryId !== undefined) {
params.append('searchRepositoryId', query.searchRepositoryId) // 你要传给后台的参数值 key/value
}
if (query.repositoryId !== '' && query.repositoryId !== null && query.repositoryId !== undefined) {
params.append('repositoryId', query.repositoryId) // 你要传给后台的参数值 key/value
}
if (query.regionIds !== '' && query.regionIds !== null && query.regionIds !== undefined) {
params.append('regionIds', query.regionIds) // 你要传给后台的参数值 key/value
}
if (query.pageNum !== '' && query.pageNum !== null && query.pageNum !== undefined) {
params.append('pageNum', query.pageNum) // 你要传给后台的参数值 key/value
}
if (query.pageSize !== '' && query.pageSize !== null && query.pageSize !== undefined) {
params.append('pageSize', query.pageSize) // 你要传给后台的参数值 key/value
}
return request({
url: '/erp/stockManager/supplierDistribut',
method: 'post',
data: params
})
}
export function stockMange2(query) {
var params = new URLSearchParams()
if (query.beginTime !== '' && query.beginTime !== null && query.beginTime !== undefined) {
params.append('beginTime', query.beginTime) // 你要传给后台的参数值 key/value
}
if (query.endTime !== '' && query.endTime !== null && query.endTime !== undefined) {
params.append('endTime', query.endTime) // 你要传给后台的参数值 key/value
}
if (query.searchRepositoryId !== '' && query.searchRepositoryId !== null && query.searchRepositoryId !== undefined) {
params.append('searchRepositoryId', query.searchRepositoryId) // 你要传给后台的参数值 key/value
}
if (query.repositoryId !== '' && query.repositoryId !== null && query.repositoryId !== undefined) {
params.append('repositoryId', query.repositoryId) // 你要传给后台的参数值 key/value
}
if (query.regionIds !== '' && query.regionIds !== null && query.regionIds !== undefined) {
params.append('regionIds', query.regionIds) // 你要传给后台的参数值 key/value
}
if (query.pageNum !== '' && query.pageNum !== null && query.pageNum !== undefined) {
params.append('pageNum', query.pageNum) // 你要传给后台的参数值 key/value
}
if (query.pageSize !== '' && query.pageSize !== null && query.pageSize !== undefined) {
params.append('pageSize', query.pageSize) // 你要传给后台的参数值 key/value
}
return request({
url: '/erp/stockManager/productTrack',
method: 'post',
data: params
})
}

View file

@ -1838,18 +1838,18 @@ export default {
productName: '产品名称',
productCode: '产品编码',
accountType: '核算方法',
isInput: '创建时间',
finishQuantity: '创建时间',
producingQuantity: '创建时间',
producingMaterialsQuantity: '创建时间',
producingSalary: '创建时间',
producingCost: '创建时间',
finishMaterialsUsedQuantity: '创建时间',
finishWorkHours: '创建时间',
endMaterialsQuantity: '创建时间',
endWorkHours: '创建时间',
currency: '创建时间',
createPersonId: '创建时间'
completeRate: '完工比例',
isInput: '是否一次性投入',
finishQuantity: '完工数量',
producingQuantity: '在产品数量',
producingMaterialsQuantity: '在产品直接材料定额',
producingSalary: '在产品工资定额',
producingCost: '在产品制造费用定额',
finishMaterialsUsedQuantity: '完工产品直接材料消耗定额',
finishWorkHours: '完工产品工时消耗定额',
endMaterialsQuantity: '月末在产品直接材料消耗定额',
endWorkHours: '月末在产品工时消耗定额',
currency: '币种'
},
SmartReplenishmentList: {
productCode: '商品编号',

View file

@ -4,240 +4,165 @@
<!--基本信息-->
<el-card class="box-card" shadow="never">
<h2 ref="geren" class="form-name">基本信息</h2>
<div class="container" style="margin-top: 37px">
<el-form ref="personalForm" :model="personalForm" :rules="personalrules" :inline="true" status-icon class="demo-ruleForm" label-width="130px">
<div class="container" style="margin-top: 37px;">
<el-form ref="personalForm" :model="personalForm" :rules="personalrules" :inline="true" status-icon class="demo-ruleForm" label-width="205px">
<el-row>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.title')" style="width: 100%;">
<el-input v-model="personalForm.title" style="margin-left: 18px;width: 200px" clearable/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.sourceType')" prop="sourceType" style="width: 100%;">
<el-select v-model="personalForm.sourceType" style="margin-left: 18px;width: 200px" @change="chooseType">
<el-option value="1" label="质检申请单" />
<el-option value="2" label="采购到货单" />
<el-option value="3" label="生产任务单" />
<el-option value="4" label="无来源" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.sourceNumber')" prop="sourceNumber" style="width: 100%;">
<el-input v-model="personalForm.sourceNumber" style="margin-left: 18px;width: 200px" clearable @focus="chooseNumber"/>
<my-quality :qualitycontrol.sync="qualitycontrol" @allqualityinfo="allqualityinfo"/>
<my-arrival :arrivalcontrol.sync="arrivalcontrol" @allarrivalinfo="allarrivalinfo"/>
<produce-task :procontrol.sync="producecontrol" @produce="produce"/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.supplierId')" style="width: 100%;">
<el-input v-model="supplierId" :disabled="IsSupplierId" style="margin-left: 18px;width: 200px" @focus="handlechoose"/>
<my-supplier :control.sync="empcontrol" @supplierName="supplierName"/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.inspectionPersonId')" prop="inspectionPersonId" style="width: 100%;">
<el-input v-model="inspectionPersonId" :disabled="IsInspectionPersonId" style="margin-left: 18px;width: 200px" clearable @focus="handlechooseStock"/>
<my-emp :control.sync="stockControl" @stockName="stockName"/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.inspectionDeptId')" prop="reportDeptId" style="width: 100%;">
<el-select v-model="personalForm.inspectionDeptId" :disabled="IsInspectionDeptId" style="margin-left: 18px;width: 200px" @change="change()">
<el-option
v-for="(item, index) in depts"
:key="index"
:value="item.id"
:label="item.deptName"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.checkType')" prop="checkType" style="width: 100%;">
<el-select v-model="personalForm.checkType" value="personalForm.checkType" style="margin-left: 18px;width: 200px" @change="change()">
<el-option value="1" label="来料质检"/>
<el-option value="2" label="送样质检"/>
<el-option value="3" label="生产质检"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.checkMode')" prop="checkMode" style="width: 100%;">
<el-select v-model="personalForm.checkMode" value="personalForm.checkMode" style="margin-left: 18px;width: 200px" @change="checkModeChoose">
<el-option value="1" label="抽样"/>
<el-option value="2" label="全检"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.produceManagerId')" style="width: 100%;">
<el-input v-model="produceManagerId" :disabled="IsProduceManagerId" style="margin-left: 18px;width: 200px" @focus="handlechooseDelivery"/>
</el-form-item>
<my-delivery :deliverycontrol.sync="deliverycontrol" @deliveryName="deliveryName"/>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.workCenterId')" style="width: 100%;">
<el-input v-model="workCenterId" :disabled="IsWorkCenterId" style="margin-left: 18px;width: 200px" @focus="workcenterchoose"/>
<my-center :control.sync="centercontrol" @center="center"/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.checkPersonId')" style="width: 100%;">
<el-input v-model="checkPersonId" style="margin-left: 18px;width: 200px" clearable @focus="handlechooseAccept"/>
<my-accept :accetpcontrol.sync="accetpcontrol" @acceptName="acceptName"/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.checkDeptId')" prop="reportDeptId" style="width: 100%;">
<el-select v-model="personalForm.checkDeptId" clearable style="margin-left: 18px;width: 200px">
<el-option
v-for="(item, index) in depts"
:key="index"
:value="item.id"
:label="item.deptName"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.checkDate')" prop="checkDate" style="width: 100%;">
<el-form-item :label="$t('ProductCost.accountTime')" style="width: 100%;">
<el-date-picker
v-model="personalForm.checkDate"
type="date"
value-format="yyyy-MM-dd"
v-model="personalForm.accountTime"
type="month"
placeholder="选择月"
style="margin-left: 18px;width: 200px"/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('ProductCost.productName')" prop="sourceType" style="width: 100%;">
<el-input v-model="personalForm.productName" style="margin-left: 18px;width:200px" @focus="handlemater"/>
<my-mater :matercontrol.sync="matercontrol" @mater="mater"/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('ProductCost.accountType')" prop="sourceNumber" style="width: 100%;">
<el-select v-model="personalForm.accountType" value="personalForm.accountType" style="margin-left: 18px;width: 200px" @change="change()">
<el-option value="1" label="约当产量法"/>
<el-option value="2" label="定额成本发"/>
<el-option value="3" label="定额比例发"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('ProductCost.completeRate')+'%'" style="width: 100%;">
<el-input v-model="personalForm.completeRate" style="margin-left: 18px;width: 200px" clearable/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('ProductCost.isInput')" prop="inspectionPersonId" style="width: 100%;">
<el-radio-group v-model="personalForm.isInput" style="margin-left: 18px;width: 200px" >
<el-radio :label="1" style="width: 100px"></el-radio>
<el-radio :label="2"></el-radio>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('ProductCost.finishQuantity')" prop="reportDeptId" style="width: 100%;">
<el-input v-model="personalForm.finishQuantity" style="margin-left: 18px;width: 200px" clearable/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('ProductCost.producingQuantity')" prop="checkType" style="width: 100%;">
<el-input v-model="personalForm.producingQuantity" style="margin-left: 18px;width: 200px" clearable/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('ProductCost.producingMaterialsQuantity')" prop="checkMode" style="width: 100%;">
<el-input v-model="personalForm.producingMaterialsQuantity" style="margin-left: 18px;width: 200px" clearable/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('ProductCost.producingSalary')" style="width: 100%;">
<el-input v-model="personalForm.producingSalary" style="margin-left: 18px;width: 200px" clearable/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('ProductCost.producingCost')" style="width: 100%;">
<el-input v-model="personalForm.producingCost" style="margin-left: 18px;width: 200px" clearable/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('ProductCost.finishMaterialsUsedQuantity')" style="width: 100%;">
<el-input v-model="personalForm.finishMaterialsUsedQuantity" style="margin-left: 18px;width: 200px" clearable/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('ProductCost.finishWorkHours')" prop="reportDeptId" style="width: 100%;">
<el-input v-model="personalForm.finishWorkHours" style="margin-left: 18px;width: 200px" clearable/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('ProductCost.endMaterialsQuantity')" prop="checkDate" style="width: 100%;">
<el-input v-model="personalForm.endMaterialsQuantity" style="margin-left: 18px;width: 200px" clearable/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('ProductCost.endWorkHours')" prop="reportDeptId" style="width: 100%;">
<el-input v-model="personalForm.endWorkHours" style="margin-left: 18px;width: 200px" clearable/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('ProductCost.currency')" prop="reportDeptId" style="width: 100%;">
<el-select v-model="personalForm.checkMode" value="personalForm.checkMode" style="margin-left: 18px;width: 200px" >
<el-option value="1" label="RMB"/>
<el-option value="2" label="USD"/>
</el-select>
</el-form-item>
</el-col>
</el-row>
</el-form>
</div>
</el-card>
<el-card class="box-card" shadow="never" style="margin-top: 10px">
<h2 ref="geren" class="form-name">物品信息</h2>
<div class="container" style="margin-top: 37px">
<el-form ref="personalForm2" :model="personalForm" :rules="personalrules" :inline="true" status-icon class="demo-ruleForm" label-width="130px">
<el-row>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.productCode')" prop="productCode" style="width: 100%;">
<el-input v-model="personalForm.productCode" style="margin-left: 18px;width:200px" @focus="handlemater"/>
<my-mater :matercontrol.sync="matercontrol" @mater="mater"/>
<detail-report :reportcontrol.sync="reportcontrol" :reportdata.sync="reportdata" @report="report"/>
<detail-report2 :reportcontrol2.sync="reportcontrol2" :reportdata2.sync="reportdata2" @report2="report2"/>
<detail-report3 :reportcontrol3.sync="reportcontrol3" :reportdata3.sync="reportdata3" @report3="report3"/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.productName')" style="width: 100%;">
<el-input v-model="personalForm.productName" style="margin-left: 18px;width:200px" disabled/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.unit')" style="width: 100%;">
<el-input v-model="personalForm.unit" style="margin-left: 18px;width:200px" disabled/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.typeId')" style="width: 100%;">
<el-input v-model="typeId" style="margin-left: 18px;width:200px" disabled/>
</el-form-item>
</el-col>
</el-row>
</el-form>
</div>
</el-card>
<el-card class="box-card" shadow="never" style="margin-top: 10px">
<h2 ref="geren" class="form-name">检验信息</h2>
<div class="container" style="margin-top: 37px">
<el-form ref="personalForm3" :model="personalForm" :rules="personalrules" :inline="true" status-icon class="demo-ruleForm" label-width="130px">
<el-row>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.checkQuantity')" prop="checkQuantity" style="width: 100%;" >
<el-input v-model="personalForm.checkQuantity" style="margin-left: 18px;width:200px" clearable @blur="changeCheckQuantity"/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.sampleQuantity')" prop="sampleQuantity" style="width: 100%;">
<el-input v-model="personalForm.sampleQuantity" :disabled="IsSampleQuantity" style="margin-left: 18px;width:200px" clearable @blur="changeSampleQuantity"/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.passQuantity')" prop="passQuantity" style="width: 100%;">
<el-input v-model="personalForm.passQuantity" style="margin-left: 18px;width:200px" @blur="changePassQuantity"/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.failedQuantity')" style="width: 100%;">
<el-input :disabled="true" v-model="personalForm.failedQuantity" style="margin-left: 18px;width:200px" clearable/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.passRate')" style="width: 100%;">
<el-input :disabled="true" v-model="personalForm.passRate" style="margin-left: 18px;width:200px" clearable/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.checkResult')" style="width: 100%;">
<el-input v-model="personalForm.checkResult" style="margin-left: 18px;width:200px" clearable/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="$t('CheckReport.isRecheck')" style="width: 100%;">
<el-radio-group v-model="personalForm.isRecheck" style="margin-left: 18px;width:200px">
<el-radio :label="1" style="width: 100px"></el-radio>
<el-radio :label="2"></el-radio>
</el-radio-group>
</el-form-item>
</el-col>
</el-row>
</el-form>
</div>
</el-card>
<!--子件信息-->
<el-card class="box-card" style="margin-top: 15px" shadow="never">
<h2 ref="fuzhu" class="form-name" >质检报告单明细</h2>
<div class="buttons" style="margin-top: 35px;margin-bottom: 10px;">
<el-button @click="handleAdd">添加</el-button>
<el-button type="danger" @click="$refs.editable.removeSelecteds()">删除</el-button>
</div>
<h2 ref="fuzhu" class="form-name" >成本费用明细</h2>
<div class="container">
<el-editable
ref="editable"
:data.sync="list2"
:edit-config="{ showIcon: true, showStatus: true}"
:edit-rules="validRules"
class="click-table1"
stripe
border
size="medium"
style="width: 100%">
<el-editable-column type="selection" min-width="55" align="center"/>
<el-editable-column label="序号" min-width="55" align="center" type="index"/>
<el-editable-column :edit-render="{name: 'ElInput', type: 'visible'}" prop="checkItem" align="center" label="检验项目" min-width="150px"/>
<el-editable-column :edit-render="{name: 'ElInput', type: 'visible'}" prop="checkTarget" align="center" label="检验指标" min-width="150px"/>
<el-editable-column :edit-render="{name: 'ElInputNumber', attrs: {min: 0}, type: 'visible'}" prop="checkValue" align="center" label="检验值" min-width="150px"/>
<el-editable-column :edit-render="{name: 'ElSelect',options: results ,type: 'visible'}" prop="chectResult" align="center" label="检验结果" min-width="150px"/>
<el-editable-column prop="checkQuantity" align="center" label="检验数量" min-width="150px">
<template slot-scope="scope">
<p>{{ getcheckQuantity(scope.row) }}</p>
</template>
</el-editable-column>
<el-editable-column :edit-render="{name: 'ElInputNumber', attrs: {min: 0}, type: 'visible'}" prop="passQuantity" align="center" label="合格数量" min-width="150px"/>
<el-editable-column prop="failedQuantity" align="center" label="不合格数量" min-width="150px">
<template slot-scope="scope">
<p>{{ getfailedQuantity(scope.row) }}</p>
</template>
</el-editable-column>
<el-editable-column :edit-render="{name: 'ElInput', type: 'visible'}" prop="checkPersonname" align="center" label="检验人员" min-width="150px">
<template slot="edit" slot-scope="scope">
<el-input v-model="scope.row.checkPersonname" @focus="handlechoosestaff"/>
<my-emp2 :staffcontrol.sync="staffcontrol" @chuli="chuli(scope, $event)"/>
</template>
</el-editable-column>
<el-editable-column :edit-render="{name: 'ElSelect', options: depts2, type: 'visible'}" prop="checkDeptId" align="center" label="检验部门" min-width="150px"/>
<el-editable-column :edit-render="{name: 'ElInputNumber', attrs: {min: 0}, type: 'visible'}" prop="targetUp" align="center" label="指标上限" min-width="150px"/>
<el-editable-column :edit-render="{name: 'ElInputNumber', attrs: {min: 0}, type: 'visible'}" prop="targetDown" align="center" label="指标下限" min-width="150px"/>
</el-editable>
<el-row :gutter="20" style="margin-top: 100px">
<el-col :span="24">
<div style="width: 100%; min-height: 300px;" >
<el-row :gutter="20" style="margin-top: 26px">
<el-col :span="24">
<div style="width: 100%; min-height: 400px;" >
<el-table
:data="list2"
:border="true"
style="width: 100%">
<el-table-column
prop="productCost"
label="产品成本"
min-width="140"
align="center"/>
<el-table-column
prop="material"
label="直接材料费用"
min-width="140"
align="center">
<template slot-scope="scope">
<span v-show="scope.$index >= 2" @click="getscope(scope)">{{ scope.row.material }}</span>
<el-input v-show="scope.$index < 2" v-model="scope.row.material" style="width: 130px;" @blur="getdata(scope)"/>
</template>
</el-table-column>
<el-table-column
prop="man"
label="直接人工费用"
min-width="140"
align="center">
<template slot-scope="scope">
<span v-show="scope.$index >= 2" @click="getscope(scope)">{{ scope.row.material }}</span>
<el-input v-show="scope.$index < 2" v-model="scope.row.man" style="width: 130px;"/>
</template>
</el-table-column>
<el-table-column
prop="produce"
label="制造费用"
min-width="140"
align="center">
<template slot-scope="scope">
<span v-show="scope.$index >= 2" @click="getscope(scope)">{{ scope.row.material }}</span>
<el-input v-show="scope.$index < 2" v-model="scope.row.produce" style="width: 130px;"/>
</template>
</el-table-column>
<el-table-column
prop="total"
label="费用合计"
min-width="140"
align="center"/>
</el-table>
</div>
</el-col>
</el-row>
</div>
</el-col>
</el-row>
</div>
</el-card>
<!--操作-->
@ -433,8 +358,55 @@ export default {
{ required: true, message: '请输入合格数量', trigger: 'blur' }
]
},
//
list: [],
//
listLoading: true,
//
list2: [],
list2: [
{
productCost: '月初在产品成本',
material: '',
man: '',
produce: '',
total: 0.00
},
{
productCost: '本月发生生产费用',
material: '',
man: '',
produce: '',
total: 0.00
},
{
productCost: '合计',
material: 0.00,
man: 0.00,
produce: 0.00,
total: 0.00
},
{
productCost: '完工产品总成本',
material: 0.00,
man: 0.00,
produce: 0.00,
total: 0.00
},
{
productCost: '单位成本',
material: 0.00,
man: 0.00,
produce: 0.00,
total: 0.00
},
{
productCost: '月末在产品成本',
material: 0.00,
man: 0.00,
produce: 0.00,
total: 0.00
}
],
//
validRules: {
chectResult: [
@ -459,6 +431,12 @@ export default {
this.getTypes()
},
methods: {
getdata(val) {
console.log('123', val)
},
getscope(val) {
console.log(val)
},
getcheckQuantity(row) {
row.sampleQuantity = this.personalForm.sampleQuantity
return row.sampleQuantity
@ -518,15 +496,7 @@ export default {
},
// focus
handlemater() {
if (this.personalForm.sourceType === '1') {
this.reportcontrol = true
} else if (this.personalForm.sourceType === '2') {
this.reportcontrol2 = true
} else if (this.personalForm.sourceType === '3') {
this.reportcontrol3 = true
} else if (this.personalForm.sourceType === '4') {
this.matercontrol = true
}
this.matercontrol = true
},
//
report(val) {
@ -943,4 +913,8 @@ export default {
width: 98px;
}
}
.shipei {
width: 150px !important;
}
</style>

View file

@ -35,26 +35,26 @@
:header-cell-style="tableHeaderColor3"
style="width: 100%">
<el-table-column
prop="repositoryName"
prop="stockPersonName"
label="采购员"
width="320"
align="center">
</el-table-column>
<el-table-column align="center" label="分类">
<el-table-column
prop="first"
prop="oneNum"
label="原材料供应商"
width="220"
align="center">
</el-table-column>
<el-table-column
prop="manyTimes"
prop="twoNum"
label="配件供应商"
width="220"
align="center">
</el-table-column>
<el-table-column
prop="important"
prop="threeNum"
label="紧固件供应商"
width="220"
align="center">
@ -62,25 +62,26 @@
</el-table-column>
<el-table-column align="center" label="级别">
<el-table-column
prop="first"
prop="fourNum"
label="一级"
width="220"
align="center">
</el-table-column>
<el-table-column
prop="manyTimes"
prop="fiveNum"
label="二级"
width="220"
align="center">
</el-table-column>
<el-table-column
prop="important"
prop="sixNum"
label="三级"
width="220"
align="center">
</el-table-column>
</el-table-column>
</el-table>
<pagination v-show="total>0" :total="total" :page.sync="getemplist4.pageNum" :limit.sync="getemplist4.pageSize" style="margin-top: 0px;" @pagination="getlist" />
</div>
</el-col>
</el-row>
@ -96,103 +97,164 @@
<el-col :span="24">
<div style="width: 100%; min-height: 400px;" >
<div style="width: 100%; height: 50px;background: #d9e0e8;" >
<div style="padding-top: 16px;padding-left: 20px;">产品信息追踪</div>
<div style="padding-top: 16px;padding-left: 20px;width: 25%;height: 100%;float: left">产品信息追踪</div>
<div style="width: 75%;height: 100%;float: left;">
<el-form ref="getemplist2" :model="getemplist2" label-width="100px">
<el-date-picker
v-model="date"
type="daterange"
range-separator="-"
unlink-panels
start-placeholder="开始日期"
end-placeholder="结束日期"
value-format="yyyy-MM-dd"
style="margin-left: 60%;"
class="shipei"/>
<!-- 搜索按钮 -->
<el-button v-waves class="filter-item" type="primary" icon="el-icon-search" style="width: 86px;margin-top: 10px;" round @click="handleFilter">{{ $t('public.search') }}</el-button>
</el-form>
</div>
</div>
<el-table
:data="list2"
:header-cell-style="tableHeaderColor"
style="width: 100%">
<el-table-column
prop="repositoryName"
prop="productName"
label="产品名称"
min-width="105"
min-width="160"
align="center">
</el-table-column>
<el-table-column
prop="repositoryName"
prop="productCode"
label="产品编号"
min-width="105"
min-width="160"
align="center">
</el-table-column>
<el-table-column
prop="repositoryName"
prop="productType"
label="产品型号"
min-width="105"
min-width="160"
align="center">
</el-table-column>
<el-table-column
prop="repositoryName"
prop="unit"
label="单位"
min-width="105"
align="center">
</el-table-column>
<el-table-column
prop="repositoryName"
prop="existStock"
label="当前库存"
min-width="105"
align="center">
</el-table-column>
<el-table-column
prop="repositoryName"
prop="orderStock"
label="预定库存"
min-width="105"
align="center">
</el-table-column>
<el-table-column
prop="repositoryName"
prop="onStock"
label="在途库存"
min-width="105"
align="center">
</el-table-column>
<el-table-column
prop="repositoryName"
prop="enterQuantity"
label="待审批入库"
min-width="105"
align="center">
</el-table-column>
<el-table-column
prop="repositoryName"
prop="minPrice"
label="历史最低价"
min-width="105"
align="center">
</el-table-column>
<el-table-column
prop="repositoryName"
prop="planQuantity"
label="计划采购"
min-width="105"
align="center">
</el-table-column>
<el-table-column
prop="repositoryName"
prop="maxPrice"
label="历史最高价"
min-width="105"
align="center">
</el-table-column>
<el-table-column
prop="repositoryName"
prop="recentlyPrice"
label="最近购买价"
min-width="105"
align="center">
</el-table-column>
<el-table-column
prop="repositoryName"
prop="avgPrice"
label="历史平均价"
min-width="105"
align="center">
</el-table-column>
<el-table-column
prop="repositoryName"
prop="advicePrice"
label="建议进价"
min-width="105"
align="center">
</el-table-column>
<el-table-column
prop="repositoryName"
prop="supplierVos"
label="可选供应商"
min-width="105"
width="200"
align="center">
<!-- type="expand"-->
<!-- <el-select v-model="personalForm.accountType" value="personalForm.accountType" style="margin-left: 18px;width: 200px" @change="change()">-->
<!-- <el-option value="1" label="约当产量法"/>-->
<!-- <el-option value="2" label="定额成本发"/>-->
<!-- <el-option value="3" label="定额比例发"/>-->
<!-- </el-select>-->
</el-table-column>
</el-table>
<pagination v-show="total2>0" :total="total2" :page.sync="getemplist2.pageNum" :limit.sync="getemplist2.pageSize" style="margin-top: 0px;" @pagination="getlist" />
<!--质检报告-->
<!-- <el-editable-->
<!-- ref="editable"-->
<!-- :data.sync="list2"-->
<!-- :edit-config="{ showIcon: true, showStatus: true}"-->
<!-- :edit-rules="validRules"-->
<!-- class="click-table1"-->
<!-- stripe-->
<!-- border-->
<!-- size="medium"-->
<!-- style="width: 100%">-->
<!-- <el-editable-column type="selection" min-width="55" align="center"/>-->
<!-- <el-editable-column label="序号" min-width="55" align="center" type="index"/>-->
<!-- <el-editable-column :edit-render="{name: 'ElInput', type: 'visible'}" prop="checkItem" align="center" label="检验项目" min-width="150px"/>-->
<!-- <el-editable-column :edit-render="{name: 'ElInput', type: 'visible'}" prop="checkTarget" align="center" label="检验指标" min-width="150px"/>-->
<!-- <el-editable-column :edit-render="{name: 'ElInputNumber', attrs: {min: 0}, type: 'visible'}" prop="checkValue" align="center" label="检验值" min-width="150px"/>-->
<!-- <el-editable-column :edit-render="{name: 'ElSelect',options: results ,type: 'visible'}" prop="chectResult" align="center" label="检验结果" min-width="150px"/>-->
<!-- <el-editable-column prop="checkQuantity" align="center" label="检验数量" min-width="150px">-->
<!-- <template slot-scope="scope">-->
<!-- <p>{{ getcheckQuantity(scope.row) }}</p>-->
<!-- </template>-->
<!-- </el-editable-column>-->
<!-- <el-editable-column :edit-render="{name: 'ElInputNumber', attrs: {min: 0}, type: 'visible'}" prop="passQuantity" align="center" label="合格数量" min-width="150px"/>-->
<!-- <el-editable-column prop="failedQuantity" align="center" label="不合格数量" min-width="150px">-->
<!-- <template slot-scope="scope">-->
<!-- <p>{{ getfailedQuantity(scope.row) }}</p>-->
<!-- </template>-->
<!-- </el-editable-column>-->
<!-- <el-editable-column :edit-render="{name: 'ElInput', type: 'visible'}" prop="checkPersonname" align="center" label="检验人员" min-width="150px">-->
<!-- <template slot="edit" slot-scope="scope">-->
<!-- <el-input v-model="scope.row.checkPersonname" @focus="handlechoosestaff"/>-->
<!-- <my-emp2 :staffcontrol.sync="staffcontrol" @chuli="chuli(scope, $event)"/>-->
<!-- </template>-->
<!-- </el-editable-column>-->
<!-- <el-editable-column :edit-render="{name: 'ElSelect', options: depts2, type: 'visible'}" prop="checkDeptId" align="center" label="检验部门" min-width="150px"/>-->
<!-- <el-editable-column :edit-render="{name: 'ElInputNumber', attrs: {min: 0}, type: 'visible'}" prop="targetUp" align="center" label="指标上限" min-width="150px"/>-->
<!-- <el-editable-column :edit-render="{name: 'ElInputNumber', attrs: {min: 0}, type: 'visible'}" prop="targetDown" align="center" label="指标下限" min-width="150px"/>-->
<!-- </el-editable>-->
</div>
</el-col>
</el-row>
@ -209,7 +271,7 @@
import { searchsaleOrder, deletesaleOrder, updatesaleOrder2 } from '@/api/SaleOrder'
import { searchalarm } from '@/api/StockAlarm'
import { applyList } from '@/api/StockApply'
import { SaleMange1, SaleMange2, SaleMange3 } from '@/api/home'
import { SaleMange1, SaleMange2, SaleMange3, stockMange, stockMange2 } from '@/api/home'
import waves from '@/directive/waves' // Waves directive
import Pagination from '@/components/Pagination'
import permission from '@/directive/permission/index.js' //
@ -258,6 +320,7 @@
},
data() {
return {
checkDeptId: {},
deskdata: {
},
//
@ -305,6 +368,7 @@
applyList: [],
//
total: 0,
total2: 0,
//
tableKey: 0,
//
@ -328,6 +392,8 @@
regionid: this.$store.getters.regionId,
},
getemplist4: {
pageNum: 1,
pageSize: 10
},
//
personalForm: {},
@ -480,66 +546,48 @@
},
getlist() {
this.listLoading = true
SaleMange1(this.getemplist3).then(res => {
if (res.data.ret === 200) {
console.log(res.data)
console.log(res.data.data.repositoryName)
this.list3 = res.data.data.content.map(function (item) {
return {
repositoryName: item.repositoryName,
finished: item.finished,
comment: item.comment,
canceled: item.canceled,
begin: item.begin,
submit: item.submit,
repair: item.repair,
assigned: item.assigned
}
})
}
setTimeout(() => {
this.listLoading = false
}, 0.5 * 100)
})
SaleMange2(this.getemplist3).then(res => {
if (res.data.ret === 200) {
console.log(res.data)
console.log(res.data.data.saleManagerVos)
this.list2 = res.data.data.saleManagerVos.map(function (item) {
if (item.customerToday === null) {
item.customerToday = 0
}
if (item.customerMonth === null) {
item.customerMonth = 0
}
return {
repositoryName: item.repositoryName,
agentLast: item.agentLast,
agentMonth: item.agentMonth,
agentToday: item.agentToday,
customerLast: item.customerLast,
customerMonth: item.customerMonth,
customerToday: item.customerToday
}
})
}
setTimeout(() => {
this.listLoading = false
}, 0.5 * 100)
})
SaleMange3(this.getemplist4).then(res => {
stockMange2(this.getemplist2).then(res => {
if (res.data.ret === 200) {
this.total2 = res.data.data.content.totalCount
console.log('list',res.data)
this.list = res.data.data.content.map(function (item) {
this.list2 = res.data.data.content.list.map(function (item) {
return {
repositoryName: item.repositoryName,
first: item.first,
manyTimes: item.manyTimes,
important: item.important,
online: item.online,
total: item.first + item.manyTimes + item.important
productName: item.productName,
productCode: item.productCode,
productType: item.productType,
unit: item.unit,
existStock: item.existStock,
orderStock: item.orderStock,
onStock: item.onStock,
enterQuantity: item.enterQuantity,
planQuantity: item.planQuantity,
minPrice: item.minPrice,
maxPrice: item.maxPrice,
recentlyPrice: item.recentlyPrice,
avgPrice: item.avgPrice,
advicePrice: item.advicePrice
// supplierVos: item.supplierVos
}
})
}
setTimeout(() => {
this.listLoading = false
}, 0.5 * 100)
})
stockMange(this.getemplist4).then(res => {
if (res.data.ret === 200) {
this.total = res.data.data.content.totalCount
console.log('list',res.data)
this.list = res.data.data.content.list.map(function (item) {
return {
stockPersonName: item.stockPersonName,
oneNum: item.oneNum,
twoNum: item.twoNum,
threeNum: item.threeNum,
fourNum: item.fourNum,
fiveNum: item.fiveNum,
sixNum: item.sixNum
}
})
}
@ -558,26 +606,33 @@
//
handleFilter() {
if (this.date === null || this.date === undefined || this.date === '') {
this.getemplist3.beginTime = ''
this.getemplist3.endTime = ''
this.getemplist2.beginTime = ''
this.getemplist2.endTime = ''
} else {
this.getemplist3.beginTime = this.date[0]
this.getemplist3.endTime = this.date[1]
this.getemplist2.beginTime = this.date[0]
this.getemplist2.endTime = this.date[1]
}
SaleMange1(this.getemplist3).then(res => {
stockMange2(this.getemplist2).then(res => {
if (res.data.ret === 200) {
console.log(res.data)
console.log(res.data.data.repositoryName)
this.list3 = res.data.data.content.map(function (item) {
this.total2 = res.data.data.content.totalCount
console.log('list',res.data)
this.list2 = res.data.data.content.list.map(function (item) {
return {
repositoryName: item.repositoryName,
finished: item.finished,
comment: item.comment,
canceled: item.canceled,
begin: item.begin,
submit: item.submit,
repair: item.repair,
assigned: item.assigned
productName: item.productName,
productCode: item.productCode,
productType: item.productType,
unit: item.unit,
existStock: item.existStock,
orderStock: item.orderStock,
onStock: item.onStock,
enterQuantity: item.enterQuantity,
planQuantity: item.planQuantity,
minPrice: item.minPrice,
maxPrice: item.maxPrice,
recentlyPrice: item.recentlyPrice,
avgPrice: item.avgPrice,
advicePrice: item.advicePrice
// supplierVos: item.supplierVos
}
})
}
@ -595,17 +650,19 @@
this.getemplist4.beginTime = this.date2[0]
this.getemplist4.endTime = this.date2[1]
}
SaleMange3(this.getemplist4).then(res => {
stockMange(this.getemplist4).then(res => {
if (res.data.ret === 200) {
console.log('list',res.data)
this.list = res.data.data.content.map(function (item) {
this.total = res.data.data.content.totalCount
console.log('list2',res.data.data.content.list)
this.list = res.data.data.content.list.map(function (item) {
return {
repositoryName: item.repositoryName,
first: item.first,
manyTimes: item.manyTimes,
important: item.important,
online: item.online,
total: item.first + item.manyTimes + item.important
stockPersonName: item.stockPersonName,
oneNum: item.oneNum,
twoNum: item.twoNum,
threeNum: item.threeNum,
fourNum: item.fourNum,
fiveNum: item.fiveNum,
sixNum: item.sixNum
}
})
}