Skip to content

Commit

Permalink
fix: WorkDataをSwaggerのSchemaと同じものに変更
Browse files Browse the repository at this point in the history
  • Loading branch information
shirakasu committed Oct 10, 2023
1 parent b3d5913 commit ad52379
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 9 deletions.
1 change: 0 additions & 1 deletion .idea/vcs.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ android {
buildFeatures {
dataBinding true
}
namespace 'com.example.funcy_portfolio_android'
}

dependencies {
Expand Down
3 changes: 1 addition & 2 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.funcy_portfolio_android">
<manifest xmlns:android="http://schemas.android.com/apk/res/android">

<uses-permission android:name="android.permission.INTERNET"/>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,22 @@ package com.example.funcy_portfolio_android.model.data
data class WorkData(
val title: String,
val description: String,
val thumbnail: String,
val user_icon: String,
val user_name: String,
val userID: String,
val images: List<ImageData>,
val URL: String,
val work_url: String,
val movie_url: String,
val tags: List<TagData>,
val group: String?,
val group: String,
val security: Int,
)

data class ImageData(
val Image: String
val image: String
)

data class TagData(
val Tag: String
val tag: String
)
Original file line number Diff line number Diff line change
Expand Up @@ -80,19 +80,27 @@ class WorkRegisterViewModel : ViewModel() {
description: String,
security: Int,
work_url: String,
youtube_url: String
youtube_url: String,
group: String,
user_icon: String,
user_name: String,
userID: String
): String? {
viewModelScope.launch {
val postTagList = stringTagListToTagList(tags)
res = workRepository.registerWork(
WorkData(
title,
description,
thumbnail,
user_icon,
user_name,
userID,
listOf(ImageData("")),
work_url,
youtube_url,
postTagList,
null,
group,
security
)
)
Expand Down

0 comments on commit ad52379

Please sign in to comment.