Commit 3898f192 by yeran

update

1 parent 1c9d7da4
...@@ -60,7 +60,7 @@ ...@@ -60,7 +60,7 @@
}, },
init() { init() {
getArticleDetails({ getArticleDetails({
ids: [this.levelConfig.article_ids[0]] 'type' : 2
}).then((articles) => { }).then((articles) => {
this.articles = []; this.articles = [];
if (articles && articles.data) { if (articles && articles.data) {
......
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
<div class="list"> <div class="list">
<div class="item" v-for="(item,index) in myAnswer"> <div class="item" v-for="(item,index) in myAnswer">
<div v-if="item.check" class="data-2">{{item.txt}}</div> <div v-if="item.check" class="data-2">{{item.txt}}</div>
<div v-else class="data-1">{{item.txt}}</div> <div v-else class="data-1">{{item.txt }}</div>
</div> </div>
</div> </div>
<div class="answer">正确答案</div> <div class="answer">正确答案</div>
...@@ -191,6 +191,7 @@ ...@@ -191,6 +191,7 @@
.list .item .data-1 { .list .item .data-1 {
width: 90%; width: 90%;
height: 100%; height: 100%;
min-width: 14px;
border-bottom: 2px solid #ff573f; border-bottom: 2px solid #ff573f;
display: flex; display: flex;
align-items: center; align-items: center;
...@@ -200,6 +201,7 @@ ...@@ -200,6 +201,7 @@
.list .item .data-2 { .list .item .data-2 {
width: 90%; width: 90%;
height: 100%; height: 100%;
min-width: 14px;
border-bottom: 2px solid #077907; border-bottom: 2px solid #077907;
display: flex; display: flex;
align-items: center; align-items: center;
......
...@@ -6,9 +6,12 @@ ...@@ -6,9 +6,12 @@
</div> </div>
<div class="list"> <div class="list">
<div class="item" v-for="(item,index) in answer"> <div class="number-data-word" v-for="(item,index) in answer">
<div class="text-2"> <!-- <input class="text-1" v-model="item.txt" type="text" >-->
<input class="text-1" v-model="item.txt" type="text" > <input class="number-item-word" :style="{borderRightColor: item.border?'#666':''}"
v-model="item.txt" type="text">
<div class="number-item-translation" :key="index"
:style="{borderRightColor: item.border?'#666':''}">{{item.translation}}
</div> </div>
</div> </div>
</div> </div>
...@@ -77,9 +80,10 @@ ...@@ -77,9 +80,10 @@
this.answer.push({ this.answer.push({
txt: '', txt: '',
check: false, check: false,
translation: this.correctAnswer[i].translation
}); });
} }
console.log(this.correctAnswer,this.answer); console.log(this.correctAnswer, this.answer);
StoreUtil.stateSave(BaseConstant.BRAIN_TRAIN_TRAIN_INFO_NOW, { StoreUtil.stateSave(BaseConstant.BRAIN_TRAIN_TRAIN_INFO_NOW, {
result: { result: {
...@@ -155,6 +159,39 @@ ...@@ -155,6 +159,39 @@
cursor: pointer; cursor: pointer;
} }
.number-data-word {
display: flex;
width: 100%;
align-items: center;
justify-content: center;
padding: 4px 8px;
font-size: 0.4rem;
}
.number-item-word {
width: 35%;
height: 50px;
display: flex;
align-items: center;
justify-content: space-between;
color: #333;
font-size: 24px;
text-align: center;
border: 0px;
outline: none;
cursor: pointer;
border-bottom: 2px solid #409eff;
}
.number-item-translation {
width: 56%;
display: flex;
align-items: center;
/*justify-content: flex-end;*/
justify-content: space-between;
border-right: 2px solid transparent;
margin-left: 24px;
}
.operation .item { .operation .item {
......
...@@ -23,8 +23,8 @@ ...@@ -23,8 +23,8 @@
</div> </div>
<div v-else class="number-list"> <div v-else class="number-list">
<div class="number-data-word" v-for="(item,index) in numberList"> <div class="number-data-word" v-for="(item,index) in numberList">
<div class="number-item" :key="index" :style="{borderRightColor: item.border?'#666':''}">{{item.num}} <div class="number-item-word" :key="index" :style="{borderRightColor: item.border?'#666':''}">{{item.num}} </div>
</div> <div class="number-item-translation" :key="index" :style="{borderRightColor: item.border?'#666':''}">{{item.translation}} </div>
</div> </div>
</div> </div>
...@@ -101,6 +101,7 @@ ...@@ -101,6 +101,7 @@
for (let i = 0; i < words.data.length; i++) { for (let i = 0; i < words.data.length; i++) {
this.numberList.push({ this.numberList.push({
num: words.data[i].word, num: words.data[i].word,
translation: words.data[i].translation,
border: false border: false
}) })
} }
...@@ -236,21 +237,41 @@ ...@@ -236,21 +237,41 @@
justify-content: center; justify-content: center;
} }
.number-item {
width: 90%;
height: 50px;
display: flex;
align-items: center;
justify-content: center;
border-right: 2px solid transparent;
}
.number-data-word { .number-data-word {
display: flex; display: flex;
width: 100%;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
padding: 4px 8px; padding: 4px 8px;
font-size: 0.4rem; font-size: 0.4rem;
} }
.number-item { .number-item-word {
width: 90%; width: 35%;
height: 50px; height: 50px;
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: center; justify-content: space-between;
border-right: 2px solid transparent;
}
.number-item-translation {
width: 60%;
display: flex;
align-items: center;
/*justify-content: flex-end;*/
justify-content: space-between;
border-right: 2px solid transparent; border-right: 2px solid transparent;
margin-left: 24px;
} }
.start { .start {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!