Commit ae00d062 authored by 季圣华's avatar 季圣华
Browse files

给商品增加图片上传功能,单据增加附件,优化付款收款单

parent 9af01678
......@@ -171,7 +171,7 @@ export function getFileAccessHttpUrl(avatar,subStr) {
return avatar;
}else{
if(avatar && avatar.length>0 && avatar.indexOf('[')==-1){
return window._CONFIG['staticDomainURL'] + "/" + avatar;
return window._CONFIG['domianURL'] + "/" + avatar;
}
}
}
......@@ -43,7 +43,7 @@
name: 'JImageUpload',
data(){
return {
uploadAction:window._CONFIG['domianURL']+"/sys/common/upload",
uploadAction:window._CONFIG['domianURL']+"/systemConfig/upload",
uploadLoading:false,
picUrl:false,
headers:{},
......@@ -96,21 +96,22 @@
initFileList(paths){
if(!paths || paths.length==0){
this.fileList = [];
this.picUrl = false;
return;
}
this.picUrl = true;
let fileList = [];
let arr = paths.split(",")
for(var a=0;a<arr.length;a++){
let url = getFileAccessHttpUrl(arr[a]);
let url = getFileAccessHttpUrl('systemConfig/static/' + arr[a]);
fileList.push({
uid: uidGenerator(),
name: getFileName(arr[a]),
status: 'done',
url: url,
response:{
status:"history",
message:arr[a]
code:"history",
data:arr[a]
}
})
}
......@@ -127,11 +128,11 @@
this.picUrl = false;
let fileList = info.fileList
if(info.file.status==='done'){
if(info.file.response.success){
if(info.file.response.code === 200){
this.picUrl = true;
fileList = fileList.map((file) => {
if (file.response) {
file.url = file.response.message;
file.url = file.response.data;
}
return file;
});
......@@ -155,7 +156,7 @@
getAvatarView(){
if(this.fileList.length>0){
let url = this.fileList[0].url
return getFileAccessHttpUrl(url)
return url
}
},
handlePathChange(){
......@@ -166,10 +167,10 @@
}
let arr = [];
if(!this.isMultiple){
arr.push(uploadFiles[uploadFiles.length-1].response.message)
arr.push(uploadFiles[uploadFiles.length-1].response.data)
}else{
for(var a=0;a<uploadFiles.length;a++){
arr.push(uploadFiles[a].response.message)
arr.push(uploadFiles[a].response.data)
}
}
if(arr.length>0){
......
......@@ -247,7 +247,6 @@
},
handleChange(info) {
console.log("--文件列表改变--")
debugger
if(!info.file.status && this.uploadGoOn === false){
info.fileList.pop();
}
......
......@@ -795,6 +795,20 @@
</a-row>
</section>
</template>
<template v-if="fileList.length>0">
<a-row class="form-row" :gutter="24">
<a-col :span="8">
<a-form-item :labelCol="{xs: { span: 24 },sm: { span: 4 }}" :wrapperCol="{xs: { span: 24 },sm: { span: 20 }}" label="附件">
<ul style="list-style-type:none">
<li v-for="(item,index) in fileList" :key="index">
<a :href="item.url" target="_blank">{{item.name}}</a>
</li>
</ul>
</a-form-item>
</a-col>
<a-col :span="16"></a-col>
</a-row>
</template>
</a-form>
</j-modal>
</a-card>
......@@ -814,6 +828,7 @@
visible: false,
model: {},
billType: '',
fileList: [],
labelCol: {
xs: { span: 24 },
sm: { span: 5 },
......@@ -1036,6 +1051,20 @@
methods: {
show(record, type) {
this.billType = type
//附件下载
let fileName = record.fileName
if(fileName) {
let fileArr = fileName.split(",")
this.fileList = []
for(let i=0; i<fileArr.length; i++) {
let fileInfo = {}
fileInfo.name= fileArr[i].replace("bill/","")
fileInfo.url= window._CONFIG['domianURL'] + '/systemConfig/static/' + fileArr[i]
this.fileList.push(fileInfo)
}
} else {
this.fileList = []
}
this.visible = true;
this.model = Object.assign({}, record);
this.model.debt = (this.model.discountLastMoney + this.model.otherMoney - this.model.changeAmount).toFixed(2)
......
......@@ -47,6 +47,13 @@
</a-form-item>
</a-col>
</a-row>
<a-row class="form-row" :gutter="24">
<a-col :lg="6" :md="12" :sm="24">
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="附件">
<j-upload v-model="fileList" bizPath="bill"></j-upload>
</a-form-item>
</a-col>
</a-row>
</a-form>
</a-spin>
</j-modal>
......@@ -57,12 +64,14 @@
import { JEditableTableMixin } from '@/mixins/JEditableTableMixin'
import { BillModalMixin } from '../mixins/BillModalMixin'
import { getMpListShort } from "@/utils/util"
import JUpload from '@/components/jeecg/JUpload'
import JDate from '@/components/jeecg/JDate'
import Vue from 'vue'
export default {
name: "AllocationOutModal",
mixins: [JEditableTableMixin, BillModalMixin],
components: {
JUpload,
JDate
},
data () {
......@@ -75,6 +84,7 @@
visible: false,
operTimeStr: '',
prefixNo: 'DBCK',
fileList:[],
model: {},
labelCol: {
xs: { span: 24 },
......@@ -138,8 +148,10 @@
editAfter() {
if (this.action === 'add') {
this.addInit(this.prefixNo)
this.fileList = []
} else {
this.model.operTime = this.model.operTimeStr
this.fileList = this.model.fileName
this.$nextTick(() => {
this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'remark',
'discount','discountMoney','discountLastMoney','otherMoney','accountId','changeAmount'))
......@@ -165,6 +177,9 @@
totalPrice += item.allPrice-0
}
billMain.totalPrice = totalPrice
if(this.fileList && this.fileList.length > 0) {
billMain.fileName = this.fileList
}
if(this.model.id){
billMain.id = this.model.id
}
......
......@@ -47,6 +47,13 @@
</a-form-item>
</a-col>
</a-row>
<a-row class="form-row" :gutter="24">
<a-col :lg="6" :md="12" :sm="24">
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="附件">
<j-upload v-model="fileList" bizPath="bill"></j-upload>
</a-form-item>
</a-col>
</a-row>
</a-form>
</a-spin>
</j-modal>
......@@ -58,12 +65,14 @@
import { BillModalMixin } from '../mixins/BillModalMixin'
import { getAction } from '@/api/manage'
import { getMpListShort } from "@/utils/util"
import JUpload from '@/components/jeecg/JUpload'
import JDate from '@/components/jeecg/JDate'
import Vue from 'vue'
export default {
name: "AssembleModal",
mixins: [JEditableTableMixin, BillModalMixin],
components: {
JUpload,
JDate
},
data () {
......@@ -76,6 +85,7 @@
visible: false,
operTimeStr: '',
prefixNo: 'ZZD',
fileList:[],
model: {},
labelCol: {
xs: { span: 24 },
......@@ -139,9 +149,11 @@
editAfter() {
if (this.action === 'add') {
this.addInit(this.prefixNo)
this.fileList = []
} else {
this.model.operTime = this.model.operTimeStr
this.model.debt = (this.model.discountLastMoney - this.model.changeAmount).toFixed(2)
this.fileList = this.model.fileName
this.$nextTick(() => {
this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'remark',
'discount','discountMoney','discountLastMoney','otherMoney','accountId','changeAmount','debt'))
......@@ -167,6 +179,9 @@
totalPrice += item.allPrice-0
}
billMain.totalPrice = totalPrice
if(this.fileList && this.fileList.length > 0) {
billMain.fileName = this.fileList
}
if(this.model.id){
billMain.id = this.model.id
}
......
......@@ -47,6 +47,13 @@
</a-form-item>
</a-col>
</a-row>
<a-row class="form-row" :gutter="24">
<a-col :lg="6" :md="12" :sm="24">
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="附件">
<j-upload v-model="fileList" bizPath="bill"></j-upload>
</a-form-item>
</a-col>
</a-row>
</a-form>
</a-spin>
</j-modal>
......@@ -58,12 +65,14 @@
import { BillModalMixin } from '../mixins/BillModalMixin'
import { getAction } from '@/api/manage'
import { getMpListShort } from "@/utils/util"
import JUpload from '@/components/jeecg/JUpload'
import JDate from '@/components/jeecg/JDate'
import Vue from 'vue'
export default {
name: "DisassembleModal",
mixins: [JEditableTableMixin, BillModalMixin],
components: {
JUpload,
JDate
},
data () {
......@@ -76,6 +85,7 @@
visible: false,
operTimeStr: '',
prefixNo: 'CXD',
fileList:[],
model: {},
labelCol: {
xs: { span: 24 },
......@@ -139,8 +149,10 @@
editAfter() {
if (this.action === 'add') {
this.addInit(this.prefixNo)
this.fileList = []
} else {
this.model.operTime = this.model.operTimeStr
this.fileList = this.model.fileName
this.$nextTick(() => {
this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'remark',
'discount','discountMoney','discountLastMoney','otherMoney','accountId','changeAmount'))
......@@ -166,6 +178,9 @@
totalPrice += item.allPrice-0
}
billMain.totalPrice = totalPrice
if(this.fileList && this.fileList.length > 0) {
billMain.fileName = this.fileList
}
if(this.model.id){
billMain.id = this.model.id
}
......
......@@ -55,6 +55,13 @@
</a-form-item>
</a-col>
</a-row>
<a-row class="form-row" :gutter="24">
<a-col :lg="6" :md="12" :sm="24">
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="附件">
<j-upload v-model="fileList" bizPath="bill"></j-upload>
</a-form-item>
</a-col>
</a-row>
</a-form>
</a-spin>
</j-modal>
......@@ -65,12 +72,14 @@
import { JEditableTableMixin } from '@/mixins/JEditableTableMixin'
import { BillModalMixin } from '../mixins/BillModalMixin'
import { getMpListShort } from "@/utils/util"
import JUpload from '@/components/jeecg/JUpload'
import JDate from '@/components/jeecg/JDate'
import Vue from 'vue'
export default {
name: "OtherInModal",
mixins: [JEditableTableMixin, BillModalMixin],
components: {
JUpload,
JDate
},
data () {
......@@ -83,6 +92,7 @@
visible: false,
operTimeStr: '',
prefixNo: 'QTRK',
fileList:[],
model: {},
labelCol: {
xs: { span: 24 },
......@@ -145,8 +155,10 @@
editAfter() {
if (this.action === 'add') {
this.addInit(this.prefixNo)
this.fileList = []
} else {
this.model.operTime = this.model.operTimeStr
this.fileList = this.model.fileName
this.$nextTick(() => {
this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'remark',
'discount','discountMoney','discountLastMoney','otherMoney','accountId','changeAmount'))
......@@ -172,6 +184,9 @@
totalPrice += item.allPrice-0
}
billMain.totalPrice = totalPrice
if(this.fileList && this.fileList.length > 0) {
billMain.fileName = this.fileList
}
if(this.model.id){
billMain.id = this.model.id
}
......
......@@ -55,6 +55,13 @@
</a-form-item>
</a-col>
</a-row>
<a-row class="form-row" :gutter="24">
<a-col :lg="6" :md="12" :sm="24">
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="附件">
<j-upload v-model="fileList" bizPath="bill"></j-upload>
</a-form-item>
</a-col>
</a-row>
</a-form>
</a-spin>
</j-modal>
......@@ -65,12 +72,14 @@
import { JEditableTableMixin } from '@/mixins/JEditableTableMixin'
import { BillModalMixin } from '../mixins/BillModalMixin'
import { getMpListShort } from "@/utils/util"
import JUpload from '@/components/jeecg/JUpload'
import JDate from '@/components/jeecg/JDate'
import Vue from 'vue'
export default {
name: "OtherOutModal",
mixins: [JEditableTableMixin, BillModalMixin],
components: {
JUpload,
JDate
},
data () {
......@@ -83,6 +92,7 @@
visible: false,
operTimeStr: '',
prefixNo: 'QTCK',
fileList:[],
model: {},
labelCol: {
xs: { span: 24 },
......@@ -145,8 +155,10 @@
editAfter() {
if (this.action === 'add') {
this.addInit(this.prefixNo)
this.fileList = []
} else {
this.model.operTime = this.model.operTimeStr
this.fileList = this.model.fileName
this.$nextTick(() => {
this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'remark',
'discount','discountMoney','discountLastMoney','otherMoney','accountId','changeAmount'))
......@@ -172,6 +184,9 @@
totalPrice += item.allPrice-0
}
billMain.totalPrice = totalPrice
if(this.fileList && this.fileList.length > 0) {
billMain.fileName = this.fileList
}
if(this.model.id){
billMain.id = this.model.id
}
......
......@@ -109,6 +109,13 @@
<a-col :lg="6" :md="12" :sm="24">
</a-col>
</a-row>
<a-row class="form-row" :gutter="24">
<a-col :lg="6" :md="12" :sm="24">
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="附件">
<j-upload v-model="fileList" bizPath="bill"></j-upload>
</a-form-item>
</a-col>
</a-row>
</a-form>
</a-spin>
</j-modal>
......@@ -125,6 +132,7 @@
import { BillModalMixin } from '../mixins/BillModalMixin'
import { getMpListShort, changeListFmtMinus} from "@/utils/util"
import { getAction } from '@/api/manage'
import JUpload from '@/components/jeecg/JUpload'
import JDate from '@/components/jeecg/JDate'
import Vue from 'vue'
export default {
......@@ -133,6 +141,7 @@
components: {
ManyAccountModal,
LinkBillList,
JUpload,
JDate
},
data () {
......@@ -145,6 +154,7 @@
visible: false,
operTimeStr: '',
prefixNo: 'CGTH',
fileList:[],
model: {},
labelCol: {
xs: { span: 24 },
......@@ -216,6 +226,7 @@
editAfter() {
if (this.action === 'add') {
this.addInit(this.prefixNo)
this.fileList = []
} else {
this.model.operTime = this.model.operTimeStr
this.model.debt = (this.model.discountLastMoney + this.model.otherMoney - this.model.changeAmount).toFixed(2)
......@@ -227,6 +238,7 @@
} else {
this.manyAccountBtnStatus = false
}
this.fileList = this.model.fileName
this.$nextTick(() => {
this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'linkNumber', 'remark',
'discount','discountMoney','discountLastMoney','otherMoney','accountId','changeAmount','debt'))
......@@ -252,6 +264,9 @@
totalPrice += item.allPrice-0
}
billMain.totalPrice = totalPrice
if(this.fileList && this.fileList.length > 0) {
billMain.fileName = this.fileList
}
if(this.model.id){
billMain.id = this.model.id
}
......
......@@ -109,6 +109,13 @@
<a-col :lg="6" :md="12" :sm="24">
</a-col>
</a-row>
<a-row class="form-row" :gutter="24">
<a-col :lg="6" :md="12" :sm="24">
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="附件">
<j-upload v-model="fileList" bizPath="bill"></j-upload>
</a-form-item>
</a-col>
</a-row>
</a-form>
</a-spin>
</j-modal>
......@@ -126,6 +133,7 @@
import { BillModalMixin } from '../mixins/BillModalMixin'
import { getMpListShort, changeListFmtMinus} from "@/utils/util"
import { getAction } from '@/api/manage'
import JUpload from '@/components/jeecg/JUpload'
import JDate from '@/components/jeecg/JDate'
import Vue from 'vue'
export default {
......@@ -134,6 +142,7 @@
components: {
ManyAccountModal,
LinkBillList,
JUpload,
JDate
},
data () {
......@@ -146,6 +155,7 @@
visible: false,
operTimeStr: '',
prefixNo: 'CGRK',
fileList:[],
model: {},
labelCol: {
xs: { span: 24 },
......@@ -216,8 +226,8 @@
//调用完edit()方法之后会自动调用此方法
editAfter() {
if (this.action === 'add') {
let that = this
this.addInit(this.prefixNo)
this.fileList = []
} else {
this.model.operTime = this.model.operTimeStr
this.model.debt = (this.model.discountLastMoney + this.model.otherMoney - this.model.changeAmount).toFixed(2)
......@@ -229,6 +239,7 @@
} else {
this.manyAccountBtnStatus = false
}
this.fileList = this.model.fileName
this.$nextTick(() => {
this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'linkNumber', 'remark',
'discount','discountMoney','discountLastMoney','otherMoney','accountId','changeAmount','debt'))
......@@ -260,6 +271,9 @@
}
billMain.accountIdList = this.accountIdList.length>0 ? JSON.stringify(this.accountIdList) : ""
billMain.accountMoneyList = this.accountMoneyList.length>0 ? JSON.stringify(this.accountMoneyList) : ""
if(this.fileList && this.fileList.length > 0) {
billMain.fileName = this.fileList
}
if(this.model.id){
billMain.id = this.model.id
}
......
......@@ -55,6 +55,13 @@
</a-form-item>
</a-col>
</a-row>
<a-row class="form-row" :gutter="24">
<a-col :lg="6" :md="12" :sm="24">
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="附件">
<j-upload v-model="fileList" bizPath="bill"></j-upload>
</a-form-item>
</a-col>
</a-row>
</a-form>
</a-spin>
</j-modal>
......@@ -65,12 +72,14 @@
import { JEditableTableMixin } from '@/mixins/JEditableTableMixin'
import { BillModalMixin } from '../mixins/BillModalMixin'
import { getMpListShort } from "@/utils/util"
import JUpload from '@/components/jeecg/JUpload'
import JDate from '@/components/jeecg/JDate'
import Vue from 'vue'
export default {
name: "PurchaseOrderModal",
mixins: [JEditableTableMixin,BillModalMixin],
components: {
JUpload,
JDate
},
data () {
......@@ -85,6 +94,7 @@
depotList: [],
operTimeStr: '',
prefixNo: 'CGDD',
fileList:[],
model: {},
labelCol: {
xs: { span: 24 },
......@@ -148,8 +158,10 @@
editAfter() {
if (this.action === 'add') {
this.addInit(this.prefixNo)
this.fileList = []
} else {
this.model.operTime = this.model.operTimeStr
this.fileList = this.model.fileName
this.$nextTick(() => {
this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'remark'))
});
......@@ -174,6 +186,9 @@
totalPrice += item.allPrice-0
}
billMain.totalPrice = 0-totalPrice
if(this.fileList && this.fileList.length > 0) {
billMain.fileName = this.fileList
}
if(this.model.id){
billMain.id = this.model.id
}
......
......@@ -93,6 +93,13 @@
</a-form-item>
</a-col>
</a-row>
<a-row class="form-row" :gutter="24">
<a-col :lg="6" :md="12" :sm="24">
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="附件">
<j-upload v-model="fileList" bizPath="bill"></j-upload>
</a-form-item>
</a-col>
</a-row>
</a-form>
</a-spin>
</j-modal>
......@@ -107,6 +114,7 @@
import { BillModalMixin } from '../mixins/BillModalMixin'
import { getMpListShort } from "@/utils/util"
import { getAction } from '@/api/manage'
import JUpload from '@/components/jeecg/JUpload'
import JDate from '@/components/jeecg/JDate'
import Vue from 'vue'
export default {
......@@ -114,6 +122,7 @@
mixins: [JEditableTableMixin, BillModalMixin],
components: {
LinkBillList,
JUpload,
JDate
},
data () {
......@@ -126,6 +135,7 @@
visible: false,
operTimeStr: '',
prefixNo: 'LSTH',
fileList:[],
model: {},
labelCol: {
xs: { span: 24 },
......@@ -188,10 +198,12 @@
editAfter() {
if (this.action === 'add') {
this.addInit(this.prefixNo)
this.fileList = []
} else {
this.model.operTime = this.model.operTimeStr
this.model.getAmount = this.model.changeAmount
this.model.backAmount = 0
this.fileList = this.model.fileName
this.$nextTick(() => {
this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'linkNumber', 'remark',
'discount','discountMoney','discountLastMoney','otherMoney','accountId','changeAmount','getAmount','backAmount'))
......@@ -218,6 +230,9 @@
}
billMain.totalPrice = 0-totalPrice
billMain.changeAmount = 0-billMain.changeAmount
if(this.fileList && this.fileList.length > 0) {
billMain.fileName = this.fileList
}
if(this.model.id){
billMain.id = this.model.id
}
......
......@@ -95,6 +95,13 @@
</a-form-item>
</a-col>
</a-row>
<a-row class="form-row" :gutter="24">
<a-col :lg="6" :md="12" :sm="24">
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="附件">
<j-upload v-model="fileList" bizPath="bill"></j-upload>
</a-form-item>
</a-col>
</a-row>
</a-form>
</a-spin>
</j-modal>
......@@ -105,12 +112,14 @@
import { JEditableTableMixin } from '@/mixins/JEditableTableMixin'
import { BillModalMixin } from '../mixins/BillModalMixin'
import { getMpListShort } from "@/utils/util"
import JUpload from '@/components/jeecg/JUpload'
import JDate from '@/components/jeecg/JDate'
import Vue from 'vue'
export default {
name: "RetailOutModal",
mixins: [JEditableTableMixin, BillModalMixin],
components: {
JUpload,
JDate
},
data () {
......@@ -123,6 +132,7 @@
visible: false,
operTimeStr: '',
prefixNo: 'LSCK',
fileList:[],
model: {},
labelCol: {
xs: { span: 24 },
......@@ -185,12 +195,14 @@
editAfter() {
if (this.action === 'add') {
this.addInit(this.prefixNo)
this.fileList = []
this.$nextTick(() => {
this.form.setFieldsValue({'payType': '现付'})
})
} else {
this.model.operTime = this.model.operTimeStr
this.model.getAmount = this.model.changeAmount
this.fileList = this.model.fileName
this.$nextTick(() => {
this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'payType', 'remark',
'discount','discountMoney','discountLastMoney','otherMoney','accountId','changeAmount','getAmount'))
......@@ -216,6 +228,9 @@
totalPrice += item.allPrice-0
}
billMain.totalPrice = totalPrice
if(this.fileList && this.fileList.length > 0) {
billMain.fileName = this.fileList
}
if(this.model.id){
billMain.id = this.model.id
}
......
......@@ -112,6 +112,13 @@
</a-form-item>
</a-col>
</a-row>
<a-row class="form-row" :gutter="24">
<a-col :lg="6" :md="12" :sm="24">
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="附件">
<j-upload v-model="fileList" bizPath="bill"></j-upload>
</a-form-item>
</a-col>
</a-row>
</a-form>
</a-spin>
</j-modal>
......@@ -129,6 +136,7 @@
import { getMpListShort, changeListFmtMinus } from "@/utils/util"
import { getAction } from '@/api/manage'
import JSelectMultiple from '@/components/jeecg/JSelectMultiple'
import JUpload from '@/components/jeecg/JUpload'
import JDate from '@/components/jeecg/JDate'
import Vue from 'vue'
export default {
......@@ -137,6 +145,7 @@
components: {
ManyAccountModal,
LinkBillList,
JUpload,
JDate,
JSelectMultiple
},
......@@ -150,6 +159,7 @@
visible: false,
operTimeStr: '',
prefixNo: 'XSTH',
fileList:[],
model: {},
labelCol: {
xs: { span: 24 },
......@@ -222,6 +232,7 @@
if (this.action === 'add') {
this.addInit(this.prefixNo)
this.personList.value = ''
this.fileList = []
} else {
this.model.operTime = this.model.operTimeStr
this.model.debt = (this.model.discountLastMoney + this.model.otherMoney - this.model.changeAmount).toFixed(2)
......@@ -234,6 +245,7 @@
this.manyAccountBtnStatus = false
}
this.personList.value = this.model.salesMan
this.fileList = this.model.fileName
this.$nextTick(() => {
this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'linkNumber', 'remark',
'discount','discountMoney','discountLastMoney','otherMoney','accountId','changeAmount','debt','salesMan'))
......@@ -265,6 +277,9 @@
}
billMain.accountIdList = this.accountIdList.length>0 ? JSON.stringify(this.accountIdList) : ""
billMain.accountMoneyList = this.accountMoneyList.length>0 ? JSON.stringify(this.accountMoneyList) : ""
if(this.fileList && this.fileList.length > 0) {
billMain.fileName = this.fileList
}
if(this.model.id){
billMain.id = this.model.id
}
......
......@@ -59,6 +59,13 @@
</a-form-item>
</a-col>
</a-row>
<a-row class="form-row" :gutter="24">
<a-col :lg="6" :md="12" :sm="24">
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="附件">
<j-upload v-model="fileList" bizPath="bill"></j-upload>
</a-form-item>
</a-col>
</a-row>
</a-form>
</a-spin>
</j-modal>
......@@ -70,12 +77,14 @@
import { BillModalMixin } from '../mixins/BillModalMixin'
import { getMpListShort } from "@/utils/util"
import JSelectMultiple from '@/components/jeecg/JSelectMultiple'
import JUpload from '@/components/jeecg/JUpload'
import JDate from '@/components/jeecg/JDate'
import Vue from 'vue'
export default {
name: "SaleOrderModal",
mixins: [JEditableTableMixin, BillModalMixin],
components: {
JUpload,
JDate,
JSelectMultiple
},
......@@ -89,6 +98,7 @@
visible: false,
operTimeStr: '',
prefixNo: 'XSDD',
fileList:[],
model: {},
labelCol: {
xs: { span: 24 },
......@@ -152,9 +162,11 @@
if (this.action === 'add') {
this.addInit(this.prefixNo)
this.personList.value = ''
this.fileList = []
} else {
this.model.operTime = this.model.operTimeStr
this.personList.value = this.model.salesMan
this.fileList = this.model.fileName
this.$nextTick(() => {
this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'remark',
'discount','discountMoney','discountLastMoney','otherMoney','accountId','changeAmount','salesMan'))
......@@ -180,6 +192,9 @@
totalPrice += item.allPrice-0
}
billMain.totalPrice = totalPrice
if(this.fileList && this.fileList.length > 0) {
billMain.fileName = this.fileList
}
if(this.model.id){
billMain.id = this.model.id
}
......
......@@ -112,6 +112,13 @@
</a-form-item>
</a-col>
</a-row>
<a-row class="form-row" :gutter="24">
<a-col :lg="6" :md="12" :sm="24">
<a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="附件">
<j-upload v-model="fileList" bizPath="bill"></j-upload>
</a-form-item>
</a-col>
</a-row>
</a-form>
</a-spin>
</j-modal>
......@@ -129,6 +136,7 @@
import { getMpListShort } from "@/utils/util"
import { getAction } from '@/api/manage'
import JSelectMultiple from '@/components/jeecg/JSelectMultiple'
import JUpload from '@/components/jeecg/JUpload'
import JDate from '@/components/jeecg/JDate'
import Vue from 'vue'
export default {
......@@ -137,6 +145,7 @@
components: {
ManyAccountModal,
LinkBillList,
JUpload,
JDate,
JSelectMultiple
},
......@@ -150,6 +159,7 @@
visible: false,
operTimeStr: '',
prefixNo: 'XSCK',
fileList:[],
model: {},
labelCol: {
xs: { span: 24 },
......@@ -222,6 +232,7 @@
if (this.action === 'add') {
this.addInit(this.prefixNo)
this.personList.value = ''
this.fileList = []
} else {
this.model.operTime = this.model.operTimeStr
this.model.debt = (this.model.discountLastMoney + this.model.otherMoney - this.model.changeAmount).toFixed(2)
......@@ -234,6 +245,7 @@
this.manyAccountBtnStatus = false
}
this.personList.value = this.model.salesMan
this.fileList = this.model.fileName
this.$nextTick(() => {
this.form.setFieldsValue(pick(this.model,'organId', 'operTime', 'number', 'linkNumber', 'remark',
'discount','discountMoney','discountLastMoney','otherMoney','accountId','changeAmount','debt','salesMan'))
......@@ -264,6 +276,9 @@
}
billMain.accountIdList = this.accountIdList.length>0 ? JSON.stringify(this.accountIdList) : ""
billMain.accountMoneyList = this.accountMoneyList.length>0 ? JSON.stringify(this.accountMoneyList) : ""
if(this.fileList && this.fileList.length > 0) {
billMain.fileName = this.fileList
}
if(this.model.id){
billMain.id = this.model.id
}
......
......@@ -123,7 +123,9 @@
{ title: '单据编号', dataIndex: 'billNo',width:160},
{ title: '操作员', dataIndex: 'userName',width:80},
{ title: '单据日期 ', dataIndex: 'billTimeStr',width:160},
{ title: '合计', dataIndex: 'totalPrice',width:80},
{ title: '合计金额', dataIndex: 'totalPrice',width:80},
{ title: '优惠金额', dataIndex: 'discountMoney',width:80},
{ title: '收款金额', dataIndex: 'changeAmount',width:80},
{ title: '备注', dataIndex: 'remark',width:200},
{
title: '操作',
......
......@@ -122,7 +122,7 @@
{ title: '单据编号', dataIndex: 'billNo',width:160},
{ title: '操作员', dataIndex: 'userName',width:80},
{ title: '单据日期 ', dataIndex: 'billTimeStr',width:160},
{ title: '合计', dataIndex: 'totalPrice',width:80},
{ title: '实付金额', dataIndex: 'changeAmount',width:80},
{ title: '备注', dataIndex: 'remark',width:200},
{
title: '操作',
......
......@@ -123,7 +123,7 @@
{ title: '单据编号', dataIndex: 'billNo',width:160},
{ title: '操作员', dataIndex: 'userName',width:80},
{ title: '单据日期 ', dataIndex: 'billTimeStr',width:160},
{ title: '合计', dataIndex: 'totalPrice',width:80},
{ title: '收入金额', dataIndex: 'changeAmount',width:80},
{ title: '备注', dataIndex: 'remark',width:200},
{
title: '操作',
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment