refac: linter 관련 설정 변경 및 적용, map_theme 변수 제거
- eslint에 prettier 조합 - prettierrc에 width 120, tabWidth 2 - gameStor->map_theme 제거 - map_theme, mapTheme를 GameConst::$mapName으로 대체 - eslint에서 vue/vue3-essential 대신 vue3-recommended 적용 - vue/max-attributes-per-line 완화 - vue/v-on-event-hyphenation 해제 - vue/attribute-hyphenation 해제 - 일부 tsc import type warning 해결 - 일부 vue template type warning 해결 - 일부 vue SFC를 script setup으로 변경 - TipTap - TopBackBar - BottomBackBar - BoardArticle - ProcessCity
This commit is contained in:
+83
-197
@@ -3,7 +3,7 @@
|
||||
<BContainer
|
||||
id="container"
|
||||
class="tb_layout bg0"
|
||||
:toast="{root: true}"
|
||||
:toast="{ root: true }"
|
||||
:style="{ maxWidth: '1000px', margin: 'auto', border: 'solid 1px #888888', padding: '0' }"
|
||||
>
|
||||
<div class="bg1 section_bar">국가 정책</div>
|
||||
@@ -17,94 +17,54 @@
|
||||
<div class="form_list row row-cols-md-2 row-cols-1">
|
||||
<div class="col">
|
||||
<NumberInputWithInfo v-model="nationPolicy.reqNationGold" :step="100" title="국가 권장 금">
|
||||
이보다 많으면 포상, 적으면 몰수/헌납합니다.(긴급포상
|
||||
제외)
|
||||
이보다 많으면 포상, 적으면 몰수/헌납합니다.(긴급포상 제외)
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
<NumberInputWithInfo v-model="nationPolicy.reqNationRice" :step="100" title="국가 권장 쌀">
|
||||
이보다 많으면 포상, 적으면 몰수/헌납합니다.(긴급포상
|
||||
제외)
|
||||
이보다 많으면 포상, 적으면 몰수/헌납합니다.(긴급포상 제외)
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
<NumberInputWithInfo
|
||||
v-model="nationPolicy.reqHumanWarUrgentGold"
|
||||
:step="100"
|
||||
title="유저전투장 긴급포상 금"
|
||||
>
|
||||
<NumberInputWithInfo v-model="nationPolicy.reqHumanWarUrgentGold" :step="100" title="유저전투장 긴급포상 금">
|
||||
유저장긴급포상시 이보다 금이 적은 장수에게 포상합니다.
|
||||
<br />
|
||||
0이면
|
||||
보병 6회 징병({{ (defaultStatMax * 100).toLocaleString() }} * 6)
|
||||
가능한 금을 기준으로 하며, 그 수치는 현재
|
||||
{{
|
||||
zeroPolicy.reqHumanWarUrgentGold.toLocaleString()
|
||||
}}입니다.
|
||||
0이면 보병 6회 징병({{ (defaultStatMax * 100).toLocaleString() }} * 6) 가능한 금을 기준으로 하며, 그 수치는
|
||||
현재 {{ zeroPolicy.reqHumanWarUrgentGold.toLocaleString() }}입니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
<NumberInputWithInfo
|
||||
v-model="nationPolicy.reqHumanWarUrgentRice"
|
||||
:step="100"
|
||||
title="유저전투장 긴급포상 쌀"
|
||||
>
|
||||
<NumberInputWithInfo v-model="nationPolicy.reqHumanWarUrgentRice" :step="100" title="유저전투장 긴급포상 쌀">
|
||||
유저장긴급포상시 이보다 쌀이 적은 장수에게 포상합니다.
|
||||
<br />
|
||||
0이면
|
||||
기본 병종으로 {{ (defaultStatMax * 100).toLocaleString() }} * 6명 사살
|
||||
가능한 쌀을 기준으로 하며, 그 수치는 현재
|
||||
{{
|
||||
zeroPolicy.reqHumanWarUrgentRice.toLocaleString()
|
||||
}}입니다.
|
||||
0이면 기본 병종으로 {{ (defaultStatMax * 100).toLocaleString() }} * 6명 사살 가능한 쌀을 기준으로 하며, 그
|
||||
수치는 현재 {{ zeroPolicy.reqHumanWarUrgentRice.toLocaleString() }}입니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
<NumberInputWithInfo
|
||||
v-model="nationPolicy.reqHumanWarRecommandGold"
|
||||
:step="100"
|
||||
title="유저전투장 권장 금"
|
||||
>
|
||||
<NumberInputWithInfo v-model="nationPolicy.reqHumanWarRecommandGold" :step="100" title="유저전투장 권장 금">
|
||||
유저전투장에게 주는 금입니다. 이보다 적으면 포상합니다.
|
||||
<br />
|
||||
0이면 유저전투장 긴급포상 금의 2배를 기준으로 하며, 그 수치는 현재
|
||||
{{
|
||||
(calcPolicyValue("reqHumanWarUrgentGold") * 2).toLocaleString()
|
||||
}}입니다.
|
||||
{{ (calcPolicyValue("reqHumanWarUrgentGold") * 2).toLocaleString() }}입니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
<NumberInputWithInfo
|
||||
v-model="nationPolicy.reqHumanWarRecommandRice"
|
||||
:step="100"
|
||||
title="유저전투장 권장 쌀"
|
||||
>
|
||||
<NumberInputWithInfo v-model="nationPolicy.reqHumanWarRecommandRice" :step="100" title="유저전투장 권장 쌀">
|
||||
유저전투장에게 주는 쌀입니다. 이보다 적으면 포상합니다.
|
||||
<br />
|
||||
0이면 유저전투장 긴급포상 쌀의 2배를 기준으로 하며, 그 수치는 현재
|
||||
{{
|
||||
(calcPolicyValue("reqHumanWarUrgentRice") * 2).toLocaleString()
|
||||
}}입니다.
|
||||
{{ (calcPolicyValue("reqHumanWarUrgentRice") * 2).toLocaleString() }}입니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
<NumberInputWithInfo
|
||||
v-model="nationPolicy.reqHumanDevelGold"
|
||||
:step="100"
|
||||
title="유저내정장 권장 금"
|
||||
>
|
||||
유저내정장에게 주는 금입니다. 이보다 적으면
|
||||
포상합니다.
|
||||
<NumberInputWithInfo v-model="nationPolicy.reqHumanDevelGold" :step="100" title="유저내정장 권장 금">
|
||||
유저내정장에게 주는 금입니다. 이보다 적으면 포상합니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
<NumberInputWithInfo
|
||||
v-model="nationPolicy.reqHumanDevelRice"
|
||||
:step="100"
|
||||
title="유저내정장 권장 쌀"
|
||||
>
|
||||
유저내정장에게 주는 쌀입니다. 이보다 적으면
|
||||
포상합니다.
|
||||
<NumberInputWithInfo v-model="nationPolicy.reqHumanDevelRice" :step="100" title="유저내정장 권장 쌀">
|
||||
유저내정장에게 주는 쌀입니다. 이보다 적으면 포상합니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
@@ -113,9 +73,7 @@
|
||||
<br />
|
||||
0이면 기본 병종 4회({{ (defaultStatNPCMax * 100).toLocaleString() }}
|
||||
* 4) 징병비를 기준으로 하며, 그 수치는 현재
|
||||
{{
|
||||
zeroPolicy.reqNPCWarGold.toLocaleString()
|
||||
}}입니다.
|
||||
{{ zeroPolicy.reqNPCWarGold.toLocaleString() }}입니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
@@ -123,26 +81,21 @@
|
||||
NPC전투장에게 주는 쌀입니다. 이보다 적으면 포상합니다.
|
||||
<br />
|
||||
0이면 기본 병종으로
|
||||
{{ (defaultStatNPCMax * 100).toLocaleString() }} * 4명 사살 가능한
|
||||
쌀을 기준으로 하며, 그 수치는 현재
|
||||
{{
|
||||
zeroPolicy.reqNPCWarRice.toLocaleString()
|
||||
}}입니다.
|
||||
{{ (defaultStatNPCMax * 100).toLocaleString() }} * 4명 사살 가능한 쌀을 기준으로 하며, 그 수치는 현재
|
||||
{{ zeroPolicy.reqNPCWarRice.toLocaleString() }}입니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
<NumberInputWithInfo v-model="nationPolicy.reqNPCDevelGold" :step="100" title="NPC내정장 권장 금">
|
||||
NPC내정장에게 주는 금입니다. 이보다 5배 더 많다면 헌납합니다.
|
||||
<br />
|
||||
0이면
|
||||
30턴 내정 가능한 금을 기준으로 하며, 그 수치는 현재
|
||||
0이면 30턴 내정 가능한 금을 기준으로 하며, 그 수치는 현재
|
||||
{{ zeroPolicy.reqNPCDevelGold }}입니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
<NumberInputWithInfo v-model="nationPolicy.reqNPCDevelRice" :step="100" title="NPC내정장 권장 쌀">
|
||||
NPC내정장에게 주는 쌀입니다. 이보다 5배 더 많다면
|
||||
헌납합니다.
|
||||
NPC내정장에게 주는 쌀입니다. 이보다 5배 더 많다면 헌납합니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
@@ -150,21 +103,23 @@
|
||||
v-model="nationPolicy.minimumResourceActionAmount"
|
||||
:step="100"
|
||||
title="포상/몰수/헌납/삼/팜 최소 단위"
|
||||
>연산결과가 이 단위보다 적다면 수행하지 않습니다.</NumberInputWithInfo>
|
||||
>
|
||||
연산결과가 이 단위보다 적다면 수행하지 않습니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
<NumberInputWithInfo
|
||||
v-model="nationPolicy.maximumResourceActionAmount"
|
||||
:step="100"
|
||||
title="포상/몰수/헌납/삼/팜 최대 단위"
|
||||
>연산결과가 이 단위보다 크다면, 이 값에 맞춥니다.</NumberInputWithInfo>
|
||||
>
|
||||
연산결과가 이 단위보다 크다면, 이 값에 맞춥니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
<NumberInputWithInfo
|
||||
v-model="nationPolicy.minWarCrew"
|
||||
:step="50"
|
||||
title="최소 전투 가능 병력 수"
|
||||
>이보다 적을 때에는 징병을 시도합니다.</NumberInputWithInfo>
|
||||
<NumberInputWithInfo v-model="nationPolicy.minWarCrew" :step="50" title="최소 전투 가능 병력 수">
|
||||
이보다 적을 때에는 징병을 시도합니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
<NumberInputWithInfo
|
||||
@@ -172,38 +127,27 @@
|
||||
:step="100"
|
||||
title="NPC 최소 징병 가능 인구 수"
|
||||
>
|
||||
도시의 인구가 이보다 낮으면 NPC는 도시에서 징병하지 않고 후방
|
||||
워프합니다.
|
||||
<br />NPC의 최대 병력수보다 낮게 설정하면 제자리에서
|
||||
정착장려를 합니다.
|
||||
도시의 인구가 이보다 낮으면 NPC는 도시에서 징병하지 않고 후방 워프합니다.
|
||||
<br />NPC의 최대 병력수보다 낮게 설정하면 제자리에서 정착장려를 합니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
<NumberInputWithInfo
|
||||
:modelValue="nationPolicy.safeRecruitCityPopulationRatio * 100"
|
||||
@update:modelValue="
|
||||
nationPolicy.safeRecruitCityPopulationRatio = $event / 100
|
||||
"
|
||||
:step="0.5"
|
||||
:int="false"
|
||||
:min="0"
|
||||
:max="100"
|
||||
title="제자리 징병 허용 인구율(%)"
|
||||
@update:modelValue="nationPolicy.safeRecruitCityPopulationRatio = $event / 100"
|
||||
>
|
||||
전쟁 시 후방 발령, 후방 워프의 기준 인구입니다. 이보다 많다면
|
||||
'충분하다'고 판단합니다.
|
||||
<br />NPC의 최대 병력수보다 낮게 설정하면
|
||||
제자리에서 정착장려를 합니다.
|
||||
전쟁 시 후방 발령, 후방 워프의 기준 인구입니다. 이보다 많다면 '충분하다'고 판단합니다.
|
||||
<br />NPC의 최대 병력수보다 낮게 설정하면 제자리에서 정착장려를 합니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
<NumberInputWithInfo
|
||||
v-model="nationPolicy.minNPCWarLeadership"
|
||||
:step="5"
|
||||
title="NPC 전투 참여 통솔 기준"
|
||||
>
|
||||
이 수치보다 같거나 높으면 NPC전투장으로
|
||||
분류됩니다.
|
||||
<NumberInputWithInfo v-model="nationPolicy.minNPCWarLeadership" :step="5" title="NPC 전투 참여 통솔 기준">
|
||||
이 수치보다 같거나 높으면 NPC전투장으로 분류됩니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<div class="col">
|
||||
@@ -214,44 +158,27 @@
|
||||
:max="100"
|
||||
title="훈련/사기진작 목표치"
|
||||
>
|
||||
훈련/사기진작 기준치입니다. 이보다 같거나 높으면
|
||||
출병합니다.
|
||||
훈련/사기진작 기준치입니다. 이보다 같거나 높으면 출병합니다.
|
||||
</NumberInputWithInfo>
|
||||
</div>
|
||||
<!--allowNpcAttackCity는 현재 게임 내 비활성-->
|
||||
</div>
|
||||
<div style="padding: 0 8pt">
|
||||
<div class="alert alert-secondary">
|
||||
전투 부대는 작업중입니다(json양식:
|
||||
{부대번호:[시작도시번호(아국),도착도시번호(적군)],...})
|
||||
<br />후방 징병 부대는 작업중입니다(json양식: [부대번호,...])
|
||||
<br />내정 부대는 작업중입니다(json양식: [부대번호,...])
|
||||
<input
|
||||
type="hidden"
|
||||
:value="JSON.stringify(nationPolicy.CombatForce)"
|
||||
data-type="json"
|
||||
id="CombatForce"
|
||||
/>
|
||||
<input
|
||||
type="hidden"
|
||||
:value="JSON.stringify(nationPolicy.SupportForce)"
|
||||
data-type="json"
|
||||
id="SupportForce"
|
||||
/>
|
||||
<input
|
||||
type="hidden"
|
||||
:value="JSON.stringify(nationPolicy.DevelopForce)"
|
||||
data-type="json"
|
||||
id="DevelopForce"
|
||||
/>
|
||||
전투 부대는 작업중입니다(json양식: {부대번호:[시작도시번호(아국),도착도시번호(적군)],...})
|
||||
<br />후방 징병 부대는 작업중입니다(json양식: [부대번호,...]) <br />내정 부대는 작업중입니다(json양식:
|
||||
[부대번호,...])
|
||||
<input id="CombatForce" type="hidden" :value="JSON.stringify(nationPolicy.CombatForce)" data-type="json" />
|
||||
<input id="SupportForce" type="hidden" :value="JSON.stringify(nationPolicy.SupportForce)" data-type="json" />
|
||||
<input id="DevelopForce" type="hidden" :value="JSON.stringify(nationPolicy.DevelopForce)" data-type="json" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="control_bar" data-type="nationPolicy">
|
||||
<div class="btn-group" role="group">
|
||||
<button type="button" @click="resetPolicy" class="btn btn-dark reset_btn">초기값으로</button>
|
||||
<button type="button" @click="rollbackPolicy" class="btn btn-secondary revert_btn">이전값으로</button>
|
||||
<button type="button" class="btn btn-dark reset_btn" @click="resetPolicy">초기값으로</button>
|
||||
<button type="button" class="btn btn-secondary revert_btn" @click="rollbackPolicy">이전값으로</button>
|
||||
</div>
|
||||
<button type="button" @click="submitPolicy" class="btn btn-primary submit_btn">설정</button>
|
||||
<button type="button" class="btn btn-primary submit_btn" @click="submitPolicy">설정</button>
|
||||
</div>
|
||||
<div class="row row-cols-md-2 row-cols-1 g-0">
|
||||
<div class="col half_section_left">
|
||||
@@ -266,8 +193,7 @@
|
||||
<div class="text-left px-2">
|
||||
<small class="text-muted">
|
||||
예턴이 없거나, 지정되어 있더라도 실패하면
|
||||
<br />아래 순위에 따라
|
||||
사령턴을 시도합니다.
|
||||
<br />아래 순위에 따라 사령턴을 시도합니다.
|
||||
</small>
|
||||
</div>
|
||||
<div>
|
||||
@@ -285,16 +211,14 @@
|
||||
</template>
|
||||
<template #item="{ element }">
|
||||
<div class="list-group-item">
|
||||
<i class="bi bi-list"></i>
|
||||
{{
|
||||
element.id
|
||||
}}
|
||||
<i class="bi bi-list" />
|
||||
{{ element.id }}
|
||||
<button
|
||||
class="btn btn-sm float-right btn-secondary py-0 px-1"
|
||||
v-b-tooltip.hover
|
||||
class="btn btn-sm float-right btn-secondary py-0 px-1"
|
||||
:title="actionHelpText[element.id]"
|
||||
>
|
||||
<i class="bi bi-question-lg"></i>
|
||||
<i class="bi bi-question-lg" />
|
||||
</button>
|
||||
</div>
|
||||
</template>
|
||||
@@ -310,16 +234,14 @@
|
||||
>
|
||||
<template #item="{ element }">
|
||||
<div class="list-group-item">
|
||||
<i class="bi bi-list"></i>
|
||||
{{
|
||||
element.id
|
||||
}}
|
||||
<i class="bi bi-list" />
|
||||
{{ element.id }}
|
||||
<button
|
||||
class="btn btn-sm float-right btn-secondary py-0 px-1"
|
||||
v-b-tooltip.hover
|
||||
class="btn btn-sm float-right btn-secondary py-0 px-1"
|
||||
:title="actionHelpText[element.id]"
|
||||
>
|
||||
<i class="bi bi-question-lg"></i>
|
||||
<i class="bi bi-question-lg" />
|
||||
</button>
|
||||
</div>
|
||||
</template>
|
||||
@@ -328,22 +250,12 @@
|
||||
</div>
|
||||
<div class="control_bar" data-type="nationPriority">
|
||||
<div class="btn-group" role="group">
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-dark reset_btn"
|
||||
@click="resetNationPriority"
|
||||
>초기값으로</button>
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-secondary revert_btn"
|
||||
@click="rollbackNationPriority"
|
||||
>이전값으로</button>
|
||||
<button type="button" class="btn btn-dark reset_btn" @click="resetNationPriority">초기값으로</button>
|
||||
<button type="button" class="btn btn-secondary revert_btn" @click="rollbackNationPriority">
|
||||
이전값으로
|
||||
</button>
|
||||
</div>
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-primary submit_btn"
|
||||
@click="submitNationPriority"
|
||||
>설정</button>
|
||||
<button type="button" class="btn btn-primary submit_btn" @click="submitNationPriority">설정</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -359,8 +271,7 @@
|
||||
<div class="text-left px-2">
|
||||
<small class="text-muted">
|
||||
순위가 높은 것부터 시도합니다.
|
||||
<br />아무것도 실행할 수 없으면
|
||||
물자조달이나 인재탐색을 합니다.
|
||||
<br />아무것도 실행할 수 없으면 물자조달이나 인재탐색을 합니다.
|
||||
</small>
|
||||
</div>
|
||||
<div>
|
||||
@@ -378,16 +289,14 @@
|
||||
</template>
|
||||
<template #item="{ element }">
|
||||
<div class="list-group-item">
|
||||
<i class="bi bi-list"></i>
|
||||
{{
|
||||
element.id
|
||||
}}
|
||||
<i class="bi bi-list" />
|
||||
{{ element.id }}
|
||||
<button
|
||||
class="btn btn-sm float-right btn-secondary py-0 px-1"
|
||||
v-b-tooltip.hover
|
||||
class="btn btn-sm float-right btn-secondary py-0 px-1"
|
||||
:title="actionHelpText[element.id]"
|
||||
>
|
||||
<i class="bi bi-question-lg"></i>
|
||||
<i class="bi bi-question-lg" />
|
||||
</button>
|
||||
</div>
|
||||
</template>
|
||||
@@ -403,16 +312,14 @@
|
||||
>
|
||||
<template #item="{ element }">
|
||||
<div class="list-group-item">
|
||||
<i class="bi bi-list"></i>
|
||||
{{
|
||||
element.id
|
||||
}}
|
||||
<i class="bi bi-list" />
|
||||
{{ element.id }}
|
||||
<button
|
||||
class="btn btn-sm float-right btn-secondary py-0 px-1"
|
||||
v-b-tooltip.hover
|
||||
class="btn btn-sm float-right btn-secondary py-0 px-1"
|
||||
:title="actionHelpText[element.id]"
|
||||
>
|
||||
<i class="bi bi-question-lg"></i>
|
||||
<i class="bi bi-question-lg" />
|
||||
</button>
|
||||
</div>
|
||||
</template>
|
||||
@@ -421,22 +328,12 @@
|
||||
</div>
|
||||
<div class="control_bar" data-type="generalPriority">
|
||||
<div class="btn-group" role="group">
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-dark reset_btn"
|
||||
@click="resetGeneralPriority"
|
||||
>초기값으로</button>
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-secondary revert_btn"
|
||||
@click="rollbackGeneralPriority"
|
||||
>이전값으로</button>
|
||||
<button type="button" class="btn btn-dark reset_btn" @click="resetGeneralPriority">초기값으로</button>
|
||||
<button type="button" class="btn btn-secondary revert_btn" @click="rollbackGeneralPriority">
|
||||
이전값으로
|
||||
</button>
|
||||
</div>
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-primary submit_btn"
|
||||
@click="submitGeneralPriority"
|
||||
>설정</button>
|
||||
<button type="button" class="btn btn-primary submit_btn" @click="submitGeneralPriority">설정</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -444,7 +341,6 @@
|
||||
</BContainer>
|
||||
</template>
|
||||
<script lang="ts">
|
||||
|
||||
type SetterInfo = {
|
||||
setter: string | null;
|
||||
date: string | null;
|
||||
@@ -480,13 +376,7 @@ import "@scss/common/bootstrap5.scss";
|
||||
import "@scss/game_bg.scss";
|
||||
|
||||
import { ref } from "vue";
|
||||
import type {
|
||||
IDItem,
|
||||
InvalidResponse,
|
||||
NationPolicy,
|
||||
NPCChiefActions,
|
||||
NPCGeneralActions,
|
||||
} from "@/defs";
|
||||
import type { IDItem, InvalidResponse, NationPolicy, NPCChiefActions, NPCGeneralActions } from "@/defs";
|
||||
import NumberInputWithInfo from "@/components/NumberInputWithInfo.vue";
|
||||
import { cloneDeep, isEqual, isNumber, last } from "lodash";
|
||||
import { unwrap } from "@util/unwrap";
|
||||
@@ -496,7 +386,7 @@ import { NPCPriorityBtnHelpMessage } from "@/helpTexts";
|
||||
import draggable from "vuedraggable";
|
||||
import TopBackBar from "@/components/TopBackBar.vue";
|
||||
import { convertIDArray } from "@util/convertIDArray";
|
||||
import { useToast, BContainer } from 'bootstrap-vue-3';
|
||||
import { useToast, BContainer } from "bootstrap-vue-3";
|
||||
|
||||
const chiefActionPriority = ref<IDItem<NPCChiefActions>[]>([]);
|
||||
const chiefActionKeys = ref(new Set(staticValues.availableNationPriorityItems));
|
||||
@@ -533,8 +423,8 @@ function resetPolicy() {
|
||||
}
|
||||
nationPolicy.value = cloneDeep(staticValues.defaultNationPolicy);
|
||||
toasts.info({
|
||||
title: '초기화 완료',
|
||||
body: "서버 초기값을 적용했습니다.설정 버튼을 누르면 반영됩니다."
|
||||
title: "초기화 완료",
|
||||
body: "서버 초기값을 적용했습니다.설정 버튼을 누르면 반영됩니다.",
|
||||
});
|
||||
}
|
||||
|
||||
@@ -596,9 +486,7 @@ async function submitPolicy() {
|
||||
}
|
||||
}
|
||||
|
||||
function calcPolicyValue(
|
||||
title: keyof NationPolicy
|
||||
): number {
|
||||
function calcPolicyValue(title: keyof NationPolicy): number {
|
||||
if (!(title in nationPolicy.value)) {
|
||||
throw `${title}이 NationPolicy key가 아님`;
|
||||
}
|
||||
@@ -745,9 +633,7 @@ async function submitGeneralPriority() {
|
||||
method: "post",
|
||||
data: convertFormData({
|
||||
type: "generalPriority",
|
||||
data: JSON.stringify(
|
||||
generalActionPriority.value.map(({ id }) => id)
|
||||
),
|
||||
data: JSON.stringify(generalActionPriority.value.map(({ id }) => id)),
|
||||
}),
|
||||
});
|
||||
const result: InvalidResponse = response.data;
|
||||
@@ -828,4 +714,4 @@ async function submitGeneralPriority() {
|
||||
padding-right: 0;
|
||||
padding-left: 0;
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user