20200204创建外购计划,备料分配,外购备料请款界面修改

This commit is contained in:
liulujia@meswork.com
2020-02-05 08:49:01 +08:00
parent abc24b9120
commit a8f4599c8b
15 changed files with 570 additions and 232 deletions

View File

@@ -13,7 +13,19 @@
:label="item.label"
:value="item.value"/>
</el-select>
<span v-show="false" class="demonstration">时间段:</span>
<span v-show="true" class="demonstration">时间段:</span>
<el-date-picker
v-model="dateRange"
:picker-options="pickerOptions"
size="small"
type="daterange"
align="center"
style="width: 300px;margin: 3px 0"
value-format="yyyy-MM-dd"
format="yyyy-MM-dd"
range-separator=""
start-placeholder="开始日期"
end-placeholder="结束日期"/>
<el-date-picker
v-show="false"
v-model="startTime"
@@ -34,7 +46,7 @@
<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="total1=0;pageCurrent1=1;pageSize1=30;searchTable1()">查询</el-button>
</el-tooltip>
<el-button type="primary" size="small" icon="el-icon-circle-plus-outline" style="margin-left: 10px" @click="addTable1()">新增</el-button>
<el-button type="primary" size="small" icon="el-icon-circle-plus-outline" style="margin-left: 10px" @click="addTable1()">新增</el-button>
</el-row>
</el-card>
<el-card style="width: 58%;float: left">
@@ -252,6 +264,34 @@ export default {
name: '', // 发票交接单
data() {
return {
dateRange: '',
pickerOptions: {
shortcuts: [{
text: '上季度',
onClick(picker) {
const end = new Date()
const start = new Date()
start.setTime(end.getTime() - 3600 * 1000 * 24 * 30 * 3)
picker.$emit('pick', [start, end])
}
}, {
text: '过去半年',
onClick(picker) {
const end = new Date()
const start = new Date()
start.setTime(end.getTime() - 3600 * 1000 * 24 * 366 / 2)
picker.$emit('pick', [start, end])
}
}, {
text: '过去一年',
onClick(picker) {
const end = new Date()
const start = new Date()
start.setTime(end.getTime() - 3600 * 1000 * 24 * 365)
picker.$emit('pick', [start, end])
}
}]
},
gongyingshangValue: '',
gongyingshang: [],
startTime: '',
@@ -332,8 +372,9 @@ export default {
this.invoiceNum ? this.check1 = 1 : this.check1 = 0
this.supplierName0 ? this.check2 = 1 : this.check2 = 0
this.gongyingshangValue ? this.check3 = 1 : this.check3 = 0
this.startTime && this.endTime ? this.check4 = 1 : this.check4 = 0
searchInvoice(this.pageCurrent1, this.pageSize1, this.check1, this.invoiceNum, this.check2, this.supplierName0, this.check3, this.gongyingshangValue, this.check4, this.startTime, this.endTime).then(response => {
this.dateRange ? this.check4 = 1 : (this.check4 = 0, this.dateRange = '')
// this.startTime && this.endTime ? this.check4 = 1 : this.check4 = 0
searchInvoice(this.pageCurrent1, this.pageSize1, this.check1, this.invoiceNum, this.check2, this.supplierName0, this.check3, this.gongyingshangValue, this.check4, this.dateRange[0], this.dateRange[1]).then(response => {
for (let j = 0; j < response.data.rows.length; j++) {
response.data.rows[j].开票金额 = parseInt(response.data.rows[j].开票金额 * 100) / 100
if (response.data.rows[j].开票时间 !== null) {