chengkun
2025-04-18 1bb985f32f2efe0f9dd69f3cf29a1c809b1cf96d
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
{yun:}include file="$wapstyle/member/header.htm"{/yun}
 
<div id="yunvue" class="none">
<div class="issue_post_body">
    <div class="video_interview_card" v-for="(item, infokey) in list" :key="infokey">
        <div class="interview_card_top">            
            <div class="interview_card_top_box" v-if="item.canroom" @click="goRoom(item.sid)">
                <div class="top_box_icon">
                    <img src="{yun:}$wap_style{/yun}/images/video_icon.png" alt="" width="100%" height="100%">
                </div>
                <div class="top_box_text">进入面试间</div>
            </div>
            <div class="interview_card_top_state" v-if="item.status==1">{{item.status_n}}</div>
            <div class="interview_card_top_state" v-else-if="item.status==2">{{item.status_n}}</div>
            <div class="interview_card_top_state" v-else>{{item.status_n}}</div>
        </div>
        <div class="video_interview_template">
            <div class="interview_template_q">面试时间</div>
            <div class="interview_template_a">{{item.ctime_n}}</div>
        </div>
        <div class="video_interview_template">
            <div class="interview_template_q">预约职位</div>
            <div class="interview_template_a" @click="pageTo(item.wapjob_url)">{{item.jobname}}</div>
        </div>
        <div class="video_interview_template">
            <div class="interview_template_q">备注信息</div>
            <div class="interview_template_remark">{{item.remark}}</div>
        </div>
        <div class="video_interview_del">
            <div class="video_interview_name" @click="pageTo(item.wapcom_url)">{{item.comname}}</div>
                <div class="video_interview_icon" @click="del(item.id,infokey)">
                    <img src="{yun:}$wap_style{/yun}/images/resume_del.png" alt="" width="100%" height="100%">
                </div>
        </div>
     </div>
   
     <div v-if="count ==2">
    <van-pagination v-model="page" :total-items="total" :items-per-page="limit" force-ellipses @change="pageChange" /> 
    </div>
    
    <div class="wap_member_no" v-show="islook&&count==0">
        暂无预约记录<div><a class="wap_member_no_submit" href="{yun:}url m=wap c=spview{/yun}">去搜索视频面试</a></div>
    </div>
    
</div>
</div>
<script>  
  var currentPage = parseInt('{yun:}$smarty.get.page{/yun}');   
  var wapurl = "{yun:}url m=wap{/yun}";
      new Vue({
        el: '#yunvue',
        data: {
          list: [],
          limit:20,       
          total:0,
          page: currentPage ? currentPage : 1,
          islook :false
        },
        computed: {
          count(){
            if(this.total > this.limit){
              return 2;
            }else if(this.list.length==0){
              return 0;
            }else{
                return 1;
            }
          }
        },
        created() {   
         this.getSub();
        },
        methods:{
          getSub:function(){
            showLoading();
            var that = this;
            var paramer = {};
                paramer['page'] = that.page;
                paramer['limit'] = that.limit;     
            $.post('{yun:}url d=wxapp h=user m=spview c=index{/yun}',paramer,function(res){
              hideLoading();      
             
              that.list = res.data.list;
              that.total = res.total;
              that.page = currentPage ? currentPage : 1;
              that.islook = true 
               $("#yunvue").css('display', 'block');
            },'json');
          },
          goRoom:function(sid){
              let param = {               
                sid: sid
              };
              showLoading();
              $.post('{yun:}url d=wxapp m=spview c=goRoom{/yun}',param,function(res){
                hideLoading();      
                  if(res.error==1){
                      window.location.href = wapurl +'/member/?c=sproom&id=' + sid
                  }else{
                    showToast(res.msg);
                  }
               
               },'json');
          },          
          del:function(id,key){
              let that = this
              let param = {
                id: id
              };
             
             showConfirm('确定删除', () => {
                showLoading('删除中...')
                $.post('{yun:}url d=wxapp h=user m=spview c=delSub{/yun}', param, function(data){
                  hideLoading();
                  if (data.error == 1) {
                    showToast(data.msg,2, function() {
                      that.list.splice(key, 1);   
                    });
                  } else {
                    showToast(data.msg);
                  }
                });
             });   
             
          },
           pageChange:function(e){
          
            location.href = 'index.php?c=spview&page='+e;
          },
          pageTo:function(url){
              window.location.href = url;
          }
        } 
      });
</script>
</body>
</html>