@extends('layouts.app') @section('title', '個人設定') @push('styles') @endpush @section('content')
@if(session('success')) @endif
{{-- ── Sidebar ── --}} {{-- ── Main content ── --}}
{{-- ══════════════════════════════════════════════════ --}} {{-- 基本資料 panel --}} {{-- ══════════════════════════════════════════════════ --}}
@csrf @method('PATCH') {{-- keep proxy so it isn't wiped when saving basic info --}}

基本資料

姓名、職稱等個人資訊

帳號
{{ $user->email }}
部門
{{ $user->department ?? '—' }}
由管理員設定
@error('name')
{{ $message }}
@enderror

密碼變更

留空表示不更改目前密碼

{{-- ══════════════════════════════════════════════════ --}} {{-- 職務代理人 panel --}} {{-- ══════════════════════════════════════════════════ --}}
@csrf @method('PATCH')

預設職務代理人

請假申請時系統將自動帶入此代理人設定

@if($user->defaultProxy)
{{ mb_substr($user->defaultProxy->name, 0, 1) }}
{{ $user->defaultProxy->name }}
目前預設代理人{{ $user->defaultProxy->department ? '・'.$user->defaultProxy->department : '' }}
@endif
@error('default_proxy_user_id')
{{ $message }}
@enderror
可選擇上級、同組或跨組同事
{{-- ══════════════════════════════════════════════════ --}} {{-- 介面樣式 panel --}} {{-- ══════════════════════════════════════════════════ --}}

主題色調

選擇介面的明暗模式

專案管理介面

切換後下次進入專案管理時生效

@csrf
{{-- ══════════════════════════════════════════════════ --}} {{-- API Token panel --}} {{-- ══════════════════════════════════════════════════ --}}

工時填報 API Token

用於外部工具自動填寫工時

@if(session('new_timelog_token'))
新產生的 Token — 請立即複製儲存
{{ session('new_timelog_token') }}
••••••••••••••••••••••••••••••••••••••••••••••••
@endif @if($timelogTokens->isNotEmpty())
@foreach($timelogTokens as $tok) @endforeach
說明TokenIP 白名單最後使用建立時間
{{ $tok->description ?: '—' }}
{{ substr($tok->token,0,8) }}••••••••
@if($tok->allowed_ips) {{ $tok->allowed_ips }} @else 未設定(無法使用) @endif {{ $tok->last_used_at?->format('Y-m-d H:i') ?? '未使用' }} {{ $tok->created_at->format('Y-m-d') }}
@csrf @method('DELETE')
@endif

產生新 Token

@csrf
必填,支援單一 IP 或 CIDR 網段,多個以逗號分隔
@error('allowed_ips')
{{ $message }}
@enderror

API 使用方式

查詢可填報專案:

GET {{ url('/api/timelog/projects') }}?token=YOUR_TOKEN

填寫工時:

POST {{ url('/api/timelog') }}
Content-Type: application/json

{
  "token": "YOUR_TOKEN",
  "project": "專案名稱或 project_id",
  "hours": 2.5,
  "date": "{{ today()->toDateString() }}",
  "comments": "備註(選填)"
}
{{-- /settings-layout --}}
{{-- /settings-page --}} @endsection @push('scripts') @endpush