|
|
@@ -42,10 +42,9 @@
|
|
|
customStyle="margin-right:40rpx"
|
|
|
label="C"
|
|
|
name="30"></u-radio>
|
|
|
- <!-- <u-radio v-if="projectDetails.nboType === '10'" label="储备" name="50"></u-radio> -->
|
|
|
</u-radio-group>
|
|
|
</u-form-item>
|
|
|
- <!-- A/B -->
|
|
|
+ <!-- C - B 必填项:项目类别、项目预算、渠道销售人员、渠道销售电话、微信、预计出货金额(不填)、添加产品、上传报价单 -->
|
|
|
<view v-if="addForm.nboType !== '30'">
|
|
|
<u-form-item prop="nboBudget" borderBottom customStyle="padding:40rpx 0 30rpx">
|
|
|
<view class="form-label flex_l">
|
|
|
@@ -61,102 +60,40 @@
|
|
|
clearable
|
|
|
customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
</u-form-item>
|
|
|
- <u-form-item
|
|
|
- prop="distributorName"
|
|
|
- borderBottom
|
|
|
- customStyle="padding:40rpx 0 30rpx"
|
|
|
- @click="$refs.dealer.open()">
|
|
|
- <view class="form-label flex_l">经销商/代理商</view>
|
|
|
- <u-input
|
|
|
- :readonly="true"
|
|
|
- placeholder="请选择经销商/代理商"
|
|
|
- v-model="addForm.distributorName"
|
|
|
- border="none"
|
|
|
- suffixIcon="arrow-down"
|
|
|
- suffixIconStyle="color:#CDCDCD"
|
|
|
- clearable
|
|
|
- customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
- </u-form-item>
|
|
|
- <u-form-item prop="parentReceiver" borderBottom customStyle="padding:40rpx 0 30rpx">
|
|
|
- <view class="form-label flex_l">总部对接人</view>
|
|
|
- <u-input
|
|
|
- placeholder="输入总部对接人"
|
|
|
- v-model="addForm.parentReceiver"
|
|
|
- border="none"
|
|
|
- suffixIconStyle="color:#CDCDCD"
|
|
|
- clearable
|
|
|
- customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
- </u-form-item>
|
|
|
- <u-form-item prop="technicalSupportName" borderBottom customStyle="padding:40rpx 0 30rpx">
|
|
|
- <view class="form-label flex_l">
|
|
|
- <view class="label-tag"></view>
|
|
|
- 技术支持人员
|
|
|
- </view>
|
|
|
- <u-input
|
|
|
- placeholder="输入技术支持人员"
|
|
|
- v-model="addForm.technicalSupportName"
|
|
|
- border="none"
|
|
|
- suffixIconStyle="color:#CDCDCD"
|
|
|
- clearable
|
|
|
- customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
- </u-form-item>
|
|
|
- <u-form-item prop="technicalSupportContent" borderBottom customStyle="padding:40rpx 0 30rpx">
|
|
|
- <view class="form-label flex_l">
|
|
|
- <view class="label-tag"></view>
|
|
|
- 技术支持内容
|
|
|
- </view>
|
|
|
- <u-input
|
|
|
- placeholder="输入技术支持内容"
|
|
|
- v-model="addForm.technicalSupportContent"
|
|
|
- border="none"
|
|
|
- suffixIconStyle="color:#CDCDCD"
|
|
|
- clearable
|
|
|
- customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
- </u-form-item>
|
|
|
- <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx" @click="showSupportDate = true">
|
|
|
- <view class="form-label flex_l">技术支持时间</view>
|
|
|
- <u-input
|
|
|
- :readonly="true"
|
|
|
- placeholder="请选择技术支持时间"
|
|
|
- v-model="addForm.technicalSupportTime"
|
|
|
- border="none"
|
|
|
- suffixIcon="arrow-down"
|
|
|
- suffixIconStyle="color:#CDCDCD"
|
|
|
- clearable
|
|
|
- customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
- </u-form-item>
|
|
|
- <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx" @click="showBudgetDate = true">
|
|
|
- <view class="form-label flex_l">项目预算期限</view>
|
|
|
- <u-input
|
|
|
- :readonly="true"
|
|
|
- placeholder="请选择项目预算期限"
|
|
|
- v-model="addForm.nboBudgetTime"
|
|
|
- border="none"
|
|
|
- suffixIcon="arrow-down"
|
|
|
- suffixIconStyle="color:#CDCDCD"
|
|
|
- clearable
|
|
|
- customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
- </u-form-item>
|
|
|
- <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx">
|
|
|
- <view class="form-label flex_l">资金来源</view>
|
|
|
- <u-input
|
|
|
- placeholder="输入资金来源"
|
|
|
- v-model="addForm.capitalSource"
|
|
|
- border="none"
|
|
|
- suffixIconStyle="color:#CDCDCD"
|
|
|
- clearable
|
|
|
- customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
- </u-form-item>
|
|
|
- <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx">
|
|
|
- <view class="form-label flex_l">产品/方案满足情况</view>
|
|
|
- <u-input
|
|
|
- placeholder="输入产品/方案满足情况"
|
|
|
- v-model="addForm.productSatisfaction"
|
|
|
- border="none"
|
|
|
- suffixIconStyle="color:#CDCDCD"
|
|
|
- clearable
|
|
|
- customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
- </u-form-item>
|
|
|
+ <!-- v-if="projectDetails.salesModel !== '10'" -->
|
|
|
+ <view v-if="projectDetails.salesModel !== '10'">
|
|
|
+ <u-form-item
|
|
|
+ prop="dealerSalesName"
|
|
|
+ borderBottom
|
|
|
+ customStyle="padding:40rpx 0 30rpx"
|
|
|
+ @click="$refs.distrConcat.open()">
|
|
|
+ <view class="form-label flex_l">
|
|
|
+ <view class="label-tag"></view>
|
|
|
+ 渠道销售人员
|
|
|
+ </view>
|
|
|
+ <u-input
|
|
|
+ :readonly="true"
|
|
|
+ placeholder="请选择渠道销售人员"
|
|
|
+ v-model="addForm.dealerSalesName"
|
|
|
+ border="none"
|
|
|
+ suffixIcon="arrow-down"
|
|
|
+ suffixIconStyle="color:#CDCDCD"
|
|
|
+ clearable
|
|
|
+ customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
+ </u-form-item>
|
|
|
+ <u-form-item prop="dealerSalesContact" borderBottom customStyle="padding:40rpx 0 30rpx">
|
|
|
+ <view class="form-label flex_l">
|
|
|
+ <view class="label-tag"></view>
|
|
|
+ 渠道销售电话/微信
|
|
|
+ </view>
|
|
|
+ <u-input
|
|
|
+ placeholder="请选择渠道销售人员"
|
|
|
+ v-model="addForm.dealerSalesContact"
|
|
|
+ border="none"
|
|
|
+ clearable
|
|
|
+ customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
+ </u-form-item>
|
|
|
+ </view>
|
|
|
<!-- 上传报价单文件 -->
|
|
|
<u-form-item prop="quotationFile" borderBottom customStyle="padding:40rpx 0 30rpx">
|
|
|
<view class="form-label flex_l">
|
|
|
@@ -175,9 +112,48 @@
|
|
|
</view>
|
|
|
</uni-file-picker>
|
|
|
</u-form-item>
|
|
|
+ <view>
|
|
|
+ <view class="step-tit center">
|
|
|
+ <text class="margin20">添加产品</text>
|
|
|
+ <view class="add-btn" @click="$refs.product.open()">+</view>
|
|
|
+ </view>
|
|
|
+ <view class="product-wrap">
|
|
|
+ <view class="product-item" v-for="(v, i) in productList" :key="v.id">
|
|
|
+ <u-text
|
|
|
+ type="primary"
|
|
|
+ text="删除"
|
|
|
+ customStyle="margin-left:20rpx"
|
|
|
+ @click="removeProductItem(i)"></u-text>
|
|
|
+ <view class="product-label flex_l">
|
|
|
+ 产品编码:
|
|
|
+ <view class="product-val">{{ v.prodCode }}</view>
|
|
|
+ </view>
|
|
|
+ <view class="product-label flex_l">
|
|
|
+ 产品名称:
|
|
|
+ <view class="product-val">{{ v.prodName }}</view>
|
|
|
+ </view>
|
|
|
+ <view class="product-label flex_l">
|
|
|
+ 产品类别:
|
|
|
+ <view class="product-val">{{ v.prodClass }}</view>
|
|
|
+ </view>
|
|
|
+ <view class="product-label flex_l">
|
|
|
+ 产品单价:
|
|
|
+ <view class="product-val">
|
|
|
+ <u-input v-model.number="productList[i].guidPrice" clearable></u-input>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ <view class="product-label flex_l">
|
|
|
+ 产品数量:
|
|
|
+ <view class="product-val">
|
|
|
+ <u-input v-model="productList[i].prodNum" clearable></u-input>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
- <!-- A -->
|
|
|
- <view v-if="addForm.nboType === '10'">
|
|
|
+ <!-- B-A 必填项:采购方式、资金来源、计划 计划采购时间、客户联系人、客户决策部分、客户联系人姓名、客户联系人电话/微信、是否采纳我司技术参数(是/否)、竞争公司、客户倾向厂家 -->
|
|
|
+ <view v-if="addForm.nboType == '10'">
|
|
|
<u-form-item
|
|
|
prop="purchasingWayVal"
|
|
|
borderBottom
|
|
|
@@ -197,74 +173,109 @@
|
|
|
clearable
|
|
|
customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
</u-form-item>
|
|
|
+ <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx">
|
|
|
+ <view class="form-label flex_l">
|
|
|
+ <view class="label-tag"></view>
|
|
|
+ 资金来源
|
|
|
+ </view>
|
|
|
+ <u-input
|
|
|
+ placeholder="输入资金来源"
|
|
|
+ v-model="addForm.capitalSource"
|
|
|
+ border="none"
|
|
|
+ suffixIconStyle="color:#CDCDCD"
|
|
|
+ clearable
|
|
|
+ customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
+ </u-form-item>
|
|
|
<u-form-item
|
|
|
- prop="purchasingTime"
|
|
|
+ prop="planPurchaseTime"
|
|
|
borderBottom
|
|
|
customStyle="padding:40rpx 0 30rpx"
|
|
|
@click="showPurchasingDate = true">
|
|
|
<view class="form-label flex_l">
|
|
|
<view class="label-tag"></view>
|
|
|
- 采购时间
|
|
|
+ 计划采购时间
|
|
|
</view>
|
|
|
<u-input
|
|
|
:readonly="true"
|
|
|
- placeholder="请选择采购时间"
|
|
|
- v-model="addForm.purchasingTime"
|
|
|
+ placeholder="请选择 计划采购时间"
|
|
|
+ v-model="addForm.planPurchaseTime"
|
|
|
border="none"
|
|
|
suffixIcon="arrow-down"
|
|
|
suffixIconStyle="color:#CDCDCD"
|
|
|
clearable
|
|
|
customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
</u-form-item>
|
|
|
- <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx" @click="selectContact()">
|
|
|
- <view class="form-label flex_l">决策人员</view>
|
|
|
+ <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx" prop="makerName">
|
|
|
+ <view class="form-label flex_l">
|
|
|
+ <view class="label-tag"></view>
|
|
|
+ 客户决策人
|
|
|
+ </view>
|
|
|
<u-input
|
|
|
- :readonly="true"
|
|
|
- placeholder="输入决策人员"
|
|
|
+ placeholder="输入客户联系人"
|
|
|
v-model="addForm.makerName"
|
|
|
border="none"
|
|
|
- suffixIconStyle="color:#CDCDCD"
|
|
|
clearable
|
|
|
customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
</u-form-item>
|
|
|
- <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx">
|
|
|
- <view class="form-label flex_l">决策部门</view>
|
|
|
+ <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx" prop="makerDept">
|
|
|
+ <view class="form-label flex_l">
|
|
|
+ <view class="label-tag"></view>
|
|
|
+ 客户决策部门
|
|
|
+ </view>
|
|
|
<u-input
|
|
|
- :readonly="true"
|
|
|
- placeholder="输入决策部门"
|
|
|
+ placeholder="输入客户决策部门"
|
|
|
v-model="addForm.makerDept"
|
|
|
border="none"
|
|
|
- suffixIconStyle="color:#CDCDCD"
|
|
|
clearable
|
|
|
customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
</u-form-item>
|
|
|
- <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx">
|
|
|
- <view class="form-label flex_l">经销商与客户历史成交信息</view>
|
|
|
+ <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx" @click="selectContact()">
|
|
|
+ <view class="form-label flex_l">
|
|
|
+ <view class="label-tag"></view>
|
|
|
+ 客户联系人
|
|
|
+ </view>
|
|
|
<u-input
|
|
|
- placeholder="输入经销商与客户历史成交信息"
|
|
|
- v-model="addForm.historicalTransactionInfo"
|
|
|
+ :readonly="true"
|
|
|
+ placeholder="输入客户联系人"
|
|
|
+ v-model="addForm.contactName"
|
|
|
border="none"
|
|
|
suffixIconStyle="color:#CDCDCD"
|
|
|
clearable
|
|
|
customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
</u-form-item>
|
|
|
- <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx">
|
|
|
- <view class="form-label flex_l">经销商销售人员</view>
|
|
|
+ <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx" prop="contactTelephone">
|
|
|
+ <view class="form-label flex_l">
|
|
|
+ <view class="label-tag"></view>
|
|
|
+ 客户联系人电话/微信
|
|
|
+ </view>
|
|
|
<u-input
|
|
|
- placeholder="输入经销商销售人员"
|
|
|
- v-model="addForm.dealerSalesName"
|
|
|
+ placeholder="输入客户联系人电话/微信"
|
|
|
+ v-model="addForm.contactTelephone"
|
|
|
border="none"
|
|
|
- suffixIconStyle="color:#CDCDCD"
|
|
|
clearable
|
|
|
customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
</u-form-item>
|
|
|
- <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx">
|
|
|
- <view class="form-label flex_l">维护部门及人员</view>
|
|
|
+ <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx" prop="competitor">
|
|
|
+ <view class="form-label flex_l">
|
|
|
+ <view class="label-tag"></view>
|
|
|
+ 竞争公司
|
|
|
+ </view>
|
|
|
<u-input
|
|
|
- placeholder="输入维护部门及人员"
|
|
|
- v-model="addForm.accendant"
|
|
|
+ placeholder="输入竞争公司"
|
|
|
+ v-model="addForm.competitor"
|
|
|
+ border="none"
|
|
|
+ clearable
|
|
|
+ customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
+ </u-form-item>
|
|
|
+ <u-form-item borderBottom customStyle="padding:40rpx 0 30rpx" prop="customerIntentionFactory">
|
|
|
+ <view class="form-label flex_l">
|
|
|
+ <view class="label-tag"></view>
|
|
|
+ 客户倾向厂家
|
|
|
+ </view>
|
|
|
+ <u-input
|
|
|
+ placeholder="输入客户倾向厂家"
|
|
|
+ v-model="addForm.customerIntentionFactory"
|
|
|
border="none"
|
|
|
- suffixIconStyle="color:#CDCDCD"
|
|
|
clearable
|
|
|
customStyle="padding: 0 30rpx 0 12rpx"></u-input>
|
|
|
</u-form-item>
|
|
|
@@ -301,57 +312,48 @@
|
|
|
</uni-file-picker>
|
|
|
</u-form-item>
|
|
|
</view>
|
|
|
- <u-form-item
|
|
|
- prop="projConversionReason"
|
|
|
- customStyle="padding:40rpx 0 30rpx"
|
|
|
- v-if="addForm.isAdoptDashoo != '30'">
|
|
|
- <view class="form-label flex_l">升级原因</view>
|
|
|
- <u-textarea
|
|
|
- fontSize="26rpx"
|
|
|
- v-model="addForm.projConversionReason"
|
|
|
- placeholder="请输入升级原因"
|
|
|
- height="180"
|
|
|
- :count="true"
|
|
|
- maxlength="300"></u-textarea>
|
|
|
- </u-form-item>
|
|
|
- <u-form-item prop="remark" customStyle="padding:40rpx 0 30rpx" v-else>
|
|
|
- <view class="form-label flex_l">
|
|
|
- <view class="label-tag"></view>
|
|
|
- 转化原因
|
|
|
- </view>
|
|
|
- <u-textarea
|
|
|
- fontSize="26rpx"
|
|
|
- v-model="addForm.remark"
|
|
|
- placeholder="请输入转化原因"
|
|
|
- height="180"
|
|
|
- :count="true"
|
|
|
- maxlength="300"></u-textarea>
|
|
|
- </u-form-item>
|
|
|
+ <view v-if="addForm.nboType === '30'">
|
|
|
+ <u-form-item
|
|
|
+ prop="projConversionReason"
|
|
|
+ customStyle="padding:40rpx 0 30rpx"
|
|
|
+ v-if="addForm.isAdoptDashoo != '30'">
|
|
|
+ <view class="form-label flex_l">
|
|
|
+ <view class="label-tag"></view>
|
|
|
+ 转化原因
|
|
|
+ </view>
|
|
|
+ <u-textarea
|
|
|
+ fontSize="26rpx"
|
|
|
+ v-model="addForm.projConversionReason"
|
|
|
+ placeholder="请输入转化原因"
|
|
|
+ height="180"
|
|
|
+ :count="true"
|
|
|
+ maxlength="300"></u-textarea>
|
|
|
+ </u-form-item>
|
|
|
+ </view>
|
|
|
+ <view v-else>
|
|
|
+ <u-form-item prop="remark" customStyle="padding:40rpx 0 30rpx" v-if="addForm.isAdoptDashoo != '30'">
|
|
|
+ <view class="form-label flex_l">
|
|
|
+ <view class="label-tag"></view>
|
|
|
+ 升级原因
|
|
|
+ </view>
|
|
|
+ <u-textarea
|
|
|
+ fontSize="26rpx"
|
|
|
+ v-model="addForm.remark"
|
|
|
+ placeholder="请输入升级原因"
|
|
|
+ height="180"
|
|
|
+ :count="true"
|
|
|
+ maxlength="300"></u-textarea>
|
|
|
+ </u-form-item>
|
|
|
+ </view>
|
|
|
</u-form>
|
|
|
<view class="save" @click="handleUpgrade">提交</view>
|
|
|
</view>
|
|
|
- <!-- 技术支持时间 -->
|
|
|
- <u-datetime-picker
|
|
|
- v-if="showSupportDate"
|
|
|
- :show="showSupportDate"
|
|
|
- mode="date"
|
|
|
- v-model="addForm.technicalSupportTime"
|
|
|
- @cancel="showSupportDate = false"
|
|
|
- @confirm="pickSupportDate"></u-datetime-picker>
|
|
|
- <!-- 项目预算期限 -->
|
|
|
- <u-datetime-picker
|
|
|
- v-if="showBudgetDate"
|
|
|
- :show="showBudgetDate"
|
|
|
- mode="date"
|
|
|
- v-model="addForm.nboBudgetTime"
|
|
|
- @cancel="showBudgetDate = false"
|
|
|
- @confirm="pickBudgetDate"></u-datetime-picker>
|
|
|
- <!-- 采购时间 -->
|
|
|
+ <!-- 计划采购时间 -->
|
|
|
<u-datetime-picker
|
|
|
v-if="showPurchasingDate"
|
|
|
:show="showPurchasingDate"
|
|
|
mode="date"
|
|
|
- v-model="addForm.purchasingTime"
|
|
|
+ v-model="addForm.planPurchaseTime"
|
|
|
@cancel="showPurchasingDate = false"
|
|
|
@confirm="pickPurchasingDate"></u-datetime-picker>
|
|
|
<!-- 采购方式 -->
|
|
|
@@ -361,10 +363,12 @@
|
|
|
keyName="value"
|
|
|
@cancel="showChasingWay = false"
|
|
|
@confirm="pickModel"></u-picker>
|
|
|
- <!-- 选择经销商 -->
|
|
|
- <select-dealer ref="dealer" @close="closeDealer($event)"></select-dealer>
|
|
|
+ <!-- 经销商代理商联系人 -->
|
|
|
+ <distr-contact ref="distrConcat" @close="closeConcat" :distrType="targetType"></distr-contact>
|
|
|
<!-- 客户联系人 -->
|
|
|
<customer-contact ref="contact" @close="closeContact($event)"></customer-contact>
|
|
|
+ <!-- 选择产品 -->
|
|
|
+ <select-product ref="product" :selectedRows="productList" @close="closeProduct($event)"></select-product>
|
|
|
<u-notify ref="uNotify"></u-notify>
|
|
|
<u-toast ref="uToast"></u-toast>
|
|
|
<u-modal
|
|
|
@@ -380,16 +384,16 @@
|
|
|
import {
|
|
|
multipartUpload as upload,
|
|
|
uploadTask as task, //上传任务对象,同requestTask js_sdk\xp-multipart\xp-multipart\xp-multipart.js
|
|
|
-
|
|
|
- // D:\work\oms\js_sdk\xp-multipart\xp-multipart\xp-multipart.js
|
|
|
} from '@/js_sdk/xp-multipart/xp-multipart/xp-multipart'
|
|
|
import projectApi from '../../api/project'
|
|
|
import to from 'await-to-js'
|
|
|
- import SelectDealer from 'components/SelectDealer'
|
|
|
import CustomerContact from '../../components/CustomerContact'
|
|
|
+ import DistrContact from '@/components/DistrContact'
|
|
|
+ import SelectProduct from 'components/SelectProduct'
|
|
|
+
|
|
|
export default {
|
|
|
name: 'omsIndex',
|
|
|
- components: { SelectDealer, CustomerContact },
|
|
|
+ components: { CustomerContact, DistrContact, SelectProduct },
|
|
|
data() {
|
|
|
return {
|
|
|
flag: true,
|
|
|
@@ -397,33 +401,28 @@
|
|
|
paddingTop: '',
|
|
|
showSupportDate: false, //技术支持时间
|
|
|
showBudgetDate: false, //项目预算时间
|
|
|
- showPurchasingDate: false, //采购时间
|
|
|
+ showPurchasingDate: false, // 计划采购时间
|
|
|
showChasingWay: false,
|
|
|
purchasingWayOptions: [],
|
|
|
addForm: {
|
|
|
nboType: '', //项目及别
|
|
|
nboBudget: 0, //项目预算
|
|
|
- distributorName: '', //经销商
|
|
|
- distributorId: '', //经销商ID
|
|
|
- parentReceiver: '', //项目对接人
|
|
|
- technicalSupportName: '', //技术支持人员
|
|
|
- technicalSupportContent: null, //技术支持内容
|
|
|
- technicalSupportTime: '', //技术支持时间
|
|
|
- nboBudgetTime: this.parseTime(new Date(), '{y}-{m}-{d}'), //项目预算时间
|
|
|
+ dealerSalesName: '', //经销商销售人员
|
|
|
+ dealerSalesId: '', //经销商销售人员
|
|
|
capitalSource: '', //资金来源
|
|
|
- productSatisfaction: '', //产品方案满足情况
|
|
|
purchasingWay: '', //采购方式id
|
|
|
purchasingWayVal: '', //采购方式
|
|
|
- purchasingTime: this.parseTime(new Date(), '{y}-{m}-{d}'), //采购时间
|
|
|
- makerId: '', //决策人
|
|
|
- makerName: '', //决策人
|
|
|
- makerDept: '', //决策部门
|
|
|
- historicalTransactionInfo: '', //输入经销商与客户历史成交信息
|
|
|
- dealerSalesName: '', //经销商销售人员
|
|
|
- accendant: '', //维护部门及人员
|
|
|
+ planPurchaseTime: this.parseTime(new Date(), '{y}-{m}-{d}'), // 计划采购时间
|
|
|
+ makerName: '', //客户决策人
|
|
|
+ contactName: '', //客户联系人
|
|
|
+ contactId: '', //客户联系人
|
|
|
+ contactTelephone: '', //客户联系人电话
|
|
|
+ competitor: '', //竞争公司
|
|
|
+ customerIntentionFactory: '', //客户倾向厂家
|
|
|
+ makerDept: '', //客户决策部门
|
|
|
isAdoptDashoo: '', //是否采纳大数技术参数
|
|
|
remark: '', //转化原因
|
|
|
- projConversionReason: '', //升级原因
|
|
|
+ projConversionReason: '', //转化原因
|
|
|
id: 0, //项目id
|
|
|
dashooParamFile: '',
|
|
|
dashooParamFilePaths: '',
|
|
|
@@ -433,48 +432,22 @@
|
|
|
showModal: false,
|
|
|
projectDetails: {},
|
|
|
rules: {
|
|
|
- nboType: {
|
|
|
- type: 'string',
|
|
|
- required: true,
|
|
|
- message: '请选择项目级别',
|
|
|
- trigger: ['blur'],
|
|
|
- },
|
|
|
- technicalSupportName: {
|
|
|
- type: 'string',
|
|
|
- required: true,
|
|
|
- message: '请输入技术支持人员',
|
|
|
- trigger: ['blur'],
|
|
|
- },
|
|
|
- technicalSupportContent: {
|
|
|
- type: 'string',
|
|
|
- required: true,
|
|
|
- message: '请输入技术支持内容',
|
|
|
- trigger: ['blur'],
|
|
|
- },
|
|
|
- nboBudget: {
|
|
|
- type: 'number',
|
|
|
- required: true,
|
|
|
- message: '请输入项目预算',
|
|
|
- trigger: ['blur'],
|
|
|
- },
|
|
|
- purchasingWayVal: {
|
|
|
- type: 'string',
|
|
|
- required: true,
|
|
|
- message: '请输入采购方式',
|
|
|
- trigger: ['blur'],
|
|
|
- },
|
|
|
- technicalSupportTime: {
|
|
|
- type: 'string',
|
|
|
- required: true,
|
|
|
- message: '请输入采购时间',
|
|
|
- trigger: ['blur'],
|
|
|
- },
|
|
|
- isAdoptDashoo: {
|
|
|
- type: 'string',
|
|
|
- required: true,
|
|
|
- message: '请选择是否采纳大数技术参数',
|
|
|
- trigger: ['blur'],
|
|
|
- },
|
|
|
+ nboType: [{ required: true, trigger: ['blur', 'change'], message: '请选择项目类别' }],
|
|
|
+ // C => B
|
|
|
+ nboBudget: [
|
|
|
+ { required: true, trigger: ['blur', 'change'], message: '请输入项目预算' },
|
|
|
+ {
|
|
|
+ validator: (rule, value, callback) => {
|
|
|
+ return parseInt(value) <= 0
|
|
|
+ },
|
|
|
+ trigger: ['blur', 'change'],
|
|
|
+ message: '项目预算应大于0',
|
|
|
+ },
|
|
|
+ ],
|
|
|
+ dealerSalesId: [{ required: true, trigger: ['blur', 'change'], message: '请选择渠道销售' }],
|
|
|
+ dealerSalesName: [{ required: true, trigger: ['blur', 'change'], message: '请选择项渠道销售人员' }],
|
|
|
+ dealerSalesContact: [{ required: true, trigger: ['blur', 'change'], message: '请输入渠道销售电话/微信' }],
|
|
|
+ estTransPrice: [{ required: true, trigger: ['blur', 'change'], message: '请选择预计出货金额' }],
|
|
|
dashooParamFile: {
|
|
|
type: 'object',
|
|
|
required: true,
|
|
|
@@ -487,13 +460,24 @@
|
|
|
message: '请上传报价单',
|
|
|
trigger: ['change'],
|
|
|
},
|
|
|
- remark: {
|
|
|
- type: 'string',
|
|
|
- required: true,
|
|
|
- message: '请输入转化',
|
|
|
- trigger: ['blur'],
|
|
|
- },
|
|
|
+ products: [{ required: true, trigger: ['blur', 'change'], message: '请选择产品' }],
|
|
|
+ // B => A
|
|
|
+ purchasingWay: [{ required: true, trigger: ['blur', 'change'], message: '请选择采购方式' }],
|
|
|
+ capitalSource: [{ required: true, trigger: ['blur', 'change'], message: '请输入资金来源' }],
|
|
|
+ planPurchaseTime: [{ required: true, trigger: ['blur', 'change'], message: '请选择计划采购时间' }],
|
|
|
+ contactId: [{ required: true, trigger: ['blur', 'change'], message: '请选择客户联系人' }],
|
|
|
+ contactName: [{ required: true, trigger: ['blur', 'change'], message: '请选择客户联系人姓名' }],
|
|
|
+ contactTelephone: [{ required: true, trigger: ['blur', 'change'], message: '请输入客户联系人电话/微信' }],
|
|
|
+ makerId: [{ required: true, trigger: ['blur', 'change'], message: '请选择客户决策人' }],
|
|
|
+ makerName: [{ required: true, trigger: ['blur', 'change'], message: '请选择客户决策人姓名' }],
|
|
|
+ makerDept: [{ required: true, trigger: ['blur', 'change'], message: '请选择客户决策部门' }],
|
|
|
+ customerIntentionFactory: [{ required: true, trigger: ['blur', 'change'], message: '请输入客户倾向厂家' }],
|
|
|
+ competitor: [{ required: true, trigger: ['blur', 'change'], message: '请输入竞争公司' }],
|
|
|
+ isAdoptDashoo: [{ required: true, trigger: ['blur', 'change'], message: '请选择是或否' }],
|
|
|
+ projConversionReason: [{ required: true, trigger: ['blur', 'change'], message: '请输入转化原因' }],
|
|
|
+ remark: [{ required: true, trigger: ['blur', 'change'], message: '请输入原因' }],
|
|
|
},
|
|
|
+ productList: [],
|
|
|
}
|
|
|
},
|
|
|
created() {
|
|
|
@@ -524,14 +508,32 @@
|
|
|
this.projectDetails = res.data
|
|
|
this.addForm = Object.assign(this.addForm, this.projectDetails)
|
|
|
this.addForm.nboType = ''
|
|
|
- this.addForm.technicalSupportName = ''
|
|
|
- this.addForm.technicalSupportContent = ''
|
|
|
- this.addForm.technicalSupportTime = this.parseTime(new Date(), '{y}-{m}-{d}')
|
|
|
- this.addForm.nboBudgetTime = this.parseTime(new Date(), '{y}-{m}-{d}')
|
|
|
this.addForm.projConversionReason = ''
|
|
|
this.addForm.remark = ''
|
|
|
+ this.productList = res.data.products.map((item) => ({
|
|
|
+ id: item.prodId,
|
|
|
+ prodCode: item.prodCode,
|
|
|
+ prodName: item.prodName,
|
|
|
+ prodClass: item.prodClass,
|
|
|
+ guidPrice: item.guidPrice,
|
|
|
+ prodPrice: item.marketPrice,
|
|
|
+ prodNum: 1,
|
|
|
+ }))
|
|
|
+ console.log(this.productList)
|
|
|
+ }
|
|
|
+ },
|
|
|
+ closeProduct(product) {
|
|
|
+ if (product.length > 0) {
|
|
|
+ const combinedArray = [...this.productList, ...product]
|
|
|
+ this.productList = Array.from(new Set(combinedArray.map((item) => item.id))).map((id) => {
|
|
|
+ return combinedArray.find((item) => item.id === id)
|
|
|
+ })
|
|
|
+ console.log(this.productList)
|
|
|
}
|
|
|
},
|
|
|
+ removeProductItem(idx) {
|
|
|
+ this.productList.splice(idx, 1)
|
|
|
+ },
|
|
|
changeLevel(e) {
|
|
|
if (e == '20') {
|
|
|
this.addForm.dashooParamFile = ''
|
|
|
@@ -549,11 +551,18 @@
|
|
|
this.addForm.purchasingWayVal = e.value[0].value
|
|
|
this.showChasingWay = false
|
|
|
},
|
|
|
- // 经销商
|
|
|
- closeDealer(dealer) {
|
|
|
- if (dealer) {
|
|
|
- this.addForm.distributorId = dealer.id
|
|
|
- this.addForm.distributorName = dealer.name
|
|
|
+ // 经销商代理商联系人
|
|
|
+ closeConcat(user) {
|
|
|
+ this.addForm.dealerSalesId = user.id
|
|
|
+ this.addForm.dealerSalesName = user.name
|
|
|
+ if (user.phone !== '' && user.wechat !== '') {
|
|
|
+ this.addForm.dealerSalesContact = user.phone + '/' + user.wechat
|
|
|
+ }
|
|
|
+ if (user.phone !== '') {
|
|
|
+ this.addForm.dealerSalesContact = user.phone
|
|
|
+ }
|
|
|
+ if (user.wechat !== '') {
|
|
|
+ this.addForm.dealerSalesContact = user.wechat
|
|
|
}
|
|
|
},
|
|
|
selectContact() {
|
|
|
@@ -571,33 +580,16 @@
|
|
|
// 关闭选择客户联系人
|
|
|
closeContact(user) {
|
|
|
if (user) {
|
|
|
- this.addForm.makerId = user.id
|
|
|
- this.addForm.makerName = user.cuctName
|
|
|
- this.addForm.makerDept = user.dept
|
|
|
- // this.addForm.makerPost = user.postion
|
|
|
- // this.addForm.makerTelephone = user.telephone
|
|
|
+ this.addForm.contactId = user.id
|
|
|
+ this.addForm.contactName = user.cuctName
|
|
|
}
|
|
|
},
|
|
|
- // 技术支持时间
|
|
|
- async pickSupportDate(e) {
|
|
|
- this.showSupportDate = false
|
|
|
- const timeFormat = uni.$u.timeFormat
|
|
|
- let timeValue = await timeFormat(e.value, 'yyyy-mm-dd hh:MM')
|
|
|
- this.addForm.technicalSupportTime = timeValue
|
|
|
- },
|
|
|
- // 项目预算时间
|
|
|
- async pickBudgetDate(e) {
|
|
|
- this.showBudgetDate = false
|
|
|
- const timeFormat = uni.$u.timeFormat
|
|
|
- let timeValue = await timeFormat(e.value, 'yyyy-mm-dd hh:MM')
|
|
|
- this.addForm.nboBudgetTime = timeValue
|
|
|
- },
|
|
|
- // 采购时间
|
|
|
+ // 计划采购时间
|
|
|
async pickPurchasingDate(e) {
|
|
|
this.showPurchasingDate = false
|
|
|
const timeFormat = uni.$u.timeFormat
|
|
|
let timeValue = await timeFormat(e.value, 'yyyy-mm-dd hh:MM')
|
|
|
- this.addForm.purchasingTime = timeValue
|
|
|
+ this.addForm.planPurchaseTime = timeValue
|
|
|
},
|
|
|
// 选择是否采用大数参数
|
|
|
chooseRadio(e) {
|
|
|
@@ -691,23 +683,20 @@
|
|
|
if (!this.flag) return
|
|
|
let params = this.addForm
|
|
|
params.nboBudget = Number(params.nboBudget)
|
|
|
+ params.products = this.productList
|
|
|
this.flag = false
|
|
|
- if (this.addForm.nboType === '10' || this.addForm.nboType === '20') {
|
|
|
- this.upgradeAorB(params)
|
|
|
- } else {
|
|
|
- const [err, res] = await to(projectApi.upgrade(params))
|
|
|
- this.flag = true
|
|
|
- this.showModal = false
|
|
|
- if (err) return
|
|
|
- if (res && res.code == 200) {
|
|
|
- this.$refs.uToast.show({
|
|
|
- type: 'success',
|
|
|
- message: '提交成功',
|
|
|
- complete: () => {
|
|
|
- this.goBack()
|
|
|
- },
|
|
|
- })
|
|
|
- }
|
|
|
+ const [err, res] = await to(projectApi.upgrade(params))
|
|
|
+ this.flag = true
|
|
|
+ this.showModal = false
|
|
|
+ if (err) return
|
|
|
+ if (res && res.code == 200) {
|
|
|
+ this.$refs.uToast.show({
|
|
|
+ type: 'success',
|
|
|
+ message: '提交成功',
|
|
|
+ complete: () => {
|
|
|
+ this.goBack()
|
|
|
+ },
|
|
|
+ })
|
|
|
}
|
|
|
},
|
|
|
goBack() {
|
|
|
@@ -727,7 +716,41 @@
|
|
|
<style lang="scss" scoped>
|
|
|
.home {
|
|
|
padding-top: 188rpx;
|
|
|
-
|
|
|
+ .step-tit {
|
|
|
+ margin-top: 40rpx;
|
|
|
+ text-align: center;
|
|
|
+ line-height: 60rpx;
|
|
|
+ font-size: 26rpx;
|
|
|
+ color: #000;
|
|
|
+ }
|
|
|
+ .product-wrap {
|
|
|
+ width: 100%;
|
|
|
+ margin-top: 30rpx;
|
|
|
+ height: calc(100% - 150rpx);
|
|
|
+ overflow: auto;
|
|
|
+ padding: 0 10rpx;
|
|
|
+ .product-item {
|
|
|
+ margin: 30rpx 0;
|
|
|
+ padding: 20rpx;
|
|
|
+ border-radius: 10px;
|
|
|
+ box-shadow: 0 6rpx 19rpx 2rpx rgba(0, 45, 132, 0.15);
|
|
|
+ .product-label {
|
|
|
+ padding: 20rpx 0 20rpx 20rpx;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .add-btn {
|
|
|
+ color: #fff;
|
|
|
+ width: 120rpx;
|
|
|
+ height: 60rpx;
|
|
|
+ padding: 0rpx 8rpx;
|
|
|
+ font-size: 12rpx;
|
|
|
+ background: #3c9cff;
|
|
|
+ border-radius: 3px;
|
|
|
+ text-align: center;
|
|
|
+ line-height: 58rpx;
|
|
|
+ font-size: 44rpx;
|
|
|
+ }
|
|
|
.nav {
|
|
|
position: absolute;
|
|
|
left: 0;
|