견적서 수정
This commit is contained in:
parent
943c7fd4b2
commit
38f70437c6
@ -58,7 +58,7 @@ export default function Estimate({ params }) {
|
|||||||
const objectRecoil = useRecoilValue(floorPlanObjectState)
|
const objectRecoil = useRecoilValue(floorPlanObjectState)
|
||||||
|
|
||||||
//견적서 상세데이터
|
//견적서 상세데이터
|
||||||
const { state, setState, addItem, handleEstimateFileDownload } = useEstimateController(params.pid)
|
const { estimateContextState, setEstimateContextState, addItem, handleEstimateFileDownload } = useEstimateController(params.pid)
|
||||||
|
|
||||||
//견적특이사항 List
|
//견적특이사항 List
|
||||||
const [specialNoteList, setSpecialNoteList] = useState([])
|
const [specialNoteList, setSpecialNoteList] = useState([])
|
||||||
@ -105,9 +105,9 @@ export default function Estimate({ params }) {
|
|||||||
let url = `/api/estimate/special-note-list`
|
let url = `/api/estimate/special-note-list`
|
||||||
get({ url: url }).then((res) => {
|
get({ url: url }).then((res) => {
|
||||||
if (isNotEmptyArray(res)) {
|
if (isNotEmptyArray(res)) {
|
||||||
if (state?.estimateOption) {
|
if (estimateContextState?.estimateOption) {
|
||||||
res.map((row) => {
|
res.map((row) => {
|
||||||
let estimateOption = state?.estimateOption?.split('、')
|
let estimateOption = estimateContextState?.estimateOption?.split('、')
|
||||||
row.text = false
|
row.text = false
|
||||||
estimateOption.map((row2) => {
|
estimateOption.map((row2) => {
|
||||||
if (row2 === row.code) {
|
if (row2 === row.code) {
|
||||||
@ -119,16 +119,16 @@ export default function Estimate({ params }) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}, [state?.estimateOption])
|
}, [estimateContextState?.estimateOption])
|
||||||
|
|
||||||
//견적일 set
|
//견적일 set
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
let estimateDate = dayjs(startDate).format('YYYY-MM-DD')
|
let estimateDate = dayjs(startDate).format('YYYY-MM-DD')
|
||||||
setState({ estimateDate: estimateDate })
|
setEstimateContextState({ estimateDate: estimateDate })
|
||||||
}, [startDate])
|
}, [startDate])
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
//선택된 견적특이사항 setState
|
//선택된 견적특이사항 setEstimateContextState
|
||||||
if (isNotEmptyArray(specialNoteList)) {
|
if (isNotEmptyArray(specialNoteList)) {
|
||||||
const liveCheckedData = specialNoteList.filter((row) => row.text === true)
|
const liveCheckedData = specialNoteList.filter((row) => row.text === true)
|
||||||
|
|
||||||
@ -138,7 +138,7 @@ export default function Estimate({ params }) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const newData = data.join('、')
|
const newData = data.join('、')
|
||||||
setState({ estimateOption: newData })
|
setEstimateContextState({ estimateOption: newData })
|
||||||
}
|
}
|
||||||
}, [specialNoteList])
|
}, [specialNoteList])
|
||||||
|
|
||||||
@ -148,23 +148,23 @@ export default function Estimate({ params }) {
|
|||||||
event.stopPropagation()
|
event.stopPropagation()
|
||||||
}
|
}
|
||||||
|
|
||||||
// 추가한 첨부파일 state에 넣기
|
// 추가한 첨부파일 estimateContextState에 넣기
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (isNotEmptyArray(files)) {
|
if (isNotEmptyArray(files)) {
|
||||||
files.map((row) => {
|
files.map((row) => {
|
||||||
setState({ fileList: row.data })
|
setEstimateContextState({ fileList: row.data })
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
setState({ fileList: [] })
|
setEstimateContextState({ fileList: [] })
|
||||||
}
|
}
|
||||||
}, [files])
|
}, [files])
|
||||||
|
|
||||||
//상세에서 내려온 첨부파일 set 만들기
|
//상세에서 내려온 첨부파일 set 만들기
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (isNotEmptyArray(state.fileList)) {
|
if (isNotEmptyArray(estimateContextState.fileList)) {
|
||||||
setOriginFiles(state.fileList)
|
setOriginFiles(estimateContextState.fileList)
|
||||||
}
|
}
|
||||||
}, [state?.fileList])
|
}, [estimateContextState?.fileList])
|
||||||
|
|
||||||
// 기존첨부파일 삭제
|
// 기존첨부파일 삭제
|
||||||
const deleteOriginFile = async (objectNo, no) => {
|
const deleteOriginFile = async (objectNo, no) => {
|
||||||
@ -176,7 +176,7 @@ export default function Estimate({ params }) {
|
|||||||
await promisePost({ url: 'api/file/fileDelete', data: delParams }).then((res) => {
|
await promisePost({ url: 'api/file/fileDelete', data: delParams }).then((res) => {
|
||||||
if (res.status === 204) {
|
if (res.status === 204) {
|
||||||
setOriginFiles(originFiles.filter((file) => file.objectNo === objectNo && file.no !== no))
|
setOriginFiles(originFiles.filter((file) => file.objectNo === objectNo && file.no !== no))
|
||||||
setState({
|
setEstimateContextState({
|
||||||
fileList: originFiles.filter((file) => file.objectNo === objectNo && file.no !== no),
|
fileList: originFiles.filter((file) => file.objectNo === objectNo && file.no !== no),
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -185,11 +185,11 @@ export default function Estimate({ params }) {
|
|||||||
|
|
||||||
//가격표시 option 목록 최초세팅 && 주문분류 변경시
|
//가격표시 option 목록 최초세팅 && 주문분류 변경시
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (state.estimateType !== '') {
|
if (estimateContextState.estimateType !== '') {
|
||||||
const param = {
|
const param = {
|
||||||
saleStoreId: session.storeId,
|
saleStoreId: session.storeId,
|
||||||
sapSalesStoreCd: session.custCd,
|
sapSalesStoreCd: session.custCd,
|
||||||
docTpCd: state?.estimateType,
|
docTpCd: estimateContextState?.estimateType,
|
||||||
}
|
}
|
||||||
|
|
||||||
const apiUrl = `/api/estimate/price/store-price-list?${queryStringFormatter(param)}`
|
const apiUrl = `/api/estimate/price/store-price-list?${queryStringFormatter(param)}`
|
||||||
@ -201,13 +201,13 @@ export default function Estimate({ params }) {
|
|||||||
|
|
||||||
setItemChangeYn(true)
|
setItemChangeYn(true)
|
||||||
}
|
}
|
||||||
}, [state?.estimateType])
|
}, [estimateContextState?.estimateType])
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (state?.priceCd) {
|
if (estimateContextState?.priceCd) {
|
||||||
setShowPriceCd(state.priceCd)
|
setShowPriceCd(estimateContextState.priceCd)
|
||||||
}
|
}
|
||||||
}, [state?.priceCd])
|
}, [estimateContextState?.priceCd])
|
||||||
|
|
||||||
//가격 표시 option 변경 이벤트
|
//가격 표시 option 변경 이벤트
|
||||||
const onChangeStorePriceList = (priceCd) => {
|
const onChangeStorePriceList = (priceCd) => {
|
||||||
@ -217,7 +217,7 @@ export default function Estimate({ params }) {
|
|||||||
docTpCd: priceCd,
|
docTpCd: priceCd,
|
||||||
}
|
}
|
||||||
|
|
||||||
//프라이싱 했을때 priceCd setState
|
//프라이싱 했을때 priceCd setEstimateContextState
|
||||||
//화면에 보여지는 값은 showPriceCd로 관리
|
//화면에 보여지는 값은 showPriceCd로 관리
|
||||||
setShowPriceCd(priceCd)
|
setShowPriceCd(priceCd)
|
||||||
|
|
||||||
@ -234,10 +234,10 @@ export default function Estimate({ params }) {
|
|||||||
const param = {
|
const param = {
|
||||||
saleStoreId: session.storeId,
|
saleStoreId: session.storeId,
|
||||||
sapSalesStoreCd: session.custCd,
|
sapSalesStoreCd: session.custCd,
|
||||||
docTpCd: state.estimateType,
|
docTpCd: estimateContextState.estimateType,
|
||||||
priceCd: showPriceCd,
|
priceCd: showPriceCd,
|
||||||
//itemIdList: state.itemList, //아이템 최초정보로 호출 delFlg 0인거만..
|
//itemIdList: estimateContextState.itemList, //아이템 최초정보로 호출 delFlg 0인거만..
|
||||||
itemIdList: state.itemList.filter((item) => item.delFlg === '0'),
|
itemIdList: estimateContextState.itemList.filter((item) => item.delFlg === '0'),
|
||||||
}
|
}
|
||||||
|
|
||||||
if (param.itemIdList.length > 0) {
|
if (param.itemIdList.length > 0) {
|
||||||
@ -264,7 +264,7 @@ export default function Estimate({ params }) {
|
|||||||
//itemId로 비교해서 단가정보만 업데이트
|
//itemId로 비교해서 단가정보만 업데이트
|
||||||
if (data.result.code === 200) {
|
if (data.result.code === 200) {
|
||||||
if (isNotEmptyArray(data.data2)) {
|
if (isNotEmptyArray(data.data2)) {
|
||||||
state.itemList.map((item) => {
|
estimateContextState.itemList.map((item) => {
|
||||||
let checkYn = false
|
let checkYn = false
|
||||||
data.data2.map((item2) => {
|
data.data2.map((item2) => {
|
||||||
if (item2.itemId === item.itemId) {
|
if (item2.itemId === item.itemId) {
|
||||||
@ -278,7 +278,7 @@ export default function Estimate({ params }) {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
setState({
|
setEstimateContextState({
|
||||||
priceCd: showPriceCd,
|
priceCd: showPriceCd,
|
||||||
itemList: updateList,
|
itemList: updateList,
|
||||||
})
|
})
|
||||||
@ -305,7 +305,7 @@ export default function Estimate({ params }) {
|
|||||||
|
|
||||||
//주택PKG input 변경
|
//주택PKG input 변경
|
||||||
const onChangePkgAsp = (value) => {
|
const onChangePkgAsp = (value) => {
|
||||||
if (state.estimateType === 'YJSS') {
|
if (estimateContextState.estimateType === 'YJSS') {
|
||||||
let pkgAsp = Number(value.replace(/[^0-9]/g, '').replaceAll(',', ''))
|
let pkgAsp = Number(value.replace(/[^0-9]/g, '').replaceAll(',', ''))
|
||||||
if (isNaN(pkgAsp)) {
|
if (isNaN(pkgAsp)) {
|
||||||
pkgAsp = 0
|
pkgAsp = 0
|
||||||
@ -314,10 +314,10 @@ export default function Estimate({ params }) {
|
|||||||
}
|
}
|
||||||
//현재 PKG용량값 가져오기
|
//현재 PKG용량값 가져오기
|
||||||
|
|
||||||
let totVolKw = state.totVolKw * 1000
|
let totVolKw = estimateContextState.totVolKw * 1000
|
||||||
let pkgTotPrice = pkgAsp * totVolKw
|
let pkgTotPrice = pkgAsp * totVolKw
|
||||||
|
|
||||||
setState({
|
setEstimateContextState({
|
||||||
pkgAsp: pkgAsp,
|
pkgAsp: pkgAsp,
|
||||||
pkgTotPrice: pkgTotPrice.toFixed(3),
|
pkgTotPrice: pkgTotPrice.toFixed(3),
|
||||||
})
|
})
|
||||||
@ -339,9 +339,9 @@ export default function Estimate({ params }) {
|
|||||||
updates.amount = amount
|
updates.amount = amount
|
||||||
updates.itemChangeFlg = '1'
|
updates.itemChangeFlg = '1'
|
||||||
updates.partAdd = '0'
|
updates.partAdd = '0'
|
||||||
updates.saleTotPrice = (Number(amount.replaceAll(',', '')) * state.itemList[index].salePrice.replaceAll(',', '')).toLocaleString()
|
updates.saleTotPrice = (Number(amount.replaceAll(',', '')) * estimateContextState.itemList[index].salePrice.replaceAll(',', '')).toLocaleString()
|
||||||
|
|
||||||
updateList = state.itemList.map((item) => {
|
updateList = estimateContextState.itemList.map((item) => {
|
||||||
if (item.dispOrder === dispOrder) {
|
if (item.dispOrder === dispOrder) {
|
||||||
return { ...item, ...updates }
|
return { ...item, ...updates }
|
||||||
} else {
|
} else {
|
||||||
@ -349,7 +349,7 @@ export default function Estimate({ params }) {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
setState({
|
setEstimateContextState({
|
||||||
itemList: updateList,
|
itemList: updateList,
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -368,9 +368,9 @@ export default function Estimate({ params }) {
|
|||||||
let updateList = []
|
let updateList = []
|
||||||
let updates = {}
|
let updates = {}
|
||||||
updates.salePrice = salePrice
|
updates.salePrice = salePrice
|
||||||
updates.saleTotPrice = (Number(salePrice.replaceAll(',', '')) * state.itemList[index].amount.replaceAll(',', '')).toLocaleString()
|
updates.saleTotPrice = (Number(salePrice.replaceAll(',', '')) * estimateContextState.itemList[index].amount.replaceAll(',', '')).toLocaleString()
|
||||||
|
|
||||||
updateList = state.itemList.map((item) => {
|
updateList = estimateContextState.itemList.map((item) => {
|
||||||
if (item.dispOrder === dispOrder) {
|
if (item.dispOrder === dispOrder) {
|
||||||
return { ...item, ...updates }
|
return { ...item, ...updates }
|
||||||
} else {
|
} else {
|
||||||
@ -378,7 +378,7 @@ export default function Estimate({ params }) {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
setState({
|
setEstimateContextState({
|
||||||
itemList: updateList,
|
itemList: updateList,
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -414,12 +414,12 @@ export default function Estimate({ params }) {
|
|||||||
updates.specialNoteCd = res.spnAttrCds
|
updates.specialNoteCd = res.spnAttrCds
|
||||||
updates.itemGroup = res.itemGroup
|
updates.itemGroup = res.itemGroup
|
||||||
updates.delFlg = '0' // 삭제플래그 0
|
updates.delFlg = '0' // 삭제플래그 0
|
||||||
// updates.saleTotPrice = res.salePrice * state.itemList[index].amount
|
// updates.saleTotPrice = res.salePrice * estimateContextState.itemList[index].amount
|
||||||
updates.saleTotPrice = '0' //추가때는 수량을 안받아서 합계를 무조건 0으로
|
updates.saleTotPrice = '0' //추가때는 수량을 안받아서 합계를 무조건 0으로
|
||||||
//104671
|
//104671
|
||||||
let bomList = res.itemBomList
|
let bomList = res.itemBomList
|
||||||
|
|
||||||
updateList = state.itemList.map((item) => {
|
updateList = estimateContextState.itemList.map((item) => {
|
||||||
if (item.dispOrder === dispOrder) {
|
if (item.dispOrder === dispOrder) {
|
||||||
return { ...item, ...updates }
|
return { ...item, ...updates }
|
||||||
} else if (item.paDispOrder === dispOrder) {
|
} else if (item.paDispOrder === dispOrder) {
|
||||||
@ -431,18 +431,18 @@ export default function Estimate({ params }) {
|
|||||||
//paDispOrder
|
//paDispOrder
|
||||||
if (bomList) {
|
if (bomList) {
|
||||||
bomList.map((bomItem, index) => {
|
bomList.map((bomItem, index) => {
|
||||||
let newItemDispOrder = Math.max(...state.itemList.map((item) => item.dispOrder))
|
let newItemDispOrder = Math.max(...estimateContextState.itemList.map((item) => item.dispOrder))
|
||||||
bomItem.dispOrder = index + 1 + newItemDispOrder
|
bomItem.dispOrder = index + 1 + newItemDispOrder
|
||||||
bomItem.delFlg = '0'
|
bomItem.delFlg = '0'
|
||||||
bomItem.objectNo = objectNo
|
bomItem.objectNo = objectNo
|
||||||
bomItem.planNo = planNo
|
bomItem.planNo = planNo
|
||||||
})
|
})
|
||||||
|
|
||||||
setState({
|
setEstimateContextState({
|
||||||
itemList: [...updateList, ...bomList],
|
itemList: [...updateList, ...bomList],
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
setState({
|
setEstimateContextState({
|
||||||
itemList: updateList,
|
itemList: updateList,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -455,7 +455,7 @@ export default function Estimate({ params }) {
|
|||||||
const removeItem = () => {
|
const removeItem = () => {
|
||||||
const array = [...selection]
|
const array = [...selection]
|
||||||
let delList = []
|
let delList = []
|
||||||
state.itemList.filter((row) => {
|
estimateContextState.itemList.filter((row) => {
|
||||||
array.map((row2) => {
|
array.map((row2) => {
|
||||||
if (row2 === row.dispOrder) {
|
if (row2 === row.dispOrder) {
|
||||||
delList.push({ ...row })
|
delList.push({ ...row })
|
||||||
@ -466,7 +466,7 @@ export default function Estimate({ params }) {
|
|||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
const updateList = state.itemList.map((item) => {
|
const updateList = estimateContextState.itemList.map((item) => {
|
||||||
const isDeleted = delList.some((row) => item.delFlg === '1' || item.dispOrder === row.dispOrder)
|
const isDeleted = delList.some((row) => item.delFlg === '1' || item.dispOrder === row.dispOrder)
|
||||||
return {
|
return {
|
||||||
...item,
|
...item,
|
||||||
@ -485,7 +485,7 @@ export default function Estimate({ params }) {
|
|||||||
return alert(getMessage('estimate.detail.save.requiredItem'))
|
return alert(getMessage('estimate.detail.save.requiredItem'))
|
||||||
}
|
}
|
||||||
|
|
||||||
setState({
|
setEstimateContextState({
|
||||||
itemList: updateList,
|
itemList: updateList,
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -501,8 +501,8 @@ export default function Estimate({ params }) {
|
|||||||
let vatPrice = 0
|
let vatPrice = 0
|
||||||
let totPrice = 0
|
let totPrice = 0
|
||||||
let addPkgPrice = 0
|
let addPkgPrice = 0
|
||||||
if (state.estimateType === 'YJOD') {
|
if (estimateContextState.estimateType === 'YJOD') {
|
||||||
state.itemList.map((item) => {
|
estimateContextState.itemList.map((item) => {
|
||||||
if (item.delFlg === '0') {
|
if (item.delFlg === '0') {
|
||||||
const amount = Number(item.amount.replace(/[^0-9]/g, '').replaceAll(',', ''))
|
const amount = Number(item.amount.replace(/[^0-9]/g, '').replaceAll(',', ''))
|
||||||
const price = Number(item.saleTotPrice.replaceAll(',', ''))
|
const price = Number(item.saleTotPrice.replaceAll(',', ''))
|
||||||
@ -521,7 +521,7 @@ export default function Estimate({ params }) {
|
|||||||
vatPrice = supplyPrice * 0.1
|
vatPrice = supplyPrice * 0.1
|
||||||
totPrice = supplyPrice + vatPrice
|
totPrice = supplyPrice + vatPrice
|
||||||
|
|
||||||
setState({
|
setEstimateContextState({
|
||||||
totAmount: totAmount,
|
totAmount: totAmount,
|
||||||
totVolKw: totVolKw.toFixed(3),
|
totVolKw: totVolKw.toFixed(3),
|
||||||
supplyPrice: supplyPrice.toFixed(3),
|
supplyPrice: supplyPrice.toFixed(3),
|
||||||
@ -530,7 +530,7 @@ export default function Estimate({ params }) {
|
|||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
//YJSS
|
//YJSS
|
||||||
state.itemList.map((item) => {
|
estimateContextState.itemList.map((item) => {
|
||||||
if (item.delFlg === '0') {
|
if (item.delFlg === '0') {
|
||||||
const amount = Number(item.amount.replace(/[^0-9]/g, '').replaceAll(',', ''))
|
const amount = Number(item.amount.replace(/[^0-9]/g, '').replaceAll(',', ''))
|
||||||
const price = Number(item.saleTotPrice.replaceAll(',', ''))
|
const price = Number(item.saleTotPrice.replaceAll(',', ''))
|
||||||
@ -556,7 +556,7 @@ export default function Estimate({ params }) {
|
|||||||
vatPrice = supplyPrice * 0.1
|
vatPrice = supplyPrice * 0.1
|
||||||
totPrice = supplyPrice + vatPrice
|
totPrice = supplyPrice + vatPrice
|
||||||
|
|
||||||
setState({
|
setEstimateContextState({
|
||||||
totAmount: totAmount,
|
totAmount: totAmount,
|
||||||
totVolKw: totVolKw.toFixed(3),
|
totVolKw: totVolKw.toFixed(3),
|
||||||
supplyPrice: supplyPrice.toFixed(3),
|
supplyPrice: supplyPrice.toFixed(3),
|
||||||
@ -567,21 +567,22 @@ export default function Estimate({ params }) {
|
|||||||
|
|
||||||
setItemChangeYn(false)
|
setItemChangeYn(false)
|
||||||
}
|
}
|
||||||
}, [itemChangeYn, state.itemList])
|
}, [itemChangeYn, estimateContextState.itemList])
|
||||||
|
|
||||||
//안건명 인풋 변경
|
//안건명 인풋 변경
|
||||||
const handleBlurObjectName = (e) => {
|
const handleBlurObjectName = (e) => {
|
||||||
setState({ objectName: e.target.value })
|
setEstimateContextState({ objectName: e.target.value })
|
||||||
}
|
}
|
||||||
|
|
||||||
//담당자 인풋 변경
|
//담당자 인풋 변경
|
||||||
const handleBlurCharger = (e) => {
|
const handleBlurCharger = (e) => {
|
||||||
setState({ charger: e.target.value })
|
setEstimateContextState({ charger: e.target.value })
|
||||||
}
|
}
|
||||||
|
|
||||||
useEffect(() => {
|
//비고 인풋 변경
|
||||||
console.log('수정날짜시간???????????', state.lastEditDatetime)
|
const handleBlurRemarks = (e) => {
|
||||||
}, [state])
|
setEstimateContextState({ remarks: e.target.value })
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="sub-content estimate">
|
<div className="sub-content estimate">
|
||||||
@ -598,18 +599,21 @@ export default function Estimate({ params }) {
|
|||||||
</div>
|
</div>
|
||||||
<div className="estimate-box">
|
<div className="estimate-box">
|
||||||
<div className="estimate-tit">{getMessage('estimate.detail.docNo')}</div>
|
<div className="estimate-tit">{getMessage('estimate.detail.docNo')}</div>
|
||||||
<div className="estimate-name">{state.docNo}</div>
|
<div className="estimate-name">{estimateContextState.docNo}</div>
|
||||||
</div>
|
</div>
|
||||||
<div className="estimate-box">
|
<div className="estimate-box">
|
||||||
<div className="estimate-tit">{getMessage('estimate.detail.drawingEstimateCreateDate')}</div>
|
<div className="estimate-tit">{getMessage('estimate.detail.drawingEstimateCreateDate')}</div>
|
||||||
<div className="estimate-name">
|
<div className="estimate-name">
|
||||||
{state?.drawingEstimateCreateDate ? `${dayjs(state.drawingEstimateCreateDate).format('YYYY.MM.DD')}` : ''}
|
{estimateContextState?.drawingEstimateCreateDate
|
||||||
|
? `${dayjs(estimateContextState.drawingEstimateCreateDate).format('YYYY.MM.DD')}`
|
||||||
|
: ''}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div className="estimate-box">
|
<div className="estimate-box">
|
||||||
<div className="estimate-tit">{getMessage('estimate.detail.lastEditDatetime')}</div>
|
<div className="estimate-tit">{getMessage('estimate.detail.lastEditDatetime')}</div>
|
||||||
{/* <div className="estimate-name">{state?.lastEditDatetime ? `${dayjs(state.lastEditDatetime).format('YYYY.MM.DD HH:mm')}` : ''}</div> */}
|
<div className="estimate-name">
|
||||||
<div className="estimate-name">{state?.lastEditDatetime ? `${dayjs(state?.lastEditDatetime).format('HH:mm:ss')}` : ''}</div>
|
{estimateContextState?.lastEditDatetime ? `${dayjs(estimateContextState.lastEditDatetime).format('YYYY.MM.DD HH:mm')}` : ''}
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -635,7 +639,7 @@ export default function Estimate({ params }) {
|
|||||||
<tr>
|
<tr>
|
||||||
{/* 1차 판매점명 */}
|
{/* 1차 판매점명 */}
|
||||||
<th>{getMessage('estimate.detail.saleStoreId')}</th>
|
<th>{getMessage('estimate.detail.saleStoreId')}</th>
|
||||||
<td>{state?.firstSaleStoreName}</td>
|
<td>{estimateContextState?.firstSaleStoreName}</td>
|
||||||
{/* 견적일 */}
|
{/* 견적일 */}
|
||||||
<th>
|
<th>
|
||||||
{getMessage('estimate.detail.estimateDate')} <span className="important">*</span>
|
{getMessage('estimate.detail.estimateDate')} <span className="important">*</span>
|
||||||
@ -649,23 +653,14 @@ export default function Estimate({ params }) {
|
|||||||
<tr>
|
<tr>
|
||||||
{/* 2차 판매점명 */}
|
{/* 2차 판매점명 */}
|
||||||
<th>{getMessage('estimate.detail.otherSaleStoreId')}</th>
|
<th>{getMessage('estimate.detail.otherSaleStoreId')}</th>
|
||||||
<td>{state?.agencySaleStoreName}</td>
|
<td>{estimateContextState?.agencySaleStoreName}</td>
|
||||||
{/* 담당자 */}
|
{/* 담당자 */}
|
||||||
<th>
|
<th>
|
||||||
{getMessage('estimate.detail.receiveUser')} <span className="important">*</span>
|
{getMessage('estimate.detail.receiveUser')} <span className="important">*</span>
|
||||||
</th>
|
</th>
|
||||||
<td>
|
<td>
|
||||||
<div className="input-wrap" style={{ width: '350px' }}>
|
<div className="input-wrap" style={{ width: '350px' }}>
|
||||||
<input
|
<input type="text" className="input-light" defaultValue={estimateContextState?.charger} onBlur={handleBlurCharger} />
|
||||||
type="text"
|
|
||||||
className="input-light"
|
|
||||||
defaultValue={state?.charger}
|
|
||||||
// onChange={(e) => {
|
|
||||||
// //담당자 charger
|
|
||||||
// setState({ charger: e.target.value })
|
|
||||||
// }}
|
|
||||||
onBlur={handleBlurCharger}
|
|
||||||
/>
|
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@ -677,16 +672,7 @@ export default function Estimate({ params }) {
|
|||||||
<td colSpan={3}>
|
<td colSpan={3}>
|
||||||
<div className="form-flex-wrap">
|
<div className="form-flex-wrap">
|
||||||
<div className="input-wrap mr5" style={{ width: '610px' }}>
|
<div className="input-wrap mr5" style={{ width: '610px' }}>
|
||||||
<input
|
<input type="text" className="input-light" defaultValue={estimateContextState?.objectName} onBlur={handleBlurObjectName} />
|
||||||
type="text"
|
|
||||||
className="input-light"
|
|
||||||
defaultValue={state?.objectName}
|
|
||||||
// onChange={(e) => {
|
|
||||||
// //안건명 objectName
|
|
||||||
// setState({ objectName: e.target.value })
|
|
||||||
// }}
|
|
||||||
onBlur={handleBlurObjectName}
|
|
||||||
/>
|
|
||||||
</div>
|
</div>
|
||||||
<div className="select-wrap" style={{ width: '200px' }}>
|
<div className="select-wrap" style={{ width: '200px' }}>
|
||||||
<Select
|
<Select
|
||||||
@ -698,9 +684,9 @@ export default function Estimate({ params }) {
|
|||||||
options={honorificCodeList}
|
options={honorificCodeList}
|
||||||
onChange={(e) => {
|
onChange={(e) => {
|
||||||
if (isObjectNotEmpty(e)) {
|
if (isObjectNotEmpty(e)) {
|
||||||
setState({ objectNameOmit: e.clCodeNm })
|
setEstimateContextState({ objectNameOmit: e.clCodeNm })
|
||||||
} else {
|
} else {
|
||||||
setState({ objectNameOmit: '' })
|
setEstimateContextState({ objectNameOmit: '' })
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
getOptionLabel={(x) => x.clCodeNm}
|
getOptionLabel={(x) => x.clCodeNm}
|
||||||
@ -708,7 +694,7 @@ export default function Estimate({ params }) {
|
|||||||
isClearable={false}
|
isClearable={false}
|
||||||
isSearchable={false}
|
isSearchable={false}
|
||||||
value={honorificCodeList.filter(function (option) {
|
value={honorificCodeList.filter(function (option) {
|
||||||
return option.clCodeNm === state.objectNameOmit
|
return option.clCodeNm === estimateContextState.objectNameOmit
|
||||||
})}
|
})}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
@ -718,7 +704,7 @@ export default function Estimate({ params }) {
|
|||||||
<tr>
|
<tr>
|
||||||
{/* 물건정보에서 입력한 메모 */}
|
{/* 물건정보에서 입력한 메모 */}
|
||||||
<th>{getMessage('estimate.detail.objectRemarks')}</th>
|
<th>{getMessage('estimate.detail.objectRemarks')}</th>
|
||||||
<td colSpan={3}>{state?.objectRemarks}</td>
|
<td colSpan={3}>{estimateContextState?.objectRemarks}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
{/* 주문분류 */}
|
{/* 주문분류 */}
|
||||||
@ -733,13 +719,13 @@ export default function Estimate({ params }) {
|
|||||||
name="estimateType"
|
name="estimateType"
|
||||||
id="YJSS"
|
id="YJSS"
|
||||||
value={'YJSS'}
|
value={'YJSS'}
|
||||||
checked={state?.estimateType === 'YJSS' ? true : false}
|
checked={estimateContextState?.estimateType === 'YJSS' ? true : false}
|
||||||
onChange={(e) => {
|
onChange={(e) => {
|
||||||
//주문분류
|
//주문분류
|
||||||
setState({ estimateType: e.target.value })
|
setEstimateContextState({ estimateType: e.target.value })
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
<label htmlFor="YJSS">住宅PKG</label>
|
<label htmlFor="YJSS">{getMessage('estimate.detail.estimateType.yjss')}</label>
|
||||||
</div>
|
</div>
|
||||||
<div className="d-check-radio light">
|
<div className="d-check-radio light">
|
||||||
<input
|
<input
|
||||||
@ -747,12 +733,12 @@ export default function Estimate({ params }) {
|
|||||||
name="estimateType"
|
name="estimateType"
|
||||||
id="YJOD"
|
id="YJOD"
|
||||||
value={'YJOD'}
|
value={'YJOD'}
|
||||||
checked={state?.estimateType === 'YJOD' ? true : false}
|
checked={estimateContextState?.estimateType === 'YJOD' ? true : false}
|
||||||
onChange={(e) => {
|
onChange={(e) => {
|
||||||
setState({ estimateType: e.target.value })
|
setEstimateContextState({ estimateType: e.target.value })
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
<label htmlFor="YJOD">積上げ( YJOD )</label>
|
<label htmlFor="YJOD">{getMessage('estimate.detail.estimateType.yjod')}</label>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
@ -761,16 +747,16 @@ export default function Estimate({ params }) {
|
|||||||
{/* 지붕재・사양시공 최대4개*/}
|
{/* 지붕재・사양시공 최대4개*/}
|
||||||
<th>{getMessage('estimate.detail.roofCns')}</th>
|
<th>{getMessage('estimate.detail.roofCns')}</th>
|
||||||
<td colSpan={3}>
|
<td colSpan={3}>
|
||||||
{state?.roofMaterialIdMulti?.split('、').map((row, index) => {
|
{estimateContextState?.roofMaterialIdMulti?.split('、').map((row, index) => {
|
||||||
//지붕재
|
//지붕재
|
||||||
let roofList = row
|
let roofList = row
|
||||||
let roofListLength = state?.roofMaterialIdMulti?.split('、').length
|
let roofListLength = estimateContextState?.roofMaterialIdMulti?.split('、').length
|
||||||
let style = 'mb5'
|
let style = 'mb5'
|
||||||
if (roofListLength == index + 1) {
|
if (roofListLength == index + 1) {
|
||||||
style = ''
|
style = ''
|
||||||
}
|
}
|
||||||
//사양시공
|
//사양시공
|
||||||
let constructSpecificationMulti = state?.constructSpecificationMulti?.split('、')
|
let constructSpecificationMulti = estimateContextState?.constructSpecificationMulti?.split('、')
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
@ -792,15 +778,7 @@ export default function Estimate({ params }) {
|
|||||||
<th>{getMessage('estimate.detail.remarks')}</th>
|
<th>{getMessage('estimate.detail.remarks')}</th>
|
||||||
<td colSpan={3}>
|
<td colSpan={3}>
|
||||||
<div className="input-wrap">
|
<div className="input-wrap">
|
||||||
<input
|
<input type="text" className="input-light" defaultValue={estimateContextState?.remarks} onBlur={handleBlurRemarks} />
|
||||||
type="text"
|
|
||||||
className="input-light"
|
|
||||||
defaultValue={state?.remarks}
|
|
||||||
onChange={(e) => {
|
|
||||||
//비고
|
|
||||||
setState({ remarks: e.target.value })
|
|
||||||
}}
|
|
||||||
/>
|
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@ -815,9 +793,9 @@ export default function Estimate({ params }) {
|
|||||||
<input
|
<input
|
||||||
type="checkbox"
|
type="checkbox"
|
||||||
id="next"
|
id="next"
|
||||||
checked={state?.fileFlg === '0' ? false : true}
|
checked={estimateContextState?.fileFlg === '0' ? false : true}
|
||||||
onChange={(e) => {
|
onChange={(e) => {
|
||||||
setState({
|
setEstimateContextState({
|
||||||
fileFlg: e.target.checked ? '1' : '0',
|
fileFlg: e.target.checked ? '1' : '0',
|
||||||
})
|
})
|
||||||
}}
|
}}
|
||||||
@ -959,28 +937,28 @@ export default function Estimate({ params }) {
|
|||||||
<div className="estimate-list-wrap one">
|
<div className="estimate-list-wrap one">
|
||||||
<div className="estimate-box">
|
<div className="estimate-box">
|
||||||
<div className="estimate-tit">{getMessage('estimate.detail.sepcialEstimateProductInfo.totAmount')}</div>
|
<div className="estimate-tit">{getMessage('estimate.detail.sepcialEstimateProductInfo.totAmount')}</div>
|
||||||
<div className="estimate-name blue">{convertNumberToPriceDecimal(state?.totAmount)}</div>
|
<div className="estimate-name blue">{convertNumberToPriceDecimal(estimateContextState?.totAmount)}</div>
|
||||||
</div>
|
</div>
|
||||||
<div className="estimate-box">
|
<div className="estimate-box">
|
||||||
<div className="estimate-tit">{getMessage('estimate.detail.sepcialEstimateProductInfo.totVolKw')}</div>
|
<div className="estimate-tit">{getMessage('estimate.detail.sepcialEstimateProductInfo.totVolKw')}</div>
|
||||||
<div className="estimate-name blue">{convertNumberToPriceDecimal(state?.totVolKw)}</div>
|
<div className="estimate-name blue">{convertNumberToPriceDecimal(estimateContextState?.totVolKw)}</div>
|
||||||
</div>
|
</div>
|
||||||
<div className="estimate-box">
|
<div className="estimate-box">
|
||||||
<div className="estimate-tit">{getMessage('estimate.detail.sepcialEstimateProductInfo.supplyPrice')}</div>
|
<div className="estimate-tit">{getMessage('estimate.detail.sepcialEstimateProductInfo.supplyPrice')}</div>
|
||||||
<div className="estimate-name blue">{convertNumberToPriceDecimal(state?.supplyPrice)}</div>
|
<div className="estimate-name blue">{convertNumberToPriceDecimal(estimateContextState?.supplyPrice)}</div>
|
||||||
</div>
|
</div>
|
||||||
<div className="estimate-box">
|
<div className="estimate-box">
|
||||||
<div className="estimate-tit">{getMessage('estimate.detail.sepcialEstimateProductInfo.vatPrice')}</div>
|
<div className="estimate-tit">{getMessage('estimate.detail.sepcialEstimateProductInfo.vatPrice')}</div>
|
||||||
<div className="estimate-name blue">{convertNumberToPriceDecimal(state?.vatPrice)}</div>
|
<div className="estimate-name blue">{convertNumberToPriceDecimal(estimateContextState?.vatPrice)}</div>
|
||||||
</div>
|
</div>
|
||||||
<div className="estimate-box">
|
<div className="estimate-box">
|
||||||
<div className="estimate-tit">{getMessage('estimate.detail.sepcialEstimateProductInfo.totPrice')}</div>
|
<div className="estimate-tit">{getMessage('estimate.detail.sepcialEstimateProductInfo.totPrice')}</div>
|
||||||
<div className="estimate-name red">{convertNumberToPriceDecimal(state?.totPrice)}</div>
|
<div className="estimate-name red">{convertNumberToPriceDecimal(estimateContextState?.totPrice)}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{/* YJOD면 아래영역 숨김 */}
|
{/* YJOD면 아래영역 숨김 */}
|
||||||
<div className="common-table bt-able" style={{ display: state?.estimateType === 'YJSS' ? '' : 'none' }}>
|
<div className="common-table bt-able" style={{ display: estimateContextState?.estimateType === 'YJSS' ? '' : 'none' }}>
|
||||||
<table>
|
<table>
|
||||||
<colgroup>
|
<colgroup>
|
||||||
<col style={{ width: '160px' }} />
|
<col style={{ width: '160px' }} />
|
||||||
@ -1001,7 +979,7 @@ export default function Estimate({ params }) {
|
|||||||
<input
|
<input
|
||||||
type="text"
|
type="text"
|
||||||
className="input-light"
|
className="input-light"
|
||||||
value={state?.pkgAsp}
|
value={estimateContextState?.pkgAsp}
|
||||||
onChange={(e) => {
|
onChange={(e) => {
|
||||||
onChangePkgAsp(e.target.value)
|
onChangePkgAsp(e.target.value)
|
||||||
}}
|
}}
|
||||||
@ -1009,9 +987,9 @@ export default function Estimate({ params }) {
|
|||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
<th>{getMessage('estimate.detail.sepcialEstimateProductInfo.pkgWeight')}</th>
|
<th>{getMessage('estimate.detail.sepcialEstimateProductInfo.pkgWeight')}</th>
|
||||||
<td>{convertNumberToPriceDecimal(state?.totVolKw)}</td>
|
<td>{convertNumberToPriceDecimal(estimateContextState?.totVolKw)}</td>
|
||||||
<th>{getMessage('estimate.detail.sepcialEstimateProductInfo.pkgPrice')}</th>
|
<th>{getMessage('estimate.detail.sepcialEstimateProductInfo.pkgPrice')}</th>
|
||||||
<td>{convertNumberToPriceDecimal(state?.pkgTotPrice)}</td>
|
<td>{convertNumberToPriceDecimal(estimateContextState?.pkgTotPrice)}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
@ -1120,8 +1098,8 @@ export default function Estimate({ params }) {
|
|||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
{state?.itemList.length > 0 &&
|
{estimateContextState?.itemList.length > 0 &&
|
||||||
state.itemList.map((item, index) => {
|
estimateContextState.itemList.map((item, index) => {
|
||||||
if (item.delFlg === '0') {
|
if (item.delFlg === '0') {
|
||||||
return (
|
return (
|
||||||
<tr key={item?.dispOrder || index}>
|
<tr key={item?.dispOrder || index}>
|
||||||
@ -1209,7 +1187,7 @@ export default function Estimate({ params }) {
|
|||||||
className="input-light al-r"
|
className="input-light al-r"
|
||||||
value={convertNumberToPriceDecimal(item?.salePrice.replaceAll(',', ''))}
|
value={convertNumberToPriceDecimal(item?.salePrice.replaceAll(',', ''))}
|
||||||
disabled={
|
disabled={
|
||||||
state?.estimateType === 'YJSS'
|
estimateContextState?.estimateType === 'YJSS'
|
||||||
? item?.paDispOrder
|
? item?.paDispOrder
|
||||||
? true
|
? true
|
||||||
: item.pkgMaterialFlg !== '1'
|
: item.pkgMaterialFlg !== '1'
|
||||||
|
|||||||
@ -9,27 +9,9 @@ import { useMessage } from '@/hooks/useMessage'
|
|||||||
import { useRouter } from 'next/navigation'
|
import { useRouter } from 'next/navigation'
|
||||||
import { FloorPlanContext } from '@/app/floor-plan/FloorPlanProvider'
|
import { FloorPlanContext } from '@/app/floor-plan/FloorPlanProvider'
|
||||||
|
|
||||||
const reducer = (prevState, nextState) => {
|
|
||||||
return { ...prevState, ...nextState }
|
|
||||||
}
|
|
||||||
|
|
||||||
// Constants
|
// Constants
|
||||||
const ESTIMATE_API_ENDPOINT = '/api/estimate' // API 엔드포인트 정의
|
const ESTIMATE_API_ENDPOINT = '/api/estimate' // API 엔드포인트 정의
|
||||||
|
|
||||||
const defaultEstimateData = {
|
|
||||||
estimateDate: new Date(), //견적일
|
|
||||||
charger: '', //담당자
|
|
||||||
objectName: '', //안건명
|
|
||||||
objectNameOmit: '', //경칭코드
|
|
||||||
estimateType: '', //주문분류
|
|
||||||
remarks: '', //비고
|
|
||||||
estimateOption: '', //견적특이사항
|
|
||||||
itemList: [],
|
|
||||||
fileList: [],
|
|
||||||
fileFlg: '0', //후일 자료 제출 (체크 1 노체크 0)
|
|
||||||
priceCd: '',
|
|
||||||
}
|
|
||||||
|
|
||||||
// Helper functions
|
// Helper functions
|
||||||
const updateItemInList = (itemList, dispOrder, updates) => {
|
const updateItemInList = (itemList, dispOrder, updates) => {
|
||||||
return itemList.map((item) => (item.dispOrder === dispOrder ? { ...item, ...updates } : item))
|
return itemList.map((item) => (item.dispOrder === dispOrder ? { ...item, ...updates } : item))
|
||||||
@ -44,11 +26,10 @@ export const useEstimateController = (planNo) => {
|
|||||||
|
|
||||||
const { getMessage } = useMessage()
|
const { getMessage } = useMessage()
|
||||||
|
|
||||||
const { promiseGet, get, post, promisePost } = useAxios(globalLocaleState)
|
const { promiseGet, post, promisePost } = useAxios(globalLocaleState)
|
||||||
|
|
||||||
const [isLoading, setIsLoading] = useState(false)
|
const [isLoading, setIsLoading] = useState(false)
|
||||||
const [state, setState] = useReducer(reducer, defaultEstimateData)
|
const { estimateContextState, setEstimateContextState } = useContext(FloorPlanContext)
|
||||||
const [newState, setNewState] = useState({})
|
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (planNo && !isLoading) {
|
if (planNo && !isLoading) {
|
||||||
@ -69,9 +50,7 @@ export const useEstimateController = (planNo) => {
|
|||||||
item.delFlg = '0'
|
item.delFlg = '0'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
console.log('조회결과;', res.data)
|
setEstimateContextState(res.data)
|
||||||
console.log('수정시간;', res.data.lastEditDatetime)
|
|
||||||
setState(res.data)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
@ -83,17 +62,17 @@ export const useEstimateController = (planNo) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const updateItem = (dispOrder, updates) => {
|
const updateItem = (dispOrder, updates) => {
|
||||||
setState({
|
setEstimateContextState({
|
||||||
itemList: updateItemInList(state.itemList, dispOrder, updates),
|
itemList: updateItemInList(estimateContextState.itemList, dispOrder, updates),
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
const addItem = () => {
|
const addItem = () => {
|
||||||
let newItemDispOrder = Math.max(...state.itemList.map((item) => item.dispOrder))
|
let newItemDispOrder = Math.max(...estimateContextState.itemList.map((item) => item.dispOrder))
|
||||||
newItemDispOrder = (Math.floor(newItemDispOrder / 100) + 1) * 100
|
newItemDispOrder = (Math.floor(newItemDispOrder / 100) + 1) * 100
|
||||||
setState({
|
setEstimateContextState({
|
||||||
itemList: [
|
itemList: [
|
||||||
...state.itemList,
|
...estimateContextState.itemList,
|
||||||
{
|
{
|
||||||
objectNo: objectRecoil.floorPlanObjectNo,
|
objectNo: objectRecoil.floorPlanObjectNo,
|
||||||
planNo: planNo,
|
planNo: planNo,
|
||||||
@ -115,8 +94,8 @@ export const useEstimateController = (planNo) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
setEstimateData({ ...state, userId: session.userId, sapSalesStoreCd: session.custCd })
|
setEstimateData({ ...estimateContextState, userId: session.userId, sapSalesStoreCd: session.custCd })
|
||||||
}, [state])
|
}, [estimateContextState])
|
||||||
|
|
||||||
// 첨부파일 다운로드
|
// 첨부파일 다운로드
|
||||||
const handleEstimateFileDownload = async (originFile) => {
|
const handleEstimateFileDownload = async (originFile) => {
|
||||||
@ -206,7 +185,7 @@ export const useEstimateController = (planNo) => {
|
|||||||
return alert(getMessage('estimate.detail.save.requiredItem'))
|
return alert(getMessage('estimate.detail.save.requiredItem'))
|
||||||
}
|
}
|
||||||
|
|
||||||
// console.log('최종 정보::;', estimateData)
|
console.log('최종 정보::;', estimateData)
|
||||||
|
|
||||||
//2. 상세데이터 저장
|
//2. 상세데이터 저장
|
||||||
// return
|
// return
|
||||||
@ -256,8 +235,8 @@ export const useEstimateController = (planNo) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return {
|
return {
|
||||||
state,
|
estimateContextState,
|
||||||
setState,
|
setEstimateContextState,
|
||||||
updateItem,
|
updateItem,
|
||||||
addItem,
|
addItem,
|
||||||
handleEstimateSubmit,
|
handleEstimateSubmit,
|
||||||
|
|||||||
@ -823,6 +823,8 @@
|
|||||||
"estimate.detail.objectName": "案件名",
|
"estimate.detail.objectName": "案件名",
|
||||||
"estimate.detail.objectRemarks": "メモ",
|
"estimate.detail.objectRemarks": "メモ",
|
||||||
"estimate.detail.estimateType": "注文分類",
|
"estimate.detail.estimateType": "注文分類",
|
||||||
|
"estimate.detail.estimateType.yjss": "住宅PKG",
|
||||||
|
"estimate.detail.estimateType.yjod": "積上げ( YJOD )",
|
||||||
"estimate.detail.roofCns": "屋根材・仕様施工",
|
"estimate.detail.roofCns": "屋根材・仕様施工",
|
||||||
"estimate.detail.remarks": "備考",
|
"estimate.detail.remarks": "備考",
|
||||||
"estimate.detail.fileFlg": "後日資料提出",
|
"estimate.detail.fileFlg": "後日資料提出",
|
||||||
|
|||||||
@ -833,6 +833,8 @@
|
|||||||
"estimate.detail.objectName": "안건명",
|
"estimate.detail.objectName": "안건명",
|
||||||
"estimate.detail.objectRemarks": "메모",
|
"estimate.detail.objectRemarks": "메모",
|
||||||
"estimate.detail.estimateType": "주문분류",
|
"estimate.detail.estimateType": "주문분류",
|
||||||
|
"estimate.detail.estimateType.yjss": "住宅PKG",
|
||||||
|
"estimate.detail.estimateType.yjod": "積上げ( YJOD )",
|
||||||
"estimate.detail.roofCns": "지붕재・사양시공",
|
"estimate.detail.roofCns": "지붕재・사양시공",
|
||||||
"estimate.detail.remarks": "비고",
|
"estimate.detail.remarks": "비고",
|
||||||
"estimate.detail.fileFlg": "후일자료제출",
|
"estimate.detail.fileFlg": "후일자료제출",
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user