|
@@ -28,6 +28,7 @@
|
|
|
<!--任务编号-->
|
|
|
<ws-form-item label="任务编号" span="1" prop="processNo">
|
|
|
<ws-input
|
|
|
+ :disabled="disabled"
|
|
|
v-model="deptBudgetList.processNo"
|
|
|
placeholder="请输入任务编号"
|
|
|
maxlength="20"
|
|
@@ -50,6 +51,7 @@
|
|
|
:value="item.staffName"
|
|
|
/> -->
|
|
|
<ws-input
|
|
|
+ :disabled="disabled"
|
|
|
v-model="deptBudgetList.goodsName"
|
|
|
placeholder="请输入货名"
|
|
|
maxlength="20"
|
|
@@ -60,6 +62,7 @@
|
|
|
<!--重量(吨)-->
|
|
|
<ws-form-item label="重量(吨)" span="1" prop="weight">
|
|
|
<ws-input
|
|
|
+ :disabled="disabled"
|
|
|
v-model="deptBudgetList.weight"
|
|
|
placeholder="请输入重量(吨)"
|
|
|
maxlength="100"
|
|
@@ -82,6 +85,7 @@
|
|
|
<!--发货人-->
|
|
|
<ws-form-item label="发货人" span="1" prop="sender" class="readonly">
|
|
|
<ws-input
|
|
|
+ :disabled="disabled"
|
|
|
v-model="deptBudgetList.sender"
|
|
|
placeholder="请输入发货人"
|
|
|
maxlength="100"
|
|
@@ -97,6 +101,7 @@
|
|
|
class="readonly"
|
|
|
>
|
|
|
<ws-input
|
|
|
+ :disabled="disabled"
|
|
|
v-model="deptBudgetList.senderPhone"
|
|
|
placeholder="请输入发货人电话"
|
|
|
maxlength="100"
|
|
@@ -117,6 +122,7 @@
|
|
|
<!--收货人-->
|
|
|
<ws-form-item label="收货人" span="1" prop="receiver">
|
|
|
<ws-input
|
|
|
+ :disabled="disabled"
|
|
|
v-model="deptBudgetList.receiver"
|
|
|
placeholder="请输入仓库名"
|
|
|
maxlength="20"
|
|
@@ -126,6 +132,7 @@
|
|
|
<!--收货人电话-->
|
|
|
<ws-form-item label="收货人电话" span="1" prop="receiverPhone">
|
|
|
<ws-input
|
|
|
+ :disabled="disabled"
|
|
|
v-model="deptBudgetList.receiverPhone"
|
|
|
placeholder="请输入仓库名"
|
|
|
maxlength="20"
|
|
@@ -135,6 +142,7 @@
|
|
|
<!--发货日期-->
|
|
|
<ws-form-item label="发货日期" span="1" prop="deliveryDateStart">
|
|
|
<ws-input
|
|
|
+ :disabled="disabled"
|
|
|
v-model="deptBudgetList.deliveryDateStart"
|
|
|
placeholder="请输入仓库名"
|
|
|
maxlength="20"
|
|
@@ -144,6 +152,7 @@
|
|
|
<!--最晚到货日期-->
|
|
|
<ws-form-item label="最晚到货日期" span="1" prop="deliveryDateEnd">
|
|
|
<ws-input
|
|
|
+ :disabled="disabled"
|
|
|
v-model="deptBudgetList.deliveryDateEnd"
|
|
|
placeholder="请输入仓库名"
|
|
|
maxlength="20"
|
|
@@ -153,6 +162,7 @@
|
|
|
<!--合同编号-->
|
|
|
<ws-form-item label="合同编号" span="1" prop="contractNo">
|
|
|
<ws-input
|
|
|
+ :disabled="disabled"
|
|
|
v-model="deptBudgetList.contractNo"
|
|
|
placeholder="请输入合同编号"
|
|
|
maxlength="20"
|
|
@@ -163,72 +173,71 @@
|
|
|
<div class="small-title">派车</div>
|
|
|
<div
|
|
|
style="width: 100%"
|
|
|
- class="flex position"
|
|
|
- v-for="(item, index) in freightspace"
|
|
|
+ class="driver"
|
|
|
+ v-for="(item, index) in deptBudgetList.tranCarInfoList"
|
|
|
>
|
|
|
<ws-info-table>
|
|
|
+ <span class="not" v-if="item.statusFlag == 3">{{ item.status }}</span>
|
|
|
+ <span class="already" v-if="item.statusFlag == 1">{{
|
|
|
+ item.status
|
|
|
+ }}</span>
|
|
|
<!--姓名-->
|
|
|
<ws-form-item label="姓名" span="1" prop="driver">
|
|
|
<ws-input
|
|
|
- v-model="deptBudgetList.driver"
|
|
|
+ :disabled="disabled"
|
|
|
+ v-model="item.driver"
|
|
|
placeholder="请输入姓名"
|
|
|
maxlength="20"
|
|
|
size="small"
|
|
|
/>
|
|
|
</ws-form-item>
|
|
|
- <!--电话-->
|
|
|
- <ws-form-item label="电话" span="1" prop="driverPhone">
|
|
|
+ <ws-form-item class="phone" label="电话" span="1" prop="driverPhone">
|
|
|
<ws-input
|
|
|
- v-model="deptBudgetList.driverPhone"
|
|
|
+ :disabled="disabled"
|
|
|
+ v-model="item.driverPhone"
|
|
|
placeholder="请输入电话"
|
|
|
maxlength="20"
|
|
|
size="small"
|
|
|
/>
|
|
|
</ws-form-item>
|
|
|
- <!--发车日期-->
|
|
|
- <ws-form-item label="发车日期" span="1" prop="sendDateStart">
|
|
|
+ <ws-form-item label="车牌号" span="1" prop="carNo">
|
|
|
<ws-input
|
|
|
- v-model="deptBudgetList.sendDateStart"
|
|
|
- placeholder="请输入发车日期"
|
|
|
+ :disabled="disabled"
|
|
|
+ v-model="item.carNo"
|
|
|
+ placeholder="请输入车牌号"
|
|
|
maxlength="20"
|
|
|
size="small"
|
|
|
/>
|
|
|
</ws-form-item>
|
|
|
- <!--到站日期-->
|
|
|
- <ws-form-item label="到站日期" span="1" prop="receiveDateEnd">
|
|
|
+ <ws-form-item label="装车(吨)" span="1" prop="loadNetWeight">
|
|
|
<ws-input
|
|
|
- v-model="deptBudgetList.receiveDateEnd"
|
|
|
- placeholder="请输入到站日期"
|
|
|
+ :disabled="disabled"
|
|
|
+ v-model="deptBudgetList.loadNetWeight"
|
|
|
+ placeholder="未装车"
|
|
|
maxlength="20"
|
|
|
size="small"
|
|
|
/>
|
|
|
</ws-form-item>
|
|
|
- <!--车次-->
|
|
|
- <ws-form-item label="车次" span="1" prop="trainNo">
|
|
|
+ <ws-form-item label="卸车(吨)" span="1" prop="unloadNetWeight">
|
|
|
<ws-input
|
|
|
- v-model="deptBudgetList.trainNo"
|
|
|
- placeholder="请输入车次"
|
|
|
+ :disabled="disabled"
|
|
|
+ v-model="item.unloadNetWeight"
|
|
|
+ placeholder="未卸车"
|
|
|
maxlength="20"
|
|
|
size="small"
|
|
|
/>
|
|
|
</ws-form-item>
|
|
|
- <!-- 加减号 -->
|
|
|
- <img
|
|
|
- width="22"
|
|
|
- height="22"
|
|
|
- class="add"
|
|
|
- @click="add"
|
|
|
- src="../../../public/img/add.png"
|
|
|
- alt=""
|
|
|
- />
|
|
|
- <img
|
|
|
- width="22"
|
|
|
- height="22"
|
|
|
- class="del"
|
|
|
- @click="del(index)"
|
|
|
- src="../../../public/img/del.png"
|
|
|
- alt=""
|
|
|
- />
|
|
|
+ <ws-form-item label="损耗(吨)" span="1" prop="loss">
|
|
|
+ <ws-input
|
|
|
+ :disabled="disabled"
|
|
|
+ v-model="item.loss"
|
|
|
+ placeholder="未损耗"
|
|
|
+ maxlength="20"
|
|
|
+ size="small"
|
|
|
+ />
|
|
|
+ </ws-form-item>
|
|
|
+ <ws-form-item label="合同" span="1" prop="unloadNetWeight">
|
|
|
+ </ws-form-item>
|
|
|
</ws-info-table>
|
|
|
</div>
|
|
|
</ws-form>
|
|
@@ -237,8 +246,8 @@
|
|
|
class="bg-bottom-up"
|
|
|
type="primary"
|
|
|
size="small"
|
|
|
- @click="submit()"
|
|
|
- >提交</el-button
|
|
|
+ @click="revert()"
|
|
|
+ >关闭</el-button
|
|
|
>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -277,6 +286,7 @@ export default {
|
|
|
showType: true,
|
|
|
// 年
|
|
|
year: '',
|
|
|
+ disabled: true,
|
|
|
deptBudgetTotal: 0,
|
|
|
currentPage: 1,
|
|
|
pageSize: 10,
|
|
@@ -343,200 +353,24 @@ export default {
|
|
|
seeCat({ id: this.$route.query.id })
|
|
|
.toPromise()
|
|
|
.then((response) => {
|
|
|
- this.deptBudgetList = response
|
|
|
- })
|
|
|
- },
|
|
|
- //提交按钮
|
|
|
- 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.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
|
|
|
- }
|
|
|
- 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' })
|
|
|
- })
|
|
|
+ for (var i = 0; i < response.tranCarInfoList.length; i++) {
|
|
|
+ if (
|
|
|
+ response.tranCarInfoList[i].loadNetWeight &&
|
|
|
+ response.tranCarInfoList[i].unloadNetWeight
|
|
|
+ ) {
|
|
|
+ response.tranCarInfoList[i].loss =
|
|
|
+ response.tranCarInfoList[i].loadNetWeight -
|
|
|
+ response.tranCarInfoList[i].unloadNetWeight
|
|
|
+ } else if (response.tranCarInfoList[i].loadNetWeight) {
|
|
|
+ response.tranCarInfoList[i].loss =
|
|
|
+ response.tranCarInfoList[i].loadNetWeight
|
|
|
} else {
|
|
|
- EventBus.$emit('error', this.$t('showMessage.asteriskRequired'))
|
|
|
- return false
|
|
|
+ response.tranCarInfoList[i].loss = 0
|
|
|
}
|
|
|
- })
|
|
|
- })
|
|
|
- .catch(() => {
|
|
|
- return false
|
|
|
+ }
|
|
|
+ this.deptBudgetList = response
|
|
|
})
|
|
|
},
|
|
|
- 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
|
|
|
- }
|
|
|
- }
|
|
|
- },
|
|
|
- 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',
|
|
@@ -647,23 +481,13 @@ export default {
|
|
|
display: inline-grid;
|
|
|
padding: 2px 4px;
|
|
|
}
|
|
|
-// .position {
|
|
|
-// width: 52px;
|
|
|
-// height: 20px;
|
|
|
-// background: #afb5cb;
|
|
|
-// border-radius: 2px;
|
|
|
-// font-size: 12px;
|
|
|
-// font-family: PingFangSC-Medium, PingFang SC;
|
|
|
-// color: #ffffff;
|
|
|
-// line-height: 20px;
|
|
|
-// }
|
|
|
//表格文字
|
|
|
/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;
|
|
|
+ color: #000;
|
|
|
line-height: 16px;
|
|
|
}
|
|
|
.small-title {
|
|
@@ -691,10 +515,6 @@ export default {
|
|
|
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%;
|
|
@@ -726,4 +546,23 @@ export default {
|
|
|
border-left: 0px;
|
|
|
border-top: 0px;
|
|
|
}
|
|
|
+.driver {
|
|
|
+ position: relative;
|
|
|
+}
|
|
|
+.not,
|
|
|
+.already {
|
|
|
+ position: absolute;
|
|
|
+ left: -45px;
|
|
|
+ top: 10px;
|
|
|
+}
|
|
|
+
|
|
|
+/deep/.driver .ws-info-table .el-form-item {
|
|
|
+ width: 14%;
|
|
|
+}
|
|
|
+/deep/.driver .ws-info-table .el-form-item .el-form-item__label {
|
|
|
+ width: 86px;
|
|
|
+}
|
|
|
+/deep/.driver .ws-info-table .el-form-item.phone .el-form-item__label {
|
|
|
+ width: 50px;
|
|
|
+}
|
|
|
</style>
|