diping
12
app.js
|
@ -25,12 +25,12 @@ App({
|
|||
wx.setStorageSync('userinfo', res.data.userinfo)
|
||||
if(res.data.userinfo.role_name == '游客' && this.globalData.rlogin){
|
||||
//未注册用户
|
||||
wx.reLaunch({
|
||||
url: '/pages/login/login',
|
||||
})
|
||||
// wx.reLaunch({
|
||||
// url: '/pages/login/login',
|
||||
// })
|
||||
}
|
||||
if(this.callBackUserinfo){
|
||||
// debugger;
|
||||
|
||||
this.callBackUserinfo(res.data.userinfo);
|
||||
}
|
||||
}
|
||||
|
@ -95,8 +95,8 @@ App({
|
|||
session_key:'',
|
||||
userInfo: {},
|
||||
userinfo: {}, // 服务器传回的消费者信息
|
||||
host: 'https://qw.ctc-zc.com/api',
|
||||
mediahost: 'https://qw.ctc-zc.com',
|
||||
host: 'https://dppz.ctc.ac.cn/api',
|
||||
mediahost: 'https://dppz.ctc.ac.cn/',
|
||||
token : '',
|
||||
rlogin:true
|
||||
}
|
||||
|
|
31
app.json
|
@ -52,20 +52,29 @@
|
|||
"pages/video/index",
|
||||
"pages/video/play",
|
||||
"pages/protocol/index",
|
||||
"pages/protocol/Privacy"
|
||||
"pages/protocol/Privacy",
|
||||
"pages/my/certificate",
|
||||
"pages/skill/index",
|
||||
"pages/skill/detail",
|
||||
"pages/youpei/company",
|
||||
"pages/youpei/detail",
|
||||
"pages/puzhuang/index",
|
||||
"pages/puzhuang/detail",
|
||||
"pages/youpei/illustrate",
|
||||
"pages/puzhuang/typelist"
|
||||
],
|
||||
"window": {
|
||||
"backgroundTextStyle": "light",
|
||||
"navigationBarBackgroundColor": "#ffffff",
|
||||
"navigationBarTitleText": "国检集团气味学堂",
|
||||
"navigationBarTitleText": "地坪铺装工工匠库",
|
||||
"navigationBarTextStyle": "black"
|
||||
},
|
||||
"tabBar": {
|
||||
"color": "#000000",
|
||||
"selectedColor": "#438af4",
|
||||
"selectedColor": "#7bbd52",
|
||||
"borderStyle": "black",
|
||||
"backgroundColor": "#ffffff",
|
||||
"fontSize":"14px",
|
||||
"fontSize": "14px",
|
||||
"list": [
|
||||
{
|
||||
"pagePath": "pages/main/main",
|
||||
|
@ -79,6 +88,12 @@
|
|||
"selectedIconPath": "images/file1.png",
|
||||
"text": "学习资料"
|
||||
},
|
||||
{
|
||||
"pagePath": "pages/material/video",
|
||||
"iconPath": "images/file.png",
|
||||
"selectedIconPath": "images/file1.png",
|
||||
"text": "视频"
|
||||
},
|
||||
{
|
||||
"pagePath": "pages/article/index",
|
||||
"iconPath": "images/news.png",
|
||||
|
@ -97,10 +112,12 @@
|
|||
"kbone": true,
|
||||
"weui": true
|
||||
},
|
||||
"usingComponents": { "mp-icon": "weui-miniprogram/icon/icon"},
|
||||
"usingComponents": {
|
||||
"mp-icon": "weui-miniprogram/icon/icon"
|
||||
},
|
||||
"plugins": {
|
||||
"tencentvideo": {
|
||||
"version": "2.1.15",
|
||||
"player": {
|
||||
"version": "2.6.1",
|
||||
"provider": "wxa75efa648b60994b"
|
||||
}
|
||||
},
|
||||
|
|
10
app.wxss
|
@ -28,20 +28,20 @@
|
|||
} */
|
||||
|
||||
button[type='primary'] {
|
||||
background-color: #438af4!important;
|
||||
background-color: #7bbd52!important;
|
||||
}
|
||||
button[disabled][type='primary'] {
|
||||
background-color: #fafafa!important;
|
||||
}
|
||||
/* .weui-cells_radio .weui-check[aria-checked=true]+.weui-icon-checked {
|
||||
color: #438af4!important;
|
||||
color: #7bbd52!important;
|
||||
} */
|
||||
.weui-cells_radio .weui-check[aria-checked=false]+.weui-icon-checked {
|
||||
color: #ffffff!important;
|
||||
}
|
||||
/* .weui-cells_radio .weui-check[aria-checked=true]+.weui-icon-checked{color:#438af4!important;-webkit-mask-image:url(data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M12%2022C6.477%2022%202%2017.523%202%2012S6.477%202%2012%202s10%204.477%2010%2010-4.477%2010-10%2010zm-1.177-7.86l-2.765-2.767L7%2012.431l3.119%203.121a1%201%200%20001.414%200l5.952-5.95-1.062-1.062-5.6%205.6z%22%2F%3E%3C%2Fsvg%3E)!important;mask-image:url(data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M12%2022C6.477%2022%202%2017.523%202%2012S6.477%202%2012%202s10%204.477%2010%2010-4.477%2010-10%2010zm-1.177-7.86l-2.765-2.767L7%2012.431l3.119%203.121a1%201%200%20001.414%200l5.952-5.95-1.062-1.062-5.6%205.6z%22%2F%3E%3C%2Fsvg%3E)!important} */
|
||||
.weui-cells_checkbox .weui-check[aria-checked=true]+.weui-icon-checked{color:#438af4!important;mask-image:url(data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2240%22%20height%3D%2240%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%23000000%22%20strokeWidth%3D%2220%22%20strokeLinecap%3D%22round%22%20strokeLinejoin%3D%22round%22%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%2210%22%3E%3C%2Fcircle%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%223%22%3E%3C%2Fcircle%3E%3C%2Fsvg%3E)!important;-webkit-mask-image:url(data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2240%22%20height%3D%2240%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%23000000%22%20strokeWidth%3D%2220%22%20strokeLinecap%3D%22round%22%20strokeLinejoin%3D%22round%22%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%2210%22%3E%3C%2Fcircle%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%223%22%3E%3C%2Fcircle%3E%3C%2Fsvg%3E)!important;
|
||||
/* .weui-cells_radio .weui-check[aria-checked=true]+.weui-icon-checked{color:#7bbd52!important;-webkit-mask-image:url(data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M12%2022C6.477%2022%202%2017.523%202%2012S6.477%202%2012%202s10%204.477%2010%2010-4.477%2010-10%2010zm-1.177-7.86l-2.765-2.767L7%2012.431l3.119%203.121a1%201%200%20001.414%200l5.952-5.95-1.062-1.062-5.6%205.6z%22%2F%3E%3C%2Fsvg%3E)!important;mask-image:url(data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M12%2022C6.477%2022%202%2017.523%202%2012S6.477%202%2012%202s10%204.477%2010%2010-4.477%2010-10%2010zm-1.177-7.86l-2.765-2.767L7%2012.431l3.119%203.121a1%201%200%20001.414%200l5.952-5.95-1.062-1.062-5.6%205.6z%22%2F%3E%3C%2Fsvg%3E)!important} */
|
||||
.weui-cells_checkbox .weui-check[aria-checked=true]+.weui-icon-checked{color:#7bbd52!important;mask-image:url(data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2240%22%20height%3D%2240%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%23000000%22%20strokeWidth%3D%2220%22%20strokeLinecap%3D%22round%22%20strokeLinejoin%3D%22round%22%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%2210%22%3E%3C%2Fcircle%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%223%22%3E%3C%2Fcircle%3E%3C%2Fsvg%3E)!important;-webkit-mask-image:url(data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2240%22%20height%3D%2240%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%23000000%22%20strokeWidth%3D%2220%22%20strokeLinecap%3D%22round%22%20strokeLinejoin%3D%22round%22%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%2210%22%3E%3C%2Fcircle%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%223%22%3E%3C%2Fcircle%3E%3C%2Fsvg%3E)!important;
|
||||
}
|
||||
.weui-cells_radio .weui-check[aria-checked=true]+.weui-icon-checked{
|
||||
color:#438af4!important;mask-image:url(data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2240%22%20height%3D%2240%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%23000000%22%20strokeWidth%3D%2220%22%20strokeLinecap%3D%22round%22%20strokeLinejoin%3D%22round%22%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%2210%22%3E%3C%2Fcircle%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%223%22%3E%3C%2Fcircle%3E%3C%2Fsvg%3E)!important;-webkit-mask-image:url(data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2240%22%20height%3D%2240%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%23000000%22%20strokeWidth%3D%2220%22%20strokeLinecap%3D%22round%22%20strokeLinejoin%3D%22round%22%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%2210%22%3E%3C%2Fcircle%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%223%22%3E%3C%2Fcircle%3E%3C%2Fsvg%3E)!important;
|
||||
color:#7bbd52!important;mask-image:url(data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2240%22%20height%3D%2240%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%23000000%22%20strokeWidth%3D%2220%22%20strokeLinecap%3D%22round%22%20strokeLinejoin%3D%22round%22%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%2210%22%3E%3C%2Fcircle%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%223%22%3E%3C%2Fcircle%3E%3C%2Fsvg%3E)!important;-webkit-mask-image:url(data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2240%22%20height%3D%2240%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%23000000%22%20strokeWidth%3D%2220%22%20strokeLinecap%3D%22round%22%20strokeLinejoin%3D%22round%22%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%2210%22%3E%3C%2Fcircle%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%223%22%3E%3C%2Fcircle%3E%3C%2Fsvg%3E)!important;
|
||||
}
|
BIN
images/file.png
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 4.2 KiB |
BIN
images/file1.png
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 3.7 KiB |
BIN
images/home.png
Before Width: | Height: | Size: 3.6 KiB After Width: | Height: | Size: 9.5 KiB |
BIN
images/home1.png
Before Width: | Height: | Size: 2.3 KiB After Width: | Height: | Size: 5.7 KiB |
After Width: | Height: | Size: 7.0 KiB |
Before Width: | Height: | Size: 56 KiB After Width: | Height: | Size: 37 KiB |
After Width: | Height: | Size: 189 KiB |
BIN
images/news.png
Before Width: | Height: | Size: 2.2 KiB After Width: | Height: | Size: 8.9 KiB |
BIN
images/news1.png
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 7.1 KiB |
Before Width: | Height: | Size: 412 B After Width: | Height: | Size: 5.8 KiB |
After Width: | Height: | Size: 5.2 KiB |
After Width: | Height: | Size: 4.8 KiB |
After Width: | Height: | Size: 2.5 KiB |
After Width: | Height: | Size: 5.6 KiB |
After Width: | Height: | Size: 7.6 KiB |
After Width: | Height: | Size: 4.8 KiB |
After Width: | Height: | Size: 5.9 KiB |
After Width: | Height: | Size: 1.9 KiB |
After Width: | Height: | Size: 2.2 KiB |
After Width: | Height: | Size: 49 KiB |
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 12 KiB |
Before Width: | Height: | Size: 2.1 KiB After Width: | Height: | Size: 7.5 KiB |
BIN
images/tiku.png
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 7.8 KiB |
BIN
images/user.png
Before Width: | Height: | Size: 4.4 KiB After Width: | Height: | Size: 9.9 KiB |
BIN
images/user1.png
Before Width: | Height: | Size: 2.9 KiB After Width: | Height: | Size: 7.4 KiB |
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 7.8 KiB |
After Width: | Height: | Size: 106 KiB |
After Width: | Height: | Size: 5.5 KiB |
|
@ -1,7 +1,7 @@
|
|||
<!--pages/admin/login.wxml-->
|
||||
<view class="page">
|
||||
<view class="page__hd" >
|
||||
<view class="page__title loginText" style="">中科辐射学堂</view>
|
||||
<view class="page__title loginText" style="">地坪铺装工</view>
|
||||
<view class="page__desc loginText" style="text-align:center">管理员登录</view>
|
||||
</view>
|
||||
<view class="page__bd loginFormWrap">
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/* pages/admin/login.wxss */
|
||||
.page{
|
||||
background: linear-gradient(to bottom, #438af4 10%, #438af4 40%, #94c0e6);
|
||||
background: linear-gradient(to bottom, #7bbd52 10%, #7bbd52 40%, #94c0e6);
|
||||
}
|
||||
.loginText{
|
||||
color: #ffffff;
|
||||
|
@ -19,7 +19,7 @@
|
|||
background-color: #ffffff!important;
|
||||
border-radius: 50rpx;
|
||||
font-weight: 500;
|
||||
color: #438af4;
|
||||
color: #7bbd52;
|
||||
}
|
||||
.loginItem{
|
||||
margin-bottom: 20rpx;
|
||||
|
|
|
@ -74,6 +74,7 @@ Page({
|
|||
})
|
||||
api.request(`/cms/article/${id}/`,'GET').then(res => {
|
||||
// res.data.content = res.data.content.replace(/"media/g, '"'+getApp().globalData.mediahost + '/media').replace(/\<img/gi, '<img style="max-width:100%;height:auto" ')
|
||||
|
||||
that.setData(res.data)
|
||||
wx.hideLoading({
|
||||
complete: (res) => {},
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<view class="weui-article__h1">{{title}}</view>
|
||||
<view class="page__desc">
|
||||
<text style="color:red;margin-right: 10rpx;" wx:if="{{is_top}}">置顶</text>
|
||||
<span>{{ifrom}}</span>
|
||||
|
||||
<span style="margin-left: auto;">{{update_time}}</span>
|
||||
</view>
|
||||
<view class="weui-article__p">
|
||||
|
|
|
@ -9,10 +9,13 @@ Page({
|
|||
results: [
|
||||
// {id:1,title:"开发需求",is_top:true,ifrom:"第一条咨询",update_time:"2022-10-01"}
|
||||
],
|
||||
type_: {1:"技能大赛",2:"铺装工匠",3:"培训信息",4:"大赛信息"},
|
||||
typeData:[{name:'培训信息',value:3},{name:'大赛信息',value:4}],//{1:"技能大赛",2:"铺装工匠",3:"培训信息",4:"大赛信息"},
|
||||
count:0,
|
||||
query: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
limit: 10,
|
||||
type:3
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -24,7 +27,15 @@ Page({
|
|||
wx.stopPullDownRefresh();
|
||||
that.getList(that.data.query)
|
||||
},
|
||||
|
||||
//tap切换
|
||||
typeChange(e){
|
||||
this.setData({
|
||||
['query.type']:e.target.dataset.type,
|
||||
['query.page']:1
|
||||
})
|
||||
this.data.query.type = e.target.dataset.type
|
||||
this.getList();
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
|
@ -39,6 +50,7 @@ Page({
|
|||
},
|
||||
getList: function () {
|
||||
var that = this
|
||||
|
||||
api.request('/cms/article/', 'GET', that.data.query).then(res => {
|
||||
if (that.data.query.page == 1) {
|
||||
that.data.results = res.data.results
|
||||
|
|
|
@ -1,20 +1,33 @@
|
|||
|
||||
<view class="page">
|
||||
<view class="head">{{count}}条资讯</view>
|
||||
<view class="weui-cells weui-cells_after-title" style="margin-top:0px;background:none;">
|
||||
<block wx:for="{{results}}" wx:key="unique">
|
||||
<navigator url="detail?id={{item.id}}" style="margin-bottom: 20rpx;box-shadow: 0 0 13rpx 8rpx #f7f7f7;background: #ffffff;" hover-class="weui-cell_active">
|
||||
<view class="weui-media-box__bd weui-media-box__bd_in-appmsg" style="padding: 20rpx;border: 1rpx solid #f7f7f7;border-radius: 10rpx;">
|
||||
<view class="weui-media-box__title">
|
||||
<view class="page" style="height:100%;box-sizing: border-box;">
|
||||
<!-- <view class="weui-flex searchWrap" style="background-color: #ffffff;">
|
||||
<input class="weui-input searchInput" maxlength="10" bindinput="bindKeyInput" placeholder="搜索文档名称"/>
|
||||
</view> -->
|
||||
|
||||
<view class="materialWrap" style="height:100%;background: #ffffff;">
|
||||
<view class="head">{{count}}条数据</view>
|
||||
|
||||
|
||||
<view class="listWrap" >
|
||||
<block wx:for="{{results}}" wx:key="unique">
|
||||
|
||||
<navigator url="detail?id={{item.id}}" style="margin-bottom: 10rpx;background: #ffffff;border-bottom: 1rpx solid #79be53;" hover-class="weui-cell_active">
|
||||
<view class="weui-media-box__bd weui-media-box__bd_in-appmsg" style="padding: 10rpx;border: 1rpx solid #f7f7f7;border-radius: 10rpx;background: #ffffff; ">
|
||||
<view class="weui-media-box__desc" style="display: flex;">
|
||||
<view class="weui-media-box__title" style="margin-right: 10rpx;">
|
||||
{{item.title}}
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<view class="weui-media-box__desc" style="display: flex;">
|
||||
<text wx:if="{{item.is_top}}" style="color:red;margin-right: 10rpx;">置顶 </text>
|
||||
<view>{{item.update_time}}</view>
|
||||
<view style="margin-left: auto;">{{item.ifrom}}</view>
|
||||
<view></view>
|
||||
<view style="margin-left: auto;">{{item.update_time}}</view>
|
||||
</view>
|
||||
</view>
|
||||
</navigator>
|
||||
</block>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
|
|
@ -1,6 +1,34 @@
|
|||
|
||||
.head{
|
||||
color:#fff;
|
||||
background-color: #438af4;
|
||||
background-color: #79be53;
|
||||
text-align: center;
|
||||
height:25px
|
||||
}
|
||||
.tabItem{
|
||||
height: 100rpx;
|
||||
line-height: 100rpx;
|
||||
text-align: center;
|
||||
position: relative;
|
||||
background-color: #f6f6f6;
|
||||
}
|
||||
.activeType{
|
||||
background-color: #ffffff;
|
||||
}
|
||||
.activeLine{
|
||||
height: 60rpx;
|
||||
width: 10rpx;
|
||||
position: absolute;
|
||||
top: 20rpx;
|
||||
background-color: #79be53;
|
||||
}
|
||||
|
||||
.listWrap{
|
||||
overflow: hidden;
|
||||
margin:10px;
|
||||
background: #ffffff;
|
||||
}
|
||||
.listItemWrap{
|
||||
position: relative;
|
||||
padding:20rpx 20rpx 0 20rpx;
|
||||
}
|
|
@ -0,0 +1,89 @@
|
|||
// pages/article/detail.js
|
||||
const api = require("../../utils/request.js");
|
||||
Page({
|
||||
|
||||
/**
|
||||
* 页面的初始数据
|
||||
*/
|
||||
data: {
|
||||
elink_f:'',
|
||||
domain:getApp().globalData.mediahost
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/
|
||||
onLoad: function (options) {
|
||||
this.getDetail(options.id)
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function () {
|
||||
|
||||
},
|
||||
|
||||
getDetail: function (id) {
|
||||
var that = this
|
||||
wx.showLoading({
|
||||
title: '加载中',
|
||||
mask:true
|
||||
})
|
||||
api.request(`/cms/article/${id}/`,'GET').then(res => {
|
||||
// res.data.content = res.data.content.replace(/"media/g, '"'+getApp().globalData.mediahost + '/media').replace(/\<img/gi, '<img style="max-width:100%;height:auto" ')
|
||||
|
||||
that.setData(res.data)
|
||||
wx.hideLoading({
|
||||
complete: (res) => {},
|
||||
})
|
||||
}).catch(res=>{
|
||||
wx.hideLoading({
|
||||
complete: (res) => {},
|
||||
})
|
||||
})
|
||||
},
|
||||
|
||||
})
|
|
@ -0,0 +1,5 @@
|
|||
{
|
||||
"usingComponents": {
|
||||
"mp-html": "/components/mp-html/index"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
<web-view src="elink" wx:if="{{elink}}"></web-view>
|
||||
<view class="page" wx:else data-weui-theme="light">
|
||||
<view class="page__bd">
|
||||
<view class="weui-article">
|
||||
<view class="weui-article__h1">{{title}}</view>
|
||||
<view class="page__desc">
|
||||
<text style="color:red;margin-right: 10rpx;" wx:if="{{is_top}}">置顶</text>
|
||||
|
||||
<span style="margin-left: auto;">{{update_time}}</span>
|
||||
</view>
|
||||
<view class="weui-article__p">
|
||||
<mp-html content="{{content}}" domain="{{domain}}"/>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
|
@ -0,0 +1,23 @@
|
|||
/* pages/article/detail.wxss */
|
||||
.page__title {
|
||||
font-size: 18px;
|
||||
}
|
||||
.weui-article{
|
||||
padding: 0!important;
|
||||
}
|
||||
.weui-article__h1{
|
||||
padding: 24rpx 24rpx 0rpx 24rpx;
|
||||
margin-bottom: 0;
|
||||
background-color: #ffffff;
|
||||
}
|
||||
.page__desc{
|
||||
margin-top: 0;
|
||||
padding: 10rpx 24rpx 15rpx 24rpx;
|
||||
background-color: #ffffff;
|
||||
margin-bottom: 20rpx;
|
||||
display: flex;
|
||||
}
|
||||
.weui-article__p{
|
||||
padding: 24rpx;
|
||||
background-color: #ffffff;
|
||||
}
|
|
@ -0,0 +1,118 @@
|
|||
// pages/lianxi/index.js
|
||||
const api = require("../../utils/request.js");
|
||||
Page({
|
||||
|
||||
/**
|
||||
* 页面的初始数据
|
||||
*/
|
||||
data: {
|
||||
results: [
|
||||
// {id:1,title:"开发需求",is_top:true,ifrom:"第一条咨询",update_time:"2022-10-01"}
|
||||
],
|
||||
type_: {1:"技能大赛",2:"铺装工匠",3:"培训信息",4:"大赛信息"},
|
||||
typeData:[{name:'培训信息',value:3},{name:'大赛信息',value:4}],//{1:"技能大赛",2:"铺装工匠",3:"培训信息",4:"大赛信息"},
|
||||
count:0,
|
||||
query: {
|
||||
page: 1,
|
||||
limit: 10,
|
||||
type:3
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/
|
||||
onLoad: function () {
|
||||
var that = this
|
||||
wx.stopPullDownRefresh();
|
||||
that.getList(that.data.query)
|
||||
},
|
||||
//tap切换
|
||||
typeChange(e){
|
||||
this.setData({
|
||||
['query.type']:e.target.dataset.type,
|
||||
['query.page']:1
|
||||
})
|
||||
this.data.query.type = e.target.dataset.type
|
||||
this.getList();
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {
|
||||
},
|
||||
getList: function () {
|
||||
var that = this
|
||||
api.request('/cms/article/', 'GET', that.data.query).then(res => {
|
||||
if (that.data.query.page == 1) {
|
||||
that.data.results = res.data.results
|
||||
} else {
|
||||
that.data.results = that.data.results.concat(res.data.results)
|
||||
}
|
||||
for(var i = 0;i<that.data.results.length;i++){
|
||||
that.data.results[i].update_time = that.data.results[i].update_time.substring(0,10)
|
||||
}
|
||||
that.setData({
|
||||
results: that.data.results,
|
||||
count: res.data.count
|
||||
})
|
||||
|
||||
})
|
||||
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {
|
||||
var that = this
|
||||
that.data.query.page = 1;
|
||||
that.getList();
|
||||
wx.stopPullDownRefresh();
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {
|
||||
var that = this
|
||||
if (that.data.count <= that.data.query.page * that.data.query.limit) {
|
||||
wx.showToast({
|
||||
title: '没有更多了',
|
||||
icon: 'none'
|
||||
})
|
||||
} else {
|
||||
that.data.query.page = that.data.query.page + 1
|
||||
that.getList()
|
||||
}
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function () {
|
||||
|
||||
},
|
||||
|
||||
})
|
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"usingComponents": {},
|
||||
"enablePullDownRefresh": true,
|
||||
"onReachBottomDistance": 50,
|
||||
"navigationBarTitleText": "新闻资讯"
|
||||
}
|
|
@ -0,0 +1,38 @@
|
|||
|
||||
<view class="page" style="height:100%;box-sizing: border-box;">
|
||||
<!-- <view class="weui-flex searchWrap" style="background-color: #ffffff;">
|
||||
<input class="weui-input searchInput" maxlength="10" bindinput="bindKeyInput" placeholder="搜索文档名称"/>
|
||||
</view> -->
|
||||
|
||||
<view class="materialWrap" style="height:100%;background: #ffffff;">
|
||||
<view class="head">{{count}}条数据</view>
|
||||
<view class="tabWrap" >
|
||||
<view wx:for="{{typeData}}" class="tabItem {{ item.value==query.type?'activeType':'' }}" bindtap="typeChange" data-type="{{item.value}}">
|
||||
<view class="activeLine" wx:if="{{item.value==query.type}}"></view>{{item.name}}
|
||||
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="listWrap" style="width: calc(100%-200rpx);">
|
||||
<block wx:for="{{results}}" wx:key="unique">
|
||||
|
||||
<navigator url="detail?id={{item.id}}" style="margin-bottom: 10rpx;background: #ffffff;border-bottom: 1rpx solid #79be53;" hover-class="weui-cell_active">
|
||||
<view class="weui-media-box__bd weui-media-box__bd_in-appmsg" style="padding: 10rpx;border: 1rpx solid #f7f7f7;border-radius: 10rpx;background: #ffffff; ">
|
||||
<view class="weui-media-box__desc" style="display: flex;">
|
||||
<view class="weui-media-box__title" style="margin-right: 10rpx;">
|
||||
{{item.title}}
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<view class="weui-media-box__desc" style="display: flex;">
|
||||
<text wx:if="{{item.is_top}}" style="color:red;margin-right: 10rpx;">置顶 </text>
|
||||
<view></view>
|
||||
<view style="margin-left: auto;">{{item.update_time}}</view>
|
||||
</view>
|
||||
</view>
|
||||
</navigator>
|
||||
</block>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
|
@ -0,0 +1,42 @@
|
|||
|
||||
.head{
|
||||
color:#fff;
|
||||
background-color: #79be53;
|
||||
text-align: center;
|
||||
height:25px
|
||||
}
|
||||
.tabItem{
|
||||
height: 100rpx;
|
||||
line-height: 100rpx;
|
||||
text-align: center;
|
||||
position: relative;
|
||||
background-color: #f6f6f6;
|
||||
}
|
||||
.activeType{
|
||||
background-color: #ffffff;
|
||||
}
|
||||
.activeLine{
|
||||
height: 60rpx;
|
||||
width: 10rpx;
|
||||
position: absolute;
|
||||
top: 20rpx;
|
||||
background-color: #79be53;
|
||||
}
|
||||
.tabWrap{
|
||||
float: left;
|
||||
height: 100%;
|
||||
width: 200rpx;
|
||||
border-right: 1rpx solid #eeeeee;
|
||||
position: fixed;
|
||||
background: #ffffff;
|
||||
}
|
||||
.listWrap{
|
||||
overflow: hidden;
|
||||
margin-top:0px;
|
||||
padding-left: 200rpx;
|
||||
background: #ffffff;
|
||||
}
|
||||
.listItemWrap{
|
||||
position: relative;
|
||||
padding:20rpx 20rpx 0 20rpx;
|
||||
}
|
|
@ -6,14 +6,13 @@ Page({
|
|||
* 页面的初始数据
|
||||
*/
|
||||
data: {
|
||||
|
||||
level:{4:'初级工',3:'中级工',2:'高级工',1:'技师',0:'高级技师'},
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/
|
||||
onLoad: function (options) {
|
||||
debugger;
|
||||
console.log(options)
|
||||
let id = options.id
|
||||
this.getDetail(id)
|
||||
|
|
|
@ -1,26 +1,46 @@
|
|||
<!--pages/candidate/detail.wxml-->
|
||||
<view style="background-color: #ffffff;margin:5px 5px;height: 99%;" >
|
||||
<view style="text-align: center;">
|
||||
<image class="logoImg" src="/images/logoImg.png" mode="aspectFit"></image>
|
||||
<image class="logoImg" src="/images/logoimage.png" mode="aspectFit"></image>
|
||||
</view>
|
||||
<view class="weui-panel__bd">
|
||||
<view class="weui-media-box weui-media-box_text" style="text-align:center">
|
||||
<h4 class="weui-media-box__title">
|
||||
<text style="color:blue;">{{candidate.consumer_name}}</text>
|
||||
{{candidate.number}}
|
||||
</h4>
|
||||
<view class="weui-media-box__desc">
|
||||
{{candidate.ID_number}}
|
||||
</view>
|
||||
<view class="weui-media-box__desc">
|
||||
{{candidate.workscope_name}}
|
||||
</view>
|
||||
<view class="weui-media-box__desc">
|
||||
{{candidate.start_date}}至{{candidate.end_date}}
|
||||
</view>
|
||||
</view>
|
||||
<view class="weui-panel__bd" style="background-color: #ffffff;margin:0 10px" >
|
||||
<view class="weui-media-box weui-media-box_text text-center">
|
||||
<h4 class="weui-media-box__title">
|
||||
<text class="text-blue">{{candidate.consumer_name}}</text>
|
||||
</h4>
|
||||
|
||||
<view class="weui-media-box__desc">
|
||||
性别: {{candidate.gender}}
|
||||
</view>
|
||||
<view class="weui-media-box__desc">
|
||||
证书编号: {{candidate.number}}
|
||||
</view>
|
||||
<view class="weui-media-box__desc">
|
||||
公司: {{candidate.company_name}}
|
||||
</view>
|
||||
<view class="weui-media-box__desc">
|
||||
身份证号: {{candidate.ID_number}}
|
||||
</view>
|
||||
<view class="weui-media-box__desc">
|
||||
职业工种:地坪铺装工
|
||||
</view>
|
||||
|
||||
<view class="weui-media-box__desc">
|
||||
职业方向: {{candidate.workscope_name}}
|
||||
</view>
|
||||
<view class="weui-media-box__desc">
|
||||
职业等级: {{ level[candidate.opllevel]}}
|
||||
</view>
|
||||
<view class="weui-media-box__desc">
|
||||
发证时间 {{candidate.issue_date}}
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<!--
|
||||
<a class="weui-btn weui-btn_primary" bindtap="goCandidate">查看证书</a>
|
||||
<a class="weui-btn weui-btn_default" bindtap="copyUrl">复制证书链接</a>
|
||||
<a class="weui-btn weui-btn_default" bindtap="godetail" wx:if="{{candidate.examtest!==null}}">答题信息</a>
|
||||
<a class="weui-btn weui-btn_default" bindtap="downDoc" wx:if="{{candidate.examtest!==null}}">下载完整文档</a>
|
||||
-->
|
||||
</view>
|
||||
|
||||
|
|
|
@ -4,4 +4,32 @@
|
|||
height:200rpx;
|
||||
margin-top: 50rpx;
|
||||
border-radius: 100rpx;
|
||||
}
|
||||
.weui-media-box {
|
||||
border: 1px solid #e5e5e5;
|
||||
border-radius: 8px;
|
||||
padding: 16px;
|
||||
margin: 10px;
|
||||
background-color: #f9f9f9;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
.weui-media-box__title {
|
||||
font-size: 25px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.weui-media-box__desc {
|
||||
font-size: 16px;
|
||||
color: #666;
|
||||
margin-bottom: 6px;
|
||||
}
|
||||
|
||||
.text-blue {
|
||||
color: #79be53;
|
||||
}
|
||||
|
||||
.text-center {
|
||||
text-align: center;
|
||||
}
|
|
@ -10,9 +10,43 @@ Page({
|
|||
query: {
|
||||
page: 1,
|
||||
limit: 10
|
||||
}
|
||||
},
|
||||
query2: {
|
||||
page: 1,
|
||||
limit: 10000
|
||||
},
|
||||
currentTab: 'tab1' ,// 默认选中 Tab 1
|
||||
consumers: [
|
||||
],
|
||||
searchQuery: '',
|
||||
level:{4:'初级工',3:'中级工',2:'高级工',1:'技师',0:'高级技师'},
|
||||
},
|
||||
switchTab: function(event) {
|
||||
const tab = event.currentTarget.dataset.tab;
|
||||
this.setData({
|
||||
currentTab: tab
|
||||
});
|
||||
},
|
||||
onSearchInput: function (event) {
|
||||
const query = event.detail.value.toLowerCase();
|
||||
console.log(query)
|
||||
if(query=="")
|
||||
{
|
||||
this.getList2();
|
||||
}
|
||||
|
||||
const consumers = this.data.consumers.filter(item => {
|
||||
return Object.values(item).some(value =>
|
||||
String(value).toLowerCase().includes(query)
|
||||
);
|
||||
});
|
||||
this.setData({ consumers });
|
||||
|
||||
},
|
||||
|
||||
onLoad: function () {
|
||||
this.getList2();
|
||||
|
||||
},
|
||||
onShow: function () {
|
||||
this.getList();
|
||||
|
@ -30,6 +64,56 @@ Page({
|
|||
wx.hideLoading()
|
||||
)
|
||||
},
|
||||
//获证信息统计,查询所有证书
|
||||
getList2: function() {
|
||||
var that = this
|
||||
wx.showLoading({
|
||||
title: '正在加载...',
|
||||
})
|
||||
api.request('/crm/candidate/', 'GET',that.data.query2).then(res => {
|
||||
if (that.data.query2.page == 1) {
|
||||
that.data.results = res.data.results
|
||||
} else {
|
||||
that.data.results = that.data.results.concat(res.data.results)
|
||||
}
|
||||
this.setData({
|
||||
consumers:res.data.results,
|
||||
})
|
||||
|
||||
}).catch(
|
||||
wx.hideLoading()
|
||||
)
|
||||
},
|
||||
|
||||
//获证信息统计点击弹窗展示详细信息
|
||||
showModal: function (event) {
|
||||
const item = event.currentTarget.dataset.item;
|
||||
console.log(item)
|
||||
// level:{2:'初级工',1:'中级工',0:'高级工',4:'技师',3:'高级技师'},
|
||||
let level = ""
|
||||
switch(item.opllevel){
|
||||
case 0:
|
||||
level='高级技师';
|
||||
break;
|
||||
case 1:
|
||||
level='技师';
|
||||
break;
|
||||
case 2:
|
||||
level='高级工';
|
||||
break;
|
||||
case 3:
|
||||
level='中级工';
|
||||
break;
|
||||
default:
|
||||
level='初级工';
|
||||
|
||||
}
|
||||
wx.showModal({
|
||||
title: '基本信息',
|
||||
content: `姓名: ${item.consumer_name} \n 性别: ${item.gender}\n 职业方向: 地坪铺装工 \n职业等级: ${level}\n 获证时间: ${item.issue_date}\n 所在企业: ${item.company_name}`,
|
||||
showCancel: false,
|
||||
});
|
||||
},
|
||||
bindinput: function(e){
|
||||
this.setData({
|
||||
search:e.detail.value
|
||||
|
@ -66,14 +150,14 @@ Page({
|
|||
// })
|
||||
}else{
|
||||
wx.showToast({
|
||||
title: '请填写正确的证书编号或身份证号',
|
||||
title: '请填写正确的身份证号',
|
||||
icon: 'none',
|
||||
duration: 1500
|
||||
})
|
||||
}
|
||||
},
|
||||
toDetail: function(e){
|
||||
debugger;
|
||||
|
||||
var url = e.currentTarget.dataset.url;
|
||||
var id = e.currentTarget.dataset.id;
|
||||
console.log(id)
|
||||
|
|
|
@ -1,12 +1,47 @@
|
|||
<view>
|
||||
<view class="searWrap">
|
||||
<input class="infoInput" placeholder="填写证书编号/身份证号" placeholder-class="weui-input__placeholder" bindinput="bindinput"
|
||||
<view class="page">
|
||||
<view class="container">
|
||||
<view class="tab" style="position:fixed;z-index:999;width:100%;top:0px;left:0;background: #fff;">
|
||||
<view class="tab-item" bindtap="switchTab" data-tab="tab1">获证信息统计</view>
|
||||
<view class="tab-item" bindtap="switchTab" data-tab="tab2">证书真伪查询</view>
|
||||
<view style="position: absolute;z-index:999;top:46px;left:0;width:100%;background: #fff;" wx:if="{{currentTab === 'tab1'}}">
|
||||
<view style="padding-top: 18px;" >
|
||||
<input class="search-input" placeholder="搜索..." bindinput="onSearchInput" />
|
||||
</view>
|
||||
<view class="table-header" >
|
||||
<text style="width:60px;">姓名</text>
|
||||
<text style="width:90px;">所在企业</text>
|
||||
<text style="width:70px;">职业等级</text>
|
||||
<text style="width:100px;">职业方向</text>
|
||||
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="tab-content" style="height:500px;padding-top:150px;position: relative;z-index:1;" >
|
||||
<view wx:if="{{currentTab === 'tab1'}}">
|
||||
|
||||
<view class="table">
|
||||
|
||||
<view class="table-body" >
|
||||
<block wx:for="{{consumers}}" wx:key="index">
|
||||
<view class="table-row" bindtap="showModal" data-item="{{item}}">
|
||||
<text style="width:60px">{{item.consumer_name}}</text>
|
||||
<text style="width:90px;">{{item.company_name}}</text>
|
||||
<text style="width:70px;">{{level[item.opllevel]}}</text>
|
||||
<text style="width:100px;">{{item.workscope_name}}</text>
|
||||
</view>
|
||||
</block>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<view wx:if="{{currentTab === 'tab2'}}" style="top:-120px;position: relative;z-index:1;">
|
||||
<view class="searWrap" >
|
||||
<input class="infoInput" placeholder="填写:身份证号" placeholder-class="weui-input__placeholder" bindinput="bindinput"
|
||||
value="{{ID_number}}"/>
|
||||
<view class="searchBtn" bindtap="search">查询</view>
|
||||
</view>
|
||||
<view class="listWrap">
|
||||
<view wx:if="{{candidates.length}}">
|
||||
<view class="listTitle">证书列表</view>
|
||||
<block wx:for="{{candidates}}" wx:key="unique">
|
||||
<view class="weui-cell" data-url="{{item.img}}" data-id="{{item.id}}" bindlongpress="copyUrl" style="border-bottom: 1rpx solid #eeeeee;" bindtap="toDetail">
|
||||
<view class="weui-cell__bd">
|
||||
|
@ -20,7 +55,7 @@
|
|||
</view>
|
||||
</view>
|
||||
<view class="weui-cell__ft">
|
||||
<view style="color:green">通过考核</view>
|
||||
<view style="color:green">查看详情</view>
|
||||
<!-- <view >长按复制地址去浏览器打开</view> -->
|
||||
</view>
|
||||
</view>
|
||||
|
@ -28,4 +63,9 @@
|
|||
</view>
|
||||
<view wx:else style="text-align:center">暂无证书信息</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
</view>
|
|
@ -1,4 +1,7 @@
|
|||
/* pages/candidate/index.wxss */
|
||||
page{
|
||||
background: #ffffff;
|
||||
}
|
||||
.searWrap{
|
||||
display: flex;
|
||||
/* margin-top: 30rpx; */
|
||||
|
@ -11,10 +14,10 @@
|
|||
height: 100rpx;
|
||||
line-height: 100rpx;
|
||||
text-align: center;
|
||||
color: #ffffff;
|
||||
color: #131212;
|
||||
border-radius: 40rpx;
|
||||
margin-right: 20rpx;
|
||||
background-color:#438af4 ;
|
||||
background-color:#faad14 ;
|
||||
}
|
||||
.infoInput{
|
||||
flex: 4;
|
||||
|
@ -37,4 +40,69 @@
|
|||
padding-left: 30rpx;
|
||||
line-height: 70rpx;
|
||||
font-size: 36rpx;
|
||||
}
|
||||
|
||||
.container {
|
||||
padding: 0px;
|
||||
background-color: #ffffff;
|
||||
}
|
||||
|
||||
.tab {
|
||||
display: flex;
|
||||
color:#ffffff
|
||||
|
||||
}
|
||||
|
||||
.tab-item {
|
||||
flex: 1;
|
||||
padding: 10px;
|
||||
text-align: center;
|
||||
background-color: #79be53;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.tab-item:hover {
|
||||
background-color: #01764a;
|
||||
}
|
||||
|
||||
.tab-content {
|
||||
margin-top: 20px;
|
||||
padding: 3px;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.search-input {
|
||||
margin-bottom: 16px;
|
||||
width: 100%;
|
||||
height:40px;
|
||||
border-radius: 10rpx;
|
||||
color: #131212;
|
||||
background-color: rgb(243, 241, 241);
|
||||
}
|
||||
|
||||
.table {
|
||||
border: 1px solid #ccc;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.table-header, .table-row {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
padding: 10px;
|
||||
}
|
||||
|
||||
.table-header {
|
||||
background-color: #00adca;
|
||||
color: #f7f8f4;
|
||||
font-weight: bold;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.table-row text {
|
||||
border-bottom: 1px solid #eee;
|
||||
text-align: center;
|
||||
white-space: nowrap; /* 不换行 */
|
||||
overflow: hidden; /* 隐藏超出部分 */
|
||||
text-overflow: ellipsis; /* 省略号 */
|
||||
}
|
|
@ -6,7 +6,7 @@
|
|||
text-align: center;
|
||||
color: #ffffff;
|
||||
border-radius: 20rpx;
|
||||
background-color:#438af4 ;
|
||||
background-color:#7bbd52 ;
|
||||
}
|
||||
.noCertificate{
|
||||
color: #666666;
|
||||
|
|
|
@ -51,7 +51,7 @@
|
|||
<view class="weui-article__h2" wx:else style="color:red;font-weight:bold">回答有误!</view>
|
||||
<view class="weui-article__h2">正确答案是{{tm_current.right}},你的答案是{{tm_current.user_answer}}</view>
|
||||
<view class="weui-article__title" style="font-size: 30rpx;">
|
||||
<span style="color:#438af4;font-weight: bold;font-size: 34rpx;">解析: </span>
|
||||
<span style="color:#7bbd52;font-weight: bold;font-size: 34rpx;">解析: </span>
|
||||
<span wx:if="{{tm_current.resolution}}">{{tm_current.resolution}}</span>
|
||||
<span wx:else>无</span>
|
||||
</view>
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
width:100%;
|
||||
height:30px;
|
||||
color:#fff;
|
||||
background-color: #438af4;
|
||||
background-color: #7bbd52;
|
||||
text-align: center;
|
||||
}
|
||||
.btns{
|
||||
|
@ -22,7 +22,7 @@
|
|||
}
|
||||
.txlabel{
|
||||
color:#fff;
|
||||
background-color: #438af4;
|
||||
background-color: #7bbd52;
|
||||
border-radius: 2px;
|
||||
font-weight: 500;
|
||||
font-size: 30rpx;
|
||||
|
|
|
@ -74,7 +74,7 @@
|
|||
<view class="weui-article__h2" wx:else style="color:red;font-weight:bold">回答有误!</view>
|
||||
<view class="weui-article__h2">正确答案是{{currentTm.right}}<span>,你的答案是{{currentTm.user_answer}}</span></view>
|
||||
<view class="weui-article__title" style="font-size: 30rpx;">
|
||||
<span style="color:#438af4;font-weight: bold;font-size: 34rpx;">解析: </span>
|
||||
<span style="color:#7bbd52;font-weight: bold;font-size: 34rpx;">解析: </span>
|
||||
<span wx:if="{{tm_current.question.resolution}}">{{tm_current.question.resolution}}</span>
|
||||
<span wx:else>暂无解析</span>
|
||||
</view>
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
}
|
||||
.txlabel{
|
||||
color:#fff;
|
||||
background-color: #438af4;
|
||||
background-color: #7bbd52;
|
||||
border-radius: 2px;
|
||||
font-weight: 500;
|
||||
font-size: 30rpx;
|
||||
|
@ -31,7 +31,7 @@
|
|||
width: 100%;
|
||||
position: fixed;
|
||||
padding: 15rpx 0;
|
||||
background-color:#438af4
|
||||
background-color:#7bbd52
|
||||
}
|
||||
.typeBtns{
|
||||
margin: auto;
|
||||
|
@ -48,7 +48,7 @@
|
|||
border-radius: 6rpx 0 0 6rpx;
|
||||
}
|
||||
.datiBtn{
|
||||
color: #438af4;
|
||||
color: #7bbd52;
|
||||
background: #ffffff;
|
||||
|
||||
}
|
||||
|
@ -70,7 +70,7 @@
|
|||
}
|
||||
|
||||
/* .weui-cells_radio .weui-check[aria-checked=true]+.weui-icon-checked {
|
||||
color: #438af4;
|
||||
color: #7bbd52;
|
||||
}
|
||||
.weui-cells_radio .weui-check[aria-checked=false]+.weui-icon-checked {
|
||||
color: #ffffff;
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
color: #ffffff;
|
||||
border-radius: 40rpx;
|
||||
font-size: 36rpx;
|
||||
background-color:#438af4 ;
|
||||
background-color:#7bbd52 ;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<view style="padding: 20rpx;color: #333333;">
|
||||
<!-- 统计 -->
|
||||
<view style="padding: 20rpx;line-height: 80rpx;font-size: 36rpx;color: #333333;">
|
||||
<view>考试次数:{{total}}(次)</view>
|
||||
<view>模考次数:{{total}}(次)</view>
|
||||
<view>通过率:{{pass_rate}}(%)</view>
|
||||
<view>平均分:{{avg_score}}</view>
|
||||
</view>
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<view class="page">
|
||||
<view style="position: relative;background: #ffffff;padding-bottom: 20rpx;">
|
||||
<view class="searchBtn" bindtap="searchItem">搜题</view>
|
||||
<view style="color:#438af4;font-weight:bold;text-align:center">{{workscopeName}}</view>
|
||||
<view style="color:#7bbd52;font-weight:bold;text-align:center">{{workscopeName}}</view>
|
||||
</view>
|
||||
<view>
|
||||
<block wx:for="{{questioncatData}}" wx:key="unique">
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
margin-top: 0!important;
|
||||
}
|
||||
.blueBold{
|
||||
color:#438af4;
|
||||
color:#7bbd52;
|
||||
font-weight:bold
|
||||
}
|
||||
.kaishilianxi{
|
||||
|
@ -15,8 +15,8 @@
|
|||
padding: 6rpx 15rpx;
|
||||
font-size: 28rpx;
|
||||
border-radius: 40rpx;
|
||||
border: 1rpx solid #438af4;
|
||||
color: #438af4;
|
||||
border: 1rpx solid #7bbd52;
|
||||
color: #7bbd52;
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
right: 10rpx;
|
||||
|
@ -25,7 +25,7 @@
|
|||
.searchBtn{
|
||||
position: absolute;
|
||||
right: 20rpx;
|
||||
background: #438af4;
|
||||
background: #7bbd52;
|
||||
color: #ffffff;
|
||||
font-size: 28rpx;
|
||||
padding: 6rpx 30rpx;
|
||||
|
|
|
@ -17,13 +17,13 @@ Page({
|
|||
page:1,
|
||||
domain:getApp().globalData.mediahost,
|
||||
moShi:'背题模式',
|
||||
isTest:true,
|
||||
isTest:true,
|
||||
processCard:false,
|
||||
},
|
||||
changeM: function () {
|
||||
var that = this;
|
||||
if(that.data.isTest){
|
||||
that.setData({
|
||||
if(that.data.isTest){
|
||||
that.setData({
|
||||
isTest:false,
|
||||
})
|
||||
that.showOptions()
|
||||
|
@ -32,23 +32,23 @@ Page({
|
|||
isTest:true,
|
||||
})
|
||||
}
|
||||
// if(that.data.moShi=='看题模式'){
|
||||
// that.setData({
|
||||
// moShi:'背题模式',
|
||||
// })
|
||||
// that.showOptions()
|
||||
// }else{
|
||||
// that.setData({
|
||||
// moShi: '看题模式',
|
||||
// })
|
||||
// }
|
||||
if(that.data.moShi=='看题模式'){
|
||||
that.setData({
|
||||
moShi:'背题模式',
|
||||
})
|
||||
that.showOptions()
|
||||
}else{
|
||||
that.setData({
|
||||
moShi: '看题模式',
|
||||
})
|
||||
}
|
||||
},
|
||||
radioChange: function(e) {
|
||||
var that = this
|
||||
that.data.tm_current['user_answer'] = e.detail.value
|
||||
that.data.tms[that.data.tm_index] = that.data.tm_current
|
||||
that.showAnswer()
|
||||
if (!that.data.isTest && that.data.ydtms.indexOf(that.data.tm_current.id) == -1) {
|
||||
if (that.data.moShi == '背题模式' && that.data.ydtms.indexOf(that.data.tm_current.id) == -1) {
|
||||
that.data.ydtms.push(that.data.tm_current.id)
|
||||
}
|
||||
},
|
||||
|
@ -56,7 +56,7 @@ Page({
|
|||
var that = this
|
||||
that.data.tm_current['user_answer'] = e.detail.value
|
||||
that.data.tms[that.data.tm_index] = that.data.tm_current
|
||||
if (!that.data.isTest && that.data.ydtms.indexOf(that.data.tm_current.id) == -1) {
|
||||
if (that.data.moShi=='背题模式' && that.data.ydtms.indexOf(that.data.tm_current.id) == -1) {
|
||||
that.data.ydtms.push(that.data.tm_current.id)
|
||||
}
|
||||
},
|
||||
|
@ -106,13 +106,13 @@ Page({
|
|||
getTms: function() {
|
||||
var that = this
|
||||
var query = {
|
||||
limit:10,
|
||||
page:that.data.page,
|
||||
questioncat: that.data.questioncat,
|
||||
ydtms: wx.getStorageSync('cat' + that.data.questioncat.toString()),
|
||||
ydtms_:that.data.ydtms
|
||||
}
|
||||
api.request('/question/question/exercise/', 'POST', query).then(res => {
|
||||
console.log(query);
|
||||
api.request('/question/question/exercise/?limit=10&page='+that.data.page, 'POST', query).then(res => {
|
||||
console.log(res.data.results);
|
||||
if(res.code>=200){
|
||||
for (var i = 0; i < res.data.results.length; i++) {
|
||||
if(res.data.results[i].img){
|
||||
|
@ -122,6 +122,7 @@ Page({
|
|||
|
||||
that.data.tms = that.data.tms.concat(res.data.results)
|
||||
that.showTm(that.data.tm_index) //展示题目和答案
|
||||
console.log(res.data);
|
||||
that.setData({
|
||||
tmtotal: res.data.count,
|
||||
})
|
||||
|
@ -147,6 +148,7 @@ Page({
|
|||
onReachBottom: function() {
|
||||
|
||||
},
|
||||
//展示题目和答案
|
||||
showTm: function(index) {
|
||||
var that = this
|
||||
if(index<that.data.tms.length){
|
||||
|
@ -170,6 +172,7 @@ Page({
|
|||
}
|
||||
|
||||
},
|
||||
//判题
|
||||
panTi: function() {
|
||||
var that = this
|
||||
let tm_current = that.data.tm_current
|
||||
|
@ -193,6 +196,7 @@ Page({
|
|||
}
|
||||
return isright
|
||||
},
|
||||
//答案
|
||||
showAnswer: function() {
|
||||
let isright = this.panTi()
|
||||
this.setData({
|
||||
|
@ -201,6 +205,7 @@ Page({
|
|||
tm_current: this.data.tm_current
|
||||
})
|
||||
},
|
||||
//下题
|
||||
next: function() {
|
||||
var that = this
|
||||
var tm_index = that.data.tm_index
|
||||
|
@ -217,6 +222,7 @@ Page({
|
|||
})
|
||||
if (tm_index + 1 > that.data.tms.length) {
|
||||
that.data.page = that.data.page + 1
|
||||
console.log(that.data.page);
|
||||
that.getTms()
|
||||
} else {
|
||||
that.showTm(tm_index)
|
||||
|
@ -226,6 +232,7 @@ Page({
|
|||
|
||||
|
||||
},
|
||||
//上题
|
||||
previous: function() {
|
||||
var that = this
|
||||
var tm_index = that.data.tm_index - 1
|
||||
|
@ -234,6 +241,7 @@ Page({
|
|||
})
|
||||
that.showTm(tm_index)
|
||||
},
|
||||
//展示选项
|
||||
showOptions: function() {
|
||||
let tm_current = this.data.tm_current
|
||||
let options = []
|
||||
|
@ -258,6 +266,7 @@ Page({
|
|||
options: options
|
||||
})
|
||||
},
|
||||
//收藏
|
||||
shoucang: function() {
|
||||
var that = this
|
||||
var tm_current = that.data.tm_current
|
||||
|
@ -286,5 +295,6 @@ Page({
|
|||
})
|
||||
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
})
|
|
@ -85,7 +85,7 @@
|
|||
<text wx:if="{{isTest}}">,你的答案:{{tm_current.user_answer}}</text>
|
||||
</view>
|
||||
<view class="weui-article__title" style="font-size: 30rpx;">
|
||||
<span style="color:#438af4;font-weight: bold;font-size: 34rpx;">解析: </span>
|
||||
<span style="color:#7bbd52;font-weight: bold;font-size: 34rpx;">解析: </span>
|
||||
<span wx:if="{{tm_current.question.resolution}}">{{tm_current.question.resolution}}</span>
|
||||
<span wx:else>暂无解析</span>
|
||||
</view>
|
||||
|
@ -102,8 +102,8 @@
|
|||
<button type="primary" size="mini" bindtap="showAnswer">答案</button>
|
||||
</view>
|
||||
<view style="width:25%">
|
||||
<image style="width: 60rpx;" mode="widthFix" src="/images/shoucang.png" bindtap="shoucang" wx:if="{{tm_current.is_collect}}"></image>
|
||||
<image style="width:60rpx;" mode="widthFix" src="/images/shoucang1.png" bindtap="shoucang" wx:else></image>
|
||||
<image style="width: 60rpx;" mode="widthFix" src="/images/shoucang1.png" bindtap="shoucang" wx:if="{{tm_current.is_collect}}"></image>
|
||||
<image style="width:60rpx;" mode="widthFix" src="/images/shoucang.png" bindtap="shoucang" wx:else></image>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
@ -113,6 +113,5 @@
|
|||
<view>
|
||||
<view class=""></view>
|
||||
</view>
|
||||
ddddddddddddd
|
||||
</view>
|
||||
</mp-halfScreenDialog>
|
|
@ -14,7 +14,7 @@
|
|||
}
|
||||
.txlabel{
|
||||
color:#fff;
|
||||
background-color:#438af4;
|
||||
background-color:#7bbd52;
|
||||
border-radius: 2px;
|
||||
padding: 6rpx 16rpx;
|
||||
font-weight: 500;
|
||||
|
@ -39,7 +39,7 @@
|
|||
position: fixed;
|
||||
padding-bottom: 20rpx;
|
||||
padding: 15rpx;
|
||||
background-color: #438af4;
|
||||
background-color: #7bbd52;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
.typeBtns{
|
||||
|
@ -57,7 +57,7 @@
|
|||
border-radius: 6rpx 0 0 6rpx;
|
||||
}
|
||||
.datiBtn{
|
||||
color: #438af4;
|
||||
color: #7bbd52;
|
||||
background: #ffffff;
|
||||
|
||||
}
|
||||
|
|
|
@ -46,5 +46,5 @@
|
|||
<view>《隐私政策》</view>
|
||||
</navigator>
|
||||
</view>
|
||||
<view class="weui-footer__text">Copyright © 2020-2022 国检集团</view>
|
||||
<!--<view class="weui-footer__text">Copyright © 2020-2022 国检集团</view>-->
|
||||
</view>
|
|
@ -1,6 +1,6 @@
|
|||
/**index.wxss**/
|
||||
page{
|
||||
background: #1576bd;
|
||||
background: #ffffff;
|
||||
}
|
||||
.userinfo {
|
||||
display: flex;
|
||||
|
@ -29,13 +29,13 @@ page{
|
|||
line-height: 100rpx;
|
||||
padding: 0;
|
||||
font-weight: 500;
|
||||
background-color: #f15806;
|
||||
background-color: #79bb52;
|
||||
margin-top: 50rpx;
|
||||
}
|
||||
.loginBtn_visit{
|
||||
background-color: #ffffff;
|
||||
color: #666666;
|
||||
/* border: 1rpx solid #438af4; */
|
||||
background-color: #007241;
|
||||
color: #ffffff;
|
||||
/* border: 1rpx solid #7bbd52; */
|
||||
}
|
||||
.logoImg{
|
||||
display: block;
|
||||
|
@ -52,7 +52,7 @@ page{
|
|||
border: 1rpx solid #cccccc;
|
||||
}
|
||||
.weui-footer{
|
||||
color: #ffffff;
|
||||
color: #79bc54;
|
||||
}
|
||||
.xieyi{
|
||||
color: #f5b5b5!important;
|
||||
|
|
|
@ -16,6 +16,7 @@ Page({
|
|||
that.setData({
|
||||
userinfo: userinfo
|
||||
})
|
||||
|
||||
},
|
||||
onShow: function () {
|
||||
let that = this;
|
||||
|
@ -126,26 +127,33 @@ Page({
|
|||
tijiao(){
|
||||
let userinfo = this.data.userinfo;
|
||||
let p = /^[1-9]\d{5}(18|19|20)\d{2}((0[1-9])|(1[0-2]))(([0-2][1-9])|10|20|30|31)\d{3}[0-9Xx]$/;
|
||||
if(p.test(userinfo.ID_number1)){
|
||||
console.log(userinfo);
|
||||
if(userinfo.name!==''&&userinfo.name!==null&&userinfo.name!=='未知'){
|
||||
api.request('/crm/consumer/improve/', 'POST', userinfo).then(res => {
|
||||
wx.setStorageSync('userinfo', userinfo);
|
||||
|
||||
app.globalData.userinfo = userinfo;
|
||||
wx.switchTab({
|
||||
url: '/pages/main/main',
|
||||
})
|
||||
wx.showModal({
|
||||
title: '您已注册成功',
|
||||
content: '登陆后请前往【个人中心】-【工作类别】选择所从事工作类别,即可解锁更多功能!',
|
||||
showCancel: false,
|
||||
success: () => {
|
||||
// 可在此跳转到首页或其他页面
|
||||
wx.switchTab({
|
||||
|
||||
url: '/pages/my/index',
|
||||
})
|
||||
}
|
||||
|
||||
})
|
||||
}else{
|
||||
})
|
||||
}
|
||||
else{
|
||||
wx.showToast({
|
||||
icon: 'none',
|
||||
title: '请完善信息后提交',
|
||||
})
|
||||
}
|
||||
}else{
|
||||
wx.showToast({
|
||||
icon: 'none',
|
||||
title: '请输入正确的身份证号',
|
||||
})
|
||||
}
|
||||
|
||||
},
|
||||
})
|
||||
|
|
|
@ -3,9 +3,9 @@
|
|||
<view class="loginFormWrap">
|
||||
<view class="weui-flex loginItem">
|
||||
<view class="loginLabel" style="flex-shrink:0">姓名</view>
|
||||
<input class="weui-input" placeholder="请输入姓名" placeholder-class="placeholderStyle" bindinput="nameInput"/>
|
||||
<input class="weui-input" placeholder="请输入姓名" placeholder-class="placeholderStyle" bindinput="nameInput" value="{{userinfo.name}}"/>
|
||||
</view>
|
||||
<!-- <view class="weui-flex loginItem">
|
||||
<view class="weui-flex loginItem">
|
||||
<view class="loginLabel" style="flex-shrink:0">性别</view>
|
||||
<picker bindchange="bindPickerChange" value="{{index}}" range="{{array}}" style="width: 100%;">
|
||||
<view class="picker">
|
||||
|
@ -13,6 +13,7 @@
|
|||
</view>
|
||||
</picker>
|
||||
</view>
|
||||
<!--
|
||||
<view class="weui-flex loginItem">
|
||||
<view class="loginLabel" style="flex-shrink:0">年龄</view>
|
||||
<input class="weui-input" type="number" placeholder="请输入年龄" maxlength="3" placeholder-class="placeholderStyle" bindinput="ageInput" />
|
||||
|
@ -20,19 +21,21 @@
|
|||
<view class="weui-flex loginItem">
|
||||
<view class="loginLabel" style="flex-shrink:0">联系电话</view>
|
||||
<input class="weui-input" placeholder="请输入联系电话" maxlength="11" placeholder-class="placeholderStyle" bindinput="phoneChange" />
|
||||
</view> -->
|
||||
</view>
|
||||
<view class="weui-flex loginItem">
|
||||
<view class="loginLabel" style="flex-shrink:0">身份证号</view>
|
||||
<input class="weui-input" placeholder="请输入身份证号" maxlength="18" placeholder-class="placeholderStyle" bindinput="numberChange" />
|
||||
<input class="weui-input" placeholder="请输入身份证号" maxlength="18" placeholder-class="placeholderStyle" bindinput="numberChange" value="{{userinfo.ID_number1}}"/>
|
||||
</view>
|
||||
<view class="weui-flex loginItem">
|
||||
<view class="loginLabel" style="flex-shrink:0">单位名称</view>
|
||||
<input class="weui-input" placeholder="请输入单位名称" placeholder-class="placeholderStyle" bindinput="deptChange"/>
|
||||
<input class="weui-input" placeholder="请输入单位名称" placeholder-class="placeholderStyle" bindinput="deptChange" value="{{userinfo.companyname}}"/>
|
||||
</view>
|
||||
<view class="weui-flex loginItem">
|
||||
<view class="loginLabel" style="flex-shrink:0">职务</view>
|
||||
<input class="weui-input" placeholder="请输入职称/职务" placeholder-class="placeholderStyle" bindinput="postChange"/>
|
||||
<input class="weui-input" placeholder="请输入职称/职务" placeholder-class="placeholderStyle" bindinput="postChange" value="{{userinfo.title}}"/>
|
||||
</view>
|
||||
-->
|
||||
|
||||
</view>
|
||||
</view>
|
||||
<view wx:if="{{if_checked}}" class="weui-btn loginBtn" bindtap="tijiao">提交</view>
|
||||
|
|
|
@ -83,7 +83,7 @@ font-size: 28rpx;
|
|||
text-decoration: underline;
|
||||
}
|
||||
.loginBtn{
|
||||
background-color: #438af4!important;
|
||||
background-color: #7bbd52!important;
|
||||
border-radius: 50rpx;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
@ -91,7 +91,7 @@ font-size: 28rpx;
|
|||
background-color: #ffffff!important;
|
||||
border-radius: 50rpx;
|
||||
font-weight: 500;
|
||||
color: #438af4;
|
||||
color: #7bbd52;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -21,9 +21,7 @@ Page({
|
|||
nowWork:null,
|
||||
userinfo:{},
|
||||
msgList: [
|
||||
{ title: "欢迎使用气味培训平台" },
|
||||
{ title: "培训报名、考证发证请关注新闻咨询" },
|
||||
{ title: "注册用户有3次自助模考机会" },
|
||||
{ title: "“地坪铺装工”工种被纳入《中华人民共和国职业分类大典》" },
|
||||
]
|
||||
},
|
||||
imgH: function (e) {
|
||||
|
@ -46,11 +44,11 @@ Page({
|
|||
userinfo: userinfo,
|
||||
search: that.search.bind(that)
|
||||
})
|
||||
if(userinfo.role_name == '游客'||(userinfo.name!==''&&userinfo.name!==null&&userinfo.name!=='未知'&&userinfo.name!==undefined)){}else{
|
||||
wx.redirectTo({
|
||||
url: '/pages/login/registe/registe',
|
||||
})
|
||||
}
|
||||
if(userinfo.role_name == '游客'||(userinfo.name!==''&&userinfo.name!==null&&userinfo.name!=='未知'&&userinfo.name!==undefined)){}else{
|
||||
wx.redirectTo({
|
||||
url: '/pages/login/registe/registe',
|
||||
})
|
||||
}
|
||||
}else{
|
||||
// debugger;
|
||||
app.callBackUserinfo=res=>{
|
||||
|
@ -60,11 +58,11 @@ Page({
|
|||
userinfo: userinfo,
|
||||
search: that.search.bind(that)
|
||||
})
|
||||
if(userinfo.role_name == '游客'||(userinfo.name!==''&&userinfo.name!==null&&userinfo.name!=='未知'&&userinfo.name!==undefined)){}else{
|
||||
wx.redirectTo({
|
||||
if(userinfo.role_name == '游客'||(userinfo.name!==''&&userinfo.name!==null&&userinfo.name!=='未知'&&userinfo.name!==undefined)){}else{
|
||||
wx.redirectTo({
|
||||
url: '/pages/login/registe/registe',
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -135,39 +133,35 @@ Page({
|
|||
}
|
||||
|
||||
},
|
||||
goFile(){
|
||||
wx.switchTab({
|
||||
url: '/pages/material/index',
|
||||
})
|
||||
},
|
||||
//业务介绍
|
||||
goIntroduction(){
|
||||
api.request('/cms/article/', 'GET', {page: 1,limit: 10}).then(res => {
|
||||
let results = res.data.results;
|
||||
let id = null;
|
||||
for(let i=0;i<results.length;i++){
|
||||
if(results[i].title=='国检集团气味评价板块介绍'){
|
||||
id=results[i].id;
|
||||
wx.navigateTo({
|
||||
url: '/pages/article/detail?id='+id,
|
||||
})
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
//成绩查询
|
||||
goScore(){
|
||||
|
||||
//技能大赛
|
||||
goskill(){
|
||||
wx.navigateTo({
|
||||
url: '/pages/candidate/index',
|
||||
url: '/pages/skill/index?type=1',
|
||||
})
|
||||
|
||||
},
|
||||
|
||||
//证书查询
|
||||
goCertificate(){
|
||||
wx.navigateTo({
|
||||
url: '/pages/candidate/index',
|
||||
})
|
||||
},
|
||||
|
||||
//铺装工匠
|
||||
goartisan(){
|
||||
wx.navigateTo({
|
||||
url: '/pages/puzhuang/typelist',
|
||||
})
|
||||
|
||||
},
|
||||
//优培企业
|
||||
goyoupei(){
|
||||
wx.navigateTo({
|
||||
url: '/pages/youpei/company',
|
||||
})
|
||||
|
||||
},
|
||||
//参加考试
|
||||
goExam(){
|
||||
wx.navigateTo({
|
||||
|
@ -370,5 +364,16 @@ Page({
|
|||
})
|
||||
})
|
||||
|
||||
},
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function () {
|
||||
return {
|
||||
title: '地坪铺装工工匠库', // 分享的标题
|
||||
path: '/pages/login/login', // 分享后打开的页面路径
|
||||
imageUrl: '/images/share.png' // 自定义分享的封面图片
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
})
|
||||
|
|
|
@ -21,90 +21,72 @@
|
|||
</block>
|
||||
</swiper>
|
||||
<!-- 快捷按钮 -->
|
||||
<view class="" style="margin-top: 20rpx;">
|
||||
<a class="topItem" bindtap="goIntroduction">
|
||||
<view class="iconWrap" style="background: #fdbf46;">
|
||||
<i class="iconfont icon-gonggao09" style="font-size: 70rpx;color: #ffffff;"></i>
|
||||
</view>
|
||||
<!-- <image class="topItemImg" src="/images/yewu.png" mode="widthFix"></image> -->
|
||||
<view class="topItemText topItemTextBlod">业务介绍</view>
|
||||
</a>
|
||||
<a class="topItem" bindtap="goFile">
|
||||
<view class="iconWrap" style="background: #fed6e1;box-sizing: border-box;padding-left: 8rpx;">
|
||||
<view style="margin-top: 30rpx;border-radius: 50rpx;">
|
||||
|
||||
<a class="topItem" bindtap="goskill">
|
||||
<view class="iconWrap" style="background: #31CDC1;box-sizing: border-box;padding-left: 2rpx;">
|
||||
<i class="iconfont icon-24gf-folderOpen" style="font-size: 75rpx;color: #ffffff;"></i>
|
||||
</view>
|
||||
<!-- <image class="topItemImg" src="/images/ziyuan1.png" mode="widthFix"></image> -->
|
||||
<view class="topItemText topItemTextBlod">学习资料</view>
|
||||
<view class="topItemText topItemTextBlod">技能大赛</view>
|
||||
</a>
|
||||
<a class="topItem" bindtap="goCertificate">
|
||||
<view class="iconWrap" style="background: #1ba37b;">
|
||||
<view class="iconWrap" style="background:#00adca;">
|
||||
<i class="iconfont icon-fabuzhengshu" style="font-size: 77rpx;color: #ffffff;"></i>
|
||||
</view>
|
||||
<!-- <image class="topItemImg" src="/images/zhengshuSearch.png" mode="widthFix"></image> -->
|
||||
<view class="topItemText topItemTextBlod">证书查询</view>
|
||||
</a>
|
||||
<a class="topItem" bindtap="goExam">
|
||||
<view class="iconWrap" style="background: #49c9e0;box-sizing: border-box;padding-top: 8rpx;">
|
||||
<i class="iconfont icon-a-kaoshi5" style="font-size: 65rpx;color: #ffffff;"></i>
|
||||
<a class="topItem" bindtap="goartisan">
|
||||
<view class="iconWrap" style="background:#7bbd52;box-sizing: border-box;padding-top: 8rpx;">
|
||||
<i class="iconfont icon-xinwen09" style="font-size: 65rpx;color: #ffffff;"></i>
|
||||
</view>
|
||||
<!-- <image class="topItemImg" src="/images/zizhukaoshi.png" mode="widthFix"></image> -->
|
||||
<view class="topItemText topItemTextBlod">参加考试</view>
|
||||
<view class="topItemText topItemTextBlod">铺装工匠</view>
|
||||
</a>
|
||||
<a class="topItem" bindtap="goyoupei">
|
||||
<view class="iconWrap" style="background:#ff4070;box-sizing: border-box;padding-top: 8rpx;">
|
||||
<i class="iconfont icon-gonggao09" style="font-size: 65rpx;color: #ffffff;"></i>
|
||||
</view>
|
||||
<!-- <image class="topItemImg" src="/images/zizhukaoshi.png" mode="widthFix"></image> -->
|
||||
<view class="topItemText topItemTextBlod">优培企业</view>
|
||||
</a>
|
||||
</view>
|
||||
<view class="listItemsWrap" >
|
||||
<!-- <view class="listItemsTitle"> 人员考试</view> -->
|
||||
<view wx:if="{{userinfo && userinfo.name}}">
|
||||
<a class="topItem" bindtap="goLianxi">
|
||||
<a class="topItem2" bindtap="goLianxi">
|
||||
<i class="iconfont iconColor icon-tiku" style="font-size: 70rpx;"></i>
|
||||
<!-- <image class="topItemImg" src="/images/lianxii.png" mode="widthFix"></image> -->
|
||||
<view class="topItemText">题库练习</view>
|
||||
</a>
|
||||
<a class="topItem" bindtap="goYati">
|
||||
<i class="iconfont iconColor icon-kaoshi" style="font-size: 70rpx;position: relative;top: -2rpx;"></i>
|
||||
<!-- <image class="topItemImg" src="/images/chengjichaxun.png" mode="widthFix"></image> -->
|
||||
<view class="topItemText">押卷模考</view>
|
||||
</a>
|
||||
<a class="topItem" bindtap="goMoni">
|
||||
|
||||
<a class="topItem2" bindtap="goMoni">
|
||||
<i class="iconfont iconColor icon-a-kaoshi2" style="font-size: 72rpx;position: relative;top: 1rpx;"></i>
|
||||
<!-- <image class="topItemImg" src="/images/yajuankaoshi.png" mode="widthFix"></image> -->
|
||||
<view class="topItemText">自助模考</view>
|
||||
</a>
|
||||
<a class="topItem" bindtap="goCuoti" style="position: relative;">
|
||||
<a class="topItem2" bindtap="goCuoti" style="position: relative;">
|
||||
<i class="iconfont iconColor icon-a-zuofei3" style="font-size: 70rpx;"></i>
|
||||
<!-- <image class="topItemImg" src="/images/cuotiji2.png" mode="widthFix"></image> -->
|
||||
<view class="topItemText">错题集</view>
|
||||
<view class="topItemText">我的错题</view>
|
||||
<view class="weui-badge" style="position: absolute;top: 1em;right: 1em;" wx:if="{{wrongnum!=0}}">{{wrongnum}}</view>
|
||||
</a>
|
||||
<a class="topItem" bindtap="goShoucang">
|
||||
<a class="topItem2" bindtap="goShoucang">
|
||||
<i class="iconfont iconColor icon-guanzhu06" style="font-size: 70rpx;"></i>
|
||||
<!-- <image class="topItemImg" src="/images/shoucang.png" mode="widthFix"></image> -->
|
||||
<view class="topItemText">收藏集</view>
|
||||
</a>
|
||||
<a class="topItem" bindtap="testList">
|
||||
<i class="iconfont iconColor icon-lishijilu-copy" style="font-size: 70rpx;"></i>
|
||||
<!-- <image class="topItemImg" src="/images/kaoshijilu.png" mode="widthFix"></image> -->
|
||||
<view class="topItemText">考试记录</view>
|
||||
</a>
|
||||
<a class="topItem" bindtap="goVideo">
|
||||
<i class="iconfont iconColor icon-shipin" style="font-size: 70rpx;"></i>
|
||||
<!-- <image class="topItemImg" src="/images/video.png" mode="widthFix"></image> -->
|
||||
<view class="topItemText fontAli">视频课程</view>
|
||||
<view class="topItemText">我的收藏</view>
|
||||
</a>
|
||||
|
||||
</view>
|
||||
<view wx:else>
|
||||
<view style="font-size: 30rpx;color: #333333;letter-spacing: 0.1em;text-align: center;">登陆后,即可刷题学习,参与考试</view>
|
||||
<navigator url="/pages/login/login" style="text-align: center;">
|
||||
<view style="background-color: #438af4;display: inline-block;color: #ffffff;width: 350rpx;height:90rpx;line-height: 90rpx;text-align: center;border-radius: 45rpx;margin-top: 20rpx;">立即登录</view>
|
||||
<view style="background-color: #7bbd52;display: inline-block;color: #ffffff;width: 350rpx;height:90rpx;line-height: 90rpx;text-align: center;border-radius: 45rpx;margin-top: 20rpx;">立即登录</view>
|
||||
</navigator>
|
||||
</view>
|
||||
</view>
|
||||
<view class="btnsWrap">
|
||||
<!-- <navigator url="/pages/main/threshold/threshold">阈值数据库</navigator> -->
|
||||
|
||||
<a class="yuzhiBtn" bindtap="toThreshold">
|
||||
<view class="">气味阈值数据库</view>
|
||||
</a>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@ page{
|
|||
background: #ffffff;
|
||||
}
|
||||
.page{
|
||||
padding: 20rpx 30rpx;
|
||||
padding: 40rpx 30rpx;
|
||||
}
|
||||
.searchWrap .weui-search-bar__form{
|
||||
border-radius: 50rpx;
|
||||
|
@ -19,15 +19,24 @@ page{
|
|||
color: #414040;
|
||||
font-size: 28rpx;
|
||||
display: inline-block;
|
||||
padding-top: 20rpx;
|
||||
padding-top: 10rpx;
|
||||
|
||||
}
|
||||
.topItem2{
|
||||
width: 25%;
|
||||
text-align: center;
|
||||
color: #414040;
|
||||
font-size: 28rpx;
|
||||
display: inline-block;
|
||||
padding-top: 30rpx;
|
||||
}
|
||||
.topItemImg{
|
||||
width: 80rpx;
|
||||
}
|
||||
.topItemText{
|
||||
height: 40rpx;
|
||||
line-height: 40rpx;
|
||||
margin-bottom: 10rpx;
|
||||
line-height: 50rpx;
|
||||
margin-bottom: 30rpx;
|
||||
color: #666666;
|
||||
/* font-weight: 600; */
|
||||
}
|
||||
|
@ -35,8 +44,8 @@ page{
|
|||
font-weight: 600;
|
||||
}
|
||||
.searchWrap .weui-search-bar{
|
||||
/* background-color: #438af4; */
|
||||
background-color: #438af4;
|
||||
/* background-color: #7bbd52; */
|
||||
background-color: #7bbd52;
|
||||
}
|
||||
.swiperImgItem{
|
||||
height: 300rpx;
|
||||
|
@ -51,7 +60,7 @@ page{
|
|||
margin: auto;
|
||||
border-radius: 15rpx;
|
||||
overflow: hidden;
|
||||
margin-top: 20rpx;
|
||||
margin-top: 50rpx;
|
||||
}
|
||||
.swiperTextItem{
|
||||
box-sizing: border-box;
|
||||
|
@ -59,26 +68,26 @@ page{
|
|||
.swiper_item1 {
|
||||
height: 70rpx;
|
||||
line-height: 70rpx;
|
||||
font-size: 28rpx;
|
||||
color:red;
|
||||
font-size: 24rpx;
|
||||
color:rgb(54, 52, 52);
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
background: #f7f7f7;
|
||||
background: #f0eded;
|
||||
}
|
||||
.iconWrap{
|
||||
width: 120rpx;
|
||||
height: 120rpx;
|
||||
border-radius: 70rpx;
|
||||
background: #49c9e0;
|
||||
background: #7bbd52;
|
||||
margin: auto;
|
||||
margin-bottom: 8rpx;
|
||||
margin-bottom: 10rpx;
|
||||
}
|
||||
.listItemsWrap{
|
||||
/* width: 96%; */
|
||||
margin: 10rpx auto;
|
||||
margin-top: 20rpx;
|
||||
padding:10rpx 20rpx;
|
||||
margin-top: 30rpx;
|
||||
padding:15rpx 20rpx;
|
||||
box-sizing: border-box;
|
||||
border-radius: 20rpx;
|
||||
background: #f7f7f7;
|
||||
|
@ -112,7 +121,7 @@ page{
|
|||
font-weight: 600;
|
||||
}
|
||||
.iconColor{
|
||||
color: #438af4!important;
|
||||
color: #339a03!important;
|
||||
}
|
||||
.btnsWrap{
|
||||
margin-top: 20rpx;
|
||||
|
@ -121,7 +130,7 @@ page{
|
|||
line-height: 100rpx;
|
||||
border-radius: 10rpx;
|
||||
color: #ffffff;
|
||||
background-color: #438af4;
|
||||
background-color: #007a46;
|
||||
}
|
||||
.yuzhiBtn{
|
||||
width: 100%;
|
||||
|
|
|
@ -10,12 +10,10 @@ Page({
|
|||
results: [],
|
||||
infoShow:false,
|
||||
infoItem:{},
|
||||
cateData:['标准文件','文献','指南','未分类'],
|
||||
query: {
|
||||
page: 1,
|
||||
limit: 10,
|
||||
type:'文档',
|
||||
cate:'标准文件'
|
||||
}
|
||||
},
|
||||
onLoad: function () {
|
||||
|
@ -26,31 +24,10 @@ Page({
|
|||
},
|
||||
onShow: function () {
|
||||
var that = this
|
||||
that.getList(that.data.query)
|
||||
},
|
||||
bindKeyInput(e){
|
||||
// debugger;
|
||||
let that = this
|
||||
console.log(e.detail.value)
|
||||
that.setData({
|
||||
['query.search']:e.detail.value
|
||||
})
|
||||
that.getList(that.data.query)
|
||||
},
|
||||
searchFile(){
|
||||
let that = this;
|
||||
this.setData({
|
||||
['query.search']:''
|
||||
})
|
||||
that.getList(that.data.query)
|
||||
},
|
||||
typeChange(e){
|
||||
this.setData({
|
||||
['query.cate']:e.target.dataset.type,
|
||||
['query.page']:1
|
||||
})
|
||||
this.getList();
|
||||
that.getList()
|
||||
},
|
||||
|
||||
|
||||
itemClick(e){
|
||||
console.log(e.currentTarget.dataset)
|
||||
let dataset = e.currentTarget.dataset;
|
||||
|
@ -62,6 +39,7 @@ Page({
|
|||
|
||||
getList: function () {
|
||||
var that = this
|
||||
that.data.query.type="文档"
|
||||
api.request('/cms/material/', 'GET', that.data.query).then(res => {
|
||||
if (that.data.query.page == 1) {
|
||||
that.data.results = res.data.results
|
||||
|
|
|
@ -21,13 +21,9 @@
|
|||
<input class="weui-input searchInput" maxlength="10" bindinput="bindKeyInput" placeholder="搜索文档名称"/>
|
||||
</view> -->
|
||||
<view class="materialWrap" style="height:100%;background: #ffffff;">
|
||||
<view class="tabWrap">
|
||||
<view wx:for="{{cateData}}" class="tabItem {{ item==query.cate?'activeType':'' }}" bindtap="typeChange" data-type="{{item}}">
|
||||
<view class="activeLine" wx:if="{{item==query.cate}}"></view>{{item}}
|
||||
</view>
|
||||
</view>
|
||||
<view class="listWrap" style="width: calc(100%-200rpx);">
|
||||
<block wx:for="{{results}}" wx:key="unique">
|
||||
|
||||
<view class="listWrap" >
|
||||
<block wx:for="{{results}}" wx:key="unique" >
|
||||
<view class="listItemWrap" bindtap="itemClick" data-description="{{item.description}}" data-name="{{item.name}}" data-downCount="{{item.down_count}}" data-type="{{item.type}}" data-cate="{{item.cate}}" data-id="{{item.id}}" data-index="{{index}}">
|
||||
<view class="listItemImg">
|
||||
<image wx:if="{{activeImage.type(item.path)=='pdf'}}" mode="widthFix" class="itemImg" src="/images/pdf.svg"></image>
|
||||
|
@ -39,7 +35,9 @@
|
|||
<view class="weui-media-box__title" style="font-size: 32rpx;">{{item.name}}</view>
|
||||
<view class="weui-media-box__desc" style="display: flex;">
|
||||
<text wx:if="{{item.description!==null}}">{{item.description}}</text>
|
||||
<text style="color:darkblue;font-weight:bold;margin-left: auto;">{{item.down_count}}</text>
|
||||
<text style="color:darkblue;font-weight:bold;margin-left: auto;width:100%;height:10px">
|
||||
<!--{{item.down_count}}-->
|
||||
</text>
|
||||
</view>
|
||||
</view>
|
||||
<!-- <a class="downloadBtn" bindtap="downFile" data-id="{{item.id}}" data-index="{{index}}">下载</a> -->
|
||||
|
@ -53,7 +51,7 @@
|
|||
<!-- <view style="text-align: center;">《{{infoItem.name}}》</view> -->
|
||||
<view class="infoItem" wx:if="{{infoItem.name!==null}}">《{{infoItem.name}}》</view>
|
||||
<view class="infoItem" wx:if="{{infoItem.cate!==null}}"><view class="itemLeft">资料分类</view>{{infoItem.cate}}</view>
|
||||
<view class="infoItem" wx:if="{{infoItem.downcount!==null}}"><view class="itemLeft">下载次数:</view>{{infoItem.downcount}}</view>
|
||||
<!-- <view class="infoItem" wx:if="{{infoItem.downcount!==null}}"><view class="itemLeft">下载次数:</view>{{infoItem.downcount}}</view>-->
|
||||
<view class="infoItem" wx:if="{{infoItem.description!==null}}">{{infoItem.description}}</view>
|
||||
<a class="downloadBtn" bindtap="downFile" data-id="{{item.id}}" data-index="{{index}}">下载</a>
|
||||
<view class="closeIcon" bindtap="closeInfo">
|
||||
|
|
|
@ -30,20 +30,13 @@
|
|||
width: 10rpx;
|
||||
position: absolute;
|
||||
top: 20rpx;
|
||||
background-color: #438af4;
|
||||
}
|
||||
.tabWrap{
|
||||
float: left;
|
||||
height: 100%;
|
||||
width: 200rpx;
|
||||
border-right: 1rpx solid #eeeeee;
|
||||
position: fixed;
|
||||
background: #ffffff;
|
||||
background-color: #7bbd52;
|
||||
}
|
||||
|
||||
.listWrap{
|
||||
overflow: hidden;
|
||||
margin-top:0px;
|
||||
padding-left: 200rpx;
|
||||
padding-left: 30rpx;
|
||||
background: #ffffff;
|
||||
}
|
||||
.listItemWrap{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
// pages/lianxi/index.js
|
||||
|
||||
const api = require("../../utils/request");
|
||||
Page({
|
||||
|
||||
|
@ -14,17 +14,20 @@ Page({
|
|||
}
|
||||
},
|
||||
onLoad: function () {
|
||||
|
||||
var that = this
|
||||
that.getList(that.data.query)
|
||||
},
|
||||
getList: function () {
|
||||
var that = this
|
||||
api.request('/cms/material/', 'GET', that.data.query).then(res => {
|
||||
console.log(that.data.results)
|
||||
for(var i=0;i<res.data.results.length;i++){
|
||||
res.data.results[i].showTitle=true
|
||||
}
|
||||
if (that.data.query.page == 1) {
|
||||
that.data.results = res.data.results
|
||||
|
||||
} else {
|
||||
that.data.results = that.data.results.concat(res.data.results)
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"usingComponents": {
|
||||
"txv-video": "plugin://tencentvideo/video"
|
||||
"txv-video": "plugin://player/video"
|
||||
},
|
||||
"enablePullDownRefresh": true,
|
||||
"onReachBottomDistance": 50,
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<view class="weui-article__h2" style="text-align: center;">考试须知</view>
|
||||
<view class="weui-article__h3">一、考试详情</view>
|
||||
<view style="padding-left: 40rpx;font-size: 30rpx;line-height: 60rpx;">
|
||||
<view>名称:<span style="color:#438af4;font-weight: bold;">{{name}}</span></view>
|
||||
<view>名称:<span style="color:#7bbd52;font-weight: bold;">{{name}}</span></view>
|
||||
<view>答卷时长:<span style="color:red;font-weight: bold;">{{limit}}</span>分钟</view>
|
||||
<view>题型说明:</view>
|
||||
<view style="padding-left: 40rpx;">
|
||||
|
@ -13,7 +13,7 @@
|
|||
<view wx:if="{{panduan_count>0}}">{{panduan_count}}道判断题,每题{{panduan_score}}分</view>
|
||||
</view>
|
||||
|
||||
<view >多选题漏选每个正确选项得1分,错选0分</view>
|
||||
<view >多选、错选、漏选均不得分</view>
|
||||
<view >满分{{total_score}},{{pass_score}}以上通过</view>
|
||||
</view>
|
||||
<view class="weui-article__h3">二、.答题须知</view>
|
||||
|
@ -25,7 +25,7 @@
|
|||
</view>
|
||||
|
||||
</view>
|
||||
<a class="weui-btn weui-btn_primary" style="background: #438af4;font-weight: 500;" bindtap="startTest">开始考试</a>
|
||||
<a class="weui-btn weui-btn_primary" style="background: #7bbd52;font-weight: 500;" bindtap="startTest">开始考试</a>
|
||||
</view>
|
||||
|
||||
</view>
|
|
@ -0,0 +1,71 @@
|
|||
// pages/exam/certificate.js
|
||||
const api = require("../../utils/request.js");
|
||||
Page({
|
||||
|
||||
/**
|
||||
* 页面的初始数据
|
||||
*/
|
||||
data: {
|
||||
title:'加载中...',
|
||||
list: [{}],//数据列表
|
||||
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/
|
||||
onLoad(options) {
|
||||
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage() {
|
||||
|
||||
}
|
||||
})
|
|
@ -0,0 +1,4 @@
|
|||
{
|
||||
"usingComponents": {},
|
||||
"navigationBarTitleText": "联系方式"
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
<!--pages/list/list.wxml-->
|
||||
<!--列表页-->
|
||||
<!--列表-->
|
||||
<view style="background-color: #ffffff;height: 99%;" >
|
||||
<view style="padding:70px 50px;font-size:18px">
|
||||
<view>中国建筑材料联合会地坪产业分会(简称CFA)是由民政部批准,于2007年12月7日正式成立。协会专业从事地坪行业规划及管理、技术交流、品牌推广、培训、施工等级评定、标准编制、工程仲裁、材料检测国际合作等多项业务,是唯一一家专注地坪行业的全国性社会团体。
|
||||
</view>
|
||||
|
||||
<view style="font-weight:900;margin-top: 30px;font-size:20px;">秘书处办公室:</view>
|
||||
<view style="font-weight:700;margin-top: 10px;">张松松 </view>
|
||||
<view>010-51167641,15810958290</view>
|
||||
<view style="font-weight:700;margin-top: 10px;">董雪梅</view>
|
||||
<view>010-51167914,15011363998</view>
|
||||
</view>
|
||||
</view>
|
|
@ -0,0 +1,61 @@
|
|||
/* pages/exam/certificate.wxss */
|
||||
|
||||
.page-body {
|
||||
display: flex;
|
||||
flex: 1;
|
||||
flex-direction: column;
|
||||
margin:2px 5px
|
||||
}
|
||||
.item {
|
||||
display: flex;
|
||||
padding: 20rpx 40rpx;
|
||||
border-bottom: 1rpx solid #eee;
|
||||
cursor: pointer;
|
||||
background-color: #ffffff;
|
||||
}
|
||||
.right{
|
||||
position: absolute;
|
||||
right: 20px;
|
||||
color: #cccccc
|
||||
}
|
||||
.item .poster {
|
||||
width: 128rpx;
|
||||
height: 128rpx;
|
||||
margin-right: 20rpx;
|
||||
}
|
||||
.item .meta {
|
||||
flex: 1;
|
||||
}
|
||||
.item .meta .title,.item .meta .sub-title {
|
||||
display: block;
|
||||
margin-bottom: 15rpx;
|
||||
}
|
||||
.item .meta .title {
|
||||
font-size: 32rpx;
|
||||
}
|
||||
.item .meta .sub-title {
|
||||
font-size: 25rpx;
|
||||
color: #7bbd52;
|
||||
}
|
||||
.item .meta .artists {
|
||||
font-size: 26rpx;
|
||||
color: #999;
|
||||
}
|
||||
.item .rating {
|
||||
font-size: 28rpx;
|
||||
margin-bottom: 15rpx;
|
||||
}
|
||||
.tips {
|
||||
font-size: 28rpx;
|
||||
text-align: center;
|
||||
padding: 50rpx;
|
||||
color: #ccc;
|
||||
}
|
||||
.tips image {
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
margin-right: 20rpx;
|
||||
}
|
||||
.tips image,.tips text {
|
||||
vertical-align: middle;
|
||||
}
|
|
@ -1,5 +1,6 @@
|
|||
// pages/my/index.js
|
||||
const api = require("../../utils/request.js");
|
||||
const app = getApp()
|
||||
Page({
|
||||
data: {
|
||||
total:0,
|
||||
|
@ -9,6 +10,7 @@ Page({
|
|||
infoView:false
|
||||
},
|
||||
onLoad: function (options) {
|
||||
|
||||
},
|
||||
onReady: function () {
|
||||
|
||||
|
@ -21,8 +23,10 @@ Page({
|
|||
if(userinfo.username){
|
||||
userinfo.username = userinfo.username.replace(/(\d{3})(\d{4})(\d{4})/,"$1****$3")
|
||||
}
|
||||
|
||||
this.setData({
|
||||
userinfo: userinfo,
|
||||
userinfo: getApp().globalData.userinfo,
|
||||
avatar:app.globalData.mediahost + getApp().globalData.userinfo.avatar
|
||||
})
|
||||
api.request('/examtest/examtest/fx/', 'GET').then(res => {
|
||||
this.setData(res.data)
|
||||
|
@ -57,5 +61,14 @@ Page({
|
|||
infoView :true
|
||||
})
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
//修改基本信息:
|
||||
onButtonClick() {
|
||||
let userinfo = wx.getStorageSync('userinfo');
|
||||
wx.navigateTo({
|
||||
url: '/pages/login/registe/registe' // 目标页面路径
|
||||
});
|
||||
|
||||
},
|
||||
})
|
|
@ -4,8 +4,8 @@
|
|||
<view class="absoluteContentWrap">
|
||||
<view class="userImgWrap" bindtap="register">
|
||||
<view class="userImg">
|
||||
<image src="/images/autar.png"></image>
|
||||
<!-- <open-data type="userAvatarUrl"></open-data> -->
|
||||
<!--<image src="/images/autar.png"></image>-->
|
||||
<open-data type="userAvatarUrl"></open-data>
|
||||
</view>
|
||||
</view>
|
||||
<view class="infoContent" bindtap="register">
|
||||
|
@ -33,23 +33,33 @@
|
|||
<view class="totalStatic">
|
||||
<view style="padding-left: 20rpx;"><text class="boldLine"></text>统计分析</view>
|
||||
<view class="weui-cells weui-cells_after-title" style="padding:20rpx;box-sizing:border-box">
|
||||
|
||||
<navigator url="/pages/workscope/index" class="weui-cell weui-cell_access">
|
||||
<view class="weui-cell__hd">
|
||||
<image src="/images/workType.png" style="margin-right: 16px;vertical-align: middle;width:20px; height: 20px;">
|
||||
<image src="/images/workType.png" style="margin-right: 16px;vertical-align: middle;width:25px; height: 25px;">
|
||||
</image>
|
||||
</view>
|
||||
|
||||
<view class="weui-cell__bd">工作类别</view>
|
||||
<view class="weui-cell__ft" style="font-weight:bold;color:#438af4" wx:if="{{userinfo.workscope_name}}">
|
||||
<view class="weui-cell__ft" style="font-weight:bold;font-size:15px;color:#017748" wx:if="{{userinfo.workscope_name}}">
|
||||
{{userinfo.workscope_name}}</view>
|
||||
<view class="weui-cell__ft" style="font-weight:bold;color:#438af4" wx:else>无</view>
|
||||
<view class="weui-cell__ft" style="font-weight:bold;color:#017748" wx:else>无</view>
|
||||
</navigator>
|
||||
<navigator url="/pages/exam/total" class="weui-cell weui-cell_access" hover-class="weui-cell_active">
|
||||
<view class="weui-cell__hd">
|
||||
<image src="/images/pingjun.png" style="margin-right: 16px;vertical-align: middle;width:20px; height: 20px;"></image>
|
||||
<image src="/images/pingjun.png" style="margin-right: 16px;vertical-align: middle;width:25px; height: 25px;"></image>
|
||||
</view>
|
||||
<view class="weui-cell__bd">考试统计</view>
|
||||
<view class="weui-cell__ft weui-cell__ft_in-access" style="color:red"></view>
|
||||
</navigator>
|
||||
<navigator url="/pages/my/certificate" class="weui-cell weui-cell_access" hover-class="weui-cell_active">
|
||||
<view class="weui-cell__hd">
|
||||
<image src="/images/lianxi.png" style="margin-right: 16px;vertical-align: middle;width:25px; height: 25px;"></image>
|
||||
</view>
|
||||
<view class="weui-cell__bd">联系我们</view>
|
||||
|
||||
|
||||
</navigator>
|
||||
</view>
|
||||
</view>
|
||||
<!-- <view class="totalStatic">
|
||||
|
@ -82,7 +92,7 @@
|
|||
<view class="weui-media-box__desc" wx:else style="display: flex;justify-content: space-between;color: #666666;">
|
||||
<view> 昵称:<open-data type="userNickName"></open-data></view>
|
||||
<navigator url="/pages/login/login">
|
||||
<span style="position: absolute;top:30rpx;right:20rpx;color:#ffffff;background-color: #438af4;padding: 15rpx;border-radius: 10rpx;display: inline-block;">去登陆</span>
|
||||
<span style="position: absolute;top:30rpx;right:20rpx;color:#ffffff;background-color: #7bbd52;padding: 15rpx;border-radius: 10rpx;display: inline-block;">去登陆</span>
|
||||
</navigator>
|
||||
</view>
|
||||
<view class="weui-media-box__desc" style="color: #666666;">单位:
|
||||
|
@ -102,9 +112,9 @@
|
|||
</image>
|
||||
</view>
|
||||
<view class="weui-cell__bd">工作类别</view>
|
||||
<view class="weui-cell__ft" style="font-weight:bold;color:#438af4" wx:if="{{userinfo.workscope_name}}">
|
||||
<view class="weui-cell__ft" style="font-weight:bold;color:#7bbd52" wx:if="{{userinfo.workscope_name}}">
|
||||
{{userinfo.workscope_name}}</view>
|
||||
<view class="weui-cell__ft" style="font-weight:bold;color:#438af4" wx:else>无</view>
|
||||
<view class="weui-cell__ft" style="font-weight:bold;color:#7bbd52" wx:else>无</view>
|
||||
</navigator>
|
||||
<navigator url="/pages/exam/total" class="weui-cell weui-cell_access" hover-class="weui-cell_active">
|
||||
<view class="weui-cell__hd">
|
||||
|
@ -133,6 +143,9 @@
|
|||
<view class="infoItem" wx:if="{{userinfo.workscope_name!==null}}"><view class="itemLeft">工作类别:</view>{{userinfo.workscope_name}}</view>
|
||||
<view class="infoItem" wx:if="{{userinfo.role_name!==null}}"><view class="itemLeft">用户类型:</view>{{userinfo.role_name}}</view>
|
||||
<view class="infoItem" wx:if="{{userinfo.exceed_date!==null}}"><view class="itemLeft">有效期至:</view>{{userinfo.exceed_date}}</view>
|
||||
<view class="button-container">
|
||||
<button bindtap="onButtonClick" class="my-button">修改基本信息</button>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
|
@ -39,7 +39,7 @@
|
|||
background: #f1f1f1;
|
||||
}
|
||||
.blueBack{
|
||||
position: absolute;top: 0;left: 0;height: 200rpx;width:100%;background-color: #438af4;
|
||||
position: absolute;top: 0;left: 0;height: 200rpx;width:100%;background-color: #7bbd52;
|
||||
}
|
||||
.absoluteContentWrap{
|
||||
position: absolute;width: 100%;height: 100%;
|
||||
|
@ -57,14 +57,25 @@
|
|||
width: 94%;background: #ffffff;border-radius: 10rpx;margin: auto;padding: 20rpx 0;margin-top: 20rpx;color: #666666;box-sizing: border-box;
|
||||
}
|
||||
.boldLine{
|
||||
display: inline-block;width: 10rpx;height: 30rpx;background: #438af4;vertical-align: text-top; margin-right: 20rpx;
|
||||
display: inline-block;width: 10rpx;height: 30rpx;background: #017748;vertical-align: text-top; margin-right: 20rpx;
|
||||
}
|
||||
.loginBtn{
|
||||
position: absolute;top:100rpx;right:20rpx;color:#ffffff;background-color: #438af4;padding: 15rpx;border-radius: 10rpx;display: inline-block;
|
||||
position: absolute;top:100rpx;right:20rpx;color:#ffffff;background-color: #7bbd52;padding: 15rpx;border-radius: 10rpx;display: inline-block;
|
||||
}
|
||||
.kaoshiWrap{
|
||||
display: flex;color: #666666;font-size: 30rpx;margin-top: 10rpx;padding: 10rpx 0;border-top: 2rpx solid #eeeeee;
|
||||
}
|
||||
.kaoshiItem{
|
||||
display: flex;flex-direction: column;flex: 1;text-align: center;
|
||||
}
|
||||
.button-container {
|
||||
padding: 20rpx;
|
||||
}
|
||||
|
||||
.my-button {
|
||||
background-color: #7bbd52;
|
||||
color: #FFFFFF;
|
||||
border: none;
|
||||
border-radius: 5rpx;
|
||||
font-size: 25rpx;
|
||||
}
|
|
@ -0,0 +1,93 @@
|
|||
|
||||
const api = require("../../utils/request.js");
|
||||
Page({
|
||||
|
||||
/**
|
||||
* 页面的初始数据
|
||||
*/
|
||||
data: {
|
||||
domain:getApp().globalData.mediahost,
|
||||
companydetail:[
|
||||
],
|
||||
query: {
|
||||
page: 1,
|
||||
limit: 10,
|
||||
search:""
|
||||
},
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/
|
||||
onLoad: function (options) {
|
||||
this.getDetail(options.id)
|
||||
},
|
||||
//铺装介绍请求
|
||||
getDetail: function (id) {
|
||||
var that = this
|
||||
wx.showLoading({
|
||||
title: '加载中',
|
||||
mask:true
|
||||
})
|
||||
api.request(`/cms/userpz/${id}/`,'GET').then(res => {
|
||||
console.log("ceshi"+res)
|
||||
that.setData(res.data)
|
||||
wx.hideLoading({
|
||||
complete: (res) => {},
|
||||
})
|
||||
}).catch(res=>{
|
||||
wx.hideLoading({
|
||||
complete: (res) => {},
|
||||
})
|
||||
})
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage() {
|
||||
|
||||
}
|
||||
})
|
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"usingComponents": {
|
||||
"mp-html": "/components/mp-html/index"
|
||||
},
|
||||
"navigationBarTitleText": "贡献企业积分"
|
||||
}
|
|
@ -0,0 +1,11 @@
|
|||
|
||||
<view class="page">
|
||||
|
||||
<view style="padding:20px 20px;">
|
||||
<view class="companyNote">个人简介</view>
|
||||
<view class="weui-article__p">
|
||||
<mp-html content="{{art_remark}}" domain="{{domain}}"/>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
|
@ -0,0 +1,16 @@
|
|||
|
||||
|
||||
.newsList{
|
||||
margin-bottom: 10rpx;
|
||||
box-shadow: 0 0 13rpx 8rpx #f7f7f7;
|
||||
background: #ffffff;
|
||||
}
|
||||
.companyNote{
|
||||
font-size:30px;
|
||||
letter-spacing: 0.1em;
|
||||
font-weight:bold;
|
||||
text-align: center;
|
||||
}
|
||||
.remark{
|
||||
text-indent:2em;font-size:20px;padding-top: 20px;letter-spacing: 0.1em;line-height: 40px;
|
||||
}
|
|
@ -0,0 +1,130 @@
|
|||
// pages/youpei/company.js
|
||||
const app = getApp()
|
||||
const api = require("../../utils/request.js");
|
||||
Page({
|
||||
|
||||
data: {
|
||||
query: {
|
||||
page: 1,
|
||||
limit: 10,
|
||||
search:""
|
||||
},
|
||||
// 数据源
|
||||
results: [
|
||||
// {id:1,title:"开发需求",is_top:true,ifrom:"第一条咨询",update_time:"2022-10-01"}
|
||||
],
|
||||
|
||||
name:"中存大数据科技有限公司"
|
||||
|
||||
},
|
||||
onLoad: function (options) {
|
||||
this.getList(options.art_cate)
|
||||
console.log(options.art_cate)
|
||||
wx.stopPullDownRefresh();
|
||||
},
|
||||
|
||||
|
||||
|
||||
getList: function (art_cate) {
|
||||
console.log(art_cate)
|
||||
var that = this
|
||||
that.data.query.art_cate=art_cate
|
||||
console.log(that.data.query.art_cate)
|
||||
api.request('/cms/userpz/', 'GET', that.data.query).then(res => {
|
||||
if (that.data.query.page == 1) {
|
||||
that.data.results = res.data.results
|
||||
} else {
|
||||
that.data.results = that.data.results.concat(res.data.results)
|
||||
}
|
||||
|
||||
|
||||
that.setData({
|
||||
results: that.data.results,
|
||||
count: res.data.count,
|
||||
url:app.globalData.mediahost
|
||||
|
||||
})
|
||||
|
||||
})
|
||||
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow() {
|
||||
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload() {
|
||||
|
||||
},
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {
|
||||
var that = this
|
||||
that.data.query.page = 1;
|
||||
that.getList();
|
||||
wx.stopPullDownRefresh();
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {
|
||||
var that = this
|
||||
if (that.data.count <= that.data.query.page * that.data.query.limit) {
|
||||
wx.showToast({
|
||||
title: '没有更多了',
|
||||
icon: 'none'
|
||||
})
|
||||
} else {
|
||||
that.data.query.page = that.data.query.page + 1
|
||||
that.getList()
|
||||
}
|
||||
|
||||
},
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom() {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage() {
|
||||
|
||||
},
|
||||
//优培企业图片点击
|
||||
goartisan(){
|
||||
wx.navigateTo({
|
||||
url: '/pages/youpei/detailpy',
|
||||
})
|
||||
|
||||
},
|
||||
})
|
|
@ -0,0 +1,4 @@
|
|||
{
|
||||
"usingComponents": {},
|
||||
"navigationBarTitleText": "铺装工匠"
|
||||
}
|
|
@ -0,0 +1,23 @@
|
|||
|
||||
|
||||
<view class="page">
|
||||
|
||||
|
||||
<view class="weui-cells weui-cells_after-title" style="border-radius: 10rpx;margin:10px; background:none;">
|
||||
<block wx:for="{{results}}" wx:key="index">
|
||||
<navigator class="newsList" url="detail?id={{item.id}}" style="display: flex;padding: 10rpx;" hover-class="weui-cell_active">
|
||||
<view class="weui-media-box__bd weui-media-box__bd_in-appmsg" style="padding: 20rpx;border-radius: 10rpx;width:90%;position:relative;height:80px">
|
||||
|
||||
<image src="{{url+item.art_photo}}" style="width:80px;height:80px;float:left;position: absolute;top:50%;transform: translateY(-50%);border-radius: 50rpx;"> </image>
|
||||
<view style="padding-left:110px;padding-top:10px;font-size:18px;font-weight:bold;word-break:break-all;">
|
||||
{{item.art_name }}
|
||||
</view>
|
||||
<view class="weui-media-box__title" style="padding-left:100px;padding-top:10px;font-size:14px;">
|
||||
<text wx:if="{{item.art_honor}}"> {{item.art_honor }}</text>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</navigator>
|
||||
</block>
|
||||
</view>
|
||||
</view>
|
|
@ -0,0 +1,11 @@
|
|||
|
||||
.head{
|
||||
color:#fff;
|
||||
background-color: #3399ff;
|
||||
text-align: center;
|
||||
}
|
||||
.newsList{
|
||||
margin-bottom: 10rpx;
|
||||
box-shadow: 0 0 13rpx 8rpx #f7f7f7;
|
||||
background: #ffffff;
|
||||
}
|
|
@ -0,0 +1,81 @@
|
|||
// pages/puzhuang/typelist.js
|
||||
const api = require("../../utils/request.js");
|
||||
Page({
|
||||
|
||||
/**
|
||||
* 页面的初始数据
|
||||
*/
|
||||
data: {
|
||||
elink_f:'',
|
||||
domain:getApp().globalData.mediahost,
|
||||
img:("/images/lianxi.png","/images/lianxi.png","/images/lianxi.png","/images/lianxi.png","/images/lianxi.png","/images/lianxi.png")
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/
|
||||
onLoad: function () {
|
||||
this.getDetail()
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function () {
|
||||
|
||||
},
|
||||
|
||||
getDetail: function () {
|
||||
var that = this
|
||||
api.request('/examtest/workscope/', 'GET', {is_public:true}).then(res => {
|
||||
|
||||
that.setData({
|
||||
workData:res.data
|
||||
})
|
||||
})
|
||||
|
||||
},
|
||||
|
||||
})
|
|
@ -0,0 +1,3 @@
|
|||
{
|
||||
"usingComponents": {}
|
||||
}
|
|
@ -0,0 +1,75 @@
|
|||
<!--pages/puzhuang/typelist.wxml-->
|
||||
|
||||
|
||||
<view class="page" style="background:#fff;">
|
||||
|
||||
<view style=" color:#fff;top:8px;left:9px;width:100%;position:absolute;">
|
||||
<!--<block wx:for="{{workData}}" wx:key="unique" >
|
||||
<navigator url="index?art_cate={{item.name}}" >
|
||||
<view style="background: #3399ff;width:93%;; border-radius: 20rpx;margin:10px 20px 10px 5px;float:left;">
|
||||
<view style="color:#fff;padding-top:28px;height:60px;width:100%;font-size: 20px;text-align: center;">
|
||||
{{item.name}}
|
||||
</view>
|
||||
<image src="/images/lianxi.png" style="width:60px;height:60px;float:left;position: absolute;top:54px;transform: translateY(-50%);border-radius: 50rpx;"> </image>
|
||||
</view>
|
||||
</navigator>
|
||||
</block>--->
|
||||
<block >
|
||||
<navigator url="index?art_cate=现浇型运动地坪铺装工" >
|
||||
<view style="background: #3399ff;width:93%;; border-radius: 20rpx;margin:10px 20px 10px 5px;float:left;">
|
||||
<view style="color:#fff;padding-top:28px;height:60px;width:75%;font-size: 18px;text-align: left;float:right">
|
||||
现浇型运动地坪铺装工
|
||||
<image src="/images/right1.png" style="width:17px;height:17px;float:right;margin-top:7px;margin-right: 20px;"> </image>
|
||||
</view>
|
||||
<image src="/images/pz1.png" style="width:50px;height:50px;float:left;position: absolute;top:35px;left:15px;"> </image>
|
||||
</view>
|
||||
</navigator>
|
||||
<navigator url="index?art_cate=预制型运动地坪铺装工" >
|
||||
<view style="background: #3399ff;width:93%;; border-radius: 20rpx;margin:10px 20px 10px 5px;float:left;">
|
||||
<view style="color:#fff;padding-top:28px;height:60px;width:75%;font-size: 18px;text-align: left;float:right">
|
||||
预制型运动地坪铺装工
|
||||
<image src="/images/right1.png" style="width:17px;height:17px;float:right;margin-top:7px;margin-right: 20px;"> </image>
|
||||
</view>
|
||||
<image src="/images/pz2.png" style="width:50px;height:50px;float:left;position: absolute;top:145px;left:15px;"> </image>
|
||||
</view>
|
||||
</navigator>
|
||||
<navigator url="index?art_cate=人造草运动地坪铺装工" >
|
||||
<view style="background: #3399ff;width:93%;; border-radius: 20rpx;margin:10px 20px 10px 5px;float:left;">
|
||||
<view style="color:#fff;padding-top:28px;height:60px;width:75%;font-size: 18px;text-align: left;float:right">
|
||||
人造草运动地坪铺装工
|
||||
<image src="/images/right1.png" style="width:17px;height:17px;float:right;margin-top:7px;margin-right: 20px;"> </image>
|
||||
</view>
|
||||
<image src="/images/pz3.png" style="width:50px;height:50px;float:left;position: absolute;top:254px;left:15px;"> </image>
|
||||
</view>
|
||||
</navigator>
|
||||
<navigator url="index?art_cate=整体涂层地坪铺装工" >
|
||||
<view style="background: #3399ff;width:93%;; border-radius: 20rpx;margin:10px 20px 10px 5px;float:left;">
|
||||
<view style="color:#fff;padding-top:28px;height:60px;width:75%;font-size: 18px;text-align: left;float:right">
|
||||
整体涂层地坪铺装工
|
||||
<image src="/images/right1.png" style="width:17px;height:17px;float:right;margin-top:7px;margin-right: 20px;"> </image>
|
||||
</view>
|
||||
<image src="/images/pz4.png" style="width:50px;height:50px;float:left;position: absolute;top:360px;left:15px;"> </image>
|
||||
</view>
|
||||
</navigator>
|
||||
<navigator url="index?art_cate=混凝土一体化地坪铺装工" >
|
||||
<view style="background: #3399ff;width:93%;; border-radius: 20rpx;margin:10px 20px 10px 5px;float:left;">
|
||||
<view style="color:#fff;padding-top:28px;height:60px;width:75%;font-size: 18px;text-align: left;float:right">
|
||||
混凝土一体化地坪铺装工
|
||||
<image src="/images/right1.png" style="width:17px;height:17px;float:right;margin-top:7px;margin-right: 20px;"> </image>
|
||||
</view>
|
||||
<image src="/images/pz5.png" style="width:50px;height:50px;float:left;position: absolute;top:467px;left:15px;"> </image>
|
||||
</view>
|
||||
</navigator>
|
||||
<navigator url="index?art_cate=预制型工业卷材地坪铺装工" >
|
||||
<view style="background: #3399ff;width:93%;; border-radius: 20rpx;margin:10px 20px 10px 5px;float:left;">
|
||||
<view style="color:#fff;padding-top:28px;height:60px;width:75%;font-size: 18px;text-align: left;float:right">
|
||||
预制型工业卷材地坪铺装工
|
||||
<image src="/images/right1.png" style="width:17px;height:17px;float:right;margin-top:7px;margin-right: 20px;"> </image>
|
||||
</view>
|
||||
<image src="/images/pz6.png" style="width:50px;height:50px;float:left;position: absolute;top:576px;left:15px;"> </image>
|
||||
</view>
|
||||
</navigator>
|
||||
</block>
|
||||
</view>
|
||||
</view>
|
||||
|
|
@ -0,0 +1,23 @@
|
|||
/* pages/puzhuang/typelist.wxss */
|
||||
.page__title {
|
||||
font-size: 18px;
|
||||
}
|
||||
.weui-article{
|
||||
padding: 0!important;
|
||||
}
|
||||
.weui-article__h1{
|
||||
padding: 24rpx 24rpx 0rpx 24rpx;
|
||||
margin-bottom: 0;
|
||||
background-color: #ffffff;
|
||||
}
|
||||
.page__desc{
|
||||
margin-top: 0;
|
||||
padding: 10rpx 24rpx 15rpx 24rpx;
|
||||
background-color: #ffffff;
|
||||
margin-bottom: 20rpx;
|
||||
display: flex;
|
||||
}
|
||||
.weui-article__p{
|
||||
padding: 24rpx;
|
||||
background-color: #ffffff;
|
||||
}
|
|
@ -55,5 +55,5 @@
|
|||
</view>
|
||||
</scroll-view>
|
||||
<view class="btns">
|
||||
<a class="weui-btn weui-btn_primary" bindtap="showAnswer" style="background: #438af4;">查看答案</a>
|
||||
<a class="weui-btn weui-btn_primary" bindtap="showAnswer" style="background: #7bbd52;">查看答案</a>
|
||||
</view>
|
|
@ -0,0 +1,88 @@
|
|||
// pages/article/detail.js
|
||||
const api = require("../../utils/request.js");
|
||||
Page({
|
||||
|
||||
/**
|
||||
* 页面的初始数据
|
||||
*/
|
||||
data: {
|
||||
elink_f:'',
|
||||
domain:getApp().globalData.mediahost
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/
|
||||
onLoad: function (options) {
|
||||
this.getDetail(options.id)
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function () {
|
||||
|
||||
},
|
||||
|
||||
getDetail: function (id) {
|
||||
var that = this
|
||||
wx.showLoading({
|
||||
title: '加载中',
|
||||
mask:true
|
||||
})
|
||||
api.request(`/cms/article/${id}/`,'GET').then(res => {
|
||||
// res.data.content = res.data.content.replace(/"media/g, '"'+getApp().globalData.mediahost + '/media').replace(/\<img/gi, '<img style="max-width:100%;height:auto" ')
|
||||
that.setData(res.data)
|
||||
wx.hideLoading({
|
||||
complete: (res) => {},
|
||||
})
|
||||
}).catch(res=>{
|
||||
wx.hideLoading({
|
||||
complete: (res) => {},
|
||||
})
|
||||
})
|
||||
},
|
||||
|
||||
})
|
|
@ -0,0 +1,5 @@
|
|||
{
|
||||
"usingComponents": {
|
||||
"mp-html": "/components/mp-html/index"
|
||||
}
|
||||
}
|