|
@@ -26,17 +26,17 @@
|
|
|
</a-col> -->
|
|
|
<a-col :md="6" :sm="8">
|
|
|
<a-form-model-item label="名称" prop="name">
|
|
|
- <a-input placeholder="请输入名称" v-model="formState.name"/>
|
|
|
+ <a-input placeholder="请输入名称" v-model="formState.name" :disabled="editAll=='yes'"/>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
<a-col :md="6" :sm="8">
|
|
|
<a-form-model-item label="合计" prop="totalNum">
|
|
|
- <a-input placeholder="" v-model="formState.totalNum" disabled="false"/>
|
|
|
+ <a-input placeholder="" v-model="formState.totalNum" disabled="false" :disabled="editAll=='yes'"/>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
<a-col :md="12" :sm="8">
|
|
|
<a-form-model-item label="合计大写" >
|
|
|
- <a-input placeholder="请输入" v-model="formState.totalText" disabled="false"/>
|
|
|
+ <a-input placeholder="请输入" v-model="formState.totalText" disabled="false" :disabled="editAll=='yes'"/>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
|
|
@@ -44,17 +44,24 @@
|
|
|
<a-row :gutter="24">
|
|
|
<a-col :md="24" :sm="8">
|
|
|
<a-form-model-item label="备注" >
|
|
|
- <a-input placeholder="请输入" v-model="formState.remarks"/>
|
|
|
+ <a-input placeholder="请输入" v-model="formState.remarks" :disabled="editAll=='yes'"/>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
</a-row>
|
|
|
<a-row :gutter="24">
|
|
|
<a-col :md="24" :sm="8">
|
|
|
<a-form-model-item label="账户信息" class="nresume" style="height:100px !important">
|
|
|
- <a-input type="textarea" placeholder="请输入" v-model="formState.demo"/>
|
|
|
+ <a-input type="textarea" placeholder="请输入" v-model="formState.demo" :disabled="editAll=='yes'"/>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
</a-row>
|
|
|
+ <a-row :gutter="24">
|
|
|
+ <a-col :md="24" :sm="8">
|
|
|
+ <a-form-model-item label="附件" class="ff">
|
|
|
+ <j-upload v-model="annex" ></j-upload>
|
|
|
+ </a-form-model-item>
|
|
|
+ </a-col>
|
|
|
+ </a-row>
|
|
|
</a-form-model>
|
|
|
<!-- 主表单区域 -->
|
|
|
<!-- <a-form :model="form">
|
|
@@ -85,7 +92,7 @@
|
|
|
<!-- 子表单区域 -->
|
|
|
<a-tabs v-model="activeKey" @change="handleChangeTabs">
|
|
|
<a-tab-pane tab="搬运工对账单" :key="refKeys[0]" :forceRender="true">
|
|
|
- <a-button type="primary" @click="addList" style="margin-bottom: 1%;">增行</a-button>
|
|
|
+ <a-button type="primary" @click="addList" style="margin-bottom: 1%;" :disabled="editAll=='yes'">增行</a-button>
|
|
|
<a-form-model ref="formRef" >
|
|
|
<a-table
|
|
|
bordered
|
|
@@ -123,67 +130,68 @@
|
|
|
v-model="record.orderDate"
|
|
|
format="YYYY-MM-DD"
|
|
|
show-time
|
|
|
+ :disabled="editAll=='yes'"
|
|
|
/>
|
|
|
</span>
|
|
|
<!-- 总件数 -->
|
|
|
<span slot="allNum" slot-scope="text, record, index">
|
|
|
<!-- <a-form-model-item prop="remarks2"> -->
|
|
|
- <a-input placeholder="请输入" v-model="record.allNum" />
|
|
|
+ <a-input placeholder="请输入" v-model="record.allNum" :disabled="editAll=='yes'"/>
|
|
|
<!-- </a-form-model-item> -->
|
|
|
</span>
|
|
|
<!-- 柜子数量 -->
|
|
|
<span slot="cabinets" slot-scope="text, record, index">
|
|
|
<!-- <a-form-model-item prop="remarks2"> -->
|
|
|
- <a-input placeholder="请输入" v-model="record.cabinets" />
|
|
|
+ <a-input placeholder="请输入" v-model="record.cabinets" :disabled="editAll=='yes'"/>
|
|
|
<!-- </a-form-model-item> -->
|
|
|
</span>
|
|
|
<!-- 明细 -->
|
|
|
<span slot="detailedNum" slot-scope="text, record, index">
|
|
|
<!-- <a-form-model-item prop="remarks2"> -->
|
|
|
- <a-input placeholder="请输入" v-model="record.detailedNum" @blur="handleChangePrice(record)"/>
|
|
|
+ <a-input placeholder="请输入" v-model="record.detailedNum" @blur="handleChangePrice(record)" :disabled="editAll=='yes'"/>
|
|
|
<!-- </a-form-model-item> -->
|
|
|
</span>
|
|
|
<!-- 衣架/吨数 -->
|
|
|
<span slot="coatHanger" slot-scope="text, record, index">
|
|
|
<!-- <a-form-model-item prop="remarks2"> -->
|
|
|
- <a-input placeholder="请输入" v-model="record.coatHanger" @blur="handleChangePrice(record)"/>
|
|
|
+ <a-input placeholder="请输入" v-model="record.coatHanger" @blur="handleChangePrice(record)" :disabled="editAll=='yes'"/>
|
|
|
<!-- </a-form-model-item> -->
|
|
|
</span>
|
|
|
<!-- 集装箱号 -->
|
|
|
<span slot="containerNo" slot-scope="text, record, index">
|
|
|
<!-- <a-form-model-item prop="remarks2"> -->
|
|
|
- <a-input placeholder="请输入" v-model="record.containerNo" />
|
|
|
+ <a-input placeholder="请输入" v-model="record.containerNo" :disabled="editAll=='yes'"/>
|
|
|
<!-- </a-form-model-item> -->
|
|
|
</span>
|
|
|
<!-- 入库单号/发票号 -->
|
|
|
<span slot="invoiceNo" slot-scope="text, record, index">
|
|
|
<!-- <a-form-model-item prop="remarks2"> -->
|
|
|
- <a-input placeholder="请输入" v-model="record.invoiceNo" />
|
|
|
+ <a-input placeholder="请输入" v-model="record.invoiceNo" :disabled="editAll=='yes'"/>
|
|
|
<!-- </a-form-model-item> -->
|
|
|
</span>
|
|
|
<!-- 外销发票号 -->
|
|
|
<span slot="saleInvoiceNo" slot-scope="text, record, index">
|
|
|
<!-- <a-form-model-item prop="remarks2"> -->
|
|
|
- <a-input placeholder="请输入" v-model="record.saleInvoiceNo" />
|
|
|
+ <a-input placeholder="请输入" v-model="record.saleInvoiceNo" :disabled="editAll=='yes'"/>
|
|
|
<!-- </a-form-model-item> -->
|
|
|
</span>
|
|
|
<!-- 价格 -->
|
|
|
<span slot="price" slot-scope="text, record, index">
|
|
|
<!-- <a-form-model-item prop="remarks2"> -->
|
|
|
- <a-input placeholder="请输入" v-model="record.price" @blur="handleChangePrice(record)"/>
|
|
|
+ <a-input placeholder="请输入" v-model="record.price" @blur="handleChangePrice(record)" :disabled="editAll=='yes'"/>
|
|
|
<!-- </a-form-model-item> -->
|
|
|
</span>
|
|
|
<!-- 总价 -->
|
|
|
<span slot="totalPrice" slot-scope="text, record, index">
|
|
|
<!-- <a-form-model-item prop="remarks2"> -->
|
|
|
- <a-input placeholder="请输入" v-model="record.totalPrice" @blur="handleChangetotalPrice()"/>
|
|
|
+ <a-input placeholder="请输入" v-model="record.totalPrice" @blur="handleChangetotalPrice()" :disabled="editAll=='yes'"/>
|
|
|
<!-- </a-form-model-item> -->
|
|
|
</span>
|
|
|
<!-- 计划员 -->
|
|
|
<span slot="jhyByData" slot-scope="text, record, index">
|
|
|
<!-- <a-form-model-item prop="remarks2"> -->
|
|
|
<a-select v-model="record.jhyByData" style="width:100%" mode="multiple"
|
|
|
- show-search :filterOption="filterOption" @change="handleChange(record)">
|
|
|
+ show-search :filterOption="filterOption" @change="handleChange(record)" :disabled="editAll=='yes'">
|
|
|
<a-select-option
|
|
|
v-for="(item,index) in jhyNameOption"
|
|
|
:key="index"
|
|
@@ -197,20 +205,20 @@
|
|
|
<!-- 原因 -->
|
|
|
<span slot="reason" slot-scope="text, record, index">
|
|
|
<!-- <a-form-model-item prop="remarks2"> -->
|
|
|
- <a-input placeholder="请输入" v-model="record.reason" />
|
|
|
+ <a-input placeholder="请输入" v-model="record.reason" :disabled="editAll=='yesno'"/>
|
|
|
<!-- </a-form-model-item> -->
|
|
|
</span>
|
|
|
<!-- 备注 -->
|
|
|
<span slot="demo" slot-scope="text, record, index">
|
|
|
<!-- <a-form-model-item prop="remarks2"> -->
|
|
|
- <a-input placeholder="请输入" v-model="record.demo" />
|
|
|
+ <a-input placeholder="请输入" v-model="record.demo" :disabled="editAll=='yes'"/>
|
|
|
<!-- </a-form-model-item> -->
|
|
|
</span>
|
|
|
<span slot="option" slot-scope="text, record, index">
|
|
|
<!-- <a-form-model-item prop="remarks2"> -->
|
|
|
- <a @click="copyRow(record)">复制</a>
|
|
|
+ <a @click="copyRow(record)" :disabled="editAll=='yes'">复制</a>
|
|
|
<a-divider type="vertical" />
|
|
|
- <a @click="deleteRow(record,index)" style="color:red">删行</a>
|
|
|
+ <a @click="deleteRow(record,index)" style="color:red" :disabled="editAll=='yes'">删行</a>
|
|
|
<!-- </a-form-model-item> -->
|
|
|
|
|
|
</span>
|
|
@@ -258,12 +266,13 @@
|
|
|
import {fileDetail} from '@api/oa/cd-sy-carry'
|
|
|
import { putAction,getAction } from '@/api/manage'
|
|
|
import {Arabia_to_Chinese} from '@api/converNumbers'
|
|
|
-
|
|
|
+ import JUpload from '@/components/jeecg/JUpload'
|
|
|
export default {
|
|
|
name: 'SyCarryModal',
|
|
|
mixins: [JEditableTableMixin],
|
|
|
components: {
|
|
|
moment,
|
|
|
+ JUpload
|
|
|
},
|
|
|
data() {
|
|
|
return {
|
|
@@ -420,6 +429,8 @@
|
|
|
]
|
|
|
},
|
|
|
defultMethods:'add',
|
|
|
+ editAll:'',
|
|
|
+ annex:[],
|
|
|
url: {
|
|
|
add: "/oa/syCarry/add",
|
|
|
edit: "/oa/syCarry/edit",
|
|
@@ -452,6 +463,7 @@
|
|
|
if(res.success){
|
|
|
var zhuId = '' //主表id
|
|
|
this.formState=res.result //详情
|
|
|
+ this.annex =(this.formState.annex!==''&&this.formState.annex)?this.formState.annex.split(','):[]
|
|
|
zhuId = res.result.id
|
|
|
this.getTable(zhuId)
|
|
|
}else{
|
|
@@ -591,6 +603,7 @@
|
|
|
}
|
|
|
})
|
|
|
obj.syCarryBList = this.syCarryBTable.dataSource
|
|
|
+ obj.annex = this.annex.toString()
|
|
|
await this.judageTablez(obj.syCarryBList)
|
|
|
if(this.defultMethods == 'add' && this.passVerification == 'yes'){
|
|
|
this.buttonLoading = true
|
|
@@ -605,7 +618,7 @@
|
|
|
this.buttonLoading = false
|
|
|
}
|
|
|
})
|
|
|
- }else if(this.passVerification == 'yes'){
|
|
|
+ }else if(this.passVerification == 'yes' && this.editAll == 'no'){
|
|
|
this.buttonLoading = true
|
|
|
putAction('/oa/syCarry/edit', obj).then((res) => {
|
|
|
if(res.success){
|
|
@@ -618,7 +631,20 @@
|
|
|
this.buttonLoading = false
|
|
|
}
|
|
|
})
|
|
|
- }
|
|
|
+ }else if(this.passVerification == 'yes' && this.editAll == 'yes'){
|
|
|
+ this.buttonLoading = true
|
|
|
+ getAction('/oa/syCarry/editFile', {id:this.formState.id,annex:obj.annex}).then((res) => {
|
|
|
+ if(res.success){
|
|
|
+ this.$message.success('编辑成功')
|
|
|
+ this.handleCancel()
|
|
|
+ this.$emit('close')
|
|
|
+ this.buttonLoading = false
|
|
|
+ }else{
|
|
|
+ this.$message.warning(res.message)
|
|
|
+ this.buttonLoading = false
|
|
|
+ }
|
|
|
+ })
|
|
|
+ }
|
|
|
}
|
|
|
})
|
|
|
|
|
@@ -820,4 +846,7 @@
|
|
|
/deep/ .table-page-search-wrapper .ant-form-inline .ant-form-item > .ant-form-item-label {
|
|
|
width: 118px;
|
|
|
}
|
|
|
+/deep/ .ff .ant-form-item-control {
|
|
|
+ display: contents;
|
|
|
+}
|
|
|
</style>
|