123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121 |
- <template >
- <view class="jp-work-item" @click="ckBtn">
- <view class="jp-work-name">
- <h3>{{item.title}}</h3>
- <span>{{item.wageTypeN}}</span>
- </view>
- <view class="jp-work-tag" v-if="item.requirements">
- <u-tag v-for="(text,index) in spiltItem(item.requirements)" :key="index" :text="text" mode="dark" bg-color="#f1f1f7" color="#999" size="mini"/>
-
- </view>
- <view class="jp-work-info">
- <view class="u-flex">
- <u-avatar :src="item.logo" size="40"></u-avatar>
- <p>{{item.name}} {{item.scaleName}}</p>
- </view>
- <p>{{item.cityName}}</p>
- </view>
- </view>
- </template>
- <script>
-
-
- export default {
- name:"Common",
- props:{
- item: {
- require: true,
- default: {},
- },
- ck:{
- require: false,
- default:true
- },
- obj:{
- require: false,
- default:null
- }
- },
- data() {
- return {
-
- };
-
- },methods:{
- ckBtn(){
- if(this.ck){
- this.gotoUrl('pages/job/index/recruitInfo/recruitInfo?id='+this.item.id)
- }else{
- this.$emit("ckItem",this.item.id)
- }
- },
- spiltItem(text){
- if(text){
- return text.split(",")
-
- }else{
- return []
- }
- },
-
- },mounted(){
- if(this.obj){
- var sz=this.obj.split(",");
- for(var i in sz ){
- var string1 = sz[i].split("=")[0];
- var string2 = sz[i].split("=")[1];
- this.item[string2]=this.item[string1];
-
- }
- this.$forceUpdate()
- }
-
- },destroyed(){
-
- }
-
- }
- </script>
- <style scoped lang="scss">
- .jp-work-item{
- padding:30rpx;
- background-color: #fff;
- border-bottom: 1px solid #f7f7f7;
- &:last-child{
- border-bottom:none;
- }
- .jp-work-name{
- display: flex;
- justify-content: space-between;
- align-items: center;
- h3{
- font-size: 36rpx;
- }
- span{
- font-size: 32rpx;
- color:#FF1700
- }
- }
- .jp-work-tag{
- display: flex;
- align-items: center;
- margin-top: 10rpx;
- *{
- margin-right: 10rpx;
- }
- }
- .jp-work-info{
- display: flex;
- justify-content: space-between;
- align-items: center;
- margin-top: 10rpx;
- p{
- color:#999;
- font-size: 24rpx;
- margin-left: 10rpx;
- }
- }
- }
- </style>
|