增加点赞点踩

main
guanxiaohan 11 months ago
parent 6e1917a6f8
commit cda35b37de
  1. 1
      components/zeroMarkdownView/zeroMarkdownView.vue
  2. 5
      pages.json
  3. 2
      pages/index/detail.vue
  4. 165
      pages/investigation/task.vue
  5. 48
      pages/knowledge/index.vue

@ -175,6 +175,7 @@
<style lang="scss">
.zero-markdown-view {
padding: 15rpx;
padding-bottom: 9rpx;
position: relative;
}
</style>

@ -87,7 +87,10 @@
//
"enablePullDownRefresh": false,
"navigationBarBackgroundColor": "#FFFFFF",
"navigationBarTextStyle": "black"
"navigationBarTextStyle": "black",
"app-plus": {
"softinputMode": "adjustResize"
}
}
},
{

@ -189,7 +189,7 @@
</template>
<script>
import AbortController from "abort-controller/dist/abort-controller";
// import AbortController from "abort-controller/dist/abort-controller";
import TopTitle from "../../components/top-title.vue";
// import headerNavBar from '../../components/headerNavBar/headerNavBar.vue'
import zeroMarkdownView from "../../components/zeroMarkdownView/zeroMarkdownView.vue";

@ -1903,73 +1903,118 @@
}
});
},
// watchKeyBoardHeight() {
// uni.onKeyboardHeightChange(res => {
// if(res.height) {
// const query = uni.createSelectorQuery().in(this);
// //
// query.select('#page').boundingClientRect(data => {
// // data
// if (data) {
// //
// const height = data.height;
// this.boxHeight = height + res.height
// console.log(':', height);
// }
// }).exec(); //
// }
// })
// },
focus() {
const query = uni.createSelectorQuery().in(this);
//
query.select('#page').boundingClientRect(data => {
// data
if (data) {
//
const height = data.height;
if (this.isEdit) {
this.boxHeight = height + 200
}
console.log('盒子的高度:', height);
}
}).exec(); //
// const query = uni.createSelectorQuery().in(this);
// //
// query.select('#page').boundingClientRect(data => {
// // data
// if (data) {
// //
// const height = data.height;
// if (this.isEdit) {
// uni.onKeyboardHeightChange((res) => {
// if (res.height) {
// this.boxHeight = height + res.height
// // this.inputTop = res.height;
// }
// });
// }
// // uni.onKeyboardHeightChange((res) => {
// // if (res.height) {
// // this.boxHeight = height - res.height
// // // this.inputTop = res.height;
// // }
// // });
// console.log(':', height);
// }
// }).exec(); //
},
blur() {
const query = uni.createSelectorQuery().in(this);
//
query.select('#page').boundingClientRect(data => {
// data
if (data) {
//
const height = data.height;
if (this.isEdit) {
this.boxHeight = height - 200
}
console.log('盒子的高度:', height);
}
}).exec(); //
// const query = uni.createSelectorQuery().in(this);
// //
// query.select('#page').boundingClientRect(data => {
// // data
// if (data) {
// //
// const height = data.height;
// if (this.isEdit) {
// uni.onKeyboardHeightChange((res) => {
// if (res.height) {
// this.boxHeight = height - res.height
// // this.inputTop = res.height;
// }
// });
// }
// // uni.onKeyboardHeightChange((res) => {
// // if (res.height) {
// // this.boxHeight = height - res.height
// // // this.inputTop = res.height;
// // }
// // });
// console.log(':', height);
// }
// }).exec(); //
},
focus2() {
const query = uni.createSelectorQuery().in(this);
//
query.select('#page').boundingClientRect(data => {
// data
if (data) {
//
const height = data.height;
if (this.isEditStep2) {
this.boxHeight = height + 300
}
console.log('盒子的高度:', height);
}
}).exec(); //
// const query = uni.createSelectorQuery().in(this);
// //
// query.select('#page').boundingClientRect(data => {
// // data
// if (data) {
// //
// const height = data.height;
// if (this.isEditStep2) {
// uni.onKeyboardHeightChange((res) => {
// if (res.height) {
// this.boxHeight = height + res.height
// // this.inputTop = res.height;
// }
// });
// }
// console.log(':', height);
// }
// }).exec(); //
},
blur2() {
const query = uni.createSelectorQuery().in(this);
//
query.select('#page').boundingClientRect(data => {
// data
if (data) {
//
const height = data.height;
if (this.isEditStep2) {
this.boxHeight = height - 300
}
console.log('盒子的高度:', height);
}
}).exec(); //
// const query = uni.createSelectorQuery().in(this);
// //
// query.select('#page').boundingClientRect(data => {
// // data
// if (data) {
// //
// const height = data.height;
// if (this.isEditStep2) {
// uni.onKeyboardHeightChange((res) => {
// if (res.height) {
// this.boxHeight = height - res.height
// // this.inputTop = res.height;
// }
// }); }
// console.log(':', height);
// }
// }).exec(); //
},
onLongPressZD(item) {
if (this.nidZD == item.nid) {

@ -32,10 +32,15 @@
item.answerId == '0'
? 'data:image/jpeg;base64,iV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MypYHwRzRMS4AUHaoVcwry6rXoi0RwYN6N5QvTjXFPdWPJiQ4UdQpEtZt4E/9G4QNU+RMyaSs7y7q4HTcg1RLsK9D8FtVZEbCwVYl5Id7Co2IlcBgpTKagdQ+6iD9DAZ5VnPoh3XjWregYsio7LE9rP9zw2+PeQjfqk9ZIR2d0T969xvtD889oN5XoXBG/PQ+vyXDxtrQ8R6+Y62zbrIz493Lu6vfdWFoqP4f+nLoyraTihhQCNO91+4gTka6ZplxzhaMfwKikpZurX5zveaNwwqdNQXMJTN1I+xAbOhHK6ezyz8Z22ypMXxnSRpJYMwumT7KgvtZcYNN5N1YY564yPjBxHhNG6pua2yjM948myGMRlKLzB8UQz4dqUzQfOFkemz5HSUGt0nr8+pRyemM34/eKYZvfWKgsKUSvsEYJ+84HO4nN9k4oE2x2PzMeOsMVoTIHrM9BMfGM+9tdwloJ1tih9bj1zM5uJM3+RZjDIaA1xVLlYLsvEkC9ribexFDLTRCd69opZq5CTS8SMOSr/L50juoR1Q/wXezDsV4mIn4fYenJF3v/l3i2DR/4Y0rZfMmkGTDMZ4UIj8hR6+i1KJUUuznkWCMuMVxqtA9JtBrJf7+Yag7Px0fJYjvcmy0F4+TZl90igyCCnoSKanvGSyLgpmYSGrJVBX5PFJSMIPAS5WDBHSwUgEwkYdMoA2J2g8u1/VfDG2hxN2McuuBuk9kWTStS7+BXwZioBnkugBrzF7iWoDbUfUJFmUgOAtxO1ofg07l4BqFIkhPzUF+lo3N2WGwKeYVudfOuEUbbVeRTlAOnuwSZrDlMRtpNyc/hfAQYAFFwdv9Iba+4AAAAASUVORK5CYII='
: $.imgSrc + '/left_user.png'
" class="img" />
" class="img"
/>
<view class="content">
<zeroMarkdownView :markdown="item.data" />
<!-- <ua-markdown :source="mdvalue" /> -->
<view class="icon" v-show="item.answerId != '0' && item.isOver && item.isSuccess">
<uni-icons :type="iconsType == '' ? 'hand-up' : (iconsType == 'handUp' ? 'hand-up-filled' : 'hand-up')" :color="iconsType == 'handUp' ? '#FFD131' : ''" size="22" @click="clickIcon('handUp')"></uni-icons>
<uni-icons :type="iconsType == '' ? 'hand-down' : (iconsType == 'handDown' ? 'hand-down-filled' : 'hand-down')" size="22" @click="clickIcon('handDown')"></uni-icons>
</view>
</view>
</view>
<view class="loading-animation" v-if="loading">
@ -114,7 +119,8 @@
text: "请给我一个典型的视距不良路口案例。",
},
],
timer: null
timer: null,
iconsType: ''
};
},
onLoad() {
@ -142,9 +148,35 @@
}
},
methods: {
clickIcon(type) {
if(this.iconsType == '') {
this.iconsType = type
} else {
if(this.iconsType == 'handUp') {
if(type == 'handUp') {
this.iconsType = ''
} else {
this.iconsType = 'handDown'
}
} else {
if(type == 'handUp') {
this.iconsType = 'handUp'
} else {
this.iconsType = ''
}
}
}
const params = {
qaId: '',
feedbackStatus : this.iconsType == '' ? 0 : (this.iconsType == 'handUp' ? 1 : 2),
feedbackInfo: ''
}
// this.$request.globalRequest('/hitapChat/hitap/feadBack', params, 'POST').then(res => {})
},
async queryChat(voiceText) {
// console.log(voiceText,"voiceText");
clearInterval(this.timer)
this.answerIsOver = false
this.loading = true;
const [err, res] = await uni.request({
// url: 'http://10.16.3.159:8777/api/local_doc_qa/local_doc_chat',
@ -239,6 +271,7 @@
id,
answerId,
data: newdata,
isSuccess: true
},
];
} else {
@ -256,6 +289,7 @@
});
if (newdata == data) {
clearInterval(this.timer);
this.msgList[this.msgList.length - 1].isOver = true
}
}, 50);
} else {
@ -699,7 +733,7 @@
}
.text {
font-size: 32rpx;
font-size: 28rpx;
}
}
@ -941,4 +975,12 @@
transform: scale(1);
}
}
.icon{
display: flex;
justify-content: flex-end;
margin: 0 15rpx 15rpx 12rpx;
.uni-icons{
margin-left: 15rpx;
}
}
</style>

Loading…
Cancel
Save