|
@@ -135,28 +135,30 @@
|
|
|
</a-col>
|
|
|
<a-col :sm="20" >
|
|
|
<a-form-item
|
|
|
- label="需求日期"
|
|
|
+ label="计划到货日期"
|
|
|
:labelCol="BaseTool.Constant.labelCol"
|
|
|
:wrapperCol="BaseTool.Constant.wrapperCol"
|
|
|
>
|
|
|
<a-date-picker
|
|
|
style="width: 100%"
|
|
|
:disabled-date="disabledDate"
|
|
|
+ @change="dateChange"
|
|
|
:format="BaseTool.Date.PICKER_NORM_DATE_PATTERN"
|
|
|
- v-decorator="['needDate', {rules: [{required: true, message: '需求日期不能为空'}]}]" />
|
|
|
+ v-decorator="['planGetDate', {rules: [{required: true, message: '计划到货日期不能为空'}]}]" />
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
<a-col :sm="20" >
|
|
|
<a-form-item
|
|
|
- label="计划到货日期"
|
|
|
+ label="需求日期"
|
|
|
:labelCol="BaseTool.Constant.labelCol"
|
|
|
:wrapperCol="BaseTool.Constant.wrapperCol"
|
|
|
>
|
|
|
<a-date-picker
|
|
|
+ :disabled="!date"
|
|
|
style="width: 100%"
|
|
|
- :disabled-date="disabledDate"
|
|
|
+ :disabled-date="disabledDate2"
|
|
|
:format="BaseTool.Date.PICKER_NORM_DATE_PATTERN"
|
|
|
- v-decorator="['planGetDate', {rules: [{required: true, message: '计划到货日期不能为空'}]}]" />
|
|
|
+ v-decorator="['needDate', {rules: [{required: true, message: '需求日期不能为空'}]}]" />
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
<a-col :sm="20" >
|
|
@@ -306,6 +308,7 @@ export default {
|
|
|
infoNum: 0,
|
|
|
cptcodeMap: {},
|
|
|
deptMap: {},
|
|
|
+ date: false,
|
|
|
cbustypeMap: {},
|
|
|
confirmLoading: false
|
|
|
}
|
|
@@ -324,6 +327,14 @@ export default {
|
|
|
// Can not select days before today and today
|
|
|
return current && current < moment().endOf('day')
|
|
|
},
|
|
|
+ disabledDate2 (current) {
|
|
|
+ // Can not select days before today and today
|
|
|
+ return current && current <= this.date
|
|
|
+ },
|
|
|
+ dateChange (data) {
|
|
|
+ console.log(data)
|
|
|
+ this.date = data
|
|
|
+ },
|
|
|
base (record) {
|
|
|
this.visible = true
|
|
|
if (this.BaseTool.Object.isBlank(record)) {
|
|
@@ -448,6 +459,7 @@ export default {
|
|
|
this.visible = false
|
|
|
this.current = 0
|
|
|
this.data = []
|
|
|
+ this.date = null
|
|
|
this.params = {}
|
|
|
this.form.resetFields()
|
|
|
this.sbIds = []
|