Commit cd620b8e authored by 胡's avatar

Merge branch 'dev20230131_android' into i-0-s_uat

parents b4c23843 00275cae
......@@ -30,3 +30,4 @@ log.txt
Thumbs.db
UserInterfaceState.xcuserstate
/www/index.html
......@@ -5,11 +5,11 @@ module.exports = {
debug: true,
isMobilePlatform: true,
loginPath: '"http://180.104.121.66:8088/oauth/token?client_id=client2&client_secret=secret&grant_type=password&username=appadmin&password=" ',
basePath: '"http://180.104.121.66:8088/r/api/interface?sysName=XCMG_UAT&apiName="',
basePath: '"http://180.104.121.66:8088/r/api/interface?sysName=XCMG_DEV&apiName="',
rootPath: '"http://180.104.121.66:8088/r/api"',
filePath: '"http://180.104.121.66:8088/r/api/app/fileViewSvc?sysName=XCMG_UAT&apiName=file_view&"',
filePath: '"http://180.104.121.66:8088/r/api/app/fileViewSvc?sysName=XCMG_DEV&apiName=file_view&"',
ocrPath:'"http://180.104.121.66:8088/r/api"',
fileUploadSvcPath:'"http://180.104.121.66:8088/r/api/app/fileUploadSvc?sysName=XCMG_UAT&apiName="',
fileUploadSvcPath:'"http://180.104.121.66:8088/r/api/app/fileUploadSvc?sysName=XCMG_DEV&apiName="',
appId: '"com.xcmg.app.dev"',
currentVersion: '"3.0.6"'
currentVersion: '"3.7.8"'
}
......@@ -7,9 +7,6 @@
"files": {}
},
"installed_plugins": {
"IdCardPlugin": {
"PACKAGE_NAME": "com.xcmg.app"
},
"com.handmobile.cordovaplugin.hotpatch": {
"PACKAGE_NAME": "com.xcmg.app"
},
......@@ -22,6 +19,9 @@
"cordova-plugin-camera": {
"PACKAGE_NAME": "com.xcmg.app"
},
"cordova-plugin-crosswalk-webview": {
"PACKAGE_NAME": "com.xcmg.app"
},
"cordova-plugin-datepicker": {
"PACKAGE_NAME": "com.xcmg.app"
},
......@@ -67,20 +67,15 @@
"cordova-plugin-whitelist": {
"PACKAGE_NAME": "com.xcmg.app"
},
"IdCardPlugin": {
"PACKAGE_NAME": "com.xcmg.app"
},
"ionic-plugin-keyboard": {
"PACKAGE_NAME": "com.xcmg.app"
},
"jpush-phonegap-plugin": {
"APP_KEY": "bef4fd44dcf54b79b8ab27c3",
"PACKAGE_NAME": "com.xcmg.app"
},
"cordova-plugin-crosswalk-webview": {
"XWALK_VERSION": "22+",
"XWALK_LITEVERSION": "xwalk_core_library_canary:17+",
"XWALK_COMMANDLINE": "--disable-pull-to-refresh-effect",
"XWALK_MODE": "embedded",
"XWALK_MULTIPLEAPK": "true",
"PACKAGE_NAME": "com.xcmg.app"
}
},
"dependent_plugins": {
......
......@@ -109,17 +109,6 @@ You can also set user agent with the preference of xwalkUserAgent.
### Release Notes
#### 2.2.0 (November 4, 2016)
* Uses the latest Crosswalk 22 stable version by default
* Keep compatible for Cordova-android 6.0 with evaluating Javascript bridge
#### 2.1.0 (September 9, 2016)
* Uses the latest Crosswalk 21 stable version by default
#### 2.0.0 (August 17, 2016)
* Uses the latest Crosswalk 20 stable version by default
* Discontinue support for Android 4.0 (ICS) in Crosswalk starting with version 20
#### 1.8.0 (June 30, 2016)
* Uses the latest Crosswalk 19 stable version by default
......
......@@ -25,8 +25,6 @@ module.exports = function(context) {
'platforms', 'android'),
projectConfigurationFile = path.join(context.opts.projectRoot,
'config.xml'),
platformConfigurationFile = path.join(androidPlatformDir,
'res', 'xml', 'config.xml'),
projectManifestFile = path.join(androidPlatformDir,
'AndroidManifest.xml'),
xwalk64bit = "xwalk64bit",
......@@ -34,7 +32,7 @@ module.exports = function(context) {
specificVersion = false;
/** Init */
var CordovaConfig = new ConfigParser(platformConfigurationFile);
var CordovaConfig = new ConfigParser(projectConfigurationFile);
var addPermission = function() {
var projectManifestXmlRoot = XmlHelpers.parseElementtreeSync(projectManifestFile);
......@@ -113,27 +111,29 @@ module.exports = function(context) {
/** Add preference */
this.addPreferences = function() {
// Pick the xwalk variables with the cli preferences
// parseCliPreference();
parseCliPreference();
// Add the permission of writing external storage when using shared mode
if (CordovaConfig.getGlobalPreference('xwalkMode') == 'shared') {
if (xwalkVariables['xwalkMode'] == 'shared') {
addPermission();
} else if (xwalkVariables['xwalkMode'] == 'lite' && specificVersion == false) {
xwalkVariables['xwalkVersion'] = xwalkLiteVersion;
}
// Configure the final value in the config.xml
// var configXmlRoot = XmlHelpers.parseElementtreeSync(projectConfigurationFile);
// var preferenceUpdated = false;
// for (var name in xwalkVariables) {
// var child = configXmlRoot.find('./preference[@name="' + name + '"]');
// if(!child) {
// preferenceUpdated = true;
// child = et.XML('<preference name="' + name + '" value="' + xwalkVariables[name] + '" />');
// XmlHelpers.graftXML(configXmlRoot, [child], '/*');
// }
// }
// if(preferenceUpdated) {
// fs.writeFileSync(projectConfigurationFile, configXmlRoot.write({indent: 4}), 'utf-8');
// }
var configXmlRoot = XmlHelpers.parseElementtreeSync(projectConfigurationFile);
var preferenceUpdated = false;
for (var name in xwalkVariables) {
var child = configXmlRoot.find('./preference[@name="' + name + '"]');
if(!child) {
preferenceUpdated = true;
child = et.XML('<preference name="' + name + '" value="' + xwalkVariables[name] + '" />');
XmlHelpers.graftXML(configXmlRoot, [child], '/*');
}
}
if(preferenceUpdated) {
fs.writeFileSync(projectConfigurationFile, configXmlRoot.write({indent: 4}), 'utf-8');
}
}
/** Remove preference*/
......@@ -143,14 +143,14 @@ module.exports = function(context) {
removePermission();
}
// var configXmlRoot = XmlHelpers.parseElementtreeSync(projectConfigurationFile);
// for (var name in xwalkVariables) {
// var child = configXmlRoot.find('./preference[@name="' + name + '"]');
// if (child) {
// XmlHelpers.pruneXML(configXmlRoot, [child], '/*');
// }
// }
// fs.writeFileSync(projectConfigurationFile, configXmlRoot.write({indent: 4}), 'utf-8');
var configXmlRoot = XmlHelpers.parseElementtreeSync(projectConfigurationFile);
for (var name in xwalkVariables) {
var child = configXmlRoot.find('./preference[@name="' + name + '"]');
if (child) {
XmlHelpers.pruneXML(configXmlRoot, [child], '/*');
}
}
fs.writeFileSync(projectConfigurationFile, configXmlRoot.write({indent: 4}), 'utf-8');
}
var build64bit = function() {
......@@ -189,11 +189,6 @@ module.exports = function(context) {
fs.writeFileSync(projectConfigurationFile, configXmlRoot.write({indent: 4}), 'utf-8');
}
}
console.log("Crosswalk info:");
console.log(" After much discussion and analysis of the market,");
console.log(" we have decided to discontinue support for Android 4.0 (ICS) in Crosswalk starting with version 20,");
console.log(" so the minSdkVersion of Cordova project is configured to 16 by default. \n");
}
xwalkVariables = defaultPreferences();
......
{
"name": "cordova-plugin-crosswalk-webview",
"version": "2.2.0",
"version": "1.8.0",
"description": "Changes the default WebView to CrossWalk",
"cordova": {
"id": "cordova-plugin-crosswalk-webview",
......@@ -21,25 +21,16 @@
"ecosystem:cordova",
"cordova-android"
],
"engines": {
"cordovaDependencies": {
"2.0.0": {
"cordova": ">=5.2.0",
"cordova-android": "4 - 5"
},
"2.1.0": {
"cordova": ">=5.2.0",
"cordova-android": "4 - 5"
},
"2.2.0": {
"cordova": ">=5.2.0",
"cordova-android": ">=6"
},
"3.0.0": {
"cordova": ">100"
}
"engines": [
{
"name": "cordova-android",
"version": ">=4"
},
{
"name": "cordova-plugman",
"version": ">=4.2.0"
}
},
],
"author": "",
"license": "Apache 2.0",
"bugs": {
......
......@@ -3,7 +3,7 @@
<plugin xmlns="http://apache.org/cordova/ns/plugins/1.0"
xmlns:android="http://schemas.android.com/apk/res/android"
id="cordova-plugin-crosswalk-webview"
version="2.2.0">
version="1.8.0">
<name>Crosswalk WebView Engine</name>
<description>Changes the default WebView to CrossWalk</description>
......@@ -13,25 +13,19 @@
<issue>https://crosswalk-project.org/jira</issue>
<engines>
<engine name="cordova-android" version=">=6"/>
<engine name="cordova-plugman" version=">=5.2.0"/><!-- needed for gradleReference support -->
<engine name="cordova-android" version=">=4"/>
<engine name="cordova-plugman" version=">=4.2.0"/><!-- needed for gradleReference support -->
</engines>
<!-- android -->
<platform name="android">
<preference name="XWALK_VERSION" default="22+"/>
<preference name="XWALK_LITEVERSION" default="xwalk_core_library_canary:17+"/>
<preference name="XWALK_COMMANDLINE" default="--disable-pull-to-refresh-effect"/>
<preference name="XWALK_MODE" default="embedded" />
<preference name="XWALK_MULTIPLEAPK" default="true" />
<config-file target="res/xml/config.xml" parent="/*">
<preference name="webView" value="org.crosswalk.engine.XWalkWebViewEngine"/>
<preference name="xwalkVersion" value="$XWALK_VERSION"/>
<preference name="xwalkLiteVersion" value="$XWALK_LITEVERSION"/>
<preference name="xwalkCommandLine" value="$XWALK_COMMANDLINE"/>
<preference name="xwalkMode" value="$XWALK_MODE" />
<preference name="xwalkMultipleApk" value="$XWALK_MULTIPLEAPK" />
<preference name="android-minSdkVersion" value="16" />
<preference name="xwalkVersion" default="19+"/>
<preference name="xwalkLiteVersion" default="xwalk_core_library_canary:17+"/>
<preference name="xwalkCommandLine" default="--disable-pull-to-refresh-effect"/>
<preference name="xwalkMode" default="embedded" />
<preference name="xwalkMultipleApk" default="true" />
</config-file>
<config-file target="AndroidManifest.xml" parent="/*">
......@@ -55,10 +49,4 @@
<hook type="after_build" src="hooks/after_build/000-build_64_bit.js"/>
<hook type="before_build" src="hooks/before_build/000-build_64_bit.js"/>
</platform>
<info>
After much discussion and analysis of the market, we have decided to discontinue support for Android 4.0 (ICS) in Crosswalk starting with version 20.
So the minSdkVersion of Cordova project is configured to 16 by default.
</info>
</plugin>
......@@ -176,14 +176,6 @@
"PHOTOLIBRARY_USAGE_DESCRIPTION": " "
}
},
"cordova-plugin-crosswalk-webview": {
"source": {
"type": "registry",
"id": "cordova-plugin-crosswalk-webview@2.2.0"
},
"is_top_level": true,
"variables": {}
},
"cordova-plugin-file": {
"source": {
"type": "registry",
......@@ -223,5 +215,13 @@
},
"is_top_level": true,
"variables": {}
},
"cordova-plugin-crosswalk-webview": {
"source": {
"type": "registry",
"id": "cordova-plugin-crosswalk-webview@1.8.0"
},
"is_top_level": true,
"variables": {}
}
}
\ No newline at end of file
<template>
<!-- <div class="tab-style">
<!-- <div class="tab-style">
<span @click="tabNum1 = 0;sendTabNum()"><img :src="tabNum == 0?check1:uncheck1"></span>
<span @click="tabNum1 = 1;sendTabNum()"><img :src="tabNum == 1?check2:uncheck2" ></span>
<span @click="tabNum1 = 2;sendTabNum()"><img :src="tabNum == 2?check3:uncheck3"></span>
......
......@@ -66,6 +66,9 @@ import Jmessage from './scripts/jmessageService'
if (process.env.CONFIG_ENV === 'uat') {
const VConsole = require('vconsole')
new VConsole() // eslint-disable-line
}else if(process.env.CONFIG_ENV === 'dev'){
const VConsole = require('vconsole')
new VConsole() // eslint-disable-line
}
Vue.use(componentInstall)
Vue.use(components)
......
......@@ -12,7 +12,7 @@
<img src="@/assets/contractCreate/hint.png" >提示: 仅签署列表中状态为“未签署”的合同
</div>
<div class="scroll-box">
<div v-for="item of list" :key="item.project_id" class="box">
<div v-for="item of list" :key="item.confirm_id" class="box">
<!-- 颜色 d6204b -->
<div class="name">
<!-- <img src="@/assets/login/contract.png" alt="icon" /> -->
......@@ -49,17 +49,60 @@ export default {
checkList: [], // 需要进行签署的合同
faceListUpload: [],
eventListener: null, // 事件监听
}
},
created () {
this.checkSigned()
},
beforeDestroy () {
// 去除事件监听(ios独有)
if (this.eventListener) this.eventListener.removeEventListener('exit')
beforeRouteEnter (to, from, next) {
next(async vm => {
// window.localStorage.setItem('check_list', this.checkList)
let list = JSON.parse(window.localStorage.getItem('check_list'))
console.log('!@#', list)
if (from.name === 'ElectronicSign') {
let url = process.env.basePath + 'batch_check_sign'
let data_class = vm.$route.query.name === 'confirmList' ? 'LEASE_ITEM' : 'PRJ_CONFIRM'
let param = { 'master': list.map(item => ({ confirm_id: item.confirm_id, data_class })) }
hlsPopup.showLoading('请稍候')
let res = await vm.$post(url, param)
vm.hlsPopup.hideLoading()
// if (res.result === 'S') {
// let checkList = res.lists.filter(ele => ele.signed_flag === 'Y').map(ele => ele.confirm_id)
// let submitList = list.filter(ele => checkList.includes(ele.confirm_id))
// if (!submitList.length) return
// let confirm_list = submitList.map(item => ({ confirm_id: item.confirm_id, data_class, confirm_status: 'APPROVED' }))
// if (!confirm_list.length) return
// let url2 = process.env.basePath + 'batch_do_confirm_bp'
// let param2 = { master: { confirm_list } }
// hlsPopup.showLoading('提交数据中')
// let res2 = await vm.$post(url2, param2)
// vm.hlsPopup.hideLoading()
// if (res2.result === 'S') {
// vm.hlsPopup.showSuccess('提交成功')
// let successList = res2.info.filter(item => item.status === 'S').map(item => item.confirm_id)
// vm.list = vm.list.filter(item => !successList.includes(item.confirm_id))
// if (!vm.list.length) vm.goBack()
// window.localStorage.setItem('handleContact', JSON.stringify(vm.list))
// await vm.checkSigned()
// } else {
// this.hlsPopup.showLongCenter(res2.message)
// }
// } else {
// hlsPopup.showLongCenter(res.message)
// }
}
})
},
methods: {
// 检测已经签署的合同,进行过滤
async checkSigned () {
......@@ -78,12 +121,14 @@ export default {
let checkList = res.lists.filter(ele => ele.signed_flag === 'N').map(ele => ele.confirm_id)
this.checkList = this.list.filter(ele => checkList.includes(ele.confirm_id))
window.localStorage.setItem('check_list', JSON.stringify(this.checkList))
// 加标识, checked为true 为 已签署
this.list = this.list.map(ele => {
ele.checked = !checkList.includes(ele.confirm_id)
return ele
})
console.log(this.list);
} else {
hlsPopup.showLongCenter(res.message)
}
......@@ -131,7 +176,10 @@ export default {
// 签署
async signContact () {
if (!this.checkList.length) return hlsPopup.showLongCenter('无可需要签署的电子合同')
<<<<<<< HEAD
=======
>>>>>>> dev20230131_android
let url = process.env.basePath + 'batch_sign'
let data_class = this.$route.query.name === 'confirmList' ? 'LEASE_ITEM' : 'PRJ_CONFIRM'
let param = {
......@@ -144,12 +192,11 @@ export default {
hlsPopup.showLoading('请稍候')
let res = await this.$post(url, param)
this.hlsPopup.hideLoading()
console.log('batch_sign接口返回信息:', res)
if (res.result === 'S' && res.info.msg === 'success') {
// 监听 InAppBrowser 关闭
this.eventListener = cordova.InAppBrowser.open(res.info.data.url, '_blank', 'location=yes')
this.eventListener.addEventListener('exit', () => {
this.checkSigned()
this.$router.push({
name: 'ElectronicSign',
params: { url: res.info.data.url },
})
} else {
hlsPopup.showLongCenter(res.message || res.info.msg)
......@@ -176,7 +223,7 @@ export default {
let filePath = JSON.stringify(success.message, '\\', null)
filePath = 'file:\/\/' + filePath.replace('\"', '')
filePath = filePath.substr(0, filePath.length - 1)
console.log('filePath ==== ' + filePath)
// console.log('filePath ==== ' + filePath)
// 回调成功上传图片
vm.uploadImg(filePath)
vm.signContact()
......
......@@ -71,7 +71,7 @@
<list-item :item-height="44">
<item>
<div slot="name">合同号</div>
<input slot="content" v-model="info.project_number" readonly placeholder="暂无数据" >
<input slot="content" v-model="project_number" readonly placeholder="暂无数据" >
</item>
<item>
<div slot="name">{{ info.bp_agent_name?'经销商':'办事处' }}</div>
......@@ -173,13 +173,14 @@
</div>
</h-content>
<bottom-tab v-if="!flag">
<tab-button class="before" @click.native="takePhonto">
<tab-button v-if="!signFlag" class="before" @click.native="takePhonto">
<img src="@/assets/constractSigning/certification.png" >签署合同
</tab-button>
<tab-button class="approve" @click.native="isConfirm">提交审核</tab-button>
<tab-button v-else class="approve" @click.native="isConfirm">提交审核</tab-button>
</bottom-tab>
</h-view>
</template>
<script>
import Tab from '@/pages/carConfirm/tab'
......@@ -213,6 +214,7 @@ export default {
legalPic: '', // 法人授权书图片
confirm_id: this.$route.query.confirm_id,
project_id: this.$route.query.project_id,
project_number: this.$route.query.project_number,
readed: require('@/assets/constractSigning/read.png'), // 已读
unRead: require('@/assets/constractSigning/unread.png'), // 未读
tabNum: 0,
......@@ -254,6 +256,8 @@ export default {
contract_id: '231',
},
],
signFlag: false,
isReadFlag: false,
}
},
// created () {
......@@ -270,8 +274,35 @@ export default {
// }
// },
beforeRouteEnter (to, from, next) {
next(vm => {
next(async vm => {
if (from.name === 'ConfirmList') {
window.localStorage.removeItem('confirm_id')
window.localStorage.removeItem('project_id')
window.localStorage.setItem('confirm_id', vm.$route.query.confirm_id)
window.localStorage.setItem('project_id', vm.$route.query.project_id)
}
vm.confirm_id = window.localStorage.getItem('confirm_id')
vm.project_id = window.localStorage.getItem('project_id')
if (from.name === 'ElectronicSign') {
let url = process.env.basePath + 'sign_check'
let param = {
confirm_id: vm.confirm_id,
data_class: 'LEASE_ITEM',
}
vm.hlsPopup.showLoading('请稍候!')
let res = await vm.hlsHttp.post(url, param)
vm.hlsPopup.hideLoading()
// if (res.result === 'S') {
// vm.signFlag = true
// await vm.confirm()
// } else {
// vm.signMsg = res.message
// vm.signFlag = false
// }
}
// if (from.name === 'ContractRepayPlan') {
vm.signCheck()
vm.getDetail()
vm.getEquipment()
vm.getAttachment()
......@@ -282,6 +313,7 @@ export default {
} else if (vm.confirm_status === 'APPROVED') {
vm.flag = true
}
// }
})
},
......@@ -300,6 +332,7 @@ export default {
hlsPopup.hideLoading()
if (res.result === 'S') {
vm.attachArray = res.attachments
vm.isReadFlag = res.attachments[0].read_status === 'Y'
} else {
vm.hlsPopup.showLongCenter(res.message)
}
......@@ -312,6 +345,7 @@ export default {
params: {
product_num: vm.info.product_num,
project_id: vm.project_id,
// quotation_id: vm.$route.query.quotation_id,
},
})
},
......@@ -337,6 +371,7 @@ export default {
temp.read_status = 'Y'
vm.$router.push({name: 'previewPdf', params: {attachUrl: vm.attachUrl}})
vm.attachArray.splice(vm.attachArray[index], 1, temp)
vm.isReadFlag = true
} else {
vm.hlsPopup.showLongCenter(res.message)
}
......@@ -386,9 +421,11 @@ export default {
let res = await vm.hlsHttp.post(url, param)
vm.hlsPopup.hideLoading()
if (res.result === 'S') {
vm.signFlag = true
return true
} else {
vm.signMsg = res.message
vm.signFlag = false
return false
}
},
......@@ -397,6 +434,10 @@ export default {
},
async takePhonto () {
let vm = this
if (!vm.isReadFlag) {
vm.hlsPopup.showLongCenter('请先阅读签约合同!')
return
}
let flag = await this.signCheck()
if (flag) {
vm.hlsPopup.showLongCenter('已经验证过!')
......@@ -609,6 +650,7 @@ export default {
let url = process.env.basePath + 'car_equip_list_query'
let param = {
project_id: vm.project_id,
// quotation_id: vm.$route.params.quotation_id,
pagesize: 999,
pagenum: 1,
}
......@@ -645,6 +687,8 @@ export default {
let url = process.env.basePath + 'con_contract_detial'
let param = {
project_id: vm.project_id,
// quotation_id: vm.$route.query.quotation_id,
}
hlsPopup.showLoading('请稍候')
vm.$post(url, param).then(function (res) {
......
......@@ -201,6 +201,8 @@ export default {
check_id: e.check_id,
confirm_id: e.confirm_id,
business_type: e.business_type,
// quotation_id: e.quotation_id,
project_number: e.project_number,
},
})
},
......
......@@ -14,16 +14,16 @@
</div>
</h-header>
<h-content class="my-contractlist">
<div v-if="['AGENT', 'OFFICE'].includes(user_bp_type)" class="contract-item" @click="goCreate()">
<div v-if="user_bp_type == 'MANAGER'" class="contract-item" @click="goCreate()">
<img src="@/assets/myInfo/contractCreate.png" >
<span>融租方案创建</span>
</div>
<div v-if="user_bp_type !== 'MANAGER'" class="contract-item" @click="goSign()">
<div v-if="user_bp_type == 'TENANT'" class="contract-item" @click="goSign()">
<p v-if="signCount > 0" :class="{'content-wrap-class-width':signCount > 99, 'content-wrap-class':signCount < 99}">{{ signCount > 99 ? '99+' : signCount }}</p>
<img src="@/assets/myInfo/unSign.png" >
<span>融租方案确认</span>
</div>
<div v-if="['GUTA', 'TENANT', 'AGENT'].includes(user_bp_type)" class="contract-item" @click="goCarConfirm()">
<div v-if="user_bp_type == 'TENANT'" class="contract-item" @click="goCarConfirm()">
<p v-if="carCount > 0" :class="{'content-wrap-class-width':carCount > 99, 'content-wrap-class':carCount < 99}">{{ carCount > 99 ? '99+' : carCount }}</p>
<img src="@/assets/myInfo/carConfirm.png" >
<span>合同签订</span>
......
......@@ -26,7 +26,7 @@
<p><span :class="{'selected':selected === 'two'}" @click="isSelected('two')">首付还款中</span></p>
<p><span :class="{'selected':selected === 'three'}" @click="isSelected('three')">还款中</span></p>
<p><span :class="{'selected':selected === 'four'}" @click="isSelected('four')">已结清</span></p>
<p><span :class="{'selected':selected === 'five'}" @click="isSelected('five')">撤销</span></p>
<!-- <p><span :class="{'selected':selected === 'five'}" @click="isSelected('five')">撤销</span></p> -->
<p><span :class="{'selected':selected === 'six'}" @click="isSelected('six')">其他</span></p>
</div>
......@@ -147,13 +147,13 @@ export default {
if (!this.repayed_flag) {
this.recordQuery('已结清', this.repayedLists)
}
} else if (this.selected === 'five') {
this.contract_status_n = '撤销'
// this.pageNum = this.repayed_pagenum
this.showLists = this.undoLists
if (!this.undo_flag) {
this.recordQuery('撤销', this.undoLists)
}
// } else if (this.selected === 'five') {
// this.contract_status_n = '撤销'
// // this.pageNum = this.repayed_pagenum
// this.showLists = this.undoLists
// if (!this.undo_flag) {
// this.recordQuery('撤销', this.undoLists)
// }
} else if (this.selected === 'six') {
this.contract_status_n = '其他'
// this.pageNum = this.repayed_pagenum
......@@ -385,9 +385,9 @@ export default {
} else if (vm.selected === 'four') {
vm.repayed_pagenum++
vm.pageNum = vm.repayed_pagenum
} else if (vm.selected === 'five') {
vm.undo_pagenum++
vm.pageNum = vm.undo_pagenum
// } else if (vm.selected === 'five') {
// vm.undo_pagenum++
// vm.pageNum = vm.undo_pagenum
} else if (vm.selected === 'six') {
vm.other_pagenum++
vm.pageNum = vm.other_pagenum
......@@ -432,8 +432,8 @@ export default {
vm.repayingLists.push(array[index])
} else if (vm.selected === 'four') {
vm.repayedLists.push(array[index])
} else if (vm.selected === 'five') {
vm.undoLists.push(array[index])
// } else if (vm.selected === 'five') {
// vm.undoLists.push(array[index])
} else if (vm.selected === 'six') {
vm.otherLists.push(array[index])
}
......@@ -451,8 +451,8 @@ export default {
vm.repayingLists.push(array[index])
} else if (vm.selected === 'four') {
vm.repayedLists.push(array[index])
} else if (vm.selected === 'five') {
vm.undoLists.push(array[index])
// } else if (vm.selected === 'five') {
// vm.undoLists.push(array[index])
} else if (vm.selected === 'six') {
vm.otherLists.push(array[index])
}
......@@ -477,8 +477,8 @@ export default {
this.searchRepaying()
} else if (vm.selected === 'four') {
this.searchRepayed()
} else if (vm.selected === 'five') {
this.searchUndo()
// } else if (vm.selected === 'five') {
// this.searchUndo()
} else if (vm.selected === 'six') {
this.searchOther()
}
......
......@@ -152,11 +152,24 @@ export default {
if (res.result === 'S') {
vm.fileArray = res.info
vm.fileArray.forEach(i => {
// cordova.InAppBrowser.open(i.fileUrl, '_system', 'location=yes,hideurlbar=no,toolbarposition=top')
// cordova.InAppBrowser.open(i.fileUrl, '_system', 'location=yes')
if (vum.Platform.isAndroid()) { // android终端
window.open(i.fileUrl, '_system', 'location=yes')
} else if (vum.Platform.isIOS() || vum.Platform.isIPad()) { // ios终端
cordova.InAppBrowser.open(i.fileUrl, '_system', 'location=yes,hideurlbar=no,toolbarposition=top')
// window.location.href = i.fileUrl;
// 模拟 输入框
var cInput = document.createElement('input')
cInput.value = i.fileUrl
document.body.appendChild(cInput)
cInput.select() // 选取文本框内容
// 执行浏览器复制命令
// 复制命令会将当前选中的内容复制到剪切板中(这里就是创建的input标签)
// Input要在正常的编辑状态下原生复制方法才会生效
document.execCommand('copy')
hlsPopup.showLongCenter('复制成功,请在浏览器中打开')
// 复制成功后再将构造的标签 移除
document.body.removeChild(cInput)
} else {
window.open(i.fileUrl, '_system', 'location=yes')
}
......
......@@ -129,6 +129,7 @@ export default {
let url = process.env.basePath + 'prj_cashflow_query'
let param = {
project_id: vm.project_id,
// quotation_id: vm.$route.query.quotation_id,
}
vm.hlsPopup.showLoading('数据加载中')
vm.hlsHttp.post(url, param).then(function (res) {
......
......@@ -18,7 +18,7 @@
</div>
<!-- 搜索 -->
<div class="search">
<input v-model="searchInput" type="text" placeholder="请输入合同号/承租人名称" >
<input v-model="searchInput" type="text" placeholder="请输入方案号/承租人名称" >
</div>
<scroll ref="scroll" :updateData="[showLists]" :pullUp="true" @pullingUp="loadMore">
......@@ -27,12 +27,12 @@
<div class="pro-code" @click="goDetails(item)">
<img src="@/assets/distributorSign/fileIcon.png" alt class="file-icon" >
<p>
<span>合同</span>
<span>方案</span>
<span>{{ item.project_number }}</span>
</p>
<img src="@/assets/constractSigning/righticon.png" alt class="arrow" >
<img v-if="item.read_check === 'N'" src="@/assets/constractSigning/unread.png" alt class="unread" >
<img v-if="item.read_check === 'Y'" src="@/assets/constractSigning/read.png" alt class="unread" >
<img src="@/assets/constractSigning/righticon.png" alt class="arrow" >
</div>
<div class="box">
<div
......@@ -54,11 +54,11 @@
<p>{{ item.bp_name }}</p>
</div>
<div>
<p>合同名称</p>
<p>方案名称</p>
<p>{{ item.project_name }}</p>
</div>
<div>
<p>合同租金</p>
<p>方案总租金</p>
<p class="money">{{ item.total_price | currency }}</p>
</div>
<div>
......@@ -189,6 +189,7 @@ export default {
methods: {
signContract () {
let list = this.showLists.filter(item => item.checked)
console.log(list)
if (!list.length) return hlsPopup.showLongCenter('请选择合同')
if (list.findIndex(item => item.read_check === 'N') > -1) return hlsPopup.showLongCenter('您有授权书未阅读,请阅读后再签署')
......
......@@ -124,7 +124,7 @@
<div slot="name">合同号</div>
<input
slot="content"
v-model="detail.project_number"
v-model="project_number"
readonly
placeholder="暂无数据"
>
......@@ -414,6 +414,7 @@ export default {
downNum: false,
show: false,
project_id: this.$route.query.project_id,
project_number: this.$route.query.project_number,
read: false, // 表示只读
showDate: '',
flag: false,
......
......@@ -159,6 +159,7 @@ export default {
query: {
project_id: e.project_id,
car_start_status: e.car_start_status,
project_number: e.project_number,
},
})
},
......
<!-- 附件 -->
<template>
<div style="width: 100%;">
<p class="notice">tips:点击上传目录即可上传,点击文件即可下载或预览。</p>
<div class="table-box">
<table class="att_table">
<tr>
<th>上传目录</th>
<th>附件</th>
<th>备注</th>
</tr>
<tr v-for="(item, index) of appendixData" :key="item.check_id">
<td @click="chooseFile(item.check_id)">{{ item.description }}</td>
<td>
<span v-for="(attach, ai) in item.attachArr" :key="attach.attachId" @click="previewOrDownload(attach)">
{{ attach.fileName + (ai === item.attachArr.length - 1 ? '' : ',') }}
</span>
</td>
<td>{{ item.note }}</td>
</tr>
</table>
</div>
</div>
</template>
<script>
export default {
props: ['appendixData'],
data() {
return {
licenseImg: '',
}
},
methods: {
previewOrDownload(attObj) {
let picUrl = `${process.env.filePath}attachment_id=${attObj.attachId}&access_token=${window.localStorage.access_token}`
if (/.png|.jpg$/.test(attObj.fileName)) {
this.showBigPicture(picUrl)
} else {
console.log(hlsUtil.convertImageUrl(picUrl));
window.open(hlsUtil.convertImageUrl(picUrl))
}
console.log(attObj);
},
// 上传窗口
chooseFile(check_id) {
let vm = this
hlsPopup.showActionSheet({
titleText: '请选择照片',
buttonArray: ['拍照', '从相册取'],
callback: index => {
if (index === 0) {
vm.openCamera(check_id)
} else {
vm.takePicture(check_id)
}
},
})
},
openCamera(check_id) {
let vm = this
let cameraoptions = {
quality: 60,
width: 1843,
height: 1382,
}
let success = function (imgdata) {
if (!imgdata) {
hlsPopup.showLongCenter('请拍照')
} else {
vm.licenseImg = hlsUtil.convertImageUrl(imgdata)
let list = [{
pkvalue: check_id,
source_type: "PRJ_CDD_ITEM_CHECK",
picture: '',
filePath: imgdata,
attachment_id: '',
user_id: 1,
fileName: ''
}]
vm.save_file(list)
}
}
let error = function () {
hlsPopup.showLongCenter('请拍照')
}
hlsUtil.openCamera(cameraoptions, success, error)
},
takePicture(check_id) {
let vm = this
var cameraoptions = {
quality: 70,
width: 1843,
height: 1382,
maxCount: 1,
}
let success = function (imgUrl) {
if (imgUrl.length === 0) {
hlsPopup.showLongCenter('请选择一张图片')
} else {
vm.licenseImg = hlsUtil.convertImageUrl(imgUrl[0])
let list = [{
pkvalue: check_id,
source_type: "PRJ_CDD_ITEM_CHECK",
picture: '',
filePath: imgUrl[0],
attachment_id: '',
user_id: 1,
fileName: ''
}]
vm.save_file(list)
}
}
let error = function () {
hlsPopup.showLongCenter(error)
}
vm.hlsUtil.takePicture(cameraoptions, success, error)
},
// 图片保存
save_file(list) {
let vm = this
let upView = vm.debounce(function () { vm.$emit("upData") }, 1500)
if (list.length) {
// hlsPopup.showLoading('图片上传请稍候')
var alreadyUploadNum = 0
var attLength = 0
var recordUploadInterval = setInterval(function () {
if (alreadyUploadNum === attLength) {
clearInterval(recordUploadInterval)
/* hlsPopup.hideLoading()
hlsPopup.showLongCenter('图片上传成功') */
}
}, 500)
for (var i = 0; i < list.length; i++) {
let uploadSuccess = function (res) {
if (res.result === 'S') {
alreadyUploadNum++
for (var j = 0; j < list.length; j++) {
if (list[j].filePath === res.response.filePath) {
list[j].attachment_id = res.response.attachment_id
break
}
}
upView()
} else {
hlsPopup.hideLoading()
}
}
if (!list[i].attachment_id) {
attLength++
console.log(list[i])
hlsUtil.fileUploadSvc(list[i], uploadSuccess)
}
}
} else {
hlsPopup.hideLoading()
}
},
// 查看图片
showBigPicture(picUrl) {
let vm = this
vm.hlsPopup.showBigPicture({ imgUrl: picUrl, width: '100%', })
},
debounce(func, wait) {
let timer;
return function () {
let context = this; // 注意 this 指向
let args = arguments; // arguments中存着e
if (timer) clearTimeout(timer);
timer = setTimeout(() => {
func.apply(this, args)
}, wait)
}
}
}
}
</script>
<style lang="less" scoped>
.notice {
padding: 10px 10px;
background-color: #fffbe8;
color: #ed6a0c;
font-size: 14px;
font-family: PingFangSC-Semibold;
}
.table-box {
width: 100vw;
overflow-x: auto;
}
.att_table {
min-width: 100%;
font-family: PingFangSC-Semibold;
font-size: 14px;
line-height: 32px;
color: #02459a;
td,
th {
box-sizing: border-box;
padding: 3px 5px;
border: 1px solid #ccc;
text-align: center;
height: 32px;
min-width: 100px;
}
th {
height: 25px;
line-height: 25px;
font-weight: 600;
}
}
</style>
\ No newline at end of file
<template>
<list-item :item-height="44">
<div>
<div slot="name" class="section-title" style="">车辆行驶证</div>
<item v-for="(ele, i) of driving_permit" :key="ele.title">
<div slot="name" class="font-color">{{ ele.title }}</div>
<span v-if="ele.type === 'date'" slot="content">{{ car[ele.prop] | dateFormat }}</span>
<span v-else-if="ele.type === 'currency'" slot="content">{{ car[ele.prop] | currency }}</span>
<span v-else-if="ele.type === 'bool'" slot="content">{{ car[ele.prop] === 'Y' ? '是' : '否' }}</span>
<span v-else slot="content">{{ car[ele.prop] }}</span>
</item>
</div>
<div>
<div slot="name" class="section-title" style="">房产证</div>
<item v-for="(ele, i) of house_card" :key="ele.title">
<div slot="name" class="font-color">{{ ele.title }}</div>
<span v-if="ele.type === 'date'" slot="content">{{ house[ele.prop] | dateFormat }}</span>
<span v-else-if="ele.type === 'currency'" slot="content">{{ house[ele.prop] | currency }}</span>
<span v-else-if="ele.type === 'bool'" slot="content">{{ house[ele.prop] === 'Y' ? '是' : '否' }}</span>
<span v-else slot="content">{{ house[ele.prop] }}</span>
</item>
</div>
<div>
<div slot="name" class="section-title" style="">不动产权证</div>
<item v-for="(ele, i) of real_est" :key="ele.title">
<div slot="name" class="font-color">{{ ele.title }}</div>
<span v-if="ele.type === 'date'" slot="content">{{ real[ele.prop] | dateFormat }}</span>
<span v-else-if="ele.type === 'currency'" slot="content">{{ real[ele.prop] | currency }}</span>
<span v-else-if="ele.type === 'bool'" slot="content">{{ real[ele.prop] === 'Y' ? '是' : '否' }}</span>
<span v-else slot="content">{{ real[ele.prop] }}</span>
</item>
</div>
</list-item>
</template>
<script>
export default {
props: ['car', 'house', 'real'],
data () {
return {
}
},
computed: {
driving_permit () {
return this.createForm()
},
house_card () {
return this.createFormHouse()
},
real_est () {
return this.createFormReal()
},
},
methods: {
factory (arr) {
let outArr = []
if (arr.length) {
arr.forEach(ele => {
let [title, prop, type] = ele
outArr.push({
title: title || '',
prop: prop || 'fdf',
type: type || 'text',
})
})
}
return outArr
},
createForm () {
let driving_permit = [
// 车辆行驶证
['车辆识别代号', 'vehicle_identify_num', 'text'],
['住址', 'address', 'text'],
['品牌型号', 'brand_model_number', 'text'],
['发证日期', 'start_date', 'date'],
['车辆类型', 'vehicle_type', 'text'],
['所有人', 'owner', 'text'],
['发动机号码', 'engine_number', 'text'],
['号牌号码', 'plate_number', 'text'],
['注册日期', 'regist_date', 'date'],
['数量', 'words_result_num', 'text'],
]
return this.factory(driving_permit)
},
createFormHouse () {
let arr = [
// 房产证
['房屋所有人', 'house_owner', 'text'],
['共有情况', 'public_situation', 'text'],
['房屋坐落', 'house_location', 'text'],
['登记时间', 'regist_date', 'date'],
['房屋性质', 'house_property', 'text'],
['规划用途', 'plan_purpose', 'text'],
['总层数', 'house_layers', 'text'],
['建筑面积', 'built_area', 'text'],
['套内建筑面积', 'built_in_area', 'text'],
['其他', 'others', 'text'],
['地号', 'land_number', 'text'],
['土地使用权取得方式', 'land_get_method', 'text'],
['土地使用年限', 'land_use_limit', 'text'],
]
return this.factory(arr)
},
createFormReal () {
let arr = [
// 不动产权证
['权利人', 'right_person', 'text'],
['共有情况', 'public_situation', 'text'],
['坐落', 'house_location', 'text'],
['不动产单元号', 'real_unit_number', 'text'],
['权利类型', 'right_type', 'text'],
['权利性质', 'right_property', 'text'],
['用途', 'house_purpose', 'text'],
['面积', 'house_area', 'text'],
['使用期限', 'land_use_limit', 'text'],
['权利其他情况', 'right_others', 'text'],
]
return this.factory(arr)
},
},
}
</script>
<style lang="less" scoped>
.section-title{
padding: 0 0 0 0.3rem;
font-size: 0.3rem;
color: #385880;
line-height: 0.5rem;
margin-top: 12px;
}
</style>
<template>
<list-item :item-height="44">
<div>
<!-- <div slot="name" class="section-title" style="">银行信息</div> -->
<item v-for="(ele, i) of formdata" :key="ele.title">
<div slot="name" class="font-color">{{ ele.title }}</div>
<span v-if="ele.type === 'date'" slot="content">{{ bankInfo[ele.prop] | dateFormat }}</span>
<span v-else-if="ele.type === 'currency'" slot="content">{{ bankInfo[ele.prop] | currency }}</span>
<span v-else-if="ele.type === 'bool'" slot="content">{{ bankInfo[ele.prop] === 'Y' ? '是' : '否' }}</span>
<Checkbox v-else-if="ele.type === 'checkbox'" :value="bankInfo[ele.prop]==='Y'" shape="square"/>
<span v-else slot="content">{{ bankInfo[ele.prop] }}</span>
</item>
</div>
</list-item>
</template>
<script>
import { Checkbox } from 'vant'
import 'vant/lib/checkbox/style'
export default {
props: ['bankInfo'],
components: {
Checkbox
},
data() {
return {
activeNames: [0],
// formdata: [],
}
},
computed: {
formdata () {
return this.createForm()
},
},
methods: {
factory (arr) {
let outArr = []
if (arr.length) {
arr.forEach(ele => {
let [title, prop, type] = ele
outArr.push({
title: title || '',
prop: prop || 'fdf',
type: type || 'text',
})
})
}
return outArr
},
createForm() {
let formArr = [
['账号名称', 'bank_account_name', 'text'],
['银行账号', 'bank_account_num', 'text'],
['支行名称', 'bank_branch_name', 'text'],
['银行名称', 'bank_full_name', 'text'],
['启用', 'enabled_flag', 'checkbox'],
]
return this.factory(formArr)
}
}
}
</script>
<style lang="less" scoped></style>
\ No newline at end of file
<!-- 基本信息 -->
<template>
<list-item :item-height="44">
<div>
<div slot="name" class="section-title" style="">基本信息</div>
<item v-for="(ele, i) of formdata" :key="ele.title">
<div slot="name" class="font-color">{{ ele.title }}</div>
<span v-if="ele.type === 'date'" slot="content">{{ baseInfo[ele.prop] | dateFormat }}</span>
<span v-else-if="ele.type === 'currency'" slot="content">{{ baseInfo[ele.prop] | currency }}</span>
<span v-else-if="ele.type === 'bool'" slot="content">{{ baseInfo[ele.prop] === 'Y' ? '是' : '否' }}</span>
<span v-else slot="content">{{ baseInfo[ele.prop] }}</span>
</item>
</div>
<div>
<div slot="name" class="section-title" style="">配偶信息</div>
<item v-for="(ele, i) of formdata_sp" :key="ele.title">
<div slot="name" class="font-color">{{ ele.title }}</div>
<span v-if="ele.type === 'date'" slot="content">{{ baseInfo[ele.prop] | dateFormat }}</span>
<span v-else-if="ele.type === 'currency'" slot="content">{{ baseInfo[ele.prop] | currency }}</span>
<span v-else-if="ele.type === 'bool'" slot="content">{{ baseInfo[ele.prop] === 'Y' ? '是' : '否' }}</span>
<span v-else slot="content">{{ baseInfo[ele.prop] }}</span>
</item>
</div>
<div v-if="['TENANT', 'GUTA'].indexOf(baseInfo.bp_type)!==-1">
<div slot="name" class="section-title" style="">资质信息</div>
<item v-for="(ele, i) of formdata_quality" :key="ele.title">
<div slot="name" class="font-color">{{ ele.title }}</div>
<span v-if="ele.type === 'date'" slot="content">{{ baseInfo[ele.prop] | dateFormat }}</span>
<span v-else-if="ele.type === 'currency'" slot="content">{{ baseInfo[ele.prop] | currency }}</span>
<span v-else-if="ele.type === 'bool'" slot="content">{{ baseInfo[ele.prop] === 'Y' ? '是' : '否' }}</span>
<span v-else slot="content">{{ baseInfo[ele.prop] }}</span>
</item>
</div>
</list-item>
</template>
<script>
export default {
props: ['baseInfo'],
data () {
return {
}
},
computed: {
formdata () {
return this.createForm()
},
formdata_sp () {
return this.createForm_SP()
},
formdata_quality () {
return this.createForm_quality()
},
},
methods: {
factory (arr) {
let outArr = []
if (arr.length) {
arr.forEach(ele => {
let [title, prop, type] = ele
outArr.push({
title: title || '',
prop: prop || 'fdf',
type: type || 'text',
})
})
}
return outArr
},
createForm () {
let baseInfo_A = [// 承租人/担保人
['姓名', 'bp_name', 'text'],
['学历', 'academic_background_n', 'text'],
['婚姻状况', 'marital_status_n', 'text'],
['身份证', 'id_card_no', 'text'],
['证件有效期从', 'id_card_date_from', 'date'],
['证件有效期到', 'id_card_date_to', 'date'],
['业务办理地(省)', 'province_n', 'text'],
['业务办理地(市)', 'city_n', 'text'],
['业务办理地(区/县)', 'district_n', 'text'],
['邮政编码', 'post_code', 'text'],
['所属机构名称', 'agent_name', 'text'],
['所属机构代码', 'business_license_num', 'text'],
['手机号', 'cell_phone', 'text'],
['QQ号', 'qq_code', 'text'],
['微信号', 'wechat_code', 'text'],
['户籍地址', 'address_on_resident_booklit', 'text'],
['联系地址', 'living_address', 'text'],
['资产', 'capital', 'text'],
]
let baseInfo_B = [// 经销商/主机厂/办事处
['姓名', 'bp_name', 'text'],
['学历', 'academic_background_n', 'text'],
['婚姻状况', 'marital_status_n', 'text'],
['身份证', 'id_card_no', 'text'],
['证件有效期从', 'id_card_date_from', 'date'],
['证件有效期到', 'id_card_date_to', 'date'],
['业务办理地(省)', 'province_n', 'text'],
['业务办理地(市)', 'city_n', 'text'],
['业务办理地(区/县)', 'district_n', 'text'],
['手机号', 'cell_phone', 'text'],
['QQ号', 'qq_code', 'text'],
['微信号', 'wechat_code', 'text'],
['所属机构证件号', 'business_license_num', 'text'],
['所属机构名称', 'agent_name', 'text'],
['户籍地址', 'address_on_resident_booklit', 'text'],
['联系地址', 'living_address', 'text'],
]
let newForm = ['TENANT', 'GUTA'].indexOf(this.baseInfo.bp_type) !== -1 ? baseInfo_A : baseInfo_B
return this.factory(newForm)
},
createForm_SP () {
let mateInfo = [// 配偶信息
['姓名', 'bp_name_sp', 'text'],
['身份证号码', 'id_card_no_sp', 'text'],
['证件有效期从', 'id_card_date_from_sp', 'date'],
['证件有效期到', 'id_card_date_to_sp', 'date'],
['手机号', 'spouse_phone', 'text'],
['工作单位', 'working_place_sp', 'text'],
['联系地址', 'address_sp', 'text'],
]
return this.factory(mateInfo)
},
createForm_quality () {
let qualificationInfo = [// 资质信息
['是否黑名单', 'blackList_flag', 'text'],
['征信是否异常', 'credit_normal_flag', 'text'],
['评级结果', 'rating_result', 'text'],
]
return this.factory(qualificationInfo)
},
},
}
</script>
<style lang="less" scoped>
.section-title{
padding: 0 0 0 0.3rem;
font-size: 0.3rem;
color: #385880;
line-height: 0.5rem;
margin-top: 12px;
}
</style>
This diff is collapsed.
<!-- 开票信息 -->
<template>
<list-item :item-height="44">
<item v-for="(ele, i) of formdata" :key="ele.title">
<div slot="name" class="font-color">{{ ele.title }}</div>
<span v-if="ele.type === 'currency'" slot="content">{{ billingInfo[ele.prop] || currency }}</span>
<span v-else-if="ele.type === 'bool'" slot="content">{{ billingInfo[ele.prop] === 'Y' ? '是' : '否' }}</span>
<span v-else="ele.type === 'text'" slot="content">{{ billingInfo[ele.prop] }}</span>
</item>
</list-item>
</template>
<script>
export default {
props: ['billingInfo'],
data () {
return {
}
},
computed: {
formdata () {
return this.createForm()
},
},
methods: {
factory (arr) {
let outArr = []
if (arr.length) {
arr.forEach(ele => {
let [title, prop, type] = ele
outArr.push({
title: title || '',
prop: prop || 'fdf',
type: type || 'text',
})
})
}
return outArr
},
createForm () {
let billingInfo_A = [// 自然人
['纳税人类型', 'taxpayer_type_n', 'text'],
['发票类型', 'invoice_kind_n', 'text'],
['发票抬头', 'invoice_title', 'text'],
['发票地址', 'invoice_adds', 'text'],
['开户电话', 'invoice_tel', 'text'],
['开户银行', 'open_bank', 'text'],
['开户行账号', 'open_account', 'text'],
]
let billingInfo_B = [// 法人
['纳税人类型', 'taxpayer_type_n', 'text'],
['发票类型', 'invoice_kind_n', 'text'],
['发票抬头', 'invoice_title', 'text'],
['发票地址', 'invoice_adds', 'text'],
['开户电话', 'invoice_tel', 'text'],
['开户银行', 'open_bank', 'text'],
['开户行账号', 'open_account', 'text'],
['纳税人识别号', 'organization_code', 'text'],
]
let newForm = this.billingInfo.bp_class === 'NP' ? billingInfo_A : billingInfo_B
return this.factory(newForm)
},
},
}
</script>
<style lang="less" scoped></style>
<!-- 审批历史 -->
<template>
<div class="history-detail">
<div class="history-item" v-for="(item, index) in historyData" :key="index" :class="{ hidden: !isOpen && index }">
<div class="dot"></div>
<div class="info-box">
<span style="font-weight: 600; flex: 1 0 33%">{{ item.node_desc }}</span>
<span style="flex: 1 0 33%; text-align: center;">{{ item.action_type_desc }}</span>
<span style="font-size: 0.24rem;flex: 1 0 33%; text-align: right;">{{ item.create_date_fmt.split(' ')[0] }}</span>
<!-- <span style="flex: 1 0 100%">{{ item.comment_text }}</span> -->
</div>
</div>
</div>
</template>
<script>
export default {
props: [
'isOpen',
'historyData'
],
data() {
return {
// historyData: [
// {
// title: '20主机厂初审中',
// date: '2023/1/4 18:01:43',
// remark: ''
// },
// {
// title: '20主机厂初审中',
// date: '2023/1/4 18:01:43',
// remark: ''
// },
// {
// title: '20主机厂初审中',
// date: '2023/1/4 18:01:43',
// remark: ''
// },
// {
// title: '20主机厂初审中',
// date: '2023/1/4 18:01:43',
// remark: ''
// },
// ]
}
},
created() {
console.log('历史审批',this.historyData);
},
methods: {
}
}
</script>
<style lang="less" scoped>
.history-detail {
color: white;
padding: 10px 10px 0;
font-size: 0.26rem;
.history-item {
display: flex;
justify-content: space-around;
height: 70px;
&:last-child .dot {
background-repeat: no-repeat;
}
&:nth-child(1) .dot {
background-repeat: repeat;
}
}
}
.dot {
height: 70px;
width: 2px;
z-index: 0;
background: linear-gradient(to top, #fff, #fff 0.05rem, transparent 0.05rem, transparent);
background-size: 100% 0.16rem;
&::before {
content: '';
display: block;
width: 12px;
height: 12px;
border-radius: 12px;
transform: translateX(-0.11rem);
z-index: 11;
background-color: #a8a9aa;
}
}
.hidden {
visibility: hidden;
}
.info-box {
display: flex;
flex-wrap: wrap;
flex: 1 0 60%;
max-width: 85%;
}
</style>
\ No newline at end of file
<!-- 商业伙伴 -->
<template>
<Collapse v-if="roleInfo.length" v-model="activeNames">
<CollapseItem v-for="(p, pi) of roleInfo" :title="p.bp_name" :key="p.bp_id" :name="pi">
<list-item :item-height="44">
<item v-for="(ele, i) of formdata" :key="ele.title">
<div slot="name" class="font-color">{{ ele.title }}</div>
<Checkbox v-if="ele.type === 'checkbox'" shape="square" :value="roleInfo[pi][ele.prop]==='Y'"/>
<span v-else slot="content">{{ roleInfo[pi][ele.prop] }}</span>
</item>
</list-item>
</CollapseItem>
</Collapse>
</template>
<script>
import { Collapse, CollapseItem, Checkbox } from 'vant'
import 'vant/lib/collapse/style'
import 'vant/lib/collapse-item/style'
import 'vant/lib/checkbox/style'
export default {
components: {
Collapse, CollapseItem, Checkbox,
},
props: ['roleInfo'],
data () {
return {
activeNames: [0],
formdata: [],
}
},
created() {
this.createForm()
},
methods: {
factory (arr) {
// 接收二维数组,产生 formdata
if (arr.length) {
arr.forEach(ele => {
let [title, prop, type] = ele
this.formdata.push({
title: title || '',
prop: prop || '',
type: type || 'text',
})
})
}
},
createForm () {
let formArr = [
['商业伙伴类型', 'bp_type_n', 'text'],
['主角色标志', 'primary_flag', 'checkbox'],
['启用', 'enabled_flag', 'checkbox'],
]
this.factory(formArr)
},
},
}
</script>
<style lang="less" scoped></style>
This diff is collapsed.
<!-- 附件 -->
<template>
<div style="width: 100%;">
<p class="notice">tips:点击上传目录即可上传,点击文件即可下载或预览。</p>
<div class="table-box">
<table class="att_table">
<tr>
<th>上传目录</th>
<th>附件</th>
<th>备注</th>
</tr>
<tr v-for="(item, index) of appendixData" :key="item.check_id">
<td @click="chooseFile(item.check_id)">{{ item.description }}</td>
<td>
<span v-for="(attach, ai) in item.attachArr" :key="attach.attachId" @click="previewOrDownload(attach)">
{{ attach.fileName + (ai === item.attachArr.length - 1 ? '' : ',') }}
</span>
</td>
<td>{{ item.note }}</td>
</tr>
</table>
</div>
</div>
</template>
<script>
export default {
props: ['appendixData'],
data() {
return {
licenseImg: '',
}
},
methods: {
previewOrDownload(attObj) {
let picUrl = `${process.env.filePath}attachment_id=${attObj.attachId}&access_token=${window.localStorage.access_token}`
if (/.png|.jpg$/.test(attObj.fileName)) {
this.showBigPicture(picUrl)
} else {
console.log(hlsUtil.convertImageUrl(picUrl));
window.open(hlsUtil.convertImageUrl(picUrl))
}
console.log(attObj);
},
// 上传窗口
chooseFile(check_id) {
let vm = this
hlsPopup.showActionSheet({
titleText: '请选择照片',
buttonArray: ['拍照', '从相册取'],
callback: index => {
if (index === 0) {
vm.openCamera(check_id)
} else {
vm.takePicture(check_id)
}
},
})
},
openCamera(check_id) {
let vm = this
let cameraoptions = {
quality: 60,
width: 1843,
height: 1382,
}
let success = function (imgdata) {
if (!imgdata) {
hlsPopup.showLongCenter('请拍照')
} else {
vm.licenseImg = hlsUtil.convertImageUrl(imgdata)
let list = [{
pkvalue: check_id,
source_type: "PRJ_CDD_ITEM_CHECK",
picture: '',
filePath: imgdata,
attachment_id: '',
user_id: 1,
fileName: ''
}]
vm.save_file(list)
}
}
let error = function () {
hlsPopup.showLongCenter('请拍照')
}
hlsUtil.openCamera(cameraoptions, success, error)
},
takePicture(check_id) {
let vm = this
var cameraoptions = {
quality: 70,
width: 1843,
height: 1382,
maxCount: 1,
}
let success = function (imgUrl) {
if (imgUrl.length === 0) {
hlsPopup.showLongCenter('请选择一张图片')
} else {
vm.licenseImg = hlsUtil.convertImageUrl(imgUrl[0])
let list = [{
pkvalue: check_id,
source_type: "PRJ_CDD_ITEM_CHECK",
picture: '',
filePath: imgUrl[0],
attachment_id: '',
user_id: 1,
fileName: ''
}]
vm.save_file(list)
}
}
let error = function () {
hlsPopup.showLongCenter(error)
}
vm.hlsUtil.takePicture(cameraoptions, success, error)
},
// 图片保存
save_file(list) {
let vm = this
let upView = vm.debounce(function () { vm.$emit("upData") }, 1500)
if (list.length) {
// hlsPopup.showLoading('图片上传请稍候')
var alreadyUploadNum = 0
var attLength = 0
var recordUploadInterval = setInterval(function () {
if (alreadyUploadNum === attLength) {
clearInterval(recordUploadInterval)
/* hlsPopup.hideLoading()
hlsPopup.showLongCenter('图片上传成功') */
}
}, 500)
for (var i = 0; i < list.length; i++) {
let uploadSuccess = function (res) {
if (res.result === 'S') {
alreadyUploadNum++
for (var j = 0; j < list.length; j++) {
if (list[j].filePath === res.response.filePath) {
list[j].attachment_id = res.response.attachment_id
break
}
}
upView()
} else {
hlsPopup.hideLoading()
}
}
if (!list[i].attachment_id) {
attLength++
console.log(list[i])
hlsUtil.fileUploadSvc(list[i], uploadSuccess)
}
}
} else {
hlsPopup.hideLoading()
}
},
// 查看图片
showBigPicture(picUrl) {
let vm = this
vm.hlsPopup.showBigPicture({ imgUrl: picUrl, width: '100%', })
},
debounce(func, wait) {
let timer;
return function () {
let context = this; // 注意 this 指向
let args = arguments; // arguments中存着e
if (timer) clearTimeout(timer);
timer = setTimeout(() => {
func.apply(this, args)
}, wait)
}
}
}
}
</script>
<style lang="less" scoped>
.notice {
padding: 10px 10px;
background-color: #fffbe8;
color: #ed6a0c;
font-size: 14px;
font-family: PingFangSC-Semibold;
}
.table-box {
width: 100vw;
overflow-x: auto;
}
.att_table {
min-width: 100%;
font-family: PingFangSC-Semibold;
font-size: 14px;
line-height: 32px;
color: #02459a;
td,
th {
box-sizing: border-box;
padding: 3px 5px;
border: 1px solid #ccc;
text-align: center;
height: 32px;
min-width: 100px;
}
th {
height: 25px;
line-height: 25px;
font-weight: 600;
}
}
</style>
\ No newline at end of file
<!-- 审批历史 -->
<template>
<div class="history-detail">
<div class="history-item" v-for="(item, index) in historyData" :key="index" :class="{ hidden: !isOpen && index }">
<div class="dot"></div>
<div class="info-box">
<span style="font-weight: 600; flex: 1 0 33%">{{ item.node_desc }}</span>
<span style="flex: 1 0 33%; text-align: center;">{{ item.action_type_desc }}</span>
<span style="font-size: 0.24rem;flex: 1 0 33%; text-align: right;">{{ item.create_date_fmt.split(' ')[0] }}</span>
<!-- <span style="flex: 1 0 100%">{{ item.comment_text }}</span> -->
</div>
</div>
</div>
</template>
<script>
export default {
props: [
'isOpen',
'historyData'
],
data() {
return {
// historyData: [
// {
// title: '20主机厂初审中',
// date: '2023/1/4 18:01:43',
// remark: ''
// },
// {
// title: '20主机厂初审中',
// date: '2023/1/4 18:01:43',
// remark: ''
// },
// {
// title: '20主机厂初审中',
// date: '2023/1/4 18:01:43',
// remark: ''
// },
// {
// title: '20主机厂初审中',
// date: '2023/1/4 18:01:43',
// remark: ''
// },
// ]
}
},
created() {
},
methods: {
}
}
</script>
<style lang="less" scoped>
.history-detail {
color: white;
padding: 10px 10px 0;
font-size: 0.26rem;
.history-item {
display: flex;
justify-content: space-around;
height: 70px;
&:last-child .dot {
background-repeat: no-repeat;
}
&:nth-child(1) .dot {
background-repeat: repeat;
}
}
}
.dot {
height: 70px;
width: 2px;
z-index: 0;
background: linear-gradient(to top, #fff, #fff 0.05rem, transparent 0.05rem, transparent);
background-size: 100% 0.16rem;
&::before {
content: '';
display: block;
width: 12px;
height: 12px;
border-radius: 12px;
transform: translateX(-0.11rem);
z-index: 11;
background-color: #a8a9aa;
}
}
.hidden {
visibility: hidden;
}
.info-box {
display: flex;
flex-wrap: wrap;
flex: 1 0 60%;
max-width: 85%;
}
</style>
\ No newline at end of file
<!-- 承租人 -->
<template>
<list-item :item-height="44">
<item v-for="(ele, i) of formdata" :key="ele.title">
<div slot="name" class="font-color">{{ ele.title }}</div>
<span slot="content" v-if="ele.type === 'currency'">{{ lesseeData[ele.prop] || currency }}</span>
<span slot="content" v-else-if="ele.type === 'bool'">{{ lesseeData[ele.prop] === 'Y' ? '是' : '否' }}</span>
<span slot="content" v-else="ele.type === 'text'">{{ lesseeData[ele.prop] }}</span>
</item>
</list-item>
</template>
<script>
export default {
props: ["lesseeData"],
data() {
return {
}
},
computed: {
formdata() {
return this.createForm()
}
},
methods: {
factory(arr) {
let outArr = []
if (arr.length) {
arr.forEach(ele => {
let [title, prop, type] = ele
outArr.push({
title: title || '',
prop: prop || 'fdf',
type: type || 'text'
})
});
}
return outArr
},
createForm() {
let corporationFormArr = [
['公司名称', 'bp_id_tenant_n', 'text'],
['客户编码', 'BP_CODE', 'text'],
['企业类型', 'enterprise_type', 'text'],
['法定代表人', 'legal_person', 'text'],
['法人身份证号', 'id_card_no', 'text'],
['法人手机号', 'cell_phone', 'text'],
['注册资本(万元)', 'registered_capital', 'text'],
['法人联系地址', 'living_ad', 'text'],
['企业性质', 'enterpriese_nature_n', 'text'],
['注册地址', 'registered_place', 'text'],
['经营地址', 'business_address', 'text'],
['自有设备价值', 'equip_value_n', 'text'],
['设备保有量', 'equip_num_n', 'text'],
['工程合同', 'engineer_con_n', 'text'],
['农行代扣', 'abc_deduction_flag', 'bool'],
['是否授权', 'auth_flag', 'bool'],
['合同补充条款', 'contract_supplementary_file', 'text'],
]
let personalFormArr = [
['姓名', 'bp_id_tenant_n', 'text'],
['客户编码', 'bp_code', 'text'],
['身份证号', 'id_card_no', 'text'],
['手机号', 'cell_phone', 'text'],
['婚姻', 'marital_status_n', 'text'],
['职业情况', 'np_occupation_n', 'text'],
['自有设备价值', 'equip_value_n', 'text'],
['行业情况', 'np_industry_exp_n', 'text'],
['户籍地址', 'address_on_resident_booklit', 'text'],
['联系地址', 'living_address', 'text'],
['配偶姓名', 'bp_name_sp', 'text'],
['配偶手机号', 'spouse_phone', 'text'],
['房产类型', 'house_type_n', 'text'],
['配偶工作地址', 'working_place_sp', 'text'],
['配偶联系地址', 'address_sp', 'text'],
['农行代扣', 'abc_deduction_flag', 'bool'],
['是否抵押', 'mortgega_flag', 'bool'],
['合同补充条款', 'contract_supplementary_file', 'text'],
]
let nowForm = this.lesseeData.bp_class === 'NP' ? personalFormArr : corporationFormArr
return this.factory(nowForm)
}
}
}
</script>
<style lang="less" scoped></style>
\ No newline at end of file
<!-- 商业伙伴 -->
<template>
<Collapse v-model="activeNames" v-if="bplist.length">
<CollapseItem v-for="(p, pi) of bplist" :title="p.bp_name" :key="p.bp_name" :name="pi">
<list-item :item-height="44">
<item v-for="(ele, i) of formdata" :key="ele.title">
<div slot="name" class="font-color">{{ ele.title }}</div>
<span slot="content">{{ bplist[pi][ele.prop] }}</span>
</item>
</list-item>
</CollapseItem>
</Collapse>
</template>
<script>
import { Collapse, CollapseItem } from 'vant';
import 'vant/lib/collapse/style';
import 'vant/lib/collapse-item/style';
export default {
props: ['bplist'],
components: {
Collapse, CollapseItem
},
data() {
return {
activeNames: [0],
formdata: [],
}
},
created() {
this.createForm()
},
methods: {
factory(arr) {
// 接收二维数组,产生 formdata
if (arr.length) {
arr.forEach(ele => {
let [title, prop, type] = ele
this.formdata.push({
title: title || '',
prop: prop || '',
type: type || 'text'
})
});
}
},
createForm() {
let formArr = [
['商业伙伴编码', 'bp_id_n', 'text'],
['商业伙伴名称', 'bp_name', 'text'],
['证件号码', 'id_card_no', 'text'],
['联系电话', 'cell_phone', 'text'],
['资产', 'capital', 'text'],
['商业伙伴角色', 'bp_category_n', 'text'],
['征信授权签约状态', 'confirm_status', 'text'],
['征信签约顺序', 'sign_position', 'text'],
['合同签约状态', 'car_confirm_status', 'text'],
['合同签约顺序', 'contract_sign_position', 'text'],
]
this.factory(formArr)
}
}
}
</script>
<style lang="less" scoped></style>
\ No newline at end of file
<!-- 商务方案 -->
<template>
<div>
<Collapse v-model="activeNames" v-if="planData.length">
<CollapseItem v-for="(p, pi) of planData" :title="p.product_plan_id_n" :key="p.quotation_id" :name="pi">
<list-item :item-height="44">
<item v-for="(ele, i) of formdata" :key="ele.title">
<div slot="name" class="font-color">{{ ele.title }}</div>
<span slot="content" v-if="ele.type == 'currency'">{{ currency(planData[pi][ele.prop]) }}</span>
<span slot="content" v-else-if="ele.type == 'rate'">{{ toPercent(planData[pi][ele.prop]) }}</span>
<span slot="content" v-else="ele.type == 'text'">{{ planData[pi][ele.prop] }}</span>
</item>
</list-item>
<Cell v-if="editFlag || showFlag" :value="p.repurchase_flag_n" :required="editFlag" :is-link="editFlag" title="合同类型" placeholder="请选择" @click="showPicker(1,pi)" />
<Cell v-if="editFlag || showFlag" :value="p.rent_invoice_type_n" :required="editFlag" :is-link="editFlag" title="开票类型" placeholder="请选择" @click="showPicker(0,pi)"/>
<!-- 查看还款计划 -->
<router-link :to="toPath(p.cash_lists, p)">查看还款计划</router-link>
</CollapseItem>
</Collapse>
<ActionSheet v-model="picker_show" :actions="actions" :title="actionTitle" :close-on-click-action="true" :closeable="false" @select="onSelect" />
<div class="foot-bottom" v-if="editFlag">
<button class="success" @click="save">保存</button>
</div>
</div>
</template>
<script>
import { Collapse, CollapseItem, Cell, ActionSheet } from 'vant'
import 'vant/lib/collapse/style'
import 'vant/lib/collapse-item/style'
import 'vant/lib/action-sheet/style'
export default {
props: ['planData','editFlag','showFlag'],
components: {
Collapse, CollapseItem, Cell, ActionSheet},
data () {
return {
activeNames: [0],
formdata: [],
actions: [], // 下拉框
contractType: [], // 合同类型下拉框
ticketType: [], // 开票类型下拉框
picker_show: false,
now_location: '',
now_nodeName: '',
actionTitle: '',
}
},
created () {
this.createForm()
this.getDropBox()
},
methods: {
async save () {
let flag = false
this.planData.map(item => {
if (!item.repurchase_flag && !item.rent_invoice_type) {
flag = true
}
})
if (flag) {
hlsPopup.showLongCenter('请将必填字段填写完整')
return
}
let url = process.env.basePath + 'prj_wfl_quotation_save'
let param = {
'master': {
quotation_lists: this.planData,
},
}
console.log(param)
hlsPopup.showLoading('请稍候')
let res = await this.$post(url, param)
this.hlsPopup.hideLoading()
if (res.result === 'S') {
hlsPopup.showLongCenter('保存成功')
} else {
hlsPopup.showLongCenter('保存失败')
}
},
onSelect (value) {
let val = value.name
if (this.now_nodeName === 'repurchase_flag') { // 合同类型
this.planData[this.now_location].repurchase_flag_n = val
let arr = this.contractType.filter(item => item.code_name === val)
this.planData[this.now_location].repurchase_flag = arr[0].code
}
if (this.now_nodeName === 'rent_invoice_type') { // 开票类型
this.planData[this.now_location].rent_invoice_type_n = val
let arr = this.ticketType.filter(item => item.code_name === val)
this.planData[this.now_location].rent_invoice_type = arr[0].code
}
},
showPicker (flag, index) {
if (!this.editFlag) return
if (flag) {
this.actions = this.contractType.map(item => ({name: item.code_name}))
this.now_nodeName = 'repurchase_flag'
this.actionTitle = '选择合同类型'
} else {
this.now_nodeName = 'rent_invoice_type'
this.actions = this.ticketType.map(item => ({name: item.code_name}))
this.actionTitle = '选择开票类型'
}
this.now_location = index
this.picker_show = true
},
// 下拉框数据获取
async getDropBox () {
let url = process.env.basePath + 'app_get_syscode'
let param = {
'a': 'PRJ501A.REPURCHASE_FLAG',
'bbbbb': 'PRJ501A.RENT_INVOICE_TYPE',
}
hlsPopup.showLoading('请稍候')
let res = await this.$post(url, param)
this.hlsPopup.hideLoading()
if (res.return_status === 'S') {
this.contractType = res.a
this.ticketType = res.bbbbb
}
},
toPath(cash_lists, p) {
let headInfo = JSON.stringify({
lease_times: p.lease_times,
financing_num: p.financing_num,
lease_charge: p.lease_charge,
down_payment: p.down_payment,
deposit: p.deposit
})
return { name: 'financingApplyFinancing', params: { cash_lists: JSON.stringify(cash_lists), headInfo } }
},
factory(arr) {
// 接收二维数组,产生 formdata
if (arr.length) {
arr.forEach(ele => {
let [title, prop, type] = ele
this.formdata.push({
title: title || '',
prop: prop || '',
type: type || 'text'
})
});
}
},
createForm() {
let formArr = [
['商务政策', 'product_plan_id_n', 'text'],
['数量', 'product_num', 'text'],
['首付款比例', 'down_payment_ratio', 'rate'],
['首付款(单台)', 'down_payment', 'currency'],
['产品名称', 'division_n', 'text'],
['单价设备', 'equip_price', 'currency'],
['保证金比例(%)', 'deposit_ratio', 'rate'],
['保证金(单台)', 'deposit', 'currency'],
['设备型号', 'product_id_n', 'text'],
['合同金额', 'total_price', 'currency'],
['手续费(%)', 'lease_charge_ratio', 'rate'],
['手续费(单台)', 'lease_charge', 'currency'],
['首期租金付款日期', 'lease_start_date', 'text'],
['租赁利率', 'int_rate', 'rate'],
['管理费(单台)', 'management_money', 'currency'],
['首付款合计', 'first_pay', 'currency'],
['保证金抵扣方式', 'deposit_deduction_n', 'text'],
['还款周期', 'annual_pay_times_n', 'text'],
['名义货价(单台)', 'residual_value', 'currency'],
['每期还款', 'per_repay_num', 'currency'],
['支付方式', 'pay_type_n', 'text'],
['报价方式', 'price_list_n', 'text'],
['GPS费金额', 'gps_fee', 'currency'],
['融资金额', 'financing_num', 'currency'],
['手续费政策', 'handling_policy_n', 'text'],
['租赁期数', 'lease_times', 'text'],
['保险押金', 'insurance_fee', 'currency'],
['利息总额', 'total_interest', 'currency'],
['逾期日利率', 'penalty_rate', 'rate'],
['首x期-起始期', 'lease_times_x_f', 'text'],
['首x期-截至期', 'lease_times_x', 'text'],
['租金总额', 'total_rental_sum', 'currency'],
['冬歇/雨歇起始月份', 'fallow_date_f', 'text'],
['冬歇/雨歇结束月份', 'fallow_date_t', 'text'],
]
this.factory(formArr)
},
currency(num, dotNum = 2) {
if (num === null || num === undefined || isNaN(+num)) return num;
return (+num).toLocaleString("en-US", { style: "decimal", minimumFractionDigits: dotNum, maximumFractionDigits: dotNum });
},
toPercent(val, needSign = true, dotNum = 2) {
if (!val || isNaN(+val)) return '0.00%';
let res = (+val).toLocaleString("zh-CN", { style: "percent", minimumFractionDigits: dotNum });
return needSign ? res : res.replace('%', '');
}
}
}
</script>
<style lang="less" scoped>
/deep/ .van-cell{
background: none !important;
}
/deep/ .van-cell__title {
color: #333333 !important
}
</style>
\ No newline at end of file
<!-- 销售 -->
<template>
<list-item :item-height="44">
<item v-for="(ele, i) of formdata" :key="ele.title">
<div slot="name" class="font-color">{{ ele.title }}</div>
<span slot="content" v-if="ele.type == 'currency'">{{ lesseeData[ele.prop] || currency }}</span>
<span slot="content" v-else="ele.type == 'text'">{{ lesseeData[ele.prop] }}</span>
</item>
</list-item>
</template>
<script>
export default {
props: ["lesseeData"],
data() {
return {
formdata: []
}
},
created() {
this.createForm()
},
methods: {
factory(arr) {
// 接收二维数组,产生 formdata
if (arr.length) {
arr.forEach(ele => {
let [title, prop, type] = ele
this.formdata.push({
title: title || '',
prop: prop || 'fdf',
type: type || 'text'
})
});
}
},
createForm() {
let formArr = [
['办事处', 'office_id_n', 'text'],
['主机厂', 'factory_n', 'text'],
['经销商', 'bp_id_agent_n', 'text'],
['业务类别', 'business_type_n', 'text'],
['申请编号', 'project_number', 'text'],
['项目名称', 'project_name', 'text'],
['签约日期', 'sale_date', 'text'],
['主机厂业务员', 'manu_manager', 'text'],
['业务经理', 'employee_id_n', 'text'],
['销售人员', 'bp_user_id_n', 'text'],
['销售人员手机', 'bp_user_id_phone', 'text'],
]
this.factory(formArr)
}
}
}
</script>
<style lang="less" scoped></style>
\ No newline at end of file
<template>
<h-view id="contract-details" class="public-style">
<h-header :proportion="[5, 1, 1]" class="bar-custom">
<div slot="left" class="h-header-btn">
<img src="@/assets/userBind/arrow.png" @click="$routeGo()">
<span>融租申请审批明细</span>
</div>
</h-header>
<h-content style="overflow-y: auto;">
<!-- 审批历史 -->
<div class="history" :class="[history_Coll ? 'history_active' : '']" @click="triggerHistory">
<History :isOpen="history_Coll" :historyData="historyData"></History>
</div>
<!-- 销售信息折叠 -->
<Collapse v-model="collActiveTab">
<CollapseItem title="销售信息" name="1">
<Sale :lesseeData="lesseeData"></Sale>
</CollapseItem>
</Collapse>
<!-- tab 页 -->
<div class="tab-style z100">
<div :class="{ 'done': tabNum === 1, 'undone': tabNum !== 1 }" @click="tabNum = 1;">
承租人
</div>
<div :class="{ 'done': tabNum === 2, 'undone': tabNum !== 2 }" @click="tabNum = 2;">
商务方案
</div>
<div :class="{ 'done': tabNum === 3, 'undone': tabNum !== 3 }" @click="tabNum = 3;">
商业伙伴
</div>
<div :class="{ 'done': tabNum === 4, 'undone': tabNum !== 4 }" @click="tabNum = 4;">
附件
</div>
</div>
<div v-if="tabNum === 1" class="z100">
<Lessee :lesseeData="lesseeData"></Lessee>
</div>
<div v-if="tabNum === 2" class="z100">
<Plan :planData="planData" :editFlag="isEditType" :showFlag="isShowType"></Plan>
</div>
<div v-if="tabNum === 3" class="z100">
<Partner :bplist="bplist"></Partner>
</div>
<div v-if="tabNum === 4" class="z100">
<Appendix :appendixData="appendixData" @upData="getData"></Appendix>
<div class="approveBottom">
<span> 审批意见 </span>
<textarea v-model="confirm_note" cols="8" rows="5" placeholder="请输入" />
</div>
<div class="foot-bottom" v-show="isTodo">
<button class="success" @click="approv('1')">通 过</button>
<button class="refused" @click="approv('2')">拒 绝</button>
</div>
</div>
</h-content>
</h-view>
</template>
<script>
import { Collapse, CollapseItem } from 'vant';
import 'vant/lib/collapse/style';
import 'vant/lib/collapse-item/style';
import Plan from './components/plan.vue'
import Sale from './components/Sale.vue'
import Partner from './components/Partner.vue'
import Appendix from './components/Appendix.vue'
import Lessee from './components/Lessee.vue'
import History from './components/History.vue'
import axios from 'axios'
export default {
components: {
Plan,
Collapse,
CollapseItem,
Sale,
Partner,
Appendix,
Lessee,
History
},
data() {
return {
tabNum: 1,
collActiveTab: ['2'],
history_Coll: false,
confirm_note: '',
bplist: [], //商业伙伴信息
lesseeData: {}, //承租人, 销售信息
planData: [], // 商务方案
historyData: [],
appendixData: [],
isTodo: true,
isEditType: false, // 30节点可编辑合同类型、开票类型
isShowType: false, // 75节点可见合同类型、开票类型
}
},
beforeRouteEnter(to, from, next) {
next(vm => {
})
},
mounted() {
console.log(this.$route.params)
this.isEditType = this.$route.params.node_sequence_num === '30'
this.isShowType = this.$route.params.node_sequence_num === '75'
this.isTodo = this.$route.params.type === 'todo'
this.getHistory()
this.getData()
},
methods: {
getData() {
let project_id = this.$route.params.document_id
this.hlsPopup.showLoading('请稍候')
let url = $config.basePath + 'prj_project_info_query'
let param = { project_id }
this.hlsHttp.post(url, param).then((res) => {
this.hlsPopup.hideLoading()
if (res.result === 'S') {
this.bplist = res.bp_lists
this.lesseeData = res.info
this.planData = res.quotation_lists
this.appendixData = (res.cdd_lists || []).map(item => {
let attachArr = []
item.attach_file_name && item.attach_file_name.split(';;').forEach(ele => {
let attach = ele.split('--')
attach[0] && attachArr.push({ fileName: attach[0], attachId: attach[1] })
})
return { ...item, attachArr }
})
} else {
hlsPopup.showLongCenter('获取工作流信息失败')
setTimeout(() => {
this.$router.back()
}, 2000);
}
})
},
getHistory() {
this.historyData = this.$route.params.approve_history_lists.reverse()
},
triggerHistory() {
this.history_Coll = !this.history_Coll
},
approv(action_type) {
if (this.isEditType) {
let flag = false
this.planData.map(item => {
if (!item.repurchase_flag && !item.rent_invoice_type) {
flag = true
}
})
if (flag) {
hlsPopup.showLongCenter('请将必填字段填写完整')
return
}
}
let params = this.$route.params
let param = {
master: {
record_id: params.record_id,
action_type: action_type,
user_id: params.user_id,
comment_text: this.confirm_note,
},
}
console.log(process.env.basePath);
let url = process.env.basePath + (action_type === '1' ? 'action_agree' : 'action_refuse')
console.log(url);
this.hlsPopup.showLoading('请稍候')
this.hlsHttp.post(url, param).then((res) => {
this.hlsPopup.hideLoading()
this.hlsPopup.showLongCenter(res.message)
if (res.result === 'S') {
setTimeout(() => {
this.$router.back()
}, 2000);
}
})
},
},
}
</script>
<style lang="less" rel="stylesheet">
#contract-details {
.bar-custom {
background-color: #02459a;
}
.history {
height: 50px;
background-color: #02459a;
position: relative;
pointer-events: none;
padding: 0 0 30px;
&::after {
background: url('../../assets/userBind/arrow-bottom.png') no-repeat;
background-size: 15px;
background-position: center;
content: " ";
display: block;
position: absolute;
height: 20px;
bottom: 3px;
width: 100%;
pointer-events: auto;
}
}
.history.history_active {
height: auto;
min-height: 100px;
&::after {
transform: rotate(180deg);
}
}
.tab-style {
display: flex;
justify-content: center;
padding-top: 12px;
text-align: center;
padding-bottom: 8px;
align-items: center;
box-shadow: 0 2px 3px 0 rgba(220, 220, 221, 0.5);
div {
display: block;
height: 32px;
width: 172px;
font-family: PingFangSC-Semibold;
font-size: 14px;
letter-spacing: 0.43px;
margin: 0 4px;
line-height: 32px;
color: #02459a;
}
.undone {}
.done {
border-bottom: 2px solid #02459a;
}
img {
width: 16px;
display: block;
float: left;
margin: 8px 5px 0 20px;
}
span:nth-of-type(2) {
margin-left: 7px;
}
}
.van-cell__title {
color: #02459a
}
.van-cell {
background-color: #f6f6f6;
}
.van-icon-arrow::before {
color: #02459a
}
.z100 {
z-index: 100;
}
.approveBottom {
width: 343px;
margin: 0 auto;
span {
display: block;
width: 100%;
font-family: PingFangSC-Semibold;
font-size: 15px;
color: #00469c;
height: 21px;
line-height: 21px;
margin: 16px 0;
img {
float: right;
}
}
textarea {
width: 343px;
border-radius: 2px;
padding: 10px;
}
span::after {
content: "";
display: block;
position: relative;
left: 70px;
top: -17px;
width: 14px;
height: 14px;
background: url("../../assets/intoApproval/approv.png");
background-size: 14px 14px;
}
}
.foot-bottom {
box-sizing: border-box;
display: flex;
justify-content: space-around;
border-radius: 20px;
background-color: #fff;
margin: 10px 15px;
padding: 10px;
button {
height: 40px;
padding: 10px 1rem;
border-radius: 10px;
}
.success {
background-color: #02459a;
border: 1px solid #02459a;
color: #fff
}
.refused {
background-color: #fff;
border: 1px solid #02459a;
color: #02459a
}
.back {
background-color: #ff5461;
border: 1px solid #ff5461;
color: #fff
}
}
}
</style>
<!-- 融资明细 -->
<template>
<h-view id="financing-apply-financing" class="public-style">
<h-header :proportion="[5, 1, 1]" class="bar-custom">
<div slot="left" class="h-header-btn">
<img src="@/assets/userBind/arrow.png" @click="$routeGo()">
<span>融资明细</span>
</div>
</h-header>
<h-content>
<div class="header">
<div class="header-title">
<p class="key">融资金额</p>
<p class="value">{{ currency(currencyObj.financing_num) }}</p>
<div class="times">
{{ currencyObj.lease_times }}
</div>
</div>
<div class="header-bottom">
<table>
<tr class="key">
<td>保证金</td>
<td>首付款</td>
<td>手续费</td>
</tr>
<tr class="secend_value">
<td>{{ currency(currencyObj.deposit) }}</td>
<td>{{ currency(currencyObj.down_payment) }}</td>
<td>{{ currency(currencyObj.lease_charge) }}</td>
</tr>
</table>
</div>
</div>
<div class="list">
<p>还款计划</p>
<div class="plan-list">
<div class="plan_item" v-for="ele, i in currencyObj.cashFlow">
<div class="space" style="flex: 1 0 15%">
<div class="item-times">{{ ele.times }}</div>
<div class="item-date">{{ getYear(ele.due_date) }}</div>
<div style="margin-top: 0;">{{ getDate(ele.due_date) }}</div>
</div>
<div class="space">
<div>本金 ¥ {{ currency(ele.principal) }}</div>
<div>租金 ¥ {{ currency(ele.rental) }}</div>
</div>
<div class="space">
<div>利息 ¥ {{ currency(ele.interest) }}</div>
</div>
</div>
</div>
</div>
</h-content>
</h-view>
</template>
<script>
export default {
prop: [],
data() {
return {
currencyObj: {
financing_num: '',
deposit: '',
down_payment: '',
lease_charge: '',
lease_times: 12,
cashFlow: [
{
}
]
}
}
},
mounted() {
let headInfo = JSON.parse(this.$route.params.headInfo)
this.currencyObj = { ...this.currencyObj, ...headInfo }
this.currencyObj.cashFlow = JSON.parse(this.$route.params.cash_lists)
},
methods: {
currency(num, dotNum = 2) {
if (num === null || num === undefined || isNaN(+num)) return num;
return (+num).toLocaleString("en-US", { style: "decimal", minimumFractionDigits: dotNum, maximumFractionDigits: dotNum });
},
getYear(date) {
if (!date) return
return date.split('-')[0]
},
getDate(date) {
if (!date) return
let list = date.split('-')
return list[1] + '-' + list[2]
}
}
}
</script>
<style lang="less" scoped>
@bc: #3079d8;
.header {
height: 19vh;
width: 100%;
padding-left: 10vw;
background-color: #02459a;
color: #fff
}
.list {
font-size: 14px;
display: flex;
flex-direction: column;
height: calc(100% - 25vh);
background-color: #fff;
border-top-left-radius: 20px;
border-top-right-radius: 20px;
box-sizing: border-box;
padding: 10px 15px 0 15px;
color: black;
overflow: hidden;
p {
margin-bottom: 3px;
color: #02459a;
font-size: 16px;
}
}
.plan-list {
flex: 1 0 auto;
height: 80%;
overflow-y: auto;
}
.plan-footer {
flex: 0 1 50px;
display: flex;
justify-content: center;
}
.header-title {
position: relative;
height: 11vh;
display: flex;
flex-direction: column;
}
.key {
line-height: 4vh;
}
.value {
font-size: 23px;
font-weight: 600;
line-height: 4vh;
}
.times {
position: absolute;
right: 10vw;
top: 2vw;
height: 5vh;
width: 7vh;
background-color: #fff;
border-radius: 5px;
font-weight: 600;
color: @bc;
line-height: 5.5vh;
text-align: center;
font-size: 14px;
}
.times::after {
content: '';
display: block;
width: 20px;
height: 20px;
background-image: linear-gradient(143deg, #fff 0%, #fff 50%, transparent 50%);
transform: translateY(-10px);
}
table {
width: 100%;
}
.secend_value {
font-weight: 600;
}
.bar-custom {
background-color: #02459a;
}
.plan_item {
height: 65px;
background-color: #f6f0e8;
width: 100%;
border-radius: 5px;
display: flex;
justify-content: space-around;
flex-wrap: wrap;
padding: 5px;
color: #7f7f7f;
div {
flex: 1 0 33%;
height: 20px;
}
.item-times {
background-color: #f9dab2;
padding-right: 5px;
width: 36px;
line-height: 18px;
}
.item-date {
flex: 0 0 auto;
padding-right: 5px;
margin: 0;
line-height: 18px;
}
}
.plan_item+.plan_item {
margin-top: 10px;
}
.space div+div {
margin-top: 15px;
}
</style>
This diff is collapsed.
......@@ -94,6 +94,15 @@
<img src="@/assets/functionCenter/in@2x.png" alt="">
</div>
</div>
<!-- <div class="info-content">
<div class="add-name">
<img src="@/assets/functionCenter/con-sign@2x.png" alt="">
<div class="name-title">融资申请审批流</div>
</div>
<div class="add-content" @click="goFinancingApply">
<img src="@/assets/functionCenter/in@2x.png" alt="">
</div>
</div> -->
</div>
<div class="fun-item-after">
<div class="userInfo"> 租后业务</div>
......@@ -133,6 +142,24 @@
<img src="@/assets/functionCenter/in@2x.png" alt="">
</div>
</div>
<!-- <div class="info-content">
<div class="add-name">
<img src="@/assets/functionCenter/con-que@2x.png" alt="">
<div class="name-title">逾期信息查询</div>
</div>
<div class="add-content" @click="goOvertimeList">
<img src="@/assets/functionCenter/in@2x.png" alt="">
</div>
</div>
<div class="info-content">
<div class="add-name">
<img src="@/assets/functionCenter/con-que@2x.png" alt="">
<div class="name-title">延期申请</div>
</div>
<div class="add-content" @click="goOvertimeApply">
<img src="@/assets/functionCenter/in@2x.png" alt="">
</div>
</div> -->
</div>
</h-content>
......@@ -348,6 +375,32 @@ export default {
hlsPopup.showLongCenter('请先进行用户绑定')
}
},
goOvertimeList(e) {
let vm = this
if (this.bp_id) {
vm.$router.push({
name: 'overTimeQueryList',
params: {
bp_type: e,
},
})
} else {
hlsPopup.showLongCenter('请先进行用户绑定')
}
},
goOvertimeApply(e) {
let vm = this
if (this.bp_id) {
vm.$router.push({
name: 'overTimeApplyList',
params: {
bp_type: e,
},
})
} else {
hlsPopup.showLongCenter('请先进行用户绑定')
}
},
// 进入合同签订
goCarConfirm () {
let vm = this
......@@ -383,6 +436,19 @@ export default {
hlsPopup.showLongCenter('请先进行用户绑定')
}
},
// // 融资申请审批流
// goFinancingApply () {
// let vm = this
// if (this.bp_id) {
// if (vm.user_bp_type === 'MANAGER') {
// this.$router.push({name: 'financingApplyList'})
// } else {
// hlsPopup.showLongCenter('您当前角色非业务经理,无法使用该功能!')
// }
// } else {
// hlsPopup.showLongCenter('请先进行用户绑定')
// }
// },
goInvoice () {
let vm = this
if (this.bp_id) {
......@@ -502,13 +568,13 @@ export default {
},
todoList () {
if (this.bp_id) {
if (this.user_bp_type !== 'OFFICE' && this.user_bp_type !== 'AGENT') {
hlsPopup.showLongCenter('仅经销商/办事处业务员角色可使用该功能!')
} else {
// if (this.user_bp_type !== 'OFFICE' && this.user_bp_type !== 'AGENT') {
// hlsPopup.showLongCenter('仅经销商/办事处业务员角色可使用该功能!')
// } else {
this.$router.push({
name: 'ToDoList',
})
}
// }
} else {
hlsPopup.showLongCenter('请先进行用户绑定')
}
......@@ -723,6 +789,7 @@ export default {
border-radius: 0.4rem;
width: 80%;
margin-left: 10%;
// margin-top: 10.8rem;
margin-top: 9.8rem;
margin-bottom: 1.5rem;
// position: absolute;
......
This diff is collapsed.
......@@ -36,8 +36,7 @@
</h-button>
<h-button class="button-class" type="primary" @click.native="showTime('YYYY-MM-DD HH')">showTime YYYY-MM-DD HH
</h-button>
<h-button class="button-class" type="primary" @click.native="showTime('YYYY-MM-DD HH:mm')">showTime YYYY-MM-DD
HH:mm
<h-button class="button-class" type="primary" @click.native="showTime('YYYY-MM-DD HH:mm')">showTime YYYY-MM-DD HH:mm
</h-button>
<h-button class="button-class" type="primary" @click.native="showBigPicture">showBigPicture</h-button>
<h-button class="button-class" type="primary" @click.native="selectListOne">selectList 普通下拉框</h-button>
......
......@@ -151,11 +151,11 @@ export default {
vm.$router.push('/choose-user')
window.localStorage.setItem('app_user_id', res.info.app_user_id)
// vm.$router.push('tab')
vm.$router.push('/choose-user')
let tagOption = {
'username': isNaN(Number(vm.username)) ? '11111111111' : vm.username,
}
let phone = isNaN(Number(vm.username)) ? '11111111111' : vm.username
vm.Jpush._jpush_config(tagOption, phone)
} else {
......
......@@ -146,6 +146,8 @@
</template>
<script>
/* eslint-disable brace-style */
import roleSwitch from './role-switch-component'
import defaultImg from '../../assets/myInfo/1.png'
export default {
......@@ -600,15 +602,15 @@ export default {
}
},
hote_update_version (content, url) {
// hlsPopup.showConfirm({
// title: '版本更新',
// content: content,
// onConfirm: function (index) {
// if (index === 1) {
// hotpatch.updateNewVersion(url)
// }
// },
// })
hlsPopup.showConfirm({
title: '版本更新',
content: content,
onConfirm: function (index) {
if (index === 1) {
hotpatch.updateNewVersion(url)
}
},
})
},
logOut () {
let vm = this
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -316,7 +316,6 @@
<div v-if="baseInfo.bp_type === 'TENANT' || baseInfo.bp_type === 'GUTA'">
<div
v-for="(list, index) in cddItemList"
:key="index"
class="card"
>
......@@ -822,7 +821,7 @@ export default {
vm.idCardBackUrlFlag = true
vm.delete_pic_to_ocr(vm.idCardBackAttachmentId)// 先删除之前识别的图片
// 身份证反面图片已修改,重新上传
var list = []
list = []
let obj = {
pkvalue: vm.idCardBackCheck_id,
source_type: 'PRJ_CDD_ITEM_CHECK',
......@@ -841,7 +840,7 @@ export default {
vm.idCardFrontSpUrlFlag = true
vm.delete_pic_to_ocr(vm.idCardFrontSpAttachmentId)// 先删除之前识别的图片
// 配偶身份证正面图片已修改,重新上传
var list = []
list = []
let obj = {
pkvalue: vm.idCardFrontSpCheck_id,
source_type: 'PRJ_CDD_ITEM_CHECK',
......@@ -860,7 +859,7 @@ export default {
vm.idCardBackSpUrlFlag = true
vm.delete_pic_to_ocr(vm.idCardBackSpAttachmentId)// 先删除之前识别的图片
// 配偶身份证背面图片已修改,重新上传
var list = []
list = []
let obj = {
pkvalue: vm.idCardBackSpCheck_id,
source_type: 'PRJ_CDD_ITEM_CHECK',
......@@ -1270,7 +1269,7 @@ export default {
let result = res.result.words_result
if (cardType === 'idCard') {
vm.baseInfo.id_card_date_from = result.签发日期.words
if (result.失效日期.words.indexOf('长期') != -1) {
if (result.失效日期.words.indexOf('长期') !== -1) {
hlsPopup.showPopup({
title: '提示',
content: `检测到您的身份证为长期有效,系统自动置为【9999-12-31】`,
......@@ -1282,7 +1281,7 @@ export default {
}
} else {
vm.baseInfo.id_card_date_from_sp = result.签发日期.words
if (result.失效日期.words.indexOf('长期') != -1) {
if (result.失效日期.words.indexOf('长期') !== -1) {
hlsPopup.showPopup({
title: '提示',
content: `检测到您的身份证为长期有效,系统自动置为【9999-12-31】`,
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
<!DOCTYPE html><html><head><meta charset=utf-8><meta name=viewport content="initial-scale=1,maximum-scale=1,minimum-scale=1,user-scalable=no,width=device-width,viewport-fit=cover"><meta name=format-detection content="telephone=no"><meta name=format-detection content="email=no"><meta name=apple-mobile-web-app-capable content=yes><meta name=apple-mobile-web-app-status-bar-style content=black><script type=text/javascript src=./static/vuePlatform.js></script><script type=text/javascript src=./static/prototype.js></script><script type=text/javascript src=./cordova.js></script><script type=text/javascript src="http://api.map.baidu.com/api?v=2.0&ak=Eoo0EtfjYCdAy7r8D19gZ0vMojdZpHqU"></script><title>徐工金服</title><link href=./static/css/app.fb52dd271f35e6cb942abb94eb5f18bb.css rel=stylesheet></head><body><div id=app-box></div><script type=text/javascript src=./static/js/manifest.16dc3c74f4e0c838ce1f.js></script><script type=text/javascript src=./static/js/vendor.a2bd9868e7885d7ce8da.js></script><script type=text/javascript src=./static/js/app.279bb6618e94708c8fd3.js></script></body></html>
\ No newline at end of file
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment