From 22271e641e4505ba906c3770905b7e84e3ad8d85 Mon Sep 17 00:00:00 2001
From: MrShi <1878285526@qq.com>
Date: 星期二, 02 四月 2024 17:05:57 +0800
Subject: [PATCH] mrshi
---
company/src/components/business/OperaCompanyDescWindow.vue | 309 ++++++++++++++++++++++++++-------------------------
1 files changed, 158 insertions(+), 151 deletions(-)
diff --git a/company/src/components/business/OperaCompanyDescWindow.vue b/company/src/components/business/OperaCompanyDescWindow.vue
index c647036..c17dd6d 100644
--- a/company/src/components/business/OperaCompanyDescWindow.vue
+++ b/company/src/components/business/OperaCompanyDescWindow.vue
@@ -60,7 +60,7 @@
<div class="info_list_item_val">{{form.invoiceEmail || '-'}}</div>
</div>
<div class="info_list_item" style="width: 100%;">
- <div class="info_list_item_label">鐢靛瓙鍙戠エ鎺ユ敹鍦板潃锛�</div>
+ <div class="info_list_item_label">绾歌川鍙戠エ鎺ユ敹鍦板潃锛�</div>
<div class="info_list_item_val">{{form.invoiceAddr || '-'}}</div>
</div>
</div>
@@ -180,156 +180,163 @@
</template>
<script>
- import BaseOpera from '@/components/base/BaseOpera'
- import GlobalWindow from '@/components/common/GlobalWindow'
- import OperaCompanyWindow from '@/components/business/OperaCompanyWindow'
- import modification from '@/components/business/modification'
- import { getById, updatePhone } from '@/api/business/company'
- import { listForCompany } from '@/api/business/solutions'
- import { sendSms } from '@/api/business/smsEmail'
- export default {
- name: 'OperaCompanyDescWindow',
- extends: BaseOpera,
- components: { GlobalWindow, OperaCompanyWindow, modification },
- data () {
- return {
- ruleForm: {
- phone: '',
- code: ''
- },
- num: 0,
- timer: null,
- // 琛ㄥ崟鏁版嵁
- form: {},
- phone: '',
- code: '',
- visiblePhone: false,
- options: [],
- tableData: []
- }
- },
- created () {
- this.config({
- api: '/business/company',
- 'field.id': 'id'
- })
- },
- methods: {
- close() {
- this.visiblePhone = false
- this.phone = ''
- this.code = ''
- clearInterval(this.timer)
- this.num = 0
- },
- updatePhoneEvent() {
- if (!this.phone) {
- this.$message.warning('璇疯緭鍏ユ墜鏈哄彿')
- return
- }
- if (!this.code) {
- this.$message.warning('璇疯緭鍏ラ獙璇佺爜')
- return
- }
- updatePhone({
- id: this.form.id,
- captche: this.code,
- phone: this.phone
- }).then(res => {
- this.form.phone = JSON.parse(JSON.stringify(this.phone))
- this.$message.success('鎿嶄綔鎴愬姛')
- this.visiblePhone = false
- this.phone = ''
- this.code = ''
- clearInterval(this.timer)
- this.num = 0
- })
- },
- send() {
- if (!this.phone) {
- this.$message.warning('璇疯緭鍏ユ墜鏈哄彿')
- return
- }
- sendSms({ phone: this.phone })
- .then(res => {
- this.num = 60
- this.setTime()
- })
- },
- setTime() {
- this.timer = setInterval(() => {
- this.num -= 1
- if (this.num === 0) {
- clearInterval(this.timer)
- this.num = 0
- }
- }, 1000)
- },
- open (title, target) {
- const that = this;
- this.title = title
- this.phone = ''
- this.code = ''
- clearInterval(this.timer)
- this.num = 0
- getById(target.id)
- .then(res => {
- this.form = res
- this.form.type = 1
-
- this.form.file = {
- imgurl: '',
- imgurlfull: ''
- }
- this.form.file1 = {
- imgurl: '',
- imgurlfull: ''
- }
- this.form.file2 = {
- imgurl: '',
- imgurlfull: ''
- }
- this.form.file3 = {
- imgurl: '',
- imgurlfull: ''
- }
-
- this.form.file.imgurl = res.businessImg.fileurl
- this.form.file.imgurlfull = res.businessImg.fileurlFull
- this.form.file1.imgurl = res.idcardImgList[0].fileurl
- this.form.file1.imgurlfull = res.idcardImgList[0].fileurlFull
- this.form.file2.imgurl = res.idcardImgList[1].fileurl
- this.form.file2.imgurlfull = res.idcardImgList[1].fileurlFull
- this.form.file3.imgurl = res.signImg.fileurl
- this.form.file3.imgurlfull = res.signImg.fileurlFull
-
- listForCompany({ companyId: target.id })
- .then(resa => {
- that.form.solutionList = resa.map(item => {
- return {
- solutionBaseId: item.solutionBaseId,
- canAdd: item.canAdd,
- canReduce: item.canReduce
- }
- })
- that.form.solutionListName = resa.map(item => {
- return {
- solutionName: item.solutionName,
- canAdd: item.canAdd,
- canReduce: item.canReduce
- }
- })
- console.log(that.form)
- that.visible = true
- })
- })
- },
- callback() {
- this.$emit('success')
- this.visible = false
- }
- }
+import BaseOpera from '@/components/base/BaseOpera'
+import GlobalWindow from '@/components/common/GlobalWindow'
+import OperaCompanyWindow from '@/components/business/OperaCompanyWindow'
+import modification from '@/components/business/modification'
+import { getById, updatePhone } from '@/api/business/company'
+import { listForCompany } from '@/api/business/solutions'
+import { sendSms } from '@/api/business/smsEmail'
+export default {
+ name: 'OperaCompanyDescWindow',
+ extends: BaseOpera,
+ components: { GlobalWindow, OperaCompanyWindow, modification },
+ data () {
+ return {
+ ruleForm: {
+ phone: '',
+ code: ''
+ },
+ dataId: null,
+ num: 0,
+ timer: null,
+ // 琛ㄥ崟鏁版嵁
+ form: {},
+ phone: '',
+ code: '',
+ visiblePhone: false,
+ options: [],
+ tableData: []
}
+ },
+ created () {
+ this.config({
+ api: '/business/company',
+ 'field.id': 'id'
+ })
+ },
+ methods: {
+ close () {
+ this.visiblePhone = false
+ this.phone = ''
+ this.code = ''
+ clearInterval(this.timer)
+ this.num = 0
+ },
+ updatePhoneEvent () {
+ if (!this.phone) {
+ this.$message.warning('璇疯緭鍏ユ墜鏈哄彿')
+ return
+ }
+ if (!this.code) {
+ this.$message.warning('璇疯緭鍏ラ獙璇佺爜')
+ return
+ }
+ updatePhone({
+ id: this.form.id,
+ captche: this.code,
+ phone: this.phone
+ }).then(res => {
+ this.form.phone = JSON.parse(JSON.stringify(this.phone))
+ this.$message.success('鎿嶄綔鎴愬姛')
+ this.visiblePhone = false
+ this.phone = ''
+ this.code = ''
+ clearInterval(this.timer)
+ this.num = 0
+ })
+ },
+ send () {
+ if (!this.phone) {
+ this.$message.warning('璇疯緭鍏ユ墜鏈哄彿')
+ return
+ }
+ sendSms({ phone: this.phone })
+ .then(res => {
+ this.num = 60
+ this.setTime()
+ })
+ },
+ setTime () {
+ this.timer = setInterval(() => {
+ this.num -= 1
+ if (this.num === 0) {
+ clearInterval(this.timer)
+ this.num = 0
+ }
+ }, 1000)
+ },
+ open (title, target) {
+ const that = this
+ this.title = title
+ this.dataId = target.id
+ this.phone = ''
+ this.code = ''
+ clearInterval(this.timer)
+ this.num = 0
+ this.getDetail()
+ },
+ getDetail () {
+ var that =this
+ getById(this.dataId)
+ .then(res => {
+ this.form = res
+ this.form.type = 1
+
+ this.form.file = {
+ imgurl: '',
+ imgurlfull: ''
+ }
+ this.form.file1 = {
+ imgurl: '',
+ imgurlfull: ''
+ }
+ this.form.file2 = {
+ imgurl: '',
+ imgurlfull: ''
+ }
+ this.form.file3 = {
+ imgurl: '',
+ imgurlfull: ''
+ }
+
+ this.form.file.imgurl = res.businessImg.fileurl
+ this.form.file.imgurlfull = res.businessImg.fileurlFull
+ this.form.file1.imgurl = res.idcardImgList[0].fileurl
+ this.form.file1.imgurlfull = res.idcardImgList[0].fileurlFull
+ this.form.file2.imgurl = res.idcardImgList[1].fileurl
+ this.form.file2.imgurlfull = res.idcardImgList[1].fileurlFull
+ this.form.file3.imgurl = res.signImg.fileurl
+ this.form.file3.imgurlfull = res.signImg.fileurlFull
+
+ listForCompany({ companyId: this.dataId })
+ .then(resa => {
+ that.form.solutionList = resa.map(item => {
+ return {
+ solutionBaseId: item.solutionBaseId,
+ canAdd: item.canAdd,
+ canReduce: item.canReduce
+ }
+ })
+ that.form.solutionListName = resa.map(item => {
+ return {
+ solutionName: item.solutionName,
+ canAdd: item.canAdd,
+ canReduce: item.canReduce
+ }
+ })
+ console.log(that.form)
+ that.visible = true
+ })
+ })
+ },
+ callback () {
+ this.getDetail()
+ this.$emit('success')
+ // this.visible = false
+ }
+ }
+}
</script>
<style lang="scss" scoped>
@@ -394,7 +401,7 @@
align-items: start;
margin-bottom: 20px;
.info_list_item_label {
- width: 150px;
+ /*width: 150px;*/
flex-shrink: 0;
}
.info_list_item_val {
--
Gitblit v1.9.3