Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| cce9c48345 | |||
| 7462656c15 | |||
| 30b150bb81 |
12
.env.local
Normal file
12
.env.local
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
# 로컬 설정 파일
|
||||||
|
|
||||||
|
## Personal Access Token (Gitea)
|
||||||
|
- 토큰: `e3b515eaa0a6683c921ca3bf718e281ed30a6075`
|
||||||
|
- 용도: git.webpluss.net API 접근 (Release 업로드, version.json 업데이트)
|
||||||
|
- **Git에 Commit되지 않도록 주의**
|
||||||
|
|
||||||
|
## 사용 예시
|
||||||
|
```bash
|
||||||
|
curl -u "sanjeok77:e3b515eaa0a6683c921ca3bf718e281ed30a6075" \
|
||||||
|
"https://git.webpluss.net/api/v1/repos/sanjeok77/NeFLIX/releases"
|
||||||
|
```
|
||||||
BIN
.env.local:Zone.Identifier
Normal file
BIN
.env.local:Zone.Identifier
Normal file
Binary file not shown.
@@ -20,10 +20,8 @@ android {
|
|||||||
applicationId = "com.example.shiftalarm"
|
applicationId = "com.example.shiftalarm"
|
||||||
minSdk = 26
|
minSdk = 26
|
||||||
targetSdk = 35
|
targetSdk = 35
|
||||||
versionCode = 1144
|
versionCode = 1148
|
||||||
versionName = "1.4.4"
|
versionName = "1.4.8"
|
||||||
versionCode = 1145
|
|
||||||
versionName = "1.4.5"
|
|
||||||
|
|
||||||
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -35,27 +35,6 @@ fun showCustomToast(context: Context, message: String, duration: Int = android.w
|
|||||||
// Fallback to default toast if custom toast fails
|
// Fallback to default toast if custom toast fails
|
||||||
android.widget.Toast.makeText(context, message, duration).show()
|
android.widget.Toast.makeText(context, message, duration).show()
|
||||||
}
|
}
|
||||||
}
|
|
||||||
* 다크모드 지원 커스텀 토스트 표시
|
|
||||||
*/
|
|
||||||
fun showCustomToast(context: Context, message: String, duration: Int = android.widget.Toast.LENGTH_SHORT) {
|
|
||||||
try {
|
|
||||||
// Use application context with theme for proper dark mode support
|
|
||||||
val themedContext = android.view.ContextThemeWrapper(context.applicationContext, R.style.Theme_ShiftAlarm)
|
|
||||||
val inflater = android.view.LayoutInflater.from(themedContext)
|
|
||||||
val layout = inflater.inflate(R.layout.custom_toast, null)
|
|
||||||
val textView = layout.findViewById<android.widget.TextView>(R.id.toastText)
|
|
||||||
textView.text = message
|
|
||||||
|
|
||||||
val toast = android.widget.Toast(context.applicationContext)
|
|
||||||
toast.duration = duration
|
|
||||||
toast.view = layout
|
|
||||||
toast.setGravity(android.view.Gravity.BOTTOM or android.view.Gravity.CENTER_HORIZONTAL, 0, 100)
|
|
||||||
toast.show()
|
|
||||||
} catch (e: Exception) {
|
|
||||||
// Fallback to default toast if custom toast fails
|
|
||||||
android.widget.Toast.makeText(context, message, duration).show()
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
// ============================================
|
// ============================================
|
||||||
// 알람 ID 생성
|
// 알람 ID 생성
|
||||||
|
|||||||
@@ -80,8 +80,7 @@ class MainActivity : AppCompatActivity() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
binding.prevMonth.setOnClickListener {
|
binding.prevMonth.setOnClickListener {
|
||||||
currentViewMonth = currentViewMonth.minusMonths(1)
|
animateMonthTransition(-1)
|
||||||
updateCalendar()
|
|
||||||
}
|
}
|
||||||
|
|
||||||
binding.monthTitle.setOnClickListener {
|
binding.monthTitle.setOnClickListener {
|
||||||
@@ -89,8 +88,7 @@ class MainActivity : AppCompatActivity() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
binding.nextMonth.setOnClickListener {
|
binding.nextMonth.setOnClickListener {
|
||||||
currentViewMonth = currentViewMonth.plusMonths(1)
|
animateMonthTransition(1)
|
||||||
updateCalendar()
|
|
||||||
}
|
}
|
||||||
|
|
||||||
binding.btnToday.setOnClickListener {
|
binding.btnToday.setOnClickListener {
|
||||||
@@ -707,11 +705,42 @@ class MainActivity : AppCompatActivity() {
|
|||||||
Toast.makeText(this, "⚠️ 루팅된 기기에서 시각적 오류나 알람 불안정이 발생할 수 있습니다.", Toast.LENGTH_LONG).show()
|
Toast.makeText(this, "⚠️ 루팅된 기기에서 시각적 오류나 알람 불안정이 발생할 수 있습니다.", Toast.LENGTH_LONG).show()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/**
|
private fun animateMonthTransition(direction: Int) {
|
||||||
* 남은 연차 표시 형식 개선
|
val card = binding.calendarCard
|
||||||
* - 정수면 정수로 표시 (예: 22)
|
val width = card.width.toFloat()
|
||||||
* - 소숫점 있으면 소숫점 표시 (예: 21.5)
|
|
||||||
*/
|
if (width == 0f) {
|
||||||
|
currentViewMonth = if (direction > 0) {
|
||||||
|
currentViewMonth.plusMonths(1)
|
||||||
|
} else {
|
||||||
|
currentViewMonth.minusMonths(1)
|
||||||
|
}
|
||||||
|
updateCalendar()
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
card.animate()
|
||||||
|
.translationX(if (direction > 0) -width else width)
|
||||||
|
.alpha(0.5f)
|
||||||
|
.setDuration(200)
|
||||||
|
.withEndAction {
|
||||||
|
currentViewMonth = if (direction > 0) {
|
||||||
|
currentViewMonth.plusMonths(1)
|
||||||
|
} else {
|
||||||
|
currentViewMonth.minusMonths(1)
|
||||||
|
}
|
||||||
|
updateCalendar()
|
||||||
|
|
||||||
|
card.translationX = if (direction > 0) width else -width
|
||||||
|
card.animate()
|
||||||
|
.translationX(0f)
|
||||||
|
.alpha(1f)
|
||||||
|
.setDuration(200)
|
||||||
|
.start()
|
||||||
|
}
|
||||||
|
.start()
|
||||||
|
}
|
||||||
|
|
||||||
private fun formatRemainingDays(days: Float): String {
|
private fun formatRemainingDays(days: Float): String {
|
||||||
return if (days == days.toInt().toFloat()) {
|
return if (days == days.toInt().toFloat()) {
|
||||||
// 정수인 경우
|
// 정수인 경우
|
||||||
|
|||||||
@@ -108,11 +108,4 @@ class ShiftRepository(private val context: Context) {
|
|||||||
))
|
))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
val annualLeave = dao.getAnnualLeave()
|
|
||||||
annualLeave?.let {
|
|
||||||
val usedDays = calculateUsedAnnualLeave()
|
|
||||||
val remainingDays = it.totalDays - usedDays
|
|
||||||
dao.insertAnnualLeave(it.copy(remainingDays = remainingDays))
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -120,6 +120,16 @@
|
|||||||
android:text="※ 연차: -1일 / 반년: -0.5일 차감"
|
android:text="※ 연차: -1일 / 반년: -0.5일 차감"
|
||||||
android:textSize="12sp"
|
android:textSize="12sp"
|
||||||
android:textColor="@color/text_tertiary"
|
android:textColor="@color/text_tertiary"
|
||||||
|
android:layout_marginBottom="8dp"
|
||||||
|
android:gravity="center"/>
|
||||||
|
|
||||||
|
<!-- 기능추가중 Notice -->
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="기능추가중"
|
||||||
|
android:textSize="11sp"
|
||||||
|
android:textColor="@color/primary"
|
||||||
android:layout_marginBottom="24dp"
|
android:layout_marginBottom="24dp"
|
||||||
android:gravity="center"/>
|
android:gravity="center"/>
|
||||||
|
|
||||||
|
|||||||
@@ -40,7 +40,7 @@
|
|||||||
android:id="@+id/shiftChar"
|
android:id="@+id/shiftChar"
|
||||||
android:layout_width="48dp"
|
android:layout_width="48dp"
|
||||||
android:layout_height="48dp"
|
android:layout_height="48dp"
|
||||||
android:layout_height="40dp"
|
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:text="주"
|
android:text="주"
|
||||||
android:textSize="15sp"
|
android:textSize="15sp"
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
<string name="tab_basic">기본 설정</string>
|
<string name="tab_basic">기본 설정</string>
|
||||||
<string name="tab_alarm">알람 설정</string>
|
<string name="tab_alarm">알람 설정</string>
|
||||||
<string name="tab_additional">부가기능</string>
|
<string name="tab_additional">부가기능</string>
|
||||||
<string name="tab_lab">휴가 관리</string>
|
<string name="tab_lab">근무 관리</string>
|
||||||
|
|
||||||
<string-array name="factory_array">
|
<string-array name="factory_array">
|
||||||
<item>전주</item>
|
<item>전주</item>
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"versionCode": 1146,
|
"versionCode": 1148,
|
||||||
"versionName": "1.4.6",
|
"versionName": "1.4.8",
|
||||||
"apkUrl": "https://git.webpluss.net/attachments/94d91eff-db0f-44af-b043-b03918cba243",
|
"apkUrl": "https://git.webpluss.net/attachments/b84726d9-cebb-4ffe-a452-6f0aefbcce93",
|
||||||
"changelog": "v1.4.6: 휴가관리 중복 텍스트 제거, 자동 저장 기능 추가",
|
"changelog": "v1.4.8: 달력 월 이동 시 부드러운 화면 전환 애니메이션 추가",
|
||||||
"forceUpdate": false
|
"forceUpdate": false
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user