许可证编辑

This commit is contained in:
shijing 2023-04-10 18:01:59 +08:00
parent a1c1bea342
commit 1a3e4b7d1a
11 changed files with 67 additions and 40 deletions

View File

@ -30,10 +30,14 @@
<view class="uni-form-item uni-column" style="border-bottom: 1upx solid #eeeeee;"> <view class="uni-form-item uni-column" style="border-bottom: 1upx solid #eeeeee;">
<view class="title">作业人员:</view> <view class="title">作业人员:</view>
<view style="position: relative;"> <view style="position: relative;">
<ba-tree-picker ref="workerPicker" :multiple='false' @select-change="selectChange" title="选择作业人员" <view @click="showWorkerPicker" style="position: relative;display: flex;">
<text type="text" >{{worker_name}}</text>
<uni-icons style="position: absolute; right: 0;" type="arrowright" color="#999999"/>
</view>
<!-- <ba-tree-picker ref="workerPicker" :multiple='false' @select-change="selectChange" title="选择作业人员"
:localdata="vuex_userRange" valueKey="id" textKey="name" childrenKey="children" :selectParent='false'/> :localdata="vuex_userRange" valueKey="id" textKey="name" childrenKey="children" :selectParent='false'/>
<text type="text">{{worker_name}}</text> <text type="text">{{worker_name}}</text>
<uni-icons style="position: absolute; right: 0;" @click="showPicker" type="arrowright" color="#999999"/> <uni-icons style="position: absolute; right: 0;" @click="showPicker" type="arrowright" color="#999999"/> -->
</view> </view>
</view> </view>
@ -131,13 +135,19 @@
// this.getVpeopleList(); // this.getVpeopleList();
}, },
methods: { methods: {
showWorkerPicker() {
let params='?type=worker&typeName=worker_name'
uni.navigateTo({
url:"../../comm/userSelect/index"+params
})
},
showPicker() { showPicker() {
this.$refs.workerPicker._show(); this.$refs.workerPicker._show();
}, },
selectChange(ids, names) { // selectChange(ids, names) {
this.formData.worker = ids[0]; // this.formData.worker = ids[0];
this.worker_name = names; // this.worker_name = names;
}, // },
showNext(){ showNext(){
if(["fire", "space", "cooler"].indexOf(this.oplCateCode)!=-1){ if(["fire", "space", "cooler"].indexOf(this.oplCateCode)!=-1){
this.showN = true this.showN = true
@ -147,7 +157,7 @@
let that = this; let that = this;
that.$u.api.oplItem(that.oplId).then((res) => { that.$u.api.oplItem(that.oplId).then((res) => {
that.oplDetail = res; // that.oplDetail = res; //
debugger; // debugger;
console.log(res); console.log(res);
}); });
}, },
@ -261,6 +271,19 @@
// //
submitticket(id) { submitticket(id) {
let that = this; let that = this;
if(that.oplDetail.ticket){
this.$u.api.ticketHandle(that.oplDetail.ticket, {transition: id}).then(res => {
debugger;
uni.reLaunch({
url: '/pages/home/list/ticket'
})
uni.hideLoading()
}).catch(e => {
uni.hideLoading()
})
return
}
let ticket = {}; let ticket = {};
ticket.workflow = that.initform.workflow; ticket.workflow = that.initform.workflow;
ticket.ticket_data = { ticket.ticket_data = {

View File

@ -148,8 +148,8 @@
</view> </view>
<view class="btn"> <view class="btn">
<button v-if="formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> <!-- <button v-if="formData.ticket_&&formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> -->
<button v-else type="primary" class="save-btn" @click="saveSubmit">下一步</button> <button type="primary" class="save-btn" @click="saveSubmit">下一步</button>
</view> </view>
</view> </view>
</template> </template>

View File

@ -146,8 +146,8 @@
</view> </view>
<view class="btn"> <view class="btn">
<button v-if="formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> <!-- <button v-if="formData.ticket_&&formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> -->
<button v-else type="primary" class="save-btn" @click="saveSubmit">下一步</button> <button type="primary" class="save-btn" @click="saveSubmit">下一步</button>
</view> </view>
</view> </view>
</template> </template>

View File

@ -157,8 +157,8 @@
</view> </view>
<view class="btn"> <view class="btn">
<button v-if="formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> <!-- <button v-if="formData.ticket_&&formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> -->
<button v-else type="primary" class="save-btn" @click="saveSubmit">下一步</button> <button type="primary" class="save-btn" @click="saveSubmit">下一步</button>
</view> </view>
</view> </view>
</template> </template>
@ -435,7 +435,6 @@
}, },
edit(row) {}, edit(row) {},
saveSubmit() { saveSubmit() {
debugger;
uni.showLoading({ uni.showLoading({
title: '提交中' title: '提交中'
}); });
@ -452,8 +451,11 @@
} }
}) })
if (that.oplId !== null) { if (that.oplId !== null) {
debugger;
that.$u.api.oplUpdate(that.oplId, that.formData).then(res => { that.$u.api.oplUpdate(that.oplId, that.formData).then(res => {
uni.hideLoading(); uni.hideLoading();
debugger;
console.log(that.oplCateCode)
params = `?oplId=${that.oplId}&oplCateCode=${that.oplCateCode}`; params = `?oplId=${that.oplId}&oplCateCode=${that.oplCateCode}`;
uni.navigateTo({ uni.navigateTo({
url: '/pages/workSpace/operation/workerList' + params url: '/pages/workSpace/operation/workerList' + params

View File

@ -156,8 +156,8 @@
</view> </view>
<view class="btn"> <view class="btn">
<button v-if="formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> <!-- <button v-if="formData.ticket_&&formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> -->
<button v-else type="primary" class="save-btn" @click="saveSubmit">下一步</button> <button type="primary" class="save-btn" @click="saveSubmit">下一步</button>
</view> </view>
</view> </view>
</template> </template>
@ -243,7 +243,7 @@
this.formData.operation = this.operationId; this.formData.operation = this.operationId;
}, },
onShow() { onShow() {
debugger; // debugger;
this.getOperation(); this.getOperation();
this.getOplcates(); this.getOplcates();
this.getdept(); this.getdept();
@ -326,7 +326,9 @@
that.risklist = []; that.risklist = [];
that.measurelist = []; that.measurelist = [];
that.oplCateName = res.name; that.oplCateName = res.name;
that.oplcateCode = res.code; that.oplCateCode = res.code;
debugger;
console.log(0, that.oplCateCode)
let risklist = res.risk_options_; let risklist = res.risk_options_;
let measurelist = res.measure_options_; let measurelist = res.measure_options_;
if (that.oplId !== null) { if (that.oplId !== null) {
@ -348,7 +350,6 @@
}); });
}, },
editCheckShow(risklist, measurelist) { editCheckShow(risklist, measurelist) {
debugger;
let that = this; let that = this;
that.$u.api.oplItem(that.oplId).then((res) => { that.$u.api.oplItem(that.oplId).then((res) => {
that.formData = res; // that.formData = res; //
@ -373,7 +374,6 @@
} }
that.measurelist.push(obj) that.measurelist.push(obj)
}) })
debugger;
console.log(res); console.log(res);
}); });
@ -473,7 +473,7 @@
}, },
edit(row) {}, edit(row) {},
saveSubmit() { saveSubmit() {
debugger; //
uni.showLoading({ uni.showLoading({
title: '提交中' title: '提交中'
}); });
@ -490,9 +490,13 @@
} }
}) })
if (that.oplId !== null) { if (that.oplId !== null) {
console.log(1, that.oplCateCode)
that.$u.api.oplUpdate(that.oplId, that.formData).then(res => { that.$u.api.oplUpdate(that.oplId, that.formData).then(res => {
uni.hideLoading(); uni.hideLoading();
params = `?oplId=${that.oplId}`; debugger;
console.log(1, that.oplCateCode)
params = `?oplId=${that.oplId}&oplCateCode=${that.oplCateCode}`;
uni.navigateTo({ uni.navigateTo({
url: '/pages/workSpace/operation/workerList' + params url: '/pages/workSpace/operation/workerList' + params
}) })
@ -501,7 +505,7 @@
} else { } else {
that.$u.api.oplCreate(that.formData).then(res => { that.$u.api.oplCreate(that.formData).then(res => {
uni.hideLoading(); uni.hideLoading();
params = `?oplId=${res.id}`; params = `?oplId=${res.id}&oplCateCode=${that.oplCateCode}`;
uni.navigateTo({ uni.navigateTo({
url: '/pages/workSpace/operation/workerList' + params url: '/pages/workSpace/operation/workerList' + params
}) })
@ -520,7 +524,6 @@
params.transition = that.transition; params.transition = that.transition;
that.formData.create_imgs = []; that.formData.create_imgs = [];
that.fileList.forEach(item=>{ that.fileList.forEach(item=>{
debugger;
if(item.id){ if(item.id){
console.log(item.id); console.log(item.id);
that.formData.create_imgs.push(item.id) that.formData.create_imgs.push(item.id)
@ -530,7 +533,6 @@
} }
}) })
that.$u.api.oplUpdate(that.oplId, that.formData).then(res => { that.$u.api.oplUpdate(that.oplId, that.formData).then(res => {
debugger;
console.log(this.formData.ticket) console.log(this.formData.ticket)
console.log(params) console.log(params)
this.$u.api.ticketHandle(this.formData.ticket, params).then(res => { this.$u.api.ticketHandle(this.formData.ticket, params).then(res => {

View File

@ -155,8 +155,8 @@
</view> </view>
<view class="btn"> <view class="btn">
<button v-if="formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> <!-- <button v-if="formData.ticket_&&formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> -->
<button v-else type="primary" class="save-btn" @click="saveSubmit">下一步</button> <button type="primary" class="save-btn" @click="saveSubmit">下一步</button>
</view> </view>
</view> </view>
</template> </template>

View File

@ -148,8 +148,8 @@
</view> </view>
<view class="btn"> <view class="btn">
<button v-if="formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> <!-- <button v-if="formData.ticket_&&formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> -->
<button v-else type="primary" class="save-btn" @click="saveSubmit">下一步</button> <button type="primary" class="save-btn" @click="saveSubmit">下一步</button>
</view> </view>
</view> </view>
</template> </template>

View File

@ -146,8 +146,8 @@
</view> </view>
<view class="btn"> <view class="btn">
<button v-if="formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> <!-- <button v-if="formData.ticket_&&formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> -->
<button v-else type="primary" class="save-btn" @click="saveSubmit">下一步</button> <button type="primary" class="save-btn" @click="saveSubmit">下一步</button>
</view> </view>
</view> </view>
</template> </template>

View File

@ -156,8 +156,8 @@
</view> </view>
<view class="btn"> <view class="btn">
<button v-if="formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> <!-- <button v-if="formData.ticket_&&formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> -->
<button v-else type="primary" class="save-btn" @click="saveSubmit">下一步</button> <button type="primary" class="save-btn" @click="saveSubmit">下一步</button>
</view> </view>
</view> </view>
</template> </template>
@ -319,7 +319,7 @@
that.risklist = []; that.risklist = [];
that.measurelist = []; that.measurelist = [];
that.oplCateName = res.name; that.oplCateName = res.name;
that.oplcateCode = res.code; that.oplCateCode = res.code;
let risklist = res.risk_options_; let risklist = res.risk_options_;
let measurelist = res.measure_options_; let measurelist = res.measure_options_;
if (that.oplId !== null) { if (that.oplId !== null) {

View File

@ -155,8 +155,8 @@
</view> </view>
<view class="btn"> <view class="btn">
<button v-if="formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> <!-- <button v-if="formData.ticket_&&formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> -->
<button v-else type="primary" class="save-btn" @click="saveSubmit">下一步</button> <button type="primary" class="save-btn" @click="saveSubmit">下一步</button>
</view> </view>
</view> </view>
</template> </template>
@ -321,7 +321,7 @@
that.risklist = []; that.risklist = [];
that.measurelist = []; that.measurelist = [];
that.oplCateName = res.name; that.oplCateName = res.name;
that.oplcateCode = res.code; that.oplCateCode = res.code;
let risklist = res.risk_options_; let risklist = res.risk_options_;
let measurelist = res.measure_options_; let measurelist = res.measure_options_;
if (that.oplId !== null) { if (that.oplId !== null) {

View File

@ -248,8 +248,8 @@
</view> </view>
<view class="btn"> <view class="btn">
<button v-if="formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> <!-- <button v-if="formData.ticket_&&formData.ticket_.act_state===2" type="primary" class="save-btn" @click="saveChange">提交</button> -->
<button v-else type="primary" class="save-btn" @click="saveSubmit">下一步</button> <button type="primary" class="save-btn" @click="saveSubmit">下一步</button>
</view> </view>
</view> </view>
</template> </template>
@ -431,7 +431,7 @@
that.risklist = []; that.risklist = [];
that.measurelist = []; that.measurelist = [];
that.oplCateName = res.name; that.oplCateName = res.name;
that.oplcateCode = res.code; that.oplCateCode = res.code;
let risklist = res.risk_options_; let risklist = res.risk_options_;
let measurelist = res.measure_options_; let measurelist = res.measure_options_;
if (that.oplId !== null) { if (that.oplId !== null) {