Merge branch 'master' of https://gitee.com/mini-org-project/course_information_center_vue
This commit is contained in:
commit
b9c5da759a
|
@ -13,8 +13,7 @@
|
||||||
<!-- -{{ item }}- -->
|
<!-- -{{ item }}- -->
|
||||||
<div class="wenZiJiaCu">
|
<div class="wenZiJiaCu">
|
||||||
<span v-if="item.score" class="hand" style="color: #337ab7;" @click="viewModal.view(item)">已评分:{{ item.score }}分</span>
|
<span v-if="item.score" class="hand" style="color: #337ab7;" @click="viewModal.view(item)">已评分:{{ item.score }}分</span>
|
||||||
<span v-else class="hand" style="color: #b77633;" @click="tingKeZuJiAddModal.view(item)"><FormOutlined/>填写评价</span>
|
<span v-else class="hand" style="color: #b77633;" @click="txpjFun(item)"><FormOutlined/>填写评价</span>
|
||||||
|
|
||||||
|
|
||||||
<span v-if="item.source != null" class="hand" style="padding-left: .5rem;color: #337ab7;">【</span>
|
<span v-if="item.source != null" class="hand" style="padding-left: .5rem;color: #337ab7;">【</span>
|
||||||
<span v-if="item.source=='0'" class="hand" style="padding-left: .5rem;color: #337ab7;">课程中心</span>
|
<span v-if="item.source=='0'" class="hand" style="padding-left: .5rem;color: #337ab7;">课程中心</span>
|
||||||
|
@ -56,7 +55,7 @@
|
||||||
<fwdtModalPage ref="fwdtModal"/>
|
<fwdtModalPage ref="fwdtModal"/>
|
||||||
</template>
|
</template>
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, onMounted, watch } from 'vue';
|
import { ref, onMounted, watch, createVNode,h } from 'vue';
|
||||||
import { TeamOutlined, FormOutlined } from '@ant-design/icons-vue';
|
import { TeamOutlined, FormOutlined } from '@ant-design/icons-vue';
|
||||||
import { getUserId,getSysConfig } from '/@/views/site/utils/index';
|
import { getUserId,getSysConfig } from '/@/views/site/utils/index';
|
||||||
|
|
||||||
|
@ -64,8 +63,12 @@ import addModalPage from '/@/views/site/tingKeZuJi/components/addModal.vue';
|
||||||
import viewModalPage from '/@/views/site/tingKeZuJi/components/viewModal.vue';
|
import viewModalPage from '/@/views/site/tingKeZuJi/components/viewModal.vue';
|
||||||
import fwdtModalPage from '/@/views/site/tingKeZuJi/components/fwdtModal.vue';
|
import fwdtModalPage from '/@/views/site/tingKeZuJi/components/fwdtModal.vue';
|
||||||
import { defHttp } from '/@/utils/http/axios';
|
import { defHttp } from '/@/utils/http/axios';
|
||||||
|
import { Modal } from 'ant-design-vue';
|
||||||
|
import { ExclamationCircleOutlined,CheckOutlined,CloseOutlined } from '@ant-design/icons-vue';
|
||||||
enum Api {
|
enum Api {
|
||||||
list = '/kcTingke/kcTingke/findTingKeZuJiBytingketimeAndUserId'
|
list = '/kcTingke/kcTingke/findTingKeZuJiBytingketimeAndUserId',
|
||||||
|
|
||||||
|
listTkjl = '/kcTingke/kcTingke/getSftk'
|
||||||
}
|
}
|
||||||
|
|
||||||
const tingKeZuJiAddModal = ref();
|
const tingKeZuJiAddModal = ref();
|
||||||
|
@ -81,6 +84,7 @@ const props = defineProps({
|
||||||
* @param params
|
* @param params
|
||||||
*/
|
*/
|
||||||
const listApi = (params) => defHttp.get({ url: Api.list, params });
|
const listApi = (params) => defHttp.get({ url: Api.list, params });
|
||||||
|
const listTkjlApi = (params) => defHttp.get({ url: Api.listTkjl, params });
|
||||||
|
|
||||||
const list = ref<any>([]);
|
const list = ref<any>([]);
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
|
@ -95,6 +99,31 @@ watch(
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
|
function txpjFun(item){
|
||||||
|
|
||||||
|
let kechengbiaoid = item.ketangbiaoid;
|
||||||
|
let userid = item.userid;
|
||||||
|
listTkjlApi({ userid: userid, kechengbiaoid:kechengbiaoid}).then(res => {
|
||||||
|
var list = res
|
||||||
|
console.log(`🚀 ~ file: list.vue:106 ~ listTkjlApi ~ list:`, list)
|
||||||
|
if(list.length>0){
|
||||||
|
Modal.error({
|
||||||
|
icon: createVNode({}),
|
||||||
|
content: h('div', {style:'height:200px;text-align:center;'}, [
|
||||||
|
h('icon', {style:'font-size:80px;font-weight:600;color:red;'}, createVNode(CloseOutlined)),
|
||||||
|
h('p',{style:'font-size:22px;font-weight:600;color:black;'}, '已经对此课程进行评价,不可重复评价,请点击刷新按钮!'),
|
||||||
|
]),
|
||||||
|
okText: 'OK',
|
||||||
|
width:'500px',
|
||||||
|
});
|
||||||
|
}else{
|
||||||
|
tingKeZuJiAddModal.value.view(item)
|
||||||
|
}
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
function init() {
|
function init() {
|
||||||
console.log('init');
|
console.log('init');
|
||||||
listApi({ userid: getUserId(), tingketime: getSysConfig().bxqkssj, ...props.queryParam }).then(res => {
|
listApi({ userid: getUserId(), tingketime: getSysConfig().bxqkssj, ...props.queryParam }).then(res => {
|
||||||
|
|
Loading…
Reference in New Issue