提示框导入
当班信息页面功能处理 链接跳转 接入 菜单参数 orgid 导入接口 获取组织为班组的列表 获取当班显示信息 requset 基础方法修改
This commit is contained in:
parent
68c1124ad6
commit
039cf70aa6
1
main.js
1
main.js
@ -3,6 +3,7 @@ import uView from '@/uni_modules/uview-ui'
|
||||
|
||||
// #ifndef VUE3
|
||||
import Vue from 'vue'
|
||||
import './utils/showMsg.js'
|
||||
import './uni.promisify.adaptor'
|
||||
import QuerySelector from 'components/custom/query-selector.vue'
|
||||
|
||||
|
||||
@ -34,7 +34,7 @@
|
||||
{
|
||||
"path": "pages/apply/user",
|
||||
"style": {
|
||||
"navigationBarTitleText": "当班员工"
|
||||
"navigationBarTitleText": "当班工作人员"
|
||||
}
|
||||
},
|
||||
{
|
||||
|
||||
@ -8,53 +8,119 @@
|
||||
<view style="position: absolute;left: -10px;color: #3d4b70;top: -3px;">*</view>
|
||||
</view>
|
||||
<view style="font-size: 15px; font-weight: bold;color: #3d4b70;margin-bottom: 10px;">组织信息</view>
|
||||
<u-form-item label="组织名称" prop="NAME" borderBottom ref="item1">
|
||||
<u--input v-model="model.NAME" border="none"
|
||||
customStyle="margin:0px;display:flex;padding:3px 9px"></u--input>
|
||||
</u-form-item>
|
||||
<u-form-item label="员工数" prop="COUNT" borderBottom @click="showSex = true;" ref="item1">
|
||||
<u--input v-model="model.COUNT" disabled disabledColor="#ffffff" placeholder="员工数量"
|
||||
border="none" suffixIcon="arrow-right" fontSize="14px"
|
||||
<u-form-item label="班组名称" prop="DEPARTMENT_NAME" borderBottom ref="item1"
|
||||
@click="handleShowSheet({title: '班组名称'})">
|
||||
<u--input v-model="model.DEPARTMENT_NAME" border="none" suffixIcon="arrow-right"
|
||||
customStyle="margin:0px;display:flex;padding:3px 9px"
|
||||
suffixIconStyle="font-size:12px"></u--input>
|
||||
</u-form-item>
|
||||
<u-form-item label="当班状态" prop="SchedulingType" borderBottom @click="showSex = true;" ref="item1">
|
||||
<u--input v-model="model.SchedulingType" disabled disabledColor="#ffffff" placeholder="员工数量"
|
||||
border="none" fontSize="14px"
|
||||
customStyle="margin:0px;display:flex;padding:3px 9px"></u--input>
|
||||
</u-form-item>
|
||||
<u-form-item label="当班开始时间" prop="START_TIME" borderBottom @click="showSex = true;" ref="item1">
|
||||
<u--input v-model="model.START_TIME" disabled disabledColor="#ffffff" placeholder="员工数量"
|
||||
border="none" fontSize="14px"
|
||||
customStyle="margin:0px;display:flex;padding:3px 9px"></u--input>
|
||||
</u-form-item>
|
||||
<u-form-item label="当班结束时间" prop="END_TIME" borderBottom @click="showSex = true;" ref="item1">
|
||||
<u--input v-model="model.END_TIME" disabled disabledColor="#ffffff" placeholder="员工数量"
|
||||
border="none" fontSize="14px"
|
||||
customStyle="margin:0px;display:flex;padding:3px 9px"></u--input>
|
||||
</u-form-item>
|
||||
<u-form-item label="当班员工数" prop="COUNT_WORKER" borderBottom @click="showSex = true;" ref="item1">
|
||||
<u--input v-model="model.COUNT_WORKER" disabled disabledColor="#ffffff" placeholder="员工数量"
|
||||
border="none" fontSize="14px"
|
||||
customStyle="margin:0px;display:flex;padding:3px 9px"></u--input>
|
||||
</u-form-item>
|
||||
<u-form-item label="请假员工数" prop="COUNT_LEVEL" borderBottom @click="showSex = true;" ref="item1">
|
||||
<u--input v-model="model.COUNT_LEVEL" disabled disabledColor="#ffffff" placeholder="员工数量"
|
||||
border="none" fontSize="14px"
|
||||
customStyle="margin:0px;display:flex;padding:3px 9px"></u--input>
|
||||
</u-form-item>
|
||||
<u-form-item label="下次排班时间" prop="SchedulingNEXTTIME" borderBottom @click="showSex = true;"
|
||||
ref="item1">
|
||||
<u--input v-model="model.SchedulingNEXTTIME" disabled disabledColor="#ffffff" placeholder="员工数量"
|
||||
border="none" fontSize="14px"
|
||||
customStyle="margin:0px;display:flex;padding:3px 9px"></u--input>
|
||||
</u-form-item>
|
||||
|
||||
<!-- <u-form-item label="员工信息" prop="SchedulingNEXTTIME" borderBottom @click="showSex = true;"
|
||||
ref="item1">
|
||||
</u-form-item> -->
|
||||
<!-- <u-form-item>工作人员信息:</u-form-item> -->
|
||||
<u-form-item>
|
||||
<u-list key="qb">
|
||||
<u-list-item v-for=" item in model.ListUser">
|
||||
<u-cell style="background-color: whitesmoke;" :title="item"> </u-cell>
|
||||
</u-list-item>
|
||||
</u-list>
|
||||
</u-form-item>
|
||||
|
||||
<!-- <u-form-item key="db">
|
||||
<u-list>
|
||||
<u-list-item v-for="item in model.LISTPERSON_SCHEDULING">
|
||||
<u-cell :title="`${item.NAME + '(当班)'}`">
|
||||
|
||||
</u-cell>
|
||||
</u-list-item>
|
||||
</u-list>
|
||||
</u-form-item>
|
||||
|
||||
<u-form-item key="qj">
|
||||
<u-list>
|
||||
<u-list-item v-for="(item, index) in model.LISTUSER_LEAVE">
|
||||
<u-cell :title="item.NAME+' (请假)'"> </u-cell>
|
||||
</u-list-item>
|
||||
</u-list>
|
||||
</u-form-item> -->
|
||||
|
||||
</u-form>
|
||||
|
||||
|
||||
<!-- 动态加载用户信息 -->
|
||||
<u-sticky offset-top="20">
|
||||
<!-- <u-sticky offset-top="20">
|
||||
<view class="sub-form">
|
||||
<view class="sub-form-wrap">
|
||||
<u--form labelPosition="left" labelWidth="auto" labelAlign="center"
|
||||
errorType="border-bottom" ref="sForm">
|
||||
errorType="border-bottom" style="margin-bottom: 50px;" ref="sForm">
|
||||
<uni-collapse :border="false" accordion>
|
||||
<uni-card style="margin-bottom: 16px;" margin="0" spacing="0" :is-shadow="false"
|
||||
v-for="(item, index) in model.Nav_ListUser.filter(i => !i.IS_DELETED)">
|
||||
<uni-card style="margin-bottom: 5px;" margin="0" spacing="0" :is-shadow="false"
|
||||
v-for="(item, index) in model.LISTPERSON_SCHEDULING">
|
||||
<uni-collapse-item :title="(index+1) + '. ' + item.NAME" name="1">
|
||||
<u-form-item label="姓名" prop="NAME" borderBottom>
|
||||
<u--input disabled disabledColor="#fff" v-model="item.NAME"
|
||||
border="none" inputAlign="right"></u--input>
|
||||
</u-form-item>
|
||||
<u-form-item label="性别" prop="SEX" borderBottom>
|
||||
<u--input disabled disabledColor="#fff" v-model="item.NAME"
|
||||
border="none" inputAlign="right"></u--input>
|
||||
<u--input disabled disabledColor="#fff" v-model="item.SEX" border="none"
|
||||
inputAlign="right"></u--input>
|
||||
</u-form-item>
|
||||
</uni-collapse-item>
|
||||
</uni-card>
|
||||
|
||||
<uni-card style="margin-bottom: 5px;" margin="0" spacing="0" :is-shadow="false"
|
||||
v-for="(item, index) in model.LISTUSER_LEAVE">
|
||||
<uni-collapse-item :title="(index+1) + '. ' + item.NAME" name="1">
|
||||
<u-form-item label="姓名" prop="NAME" borderBottom>
|
||||
<u--input disabled disabledColor="#fff" v-model="item.NAME"
|
||||
border="none" inputAlign="right"></u--input>
|
||||
</u-form-item>
|
||||
<u-form-item label="性别" prop="SEX" borderBottom>
|
||||
<u--input disabled disabledColor="#fff" v-model="item.SEX" border="none"
|
||||
inputAlign="right"></u--input>
|
||||
</u-form-item>
|
||||
</uni-collapse-item>
|
||||
</uni-card>
|
||||
|
||||
</uni-collapse>
|
||||
</u--form>
|
||||
|
||||
</view>
|
||||
</view>
|
||||
</u-sticky>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</u-sticky> -->
|
||||
|
||||
<!--
|
||||
<view style="display: flex;flex-direction: row;" class="bottom-button">
|
||||
<u-button type="primary" @click="reset" color="#3d4b70" :plain="true"
|
||||
style="margin-right: 5px;">重置</u-button>
|
||||
@ -62,16 +128,11 @@
|
||||
v-if="loading == false">提交</u-button>
|
||||
<u-button type="primary" loading loadingText="加载中" color="#3d4b70" style="margin-left: 5px;"
|
||||
v-if="loading == true">提交</u-button>
|
||||
</view>
|
||||
<u-action-sheet :show="showSex" :actions="actions" title="请选择性别" @close="showSex = false"
|
||||
@select="sexSelect">
|
||||
</u-action-sheet>
|
||||
<u-datetime-picker :show="dateTimePickerInfo.showCheckDate" mode="date"
|
||||
v-model='dateTimePickerInfo.defaultDateTime' :formatter="formatter" @confirm="handleCheckDate"
|
||||
@close="dateTimePickerInfo.showCheckDate = false;"
|
||||
@cancel="dateTimePickerInfo.showCheckDate = false;"></u-datetime-picker>
|
||||
<u-picker :show="pickerShow" :columns="pickerColumns" @confirm="pickerConfirm"
|
||||
@cancel="pickerCancel"></u-picker>
|
||||
</view> -->
|
||||
|
||||
<query-selector :show="selectorInfo.showPopup" :defaultChecked="selectorInfo.defaultChecked"
|
||||
:title="selectorInfo.title" :lists="selectorInfo.dataLists" @search="handleSearch"
|
||||
@select="handleSelected" @close="selectorInfo.showPopup=false" :total="selectorInfo.totalCount" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@ -80,184 +141,167 @@
|
||||
|
||||
<script>
|
||||
import {
|
||||
RegisterUser
|
||||
} from '../../services/apply.js'
|
||||
import config from '../../config/common.js'
|
||||
PagedDep,
|
||||
WorkerScheduling
|
||||
} from '../../services/apply'
|
||||
import {
|
||||
isChinaMobilePhone,
|
||||
easyCheckID,
|
||||
getNowFormatDate
|
||||
} from '../../utils/common.js'
|
||||
initFilter,
|
||||
extendRule
|
||||
} from '../../utils/common'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
showSex: false,
|
||||
appurl: config.uni_app_url,
|
||||
formatter: null,
|
||||
pickerShow: false,
|
||||
loading: false,
|
||||
pickerColumns: [Array(60).fill(null).map((_, i) => i)],
|
||||
OrgId: '',
|
||||
model: {
|
||||
NAME:'组织名称',
|
||||
COUNT:'员工数量',
|
||||
Nav_ListUser: [{
|
||||
NAME: '姓名显示',
|
||||
SEX: '性别显示'
|
||||
|
||||
}]
|
||||
DEPARTMENT_NAME: '磨重一班',
|
||||
DEPARTMENT_ID: '',
|
||||
SchedulingType: '',
|
||||
COUNT_WORKER: '',
|
||||
COUNT_LEVEL: '',
|
||||
START_TIME: '',
|
||||
END_TIME: '',
|
||||
SchedulingNEXTTIME: '',
|
||||
LISTPERSON_SCHEDULING: [{
|
||||
NAME: ''
|
||||
}],
|
||||
LISTUSER_LEAVE: [{
|
||||
NAME: ''
|
||||
}],
|
||||
ListUser: []
|
||||
},
|
||||
dateTimePickerInfo: {
|
||||
showCheckDate: false,
|
||||
defaultDateTime: uni.$u.timeFormat(new Date(), 'yyyy-mm-dd'),
|
||||
value: '',
|
||||
selectorInfo: {
|
||||
showPopup: false,
|
||||
totalCount: 0,
|
||||
title: '班组名称',
|
||||
// itemData: {},
|
||||
index: 0,
|
||||
dataLists: [],
|
||||
defaultText: '',
|
||||
defaultValue: '',
|
||||
name: '',
|
||||
defaultChecked: []
|
||||
},
|
||||
actions: [{
|
||||
name: '男',
|
||||
},
|
||||
{
|
||||
name: '女',
|
||||
},
|
||||
],
|
||||
rules: {
|
||||
'NAME': {
|
||||
type: 'string',
|
||||
required: true,
|
||||
message: '请填写姓名',
|
||||
trigger: ['blur', 'change']
|
||||
},
|
||||
'COUNT': {
|
||||
type: 'string',
|
||||
max: 1,
|
||||
required: true,
|
||||
message: '请选择男或女',
|
||||
trigger: ['blur', 'change']
|
||||
},
|
||||
},
|
||||
radio: '',
|
||||
switchVal: false
|
||||
}
|
||||
},
|
||||
onLoad() {},
|
||||
onLoad(option) {
|
||||
this.model.DEPARTMENT_ID = option.DEPARTMENT_ID // 'B18F95F4-572A-E521-1412-FA8CE50DC98A'
|
||||
this.OrgId = option.OrgId // 'B043B28B-BBC3-C452-6052-4FBA1457ABFA'
|
||||
this.WorkerScheduling()
|
||||
|
||||
},
|
||||
onReady() {
|
||||
//如果需要兼容微信小程序,并且校验规则中含有方法等,只能通过setRules方法设置规则。
|
||||
this.$refs.uForm.setRules(this.rules)
|
||||
},
|
||||
methods: {
|
||||
sexSelect(e) {
|
||||
this.model.userInfo.Sex = e.name
|
||||
this.$refs.uForm.validateField('userInfo.Sex')
|
||||
},
|
||||
showCheckDate() {
|
||||
if (this.model.userInfo.InTime == null) {
|
||||
this.model.userInfo.InTime = uni.$u.timeFormat(new Date(),
|
||||
'yyyy-mm-dd')
|
||||
WorkerScheduling() {
|
||||
const modelRequest = {
|
||||
Keyword: this.model.DEPARTMENT_ID,
|
||||
OrgId: this.OrgId
|
||||
}
|
||||
this.dateTimePickerInfo = {
|
||||
showCheckDate: true,
|
||||
defaultDateTime: this.model.userInfo.InTime,
|
||||
WorkerScheduling(modelRequest).then(res => {
|
||||
if (res.IsSuccessful) {
|
||||
this.model = res.Data
|
||||
var ListUser = []
|
||||
if (this.model.LISTPERSON_SCHEDULING != null && this.model.LISTPERSON_SCHEDULING.length >
|
||||
0) {
|
||||
this.model.LISTPERSON_SCHEDULING.forEach(e => {
|
||||
ListUser.push(e.NAME + '(当班)')
|
||||
})
|
||||
}
|
||||
},
|
||||
handleCheckDate(e) {
|
||||
// let v = uni.$u.timeFormat(e.value, 'yyyy-mm-dd')
|
||||
this.model.userInfo.InTime = uni.$u.timeFormat(e.value,
|
||||
'yyyy-mm-dd')
|
||||
this.dateTimePickerInfo.showCheckDate = false
|
||||
},
|
||||
pickerConfirm(e) {
|
||||
this.model.userInfo.WORKINGYEAR = e.value.toString()
|
||||
this.pickerShow = false
|
||||
},
|
||||
pickerCancel(e) {
|
||||
this.pickerShow = false
|
||||
},
|
||||
reset() {
|
||||
this.model.userInfo = {
|
||||
Name: '',
|
||||
Sex: '',
|
||||
Phone: '',
|
||||
ID_CARD: '',
|
||||
InTime: '',
|
||||
WORKINGYEAR: '',
|
||||
}
|
||||
},
|
||||
submit() {
|
||||
|
||||
// if (this.model.userInfo.Name == '' ||
|
||||
// this.model.userInfo.Sex == '' ||
|
||||
// this.model.userInfo.Phone == '' ||
|
||||
// this.model.userInfo.ID_CARD == '' ||
|
||||
// this.model.userInfo.InTime == '') {
|
||||
// uni.showToast({
|
||||
// icon: 'error',
|
||||
// title: '信息不能为空'
|
||||
// })
|
||||
// return
|
||||
// }
|
||||
// if (isChinaMobilePhone(this.model.userInfo.Phone) == false) {
|
||||
// uni.showToast({
|
||||
// icon: 'error',
|
||||
// title: '手机号码格式不正确'
|
||||
// })
|
||||
// return
|
||||
// }
|
||||
// if (easyCheckID(this.model.userInfo.ID_CARD) == false) {
|
||||
// uni.showToast({
|
||||
// icon: 'error',
|
||||
// title: '身份证号码格式不正确'
|
||||
// })
|
||||
// return
|
||||
// }
|
||||
// this.loading = true
|
||||
// const json = {
|
||||
// Name: this.model.userInfo.Name,
|
||||
// Sex: this.model.userInfo.Sex == '男' ? '1' : '0',
|
||||
// Phone: this.model.userInfo.Phone,
|
||||
// ID_CARD: this.model.userInfo.ID_CARD,
|
||||
// InTime: this.model.userInfo.InTime,
|
||||
// WORKINGYEAR: this.model.userInfo.WORKINGYEAR,
|
||||
// }
|
||||
// // const json = {
|
||||
// // Name: '云',
|
||||
// // Sex: '0',
|
||||
// // Phone: '18480141719',
|
||||
// // ID_CARD: '230182200000000000',
|
||||
// // InTime: '2024-07-25',
|
||||
// // WORKINGYEAR: '0',
|
||||
// // }
|
||||
// RegisterUser(json).then((res) => {
|
||||
// if (res.code == 200) {
|
||||
// this.loading = false
|
||||
// uni.showToast({
|
||||
// title: '注册成功!',
|
||||
// icon: 'none'
|
||||
// })
|
||||
// setTimeout(() => {
|
||||
// uni.hideToast();
|
||||
// location.href = this.appurl
|
||||
// // uni.redirectTo({
|
||||
// // url: '/pages/webview/webview?url=' + this.appurl
|
||||
// // })
|
||||
// }, 1500)
|
||||
// // uni.navigateTo({
|
||||
// // url: '/pages/apply/complete?type=success'
|
||||
// // })
|
||||
// } else {
|
||||
// this.loading = false
|
||||
// uni.showToast({
|
||||
// title: res.msg,
|
||||
// icon: 'none'
|
||||
// })
|
||||
// // uni.navigateTo({
|
||||
// // url: `/pages/apply/complete?type=failed&title=${res.msg}`
|
||||
// // })
|
||||
// }
|
||||
// }).catch((err) => {
|
||||
// this.loading = false
|
||||
// uni.navigateTo({
|
||||
// url: `/pages/apply/complete?type=failed&title=${err.msg}`
|
||||
// })
|
||||
// })
|
||||
if (this.model.LISTUSER_LEAVE != null && this.model.LISTUSER_LEAVE.length > 0) {
|
||||
this.model.LISTUSER_LEAVE.forEach(e => {
|
||||
ListUser.push(e.NAME + '(请假)')
|
||||
})
|
||||
}
|
||||
this.model.ListUser = ListUser
|
||||
} else {
|
||||
uni.$showErrorInfo(res.ErrorMessage)
|
||||
// this.model.DEPARTMENT_NAME = ''
|
||||
this.model.DEPARTMENT_ID = ''
|
||||
this.model.SchedulingType = ''
|
||||
this.model.COUNT_WORKER = ''
|
||||
this.model.COUNT_LEVEL = ''
|
||||
this.model.START_TIME = ''
|
||||
this.model.END_TIME = ''
|
||||
this.model.SchedulingNEXTTIME = ''
|
||||
this.model.LISTPERSON_SCHEDULING = []
|
||||
this.model.LISTUSER_LEAVE = []
|
||||
this.model.ListUser = []
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
|
||||
closePicker() {
|
||||
this.comPickerInfo = {
|
||||
showSheet: false,
|
||||
columns: [],
|
||||
title: '',
|
||||
name: '',
|
||||
formIndex: undefined
|
||||
}
|
||||
},
|
||||
|
||||
//显示组件
|
||||
handleChange() {
|
||||
this.selectorInfo.showPopup = true
|
||||
this.selectorInfo.title = '班组名称'
|
||||
this.handleSearch()
|
||||
},
|
||||
|
||||
//数据加载
|
||||
handleSearch(val, pageIndex) {
|
||||
var p = {
|
||||
name: this.selectorInfo.name,
|
||||
title: this.selectorInfo.title,
|
||||
val: val,
|
||||
pageIndex: pageIndex
|
||||
}
|
||||
this.handleShowSheet(p)
|
||||
},
|
||||
|
||||
async handleShowSheet(p) {
|
||||
var defaultChecked = []
|
||||
const json = initFilter(this.OrgId, null, "NAME", 0, (p.pageIndex ?? 1));
|
||||
json.IgnoreDataRule = true
|
||||
json.Limit = 20
|
||||
if (p.val) {
|
||||
extendRule(json, "NAME", 9, p.val)
|
||||
}
|
||||
let dataSelect = await PagedDep(json).then(res => {
|
||||
this.selectorInfo.totalCount = res.TotalCount
|
||||
if (res != undefined && res.Data.length > 0) {
|
||||
for (let i = 0; i < res.Data.length; i++) {
|
||||
res.Data[i].name = res.Data[i].NAME
|
||||
res.Data[i].code = res.Data[i].CODE
|
||||
}
|
||||
}
|
||||
return res.Data
|
||||
})
|
||||
|
||||
if (defaultChecked == null)
|
||||
defaultChecked = []
|
||||
if (dataSelect.length) {
|
||||
this.selectorInfo = {
|
||||
totalCount: this.selectorInfo.totalCount,
|
||||
showPopup: true,
|
||||
title: p.title,
|
||||
name: p.name,
|
||||
dataLists: dataSelect,
|
||||
defaultChecked: defaultChecked
|
||||
}
|
||||
} else {
|
||||
// 暂无数据
|
||||
}
|
||||
},
|
||||
handleSelected(e) {
|
||||
this.selectorInfo.showPopup = false
|
||||
this.model.DEPARTMENT_NAME = e.NAME
|
||||
this.model.DEPARTMENT_ID = e.ID
|
||||
this.WorkerScheduling()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
@ -4,7 +4,7 @@
|
||||
<u-grid :border="false" :col="2"> <!-- @click="click" -->
|
||||
<u-grid-item v-for="(baseListItem,baseListIndex) in baseList" :key="baseListIndex" bgColor="#fff">
|
||||
<u-icon :customStyle="{paddingTop:20+'rpx'}" :name="baseListItem.iconName" :size="42"
|
||||
@click="menuClick(baseListItem.url)" color="#304ffe"></u-icon>
|
||||
@click="menuClick(baseListItem)" color="#304ffe"></u-icon>
|
||||
<text class="grid-text">{{baseListItem.name}}</text>
|
||||
</u-grid-item>
|
||||
</u-grid>
|
||||
@ -26,6 +26,10 @@
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
|
||||
DEPARTMENT_ID: 'B18F95F4-572A-E521-1412-FA8CE50DC98A',
|
||||
OrgId: '',
|
||||
|
||||
baseList: [
|
||||
|
||||
{
|
||||
@ -79,9 +83,9 @@
|
||||
// })
|
||||
// },
|
||||
|
||||
menuClick(linkToUrl) {
|
||||
menuClick(menuInfo) {
|
||||
uni.navigateTo({
|
||||
url: linkToUrl
|
||||
url: menuInfo.url +'?DEPARTMENT_ID='+this.DEPARTMENT_ID+'&OrgId='+menuInfo.ORG_ID
|
||||
})
|
||||
},
|
||||
goCamera() {
|
||||
|
||||
@ -16,3 +16,23 @@ export const RegisterUser = (params) => {
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
//获取班组
|
||||
export const PagedDep = (params) => {
|
||||
return request.send({
|
||||
url: '/BI/H5Controller/PagedDep',
|
||||
method: 'post',
|
||||
data: params,
|
||||
})
|
||||
}
|
||||
|
||||
//获取某个班组的当班信息
|
||||
export const WorkerScheduling = (params) => {
|
||||
return request.send({
|
||||
url: '/BI/H5Controller/WorkerScheduling',
|
||||
method: 'post',
|
||||
data: params,
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -8,7 +8,7 @@ export default {
|
||||
const pages = getCurrentPages()
|
||||
const currentPage = pages[pages.length - 1]
|
||||
const Options = currentPage.options
|
||||
let Company = Options.Company?Options.Company:'XLK'
|
||||
let Company = Options.Company ? Options.Company : 'XLK'
|
||||
let tenantId = ''
|
||||
if (Company == 'DCJD') {
|
||||
tenantId = 'A0000025'
|
||||
@ -31,13 +31,13 @@ export default {
|
||||
'Tenant': tenantId, // avue配置相关
|
||||
...params.header
|
||||
}
|
||||
if (method == "post") {
|
||||
header = {
|
||||
'Content-Type': 'application/x-www-form-urlencoded',
|
||||
'Tenant': tenantId,
|
||||
...params.header
|
||||
};
|
||||
}
|
||||
// if (method == "post") {
|
||||
// header = {
|
||||
// 'Content-Type': 'application/x-www-form-urlencoded',
|
||||
// 'Tenant': tenantId,
|
||||
// ...params.header
|
||||
// };
|
||||
// }
|
||||
return new Promise((resolve, reject) => {
|
||||
uni.request({
|
||||
url: config.serviceHost(url),
|
||||
|
||||
Loading…
Reference in New Issue
Block a user