Skip to content

Commit

Permalink
自动格式化代码,调整公招说明文字
Browse files Browse the repository at this point in the history
  • Loading branch information
ZhaoZuohong committed Sep 18, 2023
1 parent 9924f79 commit 63b40c7
Show file tree
Hide file tree
Showing 6 changed files with 75 additions and 77 deletions.
4 changes: 3 additions & 1 deletion ui/components.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ declare module '@vue/runtime-core' {
Email: typeof import('./src/components/Email.vue')['default']
HelpText: typeof import('./src/components/HelpText.vue')['default']
MaaBasic: typeof import('./src/components/MaaBasic.vue')['default']
MaaRecruit: typeof import('./src/components/MaaRecruit.vue')['default']
MaaRogue: typeof import('./src/components/MaaRogue.vue')['default']
MaaWeekly: typeof import('./src/components/MaaWeekly.vue')['default']
NButton: typeof import('naive-ui')['NButton']
Expand All @@ -22,6 +21,7 @@ declare module '@vue/runtime-core' {
NConfigProvider: typeof import('naive-ui')['NConfigProvider']
NDialogProvider: typeof import('naive-ui')['NDialogProvider']
NDivider: typeof import('naive-ui')['NDivider']
NDynamicInput: typeof import('naive-ui')['NDynamicInput']
NGlobalStyle: typeof import('naive-ui')['NGlobalStyle']
NH4: typeof import('naive-ui')['NH4']
NIcon: typeof import('naive-ui')['NIcon']
Expand All @@ -40,5 +40,7 @@ declare module '@vue/runtime-core' {
NTimePicker: typeof import('naive-ui')['NTimePicker']
NTooltip: typeof import('naive-ui')['NTooltip']
PlanEditor: typeof import('./src/components/PlanEditor.vue')['default']
Recruit: typeof import('./src/components/Recruit.vue')['default']
SKLand: typeof import('./src/components/SKLand.vue')['default']
}
}
6 changes: 0 additions & 6 deletions ui/src/components/HelpText.vue
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,3 @@
<slot />
</n-tooltip>
</template>

<style scoped>
.help {
line-height: 34px;
}
</style>
96 changes: 49 additions & 47 deletions ui/src/components/Recruit.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import { useConfigStore } from '@/stores/config'
const store = useConfigStore()
import { storeToRefs } from 'pinia'
const { recruit_enable, recruit_only_4, recruitment_time ,recruit_robot } = storeToRefs(store)
const { recruit_enable, recruit_only_4, recruitment_time, recruit_robot } = storeToRefs(store)
import { ref, computed } from 'vue'
const recruit_3 = computed({
Expand All @@ -19,7 +19,6 @@ const recruit_3 = computed({
})
const recruit_4 = ref('900')
</script>

<template>
Expand All @@ -31,52 +30,55 @@ const recruit_4 = ref('900')
</template>
<n-table :single-line="false" size="small" class="big-table">
<thead>
<tr>
<th>可保底</th>
<th>招募选项</th>
</tr>
<tr>
<th>可保底</th>
<th>招募选项</th>
</tr>
</thead>
<tbody>
<tr>
<td>三星</td>
<td>
<n-radio-group v-model:value="recruit_3" name="recruit_3">
<n-space justify="start">
<n-radio value="skip">不招</n-radio>
<n-radio value="740">7:40</n-radio>
<n-radio value="900">9:00</n-radio>
</n-space>
</n-radio-group>
</td>
</tr>
<tr>
<td>四星</td>
<td>
<n-radio-group name="recruit_4" v-model:value="recruit_4">
<n-space justify="start">
<n-radio value="900">9:00</n-radio>
</n-space>
</n-radio-group>
</td>
</tr>
<tr>
<td>支援机械</td>
<td>
<n-radio-group name="recruit_robot" v-model:value="recruit_robot">
<n-space justify="start">
<n-radio :value="true">邮件通知</n-radio>
<help-text>
<div>碰到标签中包含支援机械时会发送邮件进行通知,不会自动选择</div>
</help-text>
<n-radio :value="false">忽略标签</n-radio>
<help-text>
<div>忽略支援机械标签,刷新标签或者选择其他的干员</div>
</help-text>
</n-space>

</n-radio-group>
</td>
</tr>
<tr>
<td>三星</td>
<td>
<n-radio-group v-model:value="recruit_3" name="recruit_3">
<n-space justify="start">
<n-radio value="skip">不招</n-radio>
<n-radio value="740">7:40</n-radio>
<n-radio value="900">9:00</n-radio>
</n-space>
</n-radio-group>
</td>
</tr>
<tr>
<td>四星</td>
<td>
<n-radio-group name="recruit_4" v-model:value="recruit_4">
<n-space justify="start">
<n-radio value="900">9:00</n-radio>
</n-space>
</n-radio-group>
</td>
</tr>
<tr>
<td>支援机械</td>
<td>
<n-radio-group name="recruit_robot" v-model:value="recruit_robot">
<n-space justify="start">
<n-radio :value="true">
邮件通知
<help-text>
<div>发送邮件通知,不自动选择</div>
</help-text>
</n-radio>
<n-radio :value="false">
忽略标签
<help-text>
<div>忽略支援机械标签,按策略自动刷新或选择标签</div>
</help-text>
</n-radio>
</n-space>
</n-radio-group>
</td>
</tr>
</tbody>
</n-table>
</n-card>
Expand Down Expand Up @@ -130,4 +132,4 @@ h4 {
.final {
margin: 16px 0 0;
}
</style>
</style>
32 changes: 16 additions & 16 deletions ui/src/components/SKLand.vue
Original file line number Diff line number Diff line change
@@ -1,21 +1,18 @@
<script setup>
import {storeToRefs} from "pinia";
import { storeToRefs } from 'pinia'
import { useConfigStore } from '@/stores/config'
const store = useConfigStore()
const { skland_enable ,skland_info} = storeToRefs(store)
const { skland_enable, skland_info } = storeToRefs(store)
function add_account(){
function add_account() {
return {
isCheck: true,
account: '',
password: ''
}
}
</script>


<template>
<n-card>
<template #header>
Expand All @@ -29,25 +26,28 @@ function add_account(){
<template #default="{ value }">
<div style="display: flex; align-items: center; width: 100%">
<n-checkbox v-model:checked="value.isCheck" style="margin-right: 12px" />
<n-input style="margin-right: 10px;" v-model:value="value.account" type="text" placeholder="账号"/>

<n-input v-model:value="value.password" type="password" show-password-on="click" placeholder="密码"/>
<n-input
style="margin-right: 10px"
v-model:value="value.account"
type="text"
placeholder="账号"
/>

<n-input
v-model:value="value.password"
type="password"
show-password-on="click"
placeholder="密码"
/>
</div>
</template>
</n-dynamic-input>
</n-card>


</template>


<style>
.card-title {
font-weight: 500;
font-size: 18px;
}
</style>

2 changes: 1 addition & 1 deletion ui/src/pages/Advanced.vue
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ async function select_simulator_folder() {
</n-card>
<maa-basic />
<email />
<SKLand/>
<SKLand />
</div>
</template>

Expand Down
12 changes: 6 additions & 6 deletions ui/src/stores/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,12 @@ export const useConfigStore = defineStore('config', () => {
const rogue = ref({})
const screenshot = ref(0)
const mail_subject = ref('')
const skland_enable= ref(false)
const skland_info= ref([])
const recruit_enable= ref(true)
const skland_enable = ref(false)
const skland_info = ref([])
const recruit_enable = ref(true)
const recruit_only_4 = ref(false)
const recruitment_time = ref(false)
const recruit_robot= ref(true)
const recruit_robot = ref(true)

async function load_shop() {
const response = await axios.get(`${import.meta.env.VITE_HTTP_URL}/shop`)
Expand Down Expand Up @@ -160,12 +160,12 @@ export const useConfigStore = defineStore('config', () => {
rogue: rogue.value,
screenshot: screenshot.value,
mail_subject: mail_subject.value,
skland_enable: skland_enable.value ,
skland_enable: skland_enable.value,
skland_info: skland_info.value,
recruit_enable: recruit_enable.value,
recruit_only_4: recruit_only_4.value,
recruitment_time: recruitment_time.value,
recruit_robot: recruit_robot.value,
recruit_robot: recruit_robot.value
}
}

Expand Down

0 comments on commit 63b40c7

Please sign in to comment.