|
|
|
@ -43,7 +43,11 @@ function Detail() {
|
|
|
|
|
return {'info_money':data.GMD_Cost,'info_Currency':data.GMD_Currency,'info_date':isNotEmpty(data.GMD_PayDate)?dayjs(data.GMD_PayDate):'','info_gmdsn':data.GMD_SN};
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
if (form){
|
|
|
|
|
form.setFieldsValue(formData[arrLen-1]); //{'info_money':'111','info_Currency':'THB','info_date':''}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//图片列表
|
|
|
|
|
let arrPicList = ZDDetail.map((data,index)=>{
|
|
|
|
@ -69,7 +73,6 @@ function Detail() {
|
|
|
|
|
|
|
|
|
|
})
|
|
|
|
|
setInvoicePicList(arrPicList);
|
|
|
|
|
|
|
|
|
|
})
|
|
|
|
|
.catch(ex => {
|
|
|
|
|
notification.error({
|
|
|
|
@ -83,12 +86,13 @@ function Detail() {
|
|
|
|
|
setDataLoading(false);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
// if (invoiceStore.invoiceFormData){
|
|
|
|
|
// form.setFieldsValue(invoiceStore.invoiceFormData);
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
}, [GMDSN, GSN]);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function defaultShow(json){
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const fileList = toJS(invoicekImages);
|
|
|
|
|
//图片列表
|
|
|
|
|
let arrimg = [];
|
|
|
|
@ -192,13 +196,21 @@ function Detail() {
|
|
|
|
|
return arr;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function addInvoice(){
|
|
|
|
|
invoiceStore.postAddInvoice(GSN, "", 0, "", "[]", "").then((data) => {
|
|
|
|
|
runInAction(() => {
|
|
|
|
|
invoiceStore.invoiceFormData = {'info_money':0,'info_Currency':'','info_date':'','info_gmdsn':GMDSN};
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function addButton(check) {
|
|
|
|
|
if (check) {
|
|
|
|
|
return (
|
|
|
|
|
|
|
|
|
|
<Row>
|
|
|
|
|
<Divider orientation="left"></Divider>
|
|
|
|
|
<Button type="primary" block onClick={() => showConfirmModal(confirm)}>
|
|
|
|
|
<Button type="primary" block onClick={() => addInvoice(confirm)}>
|
|
|
|
|
ADD New Invoice
|
|
|
|
|
</Button>
|
|
|
|
|
</Row>
|
|
|
|
@ -372,7 +384,7 @@ function Detail() {
|
|
|
|
|
|
|
|
|
|
return (
|
|
|
|
|
<>
|
|
|
|
|
<Modal
|
|
|
|
|
{/* <Modal
|
|
|
|
|
centered
|
|
|
|
|
confirmLoading={confirmLoading}
|
|
|
|
|
open={isModalOpen} onOk={handleOk} onCancel={handleCancel}
|
|
|
|
@ -445,7 +457,7 @@ function Detail() {
|
|
|
|
|
</Form.Item>
|
|
|
|
|
|
|
|
|
|
</Form>
|
|
|
|
|
</Modal>
|
|
|
|
|
</Modal> */}
|
|
|
|
|
<Space direction="vertical" style={{ width: "100%" }}>
|
|
|
|
|
<Row gutter={16}>
|
|
|
|
|
<Col span={20}>
|
|
|
|
|