Переглянути джерело

Merge remote-tracking branch 'refs/remotes/origin/master'

wngur6076 1 місяць тому
батько
коміт
bdb7ef181f

+ 0 - 169
public/css/all.min.css

@@ -2415,13 +2415,6 @@ border-radius:.25rem;
 a.btn.disabled, fieldset:disabled a.btn {
 	pointer-events: none
 }
-<<<<<<< HEAD
-
-.btn-group-sm>.btn, 
-.btn-sm {min-width: 3.250rem; padding: .3125rem .75rem; font-size: .8125rem; line-height: 1.6924; border-radius: .1875rem;}
-
-=======
->>>>>>> refs/remotes/origin/master
 .btn-primary {
 	color: #fff;
 	background-color:#5c6bc0;
@@ -29595,10 +29588,6 @@ body {
 	overflow-y: auto;
 	-webkit-overflow-scrolling: touch;
 }
-<<<<<<< HEAD
-
-=======
->>>>>>> refs/remotes/origin/master
 @media (prefers-reduced-motion:no-preference) {
 .content-inner {
 	scroll-behavior: smooth
@@ -31531,164 +31520,6 @@ a:focus {    outline: 0;}
 
 .post-tabbed .tab-pane {padding:0.625rem 0;}
 
-<<<<<<< HEAD
-/*프린트 상품등록*/
-.blanker_item .btn-group-sm>.btn, 
-.blanker_item .btn-sm {height:32px; padding: 2px 0.625rem;/*.3125rem .75rem;*/ font-size: 13px; line-height:1; border-radius:5px;}
-.blanker_item .guide,
-.blanker_item .setsize_wrap,
-.editor_wrap  > div,
-.option_wrap  > div {margin-right:32px;}
-.head_btn_add {color:var(--basic-hover);}
-.backslash {width:287px; background-image: linear-gradient(to left bottom, transparent calc(50% - 1px), #ddd, transparent calc(50% + 1px)); background-size: 120% 120%; background-position: center;}
-.backslash div {display:flex; align-items:center; height:50%;}
-.backslash > div:first-child {justify-content:flex-end;}
-.backslash input {margin-left:6px;}
-.backslash a {margin-top:10px;}
-#topAnchor {height:0.5rem; margin-top:-0.5rem;}
-.blanker_item .contents_wrap {margin-top:0;}
-.blanker_item.content {padding-top:0;}
-.blanker_item .topbtn_wrap {position: sticky; top: 0; left: 0; z-index: 110; background: #f6f6f6;}
-.blanker_item .btn-groups {margin-top:-2rem; padding-top:0.625rem; padding-bottom:0.625rem; }
-.blanker_item .anchor {height:101px; margin-top:-101px;}
-.blanker_item .tabs_wrap {position:sticky; top:56px; left:0; margin:-11px; padding:10px; padding-top:0; border: 1px solid rgba(0, 0, 0, .125); border-bottom:0; border-top-left-radius:.25rem; border-top-right-radius:.25rem; overflow:hidden; z-index: 10; background:#fff;}
-.blanker_item .tab-content>.tab-pane {display:block; opacity:1;}
-.blanker_item .card {padding:12px; margin-top:12px;}
-.blanker_item .ptxt_wrap {position: absolute; padding:6px; margin: 5px; display: none; background-color:#5c6bc0; border-radius:5px; z-index:10;}
-.blanker_item .table-responsive {overflow-x: auto;}
-.blanker_item input,
-.blanker_item tbody input[type="text"] {border-radius: .25rem;}
-.blanker_item tbody input[type="text"] {width:auto!important;}
-.blanker_item input::placeholder {color:#787878;}
-.blanker_item ul,
-.blanker_item li {padding:0; margin:0; list-style:none;}
-.blanker_item .stit {display:flex; align-items:center; gap:10px; margin-bottom:10px;}
-.blanker_item .stit h3 {margin-bottom:0; font-weight:700; color:#191919; font-size:14px; }
-.blanker_item .tab-pane {padding:20px 3px;}
-.blanker_item .stit h3 span {font-weight:400;}
-.blanker_item .guide {display:flex; gap:60px; margin-bottom:12px; padding:12px; background-color: #fff; background-clip: border-box;  border: 1px solid rgba(0, 0, 0, .125);   border-radius: .25rem; word-wrap: break-word;}
-.blanker_item .guide dt,
-.blanker_item .guide li {position:relative; padding-left:10px; font-weight:500; color:var(--black);}
-.blanker_item .guide dt:before,
-.blanker_item .guide li:before {content:""; position:absolute; top:7px; left:0; width:4px; height:4px; background:var(--black); border-radius:50px;}
-.blanker_item .guide dd {margin-bottom:3px;}
-.blanker_item .guide dd strong {font-weight:400; color:var(--danger);}
-.blanker_item .guide .txt_sm {margin-top:10px; color:var(--basic-hover);}
-.blanker_item .guide ul {margin-bottom:1rem;}
-
-#pheader1 > td:last-child > div {position:relative; max-width:1230px; text-align:center;}
-.stock_table2 .p_img_area {text-align: left;width: 78px;display: inline-block}
-.stock_table2 .p_img_icon > img {width: 21px; 	height: 21px; cursor: pointer;vertical-align: middle}
-
-.p_tbl_header {background:#f6f6f6;}
-.p_tbl_header,
-.p_tbl_row1 {border-collapse: collapse; table-layout: fixed; width: max-content; border:1px solid #ddd;}
-.p_tbl_header td {padding:8px 5px; border:1px solid #ddd; vertical-align:top;}
-.p_tbl_header td .position-absolute {top:50%; left:5px; transform:translateY(-50%); display: flex;  align-items: center;}
-.p_tbl_header td .position-absolute i {margin-left:6px;}
-.p_tbl_header td > input:first-of-type {margin-top:4px;}
-
-.p_tbl_header .set_qty,
-.p_img_area a,
-.p_text_area a {position:relative; display:inline-block; color:var(--txt-hover); text-decoration:underline;}
-.p_text_area {position:relative;}
-.p_tbl_header .btn_cls {position:relative;}
-.p_tbl_header .btn_cls a {position:absolute; top:-50px; right:0;}
-.p_tbl_header .row {display:block; margin:4px 0; text-align:left;}
-
-.ctl_amount {display: inline-block; vertical-align: middle; font-size: 14px;}
-.ctl_amount i {display:block; margin-left: 2px;}
-
-#pheader2 > td {width:205px; font-size:12px;	}
-tbody input[type="text"].pn
-tbody input[type="text"].row_nk {width:90px!important;}
-tbody input[type="text"].pc1, 
-tbody input[type="text"].pc2, 
-tbody input[type="text"].pw1, 
-tbody input[type="text"].pw2 {width:44px!important;}
-
-.p_tbl_row1 {border-top: none}
-.p_tbl_row1 .p_img_area {width:auto; margin-left:2px;}
-.p_tbl_row1_td1 {position:relative; padding: 5px;  width:116px}
-.p_tbl_row1_td2 {border-left:1px solid #ddd;}
-.p_tbl_row3, .p_tbl_row4 {border-collapse: collapse; table-layout: fixed; border-top: 1px solid #ddd;}
-.p_tbl_row2_td1 {width: 170px;}
-.p_tbl_row2_td1 > input {width:90px!important;}
-.p_tbl_row2_td2 {width: 205px; border-left: 1px solid #ddd;}
-.p_tbl_val2 {border-bottom:1px solid #ddd;}
-.p_tbl_row1_td2_tbl_last,
-.table-responsive > table:nth-of-type(2) .p_tbl_val2:last-of-type,
-.stock_table2 > table:nth-of-type(2) .p_tbl_val2:last-of-type {border-bottom: none}
-
-.on11_opt_type {margin-top:10px;}
-.p_tbl_row2 td, .p_tbl_row3 td, .p_tbl_row4 td {padding: 5px;}
-.p_tbl_row4 .size_div_btn, .p_tbl_row4 .pp {display: none	}
-.p_tbl_row4 {height: 32px}						
-
-.stock_table2 .pr {display: none}
-.stock_table2 .pfo {display: none}
-.stock_table2 .pfd {display: none}
-.stock_table2 .pf {display: none}
-.stock_table2 .pp {width: 90px;}
-.stock_table2 .p_text_icon {
-	display: inline-block;
-	border: 1px solid #CCC;
-	border-radius: 5px;
-	width: 15px;
-	height: 15px;
-	background-color: #EEE;
-	text-align: center
-}
-
-.stock_table2 .p_text_area {
-	height: 25px;
-}
-.stock_table2 .p3v {
-	display: none
-}
-.stock_table2 .size_div_btn {
-	cursor: pointer
-}						
-
-.row2_td1_spc1 {
-	width: 10px;
-	display: inline-block
-}
-.row2_td1_spc2 {
-	width: 25px;
-	display: inline-block
-}
-
-.blanker_item .setsize_wrap {gap:80px;}
-.blanker_item .setsize_wrap .text-orange-700{margin:12px 0;}
-.blanker_item .setsize_wrap a {line-height:28px;}
-.blanker_item .setsize_wrap > div {position:relative;}
-.blanker_item .setsize_wrap > div:first-child:after {content:"\f0da"; font-family: "Font Awesome 5 Free"; font-weight: 900; position:absolute; top:50%; right:-45px; transform:translateY(-50%); color:#ccc; font-size:24px;}
-.set_size input[type="text"] {width:auto!important;}
-.set_size .stit h4 {display:inline-block; font-weight:700; color:var(--danger); font-size:14px;}
-.set_size .stit span {color:var(--black); font-weight:500;}
-.set_size ul {display:flex; align-items:center; gap:20px; margin-top:12px;}
-.set_size dl {display:flex; align-items:center;  gap:10px; color:#666;}
-.set_size dt {margin-bottom:0;}
-
-.blanker_item .editor_wrap .d-flex {flex-wrap:wrap; gap:8px;}
-.blanker_item .editor_wrap .btn {height:28px;}
-
-.blanker_item .option_wrap .tit {gap:10px; padding:12px; background:#f6f6f6;}
-.blanker_item .option_wrap .card {align-items: flex-start; padding:0; padding-bottom:12px;}
-.blanker_item .hu_cnts .card {margin-bottom:0;}
-.blanker_item .hu_cnts table:first-of-type .card {margin-top:12px;}
-.blanker_item .hu_cnts th {width:165px; padding:12px; padding-top:22px; vertical-align:top;}
-.blanker_item .option_wrap a.btn {line-height:28px;}
-.blanker_item .option_wrap .top_tb {width:100%;}
-.blanker_item .option_wrap .top_tb td {padding:12px; background:#f6f6f6;}
-.blanker_item .option_wrap .top_tb .btn_del {position:absolute; right:10px;}
-.blanker_item .sortable0 table tr td,
-.blanker_item .row_tb tr td {padding-left:12px; padding-right:12px;}
-.blanker_item .row_tb tr td td {padding-left:0; padding-right:0;}
-
-=======
->>>>>>> refs/remotes/origin/master
 @media (max-width:1440px) {
 	.m_searchbox {max-width:30%;}
 }

+ 42 - 12
resources/views/front/dabory/erp/basic-settings/monthly-settle.blade.php

@@ -4,7 +4,6 @@
     <div class="content">
         <div class="row">
             <div class="col-xl-12">
-                <h2>{{ $formA['General']['Title'] }}</h2>
                 <div class="card" id="monthly-settle-form">
                     <div class="card-body mt-2" id="frm">
                         <input type="hidden" id="Id" name="Id" value="0">
@@ -31,13 +30,13 @@
                         </div>
 
                         <div class="form-group mb-3" {{ $formA['FormVars']['Hidden']['YyyyMm'] }}>
-                            <label>{{ $formA['FormVars']['Title']['YyyyMm'] }}</label>
+                            <label class="m-0">{{ $formA['FormVars']['Title']['YyyyMm'] }}</label>
                             <br>
-                            <input type="text" id="yyyy-txt" data-copy="true"
+                            <input type="text" class="rounded w-sm-auto" id="yyyy-txt" data-copy="true"
                                 maxlength="{{ $formA['FormVars']['MaxLength']['YyyyMm'] }}"
-                                {{ $formA['FormVars']['Required']['YyyyMm'] }}>
+                                {{ $formA['FormVars']['Required']['YyyyMm'] }}>&nbsp;&nbsp;년&nbsp;&nbsp;
                             @php $todayMonth = date('n');@endphp
-                            <select id = "mm-select">
+                            <select id = "mm-select" class="rounded">
                                 @foreach($monthArr as $index => $month)
                                     <option value="{{ $index + 1 }}" @if($todayMonth == $index + 1) selected @endif>
                                         {{ $month }}
@@ -90,7 +89,7 @@
                 });
             });
 
-            console.log('parameters : ', parameters);
+            // console.log(parameters);
             return parameters;
         }
 
@@ -114,28 +113,59 @@
             $('#monthly-settle-form').find('#monthly_settle-name-txt').val(monthly_settle.IgroupName)
             $('#monthly-settle-form').find('#monthly_settle-code-txt').val(monthly_settle.IgroupCode)
             $('#monthly-settle-form').find('#monthly_settle-slug-txt').val(monthly_settle.IgroupSlug)
-            $(`input:radio[name=is-end-level]:input[value=${monthly_settle.IsEndLevel}]`).prop('checked', true);
 
             $('#modal-setting_monthly_settle').modal('hide');
         }
 
-        MonthlySettleForm.btn_re_cal = async function () {
+        MonthlySettleForm.change_tbl_name = async function (tbl_name) {
+            let check_name;
+            switch(tbl_name){
+                case "bal_buyer":
+                    check_name = "{{ $formA['FormVars']['Title']['IsBalBuyer'] }}"
+                    break;
+                case "bal_supplier":
+                    check_name = "{{ $formA['FormVars']['Title']['IsBalSupplier'] }}"
+                    break;
+                case "bal_item":
+                    check_name = "{{ $formA['FormVars']['Title']['IsBalItem'] }}"
+                    break;
+                case "bal_reward":
+                    check_name = "{{ $formA['FormVars']['Title']['IsBalReward'] }}"
+                    break;
+                case "bal_credit":
+                    check_name = "{{ $formA['FormVars']['Title']['IsBalCredit'] }}"
+                    break;
+            }
+            return check_name;
+        }
+
+        MonthlySettleForm.check_input = async function (parameters) {
             if ($('#yyyy-txt').val() == '') {
                 return iziToast.error({ title: 'Error', message: '정산년도를 입력해주세요. ex)2024' });
             }
+            if(parameters.length == 0){
+                return iziToast.error({ title: 'Error', message: '체크박스를 1개이상 체크해주세요.' });
+            }
+        }
 
+        MonthlySettleForm.btn_re_cal = async function () {
             const parameters = MonthlySettleForm.parameter();
+            MonthlySettleForm.check_input(parameters);
 
             for (const parameter of parameters) {
                 const response = await get_api_data('monthly-settle', parameter);
-
+                // const table_name = parameter['TableName'];
+                const table_name = await MonthlySettleForm.change_tbl_name(parameter['TableName']);
+                console.log('table_name : ', table_name);
                 if (response && response.data.apiStatus) {
+                    const status = response.data.apiStatus;
+                    const message = response.data.body;
                     console.log(response);
-                    return iziToast.error({ title: 'Error', message: 'API Error' });
+                    return iziToast.error({ title: 'Error', message: `${table_name} : ${status}, ${message}` });
                 }
 
-                iziToast.success({ title: 'Success', message: '재정산 완료' });
-                console.log(response);
+                iziToast.success({ title: 'Success', message: `${table_name} 완료` });
+                // console.log(response);
             }
         };