You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

183 lines
3.5 KiB
JavaScript

const wxml = (jobDetail) => {
console.log(jobDetail.storeJob.hourlyPay);
// debugger;
var str = ''
for (var i = 0; i < jobDetail.storeJob.jobSpecialLabelNames.length; i++) {
str += `
<text class="tag">` + jobDetail.storeJob.jobSpecialLabelNames[i] + `</text>
`
}
// <image src="https://matripe.oss-cn-beijing.aliyuncs.com/logo-01.png" class="logo"/>
// <image src="` + jobDetail.storeJob.logo +`" class="logo"/>
return `<view class="container">
<view class="df">
<view class="dib2" >
<image src="https://matripe.oss-cn-beijing.aliyuncs.com/logo-01.png" class="logo"/>
</view>
<view class="itembox" >
<text class="text">` + jobDetail.storeJob.jobName + `</text>
</view>
</view>
<view class="df1">
<view class="itembox" >
<text class="money">` + jobDetail.storeJob.hourlyPay + `</text>
</view>
</view>
<view class="df2">
<view class="itembox" >
<text class="moneyD">` + jobDetail.storeJob.monthlyPay + `</text>
</view>
</view>
<view class="df4">
<view class="itemboxTag">
` + str + `
</view>
</view>
<view class="df">
<view class="itembox" >
<text class="detail">查看详情 </text>
</view>
</view>
</view>`
}
{/* <image src="https://matripe.oss-cn-beijing.aliyuncs.com/more.png" class="next"/> */}
// return `<view class="container" >
// <view class="df">
// <view class="dib2" >
// <image src="http://matripe.oss-cn-beijing.aliyuncs.com/default.png" class="logo"/>
// </view>
// <view class="itembox" >
// <text class="text"></text>
// <text class="text1">yeah!12</text>
// </view>
// </view>
// </view>
// `
const style = {
container: {
width: 300,
height: 240,
lingHeight: 1,
backgroundColor: "#f8f8f8",
},
df: {
width: 300,
height: 30,
padding: 12,
marginTop: 10,
flexDirection: 'row',
},
df1: {
width: 300,
height: 30,
padding: 12,
marginTop: 10,
flexDirection: 'row',
},
df2: {
width: 300,
height: 30,
padding: 12,
marginTop: 10,
flexDirection: 'row',
},
df4: {
width: 300,
height: 30,
padding: 12,
marginTop: 10,
flexDirection: 'row',
},
logo: {
width: 30,
height: 30,
},
next: {
width: 12,
height: 12,
marginLeft: 54,
marginTop: 3,
},
dib2: {
width: 32,
height: 32,
borderWidth: 1,
borderColor: '#fff',
borderStyle: 'dashed'
},
itembox: {
width: 184,
height: 24,
},
itemboxTag: {
width: 300,
height: 24,
flexDirection: 'row',
},
text: {
width: 180,
height: 30,
color: '#1a1a1a',
marginTop: 4,
marginLeft:8,
fontSize: 20,
},
text1: {
width: 180,
height: 30,
marginLeft: 10,
marginTop: 30,
fontSize: 16,
},
tag: {
width: 64,
height: 20,
marginRight: 10,
backgroundColor: 'rgba(212,212,212,0.50)',
borderRadius: 16,
fontSize: 12,
lineHeight: 20,
color: '#353535',
textAlign: 'center',
},
money: {
width: 180,
height: 36,
fontSize: 24,
fontWeight: 'blod',
fontWeight: 700,
color: '#ff6a00',
},
moneyD: {
width: 180,
height: 24,
fontSize: 16,
},
detail: {
color: '#353535',
width: 180,
height: 24,
fontSize: 12,
}
};
function getText(str) {
return str
};
module.exports = {
wxml,
style
}