| @@ -39,7 +39,9 @@ | |||
| "pages/contractAssets/fixedAssets", | |||
| "pages/fixedAssets/change/change", | |||
| "pages/paymentManager/paymentManager", | |||
| "pages/paymentManager/toPay/toPay" | |||
| "pages/paymentManager/toPay/toPay", | |||
| "pages/majorEvent/majorEvent", | |||
| "pages/majorEvent/add/add" | |||
| ], | |||
| "window": { | |||
| "backgroundTextStyle": "light", | |||
| @@ -0,0 +1,178 @@ | |||
| Component({ | |||
| properties: { | |||
| width: { | |||
| type: String | |||
| }, | |||
| height: { | |||
| type: String | |||
| }, | |||
| insertPicture: { | |||
| type: Boolean, | |||
| value: true | |||
| }, | |||
| placeholder: { | |||
| type: String, | |||
| value: '输入文字...' | |||
| } | |||
| }, | |||
| data: { | |||
| formats: {}, | |||
| readOnly: false, | |||
| // editorHeight: 300, | |||
| keyboardHeight: 0, | |||
| isIOS: false | |||
| }, | |||
| ready() { | |||
| const platform = wx.getSystemInfoSync().platform | |||
| const isIOS = platform === 'ios' | |||
| this.setData({ | |||
| isIOS | |||
| }) | |||
| const that = this | |||
| this.updatePosition(0) | |||
| let keyboardHeight = 0 | |||
| wx.onKeyboardHeightChange(res => { | |||
| if (res.height === keyboardHeight) return | |||
| const duration = res.height > 0 ? res.duration * 1000 : 0 | |||
| keyboardHeight = res.height | |||
| setTimeout(() => { | |||
| wx.pageScrollTo({ | |||
| scrollTop: 0, | |||
| success() { | |||
| that.updatePosition(keyboardHeight) | |||
| that.editorCtx.scrollIntoView() | |||
| } | |||
| }) | |||
| }, duration) | |||
| }) | |||
| }, | |||
| methods: { | |||
| readOnlyChange() { | |||
| this.setData({ | |||
| readOnly: !this.data.readOnly | |||
| }) | |||
| }, | |||
| updatePosition(keyboardHeight) { | |||
| const toolbarHeight = 100 | |||
| const { | |||
| windowHeight, | |||
| platform | |||
| } = wx.getSystemInfoSync() | |||
| // let editorHeight = keyboardHeight > 0 ? (windowHeight - keyboardHeight - toolbarHeight) : windowHeight | |||
| this.setData({ | |||
| // editorHeight, | |||
| keyboardHeight | |||
| }) | |||
| }, | |||
| calNavigationBarAndStatusBar() { | |||
| const systemInfo = wx.getSystemInfoSync() | |||
| const { | |||
| statusBarHeight, | |||
| platform | |||
| } = systemInfo | |||
| const isIOS = platform === 'ios' | |||
| const navigationBarHeight = isIOS ? 44 : 48 | |||
| return statusBarHeight + navigationBarHeight | |||
| }, | |||
| onEditorReady() { | |||
| const that = this | |||
| //组件使用createSelectorQuery加上in(this) | |||
| wx.createSelectorQuery().in(that).select('#editor').context(function (res) { | |||
| that.editorCtx = res.context | |||
| }).exec() | |||
| }, | |||
| undo() { | |||
| this.editorCtx.undo() | |||
| }, | |||
| redo() { | |||
| this.editorCtx.redo() | |||
| }, | |||
| blur() { | |||
| this.editorCtx.blur() | |||
| }, | |||
| format(e) { | |||
| let { | |||
| name, | |||
| value | |||
| } = e.target.dataset | |||
| if (!name) return | |||
| // console.log('format', name, value) | |||
| if (name === "backgroundColor" && value === "#ff0000") { //设置字体颜色为白色 | |||
| this.editorCtx.format("color", "#ffffff") | |||
| } | |||
| if (name === "backgroundColor" && value === "#ffffff") { | |||
| this.editorCtx.format("color", "#000000") | |||
| } | |||
| if (name === "color") { //清除字体样式 | |||
| this.editorCtx.removeFormat() | |||
| } | |||
| this.editorCtx.format(name, value) | |||
| }, | |||
| onStatusChange(e) { | |||
| const formats = e.detail | |||
| this.setData({ | |||
| formats | |||
| }) | |||
| }, | |||
| insertDivider() { | |||
| this.editorCtx.insertDivider({ | |||
| success: function () { | |||
| console.log('insert divider success') | |||
| } | |||
| }) | |||
| }, | |||
| clear() { | |||
| this.editorCtx.clear({ | |||
| success: function (res) { | |||
| console.log("clear success") | |||
| } | |||
| }) | |||
| }, | |||
| removeFormat() { | |||
| this.editorCtx.removeFormat() | |||
| }, | |||
| insertDate() { | |||
| const date = new Date() | |||
| const formatDate = `${date.getFullYear()}/${date.getMonth() + 1}/${date.getDate()}` | |||
| this.editorCtx.insertText({ | |||
| text: formatDate | |||
| }) | |||
| }, | |||
| insertImage() { | |||
| this.triggerEvent('insertImage'); //触发父组件方法 | |||
| }, | |||
| insertSrc(src) { //接受图片返回地址 | |||
| this.editorCtx.insertImage({ | |||
| src, | |||
| data: { | |||
| id: 'abcd', | |||
| role: 'god' | |||
| }, | |||
| width: '80%', | |||
| fail: (err) => { | |||
| console.log(`图片插入失败:${err}`); | |||
| } | |||
| }) | |||
| }, | |||
| getContent(e) { //获得文本内容 | |||
| this.triggerEvent('Content', { | |||
| content: e.detail | |||
| }) | |||
| }, | |||
| setHtml(html) { //回显 | |||
| if (html) { | |||
| this.createSelectorQuery().select('#editor').context((res) => { | |||
| this.editorCtx = res.context | |||
| this.editorCtx.setContents({ | |||
| html, | |||
| fail: (err) => { | |||
| console.log(`内容回显失败:${err}`); | |||
| } | |||
| }) | |||
| }).exec() | |||
| } | |||
| }, | |||
| } | |||
| }) | |||
| @@ -0,0 +1,3 @@ | |||
| { | |||
| "component": true | |||
| } | |||
| @@ -0,0 +1,50 @@ | |||
| <editor id="editor" class="ql-container" placeholder="{{placeholder}}" bindstatuschange="onStatusChange" bindready="onEditorReady" bindinput="getContent" style="width:{{width}};height:{{height}};" show-img-size show-img-toolbar show-img-resize> | |||
| </editor> | |||
| <view class="toolbar" catchtouchend="format" hidden="{{keyboardHeight > 0 ? false : true}}" style="bottom: {{isIOS ? keyboardHeight : 0}}px"> | |||
| <!-- 官方案例 --> | |||
| <!-- <i class="iconfont icon-charutupian" catchtouchend="insertImage"></i> | |||
| <i class="iconfont icon-format-header-2 {{formats.header === 2 ? 'ql-active' : ''}}" data-name="header" data-value="{{2}}"></i> | |||
| <i class="iconfont icon-format-header-3 {{formats.header === 3 ? 'ql-active' : ''}}" data-name="header" data-value="{{3}}"></i> | |||
| <i class="iconfont icon-zitijiacu {{formats.bold ? 'ql-active' : ''}}" data-name="bold"></i> | |||
| <i class="iconfont icon-zitixieti {{formats.italic ? 'ql-active' : ''}}" data-name="italic"></i> | |||
| <i class="iconfont icon-zitixiahuaxian {{formats.underline ? 'ql-active' : ''}}" data-name="underline"></i> | |||
| <i class="iconfont icon--checklist" data-name="list" data-value="check"></i> | |||
| <i class="iconfont icon-youxupailie {{formats.list === 'ordered' ? 'ql-active' : ''}}" data-name="list" data-value="ordered"></i> | |||
| <i class="iconfont icon-wuxupailie {{formats.list === 'bullet' ? 'ql-active' : ''}}" data-name="list" data-value="bullet"></i> --> | |||
| <i class="iconfont icon-zitijiacu {{formats.bold ? 'ql-active' : ''}}" data-name="bold"></i> | |||
| <i class="iconfont icon-zitixieti {{formats.italic ? 'ql-active' : ''}}" data-name="italic"></i> | |||
| <i class="iconfont icon-zitixiahuaxian {{formats.underline ? 'ql-active' : ''}}" data-name="underline"></i> | |||
| <i class="iconfont icon-zitishanchuxian {{formats.strike ? 'ql-active' : ''}}" data-name="strike"></i> | |||
| <i class="iconfont icon-zuoduiqi {{formats.align === 'left' ? 'ql-active' : ''}}" data-name="align" data-value="left"></i> | |||
| <i class="iconfont icon-juzhongduiqi {{formats.align === 'center' ? 'ql-active' : ''}}" data-name="align" data-value="center"></i> | |||
| <i class="iconfont icon-youduiqi {{formats.align === 'right' ? 'ql-active' : ''}}" data-name="align" data-value="right"></i> | |||
| <i class="iconfont icon-zuoyouduiqi {{formats.align === 'justify' ? 'ql-active' : ''}}" data-name="align" data-value="justify"></i> | |||
| <i class="iconfont icon-line-height {{formats.lineHeight ? 'ql-active' : ''}}" data-name="lineHeight" data-value="2"></i> | |||
| <i class="iconfont icon-Character-Spacing {{formats.letterSpacing ? 'ql-active' : ''}}" data-name="letterSpacing" data-value="2em"></i> | |||
| <i class="iconfont icon-722bianjiqi_duanqianju {{formats.marginTop ? 'ql-active' : ''}}" data-name="marginTop" data-value="20px"></i> | |||
| <i class="iconfont icon-723bianjiqi_duanhouju {{formats.micon-previewarginBottom ? 'ql-active' : ''}}" data-name="marginBottom" data-value="20px"></i> | |||
| <i class="iconfont icon-clearedformat" bindtap="removeFormat"></i> | |||
| <!-- <i class="iconfont icon-font {{formats.fontFamily ? 'ql-active' : ''}}" data-name="fontFamily" data-value="Pacifico"></i> --> | |||
| <i class="iconfont icon-fontsize {{formats.fontSize === '24px' ? 'ql-active' : ''}}" data-name="fontSize" data-value="24px"></i> | |||
| <i class="iconfont icon-text_color {{formats.color === '#ff0000' ? 'ql-active' : ''}}" data-name="color" data-value="{{formats.color === '#ff0000' ? '#000000' : '#ff0000'}}"></i> | |||
| <i class="iconfont icon-fontbgcolor {{formats.backgroundColor === '#ff0000' ? 'ql-active' : ''}}" data-name="backgroundColor" data-value="{{formats.color === '#ff0000' ? '#ffffff' : '#ff0000'}}"></i> | |||
| <i class="iconfont icon-date" bindtap="insertDate"></i> | |||
| <i class="iconfont icon--checklist" data-name="list" data-value="check"></i> | |||
| <i class="iconfont icon-youxupailie {{formats.list === 'ordered' ? 'ql-active' : ''}}" data-name="list" data-value="ordered"></i> | |||
| <i class="iconfont icon-wuxupailie {{formats.list === 'bullet' ? 'ql-active' : ''}}" data-name="list" data-value="bullet"></i> | |||
| <i class="iconfont icon-undo" bindtap="undo"></i> | |||
| <i class="iconfont icon-redo" bindtap="redo"></i> | |||
| <i class="iconfont icon-outdent" data-name="indent" data-value="-1"></i> | |||
| <i class="iconfont icon-indent" data-name="indent" data-value="+1"></i> | |||
| <i class="iconfont icon-fengexian" bindtap="insertDivider"></i> | |||
| <i class="iconfont icon-charutupian" bindtap="insertImage" wx:if="{{insertPicture}}"></i> | |||
| <i class="iconfont icon-format-header-1 {{formats.header === 1 ? 'ql-active' : ''}}" data-name="header" data-value="{{1}}"></i> | |||
| <i class="iconfont icon-format-header-2 {{formats.header === 2 ? 'ql-active' : ''}}" data-name="header" data-value="{{2}}"></i> | |||
| <i class="iconfont icon-format-header-3 {{formats.header === 3 ? 'ql-active' : ''}}" data-name="header" data-value="{{3}}"></i> | |||
| <i class="iconfont icon-zitixiabiao {{formats.script === 'sub' ? 'ql-active' : ''}}" data-name="script" data-value="sub"></i> | |||
| <i class="iconfont icon-zitishangbiao {{formats.script === 'super' ? 'ql-active' : ''}}" data-name="script" data-value="super"></i> | |||
| <!-- <i class="iconfont icon-quanping"></i> --> | |||
| <i class="iconfont icon-shanchu" bindtap="clear"></i> | |||
| <i class="iconfont icon-direction-rtl {{formats.direction === 'rtl' ? 'ql-active' : ''}}" data-name="direction" data-value="rtl"></i> | |||
| </view> | |||
| @@ -0,0 +1,34 @@ | |||
| @import "./assets/iconfont.wxss"; | |||
| .ql-container { | |||
| font-size: 16px; | |||
| line-height: 1.5; | |||
| padding: 10px 10px 20px 10px; | |||
| } | |||
| .ql-active { | |||
| color: #22C704; | |||
| } | |||
| .iconfont { | |||
| display: flex; | |||
| width: 60rpx; | |||
| height: 60rpx; | |||
| align-items: center; | |||
| justify-content: center; | |||
| font-size: 40rpx; | |||
| } | |||
| .toolbar { | |||
| padding: 0 16rpx; | |||
| height: 200rpx; | |||
| width: 100%; | |||
| position: fixed; | |||
| left: 0; | |||
| right: 100%; | |||
| bottom: 0; | |||
| display: flex; | |||
| flex-wrap: wrap; | |||
| align-items: center; | |||
| border-top: 1px solid #ECECEC; | |||
| background-color: white; | |||
| } | |||
| @@ -105,6 +105,10 @@ | |||
| <view class="image"><image class="attribute" src="../../image/index/paymentManager_icon.png" mode="aspectFit"></image></view> | |||
| <text class="desc">支付管理</text> | |||
| </view> | |||
| <view class="flex_block" data-url="/pages/majorEvent/majorEvent" bindtap="navigate" hover-class="btnView"> | |||
| <view class="image"><image class="attribute" src="../../image/index/majorEvent_icon.png" mode="aspectFit"></image></view> | |||
| <text class="desc">重大事项</text> | |||
| </view> | |||
| </block> | |||
| <view class="flex_block" bindtap="openView" hover-class="btnView"> | |||
| <view class="image"><image class="attribute" src="../../image/index/child_function_06.png" mode="aspectFit"></image></view> | |||
| @@ -0,0 +1,228 @@ | |||
| // pages/bankDraft/add/add.js | |||
| import * as UTIL from '../../../utils/util.js'; | |||
| import * as API from '../../../utils/API.js'; | |||
| let EVN_CONFIG = require('../../../env/env'); | |||
| const DISTRIBUTE_ENVIROMENT = 'IMGURL'; | |||
| let { | |||
| URL_PREFIX, | |||
| } = EVN_CONFIG[DISTRIBUTE_ENVIROMENT]; | |||
| const app = getApp(); | |||
| Page({ | |||
| /** | |||
| * 页面的初始数据 | |||
| */ | |||
| data: { | |||
| isIPX: app.globalData.isIPX, | |||
| form:{ | |||
| eventTime: "2020-01-01", //开票日期 必填 | |||
| remark: "", | |||
| }, | |||
| showBtn:true, | |||
| showEventTime:false, | |||
| status:0, | |||
| }, | |||
| /** | |||
| * 生命周期函数--监听页面加载 | |||
| */ | |||
| onLoad(options) { | |||
| let that = this | |||
| if(options.id!=null&&options.id!=""){ | |||
| this.setData({id:options.id}) | |||
| UTIL.httpRequest(API.URL_GET_MAJOREVENTGET + this.data.id, {method:'GET'}, { | |||
| success: (res) => { | |||
| console.log(res); | |||
| if(res.data.auditStatus!='0'&&res.data.auditStatus!='2'){ | |||
| this.setData({'showBtn':false}); | |||
| } | |||
| this.setData({'form':res.data}) | |||
| this.selectComponent('#hf_editor').setHtml(res.data.eventContent); | |||
| } | |||
| }) | |||
| }else{ | |||
| this.onShow() | |||
| } | |||
| }, | |||
| onConfirmEventTime(e){ | |||
| let data = this.getNewDate(new Date(e.detail.value)); | |||
| this.setData({'form.eventTime':data}); | |||
| }, | |||
| getHtml(e) {//从组件获取值 | |||
| this.data.form.eventContent = e.detail.content.html | |||
| }, | |||
| insertImage(){ //图片上传插入示例 | |||
| wx.chooseImage({ | |||
| count: 1, | |||
| success: r => { | |||
| // 本地测试图片插入 | |||
| // this.selectComponent('#hf_editor').insertSrc(res.tempFilePaths[0]); | |||
| wx.uploadFile({ //调用图片上传接口 | |||
| url: URL_PREFIX+'/common/upload', | |||
| filePath: r.tempFilePaths[0], | |||
| name: 'imgFile', | |||
| success: res => { | |||
| console.log(); | |||
| let imgUrl = JSON.parse(res.data).url | |||
| this.selectComponent('#hf_editor').insertSrc(URL_PREFIX+'/common/upload' + imgUrl);//调用组件insertSrc方法 | |||
| } | |||
| }) | |||
| } | |||
| }) | |||
| }, | |||
| getNewDate(date){ | |||
| //date是传过来的时间戳,注意需为13位,10位需*1000 | |||
| //也可以不传,获取的就是当前时间 | |||
| var time | |||
| if(date){ | |||
| time = new Date(date); | |||
| }else{ | |||
| time = new Date(); | |||
| } | |||
| var year= time.getFullYear() //年 | |||
| var month = ("0" + (time.getMonth() + 1)).slice(-2); //月 | |||
| var day = ("0" + time.getDate()).slice(-2); //日 | |||
| var mydate = year + "-" + month + "-" + day; | |||
| return mydate | |||
| }, | |||
| /** | |||
| * 生命周期函数--监听页面初次渲染完成 | |||
| */ | |||
| onReady() { | |||
| }, | |||
| /** | |||
| * 生命周期函数--监听页面显示 | |||
| */ | |||
| onShow() { | |||
| }, | |||
| openBox(even){ | |||
| console.log(even.currentTarget.dataset.name); | |||
| this.setData({ | |||
| [even.currentTarget.dataset.name]:true | |||
| }) | |||
| }, | |||
| onChange(event){ | |||
| console.log(event); | |||
| this.setData({ | |||
| [event.currentTarget.dataset.value]: event.detail, | |||
| }) | |||
| }, | |||
| closeBox(even){ | |||
| console.log(even.currentTarget.dataset.name); | |||
| this.setData({ | |||
| [even.currentTarget.dataset.name]:false | |||
| }) | |||
| }, | |||
| goSubmit(){ | |||
| if(this.data.form.eventName===''||this.data.form.eventName==null){ //事项名称 | |||
| UTIL.showToastNoneIcon('请填写事项名称!'); | |||
| return false; | |||
| }else if(this.data.form.eventTime===''||this.data.form.eventTime==null){ //事项时间 | |||
| UTIL.showToastNoneIcon('事项时间不能为空!'); | |||
| return false; | |||
| }else if(this.data.form.eventContent===''||this.data.form.eventContent==null){ //事项内容 | |||
| UTIL.showToastNoneIcon('事项内容不能为空!'); | |||
| return false; | |||
| }else if(this.data.status=='0'){ | |||
| this.setData({'status':'1'}) | |||
| var that = this; | |||
| that.data.form.method = 'POST'; | |||
| that.data.form.eventContent = that.data.form.eventContent.replace(/\\/g,"/") | |||
| console.log(that.data.form); | |||
| if(that.data.form.id==""||that.data.form.id==null){ | |||
| UTIL.httpRequest(API.URL_POST_MAJOREVENTADD, that.data.form , { | |||
| success: (res) => { | |||
| this.setData({'status':0}) | |||
| if(res.code == 200){ | |||
| UTIL.showToastNoneIcon('新增成功'); | |||
| setTimeout(function(){ | |||
| wx.navigateBack({ | |||
| delta:1 | |||
| }) | |||
| },2000) | |||
| }else{ | |||
| UTIL.showToastNoneIcon('新增失败:'+res.msg); | |||
| } | |||
| } | |||
| }) | |||
| }else{ | |||
| UTIL.httpRequest(API.URL_POST_MAJOREVENTUPDATE, that.data.form , { | |||
| success: (res) => { | |||
| this.setData({'status':0}) | |||
| if(res.code == 200){ | |||
| UTIL.showToastNoneIcon('修改成功'); | |||
| setTimeout(function(){ | |||
| wx.navigateBack({ | |||
| delta:1 | |||
| }) | |||
| },2000) | |||
| }else{ | |||
| UTIL.showToastNoneIcon('修改失败:'+res.msg); | |||
| } | |||
| } | |||
| }) | |||
| } | |||
| } | |||
| }, | |||
| onConfirmTime(event){ | |||
| this.setData({ | |||
| [event.currentTarget.dataset.name]: false, | |||
| [event.currentTarget.dataset.value]: UTIL.formatDate(event.detail), | |||
| }); | |||
| }, | |||
| openBox(even){ | |||
| console.log(even.currentTarget.dataset.name); | |||
| this.setData({ | |||
| [even.currentTarget.dataset.name]:true | |||
| }) | |||
| }, | |||
| closeBox(even){ | |||
| console.log(even.currentTarget.dataset.name); | |||
| this.setData({ | |||
| [even.currentTarget.dataset.name]:false | |||
| }) | |||
| }, | |||
| back:function(){ | |||
| wx.navigateBack({ | |||
| delta: 1 | |||
| }) | |||
| }, | |||
| /** | |||
| * 生命周期函数--监听页面隐藏 | |||
| */ | |||
| onHide() { | |||
| }, | |||
| /** | |||
| * 生命周期函数--监听页面卸载 | |||
| */ | |||
| onUnload() { | |||
| }, | |||
| /** | |||
| * 页面相关事件处理函数--监听用户下拉动作 | |||
| */ | |||
| onPullDownRefresh() { | |||
| }, | |||
| /** | |||
| * 页面上拉触底事件的处理函数 | |||
| */ | |||
| onReachBottom() { | |||
| }, | |||
| /** | |||
| * 用户点击右上角分享 | |||
| */ | |||
| onShareAppMessage() { | |||
| } | |||
| }) | |||
| @@ -0,0 +1,21 @@ | |||
| { | |||
| "navigationStyle": "custom", | |||
| "usingComponents": { | |||
| "van-row": "@vant/weapp/row/index", | |||
| "van-col": "@vant/weapp/col/index", | |||
| "van-cell": "@vant/weapp/cell/index", | |||
| "van-cell-group": "@vant/weapp/cell-group/index", | |||
| "van-tag": "@vant/weapp/tag/index", | |||
| "van-icon": "@vant/weapp/icon/index", | |||
| "van-steps": "@vant/weapp/steps/index", | |||
| "van-button": "@vant/weapp/button/index", | |||
| "van-radio": "@vant/weapp/radio/index", | |||
| "van-radio-group": "@vant/weapp/radio-group/index", | |||
| "van-field": "@vant/weapp/field/index", | |||
| "van-popup": "@vant/weapp/popup/index", | |||
| "van-picker": "@vant/weapp/picker/index", | |||
| "van-calendar": "@vant/weapp/calendar/index", | |||
| "van-datetime-picker": "@vant/weapp/datetime-picker/index", | |||
| "hf_editor": "/component/editor/editor" | |||
| } | |||
| } | |||
| @@ -0,0 +1,24 @@ | |||
| <!--pages/payee/add/add.wxml--> | |||
| <view class="ns" style="height:{{isIPX?'88px':'64px'}};"> | |||
| <image src="/image/apply/back.png" style="top:{{isIPX?'54px':'30px'}};height: 19.0909px;" mode="widthFix" bindtap="back"></image> | |||
| <text style="top:{{isIPX?'54px':'30px'}};">{{form.id?"":"新增"}}重大项目</text> | |||
| </view> | |||
| <view class="main-box table-box table-boxs" style="margin-top:{{isIPX?'100px':'75px'}};"> | |||
| <van-field label="项目名称" value="{{ form.eventName }}" placeholder="项目名称" border="{{ false }}" bind:change="onChange" input-align="right" required data-value="form.eventName"/> | |||
| <view class="section" style="margin-top: -28rpx;"> | |||
| <view class="section__title"><text style="color:red;margin-right: 8rpx;">*</text>发生日期</view> | |||
| <picker mode="date" value="{{form.eventTime}}" bindchange="onConfirmEventTime"> | |||
| <view class="picker"> | |||
| {{form.eventTime?form.eventTime:'发生日期'}} | |||
| </view> | |||
| </picker> | |||
| </view> | |||
| <view style="width:100%;"> | |||
| <hf_editor style="width:100%" height="600rpx" insertPicture="{{true}}" placeholder="编写文章..." bind:Content="getHtml" bind:insertImage="insertImage" id="hf_editor"/> | |||
| </view> | |||
| <van-field label="备注" value="{{ form.remark }}" placeholder="备注" border="{{ false }}" bind:change="onChange" input-align="right" data-value="form.remark"/> | |||
| </view> | |||
| <view class="bottom" wx:if="{{showBtn}}"> | |||
| <view class="btn2" bindtap="goSubmit">保存</view> | |||
| </view> | |||
| @@ -0,0 +1,103 @@ | |||
| /* pages/payee/add/add.wxss */ | |||
| .main-box{ | |||
| background: #ffffff; | |||
| padding: 20px; | |||
| width: 94%; | |||
| margin: 0 auto; | |||
| border-radius: 10px; | |||
| box-shadow: 0px 5px 5px rgba(0, 0, 0, 0.16); | |||
| } | |||
| .table-box van-field van-cell .van-cell{ | |||
| margin-bottom: 15px; | |||
| } | |||
| .table-box van-field:last-child van-cell .van-cell{ | |||
| margin-bottom: 0px; | |||
| } | |||
| .van-cell{ | |||
| padding: 0!important; | |||
| margin-bottom: 15px; | |||
| } | |||
| .van-cell__value { | |||
| display: flex; | |||
| justify-content: flex-end; | |||
| } | |||
| .van-radio--horizontal { | |||
| margin-right: 0!important; | |||
| margin-left: var(--padding-sm,12px) | |||
| } | |||
| .van-cell--required:before { | |||
| left: 0!important; | |||
| } | |||
| .van-field__label { | |||
| padding-left: 10px; | |||
| } | |||
| .bottom{ | |||
| width: 100%; | |||
| margin: 0 auto; | |||
| text-align: center; | |||
| margin-top: 30px; | |||
| margin-bottom: 30px; | |||
| display: flex; | |||
| position: absolute; | |||
| bottom: 10%; | |||
| } | |||
| .bottom view { | |||
| width: 47%; | |||
| margin: 0 auto; | |||
| border-radius: 30px; | |||
| display: inline-block; | |||
| } | |||
| .bottom .btn2{ | |||
| border: 1px solid transparent; | |||
| padding: 8px 0px; | |||
| background-image: linear-gradient(to right, #2C8E68, #5CAE77); | |||
| color: #fff; | |||
| } | |||
| .table-boxs>view{ | |||
| display: flex; | |||
| justify-content: space-between; | |||
| line-height: 100rpx; | |||
| } | |||
| .ql-container { | |||
| box-sizing: border-box; | |||
| width: 100%; | |||
| height: 400px; | |||
| font-size: 16px; | |||
| line-height: 1.5; | |||
| overflow: auto; | |||
| padding: 10px 10px 20px 10px; | |||
| border: 1px solid #ECECEC; | |||
| } | |||
| .ql-active { | |||
| color: #22C704; | |||
| } | |||
| .iconfont { | |||
| display: inline-block; | |||
| width: 30px; | |||
| height: 30px; | |||
| cursor: pointer; | |||
| font-size: 20px; | |||
| } | |||
| .toolbar { | |||
| box-sizing: border-box; | |||
| padding: 0 10px; | |||
| height: 50px; | |||
| width: 100%; | |||
| position: absolute; | |||
| left: 0; | |||
| right: 100%; | |||
| top: 0; | |||
| display: flex; | |||
| align-items: center; | |||
| justify-content: space-between; | |||
| border: 1px solid #ECECEC; | |||
| border-left: none; | |||
| border-right: none; | |||
| } | |||
| @@ -0,0 +1,398 @@ | |||
| // pages/project/project.js | |||
| import * as UTIL from '../../utils/util.js'; | |||
| import * as API from '../../utils/API.js'; | |||
| let EVN_CONFIG = require('../../env/env'); | |||
| const DISTRIBUTE_ENVIROMENT = 'IMGURL'; | |||
| let { | |||
| URL_PREFIX, | |||
| } = EVN_CONFIG[DISTRIBUTE_ENVIROMENT]; | |||
| const app = getApp(); | |||
| Page({ | |||
| /** | |||
| * 页面的初始数据 | |||
| */ | |||
| data: { | |||
| isIPX: app.globalData.isIPX, | |||
| eventName:"", | |||
| value:'', | |||
| pageNums:1, | |||
| showUpload:false, | |||
| uploadOptions:[], | |||
| fileList:[], | |||
| itemId:"", | |||
| itemIndex:"", | |||
| list:[], | |||
| fileEvent:{}, | |||
| showPopupDel:false, | |||
| showPopupSubmit:false, | |||
| }, | |||
| /** | |||
| * 生命周期函数--监听页面加载 | |||
| */ | |||
| onLoad(options) { | |||
| var _this = this; | |||
| let qu = wx.createSelectorQuery() | |||
| qu.select("#top_view").boundingClientRect() | |||
| qu.exec(res => { | |||
| _this.setData({ | |||
| scrollHeight:wx.getSystemInfoSync().windowHeight-res[0].height-res[0].top | |||
| }) | |||
| }) | |||
| //获取附件字典 | |||
| UTIL.httpRequest(API.URL_GET_GETDICTTYPE + 'common_attach', {method:'GET'}, { | |||
| success: (res) => { | |||
| this.setData({ | |||
| uploadOptions:res.data, | |||
| }) | |||
| } | |||
| }) | |||
| }, | |||
| /** | |||
| * 生命周期函数--监听页面初次渲染完成 | |||
| */ | |||
| onReady() { | |||
| this.onShow(); | |||
| }, | |||
| goSearch(e){ | |||
| this.setData({eventName:e.detail}) | |||
| this.onShow(); | |||
| }, | |||
| goAdd(){ | |||
| wx.navigateTo({ | |||
| url: 'add/add', | |||
| }) | |||
| }, | |||
| back:function(){ | |||
| wx.navigateBack({ | |||
| delta: 1 | |||
| }) | |||
| }, | |||
| goUpdate(e){ | |||
| wx.navigateTo({ | |||
| url: 'add/add?id='+ e.currentTarget.dataset.id, | |||
| }) | |||
| }, | |||
| /** | |||
| * 生命周期函数--监听页面显示 | |||
| */ | |||
| onShow() { | |||
| var that = this; | |||
| let params = { | |||
| pageNum : this.data.pageNum, | |||
| pageSize: 10, | |||
| eventName: this.data.eventName, | |||
| method:'GET' | |||
| } | |||
| UTIL.httpRequest(API.URL_GET_MAJOREVENTLIST, params, { | |||
| success: (res) => { | |||
| this.setData({ | |||
| list:res.rows | |||
| }); | |||
| } | |||
| }) | |||
| }, | |||
| submit(e){ | |||
| this.setData({ | |||
| 'itemId':e.currentTarget.dataset.id, | |||
| 'itemIndex':e.currentTarget.dataset.index, | |||
| "showPopupSubmit":true | |||
| }); | |||
| }, | |||
| confirmTemSub(){ | |||
| this.setData({ | |||
| "showPopupSubmit":false | |||
| }); | |||
| UTIL.httpRequest(API.URL_GET_MAJOREVENTSUBMIT + this.data.itemId , {method:'GET'}, { | |||
| success: (res) => { | |||
| if(res.code==200){ | |||
| let new_list = this.data.list | |||
| new_list[this.data.itemIndex].auditStatus = '1' | |||
| this.setData({'list':new_list}) | |||
| UTIL.showToastNoneIcon('提交成功'); | |||
| }else{ | |||
| UTIL.showToastNoneIcon('提交失败!'); | |||
| } | |||
| } | |||
| }) | |||
| }, | |||
| cancelTemSub(){ | |||
| this.setData({ | |||
| "itemId":"", | |||
| "itemIndex":"", | |||
| "showPopupSubmit":false | |||
| }); | |||
| }, | |||
| delete(e){ | |||
| this.setData({ | |||
| 'itemId':e.currentTarget.dataset.id, | |||
| 'itemIndex':e.currentTarget.dataset.index, | |||
| "showPopupDel":true | |||
| }); | |||
| }, | |||
| cancelTemDel:function(e){ | |||
| this.setData({ | |||
| "itemId":"", | |||
| "itemIndex":"", | |||
| "showPopupDel":false | |||
| }); | |||
| }, | |||
| confirmTemDel:function(e){ | |||
| this.setData({ | |||
| "showPopupDel":false | |||
| }); | |||
| UTIL.httpRequest(API.URL_GET_MAJOREVENTDELETE + this.data.itemId , {method:'GET'}, { | |||
| success: (res) => { | |||
| if(res.code==200){ | |||
| let new_list = this.data.list | |||
| new_list.splice(this.data.index,1) | |||
| this.setData({'list':new_list}) | |||
| UTIL.showToastNoneIcon('删除成功!'); | |||
| }else{ | |||
| UTIL.showToastNoneIcon('删除失败!'); | |||
| } | |||
| } | |||
| }) | |||
| }, | |||
| changeTab(e){ | |||
| var that = this ; | |||
| that.setData({value1:e.detail}) | |||
| UTIL.httpRequest(API.URL_GET_GETDICTTYPE + 'order_type', {method:'GET'}, { | |||
| success: (res) => { | |||
| UTIL.httpRequest(API.URL_GET_GETMONEYORDERLIST, {method:'GET',orderType:that.data.value1,orderStatus:that.data.value2},{ | |||
| success: (response) => { | |||
| if (response.code == API.SUCCESS_CODE) { | |||
| for (let i = 0; i < response.rows.length; i++) { | |||
| response.rows[i].orderTypeText = UTIL.getTransform(response.rows[i].orderType,res.data); | |||
| response.rows[i].startTime = response.rows[i].startTime.replace(/-/g,"."); | |||
| response.rows[i].endTime = response.rows[i].endTime.replace(/-/g,"."); | |||
| response.rows[i].orderAmount = parseFloat(response.rows[i].orderAmount).toFixed(2); | |||
| } | |||
| that.setData({ | |||
| moneyorderList:response.rows | |||
| }) | |||
| } | |||
| } | |||
| }) | |||
| } | |||
| }) | |||
| }, | |||
| changeTab2(e){ | |||
| var that = this ; | |||
| that.setData({value2:e.detail}) | |||
| UTIL.httpRequest(API.URL_GET_GETDICTTYPE + 'order_type', {method:'GET'}, { | |||
| success: (res) => { | |||
| UTIL.httpRequest(API.URL_GET_GETMONEYORDERLIST, {method:'GET',orderType:that.data.value1,orderStatus:that.data.value2},{ | |||
| success: (response) => { | |||
| if (response.code == API.SUCCESS_CODE) { | |||
| for (let i = 0; i < response.rows.length; i++) { | |||
| response.rows[i].orderTypeText = UTIL.getTransform(response.rows[i].orderType,res.data); | |||
| response.rows[i].startTime = response.rows[i].startTime.replace(/-/g,"."); | |||
| response.rows[i].endTime = response.rows[i].endTime.replace(/-/g,"."); | |||
| response.rows[i].orderAmount = parseFloat(response.rows[i].orderAmount).toFixed(2); | |||
| } | |||
| that.setData({ | |||
| moneyorderList:response.rows | |||
| }) | |||
| } | |||
| } | |||
| }) | |||
| } | |||
| }) | |||
| }, | |||
| upload(e){ | |||
| this.setData({itemId:e.currentTarget.dataset.id}); | |||
| this.asyncFun(e.currentTarget.dataset.id) | |||
| }, | |||
| asyncFun(id){ | |||
| this.setData({"fileList":[]}) | |||
| let uploadList = this.data.uploadOptions | |||
| let newList = [] | |||
| let _this = this | |||
| uploadList.map( res => { | |||
| let oData = { | |||
| tableId: id, | |||
| tableName: "t_yinnong_majorevent", //上传表 | |||
| bizPath: "yinnong", | |||
| fileType: res.dictValue, //附件类型 1原始发票 2会议纪要 3会议照片 4 参会人员签字 | |||
| method:'GET' | |||
| } | |||
| UTIL.httpRequest(API.URL_GET_ATTACHMENTLIST, oData, { | |||
| success: (rr) => { | |||
| if(rr.code==200&&rr.rows.length>0){ | |||
| rr.rows.map((rrr,index) => { | |||
| rrr.url = URL_PREFIX + rrr.fileUrl | |||
| if(index==rr.rows.length-1){ | |||
| newList.push(Object.assign({},res,{"list":rr.rows})) | |||
| _this.setData({"fileList":_this.data.fileList.concat(newList)}); | |||
| _this.setData({"showUpload":true}) | |||
| } | |||
| }) | |||
| }else{ | |||
| let newuploadList = uploadList | |||
| newuploadList.map(rd => { | |||
| rd.list = newList | |||
| }) | |||
| _this.setData({"fileList":newuploadList}); | |||
| _this.setData({"showUpload":true}) | |||
| } | |||
| }, | |||
| fail:(rr) =>{ | |||
| }, | |||
| complete:(rr) => { | |||
| } | |||
| }) | |||
| }) | |||
| }, | |||
| closeBox(){ | |||
| this.setData({"showUpload":false}) | |||
| }, | |||
| deleteImg(event){ | |||
| this.setData({"fileEvent":event}) | |||
| this.setData({"showPopup":true}); | |||
| }, | |||
| cancelTem:function(e){ | |||
| this.setData({"fileEvent":"{}"}); | |||
| this.setData({"showPopup":false}); | |||
| }, | |||
| confirmTem:function(e){ | |||
| let event = this.data.fileEvent | |||
| UTIL.httpRequest(API.URL_GET_GETFILEREMOVE+event.detail.file.id , {method:'GET'}, { | |||
| success: (res) => { | |||
| if(res.code==200){ | |||
| let ll = this.data.fileList | |||
| var jsonlist = ll[event.target.dataset.idx].list; | |||
| jsonlist.splice(event.detail.index, 1) | |||
| ll[event.target.dataset.idx].list = jsonlist | |||
| this.setData({"fileList":ll}) | |||
| this.setData({showPopup:false}); | |||
| wx.showToast({ | |||
| title: '删除成功!', | |||
| icon: 'success', | |||
| duration: 2000, | |||
| }) | |||
| } | |||
| } | |||
| }) | |||
| }, | |||
| uploadFile(uploadFile,event) { | |||
| let _this = this | |||
| return new Promise((resolve, reject) => { | |||
| wx.uploadFile({ | |||
| url: API.URL_GET_UPLOAD, | |||
| filePath: uploadFile.file.file.url, | |||
| name: 'file', | |||
| header: { | |||
| "Content-Type": "multipart/form-data",//记得设置 | |||
| "chartset":"utf-8", | |||
| 'Authorization':'Bearer '+getApp().globalData.userInfo.token | |||
| }, | |||
| formData:uploadFile, | |||
| success: (res) => { | |||
| res.data = JSON.parse(res.data); | |||
| if(res.statusCode == 200){ | |||
| let files = _this.data.fileList | |||
| let fName = res.data.fileUrl.split('/') | |||
| let fLength = fName.length | |||
| files[event.currentTarget.dataset.idx].list.push({ | |||
| "fileName": fName[fLength-1], | |||
| "fileType": "0", | |||
| "fileUrl":res.data.fileUrl , | |||
| "id": res.data.id, | |||
| "tableId": 6, | |||
| "url":URL_PREFIX+res.data.fileUrl | |||
| }) | |||
| _this.setData({"fileList":files}) | |||
| wx.hideLoading() | |||
| } | |||
| }, | |||
| fail: (err) => { | |||
| //上传失败:修改pedding为reject | |||
| reject(err) | |||
| } | |||
| }); | |||
| }) | |||
| }, | |||
| afterRead(event) { | |||
| let _this = this | |||
| wx.showLoading({ | |||
| title: '上传中...' | |||
| }) | |||
| let fileForm={ | |||
| file: event.detail, | |||
| fileType:event.currentTarget.dataset.idx, | |||
| tableName: "t_yinnong_majorevent", //上传表 | |||
| bizPath: "yinnong", | |||
| tableId:_this.data.itemId | |||
| } | |||
| this.uploadFile(fileForm,event) | |||
| }, | |||
| lookDown(file,detail){ | |||
| // 获取指定字符串最后一次出现的位置,返回index | |||
| var index1 = file.detail.url.lastIndexOf('.'); | |||
| // substr(start, length) 抽取从start下标开始的length个字符,返回新的字符串; | |||
| var style = file.detail.url.substr(index1 + 1) | |||
| //判断图片类型,不需要下载,不做处理 | |||
| if(style=='png'||style=='jpg'||style=='jpeg'||style=='bmp'||style=='gif'||style=='webp'||style=='psd'||style== 'svg'||style=='tiff'){ | |||
| //判断非图片类型 | |||
| }else{ | |||
| wx.downloadFile({ | |||
| url: file.detail.url, | |||
| success(data){ | |||
| wx.openDocument({ | |||
| filePath: data.tempFilePath, | |||
| fileType: style, | |||
| showMenu:true, | |||
| success(res){ | |||
| } | |||
| }) | |||
| } | |||
| }) | |||
| } | |||
| }, | |||
| /** | |||
| * 生命周期函数--监听页面隐藏 | |||
| */ | |||
| onHide() { | |||
| }, | |||
| /** | |||
| * 生命周期函数--监听页面卸载 | |||
| */ | |||
| onUnload() { | |||
| }, | |||
| /** | |||
| * 页面相关事件处理函数--监听用户下拉动作 | |||
| */ | |||
| onPullDownRefresh() { | |||
| }, | |||
| /** | |||
| * 页面上拉触底事件的处理函数 | |||
| */ | |||
| onReachBottom() { | |||
| }, | |||
| /** | |||
| * 用户点击右上角分享 | |||
| */ | |||
| onShareAppMessage() { | |||
| } | |||
| }) | |||
| @@ -0,0 +1,17 @@ | |||
| { | |||
| "usingComponents": { | |||
| "van-checkbox": "@vant/weapp/checkbox/index", | |||
| "van-checkbox-group": "@vant/weapp/checkbox-group/index", | |||
| "van-cell": "@vant/weapp/cell/index", | |||
| "van-cell-group": "@vant/weapp/cell-group/index", | |||
| "van-search": "@vant/weapp/search/index", | |||
| "van-radio": "@vant/weapp/radio/index", | |||
| "van-radio-group": "@vant/weapp/radio-group/index", | |||
| "van-swipe-cell": "@vant/weapp/swipe-cell/index", | |||
| "van-dropdown-menu": "@vant/weapp/dropdown-menu/index", | |||
| "van-dropdown-item": "@vant/weapp/dropdown-item/index", | |||
| "van-tag": "@vant/weapp/tag/index", | |||
| "van-action-sheet": "@vant/weapp/action-sheet/index", | |||
| "van-upload": "@vant/weapp/uploader/index" | |||
| } | |||
| } | |||
| @@ -0,0 +1,91 @@ | |||
| <!--pages/bank/bank.wxml--> | |||
| <view class="ns" style="height:{{isIPX?'88px':'64px'}};"> | |||
| <image src="../../image/apply/back.png" style="top:{{isIPX?'54px':'30px'}};height: 19.0909px;" mode="widthFix" bindtap="back"></image> | |||
| <text style="top:{{isIPX?'54px':'30px'}};">重大事项</text> | |||
| </view> | |||
| <view class="search_box" id="top_view" style="margin-top:{{isIPX?'100px':'75px'}};"> | |||
| <van-search | |||
| value="{{ eventName }}" | |||
| shape="round" | |||
| background="transparent" | |||
| placeholder="请输入事项名称" | |||
| clearable | |||
| bind:change="goSearch" | |||
| /> | |||
| <view class="add_btn" bindtap="goAdd"><text>新增</text></view> | |||
| </view> | |||
| <scroll-view scroll-y refresher-threshold="0" style="height:{{scrollHeight}}px" bindscrolltolower="paging" lower-threshold="100"> | |||
| <van-swipe-cell right-width="{{ 130 }}" class="workflow" wx:for="{{list}}" wx:key="index"> | |||
| <view class="li" bindtap="goUpdate" data-id="{{item.id}}"> | |||
| <view class="tit_box"> | |||
| <view class="tit_box_left"> | |||
| <image src="/image/icon/icon_gc.png" style="width: 17px; height: 15px;"></image> | |||
| <text class="tit">{{item.eventName}}</text> | |||
| </view> | |||
| </view> | |||
| <view class="detail_time_box"> | |||
| <view class="detail_time"> | |||
| <image src="/image/icon/icon_date.png" style="width: 14px;height: 14px;"></image> | |||
| <text>{{item.eventTime}}</text> | |||
| </view> | |||
| <view class="detail_time"> | |||
| <text class="detail_box_money" wx:if="{{item.auditStatus==0}}" style="color:#000">草稿</text> | |||
| <text class="detail_box_money" wx:if="{{item.auditStatus==1}}" style="color:#e6a23c;">待审</text> | |||
| <text class="detail_box_money" wx:if="{{item.auditStatus==2}}" style="color:#f56c6c;">驳回</text> | |||
| <text class="detail_box_money" wx:if="{{item.auditStatus==3}}" style="color:#67c23a;">通过</text> | |||
| </view> | |||
| </view> | |||
| </view> | |||
| <view slot="right" class="deleteBox"> | |||
| <view style="flex: 1;height: 100%;display: flex;align-items: center;flex-direction: column;justify-content: center;background-color: rgb(255,0,0,0.2);" data-id="{{item.id}}" data-index="{{index}}" bindtap="delete" wx:if="{{item.auditStatus==0||item.auditStatus==2}}"> | |||
| <view> | |||
| <image src="../../image/apply/icon_delete.png" style="width: 25px;height: 25px;margin: 0 auto;display: block;" ></image> | |||
| </view> | |||
| <view> | |||
| <text style="color:red">删除</text> | |||
| </view> | |||
| </view> | |||
| <view style="flex: 1;height: 100%;display: flex;align-items: center;flex-direction: column;justify-content: center;background-color: rgb(98,173,102,0.2);" data-id="{{item.id}}" data-index="{{index}}" bindtap="upload"> | |||
| <view> | |||
| <image src="../../image/icon/upload_icon.png" style="width: 25px;height: 25px;margin: 0 auto;display: block;" ></image> | |||
| </view> | |||
| <view> | |||
| <text style="color: #62AD66;">附件</text> | |||
| </view> | |||
| </view> | |||
| <view style="flex: 1;height: 100%;display: flex;align-items: center;flex-direction: column;justify-content: center;background-color: rgb(239,135,7,0.2);" data-id="{{item.id}}" data-index="{{index}}" bindtap="submit" wx:if="{{item.auditStatus==0||item.auditStatus==2}}"> | |||
| <view> | |||
| <image src="../../image/icon/relevance_icon.png" style="width: 25px;height: 25px;margin: 0 auto;display: block;" ></image> | |||
| </view> | |||
| <view> | |||
| <text style="color: rgb(239,135,7);">提交</text> | |||
| </view> | |||
| </view> | |||
| </view> | |||
| </van-swipe-cell> | |||
| </scroll-view> | |||
| <van-action-sheet show="{{showUpload}}" title="附件" bind:close="closeBox"> | |||
| <scroll-view scroll-y="true" style="height: 600rpx;" bindscrolltoupper="upper" bindscrolltolower="lower" bindscroll="scroll" scroll-top="0"> | |||
| <view class="fj-box"> | |||
| <view class="fj-li" wx:for="{{fileList}}" wx:key="index" wx:for-item="item" > | |||
| <view> | |||
| <text>{{item.dictLabel}}</text> | |||
| </view> | |||
| <view class="img_box"> | |||
| <view class="img_li"> | |||
| <van-upload file-list="{{ item.list }}" bind:after-read="afterRead" bind:delete="deleteImg" bind:click-preview="lookDown" data-idx="{{index}}"> | |||
| </van-upload> | |||
| </view> | |||
| </view> | |||
| </view> | |||
| </view> | |||
| </scroll-view> | |||
| </van-action-sheet> | |||
| <modal hidden="{{!showPopup}}" title="是否删除?" confirm-text="是" cancel-text="否" bindcancel="cancelTem" bindconfirm="confirmTem"> | |||
| </modal> | |||
| <modal hidden="{{!showPopupDel}}" title="是否删除?" confirm-text="是" cancel-text="否" bindcancel="cancelTemDel" bindconfirm="confirmTemDel"> | |||
| </modal> | |||
| <modal hidden="{{!showPopupSubmit}}" title="是否提交?" confirm-text="是" cancel-text="否" bindcancel="cancelTemSub" bindconfirm="confirmTemSub"> | |||
| </modal> | |||
| @@ -0,0 +1,347 @@ | |||
| /* pages/bank/bank.wxss */ | |||
| .van-search__content { | |||
| border: 1px solid #5CAE77!important; | |||
| background: #fff!important; | |||
| } | |||
| van-search { | |||
| flex: 0.8; | |||
| } | |||
| .search_box{ | |||
| display: flex; | |||
| } | |||
| .add_btn{ | |||
| flex: 0.2; | |||
| padding: var(--search-padding,10px 12px); | |||
| padding-left: 0; | |||
| } | |||
| .add_btn text{ | |||
| background-color: #62AD66; | |||
| display: block; | |||
| height: 100%; | |||
| text-align: center; | |||
| line-height: 36px; | |||
| color: #fff; | |||
| border-radius: 36px; | |||
| box-shadow: 0px 5px 5px #ddd; | |||
| } | |||
| text{display: block;} | |||
| .work_plan{ | |||
| padding: 40rpx 32.5rpx 30rpx; | |||
| display: flex; | |||
| } | |||
| .work_plan .menu_item{ | |||
| background-color: #fff; | |||
| box-shadow: 2px 5px 5px #ddd; | |||
| border-radius: 60rpx; | |||
| text-align: center; | |||
| position: relative; | |||
| margin-right: 20px; | |||
| padding: 8px 10px; | |||
| } | |||
| .work_plan .menu_item.active{ | |||
| background-color: #2C8E68; | |||
| color: #fff; | |||
| } | |||
| .work_plan .menu_item .remind{ | |||
| height: 30rpx; | |||
| background: #e90101; | |||
| color: #fff; | |||
| font-size: 26rpx; | |||
| position: absolute; | |||
| line-height: 30rpx; | |||
| padding:0 10rpx; | |||
| border-radius: 25px; | |||
| top: -10rpx; | |||
| right: -10rpx; | |||
| } | |||
| .work_plan .more{ | |||
| flex: 1; | |||
| text-align: center; | |||
| line-height: 60rpx; | |||
| font-size: 36rpx; | |||
| color: #31936c; | |||
| } | |||
| .deleteBox{ | |||
| width: 130px; | |||
| text-align: center; | |||
| height: 100%; | |||
| background: #F6F6F6; | |||
| align-items: center; | |||
| display: flex; | |||
| } | |||
| .workflow .workflow_list{ | |||
| height: 150rpx; | |||
| background-color: #fff; | |||
| border-radius: 24rpx; | |||
| box-shadow:0rpx 0rpx 10rpx rgba(0,0,0,.1); | |||
| margin-bottom: 20rpx; | |||
| padding:15rpx 25rpx 10rpx 35rpx; | |||
| } | |||
| .workflow .workflow_list .process_intro{ | |||
| display: flex; | |||
| height: 62rpx; | |||
| align-items: center; | |||
| } | |||
| .workflow .process_intro .name{ | |||
| width: 390rpx; | |||
| font-size: 34rpx; | |||
| margin-right: 30rpx; | |||
| display: flex; | |||
| justify-content: space-between; | |||
| align-items: center; | |||
| } | |||
| .workflow .process_intro .name .name_tit{ | |||
| width: 290rpx; | |||
| overflow: hidden; | |||
| text-overflow: ellipsis; | |||
| white-space: nowrap; | |||
| } | |||
| .van-swipe-cell { | |||
| width: 94%; | |||
| background: #fff; | |||
| border-radius: 10px; | |||
| box-shadow: 2px 5px 5px #ddd; | |||
| margin: 0 auto; | |||
| margin-bottom: 15px; | |||
| } | |||
| .li{ | |||
| width: 100%; | |||
| padding: 14px; | |||
| } | |||
| .tit_box{ | |||
| display: flex; | |||
| justify-content: space-between; | |||
| } | |||
| .tit_box_left{ | |||
| display: flex; | |||
| align-items: center; | |||
| } | |||
| .detail_box{ | |||
| margin-top: 10px; | |||
| display: flex; | |||
| justify-content: space-between; | |||
| } | |||
| .detail_box text{ | |||
| color:#878787; | |||
| } | |||
| .fkmc { | |||
| line-height: 20px; | |||
| font-size: 16px; | |||
| } | |||
| .detail_time .detail_box_money{ | |||
| font-size: 14px; | |||
| } | |||
| .detail_time_box{ | |||
| display: flex; | |||
| justify-content: space-between; | |||
| margin-top: 10px; | |||
| } | |||
| .detail_time{ | |||
| display: flex; | |||
| align-items: center; | |||
| padding-left: 3px; | |||
| } | |||
| .detail_time text{ | |||
| font-size: 12px; | |||
| margin-left: 5px; | |||
| color: #878787; | |||
| } | |||
| .li .detail_box_left text{ | |||
| text-align: center; | |||
| } | |||
| .li .detail_box_left .fkdw{ | |||
| color: #B5B5B5; | |||
| font-size: 14px; | |||
| margin-top: 5px; | |||
| } | |||
| .li .detail_box_center{ | |||
| color: #666666; | |||
| font-size: 12px; | |||
| text-align: center; | |||
| } | |||
| .li .detail_box_right text{ | |||
| text-align: center; | |||
| } | |||
| .li .detail_box_right .skdw{ | |||
| color: #B5B5B5; | |||
| font-size: 14px; | |||
| margin-top: 5px; | |||
| } | |||
| .li .fksr{ | |||
| display: flex; | |||
| align-items: center; | |||
| margin-top: 15px; | |||
| color: #2C8E68; | |||
| font-size: 16px; | |||
| } | |||
| .li .wtj{ | |||
| display: flex; | |||
| align-items: center; | |||
| justify-content: center; | |||
| padding: 3px 8px; | |||
| border-radius: 5px; | |||
| font-size: 14px; | |||
| } | |||
| .no{ | |||
| background-color:#fbe3e3; | |||
| color: #e90000; | |||
| } | |||
| .white{ | |||
| background-color:#feeadc; | |||
| color: #fc9a55; | |||
| } | |||
| .yes{ | |||
| background-color:#ddeee3; | |||
| color: #5cae77; | |||
| } | |||
| .other{ | |||
| background-color:#f0f1f6; | |||
| color: #878787; | |||
| } | |||
| .li .tit{ | |||
| font-size: 16px; | |||
| color: #333333; | |||
| line-height: 25px; | |||
| display: -webkit-box; | |||
| -webkit-box-orient: vertical; | |||
| -webkit-line-clamp: 1; | |||
| word-break: break-all; | |||
| overflow: hidden; | |||
| margin-left: 5px; | |||
| } | |||
| .li .fj_name{ | |||
| font-size: 14px; | |||
| color: #B3DB62; | |||
| line-height: 25px; | |||
| } | |||
| .li .time{ | |||
| font-size: 14px; | |||
| color: #9B9CAA; | |||
| } | |||
| .li .money{ | |||
| font-size: 18px; | |||
| color: #5CAE77; | |||
| } | |||
| .tit_type{ | |||
| display: flex; | |||
| align-items: center; | |||
| } | |||
| .tit_type text{ | |||
| background: rgba(92, 174, 119, 0.2); | |||
| color: #5CAE77; | |||
| padding: 2px 10px; | |||
| } | |||
| .van-checkbox__label { | |||
| display: flex; | |||
| justify-content: space-between; | |||
| width: 100%; | |||
| } | |||
| .van-checkbox__icon-wrap { | |||
| border-radius: 5px; | |||
| } | |||
| .van-checkbox__icon { | |||
| border-radius: 5px; | |||
| border: 2px solid #2C8E68!important; | |||
| background-color: rgba(44, 142, 104, 0.2); | |||
| } | |||
| .bottom{ | |||
| width: 100%; | |||
| margin: 0 auto; | |||
| text-align: center; | |||
| padding: 15px 0; | |||
| display: flex; | |||
| position: fixed; | |||
| bottom: 0%; | |||
| background: #fff; | |||
| box-shadow: 0 0 5px #ddd; | |||
| } | |||
| .bottom view { | |||
| width: 47%; | |||
| margin: 0 auto; | |||
| border-radius: 30px; | |||
| display: inline-block; | |||
| } | |||
| .bottom .btn2{ | |||
| border: 1px solid transparent; | |||
| padding: 10px 0px; | |||
| background-image: linear-gradient(to right, #2C8E68, #5CAE77); | |||
| color: #fff; | |||
| } | |||
| .downView{ | |||
| display: flex; | |||
| justify-content: center; | |||
| align-items: center; | |||
| padding: 0 20px; | |||
| border: 1px solid #5CAE77; | |||
| border-radius: 50px; | |||
| background: #fff; | |||
| margin-left: auto; | |||
| } | |||
| .downView image{ | |||
| width: 10px; | |||
| height: 8px; | |||
| margin-left: 10px; | |||
| } | |||
| .hp_type{ | |||
| padding: 4vw 3%; | |||
| display: flex; | |||
| border-bottom: 1px solid #eee; | |||
| } | |||
| .hp_type view{ | |||
| padding: 2vw 6%; | |||
| background: #EEEEEE; | |||
| border-radius: 60px; | |||
| margin-right: 3%; | |||
| width: 30vw; | |||
| text-align: center; | |||
| } | |||
| .hp_button{ | |||
| display: flex; | |||
| justify-content: space-around; | |||
| padding:4vw 0 6vw; | |||
| } | |||
| .hp_button view{ | |||
| padding: 3vw 6%; | |||
| background: #EEEEEE; | |||
| border-radius: 60px; | |||
| width: 30vw; | |||
| text-align: center; | |||
| } | |||
| .van-dropdown-menu { | |||
| margin-bottom: 15px; | |||
| } | |||
| .fj-box text{ | |||
| background-color: #5CAE77; | |||
| color: #ffffff; | |||
| text-align: center; | |||
| border-radius: 5px; | |||
| white-space:pre-wrap; | |||
| padding: 5rpx 8rpx; | |||
| width: 50rpx; | |||
| margin: 0px 14px; | |||
| font-size: 24rpx; | |||
| } | |||
| .fj-li{ | |||
| margin-top: 20px; | |||
| display: flex; | |||
| /* flex-wrap: wrap; */ | |||
| } | |||
| .fj-li .img_li{ | |||
| width: 100%; | |||
| height: 18.5vw; | |||
| } | |||
| .fj-li .img_add{ | |||
| overflow: hidden; | |||
| } | |||
| .van-icon-description{ | |||
| font-size: 60px; | |||
| } | |||
| @@ -87,7 +87,16 @@ Page({ | |||
| * 生命周期函数--监听页面初次渲染完成 | |||
| */ | |||
| onReady() { | |||
| //获取附件字典 | |||
| UTIL.httpRequest(API.URL_GET_GETDICTTYPE + 'bookkeeping_type', {method:'GET'}, { | |||
| success: (res) => { | |||
| if(res.data.length>0){ | |||
| this.setData({ | |||
| uploadOptions:res.data, | |||
| }) | |||
| } | |||
| } | |||
| }) | |||
| }, | |||
| getList:function(){ | |||
| @@ -101,7 +110,6 @@ Page({ | |||
| } | |||
| UTIL.httpRequest(API.URL_GET_TRANSFERPAYLIST,params,{ | |||
| success: (res) => { | |||
| console.log(res); | |||
| let _this = this | |||
| if(res.code == 200){ | |||
| if(this.data.pageNums!=1&&this.data.list.length<res.total){ | |||
| @@ -223,97 +231,21 @@ Page({ | |||
| } | |||
| }, | |||
| change(e){ | |||
| wx.navigateTo({ | |||
| url: '/pages/fixedAssets/change/change?id='+e.currentTarget.dataset.id, | |||
| }) | |||
| var that = this ; | |||
| that.setData({value:e.detail,pageNum:1}) | |||
| this.getList() | |||
| }, | |||
| changeTab(e){ | |||
| var that = this ; | |||
| that.setData({value1:e.detail}) | |||
| UTIL.httpRequest(API.URL_GET_GETDICTTYPE + 'order_type', {method:'GET'}, { | |||
| success: (res) => { | |||
| UTIL.httpRequest(API.URL_GET_GETMONEYORDERLIST, {method:'GET',orderType:that.data.value1,orderStatus:that.data.value2},{ | |||
| success: (response) => { | |||
| if (response.code == API.SUCCESS_CODE) { | |||
| for (let i = 0; i < response.rows.length; i++) { | |||
| response.rows[i].orderTypeText = UTIL.getTransform(response.rows[i].orderType,res.data); | |||
| response.rows[i].startTime = response.rows[i].startTime.replace(/-/g,"."); | |||
| response.rows[i].endTime = response.rows[i].endTime.replace(/-/g,"."); | |||
| response.rows[i].orderAmount = parseFloat(response.rows[i].orderAmount).toFixed(2); | |||
| } | |||
| that.setData({ | |||
| moneyorderList:response.rows | |||
| }) | |||
| } | |||
| } | |||
| }) | |||
| } | |||
| }) | |||
| that.setData({value1:e.detail,pageNum:1}) | |||
| this.getList() | |||
| }, | |||
| changeTab2(e){ | |||
| var that = this ; | |||
| that.setData({value2:e.detail}) | |||
| UTIL.httpRequest(API.URL_GET_GETDICTTYPE + 'order_type', {method:'GET'}, { | |||
| success: (res) => { | |||
| UTIL.httpRequest(API.URL_GET_GETMONEYORDERLIST, {method:'GET',orderType:that.data.value1,orderStatus:that.data.value2},{ | |||
| success: (response) => { | |||
| if (response.code == API.SUCCESS_CODE) { | |||
| for (let i = 0; i < response.rows.length; i++) { | |||
| response.rows[i].orderTypeText = UTIL.getTransform(response.rows[i].orderType,res.data); | |||
| response.rows[i].startTime = response.rows[i].startTime.replace(/-/g,"."); | |||
| response.rows[i].endTime = response.rows[i].endTime.replace(/-/g,"."); | |||
| response.rows[i].orderAmount = parseFloat(response.rows[i].orderAmount).toFixed(2); | |||
| } | |||
| that.setData({ | |||
| moneyorderList:response.rows | |||
| }) | |||
| } | |||
| } | |||
| }) | |||
| } | |||
| }) | |||
| }, | |||
| delete(e){ | |||
| this.setData({ | |||
| 'itemId':e.currentTarget.dataset.id, | |||
| 'itemIndex':e.currentTarget.dataset.index, | |||
| "showPopupDel":true | |||
| }); | |||
| }, | |||
| cancelTemDel:function(e){ | |||
| this.setData({ | |||
| "itemId":"", | |||
| "itemIndex":"", | |||
| "showPopupDel":false | |||
| }); | |||
| }, | |||
| confirmTemDel:function(e){ | |||
| this.setData({ | |||
| "showPopupDel":false | |||
| }); | |||
| UTIL.httpRequest(API.URL_GET_PERMANENTDELETE + this.data.itemId , {method:'GET'}, { | |||
| success: (res) => { | |||
| if(res.code==200){ | |||
| let new_list = this.data.list | |||
| new_list.splice(this.data.index,1) | |||
| this.setData({'list':new_list}) | |||
| UTIL.showToastNoneIcon('删除成功!'); | |||
| }else{ | |||
| UTIL.showToastNoneIcon('删除失败!'); | |||
| } | |||
| } | |||
| }) | |||
| that.setData({value2:e.detail,pageNum:1}) | |||
| this.getList() | |||
| }, | |||
| upload(e){ | |||
| this.setData({itemId:e.currentTarget.dataset.id}); | |||
| this.asyncFun(e.currentTarget.dataset.id) | |||
| @@ -321,13 +253,14 @@ Page({ | |||
| asyncFun(id){ | |||
| this.setData({"fileList":[]}) | |||
| let uploadList = this.data.uploadOptions | |||
| let newList = [] | |||
| let _this = this | |||
| uploadList.map( res => { | |||
| uploadList.map( (res,idx) => { | |||
| res.list=[] | |||
| console.log(res); | |||
| let oData = { | |||
| tableId: id, | |||
| tableName: "t_asset_permanent", //上传表 | |||
| bizPath: "asset", | |||
| tableName: "t_yinnong_transfer", //上传表 | |||
| bizPath: "transfer", | |||
| fileType: res.dictValue, //附件类型 1原始发票 2会议纪要 3会议照片 4 参会人员签字 | |||
| method:'GET' | |||
| } | |||
| @@ -336,18 +269,17 @@ Page({ | |||
| if(rr.rows.length>0){ | |||
| rr.rows.map((rrr,index) => { | |||
| rrr.url = URL_PREFIX + rrr.fileUrl | |||
| rrr.name = rrr.fileName | |||
| if(index==rr.rows.length-1){ | |||
| newList.push(Object.assign({},res,{"list":rr.rows})) | |||
| _this.setData({"fileList":_this.data.fileList.concat(newList)}); | |||
| res.list = rr.rows | |||
| let lis = uploadList | |||
| lis[idx] = res | |||
| _this.setData({"fileList":lis}); | |||
| _this.setData({"showUpload":true}) | |||
| } | |||
| }) | |||
| }else{ | |||
| let newuploadList = uploadList | |||
| newuploadList.map(rd => { | |||
| rd.list = newList | |||
| }) | |||
| _this.setData({"fileList":newuploadList}); | |||
| } | |||
| else{ | |||
| _this.setData({"showUpload":true}) | |||
| } | |||
| } | |||
| @@ -358,34 +290,6 @@ Page({ | |||
| closeBox(){ | |||
| this.setData({"showUpload":false}) | |||
| }, | |||
| deleteImg(event){ | |||
| this.setData({"fileEvent":event}) | |||
| this.setData({"showPopup":true}); | |||
| }, | |||
| cancelTem:function(e){ | |||
| this.setData({"fileEvent":"{}"}); | |||
| this.setData({"showPopup":false}); | |||
| }, | |||
| confirmTem:function(e){ | |||
| let event = this.data.fileEvent | |||
| UTIL.httpRequest(API.URL_GET_GETFILEREMOVE+event.detail.file.id , {method:'GET'}, { | |||
| success: (res) => { | |||
| if(res.code==200){ | |||
| let ll = this.data.fileList | |||
| var jsonlist = ll[event.target.dataset.idx].list; | |||
| jsonlist.splice(event.detail.index, 1) | |||
| ll[event.target.dataset.idx].list = jsonlist | |||
| this.setData({"fileList":ll}) | |||
| this.setData({showPopup:false}); | |||
| wx.showToast({ | |||
| title: '删除成功!', | |||
| icon: 'success', | |||
| duration: 2000, | |||
| }) | |||
| } | |||
| } | |||
| }) | |||
| }, | |||
| uploadFile(uploadFile,event) { | |||
| let _this = this | |||
| return new Promise((resolve, reject) => { | |||
| @@ -407,6 +311,7 @@ Page({ | |||
| let fLength = fName.length | |||
| files[event.currentTarget.dataset.idx].list.push({ | |||
| "fileName": fName[fLength-1], | |||
| "name":fName[fLength-1], | |||
| "fileType": "0", | |||
| "fileUrl":res.data.fileUrl , | |||
| "id": res.data.id, | |||
| @@ -432,13 +337,14 @@ Page({ | |||
| let fileForm={ | |||
| file: event.detail, | |||
| fileType:event.currentTarget.dataset.idx, | |||
| tableName: "t_asset_permanent", //上传表 | |||
| bizPath: "asset", | |||
| tableName: "t_yinnong_transfer", //上传表 | |||
| bizPath: "transfer", | |||
| tableId:_this.data.itemId | |||
| } | |||
| this.uploadFile(fileForm,event) | |||
| }, | |||
| lookDown(file,detail){ | |||
| lookDown(e){ | |||
| let file =e | |||
| // 获取指定字符串最后一次出现的位置,返回index | |||
| var index1 = file.detail.url.lastIndexOf('.'); | |||
| // substr(start, length) 抽取从start下标开始的length个字符,返回新的字符串; | |||
| @@ -9,8 +9,8 @@ | |||
| <van-dropdown-item value="{{ value3 }}" options="{{ option3 }}" bind:change="changeTab2" /> | |||
| </van-dropdown-menu> | |||
| <scroll-view scroll-y refresher-threshold="0" style="height:{{scrollHeight}}px" bindscrolltolower="paging" lower-threshold="100"> | |||
| <van-swipe-cell right-width="{{ 130 }}" left-width="{{ 90 }}" class="workflow" wx:for="{{list}}" wx:key="index" wx:for-item="item" > | |||
| <view class="li" bindtap="goUpdate" data-id="{{item.id}}"> | |||
| <van-swipe-cell right-width="{{ 50 }}" class="workflow" wx:for="{{list}}" wx:key="index" wx:for-item="item" > | |||
| <view class="li" > | |||
| <view style="width:70%;flex:7;"> | |||
| <view class="tit_box"> | |||
| <image src="/image/icon/paymentManager_icon.png" style="width: 15px;height: 15px;margin-right: 10px;" referrer="no-referrer|origin|unsafe-url"></image> | |||
| @@ -35,44 +35,19 @@ | |||
| </view> | |||
| <view style="width:30%;flex:3;"> | |||
| <view style="text-align: right;"> | |||
| <text style="color:red;line-height: 50px;">¥{{item.expenditureAmount}}</text> | |||
| <view style="color:red;line-height: 50px;font-size: 18px;"> | |||
| <text style="font-size: 10px;display: inline;">¥</text>{{item.expenditureAmount}} | |||
| </view> | |||
| </view> | |||
| <view style="text-align: right;" bindtap="toPay"> | |||
| <view style="text-align: right;" bindtap="toPay" data-id="{{item.id}}"> | |||
| <button wx-if="{{item.paymentState==1}}" type="primary" size="mini" style="border-radius: 15px;" >待支付</button> | |||
| <button wx-if="{{item.paymentState==3}}" type="primary" size="mini" style="border-radius: 15px;">银行受理</button> | |||
| <button wx-if="{{item.paymentState==3}}" type="primary" size="mini" style="border-radius: 15px;background-color: #B3DB62;">银行受理</button> | |||
| <button wx-if="{{item.paymentState==4}}" type="warn" size="mini" style="border-radius: 15px;">支付失败</button> | |||
| <button wx-if="{{item.paymentState==5}}" type="primary" size="mini" style="border-radius: 15px;">部分失败</button> | |||
| <button wx-if="{{item.paymentState==5}}" type="primary" size="mini" style="border-radius: 15px;background-color: #FC9A55;">部分失败</button> | |||
| </view> | |||
| </view> | |||
| </view> | |||
| <view slot="left" class="moreBox" > | |||
| <view style="flex: 1;height: 100%;display: flex;align-items: center;flex-direction: column;justify-content: center;background-color: rgb(165,165,165,0.2);" data-data="{{item}}" data-index="{{index}}" bindtap="scrap"> | |||
| <view> | |||
| <image src="../../image/icon/scrap_icon.png" style="width: 25px;height: 25px;margin: 0 auto;display: block;" ></image> | |||
| </view> | |||
| <view> | |||
| <text style="color:#A5A5A5">报废</text> | |||
| </view> | |||
| </view> | |||
| <view style="flex: 1;height: 100%;display: flex;align-items: center;flex-direction: column;justify-content: center;background-color: rgb(238,95,0,0.2);" data-data="{{item}}" data-index="{{index}}" bindtap="sell"> | |||
| <view> | |||
| <image src="../../image/icon/sell_icon.png" style="width: 25px;height: 25px;margin: 0 auto;display: block;" ></image> | |||
| </view> | |||
| <view> | |||
| <text style="color: rgb(238,95,0);">出售</text> | |||
| </view> | |||
| </view> | |||
| </view> | |||
| </view> | |||
| <view slot="right" class="deleteBox"> | |||
| <view style="flex: 1;height: 100%;display: flex;align-items: center;flex-direction: column;justify-content: center;background-color: rgb(255,0,0,0.2);" data-id="{{item.id}}" data-index="{{index}}" bindtap="delete"> | |||
| <view> | |||
| <image src="../../image/apply/icon_delete.png" style="width: 25px;height: 25px;margin: 0 auto;display: block;" ></image> | |||
| </view> | |||
| <view> | |||
| <text style="color:red">删除</text> | |||
| </view> | |||
| </view> | |||
| <view style="flex: 1;height: 100%;display: flex;align-items: center;flex-direction: column;justify-content: center;background-color: rgb(98,173,102,0.2);" data-id="{{item.id}}" data-index="{{index}}" bindtap="upload"> | |||
| <view> | |||
| <image src="../../image/icon/upload_icon.png" style="width: 25px;height: 25px;margin: 0 auto;display: block;" ></image> | |||
| @@ -81,20 +56,12 @@ | |||
| <text style="color: #62AD66;">附件</text> | |||
| </view> | |||
| </view> | |||
| <view style="flex: 1;height: 100%;display: flex;align-items: center;flex-direction: column;justify-content: center;background-color: rgb(239,135,7,0.2);" data-id="{{item.id}}" data-index="{{index}}" bindtap="change"> | |||
| <view> | |||
| <image src="../../image/icon/relevance_icon.png" style="width: 25px;height: 25px;margin: 0 auto;display: block;" ></image> | |||
| </view> | |||
| <view> | |||
| <text style="color: rgb(239,135,7);">变更</text> | |||
| </view> | |||
| </view> | |||
| </view> | |||
| </van-swipe-cell> | |||
| </scroll-view> | |||
| <van-action-sheet show="{{showUpload}}" title="附件" bind:close="closeBox"> | |||
| <scroll-view scroll-y="true" style="height: 600rpx;" bindscrolltoupper="upper" bindscrolltolower="lower" bindscroll="scroll" scroll-top="0"> | |||
| <scroll-view scroll-y="true" style="height: 600rpx;" scroll-top="0"> | |||
| <view class="fj-box"> | |||
| <view class="fj-li" wx:for="{{fileList}}" wx:key="index" wx:for-item="item" > | |||
| <view> | |||
| @@ -102,7 +69,7 @@ | |||
| </view> | |||
| <view class="img_box"> | |||
| <view class="img_li"> | |||
| <van-upload file-list="{{ item.list }}" bind:after-read="afterRead" bind:delete="deleteImg" bind:click-preview="lookDown" data-idx="{{index}}"> | |||
| <van-upload file-list="{{ item.list }}" deletable="{{false}}" show-upload="{{false}}" bind:click-preview="lookDown"> | |||
| </van-upload> | |||
| </view> | |||
| </view> | |||
| @@ -110,7 +77,3 @@ | |||
| </view> | |||
| </scroll-view> | |||
| </van-action-sheet> | |||
| <modal hidden="{{!showPopup}}" title="是否删除?" confirm-text="是" cancel-text="否" bindcancel="cancelTem" bindconfirm="confirmTem"> | |||
| </modal> | |||
| <modal hidden="{{!showPopupDel}}" title="是否删除?" confirm-text="是" cancel-text="否" bindcancel="cancelTemDel" bindconfirm="confirmTemDel"> | |||
| </modal> | |||
| @@ -64,7 +64,7 @@ text{display: block;} | |||
| color: #31936c; | |||
| } | |||
| .deleteBox{ | |||
| width: 130px; | |||
| width: 50px; | |||
| text-align: center; | |||
| height: 100%; | |||
| background: #F6F6F6; | |||
| @@ -1,42 +1,37 @@ | |||
| <!--pages/payee/add/add.wxml--> | |||
| <view class="ns" style="height:{{isIPX?'88px':'64px'}};"> | |||
| <image src="/image/apply/back.png" style="top:{{isIPX?'54px':'30px'}};height: 19.0909px;" mode="widthFix" bindtap="back"></image> | |||
| <text style="top:{{isIPX?'54px':'30px'}};">{{form.id?"":"新增"}}工程项目</text> | |||
| <image src="/image/apply/back.png" style="top:{{isIPX?'54px':'30px'}};" mode="widthFix" bindtap="back"></image> | |||
| <text style="top:{{isIPX?'54px':'30px'}};">新增工程项目</text> | |||
| </view> | |||
| <view class="main-box table-box table-boxs" style="margin-top:{{isIPX?'100px':'75px'}};"> | |||
| <view class="main-box table-box" style="margin-top:{{isIPX?'100px':'75px'}};"> | |||
| <van-field label="项目名称" value="{{ form.projectName }}" placeholder="项目名称" border="{{ false }}" bind:change="onChange" input-align="right" required data-value="form.projectName"/> | |||
| <van-field label="合同承建方" value="{{ form.projectContractor }}" placeholder="合同承建方" border="{{ false }}" bind:change="onChange" input-align="right" required data-value="form.projectContractor"/> | |||
| <view class="section" style="margin-top: -28rpx;"> | |||
| <view class="section__title"><text style="color:red;margin-right: 8rpx;">*</text>开工日期</view> | |||
| <picker mode="date" value="{{form.startTime}}" bindchange="onConfirmStartTime"> | |||
| <view class="picker"> | |||
| {{form.startTime?form.startTime:'开工日期'}} | |||
| </view> | |||
| </picker> | |||
| </view> | |||
| <view class="section" style="margin-top: -28rpx;"> | |||
| <view class="section__title"><text style="color:red;margin-right: 8rpx;">*</text>竣工日期</view> | |||
| <picker mode="date" value="{{form.endTime}}" bindchange="onConfirmEndTime"> | |||
| <view class="picker"> | |||
| {{form.endTime?form.endTime:'竣工日期'}} | |||
| </view> | |||
| </picker> | |||
| </view> | |||
| <van-field label="合共价款(元)" value="{{ form.projectAmount }}" type="digit" placeholder="合共价款(元)" border="{{ false }}" bind:change="onChange" input-align="right" required data-value="form.projectAmount"/> | |||
| <van-field readonly label="开工日期" value="{{ form.startTime }}" placeholder="开工日期" border="{{ false }}" bind:change="onChange" input-align="right" required is-link arrow-direction ="down" bindtap="openBox" data-name="showStartTime"/> | |||
| <van-calendar show="{{ showStartTime }}" bind:close="closeBox" data-name="showStartTime" bind:confirm="onConfirmTime" data-value="form.startTime" show-confirm="{{ false }}" /> | |||
| <view class="section" style="margin-top: -28rpx;"> | |||
| <view class="section__title"><text style="color:red;margin-right: 8rpx;">*</text>工程状态</view> | |||
| <picker bindchange="onConfirmynProjcetStatus" value="{{ynProjcetStatusindex}}" range="{{ynProjcetStatusOptions}}" range-key="{{'dictLabel'}}"> | |||
| <view class="picker"> | |||
| {{ynProjcetStatusOptions[ynProjcetStatusindex].dictLabel?ynProjcetStatusOptions[ynProjcetStatusindex].dictLabel:"选择所属银行"}} | |||
| <van-icon name="arrow-down" /> | |||
| </view> | |||
| </picker> | |||
| </view> | |||
| <van-field label="备注" value="{{ form.remark }}" placeholder="备注" border="{{ false }}" bind:change="onChange" input-align="right" data-value="form.remark"/> | |||
| <van-field label="竣工日期" value="{{ form.endTime }}" placeholder="竣工日期" border="{{ false }}" bind:change="onChange" input-align="right" required is-link arrow-direction ="down" bindtap="openBox" data-name="showEndTime" /> | |||
| <van-calendar show="{{ showEndTime }}" bind:close="closeBox" data-name="showEndTime" bind:confirm="onConfirmTime" data-value="form.endTime" show-confirm="{{ false }}" /> | |||
| <van-field label="合共价款(元)" value="{{ form.projectAmount }}" placeholder="合共价款(元)" border="{{ false }}" bind:change="onChange" input-align="right" required data-value="form.projectAmount"/> | |||
| <van-popup show="{{showYnProjcetStatus}}" round position="bottom" bind:close="closeBox" data-name="showYnProjcetStatus"> | |||
| <van-picker | |||
| columns="{{ynProjcetStatusOptions}}" | |||
| show-toolbar | |||
| value-key="dictLabel" | |||
| bind:cancel="closeBox" | |||
| bind:confirm="onConfirmYn" | |||
| data-name="showYnProjcetStatus" | |||
| data-value="form.ynProjcetStatus" | |||
| /> | |||
| </van-popup> | |||
| <van-field label="工程状态" value="{{ form.ynProjcetStatusText }}" placeholder="工程状态" border="{{ false }}" bind:change="onChange" input-align="right" required data-value="form.ynProjcetStatus" is-link arrow-direction ="down" bindtap="openBox" data-name="showYnProjcetStatus"/> | |||
| <van-field label="备注" value="{{ form.remark }}" placeholder="备注" border="{{ false }}" bind:change="onChange" input-align="right" data-value="form.remark"/> | |||
| </view> | |||
| <view class="bottom"> | |||
| <view class="btn2" bindtap="goSubmit">保存</view> | |||
| <view class="btn2" bindtap="goSubmit">确认</view> | |||
| </view> | |||
| @@ -1,4 +1,6 @@ | |||
| /* pages/payee/add/add.wxss */ | |||
| @import "../../../style/iconfont.wxss"; | |||
| .main-box{ | |||
| background: #ffffff; | |||
| padding: 20px; | |||
| @@ -357,6 +357,36 @@ const URL_GET_UPDATESCRAP = `${URL_PREFIX}/asset/permanent/updateScrap/`; | |||
| //查询支付管理列表 | |||
| const URL_GET_TRANSFERPAYLIST = `${URL_PREFIX}/yinnong/transfer/payList/`; | |||
| //查询转账详情 | |||
| const URL_GET_TRANSFERINFO= `${URL_PREFIX}/yinnong/transfer/get/`; | |||
| //查询转账列表 | |||
| const URL_GET_TRANSFERINFOS= `${URL_PREFIX}/yinnong/transferDetail/getDetails/`; | |||
| //支付验证码 | |||
| const URL_GET_SENDMSG= `${URL_PREFIX}/yinnong/transfer/sendSms/`; | |||
| //支付 | |||
| const URL_GET_PAY= `${URL_PREFIX}/yinnong/transfer/pay/`; | |||
| //重大事项列表 | |||
| const URL_GET_MAJOREVENTLIST= `${URL_PREFIX}/yinnong/majorevent/list/`; | |||
| //重大事项查询 | |||
| const URL_GET_MAJOREVENTGET= `${URL_PREFIX}/yinnong/majorevent/get/`; | |||
| //重大事项新增 | |||
| const URL_POST_MAJOREVENTADD= `${URL_PREFIX}/yinnong/majorevent/add/`; | |||
| //重大事项修改 | |||
| const URL_POST_MAJOREVENTUPDATE= `${URL_PREFIX}/yinnong/majorevent/edit/`; | |||
| //重大事项删除 | |||
| const URL_GET_MAJOREVENTDELETE= `${URL_PREFIX}/yinnong/majorevent/remove/`; | |||
| //重大事项提交 | |||
| const URL_GET_MAJOREVENTSUBMIT= `${URL_PREFIX}/yinnong/majorevent/customSubmit/`; | |||
| /****************接口地址end****************/ | |||
| @@ -490,5 +520,15 @@ export { | |||
| URL_POST_UPDATERESIDUALSRATE, | |||
| URL_GET_UPDATERSALE, | |||
| URL_GET_UPDATESCRAP, | |||
| URL_GET_TRANSFERPAYLIST | |||
| URL_GET_TRANSFERPAYLIST, | |||
| URL_GET_TRANSFERINFO, | |||
| URL_GET_TRANSFERINFOS, | |||
| URL_GET_SENDMSG, | |||
| URL_GET_PAY, | |||
| URL_GET_MAJOREVENTLIST, | |||
| URL_GET_MAJOREVENTGET, | |||
| URL_POST_MAJOREVENTADD, | |||
| URL_POST_MAJOREVENTUPDATE, | |||
| URL_GET_MAJOREVENTDELETE, | |||
| URL_GET_MAJOREVENTSUBMIT | |||
| } | |||