1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201 |
- <template>
- <div class="addintention">
- <div class="form">
- <uni-forms ref="baseForm" label-width="100%">
- <uni-forms-item label="项目/企业名称:">
- <!-- <uni-easyinput :disabled="form.createrName != createdBy" disabled v-model="form.name" placeholder="请输入"/>-->
- <uni-easyinput
- :disabled="formStatus"
- v-model="form.projectName"
- placeholder="请输入"
- />
- </uni-forms-item>
- <uni-forms-item label="项目简介:">
- <uni-easyinput
- :disabled="formStatus"
- type="textarea"
- class="bgcF9F9F9 height218rpx"
- v-model="form.projectInfo"
- placeholder="请输入"
- />
- </uni-forms-item>
- <uni-forms-item label="企业需求:">
- <uni-easyinput
- :disabled="formStatus"
- type="textarea"
- class="bgcF9F9F9 height218rpx"
- v-model="form.companyNeed"
- placeholder="请输入"
- />
- </uni-forms-item>
- <uni-forms-item label="项目/企业联系人:">
- <uni-easyinput
- :disabled="formStatus"
- v-model="form.projectManager"
- placeholder="请输入"
- />
- </uni-forms-item>
- <uni-forms-item label="联系电话:">
- <uni-easyinput
- :disabled="formStatus"
- v-model="form.managerPhone"
- @input="getNum"
- placeholder="请输入"
- />
- </uni-forms-item>
- </uni-forms>
- </div>
- <div class="form">
- <uni-forms ref="baseForm" :modelValue="form" label-width="100%">
- <uni-forms-item label="招商负责人:">
- <!-- <uni-easyinput
-
- v-model="form.createrName"
- placeholder="请输入"
- /> -->
- <!-- <van-picker
- :columns="userList"
- value-key="truename"
- v-show="userListPickerStatus"
- toolbar-position="bottom"
- /> -->
- <picker
- v-if="!formStatus"
- @change="getUser"
- range-key="truename"
- :range="userList"
- >
- <div class="userbox">
- {{ form.createrName }}
- </div>
- </picker>
- <div v-else class="userbox">
- {{ form.createrName }}
- </div>
- </uni-forms-item>
- <uni-forms-item label="所在部门:">
- <div class="userbox">
- {{ form.deptName }}
- </div>
- </uni-forms-item>
- </uni-forms>
- </div>
- <div class="list">
- <div class="project-column pdt32 pdl32 pdr32 border_bottom_ccc">
- <div
- class="pdb16 height50rpx chuzuborder lh50rpx disflex align_items_center"
- >
- <div class="lh50rpx">关联房源</div>
- <van-icon
- name="add"
- v-if="!formStatus"
- class="ml16"
- size="50rpx"
- color="#2527AA"
- @click="jumpChosseHouse('房源')"
- />
- </div>
- </div>
- <div
- class="list-row"
- v-if="fangyuanList.length != 0"
- v-for="(item, index) in fangyuanList"
- :key="item.id"
- >
- <div class="cell_1">
- <div class="width100 height50rpx mgb20">
- <div class="first_title float_left">
- {{ item.remark }}
- </div>
- </div>
- <div class="width100 height40rpx">
- <div class="second_title height40rpx">
- 预约日期:{{ item.createdAt }}
- </div>
- </div>
- <div class="width100 height40rpx">
- <div
- class="second_title height40rpx"
- v-if="item.reservationStatus == 7"
- >
- 状态:解锁
- </div>
- <div
- class="second_title height40rpx"
- v-if="item.reservationStatus == 2"
- >
- 状态:锁定
- </div>
- </div>
- <div class="width100 height40rpx">
- <div
- class="second_title height40rpx"
- style="display: flex; align-items: center"
- >
- <picker
- @change="getNeedDays($event, index, item.createdAt)"
- :range="needDaysList"
- range-key="text"
- >
- 锁定到期日期:{{ item.needDays ? item.needDays : "请选择" }}
- </picker>
- </div>
- </div>
- <div class="width100 height40rpx pdb16 border_bottom_ccc">
- <div class="second_title height40rpx">
- 解锁日期:{{ item.endTime ? item.endTime : "" }}
- </div>
- </div>
- <div class="button_list pdb20 pdt20">
- <div class="bottom_cell">
- <div
- class="button_row"
- @click="fangyuanListSplice(index)"
- v-if="item.reservationStatus != 7 && formStatus"
- >
- 解锁
- </div>
- <div
- class="disable-btn"
- @click="fangyuanListSplice(index)"
- v-if="item.reservationStatus == 7 && formStatus"
- >
- 解锁
- </div>
- </div>
- </div>
- </div>
- </div>
- </div>
- <div class="form" style="padding-bottom: 192rpx">
- <uni-forms ref="baseForm" :modelValue="form" label-width="100%">
- <uni-forms-item label="其它附件:">
- <van-button
- type="primary"
- size="small"
- @click="choosePDf()"
- style="margin-bottom: 15rpx"
- >文件选择</van-button
- >
- <div class="pdflist">
- <div
- class="pdflist-row"
- v-for="(item, index) in fileList"
- :key="item.url"
- @click="openFile(item.url)"
- >
- <div class="pdfname">{{ item.name }}</div>
- <van-icon
- name="clear"
- class="delete_icon"
- @click="uploadAddressExcelSplice(index)"
- />
- </div>
- </div>
- </uni-forms-item>
- </uni-forms>
- </div>
- <tki-tree
- ref="tkitree"
- :multiple="true"
- :range="range"
- :selectParent="true"
- :foldAll="true"
- rangeKey="name"
- idKey="id"
- @confirm="userSelectorConfirm"
- >
- </tki-tree>
- <select-dengjiyuan
- ref="selectDengjiyuan"
- :multiple="false"
- :range="range"
- :selectParent="false"
- :foldAll="true"
- rangeKey="name"
- idKey="id"
- @selectDengjiyuan="selectDengjiyuan"
- >
- </select-dengjiyuan>
- <select-dengjiren
- ref="selectXiangmanger"
- :multiple="true"
- :range="range"
- :selectParent="true"
- :foldAll="true"
- rangeKey="name"
- idKey="id"
- @xiangmudengji="xiangmudengji"
- >
- </select-dengjiren>
- <select-genzongdep
- ref="selectGenzongDep"
- :multiple="false"
- :range="range"
- :selectParent="false"
- :foldAll="true"
- rangeKey="name"
- idKey="id"
- @selectGenzongDep="selectGenzongDep"
- />
- <select-xiangguandep
- ref="selectXiangguanDep"
- :multiple="true"
- :range="range"
- :selectParent="true"
- :foldAll="true"
- rangeKey="name"
- idKey="id"
- @selectXiangguanDep="selectXiangguanDep"
- />
- <multiple-select
- v-model="show"
- :data="aboutDept"
- :default-selected="defaultSelected"
- @confirm="confirm"
- ></multiple-select>
- <choose-time @getEndTime="getEndTime()" ref="chooseTime"></choose-time>
- <view class="‘btn-view‘" v-if="!formStatus">
- <button class="btn" @click="editSave()">编辑</button>
- </view>
- </div>
- </template>
-
- <script>
- import tkiTree from "../../../subPackages/components/tkitree/tkitree.vue";
- import selectDengjiyuan from "../../../subPackages/components/select_dengjiyuan/tkitree.vue";
- import selectDengjiren from "../../../subPackages/components/select_dengjiren/tkitree.vue";
- import selectGenzongdep from "../../../subPackages/components/selectGenzongDep/tkitree.vue";
- import selectXiangguandep from "../../../subPackages/components/selectXiangguanDep/tkitree.vue";
- import tools from "../../../subPackages/components/tkitree/tools.js";
- import vantUploader from "../../../../wxcomponents/weapp/dist/uploader";
- import chooseTime from "./chooseTime.vue";
- import multipleSelect from "../../../subPackages/components/momo-multipleSelect/momo-multipleSelect";
- // form.createrName==this.createdBy
- import {
- getSelectUserTwo,
- getSelectDeptTwo,
- findRoomInfoListByIds,
- findCompanyList,
- editSave,
- findDeptList,
- saleControllerGetById,
- findListBySaleManagementId,
- getDeptById,
- getUserLocalStorageInfo,
- findUserList,
- uploadPDF,
- } from "@/js_sdk/http";
- import vanPicker from "../../../../wxcomponents/weapp/dist/picker";
- export default {
- name: "addintention",
- components: {
- tkiTree,
- multipleSelect,
- chooseTime,
- selectDengjiyuan,
- selectDengjiren,
- vantUploader,
- vanPicker,
- selectGenzongdep,
- selectXiangguandep,
- },
- data() {
- return {
- formStatus: false,
- userListPickerStatus: false,
- userList: [],
- needDaysList: [
- { value: 5, text: "5天" },
- { value: 10, text: "10天" },
- { value: 20, text: "20天" },
- { value: 30, text: "30天" },
- { value: 180, text: "180天" },
- { value: 36500, text: "永久" },
- ],
- createdBy: "",
- deptName: "",
- detail: {},
- show: false,
- aboutDept: [],
- defaultSelected: [],
- companyList_index: 0,
- companyList: [],
- range: [],
- fileList: [],
- fangyuanList: [],
- zaitiList: [],
- form: {
- createdBy: "",
- projectType: 1,
- successTime: "",
- companyId: null,
- xiangguanren: "",
- xinxidengji: "",
- xiangmudengji: "",
- relevantUserId: "",
- manageMessengerId: "",
- xiangmudengjiIds: "",
- genzongbumen: "",
- manageTrackingDepId: "",
- xiangguanbumen: "",
- relevantDepId: "",
- fangyuanListIds: "",
- successSaleRoomList: "",
- projectManager: "",
- managerPhone: "",
- projectName: "",
- projectInfo: "",
- leaseRequirements: "",
- fangyuanList: [],
- },
- currentDate: new Date().getTime(),
- minDate: new Date().getTime(),
- formatter(type, value) {
- if (type === "year") {
- return `${value}年`;
- }
- if (type === "month") {
- return `${value}月`;
- }
- return value;
- },
- value: null,
- rules: {
- // 对name字段进行必填验证
- name: {
- rules: [
- {
- required: true,
- errorMessage: "请输入",
- },
- {
- minLength: 3,
- maxLength: 5,
- errorMessage: "姓名长度在 {minLength} 到 {maxLength} 个字符",
- },
- ],
- },
- // 对email字段进行必填验证
- email: {
- rules: [
- {
- format: "email",
- errorMessage: "请输入正确的邮箱地址",
- },
- ],
- },
- },
- today: "",
- muqianjieduan: [
- { text: "跟进中", value: 1 },
- { text: "已确认", value: 2 },
- { text: "已签约", value: 3 },
- { text: "关闭", value: 4 },
- ],
- };
- },
- onLoad(option) {
- this.createdBy = JSON.parse(
- uni.getStorageSync("laocui_user_info")
- ).user.truename;
- console.log("this.createdBy", this.createdBy);
- this.saleControllerGetById(option.id);
- this.findListBySaleManagementId(option.id);
- // /wx/SaleController/getById
- // this.getDeptById();
- this.findUserList();
- this.getCurrentDate();
- this.form.userId = getUserLocalStorageInfo().user.id;
- // SaleControllerGetById
- },
- onShow() {
- let that = this;
- uni.$on("getuser", function (e) {
- console.log(e);
- console.log("that.today", that.today);
- findRoomInfoListByIds(e.result.join(",")).then((data) => {
- if (e.type == "房源") {
- // that.fangyuanList = [];
- data.forEach((a) => {
- a.reservationStatus = 2;
- a.remark = a.roomString;
- a.createdAt = that.today;
- a.needDays = 5;
- a.needDaysIndex = "0";
- var dd = new Date();
- const dd2 = new Date(dd.getFullYear(), dd.getMonth(), dd.getDate());
- const endTime = that.getMyDate(new Date(dd2.getTime()));
- a.endTime = endTime;
- console.log(data);
- that.fangyuanList.push(a);
- that.getNeedDays({ detail: { value: 0 } }, index);
- });
- console.log(that.fangyuanList);
- that.form.fangyuanList = that.fangyuanList;
- for (let i = 0; i < that.form.fangyuanList.length; i++) {
- for (let j = i + 1; j < that.form.fangyuanList.length; j++) {
- if (
- that.form.fangyuanList[i].id == that.form.fangyuanList[j].id
- ) {
- that.form.fangyuanList.splice(j, 1);
- }
- }
- }
- that.form.fangyuanListIds = "";
- that.form.fangyuanListIds = e.result.join(",");
- }
- if (e.type == "载体") {
- let all = [...that.zaitiList, ...data];
- // for (let i = 0; i < all.length; i++) {
- // for (let j = 1; j < all.length; j++) {
- // if (all[i] == all[j]) {
- // all.splice(i, 1);
- // }
- // }
- // }
- for (let i = 0; i < all.sort().length; i++) {
- for (let j = i + 1; j < all.sort().length; j++) {
- if (all[i].id == all[j].id) {
- all.splice(i, 1);
- j--;
- }
- }
- }
- that.zaitiList = all;
- // that.form.successSaleRoomList = "";
- // that.form.successSaleRoomList = e.result.join(",");
- }
- });
- });
- },
- methods: {
- openFile(url) {
- console.log(url);
- uni.downloadFile({
- url: url, // 网络文档地址
- success: (data) => {
- if (data.statusCode === 200) {
- console.log(data);
- uni.getFileSystemManager().saveFile({
- tempFilePath: data.tempFilePath, //临时路径
- success: function (res) {
- // 保存路径
- console.log(res);
- uni.openDocument({
- filePath: res.savedFilePath,
- success: function (res) {
- console.log(res);
- },
- fail(e) {
- console.error(e);
- },
- });
- },
- fail(e) {
- console.error(e);
- },
- });
- }
- },
- fail: (err) => {
- uni.showToast({
- title: "失败请重新下载",
- });
- },
- });
- },
- uploadAddressExcelSplice(index) {
- this.fileList.splice(index, 1);
- },
- async choosePDf() {
- let that = this;
- uploadPDF().then((data) => {
- console.log(data);
- that.fileList.push({
- imgUrl: "/FileController/download/" + data.url,
- imageUrl: "/FileController/download/" + data.url,
- id: data.url,
- url: that.$constant.BASE_URI + "/FileController/download/" + data.url,
- isImage: true,
- name: data.name,
- });
- console.log(that.fileList);
- this.$forceUpdate();
- });
- },
- getUser(e) {
- this.form.createdBy = this.userList[e.detail.value].id;
- this.form.createrName = this.userList[e.detail.value].truename;
- this.getDeptById(this.userList[e.detail.value].department);
- },
- async findUserList() {
- let data = await findUserList();
- this.userList = data;
- console.log(data);
- },
- getCurrentDate() {
- const nowDate = new Date();
- const date = {
- year: nowDate.getFullYear(),
- month: nowDate.getMonth() + 1,
- date: nowDate.getDate(),
- };
- console.log(date.month);
- console.log(date.date);
- this.today =
- date.year +
- "-" +
- (date.month < 10 ? 0 : "") +
- date.month +
- "-" +
- (date.date < 10 ? 0 : "") +
- date.date;
- console.log(this.today);
- },
- addZero(num) {
- if (parseInt(num) < 10) {
- num = "0" + num;
- }
- return num;
- },
- getMyDate(str) {
- var oDate = str;
- let oYear = oDate.getFullYear();
- let oMonth = oDate.getMonth() + 1;
- let oDay = oDate.getDate();
- let oHour = oDate.getHours();
- let oMin = oDate.getMinutes();
- let oSen = oDate.getSeconds();
- let oTime = oYear + "-" + this.addZero(oMonth) + "-" + this.addZero(oDay);
- return oTime;
- },
- getNeedDays(event, index, needTime) {
- console.log(event);
- let ndTime = new Date(needTime.replace(/-/g, "/"));
- console.log(ndTime);
- var resultDate = new Date(
- (ndTime / 1000 + 86400 * this.needDaysList[event.detail.value].value) *
- 1000
- );
- let month =
- resultDate.getMonth() < 10
- ? "0" + (resultDate.getMonth() + 1)
- : resultDate.getMonth();
- let resultDateStr =
- resultDate.getFullYear() + "-" + month + "-" + resultDate.getDate();
- console.log(resultDateStr);
- this.fangyuanList[index].endTime = resultDateStr;
- this.fangyuanList[index].needDays =
- this.needDaysList[event.detail.value].value;
- this.$forceUpdate();
- },
- async editSave() {
- console.log("that.fangyuanList", this.fangyuanList);
- console.log("that.form.fangyuanList", this.form.fangyuanList);
- let that = this;
- for (const key in that.form) {
- if (!that.form[key]) {
- that.form[key] = "";
- }
- }
- let saleRoomList = [];
- if (that.fangyuanList && that.fangyuanList.length > 0) {
- saleRoomList = that.fangyuanList.map((e) => {
- console.log(e);
- return {
- remark: !e.remark ? null : e.remark,
- reservationStatus: !e.reservationStatus ? 1 : e.reservationStatus,
- parkRoomId: e.id,
- needDays: e.needDays ? e.needDays : 0,
- endTime: !e.endTime ? null : e.endTime,
- successStatus: null,
- };
- });
- } else {
- saleRoomList = [];
- }
- let successSaleRoomList = [];
- if (that.zaitiList && that.zaitiList.length > 0) {
- successSaleRoomList = that.zaitiList.map((e) => {
- return {
- remark: !e.roomString ? "" : e.roomString,
- reservationStatus: !e.reservationStatus ? 1 : e.reservationStatus,
- parkRoomId: e.id,
- endTime: !e.endTime ? null : e.endTime,
- successStatus: null,
- };
- });
- } else {
- successSaleRoomList = [];
- }
- let successPictureAddress = [];
- console.log("that.fileList", that.fileList);
- if (that.fileList.length > 0) {
- successPictureAddress = that.fileList.map((e) => {
- console.log({ url: e.imageUrl });
- return {
- name: e.name,
- size: e.size,
- url: e.imageUrl,
- };
- });
- }
- let data = await editSave({
- ...that.form,
- saleRoomList: JSON.stringify(saleRoomList),
- successPictureAddress: JSON.stringify(successPictureAddress),
- successSaleRoomList: JSON.stringify(successSaleRoomList),
- successRoom: this.zaitiList
- .map((e) => {
- return e.roomString;
- })
- .join(","),
- });
- console.log(JSON.stringify(successPictureAddress));
- console.log(data);
- if (data.code == 200) {
- that.$showToast("修改成功");
- uni.navigateBack({});
- } else {
- that.$showToast(data.msg);
- }
- },
- async getDeptById(id) {
- console.log("创建者id是啥", id);
- let data = await getDeptById({
- id: id,
- });
- this.form.deptName = data.deptName;
- },
- async findListBySaleManagementId(id) {
- let data = await findListBySaleManagementId({ id: id });
- console.log(data);
- data.forEach((item) => {
- item.createdAt = this.$common.transServDate(item.createdAt);
- item.endTime = this.$common.transServDate(item.endTime);
- });
- this.fangyuanList = data;
- this.form.fangyuanList = data;
- console.log(this.form.fangyuanList);
- },
- async saleControllerGetById(id) {
- let data = await saleControllerGetById(id);
- this.form = data;
- if (this.createdBy == data.createrName || this.createdBy == "管理") {
- this.formStatus = false;
- } else {
- this.formStatus = true;
- }
- this.form.xiangguanbumen = data.relevantDepId;
- this.form.xiangguanren = data.relevantUserId;
- this.form.xinxidengji = data.manageMessengerIdName;
- this.form.genzongbumen = data.manageTrackingDepIdName;
- // this.getDeptById(data.createdBy);
- if (data.successPictureAddress) {
- this.fileList = JSON.parse(data.successPictureAddress).map((e) => {
- console.log(e);
- let url = e.url;
- console.log(url);
- return {
- name: e.name,
- size: e.size,
- url: this.$constant.BASE_URI + url.replace("/webServer", ""),
- imageUrl: url,
- isImage: true,
- };
- });
- this.$forceUpdate();
- } else {
- this.fileList = [];
- }
- console.log(this.fileList);
- },
- async findDeptList() {
- let aboutDept = await findDeptList();
- this.aboutDept = aboutDept.map((e) => {
- return {
- label: e.deptName,
- value: e.id,
- };
- });
- },
- confirm(e) {
- var xiangguanbumen = [];
- var relevantDepId = [];
- for (var p in e) {
- xiangguanbumen.push(e[p].label);
- relevantDepId.push(e[p].value);
- }
- this.form.xiangguanbumen = xiangguanbumen.join(",");
- this.form.relevantDepId = relevantDepId.join(",");
- },
- chosseAboutCompany() {
- this.show = true;
- },
- signing(i) {
- let that = this;
- if (that.zaitiList.length > 0) {
- let isReport = false;
- for (let index = 0; index < that.zaitiList.length; index++) {
- if (that.zaitiList[index].id === that.fangyuanList[i].id) {
- that.$showToast("该载体已存在与签约载体列表内");
- isReport = true;
- return;
- }
- }
- if (!isReport) {
- that.zaitiList.push(this.fangyuanList[i]);
- }
- } else {
- that.zaitiList.push(this.fangyuanList[i]);
- }
- },
- getEndTime(i, time, type) {
- console.log(i, time);
- console.log(this.fangyuanList[i]);
- this.fangyuanList[i].endTime = "";
- this.fangyuanList[i].reservationStatus = "";
- this.fangyuanList[i].reservationStatus = type;
- this.fangyuanList[i].endTime = time;
- this.$forceUpdate();
- },
- yuyueChooseTime(i, type) {
- this.$refs.chooseTime.onOpen(i, type);
- },
- fangyuanListSplice(i) {
- if (this.fangyuanList[i].reservationStatus == 7) {
- this.$showToast("该房源已解锁");
- } else {
- this.fangyuanList[i].reservationStatus = 7;
- this.$forceUpdate();
- }
- },
- getjieduan(e) {
- console.log(this.form.projectStatus);
- },
- deleteFileList(event) {
- this.fileList.splice(event.detail.index, 1);
- },
- getQymc(index) {
- let that = this;
- console.log(that.companyList[index]);
- that.form.companyId = that.companyList[index].id;
- return that.companyList[index].qymc;
- },
- bindPickerChange(e) {
- let that = this;
- that.companyList_index = e.detail.value;
- },
- async findCompanyList() {
- let data = await findCompanyList();
- this.companyList = data;
- this.companyList[0].id;
- },
- zaitiListSplice(index) {
- this.zaitiList.splice(index, 1);
- },
- // /wx/SaleController/findRoomInfoListByIds
- async findRoomInfoListByIds() {
- let data = await findRoomInfoListByIds(ids);
- return data;
- },
- xiangmudengji(e) {
- var names = [];
- var ids = [];
- for (var p in e) {
- if (e[p].type == "u") {
- names.push(e[p].name);
- ids.push(e[p].id);
- }
- }
- this.form.xiangmudengji = names.join(",");
- this.form.xiangmudengjiIds = ids.join(",");
- },
- selectGenzongDep(e) {
- var names = [];
- var ids = [];
- for (var p in e) {
- names.push(e[p].name);
- ids.push(e[p].id);
- }
- this.form.genzongbumen = names[names.length - 1];
- this.form.manageTrackingDepId = ids[ids.length - 1];
- },
- selectXiangguanDep(e) {
- var names = [];
- var ids = [];
- for (var p in e) {
- names.push(e[p].name);
- ids.push(e[p].id);
- }
- this.form.xiangguanbumen = names.join(",");
- this.form.relevantDepId = ids.join(",");
- },
- selectDengjiyuan(e) {
- var names = [];
- var ids = [];
- for (var p in e) {
- if (e[p].type == "u") {
- names.push(e[p].name);
- ids.push(e[p].id);
- }
- }
- this.form.xinxidengji = names.join(",");
- this.form.manageMessengerId = ids.join(",");
- },
- userSelectorConfirm(e) {
- var names = [];
- var ids = [];
- for (var p in e) {
- if (e[p].type == "u") {
- names.push(e[p].name);
- ids.push(e[p].id);
- }
- }
- this.form.xiangguanren = names.join(",");
- this.form.relevantUserId = ids.join(",");
- },
- // 取消回调事件
- treeCancel(e) {},
- async getSelectUserTwo(key) {
- let that = this;
- let departmentList = await getSelectUserTwo("");
- that.range = tools.transData(
- departmentList.data,
- "id",
- "parentid",
- "children"
- );
- that.$refs[key]._show();
- },
- async getSelectDeptTwo(key) {
- let that = this;
- let departmentList = await getSelectDeptTwo("");
- that.range = tools.transData(
- departmentList.data,
- "id",
- "parentid",
- "children"
- );
- that.$refs[key]._show();
- },
- jumpChosseHouse(e) {
- uni.navigateTo({
- url: "/pages/subPackages/chosseHouse/chosseHouse?type=" + e,
- });
- },
- afterRead(event) {
- let that = this;
- const { file } = event.detail;
- uni.uploadFile({
- url: that.$constant.BASE_URI + "/wx/fileController/upload2",
- filePath: file.url,
- name: "file",
- formData: { user: "test" },
- success(res) {
- // 上传完成需要更新 fileList
- let data = JSON.parse(res.data);
- console.log("处理后的data", data);
- console.log(
- that.$constant.BASE_URI + "/FileController/download/" + data.data[1]
- );
- that.fileList.push({
- name: JSON.parse(data.data[0]).name,
- size: JSON.parse(data.data[0]).size,
- imgUrl: "/FileController/download/" + data.data[1],
- url:
- that.$constant.BASE_URI +
- "/FileController/download/" +
- data.data[1],
- isImage: true,
- });
- },
- fail(res) {},
- });
- },
- beforeRead(event) {
- const { file, callback } = event.detail;
- console.log("我日历吗", file);
- callback(file.type === "image");
- },
- binddata() {},
- submit() {},
- },
- };
- </script>
-
- <style lang="scss">
- .pdfname {
- color: #777777;
- font-size: 28rpx;
- width: 75%;
- white-space: nowrap;
- overflow: hidden;
- text-overflow: ellipsis;
- margin-right: 16rpx;
- float: left;
- }
- .pdflist-row {
- margin: 15rpx 0 15rpx 0;
- display: flex;
- justify-content: space-between;
- width: 100%;
- }
- .pdflist {
- width: 100%;
- display: flex;
- flex-wrap: wrap;
- }
- .form_row {
- height: 40rpx;
- font-weight: 400;
- font-size: 24rpx;
- }
- .userbox {
- font-size: 28rpx;
- height: 61rpx;
- border: 1px solid #dcdfe6;
- border-radius: 4px;
- padding-left: 10px;
- line-height: 61rpx;
- }
- .addintention {
- .btn-view {
- width: 100%;
- height: 100rpx;
- padding: 20rpx 10%;
- background-color: #ffffff;
- position: fixed;
- bottom: 0;
- left: 0;
- }
- .btn {
- border-radius: 8rpx 8rpx 8rpx 8rpx;
- width: 80%;
- height: 90rpx;
- // border-radius: 50rpx 50rpx 50rpx 50rpx;
- background: #1d18bc;
- line-height: 90rpx;
- color: white;
- }
- .uni-forms-item__label {
- text {
- font-size: 28rpx;
- font-weight: 500;
- //color: #333333;
- }
- }
- .zaiti_list {
- width: 100%;
- min-height: 50rpx;
- line-height: 50rpx;
- }
- .zaiti {
- color: #777777;
- }
- .zaiti:first-child {
- margin: 0 !important;
- }
- .bottom_cell {
- float: right;
- height: 42rpx;
- }
- .button_row {
- color: #1d18bc;
- width: 96rpx;
- height: 42rpx;
- border-radius: 60rpx 60rpx 60rpx 60rpx;
- opacity: 1;
- margin-left: 16rpx;
- float: left;
- text-align: center;
- line-height: 42rpx;
- font-size: 24rpx;
- border: 2rpx solid #1d18bc;
- }
- .disable-btn {
- color: #cccccc;
- width: 96rpx;
- height: 42rpx;
- border-radius: 60rpx 60rpx 60rpx 60rpx;
- opacity: 1;
- margin-left: 16rpx;
- float: left;
- text-align: center;
- line-height: 42rpx;
- font-size: 24rpx;
- border: 2rpx solid #cccccc;
- }
- .project-column {
- border-radius: 8rpx 8rpx 0rpx 0rpx;
- //height: 44rpx;
- font-size: 32rpx;
- font-family: PingFang SC-Medium, PingFang SC;
- font-weight: 500;
- color: #333333;
- background: #ffffff;
- }
- .status_label {
- width: 96rpx;
- height: 50rpx;
- line-height: 50rpx;
- background: rgba(29, 24, 188, 0.05);
- color: #1d18bc;
- font-weight: 500;
- font-size: 24rpx;
- border-radius: 8rpx 8rpx 8rpx 8rpx;
- }
- .first_title {
- line-height: 50rpx;
- font-weight: 500;
- }
- .uni-forms-item {
- display: block !important;
- margin: 0;
- }
- .editSave {
- color: #3f3fb4;
- background: #eaeaf2;
- width: 170rpx;
- height: 50rpx;
- text-align: center;
- line-height: 50rpx;
- border: 2rpx #a6a6a9 dashed;
- }
- .list-row {
- width: calc(100% - 64rpx);
- padding: 16rpx 32rpx 18rpx 32rpx;
- background: #ffffff;
- margin-bottom: 16rpx;
- display: flex;
- //height: 278rpx;
- border-radius: 8rpx 8rpx 8rpx 8rpx;
- }
- .icon_phone {
- }
- .list-row {
- width: calc(100% - 64rpx);
- padding: 32rpx 32rpx 38rpx 32rpx;
- background: #ffffff;
- margin-bottom: 16rpx;
- display: flex;
- //height: 278rpx;
- border-radius: 8rpx 8rpx 8rpx 8rpx;
- }
- .mb32rpx {
- margin-bottom: 32rpx;
- }
- .second_title {
- float: left;
- font-size: 28rpx;
- font-family: PingFang SC-Medium, PingFang SC;
- font-weight: 500;
- color: #777777;
- width: 100%;
- }
- .call_icon {
- height: 40rpx;
- width: 40rpx;
- margin-top: -5rpx;
- margin-left: 5rpx;
- float: left;
- }
- .second_title_2 {
- float: left;
- width: 38%;
- font-size: 28rpx;
- font-family: PingFang SC-Medium, PingFang SC;
- font-weight: 500;
- text-align: right;
- color: #777777;
- }
- .list {
- width: calc(100% - 64rpx);
- margin: 32rpx;
- }
- .form {
- width: calc(100% - 128rpx);
- margin: 32rpx;
- background: #ffffff;
- padding: 32rpx;
- .label {
- height: 53rpx;
- line-height: 53rpx;
- }
- }
- .checklist-box {
- margin: 0 !important;
- margin-right: 16rpx !important;
- }
- .labelcolmt26 {
- .van-cell {
- padding: 0 0 0 28rpx !important;
- }
- .van-col {
- margin-top: 26rpx !important;
- }
- label {
- color: #333333;
- font-size: 30rpx;
- margin-top: 10rpx !important;
- }
- .uni-data-checklist {
- margin-top: -10rpx !important;
- }
- }
- .status {
- .uni-data-checklist {
- margin-top: 0rpx !important;
- }
- label {
- color: #333333;
- font-size: 30rpx;
- padding-right: 0rpx !important;
- }
- }
- }
- </style>
-
-
|