123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798 |
- <template>
- <view class="company-box">
- <nav-bar title="编辑公司信息" color="#000"></nav-bar>
- <view
- class="text-center text-red bg-white"
- v-if="form.auditContent && form.status == 3"
- >拒绝理由:{{ form.auditContent }}
- </view>
- <view class="company-content">
- <view class="padding">
- <view class="padding bg">
- <u-form
- :model="form"
- ref="uForm"
- label-position="top"
- :label-style="lableStyle"
- label-width="240"
- >
- <u-form-item label="企业名称" :border-bottom="false">
- <u-input
- placeholder="请输入企业名称"
- v-model="form.companyName"
- inputAlign="text-align:left"
- class="custom-input"
- />
- </u-form-item>
- <u-form-item label="公司规模" :border-bottom="false">
- <u-input
- placeholder="请输入公司规模"
- disabled
- @click="Comshow = true"
- v-model="form.companyPeople"
- inputAlign="text-align:left"
- class="custom-input"
- />
- </u-form-item>
- <u-form-item label="公司所在地" :border-bottom="false">
- <u-input
- placeholder="请选择省市区"
- :disabled="true"
- v-model="form.companyAddress1"
- @click="selectAddress()"
- inputAlign="text-align:left"
- class="custom-input no-border"
- />
- <u-input
- @click="selectAddress()"
- :disabled="true"
- placeholder="请选择详细地址"
- v-model="form.companyAddress"
- inputAlign="text-align:left"
- class="custom-input no-border"
- />
- </u-form-item>
- <u-form-item label="公司所属行业" :border-bottom="false">
- <u-input
- placeholder="请选择公司所属行业"
- v-model="form.companyScope"
- :disabled="true"
- @click="gotoHy()"
- inputAlign="text-align:left"
- class="custom-input"
- />
- </u-form-item>
- <u-form-item label="法人" :border-bottom="false">
- <u-input
- placeholder="请输入公司法人"
- v-model="form.companyLegalPerson"
- inputAlign="text-align:left"
- class="custom-input"
- />
- </u-form-item>
- <u-form-item label="企业邮箱" :border-bottom="false">
- <u-input
- placeholder="请输入企业邮箱"
- v-model="form.email"
- inputAlign="text-align:left"
- class="custom-input"
- />
- </u-form-item>
- <u-form-item label="注册资金(万)" :border-bottom="false">
- <u-input
- placeholder="请输入注册资金(万)"
- type="number"
- v-model="form.companyRegisteredFund"
- inputAlign="text-align:left"
- class="custom-input"
- />
- </u-form-item>
- <u-form-item label="注册时间" :border-bottom="false">
- <u-input
- placeholder="请输入注册时间"
- v-model="form.companyCreateTime"
- inputAlign="text-align:left"
- :disabled="true"
- @click="companyShow = true"
- class="custom-input"
- />
- </u-form-item>
- <u-form-item label="公司介绍" :border-bottom="false">
- <view class="check-box">
- <u-input
- type="textarea"
- style="padding: 10rpx"
- :maxlength="-1"
- height="350"
- placeholder="请输入公司介绍"
- v-model="form.companyDetails"
- :clearable="false"
- inputAlign="text-align:left"
- />
- </view>
- </u-form-item>
- </u-form>
- </view>
- <view class="yyzz flex justify-center">
- <view class="yyzz-box">
- <view class="yyzz-box-title"> 营业执照照片 </view>
- <view class="yyzz-box-images flex justify-center align-center">
- <view
- class="yyzz-box-images-c flex flex-wrap align-center"
- @click="addImage(2)"
- >
- <block v-if="!form.companyCertification">
- <view class="flex align-center justify-center" style="width: 100%">
- <u-icon name="camera" color="#000000" size="65"></u-icon>
- </view>
- <view class="yyzz-box-images-c-t flex justify-center">
- 营业执照照片
- </view>
- </block>
- <block v-else>
- <image
- :src="form.companyCertification"
- style="width: 100%; height: 100%"
- mode=""
- >
- </image>
- </block>
- </view>
- </view>
- </view>
- </view>
- <view class="yyzz flex justify-center" style="margin-bottom: 40rpx">
- <view class="yyzz-box">
- <view class="yyzz-box-title"> 企业头像照片 </view>
- <view class="yyzz-box-images flex justify-center align-center">
- <view
- class="yyzz-box-images-c flex justify-center flex-wrap"
- @click="addImage(1)"
- >
- <block v-if="!form.companyLogo">
- <view class="flex align-center justify-center" style="width: 100%">
- <u-icon name="camera" color="#000000" size="65"></u-icon>
- </view>
- <view class="yyzz-box-images-c-t flex justify-center">
- 企业头像照片
- </view>
- </block>
- <block v-else>
- <image
- :src="form.companyLogo"
- style="width: 100%; height: 100%"
- mode=""
- ></image>
- </block>
- </view>
- </view>
- </view>
- </view>
- <u-button
- @click="submit"
- class="margin-top"
- :custom-style="customStyle"
- shape="square"
- :hair-line="false"
- >提交审核
- </u-button>
- </view>
- </view>
- <u-picker v-model="companyShow" mode="time" @confirm="companyConfirm"></u-picker>
- <!-- 求职岗位 -->
- <u-select
- z-index="99999999"
- v-model="postShow"
- :list="postlist"
- @confirm="postConfirm"
- ></u-select>
- <!-- 区域选择 -->
- <u-picker v-model="show" mode="region" @confirm="confirm"></u-picker>
- <!-- 招聘信息选择弹窗 -->
- <u-popup
- v-model="zhaoShow"
- @open="open"
- style="overflow-y: hidden"
- width="80%"
- height="500rpx"
- :closeable="true"
- mode="center"
- border-radius="14"
- >
- <view class="" style="width: 100%; height: 90%; overflow: hidden">
- <view class="selectTitle">选择</view>
- <view class="selectbox flex justify-center">
- <view class="selectbox-con">
- <view class="flex align-center justify-between margin-bottom">
- <view class="text-bold">岗位</view>
- <view class="text-right flex align-center">
- <u-input
- :disabled="true"
- @click="getClassifyList()"
- placeholder="请选择岗位"
- v-model="postName"
- inputAlign="text-align:left"
- />
- <view class="margin-left-sm">
- <image
- src="../../static/images/my/right_icon.png"
- style="width: 12upx; height: 21upx"
- ></image>
- </view>
- </view>
- </view>
- </view>
- </view>
- <view class="selectbox flex justify-center">
- <view class="selectbox-con">
- <view class="flex align-center justify-between margin-bottom" @click="">
- <view class="text-bold">人数</view>
- <view class="text-right flex align-center">
- <u-input
- type="number"
- placeholder="请输入人数"
- v-model="peopleNum"
- inputAlign="text-align:left"
- />
- <view class="margin-left-sm">
- <image
- src="../../static/images/my/right_icon.png"
- style="width: 12upx; height: 21upx"
- ></image>
- </view>
- </view>
- </view>
- </view>
- </view>
- <view class="selectbox flex justify-center">
- <view
- @click="okHand"
- class="selectbox-con flex justify-center align-center"
- style="
- width: 80%;
- height: 88rpx;
- border-radius: 20rpx;
- background-color: #82a9fe;
- color: #ffffff;
- "
- >
- 确定
- </view>
- </view>
- </view>
- </u-popup>
- <!-- 公司规模 -->
- <u-select
- v-model="Comshow"
- :list="comList"
- value-name="value"
- label-name="value"
- @confirm="comConfirm"
- ></u-select>
- </view>
- </template>
- <script>
- import configdata from "../../common/config.js";
- import navBar from "@/components/nav-bar/index.vue";
- export default {
- data() {
- return {
- Comshow: false,
- show: false,
- form: {
- companyName: "", //企业名称
- companyLegalPerson: "", //公司规模
- companyAddress1: "", //省市区
- companyAddress: "", //营业地址
- companyScope: "", //经营范围
- companyPeople: "", //公司法人
- companyRegisteredFund: "", //注册资金
- companyCreateTime: "", //注册时间
- // companyContent: [], //招聘信息
- companyDetails: "", //简介
- companyLogo: "",
- companyCertification: "", //营业执照
- email: "", //企业邮箱
- companyLat: "",
- companyLng: "",
- province: "", //省
- city: "", //市
- district: "", //区
- },
- lableStyle: {
- color: "#1f2c37",
- fontSize: "28rpx",
- fontWeight: "bold",
- },
- customStyle: {
- backgroundColor: "#FF6600",
- color: "#FFFFFF",
- borderRadius: "100rpx",
- border: 0,
- },
- postlist: [],
- companyShow: false,
- postShow: false,
- zhaoShow: false,
- peopleNum: "",
- postName: "",
- comList: [],
- };
- },
- components: {
- navBar,
- },
- onLoad() {
- this.getCompany();
- this.getComList();
- },
- onShow() {
- let that = this;
- that.Qe = uni.getStorageSync("Qe");
- that.geRen = uni.getStorageSync("geRen");
- //选择的行业
- uni.$on("industry", (info) => {
- that.form.companyScope = info.industry;
- });
- },
- methods: {
- //打开地图选择地址
- selectAddress() {
- let that = this;
- uni.chooseLocation({
- success(res) {
- that.form.companyLat = res.latitude;
- that.form.companyLng = res.longitude;
- that.form.companyAddress = res.name;
- let address = res.address;
- let reg = /.+?(省|市|自治区|自治州|县|区)/g;
- let cityarr = address.match(reg);
- console.log(cityarr, "222222");
- if (cityarr.length > 3) {
- //刚好是省市区
- that.form.province = cityarr[0];
- that.form.city = cityarr[1];
- that.form.district = cityarr[2];
- that.form.companyAddress1 =
- that.form.province + "" + that.form.city + "" + that.form.district;
- } else {
- //可能是直辖市/自治区/自治州
- that.form.province = cityarr[0];
- that.form.city = cityarr[0];
- that.form.district = cityarr[1];
- that.form.companyAddress1 = that.form.province + "" + that.form.district;
- }
- },
- fail(err) {
- uni.showToast({
- title: "打开地图失败,请重试",
- icon: "none",
- });
- },
- });
- },
- //跳转至行业选择
- gotoHy() {
- uni.navigateTo({
- url: "/package/jobIntention/industry?type=2",
- });
- },
- //选择公司规模
- comConfirm(e) {
- this.form.companyPeople = e[0].value;
- },
- //获取公司规模
- getComList() {
- this.$Request
- .get("/app/dict/list", {
- type: "公司规模 ",
- })
- .then((res) => {
- if (res.code == 0) {
- this.comList = res.data;
- }
- });
- },
- confirm(e) {
- this.form.companyAddress1 =
- e.province.label + "" + e.city.label + "" + e.area.label;
- },
- //清除招聘信息
- clearcompanyContent() {
- this.form.companyContent = [];
- },
- //确认选择框
- okHand() {
- let text = this.postName + "" + this.peopleNum + "人";
- this.form.companyContent.push(text);
- this.zhaoShow = false;
- },
- //重置选择框
- open() {
- this.peopleNum = "";
- this.postName = "";
- },
- //选择求职岗位
- postConfirm(e) {
- this.postName = e[0].label;
- },
- //获取求职岗位
- getClassifyList() {
- let data = {
- status: 1,
- };
- this.$Request.get("/app/rule/selectRuleClassifyList", data).then((res) => {
- if (res.code == 0) {
- var arr = [];
- res.data.forEach((d, index) => {
- var data = {};
- data.label = d.ruleClassifyName;
- data.value = d.ruleClassifyId;
- arr.push(data);
- });
- this.postlist = arr;
- this.postShow = true;
- }
- });
- },
- //获取用户企业实名数据
- getCompany() {
- this.$Request.get("/app/company/selectCompanyByUserId").then((res) => {
- if (res.code == 0 && res.data) {
- // res.data.companyContent = res.data.companyContent.split(',')
- this.form = res.data;
- if (this.form.province && this.form.city && this.form.district) {
- this.form.companyAddress1 =
- this.form.province + "" + this.form.city + "" + this.form.district;
- }
- }
- });
- },
- companyConfirm(e) {
- this.form.companyCreateTime = e.year + "-" + e.month + "-" + e.day;
- },
- submit() {
- if (!this.form.companyName) {
- uni.showToast({
- title: "请填写企业名称",
- icon: "none",
- duration: 1000,
- });
- return;
- }
- if (!this.form.companyPeople) {
- uni.showToast({
- title: "请选择企业规模",
- icon: "none",
- duration: 1000,
- });
- return;
- }
- if (!this.form.companyAddress1) {
- uni.showToast({
- title: "请选择省市区",
- icon: "none",
- duration: 1000,
- });
- return;
- }
- if (!this.form.companyAddress) {
- uni.showToast({
- title: "请选择详细地址",
- icon: "none",
- duration: 1000,
- });
- return;
- }
- if (!this.form.companyScope) {
- uni.showToast({
- title: "请选择公司所属行业",
- icon: "none",
- duration: 1000,
- });
- return;
- }
- if (!this.form.companyLegalPerson) {
- uni.showToast({
- title: "请输入公司法人",
- icon: "none",
- duration: 1000,
- });
- return;
- }
- if (!this.form.email) {
- uni.showToast({
- title: "请输入企业邮箱",
- icon: "none",
- duration: 1000,
- });
- return;
- }
- if (!this.form.companyRegisteredFund) {
- uni.showToast({
- title: "请输入注册资金(万)",
- icon: "none",
- duration: 1000,
- });
- return;
- }
- if (!this.form.companyCreateTime) {
- uni.showToast({
- title: "请选择注册时间",
- icon: "none",
- duration: 1000,
- });
- return;
- }
- if (!this.form.companyDetails) {
- uni.showToast({
- title: "请输入公司介绍",
- icon: "none",
- duration: 1000,
- });
- return;
- }
- if (!this.form.companyCertification) {
- uni.showToast({
- title: "请上传营业执照",
- icon: "none",
- duration: 1000,
- });
- return;
- }
- if (!this.form.companyLogo) {
- uni.showToast({
- title: "请上传企业头像 ",
- icon: "none",
- duration: 1000,
- });
- return;
- }
- // this.form.companyContent = this.form.companyContent.length!=0?(this.form.companyContent).join(','):[]
- let data = this.form;
- if (this.form.companyId) {
- this.$Request.postJson("/app/company/updateCompany", data).then((res) => {
- if (res.code == 0) {
- uni.showToast({
- title: "认证修改成功!",
- icon: "none",
- });
- setTimeout(function () {
- uni.navigateBack();
- }, 1000);
- } else {
- uni.showToast({
- title: res.msg,
- icon: "none",
- });
- }
- });
- } else {
- this.$Request.postJson("/app/company/insertCompany", this.form).then((res) => {
- if (res.code == 0) {
- uni.showToast({
- title: "认证提交成功!",
- icon: "none",
- });
- setTimeout(function () {
- uni.navigateBack();
- }, 1000);
- } else {
- uni.showToast({
- title: res.msg,
- icon: "none",
- });
- }
- });
- }
- },
- addImage(e) {
- let that = this;
- uni.chooseImage({
- count: 1,
- sourceType: ["album", "camera"],
- success: (res) => {
- for (let i = 0; i < 1; i++) {
- this.$queue.showLoading("上传中...");
- uni.uploadFile({
- // 上传接口
- // url:configdata.APIHOST1+'/alioss/upload',
- url: "https://zp.xianmaxiong.com/sqx_fast/alioss/upload",
- filePath: res.tempFilePaths[i],
- name: "file",
- success: (uploadFileRes) => {
- if (e == 1) {
- this.form.companyLogo = JSON.parse(uploadFileRes.data).data;
- } else if (e == 2) {
- this.form.companyCertification = JSON.parse(uploadFileRes.data).data;
- }
- uni.hideLoading();
- },
- });
- }
- },
- });
- },
- config: function (name) {
- var info = null;
- if (name) {
- var name2 = name.split("."); //字符分割
- if (name2.length > 1) {
- info = configdata[name2[0]][name2[1]] || null;
- } else {
- info = configdata[name] || null;
- }
- if (info == null) {
- let web_config = cache.get("web_config");
- if (web_config) {
- if (name2.length > 1) {
- info = web_config[name2[0]][name2[1]] || null;
- } else {
- info = web_config[name] || null;
- }
- }
- }
- }
- return info;
- },
- },
- };
- </script>
- <style lang="less" scoped>
- .company-box {
- position: absolute;
- left: 0;
- right: 0;
- bottom: 0;
- top: 0;
- overflow: hidden;
- display: flex;
- flex-direction: column;
- background-color: #fff;
- .company-content {
- flex: 1;
- width: 100%;
- overflow: hidden;
- overflow-y: auto;
- }
- }
- .custom-input {
- width: 100%;
- box-sizing: border-box;
- border: 2rpx solid rgba(158, 161, 168, 1);
- border-radius: 100rpx;
- background: rgba(255, 255, 255, 1);
- padding: 0rpx 24rpx !important;
- margin: 16rpx 0;
- }
- .no-border{
- border: none !important;
- }
- .check-box {
- width: 100%;
- border-radius: 12rpx;
- background: rgba(240, 240, 240, 1);
- padding: 34rpx;
- // padding-top: 40rpx;
- box-sizing: border-box;
- margin: 20rpx 0;
- .word-count {
- font-family: DM Sans;
- font-size: 20rpx;
- font-weight: 400;
- line-height: 26rpx;
- text-align: right;
- text {
- color: #016bf6;
- }
- }
- }
-
- ::v-deep .textarea-placeholder {
- color: rgba(153, 153, 153, 1);
- font-family: DM Sans;
- font-size: 20rpx !important;
- font-weight: 400;
- line-height: 26rpx;
- }
- ::v-deep .uni-textarea-textarea {
- font-size: 20rpx;
- color: #585858;
- }
- ::v-deep .uni-textarea{
- height: 170rpx !important;
- }
- .yyzz {
- width: 100%;
- // height: 815rpx;
- margin-top: 20rpx;
- background-color: #ffffff;
- border-radius: 24rpx;
- .yyzz-box {
- width: calc(100% - 60rpx);
- height: 100%;
- padding-bottom: 40rpx;
- .yyzz-box-title {
- width: 100%;
- margin-top: 40rpx;
- color: #000000;
- font-size: 28rpx;
- font-weight: 800;
- }
- .yyzz-box-images {
- width: 100%;
- height: 320rpx;
- margin-top: 30rpx;
- border: 1rpx dashed #353535;
- }
- .yyzz-box-images-c {
- width: 100%;
- height: 100%;
- align-content: center;
- .yyzz-box-images-c-t {
- width: 100%;
- color: #353535;
- font-size: 20rpx;
- margin-top: 20rpx;
- }
- }
- }
- }
- .u-input__textarea {
- padding: 10rpx 10rpx !important;
- }
- .selectTitle {
- width: 100%;
- text-align: center;
- margin-top: 40rpx;
- font-weight: bold;
- }
- .selectbox {
- width: 100%;
- margin-top: 30rpx;
- .selectbox-con {
- width: 90%;
- }
- }
- textarea {
- background-color: #f7f7f7;
- border-radius: 10rpx;
- margin-top: 20rpx;
- }
- page {
- background-color: #f7f7f7;
- }
- .bg {
- background-color: #ffffff;
- border-radius: 24upx;
- }
- .u-input__input {
- color: red !important;
- }
- .title_btn {
- height: 78rpx;
- line-height: 78rpx;
- /* background: #f7f7f7; */
- }
- </style>
|