Browse Source

版本 1.7.11 一键服务新增企业填报功能;

release
ZhaoTongYao 4 years ago
parent
commit
bcc0a6d57f
  1. 5
      app.json
  2. 94
      components/selectCascader/selectCascader.js
  3. 6
      components/selectCascader/selectCascader.json
  4. 12
      components/selectCascader/selectCascader.wxml
  5. 84
      components/selectCascader/selectCascader.wxss
  6. BIN
      images/xiala.png
  7. 2
      pages/toRegister/toRegister.js
  8. BIN
      subpages/oneKeyService/images/shangbaojilu.png
  9. 359
      subpages/oneKeyService/pages/companyInformation/companyInformation.js
  10. 8
      subpages/oneKeyService/pages/companyInformation/companyInformation.json
  11. 69
      subpages/oneKeyService/pages/companyInformation/companyInformation.wxml
  12. 134
      subpages/oneKeyService/pages/companyInformation/companyInformation.wxss
  13. 30
      subpages/oneKeyService/pages/companyInformationDetail/companyInformationDetail.js
  14. 4
      subpages/oneKeyService/pages/companyInformationDetail/companyInformationDetail.json
  15. 44
      subpages/oneKeyService/pages/companyInformationDetail/companyInformationDetail.wxml
  16. 40
      subpages/oneKeyService/pages/companyInformationDetail/companyInformationDetail.wxss
  17. 75
      subpages/oneKeyService/pages/companyInformationList/companyInformationList.js
  18. 7
      subpages/oneKeyService/pages/companyInformationList/companyInformationList.json
  19. 16
      subpages/oneKeyService/pages/companyInformationList/companyInformationList.wxml
  20. 79
      subpages/oneKeyService/pages/companyInformationList/companyInformationList.wxss
  21. 4
      subpages/oneKeyService/pages/moduleList/moduleList.js
  22. 2
      subpages/oneKeyService/pages/suggestDict/suggestDict.wxss
  23. 29
      utils/api.js

5
app.json

@ -147,7 +147,10 @@
"pages/suggestDict/suggestDict",
"pages/suggestDictList/suggestDictList",
"pages/suggestDetail/suggestDetail",
"pages/remarkOrReply/remarkOrReply"
"pages/remarkOrReply/remarkOrReply",
"pages/companyInformation/companyInformation",
"pages/companyInformationList/companyInformationList",
"pages/companyInformationDetail/companyInformationDetail"
]
}
],

94
components/selectCascader/selectCascader.js

@ -0,0 +1,94 @@
Component({
properties: {
// 级联选择器数据
cascaderList: {
type: Array,
value: [
{
label: '全部',
value: '1',
children: [
{
label: '云台社区',
value: '333',
children: [],
},
{
label: '云台社区2',
value: '3333',
children: [],
},
],
},
{
label: '安宁街道',
value: '1268515320847425537',
children: [
{
label: '云台社区',
value: '333',
children: [],
},
{
label: '云台社区2',
value: '3333',
children: [],
},
],
},
],
},
choosedValue: {
type: Object,
value: {
title: '安宁街道',
id: '1268515320847425537',
},
},
value: {
type: Array,
value: ['1268515320847425537'],
}, //默认选中的
},
data: {
streetVisible: false,
ifClose: false //
},
// lifetimes: {
// async attached() {},
// },
methods: {
// 显示街道下拉框
showStreet() {
if(!this.data.ifClose){
this.setData({
streetVisible: true,
})
this.triggerEvent('showSelectStreet')
} else {
this.setData({
ifClose: false,
})
}
},
onChange(e) {
// this.setData({
// value: e.detail.value,
// 'choosedValue.title': e.detail.options.map((n) => n.label).join('/'),
// deptId: e.detail.value[e.detail.value.length - 1],
// })
this.triggerEvent('chooseId', e.detail)
},
onClose() {
this.setData({
streetVisible: false,
ifClose: true
})
}
// closeSelect() {
// this.setData({
// streetVisible: false,
// })
// },
},
})

6
components/selectCascader/selectCascader.json

@ -0,0 +1,6 @@
{
"component": true,
"usingComponents": {
"wux-cascader": "../../dist/cascader/index"
}
}

12
components/selectCascader/selectCascader.wxml

@ -0,0 +1,12 @@
<view class="select-item" bindtap="showStreet">
<view class="select-street">
<view class="street-info" id="streetInfo">
<view class="image-and-text">
<!-- <image src="https://epdc-shibei.elinkservice.cn/epdcFile/M00/02/B3/rBAAM16XtbeAaJoJAAAJJL-Rd40945.png"></image> -->
<text class="street-name">{{choosedValue.title}}</text>
</view>
<image class="{{ streetVisible ? '_reverse' : 'reverse'}}" src="../../images/xiala.png"></image>
</view>
<wux-cascader visible="{{ streetVisible }}" controlled value="{{ value }}" title="请选择" options="{{ cascaderList }}" bind:close="onClose" bind:change="onChange" maskClosable="{{false}}"/>
</view>
</view>

84
components/selectCascader/selectCascader.wxss

@ -0,0 +1,84 @@
/* 选择样式 */
.select-item {
box-sizing: border-box;
width: 690rpx;
background: #fff;
display: flex;
flex-direction: row;
justify-content: space-between;
}
/* 街道选择样式 */
.select-item .select-street {
box-sizing: border-box;
padding: 0 25rpx;
background: #f6f8f8;
position: relative;
min-width: 250rpx;
width: 100%;
height: 70rpx;
/* white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis; */
}
.select-item .select-street .street-info {
box-sizing: border-box;
width: 100%;
display: flex;
align-items: center;
display: -webkit-flex;
justify-content: space-between;
flex-direction: row;
flex-wrap: wrap;
margin-top: 19rpx;
}
.select-item .select-street .street-info .image-and-text {
width: 80%;
display: flex;
align-items: center;
}
.select-item .select-street .street-info .image-and-text image:first-child {
width: 28rpx;
height: 32rpx;
}
.select-item .select-street .street-info .image-and-text .street-name {
width: 100%;
display: inline-block;
margin-left: 14rpx;
font-size: 28rpx;
font-weight: 500;
color: rgba(122, 122, 122, 1);
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.select-item .select-street .street-info image:last-child {
margin-left: 11rpx;
width: 22rpx;
height: 16rpx;
}
/* 默认向下 */
.reverse {
transform: rotate(0deg);
transform-origin: center 8rpx;
transition: transform 0.4s;
}
/* 点击向上 */
._reverse {
transform: rotate(180deg);
transform-origin: center 8rpx;
transition: transform 0.4s;
}

BIN
images/xiala.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 600 B

2
pages/toRegister/toRegister.js

@ -21,7 +21,7 @@ Page({
// }
// })
let that = this
const versionNum = "1.7.10"
const versionNum = "1.7.11"
api.getScanSwitch(versionNum).then(function (res) {
console.log(res.data)
let state = res.data ? res.data.scanFlag : '1'

BIN
subpages/oneKeyService/images/shangbaojilu.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.0 KiB

359
subpages/oneKeyService/pages/companyInformation/companyInformation.js

@ -0,0 +1,359 @@
// subpages/heart/pages/myApply/myApply.js
const api = require("../../../../utils/api")
Page({
/**
* 页面的初始数据
*/
data: {
dataForm: {},
violationsCount: 0, //内容审核计数
isConReview: false, //内容审核标志
lock: false, //锁定发布按钮状态,防止连击
treeList: [
// {
// label: '长江路党工委',
// value: '1234085031077498881',
// children: [
// {
// label: '长江路党工委1',
// value: '1234085031077498882',
// },
// {
// label: '长江路党工委2',
// value: '1234085031077498883',
// },
// ],
// },
],
treeChoosedValue: {
title: '请选择',
id: '',
},
treeVlaue: [],
treeId: '',
yearsList: [],
yearChoosedValue: {
label: '请选择年度',
value: '',
},
yearValue: [], //
yearId: '',
yearPickerVisible: false,
quarterList: [],
quarterChoosedValue: {
label: '请选择季度',
value: '',
},
quarterValue: [], //
quarterId: '',
quarterPickerVisible: false,
companyList: [],
companyChoosedValue: {
label: '请选择公司状态',
value: '',
},
companyValue: [], //
companyId: '',
companyPickerVisible: false,
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.getGridTree()
this.getYearsList()
this.getFullDictInfo()
},
getGridTree () {
api.getGridTree().then(res => {
this.setData({
treeList: res.data.options
})
})
},
getYearsList (smallYears = 1970) {
let nowYears = new Date().getFullYear()
let Years = nowYears - smallYears
let arrYear = []
let yearsList = []
for (let i = 0; i <= Years; i++) {
arrYear.push(nowYears--)
}
arrYear.forEach(ele => {
yearsList.push({
value: ele.toString(),
label: ele + '年'
})
})
this.setData({
yearsList
})
},
// 获取字典 -
getFullDictInfo () {
api.getFullDictInfo('enterprise_quarter').then(res => {
if (res.code == 0 && res.msg == 'success') {
let quarterList = []
res.data.forEach(item => {
let ob = {
label: item.dictName,
value: item.dictValue
}
quarterList.push(ob)
})
this.setData({
quarterList
})
}
}).catch(err => {
console.log(err)
})
api.getFullDictInfo('enterprise_status').then(res => {
if (res.code == 0 && res.msg == 'success') {
let companyList = []
res.data.forEach(item => {
let ob = {
label: item.dictName,
value: item.dictValue
}
companyList.push(ob)
})
this.setData({
companyList
})
}
}).catch(err => {
console.log(err)
})
},
// 选择所属网格
chooseTreeId(e) {
this.setData({
treeVlaue: e.detail.value,
'treeChoosedValue.title': e.detail.options
.map((n) => n.label)
.join('/'),
// deptId: e.detail.value[e.detail.value.length - 1],
treeId: e.detail.value[e.detail.value.length - 1],
'dataForm.gridId': e.detail.value[e.detail.value.length - 1]
})
},
// 所属年度 start
onShowYearPicker() {
this.setData({
yearPickerVisible: true,
})
},
onCancelYearPicker() {
this.setData({
yearPickerVisible: false,
})
},
onConfirmYearPicker(e) {
console.log(e.detail)
this.setData({
yearPickerVisible: false,
yearValue: e.detail.value,
'yearChoosedValue.label': e.detail.label,
'yearChoosedValue.value': e.detail.value[0],
yearId: e.detail.value[0],
'dataForm.year': e.detail.value[0]
})
},
// 所属年度 end
// 所属季度 start
onShowQuarterPicker() {
this.setData({
quarterPickerVisible: true,
})
},
onCancelQuarterPicker() {
this.setData({
quarterPickerVisible: false,
})
},
onConfirmQuarterPicker(e) {
console.log(e.detail)
this.setData({
quarterPickerVisible: false,
quarterValue: e.detail.value,
'quarterChoosedValue.label': e.detail.label,
'quarterChoosedValue.value': e.detail.value[0],
quarterId: e.detail.value[0],
'dataForm.quarter': e.detail.value[0]
})
},
// 所属季度 end
// 公司经营状态 start
onShowCompanyPicker() {
this.setData({
companyPickerVisible: true,
})
},
onCancelCompanyPicker() {
this.setData({
companyPickerVisible: false,
})
},
onConfirmCompanyPicker(e) {
console.log(e.detail)
this.setData({
companyPickerVisible: false,
companyValue: e.detail.value,
'companyChoosedValue.label': e.detail.label,
'companyChoosedValue.value': e.detail.value[0],
companyId: e.detail.value[0],
'dataForm.enterpriseStatus': e.detail.value[0]
})
},
// 公司经营状态 end
onInputValue (e) {
let key = e.currentTarget.dataset.code
this.data.dataForm[key] = e.detail.value
this.setData({
dataForm: this.data.dataForm
})
},
//提交申请
submitApply () {
if (this.data.lock) {
return false
}
if (!this.data.dataForm.gridId) {
this.showToast("请选择所属网格")
return false
}
if (!this.data.dataForm.year) {
this.showToast("请选择年度")
return false
}
if (!this.data.dataForm.quarter) {
this.showToast("请选择季度")
return false
}
if (!this.data.dataForm.enterpriseName || !this.data.dataForm.enterpriseName.trim('')) {
this.showToast("请填写公司名称")
return false
}
if (this.data.dataForm.enterpriseName.length > 100) {
this.showToast("公司名称不能超过100个字")
return
}
if (!this.data.dataForm.legalPerson || !this.data.dataForm.legalPerson.trim('')) {
this.showToast("请填写法人或联系人")
return false
}
if (this.data.dataForm.legalPerson.length > 20) {
this.showToast("法人姓名不能超过20个字")
return
}
if (!this.data.dataForm.concat || !this.data.dataForm.concat.trim('')) {
this.showToast("请填写联系电话")
return false
}
if (this.data.dataForm.concat.length > 20) {
this.showToast("请输入正确的联系电话")
return
}
if (!this.data.dataForm.enterpriseStatus) {
this.showToast("请选择公司状态")
return false
}
if (!this.data.dataForm.enterpriseIncome) {
this.data.dataForm.enterpriseIncome = '0'
}
if (!this.data.dataForm.enterprisePeopleNum) {
this.data.dataForm.enterprisePeopleNum = '0'
}
if (!this.data.dataForm.question) {
this.data.dataForm.question = '无'
}
wx.showLoading({
title: "加载中",
})
this.setData({
lock: true
})
const para = { ...this.data.dataForm }
// para.isConReview = this.data.isConReview
console.log('submit apply', para)
let that = this
api.addEnterpriseReport(para).then(res => {
wx.hideLoading()
this.setData({
lock: false
})
if(res.code == 0) {
this.setData({
dialogVisible: !this.data.dialogVisible,
'dataForm.gridId': '',
violationsCount: 0,
isConReview: false
})
} else if (res.code == 533) {
this.data.violationsCount++
console.log(this.data.violationsCount)
if (this.data.violationsCount == 1){
wx.showToast({
title: res.msg,
icon: "none",
duration: 2000
})
} else if (this.data.violationsCount == 2) {
wx.showModal({
title: '提示',
content: '您提交的内容再次被判定为违规,您确定是否要提交?',
success (res) {
if (res.confirm) {
console.log('用户点击确定')
that.data.isConReview = true
that.submitApply()
} else if (res.cancel) {
console.log('用户点击取消')
that.setData({
violationsCount: 0,
isConReview: false
})
}
}
})
}
}
}).catch(err => {
console.log('err',err)
wx.hideLoading()
this.setData({
lock: false
})
})
},
//简化提示
showToast (title) {
wx.showToast({
title: title,
icon: "none",
duration: 2000
})
},
//跳转到我填报的列表
toApplyList () {
wx.navigateTo({
url: "/subpages/oneKeyService/pages/companyInformationList/companyInformationList"
})
},
// 关闭弹框
closeDialog () {
wx.navigateBack()
},
// 弹框确定按钮
confirmDialog () {
wx.navigateBack()
}
})

8
subpages/oneKeyService/pages/companyInformation/companyInformation.json

@ -0,0 +1,8 @@
{
"navigationBarTitleText": "企业信息填报",
"usingComponents": {
"notice": "../../compontents/notice/notice",
"select-cascader": "../../../../components/selectCascader/selectCascader",
"wux-picker": "../../../../dist/picker/index"
}
}

69
subpages/oneKeyService/pages/companyInformation/companyInformation.wxml

@ -0,0 +1,69 @@
<!--subpages/heart/pages/myApply/myApply.wxml-->
<view class="apply">
<view class="apply-list">
<view class="apply-img" bindtap="toApplyList">
<image src="../../images/shangbaojilu.png" />
</view>
<view class="apply-item">
<view class="item-title"><text class="must">*</text>所属网格</view>
<select-cascader cascaderList='{{treeList}}' choosedValue="{{treeChoosedValue}}" value='{{treeVlaue}}' bind:chooseId='chooseTreeId'></select-cascader>
</view>
<view class="apply-item text-item">
<view class="item-title"><text class="must">*</text>所属年度</view>
<view class="item-content" bindtap="onShowYearPicker">
<view class="select">{{yearChoosedValue.label||'请选择年度'}}</view>
<view class="trigger"></view>
</view>
<wux-picker bind:visibleChange="onCancelYearPicker" value="{{yearValue}}" options="{{ yearsList }}" controlled visible="{{yearPickerVisible}}" bind:cancel="onCancelYearPicker" bind:confirm="onConfirmYearPicker"></wux-picker>
</view>
<view class="apply-item">
<view class="item-title"><text class="must">*</text>所属季度</view>
<view class="item-content" bindtap="onShowQuarterPicker">
<view class="select">{{quarterChoosedValue.label||'请选择季度'}}</view>
<view class="trigger"></view>
</view>
<wux-picker bind:visibleChange="onCancelQuarterPicker" value="{{quarterValue}}" options="{{ quarterList }}" controlled visible="{{quarterPickerVisible}}" bind:cancel="onCancelQuarterPicker" bind:confirm="onConfirmQuarterPicker"></wux-picker>
</view>
<view class="apply-item">
<view class="item-title"><text class="must">*</text>公司名称</view>
<input type="text" class="item-content" placeholder="请输入公司名称" value="{{dataForm.enterpriseName}}" data-code="enterpriseName" bindinput="onInputValue"></input>
</view>
<view class="apply-item">
<view class="item-title"><text class="must">*</text>法人或联络人</view>
<input type="text" class="item-content" placeholder="请输入法人或联络人" value="{{dataForm.legalPerson}}" data-code="legalPerson" bindinput="onInputValue"></input>
</view>
<view class="apply-item">
<view class="item-title"><text class="must">*</text>联系电话</view>
<input type="text" class="item-content" placeholder="请输入联系电话" value="{{dataForm.concat}}" data-code="concat" bindinput="onInputValue"></input>
</view>
<view class="apply-item">
<view class="item-title"><text class="must">*</text>公司状态</view>
<view class="item-content" bindtap="onShowCompanyPicker">
<view class="select">{{companyChoosedValue.label||'请选择公司状态'}}</view>
<view class="trigger"></view>
</view>
<wux-picker bind:visibleChange="onCancelCompanyPicker" value="{{companyValue}}" options="{{ companyList }}" controlled visible="{{companyPickerVisible}}" bind:cancel="onCancelCompanyPicker" bind:confirm="onConfirmCompanyPicker"></wux-picker>
</view>
<view class="apply-item">
<view class="item-title">营业收入</view>
<input type="digit" class="item-content" placeholder="请输入营业收入" value="{{dataForm.enterpriseIncome}}" data-code="enterpriseIncome" bindinput="onInputValue"></input>
</view>
<view class="apply-item">
<view class="item-title">用工人数</view>
<input type="number" class="item-content" placeholder="请输入用工人数" value="{{dataForm.enterprisePeopleNum}}" data-code="enterprisePeopleNum" bindinput="onInputValue"></input>
</view>
<view class="apply-item text-item">
<view class="item-title">存在的困难或需要上级协调解决的问题</view>
<textarea class="item-content text-content" placeholder="请输入内容..." maxlength="500" value="{{dataForm.question}}" data-code="question" bindinput="onInputValue"></textarea>
</view>
</view>
<view class="submit" bindtap="submitApply">
<image class="submit-bk" src="../../images/submitbk.png" />
<view class="submit-text">提交</view>
</view>
</view>
<view wx:if="{{showPicker}}">
<date-time-picker bind:cancel="pickerCancel" bind:confirm="pickerConfirm" init-time="{{dataForm.actStartTime}}"></date-time-picker>
</view>
<notice bind:close="closeDialog" bind:confirm="confirmDialog" dialogVisible="{{dialogVisible}}" title="提交成功" confirmText="知道了"></notice>

134
subpages/oneKeyService/pages/companyInformation/companyInformation.wxss

@ -0,0 +1,134 @@
/* subpages/heart/pages/myApply/myApply.wxss */
page {
width: 100%;
overflow-y: auto;
background: #f7f7f7;
}
.apply-list {
position: relative;
overflow: hidden;
}
.apply-list .apply-img {
position: absolute;
right: -10rpx;
top: 16rpx;
}
.apply-list .apply-img image {
width: 176rpx;
height: 76rpx;
}
.apply-list .apply-item {
width: 100%;
background-color: white;
display: flex;
flex-direction: column;
align-items: flex-start;
justify-content: center;
padding: 20rpx 30rpx;
margin-top: 16rpx;
box-sizing: border-box;
}
.apply-list .text-item {
/* height: 220rpx; */
}
.apply-list .apply-item .item-title {
height: 50rpx;
line-height: 50rpx;
font-size: 32rpx;
font-family: PingFang SC;
font-weight: bold;
color: #333333;
margin-bottom: 20rpx;
}
.apply-list .apply-item .item-title .must {
color: #ff0000;
}
.apply-list .apply-item .item-content {
width: 100%;
height: 70rpx;
font-size: 32rpx;
font-family: PingFang SC;
font-weight: 400;
color: #666666;
box-sizing: border-box;
padding: 0 25rpx;
background: #f6f8f8;
display: flex;
align-items: center;
}
.apply-list .apply-item .text-content {
font-weight: 400;
height: 200rpx;
padding-top: 10rpx;
padding-bottom: 10rpx;
border-radius: 0%;
display: flex;
align-items: flex-start;
}
.submit {
width: 592rpx;
height: 116rpx;
position: relative;
margin: 78rpx auto 0rpx;
}
.submit .submit-bk {
width: 100%;
height: 100%;
position: absolute;
z-index: -1;
}
.submit .submit-text {
font-size: 34rpx;
font-family: PingFang SC;
font-weight: 500;
color: #FFFFFF;
height: 100rpx;
line-height: 100rpx;
text-align: center;
}
.time-group {
width: 100%;
display: flex;
justify-content: space-around;
align-items: center;
}
.time-group .select-time {
width: 304rpx;
height: 50rpx;
/* background: #F7F7F7; */
border-radius: 25rpx;
display: flex;
justify-content: center;
align-items: center;
font-size: 24rpx;
font-family: PingFang SC;
font-weight: 500;
color: #333333;
}
.time-group .select-time image {
width: 26rpx;
height: 26rpx;
opacity: 0.76;
margin-right: 20rpx;
}
/* wux-picker start */
.item-content .select {
color: #7A7A7A;
font-size: 30rpx;
width: 100%;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.item-content .trigger {
width: 0;
height: 0;
border: 10rpx solid transparent;
border-top: 12rpx solid #c2c2c2;
position: relative;
top: 6rpx;
}
/* wux-picker end */

30
subpages/oneKeyService/pages/companyInformationDetail/companyInformationDetail.js

@ -0,0 +1,30 @@
const api = require("../../../../utils/api")
Page({
/**
* 页面的初始数据
*/
data: {
enterpriseId: '',
enterpriseDetails: {}
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.setData({
enterpriseId: options.id
})
this.getEnterpriseReportDetail()
},
getEnterpriseReportDetail () {
api.getEnterpriseReportDetail(this.data.enterpriseId).then(res => {
this.setData({
enterpriseDetails: res.data
})
})
},
})

4
subpages/oneKeyService/pages/companyInformationDetail/companyInformationDetail.json

@ -0,0 +1,4 @@
{
"navigationBarTitleText": "详情",
"usingComponents": {}
}

44
subpages/oneKeyService/pages/companyInformationDetail/companyInformationDetail.wxml

@ -0,0 +1,44 @@
<view class="my-apply">
<view class="apply-detail">
<view class="apply-item">
<view class="item-title">所属网格</view>
<view class="item-content">{{enterpriseDetails.grid}}</view>
</view>
<view class="apply-item">
<view class="item-title">所属年度</view>
<view class="item-content">{{enterpriseDetails.year}}</view>
</view>
<view class="apply-item">
<view class="item-title">所属季度</view>
<view class="item-content">{{enterpriseDetails.quarter}}</view>
</view>
<view class="apply-item">
<view class="item-title">公司名称</view>
<view class="item-content">{{enterpriseDetails.enterpriseName}}</view>
</view>
<view class="apply-item">
<view class="item-title">法人或联络人</view>
<view class="item-content">{{enterpriseDetails.legalPerson}}</view>
</view>
<view class="apply-item">
<view class="item-title">联系电话</view>
<view class="item-content">{{enterpriseDetails.concat}}</view>
</view>
<view class="apply-item">
<view class="item-title">公司状态</view>
<view class="item-content">{{enterpriseDetails.enterpriseStatus}}</view>
</view>
<view class="apply-item">
<view class="item-title">营业收入</view>
<view class="item-content">{{enterpriseDetails.enterpriseIncome}}</view>
</view>
<view class="apply-item">
<view class="item-title">用工人数</view>
<view class="item-content">{{enterpriseDetails.enterprisePeopleNum}}</view>
</view>
<view class="apply-item">
<view class="item-title">存在的困难或需要上级协调解决的问题</view>
<view class="item-content">{{enterpriseDetails.question}}</view>
</view>
</view>
</view>

40
subpages/oneKeyService/pages/companyInformationDetail/companyInformationDetail.wxss

@ -0,0 +1,40 @@
page {
width: 100%;
height: auto;
overflow-y: auto;
background: #f7f7f7;
}
.apply-detail {
margin-bottom: 60rpx;
}
.apply-detail .apply-item {
width: 100%;
background-color: white;
display: flex;
flex-direction: column;
align-items: flex-start;
justify-content: center;
padding: 40rpx 30rpx;
margin-top: 16rpx;
box-sizing: border-box;
}
.apply-detail .apply-item .item-title {
font-size: 32rpx;
font-family: PingFang SC;
font-weight: bold;
color: #333333;
}
.apply-detail .apply-item .item-content {
font-size: 32rpx;
font-family: PingFang SC;
font-weight: 500;
color: #666666;
margin-top: 28rpx;
}
.apply-detail .apply-item .line {
width: 100%;
height: 1px;
background: #F2F2F2;
border-radius: 1px;
margin: 28rpx 0rpx;
}

75
subpages/oneKeyService/pages/companyInformationList/companyInformationList.js

@ -0,0 +1,75 @@
const api = require("../../../../utils/api")
Page({
/**
* 页面的初始数据
*/
data: {
pageIndex: 1,
pageSize: 10,
nodata: false,
loadMoreType: 'none',
loadMoreVisible: false,
enterpriselist: [],
quarterList: []
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.getEnterpriseReportList()
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
this.setData({
loadMoreVisible: true
})
if (this.data.loadMoreType === "loading") {
this.setData({
pageIndex: this.data.pageIndex + 1
})
this.getEnterpriseReportList()
}
},
getEnterpriseReportList () {
const para = {
pageIndex: this.data.pageIndex,
pageSize: this.data.pageSize
}
api.getEnterpriseReportList(para).then(res => {
console.log(res)
this.setData({
enterpriselist: [...this.data.enterpriselist,...res.data],
loadMoreType: res.data.length === this.data.pageSize ? 'loading' : 'none',
loadMoreVisible: res.data.length === this.data.pageSize ? false : true
})
if (this.data.enterpriselist.length == 0) {
this.setData({
nodata: true,
loadMoreType: 'none',
loadMoreVisible: false,
})
}
}).catch(err => {
this.setData({
enterpriselist: [],
nodata: true,
loadMoreType: 'none',
loadMoreVisible: false,
})
console.log(err)
})
},
//跳转到信息详情
toApplyDetail (e) {
console.log('跳转详情', e.currentTarget.dataset.id)
wx.navigateTo({
url: `/subpages/oneKeyService/pages/companyInformationDetail/companyInformationDetail?id=${e.currentTarget.dataset.id}`
})
}
})

7
subpages/oneKeyService/pages/companyInformationList/companyInformationList.json

@ -0,0 +1,7 @@
{
"navigationBarTitleText": "填报记录",
"usingComponents": {
"load-more": "/components/loadMore/loadMore",
"no-data": "/components/nodata/nodata"
}
}

16
subpages/oneKeyService/pages/companyInformationList/companyInformationList.wxml

@ -0,0 +1,16 @@
<view class="my-apply">
<view class="apply-list">
<view class="apply-item" data-id="{{item.id}}" bindtap="toApplyDetail" wx:for="{{enterpriselist}}" wx:for-index="index" wx:for-item="item" wx:key="index">
<view class="item-title">{{item.enterpriseName}}</view>
<view class="line"></view>
<view class="item-time">所属年度:{{item.year}}</view>
<view class="item-time">所属季度:{{item.quarter}}</view>
<view class="item-time">提交时间:{{item.createdTime}}</view>
<!-- <view class="item-state">审核状态:<text class="state-{{item.actStatus}}">{{item.actStatus == '0' ? '待审核' : (item.actStatus == '1' ? '通过' : '未通过')}}</text></view> -->
</view>
</view>
</view>
<load-more loadMoreType="{{loadMoreType}}" loadMoreVisible="{{loadMoreVisible}}"></load-more>
<no-data isShow="{{nodata}}"></no-data>

79
subpages/oneKeyService/pages/companyInformationList/companyInformationList.wxss

@ -0,0 +1,79 @@
page {
width: 100%;
height: auto;
overflow-y: auto;
background: #f7f7f7;
}
.apply-list {
}
.apply-list .my-apply-img {
position: absolute;
right: -10rpx;
}
.apply-list .my-apply-img image {
width: 208rpx;
height: 76rpx;
}
.apply-list .apply-item {
width: 100%;
background-color: white;
display: flex;
flex-direction: column;
align-items: flex-start;
justify-content: center;
padding: 30rpx 30rpx;
margin-top: 16rpx;
box-sizing: border-box;
}
.apply-list .text-item {
height: 220rpx;
}
.apply-list .apply-item .item-title {
font-size: 32rpx;
font-family: PingFang SC;
font-weight: bold;
color: #333333;
}
.apply-list .apply-item .item-content {
width: 100%;
height: 44rpx;
line-height: 44rpx;
font-size: 32rpx;
font-family: PingFang SC;
font-weight: 500;
color: #999999;
}
.apply-list .apply-item .text-content {
height: 88rpx;
color: #666666;
}
.apply-list .apply-item .line {
width: 100%;
height: 1px;
background: #F2F2F2;
border-radius: 1px;
margin: 28rpx 0rpx;
}
.apply-list .apply-item .item-time {
font-size: 30rpx;
font-family: PingFang SC;
font-weight: 400;
color: #666666;
}
.apply-list .apply-item .item-state {
margin: 26rpx 0rpx 28rpx;
font-size: 30rpx;
font-family: PingFang SC;
font-weight: 400;
color: #666666;
}
.apply-list .apply-item .item-state .state-0 {
color: #FB9F00;
}
.apply-list .apply-item .item-state .state-1 {
color: #28C896;
}
.apply-list .apply-item .item-state .state-2 {
color: #D80000;
}

4
subpages/oneKeyService/pages/moduleList/moduleList.js

@ -348,6 +348,10 @@ Page({
wx.navigateTo({
url: "/subpages/oneKeyService/pages/suggestDict/suggestDict"
})
} else if (e.currentTarget.dataset.code == 'notice_jztj_qytb') {
wx.navigateTo({
url: "/subpages/oneKeyService/pages/companyInformation/companyInformation"
})
} else {
wx.showToast({
title: '暂未开放',

2
subpages/oneKeyService/pages/suggestDict/suggestDict.wxss

@ -13,7 +13,7 @@ page {
top: 16rpx;
}
.suggest-list .suggest-dict-img image {
width: 164rpx;
width: 176rpx;
height: 76rpx;
}
.suggest-list .issue-item {

29
utils/api.js

@ -73,7 +73,13 @@ module.exports = {
suggestDictList: suggestDictList,
suggestDetail: suggestDetail,
getVolunteerDepts: getVolunteerDepts,
getCharityPoints: getCharityPoints
getCharityPoints: getCharityPoints,
// 企业填报
addEnterpriseReport,
getGridTree,
getFullDictInfo,
getEnterpriseReportList,
getEnterpriseReportDetail,
}
function getToken (wxCode) {
@ -638,3 +644,24 @@ function getVolunteerDepts () {
function getCharityPoints (para) {
return fly.get(`points/charityPoints`, para)
}
// 企业上报
function addEnterpriseReport (para) {
return fly.post("custom/addEnterpriseReport", para)
}
// 获取网格树
function getGridTree () {
return fly.get("admin/getDeptTreeWithTypeKey")
}
// 获取字典值
function getFullDictInfo (dictType) {
return fly.get(`dic/getFullDictInfo/${dictType}`)
}
// 我的填报列表
function getEnterpriseReportList (para) {
return fly.get("custom/getEnterpriseReportList", para)
}
// 企业详情
function getEnterpriseReportDetail (id) {
return fly.get(`custom/getEnterpriseReportDetail/${id}`)
}
Loading…
Cancel
Save