|
@@ -0,0 +1,1315 @@
|
|
|
+<!--出入库任务编辑-->
|
|
|
+<template>
|
|
|
+ <div class="container">
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="20">
|
|
|
+ <h2 class="bg-left title">编辑出入库任务</h2>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="4" class="bg-right">
|
|
|
+ <el-button
|
|
|
+ class="bg-bottom"
|
|
|
+ type="primary"
|
|
|
+ size="small"
|
|
|
+ @click="revert()"
|
|
|
+ ><img
|
|
|
+ width="6"
|
|
|
+ height="10"
|
|
|
+ style="vertical-align: bottom; margin-right: 3px"
|
|
|
+ src="../../../public/img/lujing.png"
|
|
|
+ alt=""
|
|
|
+ />返回</el-button
|
|
|
+ >
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+ <el-radio v-model="radio" label="1">出库</el-radio>
|
|
|
+ <el-radio v-model="radio" label="2">入库</el-radio>
|
|
|
+ <el-radio v-model="radio" label="3">移库</el-radio>
|
|
|
+ <el-radio v-model="radio" label="4">退库并出库</el-radio>
|
|
|
+ <el-form label-width="80px">
|
|
|
+ <h2>
|
|
|
+ 出库任务({{ }})
|
|
|
+ <span class="position" v-show="this.$route.query.warehouseType == 1">
|
|
|
+ </span>
|
|
|
+ </h2>
|
|
|
+ <ws-info-table>
|
|
|
+ <!-- 仓库名 -->
|
|
|
+ <el-form-item label="仓库名">
|
|
|
+ <el-select v-model="form.region" placeholder="请选择仓库">
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 出库类型 -->
|
|
|
+ <el-form-item label="出库类型">
|
|
|
+ <el-select v-model="form.region" placeholder="请选择出库类型">
|
|
|
+ <el-option label="销售出库" value=""></el-option>
|
|
|
+ <el-option label="移库出库" value=""></el-option>
|
|
|
+ <el-option label="暂存出库" value=""></el-option>
|
|
|
+ <el-option label="贸易服务出库" value=""></el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 合同编号 -->
|
|
|
+ <el-form-item label="合同编号">
|
|
|
+ <el-input v-model="form.name" placeholder="请输入合同编号"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 货名 -->
|
|
|
+ <el-form-item label="货名">
|
|
|
+ <el-input v-model="form.name" placeholder="请输入货名"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 重量(吨) -->
|
|
|
+ <el-form-item label="重量(吨)">
|
|
|
+ <el-input v-model="form.name" placeholder="请输入重量"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 品级 -->
|
|
|
+ <ws-form-item label="品级" span="1" class="readonly">
|
|
|
+ <ws-select
|
|
|
+ v-model="deptBudgetList.grade"
|
|
|
+ placeholder="请选择品级"
|
|
|
+ class="typeselect"
|
|
|
+ @change="selectpackingMethod"
|
|
|
+ >
|
|
|
+ <ws-option
|
|
|
+ v-for="item in gradeList"
|
|
|
+ :key="item.constKey"
|
|
|
+ :label="item.constValue"
|
|
|
+ :value="item.constValue"
|
|
|
+ />
|
|
|
+ </ws-select>
|
|
|
+ </ws-form-item>
|
|
|
+ <!-- 容重(%)<= -->
|
|
|
+ <el-form-item label="容重(%)<=">
|
|
|
+ <el-input v-model="form.name" placeholder="请输入容重"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 水分(%)<= -->
|
|
|
+ <el-form-item label="水分(%)<=">
|
|
|
+ <el-input v-model="form.name" placeholder="请输入水分"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 单价(元/吨) -->
|
|
|
+ <el-form-item label="单价(元/吨)">
|
|
|
+ <el-input v-model="form.name" placeholder="请输入单价"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 预计出库日期 -->
|
|
|
+ <el-form-item label="预计出库日期">
|
|
|
+ <el-col :span="11">
|
|
|
+ <el-date-picker type="date" placeholder="请选择日期" v-model="form.date1" style="width: 100%;"></el-date-picker>
|
|
|
+ </el-col>
|
|
|
+ <el-col class="line" :span="2">-</el-col>
|
|
|
+ </el-form-item>
|
|
|
+ <!--出库经办人-->
|
|
|
+ <el-form-item label="出库经办人">
|
|
|
+ <el-select v-model="form.region" placeholder="请选择经办人">
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 业务描述 -->
|
|
|
+ <el-form-item label="业务描述">
|
|
|
+ <el-input type="textarea" v-model="form.desc" placeholder="请输入业务描述"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+
|
|
|
+ <div style="text-align: right; padding: 10px">
|
|
|
+ <el-button
|
|
|
+ class="bg-bottom-up"
|
|
|
+ type="primary"
|
|
|
+ size="small"
|
|
|
+ @click="submit()"
|
|
|
+ >提交</el-button
|
|
|
+ >
|
|
|
+ </div>
|
|
|
+ </ws-info-table>
|
|
|
+ </el-form>
|
|
|
+
|
|
|
+
|
|
|
+ <el-form label-width="80px">
|
|
|
+ <h2>
|
|
|
+ 入库任务({{ }})
|
|
|
+ <span class="position" v-show="this.$route.query.warehouseType == 1">
|
|
|
+ </span>
|
|
|
+ </h2>
|
|
|
+ <ws-info-table>
|
|
|
+ <!-- 仓库名 -->
|
|
|
+ <el-form-item label="仓库名">
|
|
|
+ <el-select v-model="form.region" placeholder="请选择仓库">
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 入库类型 -->
|
|
|
+ <el-form-item label="入库类型">
|
|
|
+ <el-select v-model="form.region" placeholder="请选择入库类型">
|
|
|
+ <el-option label="采购入库" value=""></el-option>
|
|
|
+ <el-option label="移库入库" value=""></el-option>
|
|
|
+ <el-option label="暂存入库" value=""></el-option>
|
|
|
+ <el-option label="金融入库" value=""></el-option>
|
|
|
+ <el-option label="退库" value=""></el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 合同编号 -->
|
|
|
+ <el-form-item label="合同编号">
|
|
|
+ <el-input v-model="form.name" placeholder="请输入合同编号"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 货名 -->
|
|
|
+ <el-form-item label="货名">
|
|
|
+ <el-input v-model="form.name" placeholder="请输入货名"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 重量(吨) -->
|
|
|
+ <el-form-item label="重量(吨)">
|
|
|
+ <el-input v-model="form.name" placeholder="请输入重量"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 品级 -->
|
|
|
+ <ws-form-item label="品级" span="1" class="readonly">
|
|
|
+ <ws-select
|
|
|
+ v-model="deptBudgetList.grade"
|
|
|
+ placeholder="请选择品级"
|
|
|
+ class="typeselect"
|
|
|
+ @change="selectpackingMethod"
|
|
|
+ >
|
|
|
+ <ws-option
|
|
|
+ v-for="item in gradeList"
|
|
|
+ :key="item.constKey"
|
|
|
+ :label="item.constValue"
|
|
|
+ :value="item.constValue"
|
|
|
+ />
|
|
|
+ </ws-select>
|
|
|
+ </ws-form-item>
|
|
|
+ <!-- 容重(%)<= -->
|
|
|
+ <el-form-item label="容重(%)<=">
|
|
|
+ <el-input v-model="form.name" placeholder="请输入容重"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 水分(%)<= -->
|
|
|
+ <el-form-item label="水分(%)<=">
|
|
|
+ <el-input v-model="form.name" placeholder="请输入水分"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 单价(元/吨) -->
|
|
|
+ <el-form-item label="单价(元/吨)">
|
|
|
+ <el-input v-model="form.name" placeholder="请输入单价"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 预计入库日期 -->
|
|
|
+ <el-form-item label="预计入库日期">
|
|
|
+ <el-col :span="11">
|
|
|
+ <el-date-picker type="date" placeholder="请选择日期" v-model="form.date1" style="width: 100%;"></el-date-picker>
|
|
|
+ </el-col>
|
|
|
+ <el-col class="line" :span="2">-</el-col>
|
|
|
+ </el-form-item>
|
|
|
+ <!--入库经办人-->
|
|
|
+ <el-form-item label="入库经办人">
|
|
|
+ <el-select v-model="form.region" placeholder="请选择经办人">
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <!-- 业务描述 -->
|
|
|
+ <el-form-item label="业务描述">
|
|
|
+ <el-input type="textarea" v-model="form.desc" placeholder="请输入业务描述"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+
|
|
|
+ <div style="text-align: right; padding: 10px">
|
|
|
+ <el-button
|
|
|
+ class="bg-bottom-up"
|
|
|
+ type="primary"
|
|
|
+ size="small"
|
|
|
+ @click="submit()"
|
|
|
+ >提交</el-button
|
|
|
+ >
|
|
|
+ </div>
|
|
|
+ </ws-info-table>
|
|
|
+ </el-form>
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ </div>
|
|
|
+</template>
|
|
|
+<script>
|
|
|
+import {
|
|
|
+ pullDown,
|
|
|
+ addstorageputList,
|
|
|
+ xialaNo,
|
|
|
+ getstaff,
|
|
|
+} from '@/model/warehouse/index'
|
|
|
+import Pagination from '@/components/Pagination'
|
|
|
+import WsUpload from '@/components/WsUpload'
|
|
|
+// import { dayjs, fmoney, EventBus } from 'base-core-lib'
|
|
|
+import { dayjs, EventBus } from 'base-core-lib'
|
|
|
+export default {
|
|
|
+ name: 'viewSpareMoney',
|
|
|
+ components: {
|
|
|
+ WsUpload,
|
|
|
+ Pagination,
|
|
|
+ },
|
|
|
+ watch: {
|
|
|
+ // vesselId(val) {
|
|
|
+ // this.getList()
|
|
|
+ // },
|
|
|
+ isShow(val) {
|
|
|
+ this.showType = val
|
|
|
+ },
|
|
|
+ },
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ //弹出框
|
|
|
+ dialogViewSpareMoney: false,
|
|
|
+ dialogApproveFormVisible: false,
|
|
|
+ // 船舶类型
|
|
|
+ monetaryKey: null,
|
|
|
+ // 表格显示数据
|
|
|
+ tableDate: [],
|
|
|
+ // 是否显示
|
|
|
+ showType: true,
|
|
|
+ // 年
|
|
|
+ year: '',
|
|
|
+ deptBudgetTotal: 0,
|
|
|
+ currentPage: 1,
|
|
|
+ pageSize: 10,
|
|
|
+ searchType: 1,
|
|
|
+ searchKeyWord: '',
|
|
|
+ contractType: 2,
|
|
|
+ startDate: null,
|
|
|
+ endDate: null,
|
|
|
+ goodnameList: {},
|
|
|
+ checked: true,
|
|
|
+ agent: [],
|
|
|
+ staffList: [],
|
|
|
+ options: [],
|
|
|
+ form:{},
|
|
|
+ radio: '1',
|
|
|
+ outContractNo: [],
|
|
|
+ props: [],
|
|
|
+ bulkDensity: [],
|
|
|
+
|
|
|
+ // 提交类型
|
|
|
+ submitType: true,
|
|
|
+ storageType: [],
|
|
|
+ deliveryType: [],
|
|
|
+ readonly: true,
|
|
|
+ appendixIdsAdd: '',
|
|
|
+ uploadSuccess: {},
|
|
|
+ onChange: {},
|
|
|
+ gradeList: [],
|
|
|
+ rules: {
|
|
|
+ netWeight: [
|
|
|
+ {
|
|
|
+ required: true,
|
|
|
+ type: 'number',
|
|
|
+ message: '请输入活动名称',
|
|
|
+ trigger: 'blur',
|
|
|
+ },
|
|
|
+ ],
|
|
|
+ },
|
|
|
+ size: 10,
|
|
|
+ compId: sessionStorage.getItem('ws-pf_compId'),
|
|
|
+ deptCircularPage: {},
|
|
|
+ packtypeList: {},
|
|
|
+ date: {
|
|
|
+ year: dayjs().format('YYYY'),
|
|
|
+ month: dayjs().format('MM'),
|
|
|
+ },
|
|
|
+ contractList: [],
|
|
|
+ deptBudgetList: {
|
|
|
+ warehouseInOutDetail: {},
|
|
|
+ },
|
|
|
+ historyList: [],
|
|
|
+
|
|
|
+ pickerBeginDateBefore: {
|
|
|
+ disabledDate: (time) => {
|
|
|
+ return time.getTime() > Date.now()
|
|
|
+ },
|
|
|
+ },
|
|
|
+ accessoryTFs: false,
|
|
|
+ }
|
|
|
+ },
|
|
|
+ mounted() {
|
|
|
+ this.deptBudgetList.baseId = this.$route.query.baseId
|
|
|
+ this.deptBudgetList.positionId = this.$route.query.positionId
|
|
|
+ this.deptBudgetList.warehouseName = this.$route.query.warehouseName
|
|
|
+ this.deptBudgetList.binNumber = this.$route.query.binNumber
|
|
|
+ this.deptBudgetList.warehouseType = this.$route.query.warehouseType
|
|
|
+ this.deptBudgetList.createType = this.$route.query.createType
|
|
|
+ this.getList()
|
|
|
+ this.deptBudgetList.goodsName = '玉米'
|
|
|
+ this.deptBudgetList.goodsNameKey = '1'
|
|
|
+ this.deptBudgetList.grade = '一等品'
|
|
|
+ this.deptBudgetList.gradeKey = '1'
|
|
|
+ if (this.deptBudgetList.warehouseType == 1) {
|
|
|
+ this.deptBudgetList.inOutType = '采购入库'
|
|
|
+ this.deptBudgetList.inOutTypeKey = '1'
|
|
|
+ } else {
|
|
|
+ this.deptBudgetList.inOutType = '退库'
|
|
|
+ this.deptBudgetList.inOutTypeKey = '1'
|
|
|
+ }
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ //返回按钮
|
|
|
+ revert() {
|
|
|
+ this.$router.push({ path: 'warehouseManagementList' })
|
|
|
+ },
|
|
|
+ dataFilter(val) {
|
|
|
+ // console.log(val,"名")
|
|
|
+ this.deptBudgetList.staffList = val
|
|
|
+ if (val) {
|
|
|
+ //val存在
|
|
|
+ this.options = this.staffList.filter((item) => {
|
|
|
+ if (
|
|
|
+ !!~item.staffName.indexOf(val) ||
|
|
|
+ !!~item.staffName.toUpperCase().indexOf(val.toUpperCase())
|
|
|
+ ) {
|
|
|
+ return true
|
|
|
+ }
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ //val为空时,还原数组
|
|
|
+ this.options = this.staffList
|
|
|
+ }
|
|
|
+ },
|
|
|
+ selectstaff(e) {
|
|
|
+ for (var i = 0; i < this.staffList.length; i++) {
|
|
|
+ if (this.staffList[i].staffName == e) {
|
|
|
+ this.deptBudgetList.personChargeKey = this.staffList[i].staffId
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ //提交按钮
|
|
|
+ submit() {
|
|
|
+ if (!this.deptBudgetList.goodsName) {
|
|
|
+ this.$message({
|
|
|
+ message: '货名不能为空',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (!this.deptBudgetList.grossWeight) {
|
|
|
+ this.$message({
|
|
|
+ message: '毛重不能为空',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.grossWeight < 0 ||
|
|
|
+ this.deptBudgetList.grossWeight > 10000 ||
|
|
|
+ (String(this.deptBudgetList.grossWeight).indexOf('.') != -1 &&
|
|
|
+ String(this.deptBudgetList.grossWeight).length -
|
|
|
+ (String(this.deptBudgetList.grossWeight).indexOf('.') + 1) >
|
|
|
+ 3)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '毛重输入错误',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (!this.deptBudgetList.tare) {
|
|
|
+ this.$message({
|
|
|
+ message: '皮重不能为空',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.tare < 0 ||
|
|
|
+ this.deptBudgetList.tare > 10000 ||
|
|
|
+ (String(this.deptBudgetList.tare).indexOf('.') != -1 &&
|
|
|
+ String(this.deptBudgetList.tare).length -
|
|
|
+ (String(this.deptBudgetList.tare).indexOf('.') + 1) >
|
|
|
+ 3)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '皮重输入错误',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (!this.deptBudgetList.agent) {
|
|
|
+ this.$message({
|
|
|
+ message: '经办人不能为空',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.agent.length < 2 ||
|
|
|
+ this.deptBudgetList.agent.length > 10
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '经办人输入有误',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (!this.deptBudgetList.grade) {
|
|
|
+ this.$message({
|
|
|
+ message: '品级不能为空!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (!this.deptBudgetList.inOutDate) {
|
|
|
+ this.$message({
|
|
|
+ message: '入库日期不能为空!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (!this.deptBudgetList.inOutType) {
|
|
|
+ this.$message({
|
|
|
+ message: '入库类型不能为空!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (!this.deptBudgetList.carNo) {
|
|
|
+ this.$message({
|
|
|
+ message: '车牌号不能为空',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (this.deptBudgetList.carNo.length > 7) {
|
|
|
+ this.$message({
|
|
|
+ message: '车牌号输入错误,请输入7个字符之内',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (!this.deptBudgetList.contractNo) {
|
|
|
+ this.$message({
|
|
|
+ message: '合同编号不能为空',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.contractNo.length < 6 ||
|
|
|
+ this.deptBudgetList.contractNo.length > 20
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '合同编号长度不符合要求,请输入6-20个字符之内',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+
|
|
|
+ // if (this.deptBudgetList.netWeight > this.$route.query.capacity) {
|
|
|
+ // this.$message({
|
|
|
+ // message: '入库量大于该仓库容量!',
|
|
|
+ // type: 'warning',
|
|
|
+ // })
|
|
|
+ // return
|
|
|
+ // }
|
|
|
+ //自检员
|
|
|
+ if (this.deptBudgetList.warehouseInOutDetail.qualityInspector) {
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.qualityInspector.length <
|
|
|
+ 2 ||
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.qualityInspector.length > 10
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '质检员姓名长度错误!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if (this.deptBudgetList.warehouseInOutDetail.waterContent) {
|
|
|
+ if (isNaN(this.deptBudgetList.warehouseInOutDetail.waterContent)) {
|
|
|
+ this.$message({
|
|
|
+ message: '水分(%)非数字!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.waterContent < 1 ||
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.waterContent > 40 ||
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.waterContent
|
|
|
+ ).indexOf('.') != -1 &&
|
|
|
+ String(this.deptBudgetList.warehouseInOutDetail.waterContent)
|
|
|
+ .length -
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.waterContent
|
|
|
+ ).indexOf('.') +
|
|
|
+ 1) >
|
|
|
+ 2)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '水分(%)输入错误! 取值范围1-40之间且可以保留2小数',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ //杂质
|
|
|
+ if (this.deptBudgetList.warehouseInOutDetail.impurity) {
|
|
|
+ if (isNaN(this.deptBudgetList.warehouseInOutDetail.impurity)) {
|
|
|
+ this.$message({
|
|
|
+ message: '杂质(%)非数字!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.impurity < 1 ||
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.impurity > 40 ||
|
|
|
+ (String(this.deptBudgetList.warehouseInOutDetail.impurity).indexOf(
|
|
|
+ '.'
|
|
|
+ ) != -1 &&
|
|
|
+ String(this.deptBudgetList.warehouseInOutDetail.impurity).length -
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.impurity
|
|
|
+ ).indexOf('.') +
|
|
|
+ 1) >
|
|
|
+ 2)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '杂质(%)输入错误! 取值范围1-40之间且可以保留2小数',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
+ //霉变
|
|
|
+ if (this.deptBudgetList.warehouseInOutDetail.mildewGrain) {
|
|
|
+ if (isNaN(this.deptBudgetList.warehouseInOutDetail.mildewGrain)) {
|
|
|
+ this.$message({
|
|
|
+ message: '霉变粒(%)非数字!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.mildewGrain < 1 ||
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.mildewGrain > 40 ||
|
|
|
+ (String(this.deptBudgetList.warehouseInOutDetail.mildewGrain).indexOf(
|
|
|
+ '.'
|
|
|
+ ) != -1 &&
|
|
|
+ String(this.deptBudgetList.warehouseInOutDetail.mildewGrain)
|
|
|
+ .length -
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.mildewGrain
|
|
|
+ ).indexOf('.') +
|
|
|
+ 1) >
|
|
|
+ 2)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '霉变粒(%)输入错误! 取值范围1-40之间且可以保留2小数',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ //热损伤
|
|
|
+ if (this.deptBudgetList.warehouseInOutDetail.jiaorenli) {
|
|
|
+ if (isNaN(this.deptBudgetList.warehouseInOutDetail.jiaorenli)) {
|
|
|
+ this.$message({
|
|
|
+ message: '热损伤(%)非数字!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.jiaorenli < 1 ||
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.jiaorenli > 40 ||
|
|
|
+ (String(this.deptBudgetList.warehouseInOutDetail.jiaorenli).indexOf(
|
|
|
+ '.'
|
|
|
+ ) != -1 &&
|
|
|
+ String(this.deptBudgetList.warehouseInOutDetail.jiaorenli).length -
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.jiaorenli
|
|
|
+ ).indexOf('.') +
|
|
|
+ 1) >
|
|
|
+ 2)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '热损伤(%)输入错误! 取值范围1-40之间且可以保留2小数',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ //不完整粒(%)
|
|
|
+ if (this.deptBudgetList.warehouseInOutDetail.imperfectGrain) {
|
|
|
+ if (isNaN(this.deptBudgetList.warehouseInOutDetail.imperfectGrain)) {
|
|
|
+ this.$message({
|
|
|
+ message: '不完整粒(%)非数字!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.imperfectGrain < 1 ||
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.imperfectGrain > 40 ||
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.imperfectGrain
|
|
|
+ ).indexOf('.') != -1 &&
|
|
|
+ String(this.deptBudgetList.warehouseInOutDetail.imperfectGrain)
|
|
|
+ .length -
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.imperfectGrain
|
|
|
+ ).indexOf('.') +
|
|
|
+ 1) >
|
|
|
+ 2)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '不完整粒(%)输入错误! 取值范围1-40之间且可以保留2小数',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
+ //容重
|
|
|
+ if (this.deptBudgetList.warehouseInOutDetail.bulkDensity) {
|
|
|
+ if (isNaN(this.deptBudgetList.warehouseInOutDetail.bulkDensity)) {
|
|
|
+ this.$message({
|
|
|
+ message: '容重(克/升)非数字!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.bulkDensity < 1 ||
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.bulkDensity > 40 ||
|
|
|
+ (String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).indexOf(
|
|
|
+ '.'
|
|
|
+ ) != -1 &&
|
|
|
+ String(this.deptBudgetList.warehouseInOutDetail.bulkDensity)
|
|
|
+ .length -
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.bulkDensity
|
|
|
+ ).indexOf('.') +
|
|
|
+ 1) >
|
|
|
+ 0)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '容重(克/升)输入错误! 取值范围1-40之间且是整数',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
+ this.deptBudgetList.id = this.$route.query.id
|
|
|
+ this.$confirm(`确定提交入库信息`, {
|
|
|
+ cancelButtonText: '取消',
|
|
|
+ confirmButtonText: '确定',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ .then(() => {
|
|
|
+ this.$refs.deptBudgetList.validate((valid) => {
|
|
|
+ if (valid) {
|
|
|
+ this.deptBudgetList.compId =
|
|
|
+ sessionStorage.getItem('ws-pf_compId')
|
|
|
+ this.deptBudgetList.inOutFlag = 2
|
|
|
+ this.deptBudgetList.statusFlag = 3
|
|
|
+ addstorageputList(this.deptBudgetList)
|
|
|
+ .toPromise()
|
|
|
+ .then((response) => {
|
|
|
+ this.$message.success('添加成功')
|
|
|
+ this.$router.push({ path: 'warehouseManagementList' })
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ EventBus.$emit('error', this.$t('showMessage.asteriskRequired'))
|
|
|
+ return false
|
|
|
+ }
|
|
|
+ })
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ return false
|
|
|
+ })
|
|
|
+ },
|
|
|
+ temporaryStorage() {
|
|
|
+ if (!this.deptBudgetList.goodsName) {
|
|
|
+ this.$message({
|
|
|
+ message: '货名不能为空',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (!this.deptBudgetList.grossWeight) {
|
|
|
+ this.$message({
|
|
|
+ message: '毛重不能为空',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.grossWeight < 0 ||
|
|
|
+ this.deptBudgetList.grossWeight > 10000 ||
|
|
|
+ (String(this.deptBudgetList.grossWeight).indexOf('.') != -1 &&
|
|
|
+ String(this.deptBudgetList.grossWeight).length -
|
|
|
+ (String(this.deptBudgetList.grossWeight).indexOf('.') + 1) >
|
|
|
+ 3)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '毛重输入错误',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (!this.deptBudgetList.tare) {
|
|
|
+ this.$message({
|
|
|
+ message: '皮重不能为空',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.tare < 0 ||
|
|
|
+ this.deptBudgetList.tare > 10000 ||
|
|
|
+ (String(this.deptBudgetList.tare).indexOf('.') != -1 &&
|
|
|
+ String(this.deptBudgetList.tare).length -
|
|
|
+ (String(this.deptBudgetList.tare).indexOf('.') + 1) >
|
|
|
+ 3)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '皮重输入错误',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (!this.deptBudgetList.agent) {
|
|
|
+ this.$message({
|
|
|
+ message: '经办人不能为空',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.agent.length < 2 ||
|
|
|
+ this.deptBudgetList.agent.length > 10
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '经办人输入有误',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (!this.deptBudgetList.carNo) {
|
|
|
+ this.$message({
|
|
|
+ message: '车牌号不能为空',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (this.deptBudgetList.carNo.length > 7) {
|
|
|
+ this.$message({
|
|
|
+ message: '车牌号输入错误,请输入7个字符之内',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (!this.deptBudgetList.contractNo) {
|
|
|
+ this.$message({
|
|
|
+ message: '合同编号不能为空',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.contractNo.length < 6 ||
|
|
|
+ this.deptBudgetList.contractNo.length > 20
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '合同编号长度不符合要求,请输入6-20个字符之内',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ // if (this.deptBudgetList.netWeight > this.$route.query.capacity) {
|
|
|
+ // this.$message({
|
|
|
+ // message: '入库量大于该仓库容量!',
|
|
|
+ // type: 'warning',
|
|
|
+ // })
|
|
|
+ // return
|
|
|
+ // }
|
|
|
+ //自检员
|
|
|
+ if (this.deptBudgetList.warehouseInOutDetail.qualityInspector) {
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.qualityInspector.length <
|
|
|
+ 2 ||
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.qualityInspector.length > 10
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '质检员姓名长度错误!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if (this.deptBudgetList.warehouseInOutDetail.waterContent) {
|
|
|
+ if (isNaN(this.deptBudgetList.warehouseInOutDetail.waterContent)) {
|
|
|
+ this.$message({
|
|
|
+ message: '水分(%)非数字!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.waterContent < 1 ||
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.waterContent > 40 ||
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.waterContent
|
|
|
+ ).indexOf('.') != -1 &&
|
|
|
+ String(this.deptBudgetList.warehouseInOutDetail.waterContent)
|
|
|
+ .length -
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.waterContent
|
|
|
+ ).indexOf('.') +
|
|
|
+ 1) >
|
|
|
+ 2)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '水分(%)输入错误! 取值范围1-40之间且可以保留2小数',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ //杂质
|
|
|
+ if (this.deptBudgetList.warehouseInOutDetail.impurity) {
|
|
|
+ if (isNaN(this.deptBudgetList.warehouseInOutDetail.impurity)) {
|
|
|
+ this.$message({
|
|
|
+ message: '杂质(%)非数字!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.impurity < 1 ||
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.impurity > 40 ||
|
|
|
+ (String(this.deptBudgetList.warehouseInOutDetail.impurity).indexOf(
|
|
|
+ '.'
|
|
|
+ ) != -1 &&
|
|
|
+ String(this.deptBudgetList.warehouseInOutDetail.impurity).length -
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.impurity
|
|
|
+ ).indexOf('.') +
|
|
|
+ 1) >
|
|
|
+ 2)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '杂质(%)输入错误! 取值范围1-40之间且可以保留2小数',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
+ //霉变
|
|
|
+ if (this.deptBudgetList.warehouseInOutDetail.mildewGrain) {
|
|
|
+ if (isNaN(this.deptBudgetList.warehouseInOutDetail.mildewGrain)) {
|
|
|
+ this.$message({
|
|
|
+ message: '霉变粒(%)非数字!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.mildewGrain < 1 ||
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.mildewGrain > 40 ||
|
|
|
+ (String(this.deptBudgetList.warehouseInOutDetail.mildewGrain).indexOf(
|
|
|
+ '.'
|
|
|
+ ) != -1 &&
|
|
|
+ String(this.deptBudgetList.warehouseInOutDetail.mildewGrain)
|
|
|
+ .length -
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.mildewGrain
|
|
|
+ ).indexOf('.') +
|
|
|
+ 1) >
|
|
|
+ 2)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '霉变粒(%)输入错误! 取值范围1-40之间且可以保留2小数',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ //热损伤
|
|
|
+ if (this.deptBudgetList.warehouseInOutDetail.jiaorenli) {
|
|
|
+ if (isNaN(this.deptBudgetList.warehouseInOutDetail.jiaorenli)) {
|
|
|
+ this.$message({
|
|
|
+ message: '热损伤(%)非数字!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.jiaorenli < 1 ||
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.jiaorenli > 40 ||
|
|
|
+ (String(this.deptBudgetList.warehouseInOutDetail.jiaorenli).indexOf(
|
|
|
+ '.'
|
|
|
+ ) != -1 &&
|
|
|
+ String(this.deptBudgetList.warehouseInOutDetail.jiaorenli).length -
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.jiaorenli
|
|
|
+ ).indexOf('.') +
|
|
|
+ 1) >
|
|
|
+ 2)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '热损伤(%)输入错误! 取值范围1-40之间且可以保留2小数',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ //不完整粒(%)
|
|
|
+ if (this.deptBudgetList.warehouseInOutDetail.imperfectGrain) {
|
|
|
+ if (isNaN(this.deptBudgetList.warehouseInOutDetail.imperfectGrain)) {
|
|
|
+ this.$message({
|
|
|
+ message: '不完整粒(%)非数字!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.imperfectGrain < 1 ||
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.imperfectGrain > 40 ||
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.imperfectGrain
|
|
|
+ ).indexOf('.') != -1 &&
|
|
|
+ String(this.deptBudgetList.warehouseInOutDetail.imperfectGrain)
|
|
|
+ .length -
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.imperfectGrain
|
|
|
+ ).indexOf('.') +
|
|
|
+ 1) >
|
|
|
+ 2)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '不完整粒(%)输入错误! 取值范围1-40之间且可以保留2小数',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
+ //容重
|
|
|
+ if (this.deptBudgetList.warehouseInOutDetail.bulkDensity) {
|
|
|
+ if (isNaN(this.deptBudgetList.warehouseInOutDetail.bulkDensity)) {
|
|
|
+ this.$message({
|
|
|
+ message: '容重(克/升)非数字!',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.bulkDensity < 1 ||
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.bulkDensity > 40 ||
|
|
|
+ (String(this.deptBudgetList.warehouseInOutDetail.bulkDensity).indexOf(
|
|
|
+ '.'
|
|
|
+ ) != -1 &&
|
|
|
+ String(this.deptBudgetList.warehouseInOutDetail.bulkDensity)
|
|
|
+ .length -
|
|
|
+ (String(
|
|
|
+ this.deptBudgetList.warehouseInOutDetail.bulkDensity
|
|
|
+ ).indexOf('.') +
|
|
|
+ 1) >
|
|
|
+ 0)
|
|
|
+ ) {
|
|
|
+ this.$message({
|
|
|
+ message: '容重(克/升)输入错误! 取值范围1-40之间且是整数',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
+ this.$confirm(`暂存后可在待完成页面查看,确定暂存`, {
|
|
|
+ cancelButtonText: '取消',
|
|
|
+ confirmButtonText: '确定',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ .then(() => {
|
|
|
+ this.$refs.deptBudgetList.validate((valid) => {
|
|
|
+ if (valid) {
|
|
|
+ this.deptBudgetList.compId =
|
|
|
+ sessionStorage.getItem('ws-pf_compId')
|
|
|
+ this.deptBudgetList.inOutFlag = 2
|
|
|
+ this.deptBudgetList.statusFlag = 1
|
|
|
+ addstorageputList(this.deptBudgetList)
|
|
|
+ .toPromise()
|
|
|
+ .then((response) => {
|
|
|
+ this.$message.success('暂存成功')
|
|
|
+ this.$router.push({ path: 'warehouseManagementList' })
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ EventBus.$emit('error', this.$t('showMessage.asteriskRequired'))
|
|
|
+ return false
|
|
|
+ }
|
|
|
+ })
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ return false
|
|
|
+ })
|
|
|
+ },
|
|
|
+ tarechange(e) {
|
|
|
+ if (this.deptBudgetList.grossWeight && this.deptBudgetList.tare) {
|
|
|
+ this.deptBudgetList.netWeight = Number(
|
|
|
+ this.deptBudgetList.grossWeight - this.deptBudgetList.tare
|
|
|
+ )
|
|
|
+ }
|
|
|
+ },
|
|
|
+ grossWeightchange(e) {
|
|
|
+ if (this.deptBudgetList.grossWeight && this.deptBudgetList.tare) {
|
|
|
+ this.deptBudgetList.netWeight = Number(
|
|
|
+ this.deptBudgetList.grossWeight - this.deptBudgetList.tare
|
|
|
+ )
|
|
|
+ }
|
|
|
+ },
|
|
|
+ selectgoodsName(e) {
|
|
|
+ for (var i = 0; i < this.goodnameList.length; i++) {
|
|
|
+ if (this.goodnameList[i].constValue == e) {
|
|
|
+ this.deptBudgetList.goodsNameKey = this.goodnameList[i].constKey
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ selectpackingMethod(e) {
|
|
|
+ for (var i = 0; i < this.packtypeList.length; i++) {
|
|
|
+ if (this.packtypeList[i].constValue == e) {
|
|
|
+ this.deptBudgetList.packingMethodKey = this.packtypeList[i].constKey
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ selectstorageType(e) {
|
|
|
+ for (var i = 0; i < this.storageType.length; i++) {
|
|
|
+ if (this.storageType[i].constValue == e) {
|
|
|
+ this.deptBudgetList.inOutTypeKey = this.storageType[i].constKey
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ handleClose() {
|
|
|
+ this.accessoryTFs = false
|
|
|
+ },
|
|
|
+ handleSizeChange(val) {
|
|
|
+ console.log(`每页 ${val} 条`)
|
|
|
+ this.pageSize = val
|
|
|
+ this.getList()
|
|
|
+ },
|
|
|
+ handleCurrentChange(val) {
|
|
|
+ this.currentPage = val
|
|
|
+ console.log(`当前页: ${val}`)
|
|
|
+ this.getList()
|
|
|
+ },
|
|
|
+ getList() {
|
|
|
+ // 货名
|
|
|
+ pullDown({ constId: 'CON2' })
|
|
|
+ .toPromise()
|
|
|
+ .then((response) => {
|
|
|
+ this.goodnameList = response
|
|
|
+ })
|
|
|
+ // 品级
|
|
|
+ pullDown({ constId: 'CON3' })
|
|
|
+ .toPromise()
|
|
|
+ .then((response) => {
|
|
|
+ this.gradeList = response
|
|
|
+ })
|
|
|
+ // 类型
|
|
|
+ if (this.deptBudgetList.warehouseType == '1') {
|
|
|
+ pullDown({ constId: 'CON5' })
|
|
|
+ .toPromise()
|
|
|
+ .then((response) => {
|
|
|
+ this.storageType = response
|
|
|
+ })
|
|
|
+ } else if (this.deptBudgetList.warehouseType == '2') {
|
|
|
+ pullDown({ constId: 'WARE1' })
|
|
|
+ .toPromise()
|
|
|
+ .then((response) => {
|
|
|
+ this.storageType = response
|
|
|
+ })
|
|
|
+
|
|
|
+ pullDown({ constId: 'WARE2' })
|
|
|
+ .toPromise()
|
|
|
+ .then((response) => {
|
|
|
+ this.deliveryType = response
|
|
|
+ })
|
|
|
+ }
|
|
|
+ //合同编号
|
|
|
+ xialaNo({ compId: sessionStorage.getItem('ws-pf_compId') })
|
|
|
+ .toPromise()
|
|
|
+ .then((response) => {
|
|
|
+ this.outContractNo = response
|
|
|
+ })
|
|
|
+ //经办人
|
|
|
+ getstaff({ compId: sessionStorage.getItem('ws-pf_compId') })
|
|
|
+ .toPromise()
|
|
|
+ .then((response) => {
|
|
|
+ this.options = response
|
|
|
+ this.staffList = response
|
|
|
+ // this.agent = response
|
|
|
+ })
|
|
|
+ },
|
|
|
+ selecttaskType(e) {
|
|
|
+ for (var i = 0; i < this.taskTypeList.length; i++) {
|
|
|
+ if (this.taskTypeList[i].value == e) {
|
|
|
+ this.searchType = this.taskTypeList[i].type
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ fujian(row) {
|
|
|
+ if (
|
|
|
+ row.receiveAttachmentPath === null ||
|
|
|
+ row.receiveAttachmentPath === ''
|
|
|
+ ) {
|
|
|
+ EventBus.$emit(
|
|
|
+ 'warning',
|
|
|
+ this.$t('system.noticeCircular.NoInformation')
|
|
|
+ )
|
|
|
+ } else {
|
|
|
+ this.accessoryTFs = true
|
|
|
+ }
|
|
|
+ this.appendixIdss = row.receiveAttachmentPath
|
|
|
+ },
|
|
|
+ handleExamine(row) {
|
|
|
+ this.$router.push({
|
|
|
+ name: 'salesContractExamine',
|
|
|
+ query: { id: row.id },
|
|
|
+ })
|
|
|
+ },
|
|
|
+
|
|
|
+ // 关闭 dialog时 处理文件url 初始化upload组件
|
|
|
+ // handleCloe() {
|
|
|
+ // this.dialogViewSpareMoney = false
|
|
|
+ // },
|
|
|
+ // history(row) {
|
|
|
+ // billoperatehis({ id: row.id })
|
|
|
+ // .toPromise()
|
|
|
+ // .then((response) => {
|
|
|
+ // this.historyList = response
|
|
|
+ // })
|
|
|
+ // },
|
|
|
+ // deletecontract(){},
|
|
|
+ //删除
|
|
|
+ approve() {},
|
|
|
+ listQuery() {},
|
|
|
+ },
|
|
|
+}
|
|
|
+</script>
|
|
|
+<style lang="scss" scoped>
|
|
|
+/deep/.basicInformation {
|
|
|
+ .ws-info-table {
|
|
|
+ border: none;
|
|
|
+ }
|
|
|
+ .el-form-item {
|
|
|
+ width: 33.3333%;
|
|
|
+ border: none;
|
|
|
+ .el-form-item__label {
|
|
|
+ background: transparent;
|
|
|
+ border: none;
|
|
|
+ }
|
|
|
+ .el-form-item__content {
|
|
|
+ border: none;
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+.title {
|
|
|
+ position: relative;
|
|
|
+ padding-left: 10px;
|
|
|
+}
|
|
|
+.title::before {
|
|
|
+ content: '';
|
|
|
+ display: inline-block;
|
|
|
+ width: 5px;
|
|
|
+ height: 30px;
|
|
|
+ background: #5473e8;
|
|
|
+ position: absolute;
|
|
|
+ left: 0;
|
|
|
+}
|
|
|
+.el-form {
|
|
|
+ padding: 0 10%;
|
|
|
+}
|
|
|
+.el-button--primary {
|
|
|
+ background-color: #5878e8;
|
|
|
+ border-color: #5878e8;
|
|
|
+}
|
|
|
+.el-col {
|
|
|
+ background: #f6f7fc;
|
|
|
+}
|
|
|
+.bg-right {
|
|
|
+ text-align: right;
|
|
|
+ padding: 16px 20px;
|
|
|
+}
|
|
|
+.center {
|
|
|
+ position: relative;
|
|
|
+ top: 50px;
|
|
|
+ width: 40%;
|
|
|
+ height: 2000px;
|
|
|
+ margin: 0 auto;
|
|
|
+}
|
|
|
+
|
|
|
+//选填
|
|
|
+/deep/.el-form-item {
|
|
|
+ width: 50%;
|
|
|
+}
|
|
|
+.container {
|
|
|
+ overflow: scroll;
|
|
|
+ height: 120vh;
|
|
|
+}
|
|
|
+/deep/.ws-info-table .el-form-item .el-form-item__label {
|
|
|
+ text-align: center;
|
|
|
+}
|
|
|
+.deliverydate {
|
|
|
+ display: inline-block;
|
|
|
+ width: 10%;
|
|
|
+}
|
|
|
+.center {
|
|
|
+ margin-top: -60px;
|
|
|
+ width: 80%;
|
|
|
+}
|
|
|
+//仓位
|
|
|
+
|
|
|
+.position {
|
|
|
+ background: #afb5cb;
|
|
|
+ border-radius: 2px;
|
|
|
+ font-size: 12px;
|
|
|
+ color: #ffffff;
|
|
|
+ line-height: 20px;
|
|
|
+ display: inline-grid;
|
|
|
+ padding: 2px 4px;
|
|
|
+}
|
|
|
+//表格文字
|
|
|
+/deep/.ws-info-table .el-form-item .el-form-item__label {
|
|
|
+ text-align: left;
|
|
|
+ font-size: 14px;
|
|
|
+ font-family: PingFangSC-Regular, PingFang SC;
|
|
|
+ font-weight: 400;
|
|
|
+ color: #8890b1;
|
|
|
+ line-height: 16px;
|
|
|
+}
|
|
|
+.inspector {
|
|
|
+ width: 50%;
|
|
|
+}
|
|
|
+//质检员
|
|
|
+.inspector .el-form-item__content {
|
|
|
+ text-align: left;
|
|
|
+ margin-left: 0px;
|
|
|
+}
|
|
|
+.small-title {
|
|
|
+ position: relative;
|
|
|
+ padding: 10px;
|
|
|
+ font-weight: 600;
|
|
|
+}
|
|
|
+.small-title::before {
|
|
|
+ position: absolute;
|
|
|
+ content: '';
|
|
|
+ display: block;
|
|
|
+ background: #5473e8;
|
|
|
+ width: 4px;
|
|
|
+ height: 14px;
|
|
|
+ left: 0px;
|
|
|
+ top: 13px;
|
|
|
+ padding: 4px 2px;
|
|
|
+}
|
|
|
+//下面列表
|
|
|
+.neifor {
|
|
|
+ width: 80%;
|
|
|
+ background-color: #f6f7fc;
|
|
|
+}
|
|
|
+/deep/.neifor .ws-info-table .el-form-item .el-form-item__label {
|
|
|
+ width: 35%;
|
|
|
+ text-align: center;
|
|
|
+}
|
|
|
+/deep/.neifor .ws-info-table .el-form-item .el-form-item__content {
|
|
|
+ width: 60%;
|
|
|
+ background-color: #f6f7fc;
|
|
|
+}
|
|
|
+
|
|
|
+/deep/.neifor .el-input--small .el-input__inner {
|
|
|
+ width: 100%;
|
|
|
+}
|
|
|
+</style>
|