영문발주서 수정~

This commit is contained in:
2026-03-19 14:06:01 +09:00
parent 6bc46161e8
commit 7c540d109b

View File

@@ -172,6 +172,11 @@ input.date_icon {
.ui-jqgrid .select2-container--default .select2-selection--single .select2-selection__arrow {
height: 24px;
}
.ui-jqgrid tr.jqgrow td {
white-space: normal !important;
word-wrap: break-word;
word-break: break-all;
}
</style>
<script src="https://cdnjs.cloudflare.com/ajax/libs/html2canvas/1.4.1/html2canvas.min.js"></script>
@@ -192,6 +197,11 @@ $(document).ready(function(){
var unit_cd = $.parseJSON($("#unit_cd").val());
var currency_cd = $.parseJSON($("#currency_cd").val());
var _gridData = $.parseJSON($("#gridDetailList").val());
for(var i = 0; i < _gridData.length; i++) {
if(_gridData[i].SPEC && _gridData[i].SPEC.trim() !== '') {
_gridData[i].PART_NAME = _gridData[i].PART_NAME + '/' + _gridData[i].SPEC;
}
}
console.log("=== gridDetailList ===", JSON.stringify(_gridData));
console.log("=== currency_cd ===", JSON.stringify(currency_cd));
@@ -199,18 +209,17 @@ $(document).ready(function(){
url: ""
,datatype: "local"
,data: _gridData
,colNames: ["OBJID","PART_OBJID","Item No.","Commodity & Description","Spec","Unit","Q'ty","Currency","Unit Price","Amount","Delivery"]
,colNames: ["OBJID","PART_OBJID","Item No.","Commodity & Description","Unit","Q'ty","Currency","Unit Price","Amount","Delivery"]
,colModel: [
{name:"OBJID" , hidden: true, sortable:false, editable:false}
,{name:"PART_OBJID" , hidden: true, sortable:false, editable:false}
,{name:"PART_NO" , width:90, align:"center", sortable:false, editable:false}
,{name:"PART_NAME" , width:200, align:"left", sortable:false, editable:false}
,{name:"SPEC" , width:120, align:"left", sortable:false, editable:false}
,{name:"PART_NO" , width:120, align:"center", sortable:false, editable:false}
,{name:"PART_NAME" , width:260, align:"left", sortable:false, editable:false}
,{name:"UNIT" , width:50, align:"center", sortable:false, editable:<%= isModify %>
,edittype:"select", formatter:"select"
,editoptions:{ value: unit_cd }
}
,{name:"ORDER_QTY" , width:60, align:"right", sortable:false, editable:<%= isModify %>
,{name:"ORDER_QTY" , width:50, align:"right", sortable:false, editable:<%= isModify %>
,formatter:"integer", formatoptions:{thousandsSeparator:","}
,editoptions:{
dataInit: function(e){ e.style.textAlign = "right"; }
@@ -241,7 +250,7 @@ $(document).ready(function(){
,{name:"SUPPLY_UNIT_PRICE", width:90, align:"right", sortable:false, editable:false
,formatter:"number", formatoptions:{thousandsSeparator:",", decimalPlaces:2}
}
,{name:"DELIVERY_REQUEST_DATE", width:120, align:"center", sortable:false, editable:<%= isModify %>
,{name:"DELIVERY_REQUEST_DATE", width:90, align:"center", sortable:false, editable:<%= isModify %>
,editoptions:{
dataInit: function(elem) {
$(elem).datepicker({
@@ -308,8 +317,13 @@ $(document).ready(function(){
return MONTH_NAMES_EN[d.getMonth()] + ". " + ("0"+d.getDate()).slice(-2) + ". " + d.getFullYear();
}
// 저장값(hidden) → 표시값 초기 세팅
// 저장값(hidden) → 표시값 초기 세팅 (비어있으면 오늘 날짜)
var initDate = $("#PURCHASE_DATE").val();
if(!initDate || initDate.trim() === '') {
var today = new Date();
initDate = today.getFullYear() + '-' + ('0'+(today.getMonth()+1)).slice(-2) + '-' + ('0'+today.getDate()).slice(-2);
$("#PURCHASE_DATE").val(initDate);
}
$("#PURCHASE_DATE_DISPLAY").val(toEnglishDateDisplay(initDate));
$("#PURCHASE_DATE_DISPLAY").datepicker({
@@ -342,8 +356,7 @@ function fn_addRow(rowData){
var addData = {
"PART_OBJID" : rowData.map.PART_OBJID
,"PART_NO" : rowData.map.PART_NO
,"PART_NAME" : rowData.map.PART_NAME
,"SPEC" : rowData.map.SPEC
,"PART_NAME" : rowData.map.PART_NAME + (rowData.map.SPEC ? '/' + rowData.map.SPEC : '')
,"ORDER_QTY" : v1
,"UNIT" : fnc_checkNullDefaultValue(rowData.map.UNIT, '0001400')
,"CURRENCY" : "0001534"