Browse Source

小程序跳h5.攻坚

v5.0
是小王呀\24601 8 months ago
parent
commit
b4a453782c
  1. 7
      pages/statistics/modules/AttackEvent/AttackEvent.js
  2. 13
      pages/statistics/modules/AttackEvent/AttackEvent.wxml
  3. 17
      pages/statistics/modules/AttackEvent/AttackEvent.wxss
  4. 3
      pages/statistics/modules/HotlineRates/HotlineRates.js
  5. 5
      pages/statistics/modules/HotlineRates/HotlineRates.wxml
  6. 7
      pages/statistics/statistics.js
  7. 2
      pages/statistics/statistics.wxml
  8. 55
      pages/webView/webView.js
  9. 2
      pages/webView/webView.wxml
  10. 5
      pages/work2/work2.js

7
pages/statistics/modules/AttackEvent/AttackEvent.js

@ -48,6 +48,13 @@ Component({
wx.navigateTo({
url: '/subpages/statistics/pages/problem/problem?type='+this.data.tabValue+'&data='+JSON.stringify(data)
})
},
toNumber(data){
let token=wx.getStorageSync('token')
let iceventid=data.currentTarget.dataset.iceventid
wx.navigateTo({
url: '/pages/webView/webView?worktoken='+token+'&iceventid='+iceventid+'&AttackEvent='+'https://epmet-preview.elinkservice.cn/epmet-work-h5/#/HotlineDetail',
})
}
},

13
pages/statistics/modules/AttackEvent/AttackEvent.wxml

@ -1,13 +1,20 @@
<view class="problem-list">
<view class="problem-item" bind:tap="gotopage" data-obj="{{item}}" wx:for="{{tableList}}" wx:key="index" wx:if="{{index<3}}">
<view class="frequency">
<view class="problem-item" data-obj="{{item}}" wx:for="{{tableList}}" wx:key="index" wx:if="{{index<3}}">
<view class="frequency" bind:tap="toNumber" data-icEventId="{{item.icEventId}}" >
<view class="frequency_title">
<image style="height: 36rpx; width: 36rpx;" src="https://elink-esua-epdc.oss-cn-qingdao.aliyuncs.com/epmet-saas/dev/20250107/98ae411b86df48529139259c58c8e748.png"></image>
<view class="workOrde">工单号:{{item.icEventId}}</view>
</view>
<view class="frequency_content">
<view class="content_categoryAllName">{{item.categoryAllName}}</view>
<view class="content_workOrde">{{item.satisfactionName}}</view>
<view style="display: flex; flex-direction: row;">
<view wx:if="{{item.solved=='未解决'}}" class="content_workOrde1">{{item.solved}}</view>
<view wx:if="{{item.satisfactionName=='不满意'}}" class="content_workOrde1">、</view>
</view>
<view wx:if="{{item.satisfactionName=='不满意'}}" class="content_workOrde">{{item.satisfactionName}}</view>
</view>
<view class="frequency_footer">
<view class="content_eventContent">{{item.eventContent}}</view>

17
pages/statistics/modules/AttackEvent/AttackEvent.wxss

@ -75,12 +75,19 @@ justify-content: space-between;
overflow: hidden; /* 隐藏超出部分 */
text-overflow: ellipsis; /* 显示省略号 */
}
.content_workOrde{
.content_workOrde {
font-family: PingFang SC;
font-weight: 500;
font-size: 26rpx;
color: #FC5231;
line-height: 42rpx;
font-weight: 500;
font-size: 26rpx;
color: #FC5231;
line-height: 42rpx;
}
.content_workOrde1 {
font-family: PingFang SC;
font-weight: 500;
font-size: 26rpx;
color: #FFA312;
line-height: 42rpx;
}
.workOrde{
margin-left: 20rpx;

3
pages/statistics/modules/HotlineRates/HotlineRates.js

@ -43,12 +43,11 @@ Component({
},
methods: {
toNumber(data) {
console.log(data.currentTarget.dataset,"dskljflksdfjl");
let type=data.currentTarget.dataset.type
let staffId=data.currentTarget.dataset.staffid
let token=wx.getStorageSync('token')
wx.navigateTo({
url: '/pages/webView/webView?worktoken='+token+'&staffId='+staffId+'&type='+type+'&day='+this.data.day+'&day2='+this.data.day2,
url: '/pages/webView/webView?worktoken='+token+'&staffId='+staffId+'&type='+type+'&day='+this.data.day+'&day2='+this.data.day2+'&Hotline='+'https://epmet-preview.elinkservice.cn/epmet-work-h5/#/Hotline',
})
},
onChange(e) {

5
pages/statistics/modules/HotlineRates/HotlineRates.wxml

@ -30,13 +30,8 @@
</view>
</view>
<view class="stay-list" wx:if="{{list.length}}">
<!-- <view class="stay-item" wx:for="{{list}}" bind:tap="gotopage" data-id="{{item.icEventId || item.demandRecId}}">
<view class="date">{{item.happenTime || item.reportTime}}</view>
<view class="tit-text">{{item.eventContent || item.content}}</view>
</view> -->
<view class="hotline-rate" wx:for="{{list}}" wx:for-index="idx" wx-if="{{idx<showitem}}" wx:if="{{item.operateName}}">
<view class="name">
<!-- <view class="ranking">{{idx+1}}</view> -->
<view class="leader-name" wx-if="{{curVal=='1'}}">{{item.operateName }}</view>
<view class="leader-name" wx-if="{{curVal=='2'}}">{{item.assignOrgName}}</view>
</view>

7
pages/statistics/statistics.js

@ -55,5 +55,12 @@ Page({
this.setData({
tabValue: detail
})
},
gotoAttack(){
let worktoken=wx.getStorageSync('token')
console.log(worktoken,"执行一次");
wx.navigateTo({
url: '/pages/webView/webView?worktoken='+worktoken+'&AttackEvent='+'https://epmet-preview.elinkservice.cn/#/AttackEvent',
})
}
})

2
pages/statistics/statistics.wxml

@ -61,7 +61,7 @@
<view class="card">
<view class="title">
<text>攻坚事件</text>
<view class="view" bind:tap="gotopage" data-url="/subpages/statistics/pages/problemList/problemList?type={{tabValue}}">
<view class="view" bind:tap="gotoAttack" data-url="/subpages/statistics/pages/problemList/problemList?type={{tabValue}}">
更多
<image mode="widthFix" src="../../images/right.png"></image>
</view>

55
pages/webView/webView.js

@ -6,34 +6,63 @@
* @FilePath: \epmet-work-mp\pages\webView\webView.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/
const app = getApp()
const App = getApp()
Page({
data: {
worktoken: '',
staffId:"",
type:"",
day:"",
day2:""
day2:"",
iceventid:"",
Hotline:"",
url:"",
},
onLoad: function (options) {
let agencyId=App.globalData.user.agencyId
console.log(App.globalData.user.agencyId,"App.globalData.user.agencyId");
console.log(options,"dslkjfsldfk");
if (options.token) {
this.setData({
worktoken: `${options.worktoken}`,
});
console.log('url', this.data.worktoken);
} else {
console.log(options, "dslfjlksd");
this.setData({
worktoken: decodeURIComponent(options.worktoken),
staffId: options.staffId,
type: `${options.type}`,
day: options.day,
day2: options.day2
})
if (options.Hotline) {
if (options.staffId){
const url = `${options.Hotline}?worktoken=${decodeURIComponent(options.worktoken)}&staffId=${options.staffId}&type=${options.type}&day=${options.day}&day2=${options.day2}`;
console.log('生成的 URL:', url);
this.setData({
url: url
})
console.log(this.data.url,"ds;lkjdflks");
}else{
const url = `${options.Hotline}?worktoken=${decodeURIComponent(options.worktoken)}`;
console.log('生成的 URL:', url);
this.setData({
url: url
})
}
}else{
if (options.iceventid) {
const url = `${options.AttackEvent}?worktoken=${decodeURIComponent(options.worktoken)}&iceventid=${options.iceventid}`;
console.log('生成的 URL:', url);
this.setData({
url: url
})
}else{
const url = `${options.AttackEvent}?worktoken=${decodeURIComponent(options.worktoken)}`;
console.log('生成的 URL:', url);
this.setData({
url: url
})
}
}
}
const url = `https://epmet-preview.elinkservice.cn/epmet-work-h5/#/Hotline?worktoken=${this.data.worktoken}&staffId=${this.data.staffId}&type=${this.data.type}&day=${this.data.day}&day2=${this.data.day2}`;
console.log('生成的 URL:', url);
},
onShow() {
this.onLoad()

2
pages/webView/webView.wxml

@ -1,3 +1,3 @@
<!-- <view>https://epmet-preview.elinkservice.cn/epmet-work-h5/#/Hotline?worktoken={{worktoken}}</view> -->
<web-view src="https://epmet-preview.elinkservice.cn/epmet-work-h5/#/Hotline?worktoken={{worktoken}}&staffId={{staffId}}&type={{type}}&day={{day}}&&day2={{day2}}">
<web-view src="{{url}}">
</web-view>

5
pages/work2/work2.js

@ -122,11 +122,10 @@ Page({
},
onHotlineCompletion(){
let token=wx.getStorageSync('token')
console.log(token,"jhgjgjjhbj");
console.log('https://epmet-preview.elinkservice.cn/epmet-work-h5/#/Hotline?worktoken='+token)
wx.navigateTo({
url: '/pages/webView/webView?worktoken='+token,
url: '/pages/webView/webView?worktoken='+token+'&Hotline='+'https://epmet-preview.elinkservice.cn/epmet-work-h5/#/Hotline',
})
}
// onAddHouse(){

Loading…
Cancel
Save