diff --git a/App.vue b/App.vue
index b9d935e..c1f3c5b 100644
--- a/App.vue
+++ b/App.vue
@@ -5,21 +5,23 @@
// brestUrl: 'http://192.168.3.4:9302/brest',
// imgUrl: 'https://192.168.3.4:9301/filesystem/',
//正式
- url: 'https://hsg.dctpay.com/brest',
- imgUrl: 'https://hsg.dctpay.com/filesystem/',
- imageWxImg: 'https://hsg.dctpay.com/filesystem/wxApplets/',
- wsssocket:'wss://hsg.dctpay.com/msg/WebSocket/',
+ // url: 'https://hsg.dctpay.com/brest',
+ // imgUrl: 'https://hsg.dctpay.com/filesystem/',
+ // imageWxImg: 'https://hsg.dctpay.com/filesystem/wxApplets/',
+ // wsssocket:'wss://hsg.dctpay.com/msg/WebSocket/',
//测试
- // url: 'https://hsgcs.dctpay.com/brest',
- // imgUrl: 'https://hsgcs.dctpay.com/filesystem/',
- // imageWxImg: 'https://hsgcs.dctpay.com/filesystem/wxApplets/',
- // wsssocket: 'wss://hsgcs.dctpay.com/msg/WebSocket/',
+ url: 'https://hsgcs.dctpay.com/brest',
+ imgUrl: 'https://hsgcs.dctpay.com/filesystem/',
+ imageWxImg: 'https://hsgcs.dctpay.com/filesystem/wxApplets/',
+ wsssocket: 'wss://hsgcs.dctpay.com/msg/WebSocket/',
userInfo: "",
openId: '',
code: '',
token: '',
- //角色权限
- positionType:0
+ //角色油枪权限
+ positionType:0,
+ //角色油品权限
+ positionGunPrice:0
},
onLaunch: function() {
console.log('App Launch')
diff --git a/Utils/Api.js b/Utils/Api.js
index 7466930..95c654c 100644
--- a/Utils/Api.js
+++ b/Utils/Api.js
@@ -10,8 +10,8 @@ export const userLogin = params => {
//退出登录
export const logout = params => {
return POST('POST', `${base}/login/logout`, params).then(res => res.data);
-}
-//查询数据字典
+}
+//查询数据字典
export const getDictionaryByCodeType = params => {
return POST('GET', `${base}/common/getDictionaryByCodeType`, params).then(res => res.data);
}
@@ -42,23 +42,60 @@ export const addGasOilPrice = params => {
//删除油枪
export const delGunNo = params => {
return POST('POST', `${base}/gasOilGunNo/delGunNo`, params).then(res => res.data);
-}
-//修改密码
+}
+//修改密码
export const sendUserPass = params => {
return POST('POST', `${base}/secUser/sendUserPass`, params).then(res => res.data);
-}
-//我的信息
+}
+//我的信息
export const getGasStatistical = params => {
return POST('POST', `${base}/highGas/getGasStatistical`, params).then(res => res.data);
-}
-//订单列表
+}
+//订单列表
export const getGasOrderList = params => {
return POST('GET', `${base}/highGas/getGasOrderList`, params).then(res => res.data);
-}
-//订单详情
+}
+//订单详情
export const getGasOrderDetail = params => {
return POST('GET', `${base}/highGas/getGasOrderDetail`, params).then(res => res.data);
-}
-
-
+}
+//交接班班组功能
+//班组列表
+export const getClassGroupList = params => {
+ return POST('GET', `${base}/gasClassGroup/getClassGroupList`, params).then(res => res.data);
+}
+
+//开启班组任务
+export const startGroupTask = params => {
+ return POST('POST', `${base}/gasClassGroupTask/startGroupTask`, params).then(res => res.data);
+}
+//结束班组
+export const endGroupTask = params => {
+ return POST('POST', `${base}/gasClassGroupTask/endGroupTask`, params).then(res => res.data);
+}
+
+//交接班组
+export const swapGroupTask = params => {
+ return POST('POST', `${base}/gasClassGroupTask/swapGroupTask`, params).then(res => res.data);
+}
+
+//当前班次
+export const getCurrentClassGroupTask = params => {
+ return POST('GET', `${base}/gasClassGroupTask/getCurrentClassGroupTask`, params).then(res => res.data);
+}
+
+//查询历史班次列表
+export const getClassGroupTaskList = params => {
+ return POST('GET', `${base}/gasClassGroupTask/getClassGroupTaskList`, params).then(res => res.data);
+}
+
+//查询历史班次详情
+export const getClassGroupTaskById = params => {
+ return POST('GET', `${base}/gasClassGroupTask/getClassGroupTaskById`, params).then(res => res.data);
+}
+
+//打印小票
+export const print = params => {
+ return POST('GET', `${base}/gasClassGroupTask/print`, params).then(res => res.data);
+}
diff --git a/pages.json b/pages.json
index c2164e2..93e28dc 100644
--- a/pages.json
+++ b/pages.json
@@ -1,16 +1,26 @@
{
"pages": [ //pages数组中第一项表示应用启动页,参考:https://uniapp.dcloud.io/collocation/pages
- {
- "path": "pages/login/login/login",
- "style": {
- "navigationBarTitleText": "登录",
- "navigationBarTextStyle": "white",
- "navigationBarBackgroundColor": "#0083f5",
- "backgroundColorTop": "#0083f5",
- "enablePullDownRefresh": false
- }
-
- },{
+ {
+ "path": "pages/login/login/login",
+ "style": {
+ "navigationBarTitleText": "登录",
+ "navigationBarTextStyle": "white",
+ "navigationBarBackgroundColor": "#0083f5",
+ "backgroundColorTop": "#0083f5",
+ "enablePullDownRefresh": false
+ }
+
+ }, {
+ "path": "pages/user/shift-management/shift-management",
+ "style": {
+ "navigationBarTitleText": "班次管理",
+ "navigationBarTextStyle": "white",
+ "navigationBarBackgroundColor": "#0083f5",
+ "backgroundColorTop": "#0083f5",
+ "enablePullDownRefresh": false
+ }
+
+ }, {
"path": "pages/tabBar/home/home",
"style": {
"navigationBarTextStyle": "white",
@@ -23,7 +33,7 @@
"softinputNavBar": "none"
}
}
- },{
+ }, {
"path": "pages/home/oderDetails/oderDetails",
"style": {
"navigationBarTitleText": "订单详情",
@@ -42,7 +52,7 @@
"enablePullDownRefresh": false
}
- }, {
+ }, {
"path": "pages/tabBar/user/user",
"style": {
"enablePullDownRefresh": true,
@@ -96,6 +106,27 @@
}
}
+
+ , {
+ "path": "pages/user/shift-summary/shift-summary",
+ "style": {
+ "navigationBarTitleText": "班次汇总",
+ "navigationBarTextStyle": "white",
+ "navigationBarBackgroundColor": "#0083f5",
+ "backgroundColorTop": "#0083f5",
+ "enablePullDownRefresh": false
+ }
+
+ }, {
+ "path": "pages/user/select-team/select-team",
+ "style": {
+ "navigationBarTitleText": "",
+ "navigationBarTextStyle": "white",
+ "navigationBarBackgroundColor": "#0083f5",
+ "backgroundColorTop": "#0083f5",
+ "enablePullDownRefresh": false
+ }
+ }
],
"globalStyle": {
"navigationBarTextStyle": "black",
diff --git a/pages/login/login/login.vue b/pages/login/login/login.vue
index cb09589..db771b3 100644
--- a/pages/login/login/login.vue
+++ b/pages/login/login/login.vue
@@ -76,9 +76,6 @@
if (res.return_code == '000000' && res.return_data) {
app.globalData.userInfo = res.return_data
.object;
- if (res.return_data.object.gasStaff) {
- app.globalData.positionType = res.return_data.object.gasStaff.positionType;
- }
app.globalData.token = res.return_data.uniqueCode;
uni.setStorage({
key: "oiluser",
diff --git a/pages/tabBar/home/home.vue b/pages/tabBar/home/home.vue
index 0f2e60d..56707b1 100644
--- a/pages/tabBar/home/home.vue
+++ b/pages/tabBar/home/home.vue
@@ -68,11 +68,13 @@
pagesize: 10,
isLoadMore: false, //是否加载中
innerAudioContext: '', //音频播放
- orderNo: '' //搜索内容
+ orderNo: '', //搜索内容
+ userinfo: '' //用户数据
};
},
onShow() {
let that = this;
+ that.userinfo = app.globalData.userInfo;
that.orderList = [];
that.pageNum = 1;
uni.getStorage({
@@ -89,6 +91,18 @@
},
fail: res => {}
})
+ //油枪,油品 权限
+ if (this.userinfo.buttonList) {
+ for (var i = 0; i < this.userinfo.buttonList.length; i++) {
+ if (this.userinfo.buttonList[i].permissionCode == 'BTN_CONFIG_OIL_GUN_PURVIEW') {
+ app.globalData.positionType = 1
+ }
+ if (this.userinfo.buttonList[i].permissionCode == 'BTN_CONFIG_OIL_GUN_PRICE_PURVIEW') {
+ app.globalData.positionGunPrice = 1
+ }
+ }
+ }
+
},
onLoad() {
@@ -120,9 +134,9 @@
let innerAudioContext = uni.createInnerAudioContext(); //创建音频文件
innerAudioContext.autoplay = false; //不自动播放
innerAudioContext.src = JSON.parse(res.data).voice; //音频文件链接
- that.innerAudioContext = innerAudioContext;
- that.orderList = [];
- that.pageNum = 1;
+ that.innerAudioContext = innerAudioContext;
+ that.orderList = [];
+ that.pageNum = 1;
that.getGasOrderList();
that.startAudio();
console.log('收到服务器内容:' + JSON.parse(res.data).voice);
diff --git a/pages/tabBar/user/user.vue b/pages/tabBar/user/user.vue
index 3f9b68c..1a4fe03 100644
--- a/pages/tabBar/user/user.vue
+++ b/pages/tabBar/user/user.vue
@@ -31,8 +31,8 @@
-
- {{item.title}}
+
+ {{item.menuName}}
@@ -47,26 +47,27 @@
export default {
data() {
return {
- funcList: [{
- title: '配置油枪',
- url: '../../user/oil-list/oil-list?id=1',
- img: '../../../static/img/3.png'
- },
- {
- title: '配置油品价格',
- url: '../../user/oil-list/oil-list?id=2',
- img: '../../../static/img/2.png'
- },
- {
- title: '修改密码',
- url: '../../login/updatePsd/updatePsd',
- img: '../../../static/img/9.png'
- },
- {
- title: '退出登录',
- url: '',
- img: '../../../static/img/7.png'
- }
+ funcList: [
+ // {
+ // title: '配置油枪',
+ // url: '../../user/oil-list/oil-list?id=1',
+ // img: '../../../static/img/3.png'
+ // },
+ // {
+ // title: '配置油品价格',
+ // url: '../../user/oil-list/oil-list?id=2',
+ // img: '../../../static/img/2.png'
+ // },
+ // {
+ // title: '修改密码',
+ // url: '../../login/updatePsd/updatePsd',
+ // img: '../../../static/img/9.png'
+ // },
+ // {
+ // title: '退出登录',
+ // url: '',
+ // img: '../../../static/img/7.png'
+ // }
],
auditnum: '', //统计数据
userinfo: '', //用户信息
@@ -75,7 +76,12 @@
};
},
onLoad() {
- this.userinfo = app.globalData.userInfo;
+ this.userinfo = app.globalData.userInfo;
+ for(var i =0;i {
if (res.return_code == '000000') {
- this.oilInfo = res.return_data;
+ this.oilInfo = res.return_data;
}
});
},
@@ -99,12 +105,12 @@
},
//跳转
jumpdesfun(item) {
- if (item.title == '退出登录') {
+ if (item.menuMobileUrl == '#') {
this.logout();
uni.closeSocket();
}
uni.navigateTo({
- url: item.url
+ url: item.menuMobileUrl
})
},
//退出登录
@@ -124,6 +130,7 @@
app.globalData.userInfo = '';
app.globalData.token = '';
app.globalData.positionType = 0;
+ app.globalData.positionGunPrice = 0;
uni.setStorage({
key: "oiluser",
data: ''
diff --git a/pages/user/oil-list/oil-list.vue b/pages/user/oil-list/oil-list.vue
index d6b2a6c..baa49d3 100644
--- a/pages/user/oil-list/oil-list.vue
+++ b/pages/user/oil-list/oil-list.vue
@@ -7,9 +7,9 @@
{{item.oilNoName}}
+ @click.stop="delOilPrice(item.oilNo)" v-if="positionType == 1">
- 新 增 油 品
+ 新 增 油 品
@@ -28,7 +28,7 @@
positionType: app.globalData.positionType // 角色权限
}
},
- onLoad(Option) {
+ onLoad(Option) {
this.typeid = Option.id;
},
onShow() {
diff --git a/pages/user/select-team/select-team.vue b/pages/user/select-team/select-team.vue
new file mode 100644
index 0000000..50be7a5
--- /dev/null
+++ b/pages/user/select-team/select-team.vue
@@ -0,0 +1,202 @@
+
+
+
+ 班组选择
+
+ {{className}}
+
+
+
+
+
+ 交接班次
+
+
+ 开始班次
+
+
+
+
+
+
+
diff --git a/pages/user/shift-management/shift-management.vue b/pages/user/shift-management/shift-management.vue
new file mode 100644
index 0000000..52d9934
--- /dev/null
+++ b/pages/user/shift-management/shift-management.vue
@@ -0,0 +1,227 @@
+
+
+
+
+ 当前班次
+
+ {{currentClassGroup.classNum}}
+ 无班次
+
+
+
+ 加油总金额
+ {{currentClassGroup.refuelPrice}}元
+
+
+
+
+
+ 加油总笔数
+ {{currentClassGroup.refuelNum}}笔
+
+
+ 加油总升数
+ {{currentClassGroup.refuelLiters}}升
+
+
+
+
+
+ 退款总金额
+ {{currentClassGroup.refundPrice}}元
+
+
+
+ 退款总笔数
+ {{currentClassGroup.refundNum}}笔
+
+
+
+
+
+ 交接班组
+
+
+ 开始班次
+
+
+ 结束班次
+
+
+
+ 历史班次、共计{{listcount}}条数据
+
+
+
+
+
+
+ 班次: {{item.classNum}}班
+ 状态:
+ 进行中
+ 已结束
+
+
+
+
+
+ 班组名称: {{item.gasClassGroupName}}
+
+
+ 开始时间: {{item.startTime | timeFormat('yyyy-mm-dd hh:mm:ss')}}
+
+
+ 结束时间: {{item.endTime | timeFormat('yyyy-mm-dd hh:mm:ss')}}
+
+
+ 结束时间: 未结束
+
+
+
+
+ 班次汇总
+
+
+
+
+
+
+
+
+
+
diff --git a/pages/user/shift-summary/shift-summary.vue b/pages/user/shift-summary/shift-summary.vue
new file mode 100644
index 0000000..a21ad4b
--- /dev/null
+++ b/pages/user/shift-summary/shift-summary.vue
@@ -0,0 +1,128 @@
+
+
+
+ 开始时间:
+ {{classGroupTaskDetails.startTime | timeFormat('yyyy-mm-dd hh:mm:ss')}}
+
+
+ 结束时间:
+ {{classGroupTaskDetails.endTime | timeFormat('yyyy-mm-dd hh:mm:ss')}}
+
+
+ 加油金额汇总:
+ {{classGroupTaskDetails.refuelPrice}} 元
+
+
+ 加油笔数汇总:
+ {{classGroupTaskDetails.refuelNum}} 笔
+
+
+ 加油升数汇总:
+ {{classGroupTaskDetails.refuelLiters}} 升
+
+
+ 退款金额汇总:
+ {{classGroupTaskDetails.refundPrice }} 元
+
+
+ 退款笔数汇总:
+ {{classGroupTaskDetails.refundNum }} 笔
+
+
+
+ 退款升数汇总:
+ {{classGroupTaskDetails.refundLiters}} 升
+
+
+
+ 油号
+ 金额
+ 升数
+ 笔数
+
+
+
+
+
+
+ {{item.oilNo}}#
+ {{item.refuelPrice}}元
+ {{item.refuelLiters}}升
+ {{item.refuelNum}}笔
+
+
+
+ 打印小票
+
+
+
+
+
+
+
diff --git a/pages/user/updateOilgun/updateOilgun.vue b/pages/user/updateOilgun/updateOilgun.vue
index b35a240..beda91a 100644
--- a/pages/user/updateOilgun/updateOilgun.vue
+++ b/pages/user/updateOilgun/updateOilgun.vue
@@ -5,10 +5,10 @@
{{item.gunNo}}号枪
-
+
- 新 增 油 枪
+ 新 增 油 枪
diff --git a/pages/user/updateOilprice/updateOilprice.vue b/pages/user/updateOilprice/updateOilprice.vue
index 3eaec88..db3ba68 100644
--- a/pages/user/updateOilprice/updateOilprice.vue
+++ b/pages/user/updateOilprice/updateOilprice.vue
@@ -15,7 +15,7 @@
- 修 改
+ 修 改
@@ -34,7 +34,7 @@
oilNo: '', //油品
oilDetails: '', //油品详情
userinfo: '' ,//个人信息
- positionType: app.globalData.positionType // 角色权限
+ positionGunPrice: app.globalData.positionGunPrice // 角色权限
}
},
onLoad(options) {
diff --git a/static/img/10.png b/static/img/10.png
new file mode 100644
index 0000000..d5dc7ca
Binary files /dev/null and b/static/img/10.png differ
diff --git a/uni.scss b/uni.scss
index 216fc92..c500f18 100644
--- a/uni.scss
+++ b/uni.scss
@@ -248,7 +248,10 @@ $uni-font-size-paragraph:30upx;
.backcolor32 {
background-color: #32649d;
-}
+}
+.backcolor72{
+ background-color: #eb5823;
+}
//渐变
.backcorlr{
background: linear-gradient(to right, #fe1a1a, #ff722e);
@@ -323,7 +326,10 @@ $uni-font-size-paragraph:30upx;
.width50 {
width: 50%;
}
-
+
+.width46 {
+ width: 46%;
+}
.width40 {
width: 40%;
}