|
|
@ -105,7 +105,9 @@ |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
|
<a v-if="scope.row.authorizeFlag == 'N'" @click="initAddModel(scope.row)">{{ buttons.edit }}</a> |
|
|
<a v-if="scope.row.authorizeFlag == 'N'" @click="initAddModel(scope.row)">{{ buttons.edit }}</a> |
|
|
<a v-if="scope.row.authorizeFlag == 'N'" @click="updateAuthorizeFlag(scope.row)">{{ buttons.close }}</a> |
|
|
<a v-if="scope.row.authorizeFlag == 'N'" @click="updateAuthorizeFlag(scope.row)">{{ buttons.close }}</a> |
|
|
<a v-if="scope.row.authorizeFlag == 'Y' && scope.row.approvedFlag != 'Y' && scope.row.approveresult == '审批未通过'"@click="initReapply(scope.row)">{{buttons.reapply}}</a> |
|
|
|
|
|
|
|
|
<a |
|
|
|
|
|
v-if="scope.row.authorizeFlag == 'Y' && scope.row.approvedFlag != 'Y' && scope.row.approveresult == '审批未通过'" |
|
|
|
|
|
@click="initReapply(scope.row)">{{ buttons.reapply }}</a> |
|
|
<a @click="initReviewDetails(scope.row.requisitionno)">{{ buttons.reviewDetails }}</a> |
|
|
<a @click="initReviewDetails(scope.row.requisitionno)">{{ buttons.reviewDetails }}</a> |
|
|
</template> |
|
|
</template> |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
@ -198,24 +200,27 @@ |
|
|
</el-select> |
|
|
</el-select> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item :label="inputSearch6"> |
|
|
<el-form-item :label="inputSearch6"> |
|
|
<el-input style="text-align: left;width: 143px" onkeyup="this.value = this.value.toUpperCase()" v-model="currentPRDetailData.partno"></el-input> |
|
|
|
|
|
|
|
|
<el-input style="text-align: left;width: 143px" onkeyup="this.value = this.value.toUpperCase()" |
|
|
|
|
|
v-model="currentPRDetailData.partno"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item :label="inputSearch11"> |
|
|
<el-form-item :label="inputSearch11"> |
|
|
<el-input style="text-align: left;width: 143px" v-model="currentPRDetailData.partdesc"></el-input> |
|
|
<el-input style="text-align: left;width: 143px" v-model="currentPRDetailData.partdesc"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item :label="inputSearch7"> |
|
|
<el-form-item :label="inputSearch7"> |
|
|
<el-input style="text-align: left;width: 143px" @change="getNumber()" oninput="value=value.replace(/^\.+|[^\d.]/g,'')" |
|
|
|
|
|
|
|
|
<el-input style="text-align: left;width: 143px" @change="getNumber()" |
|
|
|
|
|
oninput="value=value.replace(/^\.+|[^\d.]/g,'')" |
|
|
v-model="currentPRDetailData.qty"></el-input> |
|
|
v-model="currentPRDetailData.qty"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item :label="inputSearch8"> |
|
|
<el-form-item :label="inputSearch8"> |
|
|
<el-input style="text-align: left;width: 143px" v-model="currentPRDetailData.price" @change="getNumber()" oninput="value=value.replace(/^\.+|[^\d.]/g,'')"></el-input> |
|
|
|
|
|
|
|
|
<el-input style="text-align: left;width: 143px" v-model="currentPRDetailData.price" @change="getNumber()" |
|
|
|
|
|
oninput="value=value.replace(/^\.+|[^\d.]/g,'')"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item :label="inputSearch9"> |
|
|
<el-form-item :label="inputSearch9"> |
|
|
<el-input style="text-align: left;width: 143px" |
|
|
<el-input style="text-align: left;width: 143px" |
|
|
v-model="currentPRDetailData.totalPrice" |
|
|
v-model="currentPRDetailData.totalPrice" |
|
|
:disabled="true"></el-input> |
|
|
:disabled="true"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<!--<el-form-item style="margin-top: 10px"> |
|
|
|
|
|
|
|
|
<el-form-item style="margin-top: 10px"> |
|
|
<upload v-on:childByValue="childByValue"></upload> |
|
|
<upload v-on:childByValue="childByValue"></upload> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-table |
|
|
<el-table |
|
|
@ -251,7 +256,7 @@ |
|
|
<a @click="fileDownload(scope.row)">{{ buttons.fileDownload }}</a> |
|
|
<a @click="fileDownload(scope.row)">{{ buttons.fileDownload }}</a> |
|
|
</template> |
|
|
</template> |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
</el-table>--> |
|
|
|
|
|
|
|
|
</el-table> |
|
|
</el-form> |
|
|
</el-form> |
|
|
<span slot="footer" class="dialog-footer"> |
|
|
<span slot="footer" class="dialog-footer"> |
|
|
<el-button @click="addPRDetailFlag = false">取消</el-button> |
|
|
<el-button @click="addPRDetailFlag = false">取消</el-button> |
|
|
@ -321,6 +326,7 @@ |
|
|
downFtpFile, |
|
|
downFtpFile, |
|
|
} from '@/api/purchaseorder/purchaseRequisition.js' |
|
|
} from '@/api/purchaseorder/purchaseRequisition.js' |
|
|
import upload from "../common/upload"; |
|
|
import upload from "../common/upload"; |
|
|
|
|
|
|
|
|
export default { |
|
|
export default { |
|
|
components: {upload}, |
|
|
components: {upload}, |
|
|
data() { |
|
|
data() { |
|
|
@ -993,12 +999,30 @@ |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
methods: { |
|
|
methods: { |
|
|
|
|
|
// 文件下载 |
|
|
fileDownload(row) { |
|
|
fileDownload(row) { |
|
|
let downLoadData = { |
|
|
|
|
|
id : row.id |
|
|
|
|
|
|
|
|
this.$http({ |
|
|
|
|
|
url: this.$http.adornUrl('ftp/file/downFtpFile'), |
|
|
|
|
|
method: 'post', |
|
|
|
|
|
data: JSON.stringify(row), |
|
|
|
|
|
responseType: 'blob', |
|
|
|
|
|
headers: { |
|
|
|
|
|
'Content-Type': 'application/json' |
|
|
} |
|
|
} |
|
|
downFtpFile(downLoadData).then(({data}) =>{ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}).then(({data}) => { |
|
|
|
|
|
// 不限制文件下载类型 |
|
|
|
|
|
const blob = new Blob([data], {type: "application/octet-stream"}) |
|
|
|
|
|
// 下载文件名称 |
|
|
|
|
|
const fileName = row.fileName |
|
|
|
|
|
// a标签下载 |
|
|
|
|
|
const linkNode = document.createElement('a') |
|
|
|
|
|
linkNode.download = fileName // a标签的download属性规定下载文件的名称 |
|
|
|
|
|
linkNode.style.display = 'none' |
|
|
|
|
|
linkNode.href = URL.createObjectURL(blob) // 生成一个Blob URL |
|
|
|
|
|
document.body.appendChild(linkNode) |
|
|
|
|
|
linkNode.click() // 模拟在按钮上的一次鼠标单击 |
|
|
|
|
|
URL.revokeObjectURL(linkNode.href) // 释放URL 对象 |
|
|
|
|
|
document.body.removeChild(linkNode) |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
childByValue(childValue) { |
|
|
childByValue(childValue) { |
|
|
|