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.
1 line
41 KiB
JavaScript
1 line
41 KiB
JavaScript
|
1 year ago
|
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-collect-index"],{"028d":function(t,a,i){"use strict";i("7a82");var e=i("4ea4").default;Object.defineProperty(a,"__esModule",{value:!0}),a.default=void 0;var o=e(i("ade3"));i("d3b7"),i("99af"),i("159b"),i("e9c4");var n=e(i("3d9f")),r=e(i("3d9f")),d=getApp(),c=i("233b"),s={components:{bottomDrawer:n.default},data:function(){return{recordShow:!1,toped:"1",recordList:[],storeJobListSearchForm:{pageNum:1,pageSize:20,classify:1,sex:-1,workTypeStr:"",lat:"",lng:"",jobClassify:"",sortTag:0,jobSpecialLabelIds:"",cityName:"",brandIds:"",jobCategoryLabelIds:"",ujc:1,keys:""},loading:!0,hasMoreData:!1,inputShowed:!1,inputVal:"搜索工作",wxCode:"",isCollect:!1,collectTxt:"收藏",searchCityParamStorage:{name:"",shortName:""},pageShow:!1,whichOneShow:"",totalPage:"",currPage:"",triggered:!1,isTrigger:!1,currentJobDrawer:"",currentInfo:"",topNum:0,scrollTo:"",selectBrandList:[],selectJobList:[],activez:"",sexid:""}},onShow:function(){this.setData({recordList:[]}),this.getJobList()},methods:{goBack:function(){uni.navigateBack({delta:-1})},goDetail:function(t){console.log(t);uni.navigateTo({url:"../detail/index?storeJobId="+t.currentTarget.dataset.id+"&wxCode="+this.wxCode})},getJobList:function(){var t=this;return t.setData({pageShow:!1}),new Promise((function(a,i){uni.showLoading({title:"加载中..."}),console.log(t.storeJobListSearchForm),uni.request({url:d.globalData.ip+"/yishoudan/custom/job/listApp",method:"POST",header:d.globalData.headers,data:t.storeJobListSearchForm,success:function(i){if(console.log("职位列表↓↓↓↓"),console.log(i),t.setData({totalPage:i.data.data.pageBean.pageCount,currPage:i.data.data.pageBean.currentPage}),setTimeout((function(){t.setData({triggered:!1})}),1e3),null==i.data.data.pageBean.recordList||0==i.data.data.pageBean.recordList.length||i.data.data.pageBean.recordList.length<t.storeJobListSearchForm.pageSize){var e=c.disposeJobListData(i.data.data.pageBean.recordList);t.recordList=t.recordList.concat(e),t.setData({recordList:t.recordList,hasMoreData:!1,isTrigger:!1})}else{e=c.disposeJobListData(i.data.data.pageBean.recordList);t.recordList=t.recordList.concat(e),t.setData({recordList:t.recordList,hasMoreData:!0,isTrigger:!1})}uni.hideLoading({success:function(t){}}),t.setData({loading:!1,pageShow:!0,storeJobListSearchForm:t.storeJobListSearchForm}),a(),t.recordList.forEach((function(t,a){console.log(t.storeDistrict),t["citys"]=c.setJobInfoPosition(t.storeDistrict),d.globalData.isNotEmptyCheck(t.returnFeeType)||"0"==t.returnFeeType||"0"==t.returnFee?t["fuWuFei"]=c.getReturnFeeTypeName1ById(t.returnFeeType,t.returnFee):t["fuWuFei"]=""})),t.setData({recordList:t.recordList,currentJobDrawer:t.currentJobDrawer}),console.log(t.recordList)}})}))},collectPaste:function(t){var a=t.currentTarget.dataset.collected,i=t.currentTarget.dataset.jobid;this.doCollected(a,i)},doCollected:function(t,a){var i=this,e="/yishoudan/custom/job/collect/"+a;console.log(d.globalData.headers),uni.request({url:d.globalData.ip+e,data:{storeJobId:a},header:d.globalData.headers,method:"GET",success:function(e){var o;if(t-1==0){for(var n=0;n!=i.recordList.length;++n)if(i.recordList[n].id-a==0){i.recordList[n].collected=2;break}o="取消收藏",1==i.choiceCollect&&(i.storeJobListSearchForm.pageNum=1,i.setData({recordList:[],storeJobListSearchForm:i.storeJobListSearchForm}),i.getJobList())}else{for(n=0;n!=i.recordList.length;++n)if(i.recordList[n].id-a==0){i.recordList[n].collected=1;break}o="收藏成功"}i.setData({recordList:i.recordList}),uni.showToast({icon:"none",title:o})},fail:function(t){console.log("操作失败")}})},hidedrawershow:function(t){console.log(t),this.setData((0,o.default)({},t.detail.type,!1)),uni.showTabBar({animation:!1,success:function(t){},fail:function(){},complete:function(){}})},recordBill:function(t){console.log(t.currentTarget.dataset.job),this.setData({recordShow:!0,currentInfo:t.currentTarget.dataset.job}),console.log(this.recordShow),uni.hideTabBar({animation:!1,success:function(t){},fail:function(){},complete:function(){}}
|