| | |
| | | <u-button shape="square" type="primary" @click="submit"> 提交 </u-button> |
| | | </view> |
| | | </view> |
| | | <u-overlay :show="show" :mask-click-able='false' opacity='0.8'> |
| | | </u-overlay> |
| | | </view> |
| | | </template> |
| | | <script> |
| | |
| | | }, |
| | | data() { |
| | | return { |
| | | basicInfor: {} |
| | | basicInfor: {}, |
| | | unitListL: [], |
| | | userInfor: null, |
| | | show: false |
| | | } |
| | | }, |
| | | computed: { |
| | | pageState() { |
| | | return this.basicInfor.pageState |
| | | } |
| | | }, |
| | | }, |
| | | created() { |
| | | this.getUnitList() |
| | | }, |
| | | onLoad: function(option) { |
| | | console.log('option', option) |
| | | //option为object类型,会序列化上个页面传递的参数 |
| | | this.basicInfor = JSON.parse(option.infor) |
| | | this.share.title = '交办单信息' |
| | | }, |
| | | onBackPress(e) { |
| | | uni.navigateBack({ |
| | | delta: 1, //返回上上一级注意这里要设置为2 |
| | | }) |
| | | return false |
| | | // let type = JSON.parse(option.type) |
| | | console.log('option', option) |
| | | this.userInfor = JSON.parse(uni.getStorageSync('userInfor') || 'null') |
| | | if (option.type === 'share' && this.userInfor) { |
| | | let params = { |
| | | allocationNum: this.basicInfor.allocationNum, |
| | | userId: this.userInfor.userId |
| | | } |
| | | this.$http.httpGet('/allocationApp/authority', params).then(res => { |
| | | res.data = false |
| | | if (!res.data) { |
| | | uni.showModal({ |
| | | content: '您暂无操作权限,请联系管理员!', |
| | | showCancel: false, |
| | | confirmText: '确定', |
| | | success: res => { |
| | | if (res.confirm) { |
| | | uni.reLaunch({ |
| | | url: '/pages/index/index', |
| | | }) |
| | | } |
| | | }, |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | | console.log('this.basicInfor ', this.basicInfor) |
| | | }, |
| | | methods: { |
| | | closePop() {}, |
| | | getUnitList() { |
| | | this.$http.httpGet('/allocation/unit').then(res => { |
| | | this.unitList = res.data |
| | | let data = '' |
| | | if (this.basicInfor.unitId && this.unitList.length > 0) { |
| | | data = this.unitList && this.unitList.find(a => Number(a.unitId) === Number(this.basicInfor |
| | | .unitId)).unitName |
| | | let time = this.basicInfor.time.slice(5) |
| | | this.share.title = `${data}-${time}的交办单` |
| | | } |
| | | }) |
| | | }, |
| | | radioGroupChange(e) { |
| | | console.log('radioGroupe,e', this.workForme.isChange) |
| | | }, |
| | |
| | | showTabBar: true |
| | | } |
| | | }) |
| | | uni.navigateBack({ |
| | | delta: 1, //返回上上一级注意这里要设置为2 |
| | | uni.redirectTo({ |
| | | url: '/pages/index/index', |
| | | }) |
| | | }, |
| | | refuse() { |